[PATCH] D152157: [AppleAccelTable] Keep track of the size of each hash data entry

Felipe de Azevedo Piovezan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 6 04:22:01 PDT 2023


fdeazeve added inline comments.


================
Comment at: llvm/include/llvm/DebugInfo/DWARF/DWARFAcceleratorTable.h:109
   dwarf::FormParams FormParams;
+  uint32_t HashDataEntryLength;
   bool IsValid = false;
----------------
aprantl wrote:
> should this be default-initialized?
I believe the design of this class is that it should not be used until `IsValid` is set to true, and `IsValid` is only set to true after all of its members are initialized.

We could clean this up by moving away from the declare(ctor)-then-initialize (`extract`) anti-pattern, instead making sure the constructor does all the way


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D152157/new/

https://reviews.llvm.org/D152157



More information about the llvm-commits mailing list