On 06/05/2014 09:47 AM, Kai Tietz wrote:
> +(define_insn "*sibcall_intern"
> + [(call (unspec [(mem:QI (match_operand:W 0 "memory_operand"))]
Probably best to use memory_nox32_operand here (and the other define_insn
patterns) too.
Otherwise ok.
r~
Thanks for all your hints. Here is the updated patch
ChangeLog testsuite
2014-06-05 Kai Tietz
PR target/46219
* gcc.target/i386/sibcall-4.c: Remove xfail.
ChangeLog
2014-06-05 Kai Tietz
Richard Henderson
PR target/46219
* config/i386/predicates.md (memory_nox32
On 06/04/2014 05:37 AM, Kai Tietz wrote:
> +(define_peephole2
> + [(set (match_operand:DI 0 "register_operand")
> +(match_operand:DI 1 "memory_operand"))
> + (call (mem:QI (match_operand:DI 2 "register_operand"))
> + (match_operand 3))]
> + "TARGET_64BIT && REG_P (operands[0])
So after SIBLING_CALL_P flags gets now preserved in peep2_attempt, the
patch simplifies.
Regression tested for x86_64-unknown-linux-gnu, and i686-pc-cygwin.
Ok for apply (with ChangeLog plus testcase adjustment as done by
initial patch)?
Index: config/i386/i386.md
On 06/03/2014 01:15 PM, Kai Tietz wrote:
> - Original Message -
>> On 06/03/2014 12:56 PM, Kai Tietz wrote:
>>> +(define_insn "*sibcall_intern"
>>> + [(call (unspec [(mem:QI (match_operand:W 0 "memory_operand"))]
>>> UNSPEC_PEEPSIB)
>>> +(match_operand 1))]
>>> + ""
>>> + "* SIBLING_
- Original Message -
> On 06/03/2014 12:56 PM, Kai Tietz wrote:
> > +(define_insn "*sibcall_intern"
> > + [(call (unspec [(mem:QI (match_operand:W 0 "memory_operand"))]
> > UNSPEC_PEEPSIB)
> > +(match_operand 1))]
> > + ""
> > + "* SIBLING_CALL_P (insn) = 1; return ix86_output_call_i
On 06/03/2014 12:56 PM, Kai Tietz wrote:
> +(define_insn "*sibcall_intern"
> + [(call (unspec [(mem:QI (match_operand:W 0 "memory_operand"))]
> UNSPEC_PEEPSIB)
> + (match_operand 1))]
> + ""
> + "* SIBLING_CALL_P (insn) = 1; return ix86_output_call_insn (insn,
> operands[0]);"
> + [(set_
Hello,
This patch fixes PR/46219 by introducing special peephole-optimization. As we
can't set for new statement in peephole2-define SIBLING_CALL_P easily, I use
UNSPEC_PEEPSIB to do indentify sibling tail-call-case.
For avoiding modification of ix86_output_call_insn, I set SIBLING_CALL_P
dir