Re: New GCC compiler for 8086 cpu's

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Juan,

Thanks for the link!  Some questions below:

On Fri, Jun 16, 2017 at 8:23 AM, Juan Perez-Sanchez <lithoxs@xxxxxxxxx> wrote:
> On Thu, Jun 15, 2017 at 5:19 AM, Edoardo <eddyx89@xxxxxxxxx> wrote:
>> If I remember correctly, one of ELKS limits was that binaries had to
>> fit on a 64KB page, and that was due to the compiler we used (dev86 /
>> bcc).
>
> Actually, code size <=  64KB and separately  (data + bss + stack sizes) <= 64KB.
>
>> Do you think/know if GCC may solve this limit, being able to produce
>> multi-page binaries?
>
> No, those limits still holds.

I guess there are both limits in the compiler and limits in ELKS itself, right?

Alan kindly explained to me in the last few days in the thread
http://www.spinics.net/lists/linux-8086/msg00813.html what kind of
complex things ELKS would need to do to handle processes with multiple
code segments and/or multiple data segments, and those restrictions
are still there, so simply using GCC doesn't make them go away.

The "Getting Started Guide" for this new IA16 GCC actually mentions a
few limitations in this area that the new compiler has:

- Section 3.2 says "Although this version of Sourcery CodeBench Lite
uses ELF as its internal object format, it produces executables in DOS
COM format."  DOS .COM format implies a single 64KB segment for
combined code and data, i.e. tiny memory model, right?  That's more
restrictive than ELKS.

- Section 3.3 says "Far pointers currently do not work, so accessing
memory outside the program's 64kB segment requires the use of assembly
(either inline or a separate file that is assembled and then linked
into the program).", so it's not going to let you make bigger
executables even if ELKS added such support.  For what it's worth
you'd find far pointer support in OpenWatcom.

I see that ia16-elf/lib/dos-com.ld seems to have some instructions
related to making a DOS .COM file.  I've never played with GCC linker
scripts before, but I assume there's nothing in the compiler that
would prevent it from generating a full 64KB code segment and also a
full 64KB data segment, and one could make a linker script for
generating an ELKS executable with those two separate segments instead
of being limited to it all being in one segment like with a .COM file?

Apologies in advance if I'm spreading any misinformation here!

Thanks,
David
--
To unsubscribe from this list: send the line "unsubscribe linux-8086" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel]     [Linux ia64]     [DCCP]     [Linux for ARM]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux