Internal compiler error with -O2 and optimize(O0)

2013-06-10 Thread Aleksandr Platonov
Hi,
-O2 command line option and optimize(O0) (#pragma GCC optimize (O0)
or __attribute__((optimize(O0 sometimes leads to internal compiler
error with trace:
 internal compiler error: in parm_ref_data_preserved_p, at
ipa-prop.c:740
 }
 ^
0x898982b ipcp_generate_summary
/home/pam/tmp/gcc_source/gcc/ipa-cp.c:3640
0x84d5d13 execute_ipa_summary_passes(ipa_opt_pass_d*)
/home/pam/tmp/gcc_source/gcc/passes.c:2136
0x825bef4 ipa_passes
/home/pam/tmp/gcc_source/gcc/cgraphunit.c:1846
0x825bef4 compile()
/home/pam/tmp/gcc_source/gcc/cgraphunit.c:1952
0x825cf39 finalize_compilation_unit()
/home/pam/tmp/gcc_source/gcc/cgraphunit.c:2106
0x810addb c_write_global_declarations()
/home/pam/tmp/gcc_source/gcc/c/c-decl.c:10118

There is a bug about problem with example code to reproduce
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57358 comment #2) but no
responses there. Could anybody take a look at this? This problem appears
in 4.8.0 version and  still observed in latest gcc sources (4.9.0
20130610 (experimental))

-- 
Aleksandr Platonov



Debug info for function with variable number of arguments is incorrect (rs6000)

2012-12-27 Thread Aleksandr Platonov
Hi.
Debug information for function with variable number of arguments is
incorrect on PowerPC (rs6000). I created bug for this problem
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55586) but got no response.
I have tried different versions of GCC and this problem observed in all
of them.

GCC generates two elements in .debug_line section for the first function
line (function header) and the second element is for address right after
the branch instruction.
If I remove bne instruction generation from setup_incoming_varargs()
function (gcc/config/rs6000/rs6000.c) then there will be only
one .debug_line element for the first function line.
Is it excepted behavior that bne instruction leads to split
of .debug_line section element?

Could anybody help me to find GCC version where debug info for function
with variable number of arguments is correct on PowerPC?

-- 
Aleksandr Platonov