diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2009-03-26 19:10:36 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2009-03-26 19:10:36 +0000 |
commit | dac14a7159c33e8ca27970b0a9ad004f0bfcdb66 (patch) | |
tree | c56f3d61b461b5b0d84378427d19f387bad79c28 | |
parent | 904f14663d6aa6354d7772dc7bce563b9aa18035 (diff) | |
download | bcm5719-llvm-dac14a7159c33e8ca27970b0a9ad004f0bfcdb66.tar.gz bcm5719-llvm-dac14a7159c33e8ca27970b0a9ad004f0bfcdb66.zip |
- Minor change to dump of ivar layout map.
- Temporarily undef'ed __OBJC2__ in nonfragile objc abi mode
as it was forcing ivar synthesis in a certain project which clang
does not yet support.
llvm-svn: 67766
-rw-r--r-- | clang/lib/CodeGen/CGObjCMac.cpp | 5 | ||||
-rw-r--r-- | clang/lib/Lex/Preprocessor.cpp | 4 |
2 files changed, 8 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGObjCMac.cpp b/clang/lib/CodeGen/CGObjCMac.cpp index f8393742429..c15c3bb1e7d 100644 --- a/clang/lib/CodeGen/CGObjCMac.cpp +++ b/clang/lib/CodeGen/CGObjCMac.cpp @@ -2918,7 +2918,10 @@ llvm::Constant *CGObjCCommonMac::BuildIvarLayout( printf("\nweak ivar layout: "); const unsigned char *s = (unsigned char*)BitMap.c_str(); for (unsigned i = 0; i < BitMap.size(); i++) - printf("0x%x ", s[i]); + if (!(s[i] & 0xf0)) + printf("0x0%x%s", s[i], s[i] != 0 ? ", " : ""); + else + printf("0x%x%s", s[i], s[i] != 0 ? ", " : ""); printf("\n"); return getConstantGEP(Entry, 0, 0); diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp index a43bb6427e9..a37b28b2b1d 100644 --- a/clang/lib/Lex/Preprocessor.cpp +++ b/clang/lib/Lex/Preprocessor.cpp @@ -497,8 +497,12 @@ static void InitializePredefinedMacros(Preprocessor &PP, if (PP.getLangOptions().ObjC1) { DefineBuiltinMacro(Buf, "__OBJC__=1"); +#if 0 +// FIXME. This flag controls declaration of ivars which is +// needed since we do not support synthesize ivars yet. if (PP.getLangOptions().ObjCNonFragileABI) DefineBuiltinMacro(Buf, "__OBJC2__=1"); +#endif if (PP.getLangOptions().getGCMode() == LangOptions::NonGC) { DefineBuiltinMacro(Buf, "__weak="); |