summaryrefslogtreecommitdiffstats
path: root/llvm/utils/TableGen/X86RecognizableInstr.cpp
diff options
context:
space:
mode:
authorStefanus Du Toit <stefanus.du.toit@intel.com>2013-06-18 17:08:10 +0000
committerStefanus Du Toit <stefanus.du.toit@intel.com>2013-06-18 17:08:10 +0000
commit8811ad4f81766bfb6f49fafbf6ba5f419d61dcd3 (patch)
tree0ffd864866584022e5f74b441a42719a741fe439 /llvm/utils/TableGen/X86RecognizableInstr.cpp
parent4526b1d410a3d6d5571ddd27e2531aad13ca6093 (diff)
downloadbcm5719-llvm-8811ad4f81766bfb6f49fafbf6ba5f419d61dcd3.tar.gz
bcm5719-llvm-8811ad4f81766bfb6f49fafbf6ba5f419d61dcd3.zip
Add support for encoding the HLE XACQUIRE and XRELEASE prefixes.
For decoding, keep the current behavior of always decoding these as their REP versions. In the future, this could be improved to recognize the cases where these behave as XACQUIRE and XRELEASE and decode them as such. llvm-svn: 184207
Diffstat (limited to 'llvm/utils/TableGen/X86RecognizableInstr.cpp')
-rw-r--r--llvm/utils/TableGen/X86RecognizableInstr.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/utils/TableGen/X86RecognizableInstr.cpp b/llvm/utils/TableGen/X86RecognizableInstr.cpp
index 46f2052b010..76d986b1c1c 100644
--- a/llvm/utils/TableGen/X86RecognizableInstr.cpp
+++ b/llvm/utils/TableGen/X86RecognizableInstr.cpp
@@ -461,6 +461,12 @@ RecognizableInstr::filter_ret RecognizableInstr::filter() const {
Name == "VMOVQs64rr")
return FILTER_WEAK;
+ // XACQUIRE and XRELEASE reuse REPNE and REP respectively.
+ // For now, just prefer the REP versions.
+ if (Name == "XACQUIRE_PREFIX" ||
+ Name == "XRELEASE_PREFIX")
+ return FILTER_WEAK;
+
if (HasFROperands && Name.find("MOV") != Name.npos &&
((Name.find("2") != Name.npos && Name.find("32") == Name.npos) ||
(Name.find("to") != Name.npos)))
OpenPOWER on IntegriCloud