[PATCH] D144565: dwp check overflow
zhuna via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Apr 2 08:30:41 PDT 2023
zhuna8616 added inline comments.
================
Comment at: llvm/lib/DWP/DWP.cpp:237
+ uint32_t OldOffset = TypesOffset;
+ static_assert(sizeof(OldOffset == TypesOffset));
TypesOffset += C.getLength();
----------------
ayermolo wrote:
> I don't think this is the same as sizeof(OldOffset) == sizeof(TypesOffset)
Err... typos... My bad
================
Comment at: llvm/lib/DWP/DWP.cpp:861
+ if (Error Err =
+ addAllTypesFromDWP(Out, TypeIndexEntries, TUIndex, OutSection,
+ TypeInputSection, CurEntry,
----------------
ayermolo wrote:
> Is this because of tabs?
Is this a format issue? Should I make it like this:
```
if (Error Err = addAllTypesFromDWP(Out, TypeIndexEntries, TUIndex, OutSection,
TypeInputSection, CurEntry,
ContributionOffsets[TypesContributionIndex],
TypesContributionIndex))
```
Or should I add a tab to the left of `addAllTypesFromDWP`?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144565/new/
https://reviews.llvm.org/D144565
More information about the llvm-commits
mailing list