This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: -fwhopr and -flto options reorg


On 10-11-11 13:01 , Jan Hubicka wrote:

   compile many smaller scale programs since the functions and variables become
   local for the whole combined compilation unit, not for the single source file
   itself.

This option implies @option{-fwhole-file} for Fortran programs.

! @item -flto[=@var{n}]
   @opindex flto
   This option runs the standard link-time optimizer.  When invoked
   with source code, it generates GIMPLE (one of GCC's internal

This should document what the valid values of @var{n} are.


   extern int flag_dump_rtl_in_asm;
+
+ /* WHOPR mode.  */
+ extern bool flag_whopr;

Why do we need this? Isn't everything we need to know encoded in flag_lto_partition?



***************
*** 1,5 ****
   /* { dg-do compile } */
! /* { dg-options "-fwhopr" { target lto } }  */

   typedef struct foo_ foo_t;
   foo_t bar;  /* { dg-error "storage size of 'bar' isn't known" }  */
--- 1,5 ----
   /* { dg-do compile } */
! /* { dg-options "-flto" { target lto } }  */

I don't think it matters much, but this test was originally for whopr mode. Add -flto-partition=1to1 here?



--- 1218,1224 ----
         opts->x_flag_ipa_struct_reorg = 0;
       }

! if (flag_whopr || opts->x_flag_lto)

So here, flag_whopr would be 'flag_lto_partition == none'


+ freorder-functions
+ Common Report Var(flag_ipa_reorder) Init(1) Optimization
+ Reroder functions for better locality at execution time
+


Unrelated change?


Diego.



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