Bug 225840 - StructureRareData::m_replacementWatchpointSets should not be a pointer to a pointer
Summary: StructureRareData::m_replacementWatchpointSets should not be a pointer to a p...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Geoffrey Garen
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-05-14 20:37 PDT by Geoffrey Garen
Modified: 2021-05-21 16:23 PDT (History)
11 users (show)

See Also:


Attachments
Patch (3.83 KB, patch)
2021-05-14 20:38 PDT, Geoffrey Garen
mark.lam: review+
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch for landing (3.96 KB, patch)
2021-05-17 16:22 PDT, Geoffrey Garen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Geoffrey Garen 2021-05-14 20:37:00 PDT
StructureRareData::m_replacementWatchpointSets should not be a pointer t o a pointer
Comment 1 Geoffrey Garen 2021-05-14 20:38:49 PDT
Created attachment 428705 [details]
Patch
Comment 2 Mark Lam 2021-05-14 20:47:28 PDT
Comment on attachment 428705 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=428705&action=review

r=me

> Source/JavaScriptCore/runtime/StructureRareData.h:130
>      typedef HashMap<PropertyOffset, RefPtr<WatchpointSet>, WTF::IntHash<PropertyOffset>, WTF::UnsignedWithZeroKeyHashTraits<PropertyOffset>> PropertyWatchpointMap;

nit: maybe add `static_assert(sizeof(PropertyWatchpointMap) == sizeof(void*));` after this line?
Comment 3 Geoffrey Garen 2021-05-17 16:22:40 PDT
Created attachment 428888 [details]
Patch for landing
Comment 4 Geoffrey Garen 2021-05-17 16:23:11 PDT
Comment on attachment 428888 [details]
Patch for landing

CQ+
Comment 5 EWS 2021-05-17 17:42:08 PDT
Committed r277620 (237835@main): <https://commits.webkit.org/237835@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 428888 [details].
Comment 6 Radar WebKit Bug Importer 2021-05-17 17:43:25 PDT
<rdar://problem/78130993>
Comment 7 Darin Adler 2021-05-17 18:54:35 PDT
Maybe HashMap should make itself allergic to allocation on the heap. It does WTF_MAKE_FAST_ALLOCATED, but it should be WTF_MAKE_DONT_DO_IT_DONT_PUT_ME_IN_A_HEAP_BLOCK_ALL_BY_MYSELF. Same for HashTableConstIterator, HashTableIterator, HashTable, HashSet, and ListHashSet. All of these are so small it is silly to put them on the heap, I think.
Comment 8 Darin Adler 2021-05-19 14:35:16 PDT
Working on this in bug 225984.