This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Fix DCE REG_LIBCALL note moving from noop move insns (PR rtl-optimization/33644)
On Fri, Oct 19, 2007 at 04:17:04PM +0200, Paolo Bonzini wrote:
> >So that would mean that you don't even need libcall notes to CSE
> >_tls_get_addr calls?
> CALL_INSNs are never DCE'd:
> static bool
> deletable_insn_p (rtx insn, bool fast)
> rtx body, x;
> int i;
> if (!NONJUMP_INSN_P (insn))
> return false;
Why is that? CONST_OR_PURE_CALL_P CALL_INSNs should be deletable...
Anyway, just tried (sorry for the delay) removing the libcall stuff, just
(call_insn/u 5 4 6 mm2.c:4 (parallel [
(set (reg:DI 0 ax)
(call:DI (mem:QI (symbol_ref:DI ("__tls_get_addr")) [0 S1 A8])
(const_int 0 [0x0])))
(const_int 0 [0x0])
]) -1 (nil)
(insn 6 5 7 mm2.c:4 (set (reg:DI 60)
(reg:DI 0 ax)) -1 (nil))
but CSE isn't able to merge these. Will still try to add REG_EQUAL note to
the pseudo = %rax insn if that helps.