make use of opcodes.h. The is part of extended immediate facility
authorcborntra <cborntra@a5019735-40e9-0310-863c-91ae7b9d1cf9>
Mon, 15 Oct 2012 14:20:46 +0000 (14:20 +0000)
committercborntra <cborntra@a5019735-40e9-0310-863c-91ae7b9d1cf9>
Mon, 15 Oct 2012 14:20:46 +0000 (14:20 +0000)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13045 a5019735-40e9-0310-863c-91ae7b9d1cf9

memcheck/tests/s390x/ltgjhe.c

index 6a02b111d27dcc4fe9d11eb788f3f8e52df69214..de0104cfe9d8e378bb5a9b9cafca67b55104609b 100644 (file)
@@ -1,4 +1,5 @@
 #include <stdio.h>
+#include "../../../none/tests/s390x/opcodes.h"
 int main()
 {
        int field1, field2;
@@ -6,12 +7,13 @@ int main()
 
        /*
          * gcc does some tricks for checking the highest bit. It seems
-         * to load a full word/double word. 
+         * to load a full word/double word.
          * By using mask=10 for brc (jhe) only the msb is influencing
          * the code flow. This test was inspired by 308427
          */
        asm volatile(   "oi %1,128\n\t"
-                       "ltg 0,%1\n\t"
+                       "la 1,%1\n\t"
+                       LTG(0,0,1,000,00)
                        "jhe 1f\n\t"
                        "lghi %0,0\n\t"
                        "j 2f\n\t"
@@ -25,7 +27,8 @@ int main()
                printf("Error\n");
 
        asm volatile(   "oi %1,128\n\t"
-                       "lt 0,%1\n\t"
+                       "la 1,%1\n\t"
+                       LT(0,0,1,000,00)
                        "jhe 1f\n\t"
                        "lghi %0,0\n\t"
                        "j 2f\n\t"