All of lore.kernel.org
 help / color / mirror / Atom feed
* Re : Re : Re : Re : [PATCH] Compressed ia32 ELF file generation for loading by Gujin 1/3
@ 2007-02-06 22:19 Etienne Lorrain
  2007-02-07  0:59 ` H. Peter Anvin
  0 siblings, 1 reply; 3+ messages in thread
From: Etienne Lorrain @ 2007-02-06 22:19 UTC (permalink / raw)
  To: H. Peter Anvin, Eric W. Biederman; +Cc: vgoyal, linux-kernel

H. Peter Anvin wrote:
> I've long wished that someone would do a proper 16-bit x86 port of gcc; 

> however, the .code16gcc is usually good enough, although it produces 
> code which is a lot bigger than it needs to be.

  It is only that much bigger if you compare to 16 bits integer compilers,

 but once you deal with 32 bits integers in real mode you have one extra byte

 out of the two - which is still better than dealing with dx:ax.

 Last time I compiled (long time ago) some piece of code with and without

 .code16gcc it was approx 15% bigger - approx what you get when optimising.


 Etienne.




	

	
		
___________________________________________________________________________ 
Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! 
Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses 
http://fr.answers.yahoo.com

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

* Re: Re : Re : Re : Re : [PATCH] Compressed ia32 ELF file generation for loading by Gujin 1/3
  2007-02-06 22:19 Re : Re : Re : Re : [PATCH] Compressed ia32 ELF file generation for loading by Gujin 1/3 Etienne Lorrain
@ 2007-02-07  0:59 ` H. Peter Anvin
  2007-02-07  2:48   ` Eric W. Biederman
  0 siblings, 1 reply; 3+ messages in thread
From: H. Peter Anvin @ 2007-02-07  0:59 UTC (permalink / raw)
  To: Etienne Lorrain; +Cc: Eric W. Biederman, vgoyal, linux-kernel

Etienne Lorrain wrote:
> H. Peter Anvin wrote:
>> I've long wished that someone would do a proper 16-bit x86 port of gcc; 
> 
>> however, the .code16gcc is usually good enough, although it produces 
>> code which is a lot bigger than it needs to be.
> 
>   It is only that much bigger if you compare to 16 bits integer compilers,
>  but once you deal with 32 bits integers in real mode you have one extra byte
>  out of the two - which is still better than dealing with dx:ax.
> 
>  Last time I compiled (long time ago) some piece of code with and without
>  .code16gcc it was approx 15% bigger - approx what you get when optimising.
> 

That's not a valid comparison, because you're using 32-bit registers to 
hold 16-bit pointers, and then sticking 67 prefixes on completely 
unnecessarily.

	-hpa

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

* Re: Re : Re : Re : Re : [PATCH] Compressed ia32 ELF file generation for loading by Gujin 1/3
  2007-02-07  0:59 ` H. Peter Anvin
@ 2007-02-07  2:48   ` Eric W. Biederman
  0 siblings, 0 replies; 3+ messages in thread
From: Eric W. Biederman @ 2007-02-07  2:48 UTC (permalink / raw)
  To: H. Peter Anvin; +Cc: Etienne Lorrain, vgoyal, linux-kernel

"H. Peter Anvin" <hpa@zytor.com> writes:

> Etienne Lorrain wrote:
>> H. Peter Anvin wrote:
>>> I've long wished that someone would do a proper 16-bit x86 port of gcc;
>>
>>> however, the .code16gcc is usually good enough, although it produces code
>>> which is a lot bigger than it needs to be.
>>
>>   It is only that much bigger if you compare to 16 bits integer compilers,
>>  but once you deal with 32 bits integers in real mode you have one extra byte
>>  out of the two - which is still better than dealing with dx:ax.
>>
>>  Last time I compiled (long time ago) some piece of code with and without
>>  .code16gcc it was approx 15% bigger - approx what you get when optimising.
>>
>
> That's not a valid comparison, because you're using 32-bit registers to hold
> 16-bit pointers, and then sticking 67 prefixes on completely unnecessarily.

Regardless if the size is good enough we can use it :)

For romcc I had a 3x code bloat over had crafted assembler, because I
had no memory and had to inline every single function call because I
didn't have someplace to put a return register.  So I have the
scenario with the most code bloat.  I win!

Eric

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

end of thread, other threads:[~2007-02-07  2:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-06 22:19 Re : Re : Re : Re : [PATCH] Compressed ia32 ELF file generation for loading by Gujin 1/3 Etienne Lorrain
2007-02-07  0:59 ` H. Peter Anvin
2007-02-07  2:48   ` Eric W. Biederman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.