[ros-dev] MASM using longer opcode sequences than GAS
David Quintana (gigaherz)
gigaherz at gmail.com
Tue Jan 17 09:38:28 UTC 2017
No idea about the encoding length, but I wonder why we don't just use NASM
everywhere, instead of having two separate assemblers.
On 17 January 2017 at 10:23, Colin Finck <colin at reactos.org> wrote:
> Hi all,
>
> In order to make our ISOs flashable to USB drives and bootable from them
> (cf. CORE-12648), I'm currently overhauling our ISO boot sector
> "isoboot.S". This adds a lot of code and while I stay in the 2K size
> limit when assembling it with GAS, I break it with MASM.
>
> Disassembling the assembled files shows the difference.
> A line like:
>
> mov word ptr ds:[GetlinsecPtr], ax
>
> is assembled by GAS to:
>
> A35B50 mov [0x505b],ax
>
> while MASM does this:
>
> 67A35B500000 mov [dword 0x505b],ax
>
>
> Is there any option to enforce the shorter opcode sequence for MASM too?
> The code uses a lot of similar MOVs and this seems to be the only reason
> why I break the 2K size limit with MASM.
>
> If there is no such option, what are the advantages of using MASM for
> our MSVC build anyway? Can't we just use GAS for both or decide on a
> common third-party assembler (NASM) for our assembly files?
>
>
> Cheers,
>
> Colin
>
> _______________________________________________
> Ros-dev mailing list
> Ros-dev at reactos.org
> http://www.reactos.org/mailman/listinfo/ros-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.reactos.org/pipermail/ros-dev/attachments/20170117/5d946df0/attachment.html>
More information about the Ros-dev
mailing list