Title: [229447] trunk/Source
Revision
229447
Author
[email protected]
Date
2018-03-08 18:16:27 -0800 (Thu, 08 Mar 2018)

Log Message

Unreviewed, rolling out r229354 and r229364.
https://bugs.webkit.org/show_bug.cgi?id=183492

Breaks internal builds (Requested by ryanhaddad on #webkit).

Reverted changesets:

"Prepare LLInt code to support pointer profiling."
https://bugs.webkit.org/show_bug.cgi?id=183387
https://trac.webkit.org/changeset/229354

"Add support for ARM64E."
https://bugs.webkit.org/show_bug.cgi?id=183398
https://trac.webkit.org/changeset/229364

Patch by Commit Queue <[email protected]> on 2018-03-08

Modified Paths

Removed Paths

Diff

Modified: trunk/Source/_javascript_Core/CMakeLists.txt (229446 => 229447)


--- trunk/Source/_javascript_Core/CMakeLists.txt	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/CMakeLists.txt	2018-03-09 02:16:27 UTC (rev 229447)
@@ -838,7 +838,6 @@
     runtime/Operations.h
     runtime/Options.h
     runtime/ParseInt.h
-    runtime/PtrTag.h
     runtime/PrivateName.h
     runtime/ProgramExecutable.h
     runtime/PromiseDeferredTimer.h

Modified: trunk/Source/_javascript_Core/ChangeLog (229446 => 229447)


--- trunk/Source/_javascript_Core/ChangeLog	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/ChangeLog	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,3 +1,20 @@
+2018-03-08  Commit Queue  <[email protected]>
+
+        Unreviewed, rolling out r229354 and r229364.
+        https://bugs.webkit.org/show_bug.cgi?id=183492
+
+        Breaks internal builds (Requested by ryanhaddad on #webkit).
+
+        Reverted changesets:
+
+        "Prepare LLInt code to support pointer profiling."
+        https://bugs.webkit.org/show_bug.cgi?id=183387
+        https://trac.webkit.org/changeset/229354
+
+        "Add support for ARM64E."
+        https://bugs.webkit.org/show_bug.cgi?id=183398
+        https://trac.webkit.org/changeset/229364
+
 2018-03-08  Michael Saboff  <[email protected]>
 
         testmasm crashes in testBranchTruncateDoubleToInt32() on ARM64

Modified: trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj (229446 => 229447)


--- trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1767,7 +1767,6 @@
 		FE63DD541EA9B61E00103A69 /* Printer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE63DD531EA9B60E00103A69 /* Printer.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		FE6491371D78F01D00A694D4 /* ExceptionScope.h in Headers */ = {isa = PBXBuildFile; fileRef = FE6491361D78F01300A694D4 /* ExceptionScope.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		FE68C6371B90DE040042BCB3 /* MacroAssemblerPrinter.h in Headers */ = {isa = PBXBuildFile; fileRef = FE68C6361B90DDD90042BCB3 /* MacroAssemblerPrinter.h */; settings = {ATTRIBUTES = (Private, ); }; };
-		FE6C1E4A20366F0100BDC2B7 /* PtrTag.h in Headers */ = {isa = PBXBuildFile; fileRef = FE9AE1C82032C887002B6934 /* PtrTag.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		FE6F56DE1E64EAD600D17801 /* VMTraps.h in Headers */ = {isa = PBXBuildFile; fileRef = FE6F56DD1E64E92000D17801 /* VMTraps.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		FE7C41961B97FC4B00F4D598 /* PingPongStackOverflowTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = FEDA50D41B97F442009A3B4F /* PingPongStackOverflowTest.cpp */; };
 		FE80C1971D775CDD008510C0 /* CatchScope.h in Headers */ = {isa = PBXBuildFile; fileRef = FE80C1961D775B27008510C0 /* CatchScope.h */; settings = {ATTRIBUTES = (Private, ); }; };
@@ -4706,7 +4705,6 @@
 		FE98B5B61BB9AE110073E7A6 /* JITSubGenerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JITSubGenerator.h; sourceTree = "<group>"; };
 		FE99B2471C24B6D300C82159 /* JITNegGenerator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JITNegGenerator.cpp; sourceTree = "<group>"; };
 		FE99B2481C24B6D300C82159 /* JITNegGenerator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JITNegGenerator.h; sourceTree = "<group>"; };
-		FE9AE1C82032C887002B6934 /* PtrTag.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PtrTag.h; sourceTree = "<group>"; };
 		FEA0861E182B7A0400F6D851 /* Breakpoint.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Breakpoint.h; sourceTree = "<group>"; };
 		FEA0861F182B7A0400F6D851 /* DebuggerPrimitives.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DebuggerPrimitives.h; sourceTree = "<group>"; };
 		FEA0C4001CDD7D0E00481991 /* FunctionWhitelist.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FunctionWhitelist.cpp; sourceTree = "<group>"; };
@@ -4727,25 +4725,6 @@
 		FEDA50D51B97F4D9009A3B4F /* PingPongStackOverflowTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = PingPongStackOverflowTest.h; path = API/tests/PingPongStackOverflowTest.h; sourceTree = "<group>"; };
 		FEF040501AAE662D00BD28B0 /* CompareAndSwapTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CompareAndSwapTest.cpp; path = API/tests/CompareAndSwapTest.cpp; sourceTree = "<group>"; };
 		FEF040521AAEC4ED00BD28B0 /* CompareAndSwapTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CompareAndSwapTest.h; path = API/tests/CompareAndSwapTest.h; sourceTree = "<group>"; };
-		FEF3475220362B1B00B7C0EF /* parser.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = parser.rb; sourceTree = "<group>"; };
-		FEF3475320362B1B00B7C0EF /* risc.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = risc.rb; sourceTree = "<group>"; };
-		FEF3475420362B1B00B7C0EF /* self_hash.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = self_hash.rb; sourceTree = "<group>"; };
-		FEF3475520362B1C00B7C0EF /* arm.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = arm.rb; sourceTree = "<group>"; };
-		FEF3475620362B1C00B7C0EF /* backends.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = backends.rb; sourceTree = "<group>"; };
-		FEF3475720362B1D00B7C0EF /* registers.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = registers.rb; sourceTree = "<group>"; };
-		FEF3475820362B1D00B7C0EF /* ast.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = ast.rb; sourceTree = "<group>"; };
-		FEF3475920362B1D00B7C0EF /* asm.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = asm.rb; sourceTree = "<group>"; };
-		FEF3475A20362B1E00B7C0EF /* cloop.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = cloop.rb; sourceTree = "<group>"; };
-		FEF3475B20362B1E00B7C0EF /* x86.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = x86.rb; sourceTree = "<group>"; };
-		FEF3475C20362B1E00B7C0EF /* mips.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = mips.rb; sourceTree = "<group>"; };
-		FEF3475D20362B1F00B7C0EF /* config.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = config.rb; sourceTree = "<group>"; };
-		FEF3475E20362B1F00B7C0EF /* instructions.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = instructions.rb; sourceTree = "<group>"; };
-		FEF3475F20362B2000B7C0EF /* opt.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = opt.rb; sourceTree = "<group>"; };
-		FEF3476020362B2100B7C0EF /* transform.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = transform.rb; sourceTree = "<group>"; };
-		FEF3476120362B2100B7C0EF /* offsets.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = offsets.rb; sourceTree = "<group>"; };
-		FEF3476220362B2200B7C0EF /* arm64.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = arm64.rb; sourceTree = "<group>"; };
-		FEF3476320362B2300B7C0EF /* settings.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = settings.rb; sourceTree = "<group>"; };
-		FEF3476420362B2300B7C0EF /* generate_offset_extractor.rb */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.ruby; path = generate_offset_extractor.rb; sourceTree = "<group>"; };
 		FEF49AA91EB947FE00653BDB /* MultithreadedMultiVMExecutionTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = MultithreadedMultiVMExecutionTest.cpp; path = API/tests/MultithreadedMultiVMExecutionTest.cpp; sourceTree = "<group>"; };
 		FEF49AAA1EB947FE00653BDB /* MultithreadedMultiVMExecutionTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MultithreadedMultiVMExecutionTest.h; path = API/tests/MultithreadedMultiVMExecutionTest.h; sourceTree = "<group>"; };
 		FEFD6FC51D5E7970008F2F0B /* JSStringInlines.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSStringInlines.h; sourceTree = "<group>"; };
@@ -4901,7 +4880,6 @@
 				1429D77A0ED20D7300B89619 /* interpreter */,
 				1429D92C0ED22D7000B89619 /* jit */,
 				0F46809C14BA7F4D00BFE272 /* llint */,
-				FEF347512036291300B7C0EF /* offlineasm */,
 				7E39D8370EC3A388003AF11A /* parser */,
 				034768DFFF38A50411DB9C8B /* Products */,
 				95AB831A0DA42C6900BC83F3 /* profiler */,
@@ -6873,7 +6851,6 @@
 				79B00CBB1C6AB07E0088C65D /* ProxyObject.h */,
 				79160DBB1C8E3EC8008C085A /* ProxyRevoke.cpp */,
 				79160DBC1C8E3EC8008C085A /* ProxyRevoke.h */,
-				FE9AE1C82032C887002B6934 /* PtrTag.h */,
 				0F5780A118FE1E98001E72D9 /* PureNaN.h */,
 				0F0CD4C015F1A6040032F1C0 /* PutDirectIndexMode.h */,
 				147B84620E6DE6B1004775A4 /* PutPropertySlot.h */,
@@ -8054,32 +8031,6 @@
 			path = domjit;
 			sourceTree = "<group>";
 		};
-		FEF347512036291300B7C0EF /* offlineasm */ = {
-			isa = PBXGroup;
-			children = (
-				FEF3475520362B1C00B7C0EF /* arm.rb */,
-				FEF3476220362B2200B7C0EF /* arm64.rb */,
-				FEF3475920362B1D00B7C0EF /* asm.rb */,
-				FEF3475820362B1D00B7C0EF /* ast.rb */,
-				FEF3475620362B1C00B7C0EF /* backends.rb */,
-				FEF3475A20362B1E00B7C0EF /* cloop.rb */,
-				FEF3475D20362B1F00B7C0EF /* config.rb */,
-				FEF3476420362B2300B7C0EF /* generate_offset_extractor.rb */,
-				FEF3475E20362B1F00B7C0EF /* instructions.rb */,
-				FEF3475C20362B1E00B7C0EF /* mips.rb */,
-				FEF3476120362B2100B7C0EF /* offsets.rb */,
-				FEF3475F20362B2000B7C0EF /* opt.rb */,
-				FEF3475220362B1B00B7C0EF /* parser.rb */,
-				FEF3475720362B1D00B7C0EF /* registers.rb */,
-				FEF3475320362B1B00B7C0EF /* risc.rb */,
-				FEF3475420362B1B00B7C0EF /* self_hash.rb */,
-				FEF3476320362B2300B7C0EF /* settings.rb */,
-				FEF3476020362B2100B7C0EF /* transform.rb */,
-				FEF3475B20362B1E00B7C0EF /* x86.rb */,
-			);
-			path = offlineasm;
-			sourceTree = "<group>";
-		};
 /* End PBXGroup section */
 
 /* Begin PBXHeadersBuildPhase section */
@@ -8116,7 +8067,6 @@
 				0FEC85721BDACDC70080FF74 /* AirBasicBlock.h in Headers */,
 				0F2C63BC1E63440C00C13839 /* AirBlockInsertionSet.h in Headers */,
 				0FB3878E1BFBC44D00E3AB1E /* AirBlockWorklist.h in Headers */,
-				FE6C1E4A20366F0100BDC2B7 /* PtrTag.h in Headers */,
 				0F79C7CA1E74C93B00EB34D1 /* AirBreakCriticalEdges.h in Headers */,
 				0F61832A1C45BF070072450B /* AirCCallingConvention.h in Headers */,
 				0FEC85741BDACDC70080FF74 /* AirCCallSpecial.h in Headers */,

Modified: trunk/Source/_javascript_Core/assembler/MacroAssembler.h (229446 => 229447)


--- trunk/Source/_javascript_Core/assembler/MacroAssembler.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/assembler/MacroAssembler.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -35,11 +35,6 @@
 #include "MacroAssemblerARMv7.h"
 namespace JSC { typedef MacroAssemblerARMv7 MacroAssemblerBase; };
 
-#elif CPU(ARM64E) && __has_include(<WebKitAdditions/MacroAssemblerARM64E.h>)
-#define TARGET_ASSEMBLER ARM64EAssembler
-#define TARGET_MACROASSEMBLER MacroAssemblerARM64E
-#include <WebKitAdditions/MacroAssemblerARM64E.h>
-
 #elif CPU(ARM64)
 #define TARGET_ASSEMBLER ARM64Assembler
 #define TARGET_MACROASSEMBLER MacroAssemblerARM64

Modified: trunk/Source/_javascript_Core/bytecode/LLIntCallLinkInfo.h (229446 => 229447)


--- trunk/Source/_javascript_Core/bytecode/LLIntCallLinkInfo.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/bytecode/LLIntCallLinkInfo.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2012 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -27,7 +27,6 @@
 
 #include "JSFunction.h"
 #include "MacroAssemblerCodeRef.h"
-#include "PtrTag.h"
 #include <wtf/SentinelLinkedList.h>
 
 namespace JSC {
@@ -51,7 +50,6 @@
     {
         callee.clear();
         machineCodeTarget = MacroAssemblerCodePtr();
-        callPtrTag = NoPtrTag;
         if (isOnList())
             remove();
     }
@@ -59,7 +57,6 @@
     WriteBarrier<JSObject> callee;
     WriteBarrier<JSObject> lastSeenCallee;
     MacroAssemblerCodePtr machineCodeTarget;
-    PtrTag callPtrTag { NoPtrTag };
 };
 
 } // namespace JSC

Modified: trunk/Source/_javascript_Core/llint/LLIntData.cpp (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntData.cpp	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntData.cpp	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2011, 2016 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -63,46 +63,9 @@
 #else // ENABLE(JIT)
     llint_entry(&Data::s_opcodeMap);
 
-    for (int i = 0; i < NUMBER_OF_BYTECODE_IDS; ++i) {
-        PtrTag tag = (i == op_catch) ? ExceptionHandlerPtrTag : BytecodePtrTag;
-        Data::s_opcodeMap[i] = tagCodePtr(Data::s_opcodeMap[i], tag);
-    }
-
-    if (VM::canUseJIT()) {
-        for (int i = NUMBER_OF_BYTECODE_IDS; i < NUMBER_OF_BYTECODE_IDS + NUMBER_OF_BYTECODE_HELPER_IDS; ++i)
-            Data::s_opcodeMap[i] = tagCodePtr(Data::s_opcodeMap[i], ptrTag(BytecodeHelperPtrTag, i));
-    } else {
-        static const PtrTag tagsForOpcode[] = {
-            CodeEntryPtrTag, // llint_program_prologue
-            CodeEntryPtrTag, // llint_eval_prologue
-            CodeEntryPtrTag, // llint_module_program_prologue
-            CodeEntryPtrTag, // llint_function_for_call_prologue
-            CodeEntryPtrTag, // llint_function_for_construct_prologue
-            CodeEntryWithArityCheckPtrTag, // llint_function_for_call_arity_check
-            CodeEntryWithArityCheckPtrTag, // llint_function_for_construct_arity_check
-            CodeEntryPtrTag, // llint_generic_return_point
-            BytecodePtrTag, // llint_throw_from_slow_path_trampoline
-            CodeEntryPtrTag, // llint_throw_during_call_trampoline
-            NativeCodePtrTag, // llint_native_call_trampoline
-            NativeCodePtrTag, // llint_native_construct_trampoline
-            InternalFunctionPtrTag, // llint_internal_function_call_trampoline
-            InternalFunctionPtrTag, // llint_internal_function_construct_trampoline
-            ExceptionHandlerPtrTag, // handleUncaughtException
-        };
-
-        static_assert(sizeof(tagsForOpcode) / sizeof(tagsForOpcode[0]) == NUMBER_OF_BYTECODE_HELPER_IDS, "");
-        static_assert(static_cast<uintptr_t>(llint_program_prologue) == NUMBER_OF_BYTECODE_IDS, "");
-
-        for (int i = 0; i < NUMBER_OF_BYTECODE_HELPER_IDS; ++i) {
-            int opcodeID = i + NUMBER_OF_BYTECODE_IDS;
-            Data::s_opcodeMap[opcodeID] = tagCodePtr(Data::s_opcodeMap[opcodeID], tagsForOpcode[i]);
-        }
-    }
-
-    void* handler = LLInt::getCodePtr(llint_throw_from_slow_path_trampoline);
     for (int i = 0; i < maxOpcodeLength + 1; ++i)
-        Data::s_exceptionInstructions[i].u.pointer = handler;
-
+        Data::s_exceptionInstructions[i].u.pointer =
+            LLInt::getCodePtr(llint_throw_from_slow_path_trampoline);
 #endif // ENABLE(JIT)
 
 #if ENABLE(LLINT_STATS)

Modified: trunk/Source/_javascript_Core/llint/LLIntData.h (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntData.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntData.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -27,7 +27,6 @@
 
 #include "JSCJSValue.h"
 #include "Opcode.h"
-#include "PtrTag.h"
 #include <array>
 #include <wtf/PointerPreparations.h>
 

Modified: trunk/Source/_javascript_Core/llint/LLIntExceptions.cpp (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntExceptions.cpp	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntExceptions.cpp	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2011, 2016 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -39,6 +39,12 @@
 
 namespace JSC { namespace LLInt {
 
+Instruction* returnToThrowForThrownException(ExecState* exec)
+{
+    UNUSED_PARAM(exec);
+    return LLInt::exceptionInstructions();
+}
+
 Instruction* returnToThrow(ExecState* exec)
 {
     UNUSED_PARAM(exec);

Modified: trunk/Source/_javascript_Core/llint/LLIntExceptions.h (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntExceptions.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntExceptions.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2011 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -34,6 +34,10 @@
 
 namespace LLInt {
 
+// Tells you where to jump to if you want to return-to-throw, after you've already
+// set up all information needed to throw the exception.
+Instruction* returnToThrowForThrownException(ExecState*);
+
 // Gives you a PC that you can tell the interpreter to go to, which when advanced
 // between 1 and 9 slots will give you an "instruction" that threads to the
 // interpreter's exception handler.

Modified: trunk/Source/_javascript_Core/llint/LLIntOfflineAsmConfig.h (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntOfflineAsmConfig.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntOfflineAsmConfig.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -118,8 +118,6 @@
 
 #if CPU(ARM64E)
 #define OFFLINE_ASM_ARM64E 1
-#undef OFFLINE_ASM_ARM64
-#define OFFLINE_ASM_ARM64 0 // Pretend that ARM64 and ARM64E are mutually exclusive to please the offlineasm.
 #else
 #define OFFLINE_ASM_ARM64E 0
 #endif
@@ -175,10 +173,4 @@
 #define OFFLINE_ASM_EXECUTION_TRACING 0
 #endif
 
-#if USE(POINTER_PROFILING)
-#define OFFLINE_ASM_POINTER_PROFILING 1
-#else
-#define OFFLINE_ASM_POINTER_PROFILING 0
-#endif
-
 #define OFFLINE_ASM_GIGACAGE_ENABLED GIGACAGE_ENABLED

Modified: trunk/Source/_javascript_Core/llint/LLIntOffsetsExtractor.cpp (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntOffsetsExtractor.cpp	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntOffsetsExtractor.cpp	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2012-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2012, 2015-2016 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -51,7 +51,6 @@
 #include "MarkedSpace.h"
 #include "NativeExecutable.h"
 #include "ProtoCallFrame.h"
-#include "PtrTag.h"
 #include "ShadowChicken.h"
 #include "Structure.h"
 #include "StructureChain.h"

Modified: trunk/Source/_javascript_Core/llint/LLIntPCRanges.h (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntPCRanges.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntPCRanges.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -25,7 +25,7 @@
 
 #pragma once
 
-#include "PtrTag.h"
+#include <wtf/PointerPreparations.h>
 
 namespace JSC {
 
@@ -40,8 +40,8 @@
 ALWAYS_INLINE bool isLLIntPC(void* pc)
 {
     uintptr_t pcAsInt = bitwise_cast<uintptr_t>(pc);
-    uintptr_t llintStart = untagCodePtr<uintptr_t>(llintPCRangeStart, CFunctionPtrTag);
-    uintptr_t llintEnd = untagCodePtr<uintptr_t>(llintPCRangeEnd, CFunctionPtrTag);
+    uintptr_t llintStart = bitwise_cast<uintptr_t>(WTF_PREPARE_FUNCTION_POINTER_FOR_EXECUTION(llintPCRangeStart));
+    uintptr_t llintEnd = bitwise_cast<uintptr_t>(WTF_PREPARE_FUNCTION_POINTER_FOR_EXECUTION(llintPCRangeEnd));
     RELEASE_ASSERT(llintStart < llintEnd);
     return llintStart <= pcAsInt && pcAsInt <= llintEnd;
 }

Modified: trunk/Source/_javascript_Core/llint/LLIntSlowPaths.cpp (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LLIntSlowPaths.cpp	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LLIntSlowPaths.cpp	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2011-2018 Apple Inc. All rights reserved.
+ * Copyright (C) 2011-2017 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -159,13 +159,12 @@
         JSValue::encode(value);                  \
     } while (false)
 
-#define LLINT_CALL_END_IMPL(exec, callTarget, callTargetTag) \
-    LLINT_RETURN_TWO(retagCodePtr((callTarget), callTargetTag, SlowPathPtrTag), (exec))
+#define LLINT_CALL_END_IMPL(exec, callTarget) LLINT_RETURN_TWO((callTarget), (exec))
 
 #define LLINT_CALL_THROW(exec, exceptionToThrow) do {                   \
         ExecState* __ct_exec = (exec);                                  \
         throwException(__ct_exec, throwScope, exceptionToThrow);        \
-        LLINT_CALL_END_IMPL(0, callToThrow(__ct_exec), ExceptionHandlerPtrTag);                 \
+        LLINT_CALL_END_IMPL(0, callToThrow(__ct_exec));                 \
     } while (false)
 
 #define LLINT_CALL_CHECK_EXCEPTION(exec, execCallee) do {               \
@@ -173,15 +172,15 @@
         ExecState* __cce_execCallee = (execCallee);                     \
         doExceptionFuzzingIfEnabled(__cce_exec, throwScope, "LLIntSlowPaths/call", nullptr); \
         if (UNLIKELY(throwScope.exception()))                           \
-            LLINT_CALL_END_IMPL(0, callToThrow(__cce_execCallee), ExceptionHandlerPtrTag); \
+            LLINT_CALL_END_IMPL(0, callToThrow(__cce_execCallee));      \
     } while (false)
 
-#define LLINT_CALL_RETURN(exec, execCallee, callTarget, callTargetTag) do { \
+#define LLINT_CALL_RETURN(exec, execCallee, callTarget) do {            \
         ExecState* __cr_exec = (exec);                                  \
         ExecState* __cr_execCallee = (execCallee);                      \
         void* __cr_callTarget = (callTarget);                           \
         LLINT_CALL_CHECK_EXCEPTION(__cr_exec, __cr_execCallee);         \
-        LLINT_CALL_END_IMPL(__cr_execCallee, __cr_callTarget, callTargetTag); \
+        LLINT_CALL_END_IMPL(__cr_execCallee, __cr_callTarget);          \
     } while (false)
 
 #define LLINT_RETURN_CALLEE_FRAME(execCallee) do {                      \
@@ -284,7 +283,7 @@
             opcodeNames[opcodeID], pc);
     if (opcodeID == op_enter) {
         dataLogF("Frame will eventually return to %p\n", exec->returnPC().value());
-        *removeCodePtrTag<volatile char*>(exec->returnPC().value());
+        *bitwise_cast<volatile char*>(exec->returnPC().value());
     }
     if (opcodeID == op_ret) {
         dataLogF("Will be returning to %p\n", exec->returnPC().value());
@@ -1326,7 +1325,7 @@
             vm.hostCallReturnValue = JSValue::decode(callData.native.function(execCallee));
             
             PoisonedMasmPtr::assertIsNotPoisoned(LLInt::getCodePtr(getHostCallReturnValue));
-            LLINT_CALL_RETURN(execCallee, execCallee, LLInt::getCodePtr(getHostCallReturnValue), CFunctionPtrTag);
+            LLINT_CALL_RETURN(execCallee, execCallee, LLInt::getCodePtr(getHostCallReturnValue));
         }
         
 #if LLINT_SLOW_PATH_TRACING
@@ -1350,7 +1349,7 @@
         vm.hostCallReturnValue = JSValue::decode(constructData.native.function(execCallee));
 
         PoisonedMasmPtr::assertIsNotPoisoned(LLInt::getCodePtr(getHostCallReturnValue));
-        LLINT_CALL_RETURN(execCallee, execCallee, LLInt::getCodePtr(getHostCallReturnValue), CFunctionPtrTag);
+        LLINT_CALL_RETURN(execCallee, execCallee, LLInt::getCodePtr(getHostCallReturnValue));
     }
     
 #if LLINT_SLOW_PATH_TRACING
@@ -1387,11 +1386,10 @@
                 callLinkInfo->callee.set(vm, callerCodeBlock, internalFunction);
                 callLinkInfo->lastSeenCallee.set(vm, callerCodeBlock, internalFunction);
                 callLinkInfo->machineCodeTarget = codePtr;
-                callLinkInfo->callPtrTag = InternalFunctionPtrTag;
             }
 
             PoisonedMasmPtr::assertIsNotPoisoned(codePtr.executableAddress());
-            LLINT_CALL_RETURN(exec, execCallee, codePtr.executableAddress(), InternalFunctionPtrTag);
+            LLINT_CALL_RETURN(exec, execCallee, codePtr.executableAddress());
         }
         throwScope.release();
         return handleHostCall(execCallee, pc, calleeAsValue, kind);
@@ -1400,12 +1398,10 @@
     JSScope* scope = callee->scopeUnchecked();
     ExecutableBase* executable = callee->executable();
 
-    PtrTag callPtrTag = NoPtrTag;
     MacroAssemblerCodePtr codePtr;
     CodeBlock* codeBlock = 0;
     if (executable->isHostFunction()) {
         codePtr = executable->entrypointFor(kind, MustCheckArity);
-        callPtrTag = NativeCodePtrTag;
     } else {
         FunctionExecutable* functionExecutable = static_cast<FunctionExecutable*>(executable);
 
@@ -1420,13 +1416,10 @@
         codeBlock = *codeBlockSlot;
         ASSERT(codeBlock);
         ArityCheckMode arity;
-        if (execCallee->argumentCountIncludingThis() < static_cast<size_t>(codeBlock->numParameters())) {
+        if (execCallee->argumentCountIncludingThis() < static_cast<size_t>(codeBlock->numParameters()))
             arity = MustCheckArity;
-            callPtrTag = CodeEntryWithArityCheckPtrTag;
-        } else {
+        else
             arity = ArityCheckNotRequired;
-            callPtrTag = CodeEntryPtrTag;
-        }
         codePtr = functionExecutable->entrypointFor(kind, arity);
     }
 
@@ -1442,14 +1435,12 @@
         callLinkInfo->callee.set(vm, callerCodeBlock, callee);
         callLinkInfo->lastSeenCallee.set(vm, callerCodeBlock, callee);
         callLinkInfo->machineCodeTarget = codePtr;
-        RELEASE_ASSERT(callPtrTag != NoPtrTag);
-        callLinkInfo->callPtrTag = callPtrTag;
         if (codeBlock)
             codeBlock->linkIncomingCall(exec, callLinkInfo);
     }
 
     PoisonedMasmPtr::assertIsNotPoisoned(codePtr.executableAddress());
-    LLINT_CALL_RETURN(exec, execCallee, codePtr.executableAddress(), callPtrTag);
+    LLINT_CALL_RETURN(exec, execCallee, codePtr.executableAddress());
 }
 
 inline SlowPathReturnType genericCall(ExecState* exec, Instruction* pc, CodeSpecializationKind kind)
@@ -1589,7 +1580,7 @@
     }
     
     vm.hostCallReturnValue = eval(execCallee);
-    LLINT_CALL_RETURN(exec, execCallee, LLInt::getCodePtr(getHostCallReturnValue), CFunctionPtrTag);
+    LLINT_CALL_RETURN(exec, execCallee, LLInt::getCodePtr(getHostCallReturnValue));
 }
 
 LLINT_SLOW_PATH_DECL(slow_path_strcat)

Modified: trunk/Source/_javascript_Core/llint/LowLevelInterpreter.asm (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LowLevelInterpreter.asm	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LowLevelInterpreter.asm	2018-03-09 02:16:27 UTC (rev 229447)
@@ -71,7 +71,7 @@
 #  They are callee-save registers, and guaranteed to be distinct from all other
 #  registers on all architectures.
 #
-#  - lr is defined on non-X86 architectures (ARM64, ARM64E, ARMv7, ARM,
+#  - lr is defined on non-X86 architectures (ARM64, ARMv7, ARM,
 #  ARMv7_TRADITIONAL, MIPS and CLOOP) and holds the return PC
 #
 #  - pc holds the (native) program counter on 32-bits ARM architectures (ARM,
@@ -223,7 +223,7 @@
 
 const CallOpCodeSize = 9
 
-if X86_64 or ARM64 or ARM64E or C_LOOP
+if X86_64 or ARM64 or C_LOOP
     const maxFrameExtentForSlowPathCall = 0
 elsif ARM or ARMv7_TRADITIONAL or ARMv7
     const maxFrameExtentForSlowPathCall = 24
@@ -235,7 +235,7 @@
     const maxFrameExtentForSlowPathCall = 64
 end
 
-if X86_64 or X86_64_WIN or ARM64 or ARM64E
+if X86_64 or X86_64_WIN or ARM64
     const CalleeSaveSpaceAsVirtualRegisters = 3
 else
     const CalleeSaveSpaceAsVirtualRegisters = 0
@@ -260,16 +260,6 @@
 const ArithProfileNumberNumber = 0x900000
 const ArithProfileIntNumber = 0x500000
 
-# Pointer Tags
-const BytecodePtrTag = constexpr BytecodePtrTag
-const CodeEntryPtrTag = constexpr CodeEntryPtrTag
-const CodeEntryWithArityCheckPtrTag = constexpr CodeEntryWithArityCheckPtrTag
-const ExceptionHandlerPtrTag = constexpr ExceptionHandlerPtrTag
-const InternalFunctionPtrTag = constexpr InternalFunctionPtrTag
-const NativeCodePtrTag = constexpr NativeCodePtrTag
-const NoPtrTag = constexpr NoPtrTag
-const SlowPathPtrTag = constexpr SlowPathPtrTag
-
 # Some register conventions.
 if JSVALUE64
     # - Use a pair of registers to represent the PC: one register for the
@@ -278,7 +268,7 @@
     # - C calls are still given the Instruction* rather than the PC index.
     #   This requires an add before the call, and a sub after.
     const PC = t4 # When changing this, make sure LLIntPC is up to date in LLIntPCRanges.h
-    if ARM64 or ARM64E
+    if ARM64
         const PB = csr7
         const tagTypeNumber = csr8
         const tagMask = csr9
@@ -502,10 +492,10 @@
 #         end
 #     )
 #
-if X86_64 or ARM64 or ARM64E
+if X86_64 or ARM64
     macro probe(action)
         # save all the registers that the LLInt may use.
-        if ARM64 or ARM64E
+        if ARM64
             push cfr, lr
         end
         push a0, a1
@@ -513,7 +503,7 @@
         push t0, t1
         push t2, t3
         push t4, t5
-        if ARM64 or ARM64E
+        if ARM64
             push csr0, csr1
             push csr2, csr3
             push csr4, csr5
@@ -524,7 +514,7 @@
         action()
 
         # restore all the registers we saved previously.
-        if ARM64 or ARM64E
+        if ARM64
             pop csr9, csr8
             pop csr7, csr6
             pop csr5, csr4
@@ -536,7 +526,7 @@
         pop t1, t0
         pop a3, a2
         pop a1, a0
-        if ARM64 or ARM64E
+        if ARM64
             pop lr, cfr
         end
     end
@@ -546,8 +536,8 @@
 end
 
 macro checkStackPointerAlignment(tempReg, location)
-    if ARM64 or ARM64E or C_LOOP
-        # ARM64 and ARM64E will check for us!
+    if ARM64 or C_LOOP
+        # ARM64 will check for us!
         # C_LOOP does not need the alignment, and can use a little perf
         # improvement from avoiding useless work.
     else
@@ -565,7 +555,7 @@
     end
 end
 
-if C_LOOP or ARM64 or ARM64E or X86_64 or X86_64_WIN
+if C_LOOP or ARM64 or X86_64 or X86_64_WIN
     const CalleeSaveRegisterCount = 0
 elsif ARM or ARMv7_TRADITIONAL or ARMv7
     const CalleeSaveRegisterCount = 7
@@ -582,7 +572,7 @@
 const VMEntryTotalFrameSize = (CalleeRegisterSaveSize + sizeof VMEntryRecord + StackAlignment - 1) & ~StackAlignmentMask
 
 macro pushCalleeSaves()
-    if C_LOOP or ARM64 or ARM64E or X86_64 or X86_64_WIN
+    if C_LOOP or ARM64 or X86_64 or X86_64_WIN
     elsif ARM or ARMv7_TRADITIONAL
         emit "push {r4-r10}"
     elsif ARMv7
@@ -604,7 +594,7 @@
 end
 
 macro popCalleeSaves()
-    if C_LOOP or ARM64 or ARM64E or X86_64 or X86_64_WIN
+    if C_LOOP or ARM64 or X86_64 or X86_64_WIN
     elsif ARM or ARMv7_TRADITIONAL
         emit "pop {r4-r10}"
     elsif ARMv7
@@ -629,7 +619,7 @@
         push cfr
     elsif X86 or X86_WIN or X86_64 or X86_64_WIN
         push cfr
-    elsif ARM64 or ARM64E
+    elsif ARM64
         push cfr, lr
     else
         error
@@ -644,7 +634,7 @@
         pop lr
     elsif X86 or X86_WIN or X86_64 or X86_64_WIN
         pop cfr
-    elsif ARM64 or ARM64E
+    elsif ARM64
         pop lr, cfr
     end
 end
@@ -654,7 +644,7 @@
     if C_LOOP
     elsif ARM or ARMv7_TRADITIONAL
     elsif ARMv7
-    elsif ARM64 or ARM64E
+    elsif ARM64
         emit "stp x27, x28, [x29, #-16]"
         emit "stp xzr, x26, [x29, #-32]"
     elsif MIPS
@@ -675,7 +665,7 @@
     if C_LOOP
     elsif ARM or ARMv7_TRADITIONAL
     elsif ARMv7
-    elsif ARM64 or ARM64E
+    elsif ARM64
         emit "ldp xzr, x26, [x29, #-32]"
         emit "ldp x27, x28, [x29, #-16]"
     elsif MIPS
@@ -693,11 +683,11 @@
 end
 
 macro copyCalleeSavesToVMEntryFrameCalleeSavesBuffer(vm, temp)
-    if ARM64 or ARM64E or X86_64 or X86_64_WIN
+    if ARM64 or X86_64 or X86_64_WIN
         loadp VM::topEntryFrame[vm], temp
         vmEntryRecord(temp, temp)
         leap VMEntryRecord::calleeSaveRegistersBuffer[temp], temp
-        if ARM64 or ARM64E
+        if ARM64
             storep csr0, [temp]
             storep csr1, 8[temp]
             storep csr2, 16[temp]
@@ -735,11 +725,11 @@
 end
 
 macro restoreCalleeSavesFromVMEntryFrameCalleeSavesBuffer(vm, temp)
-    if ARM64 or ARM64E or X86_64 or X86_64_WIN
+    if ARM64 or X86_64 or X86_64_WIN
         loadp VM::topEntryFrame[vm], temp
         vmEntryRecord(temp, temp)
         leap VMEntryRecord::calleeSaveRegistersBuffer[temp], temp
-        if ARM64 or ARM64E
+        if ARM64
             loadp [temp], csr0
             loadp 8[temp], csr1
             loadp 16[temp], csr2
@@ -777,7 +767,7 @@
 end
 
 macro preserveReturnAddressAfterCall(destinationRegister)
-    if C_LOOP or ARM or ARMv7 or ARMv7_TRADITIONAL or ARM64 or ARM64E or MIPS
+    if C_LOOP or ARM or ARMv7 or ARMv7_TRADITIONAL or ARM64 or MIPS
         # In C_LOOP case, we're only preserving the bytecode vPC.
         move lr, destinationRegister
     elsif X86 or X86_WIN or X86_64 or X86_64_WIN
@@ -795,10 +785,9 @@
 end
 
 macro functionPrologue()
-    tagReturnAddress sp
     if X86 or X86_WIN or X86_64 or X86_64_WIN
         push cfr
-    elsif ARM64 or ARM64E
+    elsif ARM64
         push cfr, lr
     elsif C_LOOP or ARM or ARMv7 or ARMv7_TRADITIONAL or MIPS
         push lr
@@ -810,7 +799,7 @@
 macro functionEpilogue()
     if X86 or X86_WIN or X86_64 or X86_64_WIN
         pop cfr
-    elsif ARM64 or ARM64E
+    elsif ARM64
         pop lr, cfr
     elsif C_LOOP or ARM or ARMv7 or ARMv7_TRADITIONAL or MIPS
         pop cfr
@@ -859,22 +848,22 @@
     callSlowPath(slowPath)
 end
 
-macro callTargetFunction(callee, callPtrTag)
+macro callTargetFunction(callee)
     if C_LOOP
         cloopCallJSFunction callee
     else
-        call callee, callPtrTag
+        call callee
     end
     restoreStackPointerAfterCall()
     dispatchAfterCall()
 end
 
-macro prepareForRegularCall(callee, temp1, temp2, temp3, prepareCallPtrTag)
+macro prepareForRegularCall(callee, temp1, temp2, temp3)
     addp CallerFrameAndPCSize, sp
 end
 
 # sp points to the new frame
-macro prepareForTailCall(callee, temp1, temp2, temp3, prepareCallPtrTag)
+macro prepareForTailCall(callee, temp1, temp2, temp3)
     restoreCalleeSavesUsedByLLInt()
 
     loadi PayloadOffset + ArgumentCount[cfr], temp2
@@ -898,7 +887,7 @@
     addi StackAlignment - 1 + CallFrameHeaderSize, temp2
     andi ~StackAlignmentMask, temp2
 
-    if ARM or ARMv7_TRADITIONAL or ARMv7 or ARM64 or ARM64E or C_LOOP or MIPS
+    if ARM or ARMv7_TRADITIONAL or ARMv7 or ARM64 or C_LOOP or MIPS
         addp 2 * PtrSize, sp
         subi 2 * PtrSize, temp2
         loadp PtrSize[cfr], lr
@@ -909,11 +898,6 @@
         storep temp3, [sp]
     end
 
-    if POINTER_PROFILING
-        addp 16, cfr, temp3
-        untagReturnAddress temp3
-    end
-
     subp temp2, temp1
     loadp [cfr], cfr
 
@@ -923,9 +907,8 @@
     storep temp3, [temp1, temp2, 1]
     btinz temp2, .copyLoop
 
-    prepareCallPtrTag(temp2)
     move temp1, sp
-    jmp callee, temp2
+    jmp callee
 end
 
 macro slowPathForCall(slowPath, prepareCall)
@@ -936,13 +919,9 @@
         macro (callee, calleeFramePtr)
             btpz calleeFramePtr, .dontUpdateSP
             move calleeFramePtr, sp
-            prepareCall(callee, t2, t3, t4, macro (callPtrTagReg)
-                if POINTER_PROFILING
-                    move SlowPathPtrTag, callPtrTagReg
-                end
-            end)
+            prepareCall(callee, t2, t3, t4)
         .dontUpdateSP:
-            callTargetFunction(callee, SlowPathPtrTag)
+            callTargetFunction(callee)
         end)
 end
 
@@ -1024,7 +1003,6 @@
 # in t1. May also trigger prologue entry OSR.
 macro prologue(codeBlockGetter, codeBlockSetter, osrSlowPath, traceSlowPath)
     # Set up the call frame and check if we should OSR.
-    tagReturnAddress sp
     preserveCallerPCAndCFR()
 
     if EXECUTION_TRACING
@@ -1051,7 +1029,7 @@
         btpz r0, .recover
         move cfr, sp # restore the previous sp
         # pop the callerFrame since we will jump to a function that wants to save it
-        if ARM64 or ARM64E
+        if ARM64
             pop lr, cfr
         elsif ARM or ARMv7 or ARMv7_TRADITIONAL or MIPS
             pop cfr
@@ -1059,7 +1037,7 @@
         else
             pop cfr
         end
-        jmp r0, CodeEntryPtrTag
+        jmp r0
     .recover:
         codeBlockGetter(t1, t2)
     .continue:
@@ -1177,7 +1155,7 @@
     global _vmEntryToJavaScript
     _vmEntryToJavaScript:
 end
-    doVMEntry(makeJavaScriptCall, CodeEntryPtrTag, CodeEntryWithArityCheckPtrTag)
+    doVMEntry(makeJavaScriptCall)
 
 
 if C_LOOP
@@ -1186,7 +1164,7 @@
     global _vmEntryToNative
     _vmEntryToNative:
 end
-    doVMEntry(makeHostFunctionCall, NativeCodePtrTag, NativeCodePtrTag)
+    doVMEntry(makeHostFunctionCall)
 
 
 if not C_LOOP
@@ -1193,7 +1171,6 @@
     # void sanitizeStackForVMImpl(VM* vm)
     global _sanitizeStackForVMImpl
     _sanitizeStackForVMImpl:
-        tagReturnAddress sp
         # We need three non-aliased caller-save registers. We are guaranteed
         # this for a0, a1 and a2 on all architectures.
         if X86 or X86_WIN
@@ -1211,7 +1188,7 @@
         storep zeroValue, [address]
         addp PtrSize, address
         bpa sp, address, .zeroFillLoop
-
+    
     .zeroFillDone:
         move sp, address
         storep address, VM::m_lastStackTop[vm]
@@ -1220,7 +1197,6 @@
     # VMEntryRecord* vmEntryRecord(const EntryFrame* entryFrame)
     global _vmEntryRecord
     _vmEntryRecord:
-        tagReturnAddress sp
         if X86 or X86_WIN
             loadp 4[sp], a0
         end
@@ -1239,7 +1215,7 @@
             call _relativePCBase
         _relativePCBase:
             pop pcBase
-        elsif ARM64 or ARM64E
+        elsif ARM64
         elsif ARMv7
         _relativePCBase:
             move pc, pcBase
@@ -1266,7 +1242,7 @@
         leap (label - _relativePCBase)[t1], t3
         move index, t4
         storep t3, [a0, t4, 4]
-    elsif ARM64 or ARM64E
+    elsif ARM64
         pcrtoaddr label, t1
         move index, t4
         storep t1, [a0, t4, 8]

Modified: trunk/Source/_javascript_Core/llint/LowLevelInterpreter32_64.asm (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LowLevelInterpreter32_64.asm	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LowLevelInterpreter32_64.asm	2018-03-09 02:16:27 UTC (rev 229447)
@@ -96,7 +96,7 @@
     move r0, PC
 end
 
-macro doVMEntry(makeCall, unused1, unused2)
+macro doVMEntry(makeCall)
     functionPrologue()
     pushCalleeSaves()
 
@@ -1957,8 +1957,8 @@
     storei t2, ArgumentCount + PayloadOffset[t3]
     storei CellTag, Callee + TagOffset[t3]
     move t3, sp
-    prepareCall(LLIntCallLinkInfo::machineCodeTarget[t1], t2, t3, t4, macro (callPtrTag) end)
-    callTargetFunction(LLIntCallLinkInfo::machineCodeTarget[t1], NoPtrTag)
+    prepareCall(LLIntCallLinkInfo::machineCodeTarget[t1], t2, t3, t4)
+    callTargetFunction(LLIntCallLinkInfo::machineCodeTarget[t1])
 
 .opCallSlow:
     slowPathForCall(slowPath, prepareCall)

Modified: trunk/Source/_javascript_Core/llint/LowLevelInterpreter64.asm (229446 => 229447)


--- trunk/Source/_javascript_Core/llint/LowLevelInterpreter64.asm	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/llint/LowLevelInterpreter64.asm	2018-03-09 02:16:27 UTC (rev 229447)
@@ -24,7 +24,7 @@
 
 # Utilities.
 macro jumpToInstruction()
-    jmp [PB, PC, 8], BytecodePtrTag
+    jmp [PB, PC, 8]
 end
 
 macro dispatch(advance)
@@ -54,7 +54,7 @@
 
 macro cCall2(function)
     checkStackPointerAlignment(t4, 0xbad0c002)
-    if X86_64 or ARM64 or ARM64E
+    if X86_64 or ARM64
         call function
     elsif X86_64_WIN
         # Note: this implementation is only correct if the return type size is > 8 bytes.
@@ -92,7 +92,7 @@
         # See http://msdn.microsoft.com/en-us/library/ms235286.aspx
         subp 32, sp 
         call function
-        addp 32, sp
+        addp 32, sp 
     else
         cCall2(function)
     end
@@ -101,7 +101,7 @@
 # This barely works. arg3 and arg4 should probably be immediates.
 macro cCall4(function)
     checkStackPointerAlignment(t4, 0xbad0c004)
-    if X86_64 or ARM64 or ARM64E
+    if X86_64 or ARM64
         call function
     elsif X86_64_WIN
         # On Win64, rcx, rdx, r8, and r9 are used for passing the first four parameters.
@@ -115,7 +115,7 @@
     end
 end
 
-macro doVMEntry(makeCall, callTag, callWithArityCheckTag)
+macro doVMEntry(makeCall)
     functionPrologue()
     pushCalleeSaves()
 
@@ -215,7 +215,7 @@
     jmp .copyArgsLoop
 
 .copyArgsDone:
-    if ARM64 or ARM64E
+    if ARM64
         move sp, t4
         storep t4, VM::topCallFrame[vm]
     else
@@ -225,17 +225,8 @@
 
     checkStackPointerAlignment(extraTempReg, 0xbad0dc02)
 
-    if POINTER_PROFILING
-        btbnz ProtoCallFrame::hasArityMismatch[protoCallFrame], .doCallWithArityCheck
-        move callTag, t2
-        jmp .readyToCall
-    .doCallWithArityCheck:
-        move callWithArityCheckTag, t2
-    .readyToCall:
-    end
+    makeCall(entry, t3)
 
-    makeCall(entry, t3, t2)
-
     # We may have just made a call into a JS function, so we can't rely on sp
     # for anything but the fact that our own locals (ie the VMEntryRecord) are
     # not below it. It also still has to be aligned, though.
@@ -258,18 +249,18 @@
 end
 
 
-macro makeJavaScriptCall(entry, temp, callTag)
+macro makeJavaScriptCall(entry, temp)
     addp 16, sp
     if C_LOOP
         cloopCallJSFunction entry
     else
-        call entry, callTag
+        call entry
     end
     subp 16, sp
 end
 
 
-macro makeHostFunctionCall(entry, temp, callTag)
+macro makeHostFunctionCall(entry, temp)
     move entry, temp
     storep cfr, [sp]
     move sp, a0
@@ -279,10 +270,10 @@
     elsif X86_64_WIN
         # We need to allocate 32 bytes on the stack for the shadow space.
         subp 32, sp
-        call temp, callTag
+        call temp
         addp 32, sp
     else
-        call temp, callTag
+        call temp
     end
 end
 
@@ -379,7 +370,7 @@
             cCall2(_llint_loop_osr)
             btpz r0, .recover
             move r1, sp
-            jmp r0, CodeEntryPtrTag
+            jmp r0
         .recover:
             loadi ArgumentCount + TagOffset[cfr], PC
         end)
@@ -552,15 +543,6 @@
     btiz t1, .continue
 
 .noExtraSlot:
-    if POINTER_PROFILING
-        if ARM64 or ARM64E
-            loadp 8[cfr], lr
-        end
-
-        addp 16, cfr, t3
-        untagReturnAddress t3
-    end
-
     // Move frame up t1 slots
     negq t1
     move cfr, t3
@@ -584,15 +566,6 @@
     addp 8, t3
     baddinz 1, t2, .fillLoop
 
-    if POINTER_PROFILING
-        addp 16, cfr, t1
-        tagReturnAddress t1
-
-        if ARM64 or ARM64E
-            storep lr, 8[cfr]
-        end
-    end
-
 .continue:
     # Reload CodeBlock and reset PC, since the slow_path clobbered them.
     loadp CodeBlock[cfr], t1
@@ -1983,9 +1956,6 @@
 macro doCall(slowPath, prepareCall)
     loadisFromInstruction(2, t0)
     loadpFromInstruction(5, t1)
-    if POINTER_PROFILING
-        move t1, t5
-    end
     loadp LLIntCallLinkInfo::callee[t1], t2
     loadConstantOrVariable(t0, t3)
     bqneq t3, t2, .opCallSlow
@@ -2001,25 +1971,11 @@
     if POISON
         loadp _g_JITCodePoison, t2
         xorp LLIntCallLinkInfo::machineCodeTarget[t1], t2
-        prepareCall(t2, t1, t3, t4, macro (callPtrTag)
-            if POINTER_PROFILING
-                loadp LLIntCallLinkInfo::callPtrTag[t5], callPtrTag
-            end
-        end)
-		if POINTER_PROFILING
-			loadp LLIntCallLinkInfo::callPtrTag[t5], t3
-		end
-        callTargetFunction(t2, t3)
+        prepareCall(t2, t1, t3, t4)
+        callTargetFunction(t2)
     else
-        prepareCall(LLIntCallLinkInfo::machineCodeTarget[t1], t2, t3, t4, macro (callPtrTag)
-            if POINTER_PROFILING
-                loadp LLIntCallLinkInfo::callPtrTag[t5], callPtrTag
-            end
-        end)
-		if POINTER_PROFILING
-			loadp LLIntCallLinkInfo::callPtrTag[t5], t3
-		end
-        callTargetFunction(LLIntCallLinkInfo::machineCodeTarget[t1], t3)
+        prepareCall(LLIntCallLinkInfo::machineCodeTarget[t1], t2, t3, t4)
+        callTargetFunction(LLIntCallLinkInfo::machineCodeTarget[t1])
     end
 
 .opCallSlow:
@@ -2119,7 +2075,7 @@
     loadp Callee[cfr], t1
     andp MarkedBlockMask, t1
     loadp MarkedBlockFooterOffset + MarkedBlock::Footer::m_vm[t1], t1
-    jmp VM::targetMachinePCForThrow[t1], ExceptionHandlerPtrTag
+    jmp VM::targetMachinePCForThrow[t1]
 
 
 _llint_throw_during_call_trampoline:
@@ -2135,7 +2091,7 @@
     andp MarkedBlockMask, t0, t1
     loadp MarkedBlockFooterOffset + MarkedBlock::Footer::m_vm[t1], t1
     storep cfr, VM::topCallFrame[t1]
-    if ARM64 or ARM64E or C_LOOP
+    if ARM64 or C_LOOP
         storep lr, ReturnPC[cfr]
     end
     move cfr, a0
@@ -2150,12 +2106,12 @@
     else
         if X86_64_WIN
             subp 32, sp
-            call executableOffsetToFunction[t1], NativeCodePtrTag
+            call executableOffsetToFunction[t1]
             addp 32, sp
         else
             loadp _g_NativeCodePoison, t2
             xorp executableOffsetToFunction[t1], t2
-            call t2, NativeCodePtrTag
+            call t2
         end
     end
 
@@ -2180,7 +2136,7 @@
     andp MarkedBlockMask, t0, t1
     loadp MarkedBlockFooterOffset + MarkedBlock::Footer::m_vm[t1], t1
     storep cfr, VM::topCallFrame[t1]
-    if ARM64 or ARM64E or C_LOOP
+    if ARM64 or C_LOOP
         storep lr, ReturnPC[cfr]
     end
     move cfr, a0
@@ -2193,12 +2149,12 @@
     else
         if X86_64_WIN
             subp 32, sp
-            call offsetOfFunction[t1], InternalFunctionPtrTag
+            call offsetOfFunction[t1]
             addp 32, sp
         else
             loadp _g_NativeCodePoison, t2
             xorp offsetOfFunction[t1], t2
-            call t2, InternalFunctionPtrTag
+            call t2
         end
     end
 

Modified: trunk/Source/_javascript_Core/offlineasm/ast.rb (229446 => 229447)


--- trunk/Source/_javascript_Core/offlineasm/ast.rb	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/offlineasm/ast.rb	2018-03-09 02:16:27 UTC (rev 229447)
@@ -929,7 +929,6 @@
             $asm.putGlobalAnnotation
         when "emit"
             $asm.puts "#{operands[0].dump}"
-        when "tagReturnAddress", "untagReturnAddress"
         else
             raise "Unhandled opcode #{opcode} at #{codeOriginString}"
         end

Modified: trunk/Source/_javascript_Core/offlineasm/backends.rb (229446 => 229447)


--- trunk/Source/_javascript_Core/offlineasm/backends.rb	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/offlineasm/backends.rb	2018-03-09 02:16:27 UTC (rev 229447)
@@ -29,11 +29,6 @@
 require "mips"
 require "cloop"
 
-begin
-    require "arm64e"
-rescue LoadError
-end
-
 BACKENDS =
     [
      "X86",
@@ -44,7 +39,6 @@
      "ARMv7",
      "ARMv7_TRADITIONAL",
      "ARM64",
-     "ARM64E",
      "MIPS",
      "C_LOOP"
     ]
@@ -64,7 +58,6 @@
      "ARMv7",
      "ARMv7_TRADITIONAL",
      "ARM64",
-     "ARM64E",
      "MIPS",
      "C_LOOP"
     ]

Modified: trunk/Source/_javascript_Core/offlineasm/instructions.rb (229446 => 229447)


--- trunk/Source/_javascript_Core/offlineasm/instructions.rb	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/offlineasm/instructions.rb	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,4 +1,4 @@
-# Copyright (C) 2011-2018 Apple Inc. All rights reserved.
+# Copyright (C) 2011 Apple Inc. All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
 # modification, are permitted provided that the following conditions
@@ -249,10 +249,7 @@
      "bnz",
      "leai",
      "leap",
-     "memfence",
-     "tagReturnAddress",
-     "untagReturnAddress",
-     "removeCodePtrTag"
+     "memfence"
     ]
 
 X86_INSTRUCTIONS =

Modified: trunk/Source/_javascript_Core/offlineasm/risc.rb (229446 => 229447)


--- trunk/Source/_javascript_Core/offlineasm/risc.rb	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/offlineasm/risc.rb	2018-03-09 02:16:27 UTC (rev 229447)
@@ -448,15 +448,9 @@
 
 def riscLowerMisplacedAddresses(list)
     newList = []
-    hasBackendSpecificLowering = Instruction.respond_to? "lowerMisplacedAddresses#{$activeBackend}"
     list.each {
         | node |
         if node.is_a? Instruction
-            if hasBackendSpecificLowering
-                wasHandled, newList = Instruction.send("lowerMisplacedAddresses#{$activeBackend}", node, newList)
-                next if wasHandled
-            end
-
             postInstructions = []
             annotation = node.annotation
             case node.opcode

Deleted: trunk/Source/_javascript_Core/runtime/PtrTag.h (229446 => 229447)


--- trunk/Source/_javascript_Core/runtime/PtrTag.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/_javascript_Core/runtime/PtrTag.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,84 +0,0 @@
-/*
- * Copyright (C) 2018 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#pragma once
-
-#include <wtf/PointerPreparations.h>
-
-namespace JSC {
-
-enum PtrTag : uintptr_t {
-    NoPtrTag = 0,
-    NearCallPtrTag,
-    CFunctionPtrTag,
-
-    BytecodePtrTag,
-    BytecodeHelperPtrTag,
-    CodeEntryPtrTag,
-    CodeEntryWithArityCheckPtrTag,
-    ExceptionHandlerPtrTag,
-    InternalFunctionPtrTag,
-    JITCodePtrTag,
-    NativeCodePtrTag,
-    SlowPathPtrTag,
-};
-
-#if !USE(POINTER_PROFILING)
-inline uintptr_t uniquePtrTagID() { return 0; }
-
-template<typename... Arguments>
-inline constexpr PtrTag ptrTag(Arguments&&...) { return NoPtrTag; }
-
-template<typename T, typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value && !std::is_same<T, PtrType>::value>>
-inline constexpr T tagCodePtr(PtrType ptr, PtrTag) { return bitwise_cast<T>(ptr); }
-
-template<typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value>>
-inline constexpr PtrType tagCodePtr(PtrType ptr, PtrTag) { return ptr; }
-
-template<typename T, typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value && !std::is_same<T, PtrType>::value>>
-inline constexpr T untagCodePtr(PtrType ptr, PtrTag) { return bitwise_cast<T>(ptr); }
-
-template<typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value>>
-inline constexpr PtrType untagCodePtr(PtrType ptr, PtrTag) { return ptr; }
-
-template<typename T, typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value && !std::is_same<T, PtrType>::value>>
-inline constexpr T retagCodePtr(PtrType ptr, PtrTag, PtrTag) { return bitwise_cast<T>(ptr); }
-
-template<typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value>>
-inline constexpr PtrType retagCodePtr(PtrType ptr, PtrTag, PtrTag) { return ptr; }
-
-template<typename T, typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value && !std::is_same<T, PtrType>::value>>
-inline constexpr T removeCodePtrTag(PtrType ptr) { return bitwise_cast<T>(ptr); }
-
-template<typename PtrType, typename = std::enable_if_t<std::is_pointer<PtrType>::value>>
-inline constexpr PtrType removeCodePtrTag(PtrType ptr) { return ptr; }
-
-#endif // !USE(POINTER_PROFILING)
-
-} // namespace JSC
-
-#if USE(APPLE_INTERNAL_SDK) && __has_include(<WebKitAdditions/PtrTagSupport.h>)
-#include <WebKitAdditions/PtrTagSupport.h>
-#endif

Modified: trunk/Source/WTF/ChangeLog (229446 => 229447)


--- trunk/Source/WTF/ChangeLog	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/WTF/ChangeLog	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1,3 +1,20 @@
+2018-03-08  Commit Queue  <[email protected]>
+
+        Unreviewed, rolling out r229354 and r229364.
+        https://bugs.webkit.org/show_bug.cgi?id=183492
+
+        Breaks internal builds (Requested by ryanhaddad on #webkit).
+
+        Reverted changesets:
+
+        "Prepare LLInt code to support pointer profiling."
+        https://bugs.webkit.org/show_bug.cgi?id=183387
+        https://trac.webkit.org/changeset/229354
+
+        "Add support for ARM64E."
+        https://bugs.webkit.org/show_bug.cgi?id=183398
+        https://trac.webkit.org/changeset/229364
+
 2018-03-08  Filip Pizlo  <[email protected]>
 
         bmalloc mutex should be adaptive

Modified: trunk/Source/WTF/wtf/Platform.h (229446 => 229447)


--- trunk/Source/WTF/wtf/Platform.h	2018-03-09 01:46:23 UTC (rev 229446)
+++ trunk/Source/WTF/wtf/Platform.h	2018-03-09 02:16:27 UTC (rev 229447)
@@ -1012,11 +1012,6 @@
 #define ENABLE_POISON 0
 #endif
 
-#if !defined(USE_POINTER_PROFILING) || USE(JSVALUE32_64) || !ENABLE(JIT)
-#undef USE_POINTER_PROFILING
-#define USE_POINTER_PROFILING 0
-#endif
-
 /* CSS Selector JIT Compiler */
 #if !defined(ENABLE_CSS_SELECTOR_JIT)
 #if (CPU(X86_64) || CPU(ARM64) || (CPU(ARM_THUMB2) && PLATFORM(IOS))) && ENABLE(JIT) && (OS(DARWIN) || PLATFORM(GTK) || PLATFORM(WPE))
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to