Otherwise it fires for every single file which includes the header,
which is very noisy when building.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
This looks sensible to me. If the size of SymbolUnion is changed then Symbols.cpp will be recompiled so we'll always get the assertion if it is only changed.
lld/ELF/Symbols.h | ||
---|---|---|
478 | I think it will be worth moving the majority of the comment here as this is where someone will look when trying to modify SymbolUnion. For example: // It is important to keep the size of SymbolUnion small for performance and // memory usage reasons. 64 bytes is a soft limit based on the size of Defined // on a 64-bit system. This is enforced by a static_assert in Symbols.cpp. Not a strong opinion, just a suggestion. |
lld/ELF/Symbols.h | ||
---|---|---|
478 | Good idea, thanks. I also belatedly noticed that the other assertions would have the same issue, so I moved them as well. |
I think it will be worth moving the majority of the comment here as this is where someone will look when trying to modify SymbolUnion.
For example:
Not a strong opinion, just a suggestion.