[PATCH, all targets]: Move definition of "nop" to the top of insn definitions

Joseph S. Myers joseph@codesourcery.com
Tue Dec 8 13:31:00 GMT 2009


On Tue, 8 Dec 2009, Uros Bizjak wrote:

> Hello!
> 
> Some parts of gcc (i.e. caller-save [1]) assume that recog_insn
> doesn't return zero for valid insn. As suggested by rth, the best fix
> for this would be to move "nop" pattern to the top of insn
> definitions, forcing it to the position 0 in the insn description
> array.

If the intention is that this be required for all targets, shouldn't there 
be (a) a check in the generator programs that gives an error if this 
pattern is not first; (b) documentation in md.texi that it must be first?

-- 
Joseph S. Myers
joseph@codesourcery.com



More information about the Gcc-patches mailing list