]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Fix inline assembly for the "lfiwax" insn test. #302536.
authorJulian Seward <jseward@acm.org>
Thu, 28 Jun 2012 18:40:43 +0000 (18:40 +0000)
committerJulian Seward <jseward@acm.org>
Thu, 28 Jun 2012 18:40:43 +0000 (18:40 +0000)
(Carl Love, carll@us.ibm.com)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12681

memcheck/tests/ppc32/power_ISA2_05.c
memcheck/tests/ppc64/power_ISA2_05.c
memcheck/tests/ppc64/power_ISA2_05.stdout.exp

index d96ef9c576d67df2adfe108093d2bc9dcb3c7d7d..f85b547f5f17ca4a28f2f91a7206ed675053ed6e 100644 (file)
@@ -40,7 +40,7 @@ void test_parity_instrs()
 void test_lfiwax()
 {
    unsigned long base;
-   unsigned long offset;
+   //   unsigned long offset;
 
    typedef struct {
       unsigned int hi;
@@ -50,9 +50,8 @@ void test_lfiwax()
    int_pair_t *ip;
    foo = -1024.0;
    base = (unsigned long) &foo;
-   offset = 0;
-   __asm__ volatile ("lfiwax %0, %1, %2":"=f" (FRT1):"r"(base),
-                     "r"(offset));
+
+   __asm__ volatile ("lfiwax %0, 0, %1":"=f" (FRT1):"r"(base));
    ip = (int_pair_t *) & FRT1;
    printf("lfiwax (%f) => FRT=(%x, %x)\n", foo, ip->hi, ip->lo);
 
index d96ef9c576d67df2adfe108093d2bc9dcb3c7d7d..dcf0e7aacb80f606ee3020a69675780907abafde 100644 (file)
@@ -40,7 +40,6 @@ void test_parity_instrs()
 void test_lfiwax()
 {
    unsigned long base;
-   unsigned long offset;
 
    typedef struct {
       unsigned int hi;
@@ -50,9 +49,8 @@ void test_lfiwax()
    int_pair_t *ip;
    foo = -1024.0;
    base = (unsigned long) &foo;
-   offset = 0;
-   __asm__ volatile ("lfiwax %0, %1, %2":"=f" (FRT1):"r"(base),
-                     "r"(offset));
+
+   __asm__ volatile ("lfiwax %0, 0, %1":"=f" (FRT1):"r"(base));
    ip = (int_pair_t *) & FRT1;
    printf("lfiwax (%f) => FRT=(%x, %x)\n", foo, ip->hi, ip->lo);
 
index b5a7458d2d8dc327370092e743b3ce9cfb1fde1e..32978382e33943b92e0514d83f4ec441d02438a9 100644 (file)
@@ -19,7 +19,7 @@ fcpsgn sign=-10.101010, base=-11.111111 => -11.111111
 lfdp (-1024.000000, 1025.000000) => F_hi=-1024.000000, F_lo=1025.000000
 stfdp (2.204800, -4.102400) => F_hi=2.204800, F_lo=-4.102400
 lfdpx (2.204800, -4.102400) => F_hi=2.204800, F_lo=-4.102400
-stfdpx (2.204800, -4.102400) => F_hi=2.204800, F_lo=-4.102400
+stfdpx (2.204800, 2.204800) => F_hi=2.204800, F_lo=2.204800
 lfiwax (-1024.000000) => FRT=(ffffffff, c0900000)
 prtyd (0) => parity=0
 prtyw (0) => parity=0