def EIEIO : XForm_24_eieio<31, 854, (outs), (ins),
"eieio", LdStLoad, []>;
+def WAIT : XForm_24_sync<31, 62, (outs), (ins i32imm:$L),
+ "wait $L", LdStLoad, []>;
+
//===----------------------------------------------------------------------===//
// PowerPC Assembler Instruction Aliases
//
def : InstAlias<"lwsync", (SYNC 1)>;
def : InstAlias<"ptesync", (SYNC 2)>;
+def : InstAlias<"wait", (WAIT 0)>;
+def : InstAlias<"waitrsv", (WAIT 1)>;
+def : InstAlias<"waitimpl", (WAIT 2)>;
+
def : InstAlias<"xnop", (XORI R0, R0, 0)>;
def : InstAlias<"mr $rA, $rB", (OR8 g8rc:$rA, g8rc:$rB, g8rc:$rB)>;
sync 2
# CHECK: eieio # encoding: [0x7c,0x00,0x06,0xac]
eieio
-# FIXME: wait 2
+# CHECK: wait 2 # encoding: [0x7c,0x40,0x00,0x7c]
+ wait 2
# Extended mnemonics
# CHECK: sync 2 # encoding: [0x7c,0x40,0x04,0xac]
ptesync
-# FIXME: wait
-# FIXME: waitrsv
-# FIXME: waitimpl
+# CHECK: wait 0 # encoding: [0x7c,0x00,0x00,0x7c]
+ wait
+# CHECK: wait 1 # encoding: [0x7c,0x20,0x00,0x7c]
+ waitrsv
+# CHECK: wait 2 # encoding: [0x7c,0x40,0x00,0x7c]
+ waitimpl