[Lldb-commits] [PATCH] D85376: Fix how ValueObjectChild handles bit-fields stored in a Scalar in UpdateValue()

Shafik Yaghmour via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Aug 5 16:59:38 PDT 2020

shafik created this revision.
shafik added reviewers: aprantl, jingham, vsk.
shafik requested review of this revision.
Herald added a reviewer: jdoerfert.
Herald added a subscriber: sstefan1.

When bit-field data was stored in a `Scalar` in `ValueObjectChild` during `UpdateValue()` it was extracting the bit-field value. Later on in `lldb_private::DumpDataExtractor(…)` we were again attempting to extract the bit-field:

  s->Printf("%" PRIu64,
              DE.GetMaxU64Bitfield(&offset, item_byte_size, item_bit_size,

which would then not obtain the correct value. This will remove the extra extraction in `UpdateValue()`.

We hit this specific case when values are passed in registers, which we could only reproduce in an optimized build.



-------------- next part --------------
A non-text attachment was scrubbed...
Name: D85376.283288.patch
Type: text/x-patch
Size: 30951 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20200805/be94e47e/attachment-0001.bin>

More information about the lldb-commits mailing list