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,M32C]:Mismatch of instruction pattern.


Your patch was not quite correct.  You checked the INTVAL of the
operand, but neglected to check that it was a CONST_INT first.  IIRC
you've done this before, so please be more careful about those kinds
of checks (op[1] is already guaranteed to be a CONST_INT, but op[3]
isn't).  In this case, the operand that the test case generated was a
REG and not a CONST_INT, so calling INTVAL on it was invalid.  I added
the CONST_INT check.

Also, you checked for zero and one, but not -1.  I added -1 so that
signed bitfields would work.

Also, the ChangeLog entry you included was improperly formatted.
Please read the guidelines for formatting CL entries, or at least
follow the pattern from the other entries.

Anyway, the fix has been committed.  Thanks!

DJ


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