canadahonk
Re:Porffor: A from-scratch ahead-of-time JS engine
on Wednesday July 31, 2024 @05:20AM (#41117573)
This type of test does work as expected. The "sync" means that it does not feature a full event loop (yet) so cannot easily support async I/O or some more "advanced" use cases.
Re:Porffor: A from-scratch ahead-of-time JS engine
on Wednesday July 31, 2024 @05:18AM (#41117557)
Yep! Also as it is technically more of an engine/runtime (sometimes) than "just" a compiler, folks in the JS space are more familiar with engine as a term :)
Re:Porffor: A from-scratch ahead-of-time JS engine
on Tuesday July 30, 2024 @07:22PM (#41115077)
Exactly. The versioning system is definitely unique and controversial, but I think it fits for a fast moving project like this, so I don't have to really consider versioning which could slow development. When it becomes more stable, I'll likely move to a more traditional semver scheme from 1.0.
Re:Porffor: A from-scratch ahead-of-time JS engine
on Tuesday July 30, 2024 @07:20PM (#41115066)
Hey, dev here, I agree that is an interesting application which Porffor could potentially help with! Happy to chat sometime :)
Re:Porffor: A from-scratch ahead-of-time JS engine
on Tuesday July 30, 2024 @07:03PM (#41114977)
Good comparison and thanks! A few minor clarifications:
- Porffor isn't fully self-hosted yet but should be possible hopefully! It does partially compile itself for builtins (eg Array.prototype.filter, Math.sin, atob, ...) though.
- As of late, Porffor does now support basic async/promise/await! Not very well yet though.
Re:Porffor: A from-scratch ahead-of-time JS engine
on Tuesday July 30, 2024 @06:52PM (#41114917)
For now, unless it is given a literal string (eg `eval('42')`) eval just won't work.
Re:Using TS type annotations for JavaScript engine optimization
on Wednesday January 31, 2024 @12:30PM (#39206646)
Agreed, I have it behind a flag because of this, in the (far) future I could enable by default if I write a type checker built-in or something. Thank you!
Re:Using TS type annotations for JavaScript engine optimization
on Wednesday January 31, 2024 @12:29PM (#39206628)
Unfortunately yes, optimizer at high levels is very unstable/aggressive at the moment. Currently working on refactoring things for perf generally instead of just an optimizer, but definitely will fix in the future!
Using TS type annotations for JavaScript engine optimization
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @10:12PM (#38046442)
CSS light-dark() function heh ;)
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @10:10PM (#38046427)
JS is a language I can cobble together something hacky in and I don't have to care about types or anything yet, just making something work. It's fun! :)
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @07:29PM (#38045296)
Zoom isn't taken into account so probably why it looks bad. The FPS is locked to your monitor's frame rate (or what your browser provides, LibreWolf might always send 60 to avoid fingerprinting).
As the post says, it's just for fun :)
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @07:05PM (#38045119)
TIL, looks neat!
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @06:56PM (#38045058)
It's there - Ladybird (https://ladybird.dev)
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @06:27PM (#38044824)
It is technically memory safe :^)
Re:Shadow: New browser engine made almost entirely in JavaScript
on Friday October 27, 2023 @06:07PM (#38044627)
Nope! It uses Wasm (really WASI) builds of existing JS engines ;)