C
C#15mo ago
surwren

❔ WebASM and c#

So I'm considering an emscripten compiled learning project. I know that C# doesn't support inline assembly. Am wondering how one could manually optimize the asm output outputted from c#?
6 Replies
Thinker
Thinker15mo ago
Are you talking about the native binary produced by the JIT or about IL?
Chiyoko_S
Chiyoko_S15mo ago
You don't directly manipulate the asm generated by C#, you can't you can read the outputted asm and see where there's inefficient asm generated, and then work around the said inefficiency by writing the code in some different ways (ideally also report the said inefficiency to the runtime team) though I guess it depends on exactly what kind of 'asm' you're talking about since you mentioned emscripten I guess you mean wasm?
Thinker
Thinker15mo ago
There are also attributes and tricks which can manipulate how the JIT outputs ASM However that's a question better suited for #allow-unsafe-blocks
surwren
surwren15mo ago
Yes correct What is that channel for specifically?
Thinker
Thinker15mo ago
It's mainly about low-level optimization and the inner-workings of the runtime Sounded adjacent to what you were asking, but I don't know anything about WASM
Accord
Accord15mo ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.