aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Basic/TargetInfo.cpp
diff options
context:
space:
mode:
authorMatthias Gehre <matthias.gehre@xilinx.com>2022-06-08 10:31:52 +0100
committerMatthias Gehre <matthias.gehre@xilinx.com>2022-06-09 07:15:03 +0100
commit7e17e15c9f01a04283524c6a6735d639aac39fe6 (patch)
treed1b50fb8b96371564ce36b5cdead19256121622c /clang/lib/Basic/TargetInfo.cpp
parente6a76a49356efd11f5f36690181f0f60cecb2e01 (diff)
downloadllvm-7e17e15c9f01a04283524c6a6735d639aac39fe6.zip
llvm-7e17e15c9f01a04283524c6a6735d639aac39fe6.tar.gz
llvm-7e17e15c9f01a04283524c6a6735d639aac39fe6.tar.bz2
clang: Introduce -fexperimental-max-bitint-width
This splits of the introduction of -fexperimental-max-bitint-width from https://reviews.llvm.org/D122234 because that PR is still blocked on discussions on the backend side. I was asked [0] to upstream at least the flag. [0] https://github.com/llvm/llvm-project/commit/09854f2af3b914b616f29cb640bede3a27cf7c4e#commitcomment-75116619 Differential Revision: https://reviews.llvm.org/D127287
Diffstat (limited to 'clang/lib/Basic/TargetInfo.cpp')
-rw-r--r--clang/lib/Basic/TargetInfo.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Basic/TargetInfo.cpp b/clang/lib/Basic/TargetInfo.cpp
index ae7dbfe..ba821f1 100644
--- a/clang/lib/Basic/TargetInfo.cpp
+++ b/clang/lib/Basic/TargetInfo.cpp
@@ -150,6 +150,9 @@ TargetInfo::TargetInfo(const llvm::Triple &T) : Triple(T) {
PlatformMinVersion = VersionTuple();
MaxOpenCLWorkGroupSize = 1024;
+
+ MaxBitIntWidth.reset();
+
ProgramAddrSpace = 0;
}
@@ -478,6 +481,9 @@ void TargetInfo::adjust(DiagnosticsEngine &Diags, LangOptions &Opts) {
Diags.Report(diag::err_opt_not_valid_on_target) << "-fprotect-parens";
Opts.ProtectParens = false;
}
+
+ if (Opts.MaxBitIntWidth)
+ MaxBitIntWidth = Opts.MaxBitIntWidth;
}
bool TargetInfo::initFeatureMap(