This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Add TST to RX


DJ Delorie wrote:
This patch adds support for the TST opcode to the RX target.  The
first two patterns are the real patterns; the rest are other ways that
gcc handles "a & const", they're converted to one of the first two
forms.  Paolo: if you replace the "return 0;" in the rtlanal.c chunk
with an abort(), you can see where the zero_extend comes from.  GCC
uses that for single-bit tests other than bit 0.

Ok to apply?

	* rtlanal.c (canonicalize_condition): Exit early if we're passed
	something other than a condition.

	* config/rx/predicates.md (rx_constshift_operand): New.
	(rx_onebit_operand): New.
	* config/rx/rx.md (zs_cond): New.
	(*tstbranchsi4_<code>): New.
	(*tstbranchsi4_<code>): New.
	(*tstbranchsi4b_eq): New.
	(*tstbranchsi4m_eq): New.
	(*tstbranchsi4m_ne): New.
	(*tstbranchsi4a_ne): New.
	(*tstbranchsi4a_eq): New.
This patch causes the following testsuite failure.

FAIL: gcc.c-torture/compile/pr32482.c -O1 (internal compiler error)

FAIL: gcc.c-torture/unsorted/shft.c, -O1 (internal compiler error)
FAIL: gcc.c-torture/unsorted/shft.c, -O2 (internal compiler error)
FAIL: gcc.c-torture/unsorted/shft.c, -O3 -fomit-frame-pointer
(internal compiler error)
FAIL: gcc.c-torture/unsorted/shft.c, -O3 -g (internal compiler error)
FAIL: gcc.c-torture/unsorted/shft.c, -Os (internal compiler error)

rx-elf-gcc -S -O1 pr32482.c
pr32482.c: In function 'drain_cpu_caches':
pr32482.c:23:1: internal compiler error: in reverse_condition, at jump.c:477
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

rx-elf-gcc -S -O3 shft.c
shft.c: In function 'foo':
shft.c:9:1: internal compiler error: in swap_condition, at jump.c:566
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

Regards,
Kazuhiro Inaoka


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]