rustc_codegen_clr
customasm
rustc_codegen_clr | customasm | |
---|---|---|
7 | 10 | |
1,026 | 684 | |
- | - | |
9.7 | 7.8 | |
7 days ago | 4 months ago | |
Rust | Rust | |
MIT License | 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.
rustc_codegen_clr
-
The search for easier safe systems programming
I don't have something that could be of Crafting Interpreters level on hand, but the general suggestion given to this question on DotNetEvolution discord by Roslyn team members was to start with the spec itself: https://ecma-international.org/publications-and-standards/st...
This might be a bit of a learning curve if you don't have experience with writing compilers like that though.
There are other materials that might prove useful should you go down this path:
- A series of blog posts of a student who is writing a Rust to .NET compiler which you could follow along: https://fractalfir.github.io/generated_html/home.html The project itself: https://github.com/FractalFir/rustc_codegen_clr
- A video series on writing a compiler for .NET from scratch: https://www.youtube.com/watch?v=wgHIkdUQbp0&list=PLRAdsfhKI4... Notes: https://github.com/terrajobst/minsk/tree/master/docs
As for CLR via C#, while it has certain facts that remained the same, the ecosystem has changed a lot since then, you really want to target the latest LTS to get best experience and performance.
p.s.: if it's any consolation, the promise in CLR via C# of JIT having the advantage of dynamically profiling code execution and compiling to profile-guided version, tuned to the exact hardware and environment is finally fulfilled, many years later :)
-
Rust to .NET compiler – Progress update
The author answers the "why" in the FAQ https://github.com/FractalFir/rustc_codegen_clr?tab=readme-o.... I didn't find it very convincing but I'm sure the author will learn a lot of neat things along the way.
- Rust in .NET Projects
- RustPython
-
The Rust compiler backend for .NET can now compile std with (numerous) errors, and supports allocation (Box, Vec, String, etc.)
After adding support for statics and many bug fixes related to pointers/slices, my compiler backend targeting .NET can finally build a barely working version of the standard library. It can be loaded into the .NET runtime, allocate memory (e.g. for a Box, Vec or String), push elements to Vec's and String's (currently without relocations). There are also some other parts of the standard library that already work, but I want to stress that the project is still fairly early into development (I started working on it late August), and you should expect most things in std to not work at all. Things working is the exception, not the rule. This newest set of commits allows you to use a small subset of the standard library, within code running inside the .NET runtime. | Here is some Rust code that I wrote to demo the ability to use the Rust std within the .NET runtime:
-
.NET backend for Rust now compiles 1000 functions within core.
This is a small update about my rustc backend, which is supposed to allow compilation of Rust code into .NET assemblies. This would allow you to use Rust crates in C#, and C# libraries in Rust.
-
Need help modeling some type constraints
I am currently working on a rust codegen targeting .NET. One of the features I currently work on is a .NET interop layer, mycorrhiza, and I am having some trouble modeling certain type constraints. There are 2 ways to store a reference to a GC type in Rust: 1. By a handle - this type has some cost associated with it, but can be stored anywhere (heap, stack). 2. By a raw reference - raw references may only live on the stack. They can be copied, and behave almost exactly like a normal rust type (with exceptions related to transmutes and enums), as long as they are stored on the stack.
customasm
-
Defining assembly instructions has killed my love of this game ultra fast.
I'm using customasm to write code in Turing Complete.
-
I was making adder circuits in games 8 years ago in an attempt to build a computer. I finally worked my way up and built a working computer!
also if you start writing programs for your own CPUs, use something like CustomASM so you don't have to write in machine code.
-
Vending Machine - FPGA
either way if you plan on doing more CPUs and similar in the future i highly recommend CustomASM.
-
My 8-bit cpu running at full speed
The source code was in Python. I was able to debug it using Arduino-based adapter and (by using some "magic") translate into machine code binary. Since then I've switched to CustomAsm for code compilation and have other means to debug (emulator and debugger tool).
- An assembler for custom, user-defined instruction sets
-
A really good assembler/compiler
Even though technically not an emulators-related post, I'd like to share a tool I've recently learned came across and found to be really useful. It's called customasm and is open source. It can compile assembly of any kind as long as you feed it with (what's called) rules-definition. You can even write a higher level language profile (such as C, sort of) through it, the possibilities are countless, so to say.
-
Programming a breadboard computer via customasm
I've got the documentation in the wiki! https://github.com/hlorenzi/customasm/wiki/User-Guide
-
CUSTOMASM, using customasm is cool (made by hlorenzi). You write some code in assembly in a text editor, assemble, download to the breadboard computer and run it. Changing modifying or extending code goes superfast. Best programming tool sofar. Description of the code in the comment section.
Thanks to hlorenzi, making an assembler is a bunch of work. https://github.com/hlorenzi/customasm
-
Today I finished the RAM module for my 16-bit breadboard computer!
anyways, it might be a good idea to throw the entire project on Github once it's done. stuff like schematics, BOM, details about the function of the CPU, maybe an Assembler (CustomASM is pretty good), also maybe a simulator version in something like Digital or Logisim so that people can look at it, write programs, or rebuild it with different parts and such
-
I was wanting an assembler I can use with my breadboard CPU, but the only one that allowed custom ISAs is Windows only. So, I created my own assembler with Python for custom ISAs, and included a configuration file for the original instruction set of Ben Easter's SAP-1. Still a bit rough, but usable.
I used https://github.com/hlorenzi/customasm along with info from https://www.reddit.com/r/beneater/comments/cori8t/custom_asm_compiler_definition/