[llvm-commits] [llvm-gcc-4.2] r53624 - /llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Dale Johannesen
dalej at apple.com
Tue Jul 15 10:57:24 PDT 2008
Author: johannes
Date: Tue Jul 15 12:57:24 2008
New Revision: 53624
URL: http://llvm.org/viewvc/llvm-project?rev=53624&view=rev
Log:
Improve comment on my last checkin.
Modified:
llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
Modified: llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp?rev=53624&r1=53623&r2=53624&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp (original)
+++ llvm-gcc-4.2/trunk/gcc/llvm-convert.cpp Tue Jul 15 12:57:24 2008
@@ -5753,8 +5753,11 @@
} else {
Value *Offset = Emit(field_offset, 0);
- // For ObjC2, we may have a base class field that should not be taken into
- // account here, as it is already in Offset. The ObjC FE figures this out.
+ // For ObjC2, the offset of the field is loaded from memory (it can
+ // change at runtime), and the initial value in memory includes the
+ // value that would normally be computed at compile time; we don't
+ // want to add this in twice. The ObjC FE figures out the value we
+ // actually should add at compile time (usually 0).
tree field_bit_offset = objc_v2_bitfield_ivar_bitpos(exp);
if (field_bit_offset) {
BitStart = (unsigned)getINTEGER_CSTVal(field_bit_offset);
More information about the llvm-commits
mailing list