Correct expected high value of multiplication
authorJoakim Andersson <joerchan@gmail.com>
Mon, 13 Apr 2015 20:57:04 +0000 (22:57 +0200)
committerJoakim Andersson <joerchan@gmail.com>
Mon, 13 Apr 2015 20:57:04 +0000 (22:57 +0200)
isa/rv32ui/mulh.S
isa/rv32ui/mulhsu.S

index 3b34b6abdcaa22c7df7c2d703cca75d592898e82..e583f5f699205240ebd25bfbb423dc4749c13044 100644 (file)
@@ -25,16 +25,15 @@ RVTEST_CODE_BEGIN
   TEST_RR_OP( 6,  mulh, 0x00000000, 0x80000000, 0x00000000 );
   TEST_RR_OP( 7,  mulh, 0x00000000, 0x80000000, 0x00000000 );
 
-  TEST_RR_OP(30,  mulh, 0xfffe0101, 0xaaaaaaab, 0x0002fe7d );
-  TEST_RR_OP(31,  mulh, 0xfffe0101, 0x0002fe7d, 0xaaaaaaab );
+  TEST_RR_OP(30,  mulh, 0xffff0081, 0xaaaaaaab, 0x0002fe7d );
+  TEST_RR_OP(31,  mulh, 0xffff0081, 0x0002fe7d, 0xaaaaaaab );
 
-  TEST_RR_OP(32,  mulh, 0xfe010000, 0xff000000, 0xff000000 );
+  TEST_RR_OP(32,  mulh, 0x00010000, 0xff000000, 0xff000000 );
 
-  TEST_RR_OP(33,  mulh, 0xfffffffe, 0xffffffff, 0xffffffff );
+  TEST_RR_OP(33,  mulh, 0x00000000, 0xffffffff, 0xffffffff );
   TEST_RR_OP(34,  mulh, 0xffffffff, 0xffffffff, 0x00000001 );
   TEST_RR_OP(35,  mulh, 0xffffffff, 0x00000001, 0xffffffff );
 
-
   #-------------------------------------------------------------
   # Source/Destination tests
   #-------------------------------------------------------------
index 93e698c6505f490df96094900de6b83aab4c2c7f..28b369099151b989344f22955b9f0e1919c303aa 100644 (file)
@@ -25,12 +25,12 @@ RVTEST_CODE_BEGIN
   TEST_RR_OP( 6,  mulhsu, 0x00000000, 0x80000000, 0x00000000 );
   TEST_RR_OP( 7,  mulhsu, 0x80004000, 0x80000000, 0xffff8000 );
 
-  TEST_RR_OP(30,  mulhsu, 0xfffe0101, 0xaaaaaaab, 0x0002fe7d );
+  TEST_RR_OP(30,  mulhsu, 0xffff0081, 0xaaaaaaab, 0x0002fe7d );
   TEST_RR_OP(31,  mulhsu, 0x0001fefe, 0x0002fe7d, 0xaaaaaaab );
 
-  TEST_RR_OP(32,  mulhsu, 0x01ff0000, 0xff000000, 0xff000000 );
+  TEST_RR_OP(32,  mulhsu, 0xff010000, 0xff000000, 0xff000000 );
 
-  TEST_RR_OP(33,  mulhsu, 0x00000001, 0xffffffff, 0xffffffff );
+  TEST_RR_OP(33,  mulhsu, 0xffffffff, 0xffffffff, 0xffffffff );
   TEST_RR_OP(34,  mulhsu, 0xffffffff, 0xffffffff, 0x00000001 );
   TEST_RR_OP(35,  mulhsu, 0x00000000, 0x00000001, 0xffffffff );