[PATCH] D91270: [Clang][CodeGen][RISCV] Fix hard float ABI test cases with empty struct
Sam Elliott via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 30 15:35:27 PST 2020
lenary added a reviewer: jrtc27.
lenary added a comment.
I *think* this is looking good, but I'd like a second pair of eyes from @jrtc27 as I know she's fixed bugs around this area recently too. We would like to have this ready for 11.0.1 if possible.
================
Comment at: clang/lib/CodeGen/TargetInfo.cpp:10603
CharUnits::fromQuantity(getDataLayout().getABITypeAlignment(Field2Ty));
- CharUnits Field1Size =
- CharUnits::fromQuantity(getDataLayout().getTypeStoreSize(Field1Ty));
- CharUnits Field2OffNoPadNoPack = Field1Size.alignTo(Field2Align);
+ CharUnits Field1EffectiveSize =
+ CharUnits::fromQuantity(getDataLayout().getTypeStoreSize(Field1Ty)) +
----------------
Please may you update this name to reflect what it really is - the offset of the *end* of Field1, rather than its size. This code is complex enough without confusing names. :)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91270/new/
https://reviews.llvm.org/D91270
More information about the cfe-commits
mailing list