diff options
author | Luke Lau <luke@igalia.com> | 2024-01-16 00:20:35 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-16 00:20:35 +0700 |
commit | 219c14a2609aaced2823f5a1b0a22584559bddad (patch) | |
tree | 87f93e6d25bbe63903485401c72efc48e023fde0 | |
parent | 6d4c88786aa503f803a6ec881e66fe1e1f38f6d8 (diff) | |
download | llvm-219c14a2609aaced2823f5a1b0a22584559bddad.zip llvm-219c14a2609aaced2823f5a1b0a22584559bddad.tar.gz llvm-219c14a2609aaced2823f5a1b0a22584559bddad.tar.bz2 |
[Flang] Remove dead -mvscale-{min,max} logic from getVScaleRange. NFCI (#78133)
After #77905, setting -mvscale-min or -mvscale-max on targets other than
AArch64 and RISC-V should be an error now, so we no longer need this
target-agnostic code in getVScaleRange.
-rw-r--r-- | flang/lib/Frontend/FrontendActions.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/flang/lib/Frontend/FrontendActions.cpp b/flang/lib/Frontend/FrontendActions.cpp index 8fb1998..74e3992 100644 --- a/flang/lib/Frontend/FrontendActions.cpp +++ b/flang/lib/Frontend/FrontendActions.cpp @@ -769,7 +769,6 @@ getRISCVVScaleRange(CompilerInstance &ci) { // too much of clang, so for now, replicate the functionality. static std::optional<std::pair<unsigned, unsigned>> getVScaleRange(CompilerInstance &ci) { - const auto &langOpts = ci.getInvocation().getLangOpts(); const llvm::Triple triple(ci.getInvocation().getTargetOpts().triple); if (triple.isAArch64()) @@ -777,10 +776,8 @@ getVScaleRange(CompilerInstance &ci) { if (triple.isRISCV()) return getRISCVVScaleRange(ci); - if (langOpts.VScaleMin || langOpts.VScaleMax) - return std::pair<unsigned, unsigned>( - langOpts.VScaleMin ? langOpts.VScaleMin : 1, langOpts.VScaleMax); - + // All other architectures that don't support scalable vectors (i.e. don't + // need vscale) return std::nullopt; } |