public inbox for linux-8086@vger.kernel.org
 help / color / mirror / Atom feed
* Patch set to ease replacement of BCC compiler
@ 2015-05-21  5:47 Juan Perez-Sanchez
  2015-05-21  6:23 ` u-vpoa
  2015-05-21  6:27 ` u-vpoa
  0 siblings, 2 replies; 4+ messages in thread
From: Juan Perez-Sanchez @ 2015-05-21  5:47 UTC (permalink / raw)
  To: linux-8086

Hi,

I will send a set of 5 patches aimed to ease the transition
to other C compiler. The compilers considered are open-watcom
and ia16-unknown-elks-gcc.

This is not a port to use another compiler, BCC is still the
only compiler able to produce the kernel image. Even if a file
is compiled without errors, there are issues such as calling
function conventions, register usage and naming conventions
in assembly code that were not solved.

Now, the alternative compilers can compile all C files in the
source tree with only a few warnings, provided that inline
assembly is not used. The compilers detected several cases of
code that never executes, and deleting this code reduces code
size.

The largest roadblocks for using other compiler are the
assembly code and the inline assembly facility in BCC. I did
some changes aimed to have "only C" files and "only assembly"
files. The few files with mixed languages have C functions
without inline assembly or complete assembly functions. I also
did changes to eliminate some assembly code.

After the modifications, code size was reduced in 240 bytes,
data reduced in 16 bytes and bss increased in 4 bytes.

Patches should be applied in the correct order: starting with
elks-3t.patch and ending with elks-3x.patch

All kernel Images builded without errors using BCC. Every kernel
was tested with QEMU and PCE emulators. Also in a PPro pc
booting from floppy.

Greetings,

Juan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Patch set to ease replacement of BCC compiler
  2015-05-21  5:47 Patch set to ease replacement of BCC compiler Juan Perez-Sanchez
@ 2015-05-21  6:23 ` u-vpoa
  2015-05-21 14:13   ` Juan Perez-Sanchez
  2015-05-21  6:27 ` u-vpoa
  1 sibling, 1 reply; 4+ messages in thread
From: u-vpoa @ 2015-05-21  6:23 UTC (permalink / raw)
  To: Juan Perez-Sanchez; +Cc: linux-8086

On Thu, May 21, 2015 at 12:47:35AM -0500, Juan Perez-Sanchez wrote:
> I will send a set of 5 patches aimed to ease the transition
> to other C compiler.

Surely a useful step.

> The compilers considered are open-watcom
> and ia16-unknown-elks-gcc.

We should keep in mind that open-watcom has a minefield license.
One ought to be careful to not introduce any dependency on it.

Juan, wonder if you tried/considered Coherent C compiler?

Rl


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Patch set to ease replacement of BCC compiler
  2015-05-21  5:47 Patch set to ease replacement of BCC compiler Juan Perez-Sanchez
  2015-05-21  6:23 ` u-vpoa
@ 2015-05-21  6:27 ` u-vpoa
  1 sibling, 0 replies; 4+ messages in thread
From: u-vpoa @ 2015-05-21  6:27 UTC (permalink / raw)
  To: Juan Perez-Sanchez; +Cc: linux-8086

On Thu, May 21, 2015 at 12:47:35AM -0500, Juan Perez-Sanchez wrote:
> After the modifications, code size was reduced in 240 bytes,
> data reduced in 16 bytes and bss increased in 4 bytes.

> All kernel Images builded without errors using BCC. Every kernel
> was tested with QEMU and PCE emulators. Also in a PPro pc
> booting from floppy.

Good work!

Rl


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Patch set to ease replacement of BCC compiler
  2015-05-21  6:23 ` u-vpoa
@ 2015-05-21 14:13   ` Juan Perez-Sanchez
  0 siblings, 0 replies; 4+ messages in thread
From: Juan Perez-Sanchez @ 2015-05-21 14:13 UTC (permalink / raw)
  To: linux-8086

On Thu, May 21, 2015 at 1:23 AM,  <u-vpoa@aetey.se> wrote:
>
>> The compilers considered are open-watcom
>> and ia16-unknown-elks-gcc.
>
> We should keep in mind that open-watcom has a minefield license.
> One ought to be careful to not introduce any dependency on it.
>
> Juan, wonder if you tried/considered Coherent C compiler?
>
No, and the reason is that I don't have any idea of how much work is
needed to make it functional under linux.

Another candidate is TACK, many times proposed in this list. It would
be nice to have staticly linked binaries for linux available.

Juan

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-05-21 14:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-21  5:47 Patch set to ease replacement of BCC compiler Juan Perez-Sanchez
2015-05-21  6:23 ` u-vpoa
2015-05-21 14:13   ` Juan Perez-Sanchez
2015-05-21  6:27 ` u-vpoa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox