On Fri, Sep 28, 2012 at 5:21 PM, Vladimir Makarov <vmaka...@redhat.com> wrote: > On 12-09-28 4:21 AM, Steven Bosscher wrote: >> >> On Fri, Sep 28, 2012 at 12:56 AM, Vladimir Makarov <vmaka...@redhat.com> >> wrote: >>> >>> Any comments and proposals are appreciated. Even if GCC community >>> decides that it is too late to submit it to gcc4.8, the earlier reviews >>> are always useful. >> >> I would like to see some benchmark numbers, both for code quality and >> compile time impact for the most notorious compile time hog PRs for >> large routines where IRA performs poorly (e.g. PR54146, PR26854). >> >> > I should look at this, Steven. Unfortunately, the compiler @ trunk (without > my patch) crashes on PR54156: > > ../../../trunk2/slow.cc: In function ‘void check_() [with NT = CGAL::Gmpfi; > int s = 3]’: > ../../../trunk2/slow.cc:95489:6: internal compiler error: Segmentation fault > void check_(){ > ^ > 0x888adf crash_signal > /home/vmakarov/build1/trunk/gcc/gcc/toplev.c:335 > 0x8f4718 gimple_code > /home/vmakarov/build1/trunk/gcc/gcc/gimple.h:1126 > 0x8f4718 gimple_nop_p > /home/vmakarov/build1/trunk/gcc/gcc/gimple.h:4851 > 0x8f4718 walk_aliased_vdefs_1 > /home/vmakarov/build1/trunk/gcc/gcc/tree-ssa-alias.c:2204 > 0x8f50ed walk_aliased_vdefs(ao_ref_s*, tree_node*, bool (*)(ao_ref_s*, > tree_node*, void*), void*, bitmap_head_def**) > /home/vmakarov/build1/trunk/gcc/gcc/tree-ssa-alias.c:2240 > 0x9018b5 propagate_necessity > /home/vmakarov/build1/trunk/gcc/gcc/tree-ssa-dce.c:909 > 0x9027b3 perform_tree_ssa_dce > /home/vmakarov/build1/trunk/gcc/gcc/tree-ssa-dce.c:1584 > Please submit a full bug report, > with preprocessed source if appropriate. > Please include the complete backtrace with any bug report. > See <http://gcc.gnu.org/bugs.html> for instructions.
Works for me on gcc17 at r191835, with a gcc configured like so: "../trunk/configure --with-mpfr=/opt/cfarm/mpfr-latest --with-gmp=/opt/cfarm/gmp-latest --with-mpc=/opt/cfarm/mpc-latest --with-isl=/opt/cfarm/isl-latest --with-cloog=/opt/cfarm/cloog-latest --enable-languages=c,c++ --disable-bootstrap --enable-checking=release --with-gnu-as --with-gnu-ld --with-as=/opt/cfarm/binutils-latest/bin/as --with-ld=/opt/cfarm/binutils-latest/bin/ld" Top 10 time consumers: integrated_RA 191.66 df_live&initialized_regs 73.43 df_live_regs 72.25 out_of_ssa 45.21 tree_PTA 35.44 tree_SSA_incremental 26.53 remove_unused_locals 18.78 combiner 16.54 dominance_computation 14.44 register_information 14.20 TOTAL : 732.10 Note I'm using the simplified test case, see comment #14 in the PR. You can just take the original test case (http://gcc.gnu.org/bugzilla/attachment.cgi?id=27912) and apply this patch: --- slow.cc.orig 2012-09-28 21:07:58.000000000 +0200 +++ slow.cc 2012-09-28 21:08:38.000000000 +0200 @@ -95503,6 +95503,7 @@ check_<NT,Eigen::Dynamic>(); } int main(){ +#if 0 { typedef CGAL::Interval_nt<true> I1; I1::Protector p1; @@ -95517,11 +95518,14 @@ check<CGAL::Gmpz>(); check<CGAL::Gmpq>(); check<CGAL::Gmpfr>(); +#endif check<CGAL::Gmpfi>(); +#if 0 check<CGAL::Quotient<CGAL::Gmpz> >(); check<CGAL::Lazy_exact_nt<CGAL::Gmpq> >(); check<CORE::BigInt>(); check<CORE::BigRat>(); check<CORE::BigFloat>(); check<CORE::Expr>(); +#endif } You can compile the test case with: "./xgcc -B. -S -std=gnu++11 -O1 -frounding-math -ftime-report slow.cc" Even with this path, the test case really is a great scalability challange for the compiler :-) I never got the full test case to work at -O1, and the simpler test case still blows up the compiler at -O2 and higher. At -O1 you need a machine with at least 8GB of memory. More than half of that is for IRA+reload... Ciao! Steven