From: Craig Topper Date: Mon, 29 Feb 2016 06:51:34 +0000 (+0000) Subject: [X86] Enabling xsave should not enable AVX. I seem to have done this, but I don't... X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=840927e074f40be0eecaf38542d9b57810952564;p=platform%2Fupstream%2Fllvm.git [X86] Enabling xsave should not enable AVX. I seem to have done this, but I don't know why. llvm-svn: 262200 --- diff --git a/clang/lib/Basic/Targets.cpp b/clang/lib/Basic/Targets.cpp index e94cebe..8f5fd1a 100644 --- a/clang/lib/Basic/Targets.cpp +++ b/clang/lib/Basic/Targets.cpp @@ -3018,15 +3018,11 @@ void X86TargetInfo::setFeatureEnabledImpl(llvm::StringMap &Features, else setSSELevel(Features, SSE41, Enabled); } else if (Name == "xsave") { - if (Enabled) - setSSELevel(Features, AVX, Enabled); - else + if (!Enabled) Features["xsaveopt"] = false; } else if (Name == "xsaveopt" || Name == "xsavec" || Name == "xsaves") { - if (Enabled) { + if (Enabled) Features["xsave"] = true; - setSSELevel(Features, AVX, Enabled); - } } }