Befunge
rune
Befunge | rune | |
---|---|---|
5 | 22 | |
19 | 1,723 | |
- | 1.5% | |
3.5 | 9.3 | |
12 months ago | 6 days ago | |
JavaScript | Rust | |
- | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Befunge
-
The Rust Performance Book
1. C compilers don't do a good job, & thus even CPython, which has historically stuck to rather vanilla C, uses computed goto, as described in https://eli.thegreenplace.net/2012/07/12/computed-goto-for-e...
I resorted to similar techniques in optimizing Befunge: https://github.com/serprex/Befunge (See bejit.c & marsh.c/marsh.h)
2. Rust enums are not variable sized, think of them as tagged C unions, where the Rust compiler can sometimes apply tricks to make Option> the same size as Vec
3. match can specialize for straight forward cases, when in doubt use https://godbolt.org
- Ask HN: Recommendation for general purpose JIT compiler
-
Why asynchronous Rust doesn't work
I've found async to be straight forward anytime I've used it. Promise#then is equivalent to callbacks
async/await often requires very little changes compared to synchronous code, whereas reworking a program into callbacks is much more impactful. & the async/await compilation process tends to produce better performance in addition to this. My first async/await work was a few years ago to increase a data importer's performance by an order of magnitude compared to the blocking code
Here's an example where looping made for a callback that recursively called, using async/await I get to use a plain loop:
before: https://github.com/serprex/Befunge/blob/946ea0024c4d87a1b75d...
after: https://github.com/serprex/Befunge/blob/9677ddddb7a26b7a17dd...
I don't see why people find it so complicated to separate begin-compute & wait-on-compute
I've since rewritten a nodejs game server into rust, https://github.com/serprex/openEtG/tree/master/src/rs/server... handleget/handlews are quite straight forward
- Python interpreter written in rust reaches 10000 commits
-
Compilers Are Hard
You'll also find them used in CPython's ceval.c
I use them in both my C befunge implementations:
https://github.com/serprex/Befunge/blob/c97c8e63a4eb262f3a60...
https://github.com/serprex/Befunge/blob/c97c8e63a4eb262f3a60...
rune
- 3 years of fulltime Rust game development, and why we're leaving Rust behind
- RustPython
-
Steel β An embedded scheme interpreter in Rust
A Lisp, a weird dialect of Lisp, is not better than Lua. Why use Rune [0]?!
[0]: https://rune-rs.github.io/
-
Embeddable Scripting Language for Embedded Rust
This is what I based my comment on - https://github.com/rune-rs/rune/issues/444
-
-π- 2022 Day 13 Solutions -π-
Late start today as well. I really thought today would be the day that I'd have to abandon my goal of no heap allocations. But, luckily I had an arena allocator available that I could fairly easily adapt to store data on the stack. And with some tweaks we have today's solution:
- α£ the Rune Programming Language
-
thought you guys might like this monstrosity i created (that i actually use in a project)
I'd have given you bonus points for using a rust styled scripting language like rune but that's pretty neat still
-
Visual scripting for Rust
As note about using rust syntax for scripting: https://rune-rs.github.io/
-
Designing a Rust -> Rust plugin system
I know you said you donβt want to embed another language but IMO Rune is worth a consideration here. It can be a pretty thin abstraction over rust by passing native structs to scripts and calling methods on them. The syntax and semantics are very close to rust so it feels natural. https://github.com/rune-rs/rune
-
Rune vs Rhai?
The biggest technical difference I'd say is that Rune uses a stack-based machine which makes adding deep C support somewhat obvious while Rhai performs AST walking to execute scripts.
What are some alternatives?
qbe-rs - QBE IR in natural Rust data structures
Rhai - Rhai - An embedded scripting language for Rust.
openEtG
RustPython - A Python Interpreter written in Rust
ubpf - Userspace eBPF VM
mun - Source code for the Mun language and runtime.
bug - Scala 2 bug reports only. Please, no questions β proper bug reports only.
miniserve - π For when you really just want to serve some files over HTTP right now!
Rustler - Safe Rust bridge for creating Erlang NIF functions
Flux.jl - Relax! Flux is the ML library that doesn't make you tensor
minivm - A VM That is Dynamic and Fast
dyon - A rusty dynamically typed scripting language