[Lldb-commits] [PATCH] Fix StdVBoolImplementation to handle large vectors

Tamas Berghammer tberghammer at google.com
Wed Mar 25 04:02:19 PDT 2015


REPOSITORY
  rL LLVM

http://reviews.llvm.org/D8585

Files:
  lldb/trunk/examples/synthetic/gnu_libstdcpp.py
  lldb/trunk/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py

Index: lldb/trunk/examples/synthetic/gnu_libstdcpp.py
===================================================================
--- lldb/trunk/examples/synthetic/gnu_libstdcpp.py
+++ lldb/trunk/examples/synthetic/gnu_libstdcpp.py
@@ -233,8 +233,9 @@
 				return None
 			byte_offset = index / 8
 			bit_offset = index % 8
-			data = self.start_p.GetPointeeData()
-			bit = data.GetUnsignedInt8(lldb.SBError(), byte_offset) & (1 << bit_offset)
+			element_size = self.start_p.GetType().GetPointeeType().GetByteSize()
+			data = self.start_p.GetPointeeData(byte_offset / element_size)
+			bit = data.GetUnsignedInt8(lldb.SBError(), byte_offset % element_size) & (1 << bit_offset)
 			if bit != 0:
 				value_expr = "(bool)true"
 			else:
Index: lldb/trunk/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py
===================================================================
--- lldb/trunk/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py
+++ lldb/trunk/test/functionalities/data-formatter/data-formatter-stl/libstdcpp/vbool/TestDataFormatterStdVBool.py
@@ -24,7 +24,6 @@
     @dwarf_test
     @skipIfWindows # http://llvm.org/pr21800
     @skipIfDarwin
-    @expectedFailurei386 #xfail to get buildbot green, failing config: i386 binary running on ubuntu 14.04 x86_64
     def test_with_dwarf_and_run_command(self):
         """Test data formatter commands."""
         self.buildDwarf()

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D8585.22634.patch
Type: text/x-patch
Size: 1481 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150325/2ac7dc09/attachment.bin>


More information about the lldb-commits mailing list