sconstab added inline comments.
================ Comment at: llvm/lib/Target/X86/ImmutableGraph.h:285 + std::unique_ptr<Edge[]> Edges; + size_type EdgesSize; +}; ---------------- @craig.topper It now occurs to me that these fields should probably be reordered to: ``` std::unique_ptr<Node[]> Nodes; std::unique_ptr<Edge[]> Edges; size_type NodesSize; size_type EdgesSize; ``` The current ordering will cause internal fragmentation. Old ordering: ``` static_assert(sizeof(ImmutableGraph<T, V>) == 32); ``` New ordering: ``` static_assert(sizeof(ImmutableGraph<T, V>) == 24); ``` With vectors instead of arrays: ``` static_assert(sizeof(ImmutableGraph<T, V>) == 48); ``` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D75936/new/ https://reviews.llvm.org/D75936 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits