Changeset 270052 in webkit


Ignore:
Timestamp:
Nov 19, 2020 3:08:56 PM (3 years ago)
Author:
sbarati@apple.com
Message:

Use os_thread_self_restrict_rwx_is_supported instead of pthread_jit_write_protect_supported_np on Apple Internal SDK builds
https://bugs.webkit.org/show_bug.cgi?id=219099
<rdar://problem/71547048>

Reviewed by Mark Lam.

Source/JavaScriptCore:

  • assembler/FastJITPermissions.h:

(useFastJITPermissions):
(threadSelfRestrictRWXToRW):
(threadSelfRestrictRWXToRX):

Source/WTF:

  • wtf/PlatformHave.h:
  • wtf/PlatformUse.h:
Location:
trunk/Source
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r270043 r270052  
     12020-11-19  Saam Barati  <sbarati@apple.com>
     2
     3        Use os_thread_self_restrict_rwx_is_supported instead of pthread_jit_write_protect_supported_np on Apple Internal SDK builds
     4        https://bugs.webkit.org/show_bug.cgi?id=219099
     5        <rdar://problem/71547048>
     6
     7        Reviewed by Mark Lam.
     8
     9        * assembler/FastJITPermissions.h:
     10        (useFastJITPermissions):
     11        (threadSelfRestrictRWXToRW):
     12        (threadSelfRestrictRWXToRX):
     13
    1142020-11-19  Xan López  <xan@igalia.com>
    215
  • trunk/Source/JavaScriptCore/assembler/FastJITPermissions.h

    r263385 r270052  
    3030#include <wtf/Platform.h>
    3131
    32 #if HAVE(PTHREAD_JIT_PERMISSIONS_API)
     32#if USE(PTHREAD_JIT_PERMISSIONS_API)
    3333#include <pthread.h>
    3434#elif USE(APPLE_INTERNAL_SDK)
     
    4040#if CPU(ARM64E)
    4141    return true;
    42 #elif HAVE(PTHREAD_JIT_PERMISSIONS_API)
     42#elif USE(PTHREAD_JIT_PERMISSIONS_API)
    4343    return !!pthread_jit_write_protect_supported_np();
    4444#elif USE(APPLE_INTERNAL_SDK)
     
    5353    ASSERT(useFastJITPermissions());
    5454
    55 #if HAVE(PTHREAD_JIT_PERMISSIONS_API)
     55#if USE(PTHREAD_JIT_PERMISSIONS_API)
    5656    pthread_jit_write_protect_np(false);
    5757#elif USE(APPLE_INTERNAL_SDK)
     
    6868    ASSERT(useFastJITPermissions());
    6969
    70 #if HAVE(PTHREAD_JIT_PERMISSIONS_API)
     70#if USE(PTHREAD_JIT_PERMISSIONS_API)
    7171    pthread_jit_write_protect_np(true);
    7272#elif USE(APPLE_INTERNAL_SDK)
  • trunk/Source/WTF/ChangeLog

    r270013 r270052  
     12020-11-19  Saam Barati  <sbarati@apple.com>
     2
     3        Use os_thread_self_restrict_rwx_is_supported instead of pthread_jit_write_protect_supported_np on Apple Internal SDK builds
     4        https://bugs.webkit.org/show_bug.cgi?id=219099
     5        <rdar://problem/71547048>
     6
     7        Reviewed by Mark Lam.
     8
     9        * wtf/PlatformHave.h:
     10        * wtf/PlatformUse.h:
     11
    1122020-11-18  Yousuke Kimoto  <Yousuke.Kimoto@sony.com>
    213
  • trunk/Source/WTF/wtf/PlatformHave.h

    r269930 r270052  
    701701#define HAVE_LSDATABASECONTEXT 1
    702702#define HAVE_PRECONNECT_PING 1
    703 #define HAVE_PTHREAD_JIT_PERMISSIONS_API 1
    704703#define HAVE_WEBP 1
    705704#endif
  • trunk/Source/WTF/wtf/PlatformUse.h

    r269700 r270052  
    317317#define USE_JUMP_ISLANDS 1
    318318#endif
     319
     320#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 110000) \
     321    || (PLATFORM(MACCATALYST) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 140000)
     322#if USE(APPLE_INTERNAL_SDK)
     323/* Always use the macro on internal builds */
     324#define USE_PTHREAD_JIT_PERMISSIONS_API 0
     325#else
     326#define USE_PTHREAD_JIT_PERMISSIONS_API 1
     327#endif
     328#endif
Note: See TracChangeset for help on using the changeset viewer.