[clang] [RISCV] Overwrite cpu target features for full arch string in target attribute (PR #77426)
Craig Topper via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 11 12:58:36 PST 2024
================
@@ -413,7 +385,9 @@ static void handleFullArchString(StringRef FullArchStr,
// Forward the invalid FullArchStr.
Features.push_back("+" + FullArchStr.str());
} else {
- std::vector<std::string> FeatStrings = (*RII)->toFeatures();
+ // Append a full list of features, including any negative extensions so that
+ // we override the CPU's features.
+ std::vector<std::string> FeatStrings = (*RII)->toFeatures(true);
----------------
topperc wrote:
Add an inline comment to label what `true` means
https://github.com/llvm/llvm-project/pull/77426
More information about the cfe-commits
mailing list