Changeset 240370 in webkit
- Timestamp:
- Jan 23, 2019 5:17:46 PM (5 years ago)
- Location:
- trunk/Source
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r240364 r240370 1 2019-01-23 Mark Lam <mark.lam@apple.com> 2 3 ARM64E should not ENABLE(SEPARATED_WX_HEAP). 4 https://bugs.webkit.org/show_bug.cgi?id=193744 5 <rdar://problem/46262952> 6 7 Reviewed by Saam Barati. 8 9 * assembler/LinkBuffer.cpp: 10 (JSC::LinkBuffer::copyCompactAndLinkCode): 11 1 12 2019-01-23 Yusuke Suzuki <ysuzuki@apple.com> 2 13 -
trunk/Source/JavaScriptCore/assembler/LinkBuffer.cpp
r239364 r240370 1 1 /* 2 * Copyright (C) 2012-201 8Apple Inc. All rights reserved.2 * Copyright (C) 2012-2019 Apple Inc. All rights reserved. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 42 42 namespace JSC { 43 43 44 #if ENABLE(SEPARATED_WX_HEAP)45 extern JS_EXPORT_PRIVATE bool useFastPermisionsJITCopy;46 #endif // ENABLE(SEPARATED_WX_HEAP)47 48 44 bool shouldDumpDisassemblyFor(CodeBlock* codeBlock) 49 45 { … … 121 117 void LinkBuffer::copyCompactAndLinkCode(MacroAssembler& macroAssembler, void* ownerUID, JITCompilationEffort effort) 122 118 { 123 #if CPU(ARM64E) && ENABLE(FAST_JIT_PERMISSIONS)124 #if ENABLE(SEPARATED_WX_HEAP)125 const bool isUsingFastPermissionsJITCopy = useFastPermisionsJITCopy;126 #else127 const bool isUsingFastPermissionsJITCopy = true;128 #endif129 #endif130 131 119 allocate(macroAssembler, ownerUID, effort); 132 120 const size_t initialSize = macroAssembler.m_assembler.codeSize(); … … 143 131 ARM64EHash verifyUncompactedHash; 144 132 uint8_t* outData = codeOutData; 145 #if ENABLE(SEPARATED_WX_HEAP)146 AssemblerData outBuffer(m_size);147 if (!isUsingFastPermissionsJITCopy)148 outData = reinterpret_cast<uint8_t*>(outBuffer.buffer());149 #endif // ENABLE(SEPARATED_WX_HEAP)150 133 #else 151 134 AssemblerData outBuffer(m_size); … … 162 145 163 146 #if CPU(ARM64E) && ENABLE(FAST_JIT_PERMISSIONS) 164 if (isUsingFastPermissionsJITCopy) 165 os_thread_self_restrict_rwx_to_rw(); 147 os_thread_self_restrict_rwx_to_rw(); 166 148 #endif 167 149 … … 250 232 #if CPU(ARM64E) && ENABLE(FAST_JIT_PERMISSIONS) 251 233 auto memcpyFunction = memcpy; 252 if (!isUsingFastPermissionsJITCopy)253 memcpyFunction = performJITMemcpy;254 234 #else 255 235 auto memcpyFunction = performJITMemcpy; … … 268 248 269 249 #if CPU(ARM64E) && ENABLE(FAST_JIT_PERMISSIONS) 270 if (isUsingFastPermissionsJITCopy) 271 os_thread_self_restrict_rwx_to_rx(); 250 os_thread_self_restrict_rwx_to_rx(); 272 251 #endif 273 252 … … 281 260 performJITMemcpy(codeOutData, outData, m_size); 282 261 #else 283 if (isUsingFastPermissionsJITCopy) 284 ASSERT(codeOutData == outData); 285 else { 286 ASSERT(codeOutData != outData); 287 performJITMemcpy(codeOutData, outData, m_size); 288 } 262 ASSERT(codeOutData == outData); 289 263 #endif 290 264 -
trunk/Source/WTF/ChangeLog
r240332 r240370 1 2019-01-23 Mark Lam <mark.lam@apple.com> 2 3 ARM64E should not ENABLE(SEPARATED_WX_HEAP). 4 https://bugs.webkit.org/show_bug.cgi?id=193744 5 <rdar://problem/46262952> 6 7 Reviewed by Saam Barati. 8 9 * wtf/Platform.h: 10 1 11 2019-01-23 David Kilzer <ddkilzer@apple.com> 2 12 -
trunk/Source/WTF/wtf/Platform.h
r240181 r240370 1 1 /* 2 * Copyright (C) 2006-201 8Apple Inc. All rights reserved.2 * Copyright (C) 2006-2019 Apple Inc. All rights reserved. 3 3 * Copyright (C) 2007-2009 Torch Mobile, Inc. 4 4 * Copyright (C) 2010, 2011 Research In Motion Limited. All rights reserved. … … 959 959 #endif 960 960 961 #ifndef ENABLE_SEPARATED_WX_HEAP 962 #if (!ENABLE(FAST_JIT_PERMISSIONS) || !CPU(ARM64E)) && PLATFORM(IOS_FAMILY) && CPU(ARM64) 961 #if PLATFORM(IOS_FAMILY) && CPU(ARM64) && (!ENABLE(FAST_JIT_PERMISSIONS) || !CPU(ARM64E)) 963 962 #define ENABLE_SEPARATED_WX_HEAP 1 964 963 #else 965 964 #define ENABLE_SEPARATED_WX_HEAP 0 966 #endif967 965 #endif 968 966
Note: See TracChangeset
for help on using the changeset viewer.