Changeset 48733 in webkit for trunk/JavaScriptCore


Ignore:
Timestamp:
Sep 24, 2009, 2:25:47 PM (16 years ago)
Author:
[email protected]
Message:

<rdar://problem/7215058> FastMalloc scavenging thread should be named

Reviewed by Sam Weinig.

  • wtf/FastMalloc.cpp:

(WTF::TCMalloc_PageHeap::scavengerThread): Set the thread name.

  • wtf/Platform.h: Move the knowledge of whether pthread_setname_np exists to here as HAVE(PTHREAD_SETNAME_NP).
  • wtf/ThreadingPthreads.cpp:

(WTF::setThreadNameInternal): Use HAVE(PTHREAD_SETNAME_NP).

Location:
trunk/JavaScriptCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/ChangeLog

    r48732 r48733  
     12009-09-24  Mark Rowe  <[email protected]>
     2
     3        Reviewed by Sam Weinig.
     4
     5        <rdar://problem/7215058> FastMalloc scavenging thread should be named
     6
     7        * wtf/FastMalloc.cpp:
     8        (WTF::TCMalloc_PageHeap::scavengerThread): Set the thread name.
     9        * wtf/Platform.h: Move the knowledge of whether pthread_setname_np exists to here as HAVE(PTHREAD_SETNAME_NP).
     10        * wtf/ThreadingPthreads.cpp:
     11        (WTF::setThreadNameInternal): Use HAVE(PTHREAD_SETNAME_NP).
     12
    1132009-09-24  Geoffrey Garen  <[email protected]>
    214
  • trunk/JavaScriptCore/wtf/FastMalloc.cpp

    r48731 r48733  
    22842284void TCMalloc_PageHeap::scavengerThread()
    22852285{
     2286#if HAVE(PTHREAD_SETNAME_NP)
     2287  pthread_setname_np("JavaScriptCore: FastMalloc scavenger");
     2288#endif
     2289
    22862290  while (1) {
    22872291      if (!shouldContinueScavenging()) {
  • trunk/JavaScriptCore/wtf/Platform.h

    r48685 r48733  
    496496#define HAVE_MADV_FREE_REUSE 1
    497497#define HAVE_MADV_FREE 1
     498#define HAVE_PTHREAD_SETNAME_NP 1
    498499#endif
    499500
  • trunk/JavaScriptCore/wtf/ThreadingPthreads.cpp

    r47979 r48733  
    187187void setThreadNameInternal(const char* threadName)
    188188{
    189 #if PLATFORM(DARWIN) && !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !PLATFORM(IPHONE)
     189#if HAVE(PTHREAD_SETNAME_NP)
    190190    pthread_setname_np(threadName);
    191191#else
Note: See TracChangeset for help on using the changeset viewer.