assembler: Optimize mov rAX,[int32-offset]
(64-bit mode)
#269
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
It's currently always using
mov rAX,[moffs]
but if it fits in ani32
, it's shorter to usemov rAX,[m]
with a modrm byte.The generated
mov()
methods would need to be updated. This is what the generated C# code looks like:An extra check would need to be added to the first line to check if the displacement fits in an
Int32
, and if so, don't usemov rax,[moffs]
.iced/src/csharp/Intel/Generator/Assembler/CSharp/CSharpAssemblerSyntaxGenerator.cs
Lines 938 to 941 in a49d0e6
iced/src/csharp/Intel/Generator/Assembler/Rust/RustAssemblerSyntaxGenerator.cs
Lines 887 to 890 in a49d0e6
The text was updated successfully, but these errors were encountered: