Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Refactoring: Rename ScrambledPtr to Poisoned.
https://bugs.webkit.org/show_bug.cgi?id=180514 Reviewed by Saam Barati. Source/JavaScriptCore: * API/JSCallbackObject.h: * API/JSObjectRef.cpp: (classInfoPrivate): * JavaScriptCore.xcodeproj/project.pbxproj: * Sources.txt: * assembler/MacroAssemblerCodeRef.h: (JSC::FunctionPtr::FunctionPtr): (JSC::FunctionPtr::value const): (JSC::FunctionPtr::executableAddress const): (JSC::ReturnAddressPtr::ReturnAddressPtr): (JSC::ReturnAddressPtr::value const): (JSC::MacroAssemblerCodePtr::MacroAssemblerCodePtr): (JSC::MacroAssemblerCodePtr::createFromExecutableAddress): (JSC::MacroAssemblerCodePtr::poisonedPtr const): (JSC::MacroAssemblerCodePtr:: const): (JSC::MacroAssemblerCodePtr::operator! const): (JSC::MacroAssemblerCodePtr::operator== const): (JSC::MacroAssemblerCodePtr::emptyValue): (JSC::MacroAssemblerCodePtr::deletedValue): (JSC::MacroAssemblerCodePtr::scrambledPtr const): Deleted. * b3/B3LowerMacros.cpp: * b3/testb3.cpp: (JSC::B3::testInterpreter): * dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::checkArray): (JSC::DFG::SpeculativeJIT::compileCheckSubClass): (JSC::DFG::SpeculativeJIT::compileNewStringObject): (JSC::DFG::SpeculativeJIT::emitSwitchIntJump): * ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileNewStringObject): (JSC::FTL::DFG::LowerDFGToB3::compileCheckSubClass): * jit/AssemblyHelpers.h: (JSC::AssemblyHelpers::emitAllocateDestructibleObject): * jit/SpecializedThunkJIT.h: (JSC::SpecializedThunkJIT::loadArgumentWithSpecificClass): * jit/ThunkGenerators.cpp: (JSC::virtualThunkFor): (JSC::boundThisNoArgsFunctionCallGenerator): * llint/LLIntSlowPaths.cpp: (JSC::LLInt::handleHostCall): (JSC::LLInt::setUpCall): * llint/LowLevelInterpreter64.asm: * runtime/InitializeThreading.cpp: (JSC::initializeThreading): * runtime/JSCPoisonedPtr.cpp: Copied from Source/JavaScriptCore/runtime/JSCScrambledPtr.cpp. (JSC::initializePoison): (JSC::initializeScrambledPtrKeys): Deleted. * runtime/JSCPoisonedPtr.h: Copied from Source/JavaScriptCore/runtime/JSCScrambledPtr.h. * runtime/JSCScrambledPtr.cpp: Removed. * runtime/JSCScrambledPtr.h: Removed. * runtime/JSDestructibleObject.h: (JSC::JSDestructibleObject::classInfo const): * runtime/JSSegmentedVariableObject.h: (JSC::JSSegmentedVariableObject::classInfo const): * runtime/Structure.h: * runtime/VM.h: Source/WTF: We're switching our nomenclature to "poisoning" instead of "scrambling" pointers. This allows us to use shorter names. This patch is almost purely refactoring, except for one change: the PoisonedImpl template class (previously ScrambledPtr) has been modified to allow usage of a constexpr uint32_t poison value (see Int32Poisoned) in addition to a runtime determined uintptr_t poison value (see Poisoned). * WTF.xcodeproj/project.pbxproj: * wtf/CMakeLists.txt: * wtf/Poisoned.cpp: Copied from Source/WTF/wtf/ScrambledPtr.cpp. (WTF::makePoison): (WTF::makeScrambledPtrKey): Deleted. * wtf/Poisoned.h: Copied from Source/WTF/wtf/ScrambledPtr.h. (WTF::PoisonedImpl::PoisonedImpl): (WTF::PoisonedImpl::assertIsPoisoned const): (WTF::PoisonedImpl::assertIsNotPoisoned const): (WTF::PoisonedImpl::unpoisoned const): (WTF::PoisonedImpl::operator-> const): (WTF::PoisonedImpl::bits const): (WTF::PoisonedImpl::operator! const): (WTF::PoisonedImpl::operator bool const): (WTF::PoisonedImpl::operator== const): (WTF::PoisonedImpl::operator==): (WTF::PoisonedImpl::operator=): (WTF::PoisonedImpl::poison): (WTF::PoisonedImpl::unpoison): (WTF::ScrambledPtr::ScrambledPtr): Deleted. (WTF::ScrambledPtr::assertIsScrambled const): Deleted. (WTF::ScrambledPtr::assertIsNotScrambled const): Deleted. (WTF::ScrambledPtr::descrambled const): Deleted. (WTF::ScrambledPtr::operator-> const): Deleted. (WTF::ScrambledPtr::bits const): Deleted. (WTF::ScrambledPtr::operator! const): Deleted. (WTF::ScrambledPtr::operator bool const): Deleted. (WTF::ScrambledPtr::operator== const): Deleted. (WTF::ScrambledPtr::operator==): Deleted. (WTF::ScrambledPtr::operator=): Deleted. (WTF::ScrambledPtr::scramble): Deleted. (WTF::ScrambledPtr::descramble): Deleted. * wtf/ScrambledPtr.cpp: Removed. * wtf/ScrambledPtr.h: Removed. Canonical link: https://commits.webkit.org/196440@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225620 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
with
368 additions
and 243 deletions.
- +2 −2 Source/JavaScriptCore/API/JSCallbackObject.h
- +1 −1 Source/JavaScriptCore/API/JSObjectRef.cpp
- +64 −0 Source/JavaScriptCore/ChangeLog
- +6 −6 Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
- +1 −1 Source/JavaScriptCore/Sources.txt
- +45 −45 Source/JavaScriptCore/assembler/MacroAssemblerCodeRef.h
- +3 −3 Source/JavaScriptCore/b3/B3LowerMacros.cpp
- +3 −3 Source/JavaScriptCore/b3/testb3.cpp
- +7 −7 Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp
- +3 −3 Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp
- +1 −1 Source/JavaScriptCore/jit/AssemblyHelpers.h
- +1 −1 Source/JavaScriptCore/jit/SpecializedThunkJIT.h
- +2 −2 Source/JavaScriptCore/jit/ThunkGenerators.cpp
- +4 −4 Source/JavaScriptCore/llint/LLIntSlowPaths.cpp
- +1 −1 Source/JavaScriptCore/llint/LowLevelInterpreter64.asm
- +1 −1 Source/JavaScriptCore/runtime/InitializeThreading.cpp
- +6 −6 Source/JavaScriptCore/runtime/{JSCScrambledPtr.cpp → JSCPoisonedPtr.cpp}
- +6 −6 Source/JavaScriptCore/runtime/{JSCScrambledPtr.h → JSCPoisonedPtr.h}
- +2 −2 Source/JavaScriptCore/runtime/JSDestructibleObject.h
- +2 −2 Source/JavaScriptCore/runtime/JSSegmentedVariableObject.h
- +2 −2 Source/JavaScriptCore/runtime/Structure.h
- +1 −1 Source/JavaScriptCore/runtime/VM.h
- +50 −0 Source/WTF/ChangeLog
- +6 −6 Source/WTF/WTF.xcodeproj/project.pbxproj
- +2 −2 Source/WTF/wtf/CMakeLists.txt
- +6 −6 Source/WTF/wtf/{ScrambledPtr.cpp → Poisoned.cpp}
- +140 −0 Source/WTF/wtf/Poisoned.h
- +0 −129 Source/WTF/wtf/ScrambledPtr.h
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.