[llvm-commits] [llvm-gcc-4.2] r94023 - /llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
Devang Patel
dpatel at apple.com
Wed Jan 20 13:04:50 PST 2010
Author: dpatel
Date: Wed Jan 20 15:04:49 2010
New Revision: 94023
URL: http://llvm.org/viewvc/llvm-project?rev=94023&view=rev
Log:
Check if BINFO_OFFSET(BInfo) is zero or not.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
Modified: llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp?rev=94023&r1=94022&r2=94023&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-debug.cpp Wed Jan 20 15:04:49 2010
@@ -869,12 +869,17 @@
BFlags |= llvm::DIType::FlagPrivate;
}
+ // Check for zero BINFO_OFFSET.
+ // FIXME : Is this correct ?
+ unsigned Offset = BINFO_OFFSET(BInfo) ?
+ getINTEGER_CSTVal(BINFO_OFFSET(BInfo))*8 : 0;
+
// FIXME : name, size, align etc...
DIType DTy =
DebugFactory.CreateDerivedType(DW_TAG_inheritance,
findRegion(TYPE_CONTEXT(type)), StringRef(),
llvm::DICompileUnit(), 0,0,0,
- getINTEGER_CSTVal(BINFO_OFFSET(BInfo))*8,
+ Offset,
BFlags, BaseClass);
EltTys.push_back(DTy);
}
More information about the llvm-commits
mailing list