artanidos 4 hours ago

We migrated the core runtime of Forge 4D from C# to C++.

The previous implementation had grown to about 41k lines of C#. The current runtime is roughly 19k lines of C++ and runs about 7× faster in early tests.

Forge is a small native runtime built around two simple concepts: • SML (Simple Markup Language) for application structure • SMS (Simple Multiplatform Script) for application logic

The idea is to keep the runtime small and move most behavior into structured scripts instead of building on top of large browser-based stacks.

Example: Window { Button { id: runButton text: "Run" } }

on runButton.clicked { lo.success("Run button pressed") }

More details about the migration:

https://codeberg.org/CrowdWare/Forge4D/src/branch/main/news/...

Happy to hear feedback.

  • pjmlp 3 hours ago

    I miss what attempts were made to improve the code using modern C#, spans, ref structs, scoped, stackalloc, fixed arrays, and Native AOT, before going into full rewrite.