Re: Matching Constraints and Predicate

2010-08-24 Thread Paulo J. Matos
On Mon, Aug 23, 2010 at 6:43 PM, Ian Lance Taylor wrote: > > This also makes no sense.  The operand predicate should test whether the > value is acceptable.  The constraints should tell the register allocator > where the value should go.  The paragraph you quoted is saying that the > operand predi

Re: Matching Constraints and Predicate

2010-08-23 Thread Ian Lance Taylor
"Paulo J. Matos" writes: > However, if I have register constraints that define constraint x to > match a certain register class X and I define predicate: > (define_predicate "x_operand" > (and (match_operand 0 "register_operand") > (match_test "REGNO_REG_CLASS(REGNO(op)) == X")))

Matching Constraints and Predicate

2010-08-23 Thread Paulo J. Matos
Hello, I am quite confused with the following from the internals: ; Operand predicates can allow operands that are not actually ; acceptable to the hardware, as long as the constraints give ; reload the ability to fix them up (see Constraints). However, ; GCC will usually generate better code if t