News for hackers. Stuff that matters.
Re:Snowman native code to C/C++ decompiler for x86/x86_64/ARM by kalnins on Friday April 22, 2022 @09:59AM (#31121617)
As Rust is llvm based, you don't need to compile it to C. Just write a backend that translates LLVM IR to C instead of x86_64. The IR is very C looking, it's probably overly complex.

Compiling down to asm, lot of information is lost regarding memory layout etc, so it's not the best source for generating code.

Re:Snowman native code to C/C++ decompiler for x86/x86_64/ARM by my123 on Friday April 22, 2022 @11:14AM (#31122618)
https://github.com/JuliaComputingOSS/llvm-cbe

edit: you also have mrustc as a Rust to C compiler outright.

Re:Snowman native code to C/C++ decompiler for x86/x86_64/ARM by frabert on Friday April 22, 2022 @12:25PM (#31123758)
Hey, LLVM to C is what Rellic does! https://github.com/lifting-bits/rellic