| Summary: | UnlinkedCodeBlock should have better accounting for extra memory | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Keith Miller <keith_miller> | ||||||
| Component: | New Bugs | Assignee: | Keith Miller <keith_miller> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | ews-watchlist, mark.lam, msaboff, saam, tzagallo, webkit-bug-importer, ysuzuki | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | WebKit Nightly Build | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Keith Miller
2021-04-26 16:28:23 PDT
Created attachment 427101 [details]
Patch
Comment on attachment 427101 [details]
Patch
r=me
Comment on attachment 427101 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=427101&action=review > Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.cpp:119 > +size_t UnlinkedCodeBlock::RareData::sizeInBytes() const Let's take a locker parameter to ensure that this is accessed while taking a lock. Comment on attachment 427101 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=427101&action=review >> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.cpp:119 >> +size_t UnlinkedCodeBlock::RareData::sizeInBytes() const > > Let's take a locker parameter to ensure that this is accessed while taking a lock. And can you ensure that these fields are initialized while taking a lock? Comment on attachment 427101 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=427101&action=review >>> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.cpp:119 >>> +size_t UnlinkedCodeBlock::RareData::sizeInBytes() const >> >> Let's take a locker parameter to ensure that this is accessed while taking a lock. > > And can you ensure that these fields are initialized while taking a lock? Done, and it did look like there were a few places where the initializer was not holding the lock... I fixed those. Created attachment 427105 [details]
Patch for landing
Committed r276625 (237053@main): <https://commits.webkit.org/237053@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 427105 [details]. |