diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2012-11-29 05:41:51 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2012-11-29 05:41:51 +0000 |
commit | e6a56db2e62eeaa62ec6cfaa099298ba3356b9fd (patch) | |
tree | b5aec782243f9e01bc76d555438cad53e3334ad0 /clang/lib/Frontend/InitPreprocessor.cpp | |
parent | 6be9b25cb628f66b8c697182bcf2fd181a3784ad (diff) | |
download | bcm5719-llvm-e6a56db2e62eeaa62ec6cfaa099298ba3356b9fd.tar.gz bcm5719-llvm-e6a56db2e62eeaa62ec6cfaa099298ba3356b9fd.zip |
Reject uses of __int128 on platforms that don't support it. Also move the ugly
'getPointerWidth(0) >= 64' test to be a method on TargetInfo, ready to be
properly cleaned up.
llvm-svn: 168856
Diffstat (limited to 'clang/lib/Frontend/InitPreprocessor.cpp')
-rw-r--r-- | clang/lib/Frontend/InitPreprocessor.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/Frontend/InitPreprocessor.cpp b/clang/lib/Frontend/InitPreprocessor.cpp index 4bbd033f1c2..7da73532782 100644 --- a/clang/lib/Frontend/InitPreprocessor.cpp +++ b/clang/lib/Frontend/InitPreprocessor.cpp @@ -507,6 +507,8 @@ static void InitializePredefinedMacros(const TargetInfo &TI, TI.getTypeWidth(TI.getWCharType()), TI, Builder); DefineTypeSizeof("__SIZEOF_WINT_T__", TI.getTypeWidth(TI.getWIntType()), TI, Builder); + if (TI.hasInt128Type()) + DefineTypeSizeof("__SIZEOF_INT128__", 128, TI, Builder); DefineType("__INTMAX_TYPE__", TI.getIntMaxType(), Builder); DefineType("__UINTMAX_TYPE__", TI.getUIntMaxType(), Builder); |