[PATCH] D131708: [RISCV] Change how mtune aliases are implemented.

Craig Topper via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 15 21:45:52 PDT 2022


craig.topper planned changes to this revision.
craig.topper added inline comments.


================
Comment at: clang/test/Driver/riscv-cpus.c:27
 // RUN: %clang --target=riscv64 -### -c %s 2>&1 -mtune=rocket | FileCheck -check-prefix=MTUNE-ROCKET-64 %s
-// MTUNE-ROCKET-64: "-tune-cpu" "rocket-rv64"
-
-// RUN: %clang --target=riscv32 -### -c %s 2>&1 -mtune=sifive-7-series | FileCheck -check-prefix=MTUNE-SIFIVE7-SERIES-32 %s
-// MTUNE-SIFIVE7-SERIES-32: "-tune-cpu" "sifive-7-rv32"
-
-// RUN: %clang --target=riscv64 -### -c %s 2>&1 -mtune=sifive-7-series | FileCheck -check-prefix=MTUNE-SIFIVE7-SERIES-64 %s
-// MTUNE-SIFIVE7-SERIES-64: "-tune-cpu" "sifive-7-rv64"
+// MTUNE-ROCKET-64: "-tune-cpu" "rocket"
 
----------------
kito-cheng wrote:
> I got `error: unknown target CPU 'rocket'` (e.g. `clang --target=riscv64 -mtune=rocket ~/hello.c`) after this patch, but no error if come with `-###`
Thanks. I failed to update `checkTuneCPUKind` so the CPU doesn't validate.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D131708



More information about the cfe-commits mailing list