[PLUTO-help] Aiuto! Errore di compilazione durante installazione	gentoo
    Gian Uberto Lauri 
    GianUberto.Lauri a eng.it
       
    Ven  5 Nov 2004 14:48:09 CET
    
    
  
>>>>> "AR" == Alessandro R <alexerre a yahoo.it> writes:
AR> On Fri, Nov 05, 2004 at 09:15:46AM +0100, Stefano Vedovelli wrote:
>> Comunque, io personalmente sono sempre partito dagli stage 3, dato che
>> considero la vera forza di Gentoo non tanto nell'ottimizzazione, ma
>> nell'aggiornabilità del sistema.
AR> Concordo anche io con questo. A meno che tu nn abbia una macchina
AR> veramente veloce.
Io invece non concordo. La forza di Gentoo non e` nell'aggiornabilita`
che  non  credo  sia  poi  tanto  migliore di  quella  di  Debian,  ma
nell'avere i programmi ricompilati  per la tua architettura invece che
per  un generico  386. Gia`  solo  a sapere  che il  processore e`  un
Pentium il  GCC sa fare  dei riordini delle istruzioni  che accelerano
l'esecuzione.
Tornando al discorso iniziale  dell'ottimizzazione e del fatto che -O3
possa inserire  problemi ecco cosa dice la  documentazione (almeno per
la 2.95, dovreste controllare i file info se ne avete un'altra):
`-O'
`-O1'
     Optimize.  Optimizing compilation takes somewhat more time, and a
     lot more memory for a large function.
     Without `-O', the compiler's goal is to reduce the cost of
     compilation and to make debugging produce the expected results.
     Statements are independent: if you stop the program with a
     breakpoint between statements, you can then assign a new value to
     any variable or change the program counter to any other statement
     in the function and get exactly the results you would expect from
     the source code.
     Without `-O', the compiler only allocates variables declared
     `register' in registers.  The resulting compiled code is a little
     worse than produced by PCC without `-O'.
     With `-O', the compiler tries to reduce code size and execution
     time.
     When you specify `-O', the compiler turns on `-fthread-jumps' and
     `-fdefer-pop' on all machines.  The compiler turns on
     `-fdelayed-branch' on machines that have delay slots, and
     `-fomit-frame-pointer' on machines that can support debugging even
     without a frame pointer.  On some machines the compiler also turns
     on other flags.
`-O2'
     Optimize even more.  GCC performs nearly all supported
     optimizations that do not involve a space-speed tradeoff.  The
     compiler does not perform loop unrolling or function inlining when
     you specify `-O2'.  As compared to `-O', this option increases
     both compilation time and the performance of the generated code.
     `-O2' turns on all optional optimizations except for loop
     unrolling, function inlining, and strict aliasing optimizations.
     It also turns on the `-fforce-mem' option on all machines and
     frame pointer elimination on machines where doing so does not
     interfere with debugging.
`-O3'
     Optimize yet more.  `-O3' turns on all optimizations specified by
     `-O2' and also turns on the `inline-functions' option.
Maggiori dettagli su cosa sono  le -f(opzione) si trovano nella stessa
pagina info ([manuale GCC]-> Invoking GCC -> Optimize Options) in modo
da capire cosa viene combinato al vostro codice.
Utile anche una lettura di [manuale GCC]->Passes.
Attenzione, se avete una ultimissima versione-sperimentale-bloody edge
con feature nuove di pallino  e` possibile che queste ultime non siano
perfette, ma -O3 la vedo in giro da alcuni anni e nella mia esperienza
-O2 e`  sicura da anni  per codice in  user space (per il  kernel puo`
essere  un'altro discorso)  e non  mi pare  che introduca  problemi di
thread safety nuovi  rispetto a quelli che gia`  ci possono essere nel
codice.
-- 
 /\            ___
/___/\__|_|\_|__|___Gian Uberto Lauri_____________________
  //--\ | | \|  |   Integralista GNUslamico e fancazzista 
\/
    
    
More information about the pluto-help
mailing list