Changeset 230515 in webkit


Ignore:
Timestamp:
Apr 10, 2018 9:57:43 PM (6 years ago)
Author:
sbarati@apple.com
Message:

IsoHeapImpl::scavenge* needs to grab the lock
https://bugs.webkit.org/show_bug.cgi?id=184461

Reviewed by Filip Pizlo.

Another thread could be modifying the linked list that the scavenge* methods traverse.

  • bmalloc/IsoHeapImplInlines.h:

(bmalloc::IsoHeapImpl<Config>::scavenge):
(bmalloc::IsoHeapImpl<Config>::scavengeToHighWatermark):

Location:
trunk/Source/bmalloc
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/bmalloc/ChangeLog

    r230501 r230515  
     12018-04-10  Saam Barati  <sbarati@apple.com>
     2
     3        IsoHeapImpl::scavenge* needs to grab the lock
     4        https://bugs.webkit.org/show_bug.cgi?id=184461
     5
     6        Reviewed by Filip Pizlo.
     7
     8        Another thread could be modifying the linked list that the scavenge* methods traverse.
     9
     10        * bmalloc/IsoHeapImplInlines.h:
     11        (bmalloc::IsoHeapImpl<Config>::scavenge):
     12        (bmalloc::IsoHeapImpl<Config>::scavengeToHighWatermark):
     13
    1142018-04-10  Saam Barati  <sbarati@apple.com>
    215
  • trunk/Source/bmalloc/bmalloc/IsoHeapImplInlines.h

    r230501 r230515  
    102102void IsoHeapImpl<Config>::scavenge(Vector<DeferredDecommit>& decommits)
    103103{
     104    std::lock_guard<Mutex> locker(this->lock);
    104105    forEachDirectory(
    105106        [&] (auto& directory) {
     
    112113void IsoHeapImpl<Config>::scavengeToHighWatermark(Vector<DeferredDecommit>& decommits)
    113114{
     115    std::lock_guard<Mutex> locker(this->lock);
    114116    if (!m_directoryHighWatermark)
    115117        m_inlineDirectory.scavengeToHighWatermark(decommits);
Note: See TracChangeset for help on using the changeset viewer.