Add LTGT operator support for amdgcn
authorAndrew Stubbs <ams@codesourcery.com>
Wed, 29 Jan 2020 11:35:07 +0000 (11:35 +0000)
committerAndrew Stubbs <ams@codesourcery.com>
Thu, 30 Jan 2020 16:50:49 +0000 (16:50 +0000)
Fixes ICE in testcase gcc.dg/pr81228.c

2020-01-30  Andrew Stubbs  <ams@codesourcery.com>

gcc/
* config/gcn/gcn.c (print_operand): Handle LTGT.
* config/gcn/predicates.md (gcn_fp_compare_operator): Allow ltgt.

gcc/ChangeLog
gcc/config/gcn/gcn.c
gcc/config/gcn/predicates.md

index ab1161b..7132bf0 100644 (file)
@@ -1,3 +1,8 @@
+2020-01-30  Andrew Stubbs  <ams@codesourcery.com>
+
+       * config/gcn/gcn.c (print_operand): Handle LTGT.
+       * config/gcn/predicates.md (gcn_fp_compare_operator): Allow ltgt.
+
 2020-01-30  Richard Biener  <rguenther@suse.de>
 
        * tree-pretty-print.c (dump_generic_node): Wrap VECTOR_CST
index c78df1d..a39e9f3 100644 (file)
@@ -5929,6 +5929,9 @@ print_operand (FILE *file, rtx x, int code)
          case UNORDERED:
            s = "_u_";
            break;
+         case LTGT:
+           s = "_lg_";
+           break;
          default:
            output_operand_lossage ("invalid %%xn code");
            return;
index 2f904b1..7bf763a 100644 (file)
   (match_code "eq,ne,gt,ge,lt,le,gtu,geu,ltu,leu"))
 
 (define_predicate "gcn_fp_compare_operator"
-  (match_code "eq,ne,gt,ge,lt,le,gtu,geu,ltu,leu,ordered,unordered"))
+  (match_code "eq,ne,gt,ge,lt,le,gtu,geu,ltu,leu,ordered,unordered,ltgt"))
 
 (define_predicate "unary_operator"
   (match_code "not,popcount"))