CodeGen support will come later.
llvm-svn: 186401
def RISBG : RotateSelectRIEf<"risbg", 0xEC55, GR64, GR64>;
}
+// Rotate second operand left and perform a logical operation with selected
+// bits of the first operand.
+let Defs = [CC] in {
+ def RNSBG : RotateSelectRIEf<"rnsbg", 0xEC54, GR64, GR64>;
+ def ROSBG : RotateSelectRIEf<"rosbg", 0xEC56, GR64, GR64>;
+ def RXSBG : RotateSelectRIEf<"rxsbg", 0xEC57, GR64, GR64>;
+}
+
//===----------------------------------------------------------------------===//
// Comparison
//===----------------------------------------------------------------------===//
# CHECK: risbg %r4, %r5, 6, 7, 8
0xec 0x45 0x06 0x07 0x08 0x55
+# CHECK: rnsbg %r0, %r0, 0, 0, 0
+0xec 0x00 0x00 0x00 0x00 0x54
+
+# CHECK: rnsbg %r0, %r0, 0, 0, 63
+0xec 0x00 0x00 0x00 0x3f 0x54
+
+# CHECK: rnsbg %r0, %r0, 0, 255, 0
+0xec 0x00 0x00 0xff 0x00 0x54
+
+# CHECK: rnsbg %r0, %r0, 255, 0, 0
+0xec 0x00 0xff 0x00 0x00 0x54
+
+# CHECK: rnsbg %r0, %r15, 0, 0, 0
+0xec 0x0f 0x00 0x00 0x00 0x54
+
+# CHECK: rnsbg %r15, %r0, 0, 0, 0
+0xec 0xf0 0x00 0x00 0x00 0x54
+
+# CHECK: rnsbg %r4, %r5, 6, 7, 8
+0xec 0x45 0x06 0x07 0x08 0x54
+
+# CHECK: rosbg %r0, %r0, 0, 0, 0
+0xec 0x00 0x00 0x00 0x00 0x56
+
+# CHECK: rosbg %r0, %r0, 0, 0, 63
+0xec 0x00 0x00 0x00 0x3f 0x56
+
+# CHECK: rosbg %r0, %r0, 0, 255, 0
+0xec 0x00 0x00 0xff 0x00 0x56
+
+# CHECK: rosbg %r0, %r0, 255, 0, 0
+0xec 0x00 0xff 0x00 0x00 0x56
+
+# CHECK: rosbg %r0, %r15, 0, 0, 0
+0xec 0x0f 0x00 0x00 0x00 0x56
+
+# CHECK: rosbg %r15, %r0, 0, 0, 0
+0xec 0xf0 0x00 0x00 0x00 0x56
+
+# CHECK: rosbg %r4, %r5, 6, 7, 8
+0xec 0x45 0x06 0x07 0x08 0x56
+
+# CHECK: rxsbg %r0, %r0, 0, 0, 0
+0xec 0x00 0x00 0x00 0x00 0x57
+
+# CHECK: rxsbg %r0, %r0, 0, 0, 63
+0xec 0x00 0x00 0x00 0x3f 0x57
+
+# CHECK: rxsbg %r0, %r0, 0, 255, 0
+0xec 0x00 0x00 0xff 0x00 0x57
+
+# CHECK: rxsbg %r0, %r0, 255, 0, 0
+0xec 0x00 0xff 0x00 0x00 0x57
+
+# CHECK: rxsbg %r0, %r15, 0, 0, 0
+0xec 0x0f 0x00 0x00 0x00 0x57
+
+# CHECK: rxsbg %r15, %r0, 0, 0, 0
+0xec 0xf0 0x00 0x00 0x00 0x57
+
+# CHECK: rxsbg %r4, %r5, 6, 7, 8
+0xec 0x45 0x06 0x07 0x08 0x57
+
# CHECK: rllg %r0, %r0, 0
0xeb 0x00 0x00 0x00 0x00 0x1c
risbg %r0,%r0,256,0,0
#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,0,0,-1
+#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,0,0,64
+#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,0,-1,0
+#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,0,256,0
+#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,-1,0,0
+#CHECK: error: invalid operand
+#CHECK: rnsbg %r0,%r0,256,0,0
+
+ rnsbg %r0,%r0,0,0,-1
+ rnsbg %r0,%r0,0,0,64
+ rnsbg %r0,%r0,0,-1,0
+ rnsbg %r0,%r0,0,256,0
+ rnsbg %r0,%r0,-1,0,0
+ rnsbg %r0,%r0,256,0,0
+
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,0,0,-1
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,0,0,64
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,0,-1,0
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,0,256,0
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,-1,0,0
+#CHECK: error: invalid operand
+#CHECK: rosbg %r0,%r0,256,0,0
+
+ rosbg %r0,%r0,0,0,-1
+ rosbg %r0,%r0,0,0,64
+ rosbg %r0,%r0,0,-1,0
+ rosbg %r0,%r0,0,256,0
+ rosbg %r0,%r0,-1,0,0
+ rosbg %r0,%r0,256,0,0
+
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,0,0,-1
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,0,0,64
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,0,-1,0
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,0,256,0
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,-1,0,0
+#CHECK: error: invalid operand
+#CHECK: rxsbg %r0,%r0,256,0,0
+
+ rxsbg %r0,%r0,0,0,-1
+ rxsbg %r0,%r0,0,0,64
+ rxsbg %r0,%r0,0,-1,0
+ rxsbg %r0,%r0,0,256,0
+ rxsbg %r0,%r0,-1,0,0
+ rxsbg %r0,%r0,256,0,0
+
+#CHECK: error: invalid operand
#CHECK: rll %r0,%r0,-524289
#CHECK: error: invalid operand
#CHECK: rll %r0,%r0,524288
risbg %r15,%r0,0,0,0
risbg %r4,%r5,6,7,8
+#CHECK: rnsbg %r0, %r0, 0, 0, 0 # encoding: [0xec,0x00,0x00,0x00,0x00,0x54]
+#CHECK: rnsbg %r0, %r0, 0, 0, 63 # encoding: [0xec,0x00,0x00,0x00,0x3f,0x54]
+#CHECK: rnsbg %r0, %r0, 0, 255, 0 # encoding: [0xec,0x00,0x00,0xff,0x00,0x54]
+#CHECK: rnsbg %r0, %r0, 255, 0, 0 # encoding: [0xec,0x00,0xff,0x00,0x00,0x54]
+#CHECK: rnsbg %r0, %r15, 0, 0, 0 # encoding: [0xec,0x0f,0x00,0x00,0x00,0x54]
+#CHECK: rnsbg %r15, %r0, 0, 0, 0 # encoding: [0xec,0xf0,0x00,0x00,0x00,0x54]
+#CHECK: rnsbg %r4, %r5, 6, 7, 8 # encoding: [0xec,0x45,0x06,0x07,0x08,0x54]
+
+ rnsbg %r0,%r0,0,0,0
+ rnsbg %r0,%r0,0,0,63
+ rnsbg %r0,%r0,0,255,0
+ rnsbg %r0,%r0,255,0,0
+ rnsbg %r0,%r15,0,0,0
+ rnsbg %r15,%r0,0,0,0
+ rnsbg %r4,%r5,6,7,8
+
+#CHECK: rosbg %r0, %r0, 0, 0, 0 # encoding: [0xec,0x00,0x00,0x00,0x00,0x56]
+#CHECK: rosbg %r0, %r0, 0, 0, 63 # encoding: [0xec,0x00,0x00,0x00,0x3f,0x56]
+#CHECK: rosbg %r0, %r0, 0, 255, 0 # encoding: [0xec,0x00,0x00,0xff,0x00,0x56]
+#CHECK: rosbg %r0, %r0, 255, 0, 0 # encoding: [0xec,0x00,0xff,0x00,0x00,0x56]
+#CHECK: rosbg %r0, %r15, 0, 0, 0 # encoding: [0xec,0x0f,0x00,0x00,0x00,0x56]
+#CHECK: rosbg %r15, %r0, 0, 0, 0 # encoding: [0xec,0xf0,0x00,0x00,0x00,0x56]
+#CHECK: rosbg %r4, %r5, 6, 7, 8 # encoding: [0xec,0x45,0x06,0x07,0x08,0x56]
+
+ rosbg %r0,%r0,0,0,0
+ rosbg %r0,%r0,0,0,63
+ rosbg %r0,%r0,0,255,0
+ rosbg %r0,%r0,255,0,0
+ rosbg %r0,%r15,0,0,0
+ rosbg %r15,%r0,0,0,0
+ rosbg %r4,%r5,6,7,8
+
+#CHECK: rxsbg %r0, %r0, 0, 0, 0 # encoding: [0xec,0x00,0x00,0x00,0x00,0x57]
+#CHECK: rxsbg %r0, %r0, 0, 0, 63 # encoding: [0xec,0x00,0x00,0x00,0x3f,0x57]
+#CHECK: rxsbg %r0, %r0, 0, 255, 0 # encoding: [0xec,0x00,0x00,0xff,0x00,0x57]
+#CHECK: rxsbg %r0, %r0, 255, 0, 0 # encoding: [0xec,0x00,0xff,0x00,0x00,0x57]
+#CHECK: rxsbg %r0, %r15, 0, 0, 0 # encoding: [0xec,0x0f,0x00,0x00,0x00,0x57]
+#CHECK: rxsbg %r15, %r0, 0, 0, 0 # encoding: [0xec,0xf0,0x00,0x00,0x00,0x57]
+#CHECK: rxsbg %r4, %r5, 6, 7, 8 # encoding: [0xec,0x45,0x06,0x07,0x08,0x57]
+
+ rxsbg %r0,%r0,0,0,0
+ rxsbg %r0,%r0,0,0,63
+ rxsbg %r0,%r0,0,255,0
+ rxsbg %r0,%r0,255,0,0
+ rxsbg %r0,%r15,0,0,0
+ rxsbg %r15,%r0,0,0,0
+ rxsbg %r4,%r5,6,7,8
+
#CHECK: rll %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x1d]
#CHECK: rll %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x1d]
#CHECK: rll %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x1d]