News for hackers. Stuff that matters.
Re:(Debugging Story) Inline Assembly Dangers by dist1ll on Monday June 10, 2024 @05:32AM (#40631719)
Writing inline assembly in most languages is a pain. I think there's some real opportunity to make things more ergonomic. Basically taking the idea of HLASM and other high-level assembler projects, but actually bringing them into the modern era of languages and tooling.

I would like to see a kind of "seamless" assembly feature, where asm instructions and ISA-specific registers could be made first-class objects (intrinsics are a weak version of this). Register-sized objects (like most numeric primitives, pointers, etc.) should seamlessly decay to the register in which they reside.

Also, tooling and LSPs could be improved. Wouldn't it be nice if I can text-select a section of asm and the LSP shows me latency/throughput of the block on my desired target platform? Or maybe it does some proper static analysis like noticing dead writes, or maybe a refactoring action that expands a slow div into a more optimal instruction sequence.

There are no comments on this comment yet.