This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Question about UNSPEC rtx and a new instruction
- From: JCX <jcx721 at gmail dot com>
- To: gcc at gcc dot gnu dot org
- Date: Wed, 7 Jan 2009 14:15:37 +0800
- Subject: Question about UNSPEC rtx and a new instruction
Hello, I am working on a gcc porting for a new instruction. This
instruction needs to move data from memory to two registers. So I use
the SET rtx, and the dest of SET is an UNSPEC rtx with two registers.
By using such a rtl pattern, gcc performs very differently. It makes
mistakes for register replacement and instruction reordering.
For example, when gcc optimizes in pass_cse, it performs register
substitution of registers in UNSPEC rtx without checking the validity
of the resulting insn.
So I wonder about the UNSPEC rtx.
What's the usage of UNSPEC rtx?
And do you have a better rtl pattern for this new instruction?
Thanks,
Jacy