[llvm-commits] [dragonegg] r115762 - /dragonegg/trunk/llvm-convert.cpp
Duncan Sands
baldrick at free.fr
Wed Oct 6 00:11:25 PDT 2010
Author: baldrick
Date: Wed Oct 6 02:11:25 2010
New Revision: 115762
URL: http://llvm.org/viewvc/llvm-project?rev=115762&view=rev
Log:
Port commit 104523 (stuart) from llvm-gcc:
Fix and off-by-one bug in bitfield handling. Radar 7980096.
Modified:
dragonegg/trunk/llvm-convert.cpp
Modified: dragonegg/trunk/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/llvm-convert.cpp?rev=115762&r1=115761&r2=115762&view=diff
==============================================================================
--- dragonegg/trunk/llvm-convert.cpp (original)
+++ dragonegg/trunk/llvm-convert.cpp Wed Oct 6 02:11:25 2010
@@ -5553,7 +5553,7 @@
// adjust FieldPtr so that it is close enough to the bitfield that
// *FieldPtr contains the first needed bit. Be careful to make sure that
// the pointer remains appropriately aligned.
- if (BitStart > LLVMValueBitSize) {
+ if (BitStart >= LLVMValueBitSize) {
// In this case, we know that the alignment of the field is less than
// the size of the field. To get the pointer close enough, add some
// number of alignment units to the pointer.
More information about the llvm-commits
mailing list