Hi, I'm a guy working with gcc4.1.1 on itanium2. In my work, some instrumentations are added by gcc. After instrumentation, all specint2000 benchmarks except gzip can successfully run with optimization flag -O3. There are some information list below:
1. Gzip can successfully run when compile with -O1(-O2 and -O3 failed). 2. When add code "while(1)" in an unreachable place in function "huft_build", gzip can successfully run. 3. Our instrumentation add two new instruction supports to gcc, which are tnat and single predicate compare: Machine description file =========================================================================================== (define_insn "shift_predicate_cmp" [(set (match_operand:BI 0 "register_operand" "=c") (and:BI (and:BI (const_int 1) (ne:BI (match_operand:DI 1 "gr_reg_or_8bit_adjusted_operand" "rL") (match_operand:DI 2 "gr_register_operand" "r"))) (const_int 1)))] "" "cmp.ne %0, p0 = %1, %2" [(set_attr "itanium_class" "icmp")]) (define_insn "shift_tnat" [(set (match_operand:BI 0 "register_operand" "=c") (unspec:BI [(match_operand:DI 1 "gr_register_operand" "r")] UNSPEC_TNAT))] "" "tnat.nz %0, p0 = %1" [(set_attr "itanium_class" "tbit")]) ============================================================================================ 4. Impossible to compare compiled .s files(the one with "while(1)" vs. the one without) since instruction scheduling make it completely different. My question are: 1. Whether this implementation could possibly make gcc's scheduling go wrong? 2. Is there any good way to debug such problems? Any help are appreciated, thanks very much.