mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 17:24:48 +00:00
While calculating original type size for a derived type, handle type variants encoded as DIDerivedType appropriately.
This improves bitfield support. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86073 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -1141,9 +1141,7 @@ DIE *DwarfDebug::CreateMemberDIE(CompileUnit *DW_Unit, const DIDerivedType &DT){
|
||||
AddUInt(MemLocationDie, 0, dwarf::DW_FORM_data1, dwarf::DW_OP_plus_uconst);
|
||||
|
||||
uint64_t Size = DT.getSizeInBits();
|
||||
uint64_t FieldSize = Size;
|
||||
if (DT.getTypeDerivedFrom().getTag() != dwarf::DW_TAG_array_type)
|
||||
FieldSize = DT.getOriginalTypeSize();
|
||||
uint64_t FieldSize = DT.getOriginalTypeSize();
|
||||
|
||||
if (Size != FieldSize) {
|
||||
// Handle bitfield.
|
||||
|
Reference in New Issue
Block a user