]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
rs6000: Correct return value of check_p9modulo_hw_available.
authorHaochen Gui <guihaoc@gcc.gnu.org>
Fri, 5 Aug 2022 02:44:18 +0000 (10:44 +0800)
committerHaochen Gui <guihaoc@gcc.gnu.org>
Fri, 5 Aug 2022 02:46:00 +0000 (10:46 +0800)
Set the return value to 0 when modulo is supported, and to 1 when not supported.

gcc/testsuite/
* lib/target-supports.exp (check_p9modulo_hw_available): Correct return
value.

gcc/testsuite/lib/target-supports.exp

index 4ed7b25b9a4de1eff4ac1f588149994ac7114a38..04a2a8e8659d05f8405be9e22e8bb406df8089ca 100644 (file)
@@ -2288,7 +2288,7 @@ proc check_p9modulo_hw_available { } {
                {
                    int i = 5, j = 3, r = -1;
                    asm ("modsw %0,%1,%2" : "+r" (r) : "r" (i), "r" (j));
-                   return (r == 2);
+                   return (r != 2);
                }
            } $options
        }