mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 11:02:59 +02:00
ae65e281f3
to reflect the new license. We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach. Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository. llvm-svn: 351636
60 lines
2.1 KiB
TableGen
60 lines
2.1 KiB
TableGen
//===-- X86InstrVMX.td - TSX Instruction Set Extension -----*- tablegen -*-===//
|
|
//
|
|
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
|
|
// See https://llvm.org/LICENSE.txt for license information.
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This file describes the instructions that make up the Intel TSX instruction
|
|
// set.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
// TSX instructions
|
|
|
|
def X86xtest: SDNode<"X86ISD::XTEST", SDTypeProfile<1, 0, [SDTCisVT<0, i32>]>,
|
|
[SDNPHasChain, SDNPSideEffect]>;
|
|
|
|
let SchedRW = [WriteSystem] in {
|
|
|
|
let usesCustomInserter = 1 in
|
|
def XBEGIN : I<0, Pseudo, (outs GR32:$dst), (ins),
|
|
"# XBEGIN", [(set GR32:$dst, (int_x86_xbegin))]>,
|
|
Requires<[HasRTM]>;
|
|
|
|
let isBranch = 1, isTerminator = 1, Defs = [EAX] in {
|
|
def XBEGIN_2 : Ii16PCRel<0xc7, MRM_F8, (outs), (ins brtarget16:$dst),
|
|
"xbegin\t$dst", []>, OpSize16;
|
|
def XBEGIN_4 : Ii32PCRel<0xc7, MRM_F8, (outs), (ins brtarget32:$dst),
|
|
"xbegin\t$dst", []>, OpSize32;
|
|
}
|
|
|
|
// Psuedo instruction to fake the definition of EAX on the fallback code path.
|
|
let isPseudo = 1, Defs = [EAX] in {
|
|
def XABORT_DEF : I<0, Pseudo, (outs), (ins), "# XABORT DEF", []>;
|
|
}
|
|
|
|
def XEND : I<0x01, MRM_D5, (outs), (ins),
|
|
"xend", [(int_x86_xend)]>, TB, Requires<[HasRTM]>;
|
|
|
|
let Defs = [EFLAGS] in
|
|
def XTEST : I<0x01, MRM_D6, (outs), (ins),
|
|
"xtest", [(set EFLAGS, (X86xtest))]>, TB, Requires<[HasRTM]>;
|
|
|
|
def XABORT : Ii8<0xc6, MRM_F8, (outs), (ins i8imm:$imm),
|
|
"xabort\t$imm",
|
|
[(int_x86_xabort imm:$imm)]>, Requires<[HasRTM]>;
|
|
} // SchedRW
|
|
|
|
// HLE prefixes
|
|
let SchedRW = [WriteSystem] in {
|
|
|
|
let isAsmParserOnly = 1 in {
|
|
def XACQUIRE_PREFIX : I<0xF2, RawFrm, (outs), (ins), "xacquire", []>;
|
|
def XRELEASE_PREFIX : I<0xF3, RawFrm, (outs), (ins), "xrelease", []>;
|
|
}
|
|
|
|
} // SchedRW
|