Michael137 wrote:

> The correct answer here is probably to fix the sizes in the RecordLayout 
> itself; in particular, the DataSize of the members.
That would be ideal, but also means we'd have to reflect the various C++ 
attributes that affect layout in DWARF. Avoiding adding such language-specific 
constructs to DWARF is what partly motivated this patch. 

> We should trust external record layout to the extent that it generates a 
> valid layout, but if it generates something with overlapping fields, or that 
> runs outside the claimed bounds of the type, we'll just end up crashing in 
> IRGen. I assume those things are expressible in DWARF;

Yea the idea was that we catch these malformed DWARF representations elsewhere. 
Not necessarily relying on the record layout layer to tell us about this. Not 
sure how equipped LLDB currently is in dealing with corrupted DWARF.


https://github.com/llvm/llvm-project/pull/93809
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to