summaryrefslogtreecommitdiffstats
path: root/clang/AST/SemaDecl.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-01-29 05:24:35 +0000
committerChris Lattner <sabre@nondot.org>2007-01-29 05:24:35 +0000
commit10a5b387cc5c4856356b7a3354f053895a275d01 (patch)
treeec4720cee869c1a1bccdac8c5f288a7f52ca3bd5 /clang/AST/SemaDecl.cpp
parent9561a0b3e7d65522086d703c170e6b0e41edf02a (diff)
downloadbcm5719-llvm-10a5b387cc5c4856356b7a3354f053895a275d01.tar.gz
bcm5719-llvm-10a5b387cc5c4856356b7a3354f053895a275d01.zip
Add support for target-specific builtins, including detecting nonportability
of source code. For example: $ clang INPUTS/carbon_h.c -arch i386 -arch ppc prints: ... /usr/lib/gcc/i686-apple-darwin8/4.0.1/include/mmintrin.h:51:3: note: use of a target-specific builtin function, source is not 'portable' __builtin_ia32_emms (); ^ because carbon.h pulls in xmmintrin.h, and __builtin_ia32_emms isn't a builtin on ppc. Though clang now supports target-specific builtins, the full table isn't implemented yet. llvm-svn: 39328
Diffstat (limited to 'clang/AST/SemaDecl.cpp')
-rw-r--r--clang/AST/SemaDecl.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/AST/SemaDecl.cpp b/clang/AST/SemaDecl.cpp
index 0d7e865ad2d..e339f167e3f 100644
--- a/clang/AST/SemaDecl.cpp
+++ b/clang/AST/SemaDecl.cpp
@@ -109,7 +109,7 @@ Decl *Sema::LookupScopedDecl(IdentifierInfo *II, unsigned NSI,
Decl *Sema::LazilyCreateBuiltin(IdentifierInfo *II, unsigned bid, Scope *S) {
Builtin::ID BID = (Builtin::ID)bid;
- TypeRef R = Builtin::GetBuiltinType(BID, Context);
+ TypeRef R = Context.BuiltinInfo.GetBuiltinType(BID, Context);
FunctionDecl *New = new FunctionDecl(SourceLocation(), II, R);
// Find translation-unit scope to insert this function into.
OpenPOWER on IntegriCloud