|
|
Subscribe / Log in / New account

GCC IA16 backend

GCC IA16 backend

Posted Oct 9, 2017 21:25 UTC (Mon) by felix.s (guest, #104710)
In reply to: GCC IA16 backend by mjthayer
Parent article: Videos from the GNU Tools Cauldron

Thanks. This is actually just the build system, but from there I found a link to their GCC repo and the binutils repo. The far pointers part is there. Props to them: I've attempted writing that myself once, but only managed to generate a few ICEs. Still a pity it's not part of the regular i386 target.

The binutils repository doesn't seem to contain any EXE support (beyond the comically incomplete 'i386msdos' target that by some miracle made its way upstream long, long ago); it looks like it just contains Bernd Jendrissek's OMF patch from 2011, which only adds objdump support and is quite buggy even for that purpose. Which I happen to know because some time ago I did some work updating and extending that very patch. What a shame I've got it all on a disk I cannot access right now.


to post comments

GCC IA16 backend

Posted Nov 4, 2017 4:07 UTC (Sat) by tkchia (guest, #119442) [Link]

Hello all,

I am the coder behind the far pointer support for IA-16 GCC. Thank you very much for your comments!

Regarding .exe support, my fork of gcc-ia16 does have it, but it can only create "small" memory model .exe files, i.e. with 64 KiB code + 64 KiB separate data in total. Passing -mcmodel=small to my GCC front-end should enable the .exe support (the default is -mcmodel=tiny).

As for the actual implementation of .exe output: it is not in the binutils component, but actually in the newlib part (!). I use a linker script to fabricate the .exe header and lay out the code and data correctly.

--- T. K. Chia


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds