http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57370
Bug ID: 57370 Summary: [4.9 Regression] compile time hog in reassoc Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: middle-end Assignee: unassigned at gcc dot gnu.org Reporter: Joost.VandeVondele at mat dot ethz.ch Between rev 199047 and 199075 the attached testcase started using an excessive amount of time (up from about 4s with 4.7.2). The important option seems to be -ffast-math (16s without this option). Reproduce with: time gfortran -c -g -O2 -ffast-math bug.f90 The stack looks like: #0 0x0000000000af4b79 in reassociate_bb(basic_block_def*) () #1 0x0000000000af4ae8 in reassociate_bb(basic_block_def*) () #2 0x0000000000af4ae8 in reassociate_bb(basic_block_def*) () #3 0x0000000000af4ae8 in reassociate_bb(basic_block_def*) () #4 0x0000000000af4ae8 in reassociate_bb(basic_block_def*) () #5 0x0000000000af6701 in execute_reassoc() () #6 0x0000000000906550 in execute_one_pass(opt_pass*) ()