This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more infromation.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: size of code gcc creates (was "m68k-coff-gcc and NOPs")


Chris,
	The command line options are applied to the build of the project and
the libraries but not to the build of the compiler (unless you want to make
the compiler shorter, and possible slower).

	I am not sure exactly how the libraries were rebuilt as a colleague
did it and he is not in today. I might be able to find out next week.

Regards, Chris

> -----Original Message-----
> From: Christopher Bahns [mailto:chris@bahns.com]
> Sent: 10 August 2000 19:09
> To: PalmerC@intgame.com; sasumner@juno.com;
> crossgcc@sourceware.cygnus.com
> Subject: RE: size of code gcc creates (was "m68k-coff-gcc and NOPs")
> 
> 
> Hello Chris (and Scott),
> 
> Regarding a CrossGCC post you made back in January, I too have to deal
> with size increases going from MRI to GNU. In my case the MRI build is
> about 94k (of 96k available) and the GNU build is about 107k, which is
> over the limit on my flash. If I can just get it close then I can look
> into other methods to reduce it further, but at the moment 
> that would be
> hopeless.
> 
> Here is your post:
> __________________________________________________________________
> Scott,
>         I too have been comparing code size with Microtec's 
> compiler. I
> found the following options useful in reducing it: -Os
> -fomit-frame-pointer
> -fno-force-mem. The results are then comparable to Microtec's.
> 
>         I also noticed that the run time library was much bigger. On
> investigation I found all the string functions had an option to do the
> operations one long word at a time. This makes the code much 
> longer on a
> 68K
> cpu, and also slower. In some cases it also fails to work! Recompiling
> with
> the PREFER_SIZE_OVER_SPEED macro defined, produces more traditional
> implementations which are much smaller.
> 
> Chris
> __________________________________________________________________
> 
> Do you recommend applying the -Os, -fomit-frame-pointer, and
> -fno-force-mem when building the project, the compiler or both (I'm
> already applying the first two when building my program, but none of
> them when building the compiler (at least not that I know of -- just
> using the default options that configure.sh generates)? If applying to
> the build of the compiler, exactly how do I do this (see next
> paragraph)?
> 
> I have looked into applying -DPREFER_SIZE_OVER_SPEED but it 
> did not seem
> clear exactly how to do this, and what I did try caused the 
> build of the
> compiler to fail. Can you tell EXACTLY how to add this 
> define? Naturally
> I'd prefer to specify it on the make (or configure) command 
> line, since
> editing the make files directly after configuration gets a 
> bit messy and
> makes the automation of the build process a bit more difficult.
> 
> Thanks a lot for any help.
> Chris
> 

------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]