================
@@ -2950,14 +2950,22 @@ bool
CodeGenModule::GetCPUAndFeaturesAttributes(GlobalDecl GD,
const auto *SD = FD ? FD->getAttr<CPUSpecificAttr>() : nullptr;
const auto *TC = FD ? FD->getAttr<TargetClonesAttr>() : nullptr;
bool AddedAttr = false;
+ auto HandleFeatureDelta = [&](llvm::StringMap<bool> &FeatureMap) {
+ // Get the default feature map for the (possibly overridden) target CPU.
+ llvm::StringMap<bool> DefaultFeatureMap;
+ getTarget().initFeatureMap(DefaultFeatureMap,
getContext().getDiagnostics(),
+ TargetCPU, {});
+ for (const auto &[K, V] : FeatureMap) {
----------------
arsenm wrote:
Ideally this wouldn't require string logic, and use the bitset, but for now you
probably can't do any better
https://github.com/llvm/llvm-project/pull/176533
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits