This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Question on fixup_abnormal_edges
First, I confirm the insn is indeed emitted after the call by way of
save_call_clobbered_regs. A great hint you gave :)
Jan Hubicka wrote:
> There is another problem when I think about that - there should not be
> live register accross REG_NORETURN note and thus no caller save need.
> Do you have any idea why the register is alive?
Not quite sure yet, but maybe the following will ring a bell to you:
The .life dump reads several times like below
(call_insn 1707 1706 1708 (parallel[
(call (mem:DI (symbol_ref:DI ("_Unwind_Resume")) [0 S8 A64])
(const_int 1 [0x1]))
(use (const_int 0 [0x0]))
(use (reg:DI 25 $25))
(use (reg:DI 26 $26))
(clobber (reg:DI 27 $27))
] ) 211 {*call_vms_1} [..]
(expr_list:REG_DEAD (reg:DI 16 $16)
(expr_list:REG_DEAD (reg:DI 26 $26)
(expr_list:REG_DEAD (reg:DI 25 $25)
(expr_list:REG_UNUSED (reg:DI 27 $27)
(expr_list:REG_NORETURN (const_int 0 [0x0]) <=====
(nil))))))
(expr_list (use (reg:DI 16 $16))
(nil)))
;; End of basic block 175, registers live:
29 [$29] 30 [$30] 31 [AP] 63 [FP]
The set of registers live after NORETURN calls is always the same, and
alpha.h reads:
$29 (global pointer)
$30, $31, $f31 (stack pointer and always zero/ap & fp) */