RKSimon added inline comments.
================ Comment at: llvm/lib/TargetParser/X86TargetParser.cpp:15 #include "llvm/ADT/StringSwitch.h" +#include "llvm/ADT/StringExtras.h" #include <numeric> ---------------- (clang-format) - include order ================ Comment at: llvm/lib/TargetParser/X86TargetParser.cpp:314 + // Empty processor. Include X87 and CMPXCHG8 for backwards compatibility. + { {""}, CK_None, ~0U, FeatureX87 | FeatureCMPXCHG8B, '\0', false }, + { {"generic"}, CK_None, ~0U, FeaturesPentiumMMX & ~FeaturesPentiumMMX, 'A', true }, ---------------- Would it be better to move all of this into X86TargetParser.def ? ================ Comment at: llvm/lib/TargetParser/X86TargetParser.cpp:315 + { {""}, CK_None, ~0U, FeatureX87 | FeatureCMPXCHG8B, '\0', false }, + { {"generic"}, CK_None, ~0U, FeaturesPentiumMMX & ~FeaturesPentiumMMX, 'A', true }, // i386-generation processors. ---------------- FeaturesPentiumMMX & ~FeaturesPentiumMMX ? ================ Comment at: llvm/test/CodeGen/X86/cpus-intel.ll:26 ; RUN: llc < %s -o /dev/null -mtriple=i686-unknown-unknown -mcpu=emeraldrapids 2>&1 | FileCheck %s --check-prefix=CHECK-NO-ERROR --allow-empty +; RUN: llc < %s -o /dev/null -mtriple=i686-unknown-unknown -mcpu=generic 2>&1 | FileCheck %s --check-prefix=CHECK-NO-ERROR --allow-empty +; RUN: llc < %s -o /dev/null -mtriple=i686-unknown-unknown -mcpu=pentium_ii 2>&1 | FileCheck %s --check-prefix=CHECK-NO-ERROR --allow-empty ---------------- Keeping all the aliased cpus variants RUN together will make maintenance easier (e.g. pentium_mmx) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151696/new/ https://reviews.llvm.org/D151696 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits