Comments (7)
Hey! Just replied to your comment on #57.
Specifically, do you plan on porting and bootstrapping the compiler?
Eventually. Right now, our main focus is building out the language itself and making it as easy as possible for contributors to contribute. We're at a decent point with thatβwe do have fairly heavy dependencies, but everything is handled through yarn. Contributors don't have to figure out how to install OCaml or anything like that.
There's quite a bit of work that needs to be done with the language before we'd be at a good point to start working on a compiler port to Grain, but we're getting there (we'll need a fully fleshed-out filesystem library, macro system, etc.).
Bootstrapped Grain (let's call it Whole Grain π) is a Grain v2.0.0 idea and we're still working towards v0.1.0. Granted, as soon as GC lands, we pretty much have everything we need for v0.1.0.
Once we're at v0.1.0, we'll start distributing binaries, so all of the OCaml and whatnot will be invisible to users. The Node dependency will slowly go away. Node is a dependency largely because portions of our runtime is written is JS, but we're slowly moving all of it to WebAssembly. Ideally Grain will be able to be run on any WASI-compliant runtime.
Long story short, that's a potential plan for the future, but we've got quite a few hurdles to clear before we get there. Right now we're continuing to put all of our effort towards core language features.
from grain.
Very good answers, thanks! ππ
One more question, if you don't mind: what's the story with regards to parallelism?
Threads, fibers, workers, coroutines... something else?
from grain.
Of course. We haven't talked about it much, but my guess right now would be threads since WebAssembly should make that pretty easy. π
from grain.
And what would thread support look like in the language?
Async/await maybe? Or just an API with threading primitives?
I suppose locks and mutexes wouldn't be required since everything is immutable. (except boxes?)
Some kind of lightweight threading primitive like fibers might be worth considering though - proper thread scheduling is hard, and most modern languages offer something a little more abstract, so that things like web/socket servers can be built to scale safely and easily. (?)
from grain.
I can't yet say what thread support will look like yet, since I haven't put much thought towards it. Since we're aiming to make things like this as easy as possible for users, I imagine that we'll have a decent level of abstraction with whatever we do. Fibers are something to consider, though if we do have them we'll probably still also have access to threads.
Generally, you're rightβmost kinds of computation won't need locks/mutexes which should just in general make parallelism fairly easy, though we'll have to keep in mind that we'll need to make it just as easy for mutable structures as well (to adhere to our language goals).
from grain.
Yeah, threads would be useful as well and might be an easier place to start. Makes sense.
Well, thanks for your time! I will definitely be watching this project to see where it goes. πβοΈ
from grain.
Of course! :D
from grain.
Related Issues (20)
- Formatter: Missing trailing comma on inline record fields
- Stdlib: Add `String.map` and `String.flatMap` functions HOT 2
- Formatter: disallow double-breaks on attributes
- Docs: Add variant docs to Json data structure
- Cleanup: Use graindoc `Markdown` lib in lsp
- Lsp: Provide context for `use XXX.*`
- stdlib: Add `input` function HOT 2
- language: look into overloading the `array[x]` syntax to support multiple number types.
- Rework: `toString` to use a buffer HOT 1
- Decrease initial memory pages to 1 HOT 3
- Implement LEB128 stdlib HOT 2
- stdlib: Add a `TOML` library
- stdlib/runtime: Implement a basic parsing library HOT 1
- Improve compilation of large list/array literals
- Redundant Operations in stdlib Set.intersect HOT 1
- Fix link to lexer in compiler walkthrough
- Installer not Working Windows HOT 3
- Memory leak on unused function calls
- Improve `String.map` and `String.mapi` HOT 2
- LSP: Go to type definition doesn't work for reprovided types
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from grain.