binary size compared to GCC

  • Follow


Why are the binaries produced by lccwin32 so much smaller 
than those produced by GCC (mingw32)?!

The lccwin32 binary is almost 40% smaller in my concrete case. 
I do use the same settings in both cases i.e. no debug info and 
optimizer turned on. In fact, for GCC I use the -Os (optimize for 
small size) optimizer flag...

The only explanation I can think of is that lccwin32 features whole
program redundant literal elemination. That would decrease the
size of my program a lot but mingw cannot do that yet.

Any idea what could cause this massive difference?

0
Reply copx 1/11/2011 1:01:19 PM

Le 11/01/11 14:01, copx a �crit :
> Why are the binaries produced by lccwin32 so much smaller than those
> produced by GCC (mingw32)?!
>
> The lccwin32 binary is almost 40% smaller in my concrete case. I do use
> the same settings in both cases i.e. no debug info and optimizer turned
> on. In fact, for GCC I use the -Os (optimize for small size) optimizer
> flag...
>
> The only explanation I can think of is that lccwin32 features whole
> program redundant literal elemination. That would decrease the
> size of my program a lot but mingw cannot do that yet.
>
> Any idea what could cause this massive difference?
>

lccwin32 starts with the optimization principle:

No instruction executes faster than a deleted instruction.

Smaller code leads to faster load time into the processor caches,
more locality and hence faster execution.

That is why I have stressed in the compiler development code size
as the most important criteria for optimization.


0
Reply jacob 1/11/2011 2:09:49 PM



"jacob navia"  wrote in message news:ighobb$uhd$1@speranza.aioe.org... 
>lccwin32 starts with the optimization principle:
>
>No instruction executes faster than a deleted instruction.
>
>Smaller code leads to faster load time into the processor caches,
>more locality and hence faster execution.
>
>That is why I have stressed in the compiler development code size
>as the most important criteria for optimization.

Ah, I see. Thank you.


0
Reply copx 1/11/2011 3:49:58 PM

2 Replies
258 Views

(page loaded in 0.098 seconds)

Similiar Articles:













7/30/2012 12:13:33 AM


Reply: