diff mbox

[i386] : Fix constm1_operand predicate

Message ID CAFULd4b72QsF8B+bdiv-DhbpgKYD5Jmqc1cy-qOoYFbF4kGQ1A@mail.gmail.com
State New
Headers show

Commit Message

Uros Bizjak April 29, 2016, 12:04 p.m. UTC
Brown-paper bag bug ...

>> Do I misuse constm1_operand?
>
> No, it is just a typo that crept in constm1_operand:
>
> ;; Match exactly -1.
> (define_predicate "constm1_operand"
>   (and (match_code "const_int")
>        (match_test "op = constm1_rtx")))
>
> There should be a test, not an assignment.

Fixed by attached patch.

2016-04-29  Uros Bizjak  <ubizjak@gmail.com>

    * config/i386/predicates.md (constm1_operand): Fix comparison.

Bootstrap and regression test in progress, will commit to mainline ASAP.

Uros.
diff mbox

Patch

Index: i386/predicates.md
===================================================================
--- i386/predicates.md  (revision 235619)
+++ i386/predicates.md  (working copy)
@@ -678,7 +678,7 @@ 
 ;; Match exactly -1.
 (define_predicate "constm1_operand"
   (and (match_code "const_int")
-       (match_test "op = constm1_rtx")))
+       (match_test "op == constm1_rtx")))

 ;; Match exactly eight.
 (define_predicate "const8_operand"