2012-11-08 15:28:54 +08:00
|
|
|
//===-- X86InstrVMX.td - TSX Instruction Set Extension -----*- tablegen -*-===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
// This file describes the instructions that make up the Intel TSX instruction
|
|
|
|
// set.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
// TSX instructions
|
|
|
|
|
2013-03-27 06:47:01 +08:00
|
|
|
def X86xtest: SDNode<"X86ISD::XTEST", SDTypeProfile<1, 0, [SDTCisVT<0, i32>]>,
|
|
|
|
[SDNPHasChain, SDNPSideEffect]>;
|
|
|
|
|
2012-11-08 15:28:54 +08:00
|
|
|
let usesCustomInserter = 1 in
|
|
|
|
def XBEGIN : I<0, Pseudo, (outs GR32:$dst), (ins),
|
|
|
|
"# XBEGIN", [(set GR32:$dst, (int_x86_xbegin))]>,
|
|
|
|
Requires<[HasRTM]>;
|
|
|
|
|
2015-01-06 16:59:30 +08:00
|
|
|
let isBranch = 1, isTerminator = 1, Defs = [EAX] in {
|
|
|
|
def XBEGIN_2 : Ii16PCRel<0xc7, MRM_F8, (outs), (ins brtarget16:$dst),
|
|
|
|
"xbegin\t$dst", []>, OpSize16, Requires<[HasRTM]>;
|
|
|
|
def XBEGIN_4 : Ii32PCRel<0xc7, MRM_F8, (outs), (ins brtarget32:$dst),
|
|
|
|
"xbegin\t$dst", []>, OpSize32, Requires<[HasRTM]>;
|
|
|
|
}
|
2012-11-08 15:28:54 +08:00
|
|
|
|
|
|
|
def XEND : I<0x01, MRM_D5, (outs), (ins),
|
|
|
|
"xend", [(int_x86_xend)]>, TB, Requires<[HasRTM]>;
|
|
|
|
|
2013-03-26 02:59:43 +08:00
|
|
|
let Defs = [EFLAGS] in
|
2013-03-27 06:47:01 +08:00
|
|
|
def XTEST : I<0x01, MRM_D6, (outs), (ins),
|
|
|
|
"xtest", [(set EFLAGS, (X86xtest))]>, TB, Requires<[HasTSX]>;
|
2013-03-26 02:59:43 +08:00
|
|
|
|
2012-11-08 15:28:54 +08:00
|
|
|
def XABORT : Ii8<0xc6, MRM_F8, (outs), (ins i8imm:$imm),
|
|
|
|
"xabort\t$imm",
|
|
|
|
[(int_x86_xabort imm:$imm)]>, Requires<[HasRTM]>;
|
2013-06-19 01:08:10 +08:00
|
|
|
|
|
|
|
// HLE prefixes
|
|
|
|
|
2014-02-12 16:02:29 +08:00
|
|
|
let isAsmParserOnly = 1 in {
|
2013-06-19 01:08:10 +08:00
|
|
|
def XACQUIRE_PREFIX : I<0xF2, RawFrm, (outs), (ins), "xacquire", []>, Requires<[HasHLE]>;
|
|
|
|
def XRELEASE_PREFIX : I<0xF3, RawFrm, (outs), (ins), "xrelease", []>, Requires<[HasHLE]>;
|
2014-02-12 16:02:29 +08:00
|
|
|
}
|
2013-06-19 01:08:10 +08:00
|
|
|
|