-
Notifications
You must be signed in to change notification settings - Fork 0
-
Optimizations
No due date Last updated over 1 year ago"Acceptable" performance from compiled code.
x :: Integer + y :: In…
"Acceptable" performance from compiled code.
x :: Integer + y :: Integer
==>
x.datum.int64 + y.datum.int64
-
CotMTA-experiment
No due date Last updated almost 3 years agoPurpose: determine if Cheney on the MTA -style GC and codegen is su…
Purpose: determine if Cheney on the MTA -style GC and codegen is sufficiently performant. Assumption is that a regular Cheney-GC is a good comparison, with using direct-line code emitted from the same CPS. If CotMTA performance is within 10% of alternative implementation for self-build, I'll assume it's going to be good enough.
Part 1:
- Implement CPS ir.
- Inlining and constant propagation on the CPS.
- Transpile to non-CPS-style C.
Rationale: inlining is likely critical for CotMTA performance, since sends will have the extra tax of a continuation call to return. Also make sure there's a good competitor for CotMTA.
Checkpoint 1: should outperform previous by a good margin.
Part 2:
- Transpile to CPS-style, implement Cheney on the MTA -style GC.
Checkpoint 2: performance comparison. If CotMTA wins at this point, it won already: milestone done.
Part 3:
Assuming CotMTA doesn't win, try to make it win while also giving the other code a fair shake.
Main ideas to implement as optimization of CotMTA:
- known leaf-calls can just return, callers can check the stack as part of their own entry
- expansion of above leaf-call optimization: fully known non-recursive call-trees can have return-style codegen instead, with callers into the tree checking stack before
Checkpoint 3: pick the winner
-
0.2: Self-Hosting
No due date Last updated almost 3 years agoSelf-hosted parser -> CST -> AST -> interprerter and transpiler. …
Self-hosted parser -> CST -> AST -> interprerter and transpiler.
- Able to self-compile.
- Self-compilation results in consistent C source
- Metacircular interpreter
-
0.4: Actors
No due date Last updated almost 3 years agoActors Futures Executors Support > 1K parallel actors on a laptop…
- Actors
- Futures
- Executors
Support > 1K parallel actors on a laptop. Doesn't need to be the greatest yet, but needs to be good enough to use, getting the language level right as first step is important. Finesse like work stealing can come later.
Block + fork model is the current idea:
let mailbox = Mailbox new. let actor = { mailbox do: { |each| MyActor handle: each } } fork. world publish: mailbox as: "MyActor". actor wait: 10 seconds. actor kill.
- Copy the closure to a new actor, run it there.
- Acceptable messages are:
- Mailboxes (pass by id)
- Primitives
- Records
- Tuples
- Arrays
-
0.3: Development Environment
No due date Last updated almost 3 years agoSmalltalkish method browser. 80s design is good enough for first v…
- Smalltalkish method browser. 80s design is good enough for first version.
- Able to run the browser both compiled and interpreted: able to work on Foolang and the browser itself in the browser.
- Support panoply of interactive changes, including redefinitions of globals.
- Application delivery from the browser.
- Live debugger and inspector.
Moved ahead of optimizations because this should be a productivity boon for further Foolang work.