[PATCH] D105462: [X86] Add CRC32 feature.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 6 00:26:40 PDT 2021


craig.topper added inline comments.


================
Comment at: llvm/lib/Support/X86TargetParser.cpp:531
 constexpr FeatureBitset ImpliedFeaturesSSE4_1 = FeatureSSSE3;
-constexpr FeatureBitset ImpliedFeaturesSSE4_2 = FeatureSSE4_1;
+constexpr FeatureBitset ImpliedFeaturesSSE4_2 = FeatureSSE4_1 | FeatureCRC32;
 constexpr FeatureBitset ImpliedFeaturesAVX = FeatureSSE4_2;
----------------
Same question.


================
Comment at: llvm/lib/Target/X86/X86.td:84
                                       "Enable SSE 4.2 instructions",
-                                      [FeatureSSE41]>;
+                                      [FeatureSSE41, FeatureCRC32]>;
 // The MMX subtarget feature is separate from the rest of the SSE features
----------------
Doesn't this make -mno-crc32 disable sse4.2? Is that what we want?

Or should we be doing this like popcnt where we loosely enable it at the end of X86TargetInfo::initFeatureMap


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105462/new/

https://reviews.llvm.org/D105462



More information about the llvm-commits mailing list