Reduce allocations in DatabaseUtilities::sortedTables
Created attachment 439561 [details] Patch
Comment on attachment 439561 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=439561&action=review > Source/WebKit/NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:276 > +Span<const ASCIILiteral> ResourceLoadStatisticsDatabaseStore::sortedTables() Why return a span and not a const std::array<ASCIILiteral>& ?
Because they have different sizes. std::array has a template parameter that is its size, so they would return different types.
Committed r283227 (242269@main): <https://commits.webkit.org/242269@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 439561 [details].
<rdar://problem/83674449>
Comment on attachment 439561 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=439561&action=review > Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp:116 > + static std::array sortedTables { Why not constexpr?
Comment on attachment 439561 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=439561&action=review >> Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp:116 >> + static std::array sortedTables { > > Why not constexpr? indeed. That could be added. I missed that.