summaryrefslogtreecommitdiff
path: root/patches/patch-Source_JavaScriptCore_llint_LowLevelInterpreter_asm
blob: 209a0e5814dae96af79eb757970475cf298755c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
$OpenBSD: patch-Source_JavaScriptCore_llint_LowLevelInterpreter_asm,v 1.2 2013/10/06 14:03:42 landry Exp $
https://bugs.webkit.org/show_bug.cgi?id=103128
https://bug-103128-attachments.webkit.org/attachment.cgi?id=202076
Last chunk: https://bug-103128-attachments.webkit.org/attachment.cgi?id=202651
--- Source/JavaScriptCore/llint/LowLevelInterpreter.asm.orig	Tue Feb  4 17:38:03 2014
+++ Source/JavaScriptCore/llint/LowLevelInterpreter.asm	Fri Feb 14 22:47:15 2014
@@ -122,6 +122,12 @@ else
     const PayloadOffset = 0
 end
 
+if JSVALUE64
+    const CellOffset = 0
+else
+    const CellOffset = PayloadOffset
+end
+
 # Constant for reasoning about butterflies.
 const IsArray                  = 1
 const IndexingShapeMask        = 30
@@ -299,13 +305,13 @@ macro assertNotConstant(index)
 end
 
 macro functionForCallCodeBlockGetter(targetRegister)
-    loadp Callee[cfr], targetRegister
+    loadp Callee + CellOffset[cfr], targetRegister
     loadp JSFunction::m_executable[targetRegister], targetRegister
     loadp FunctionExecutable::m_codeBlockForCall[targetRegister], targetRegister
 end
 
 macro functionForConstructCodeBlockGetter(targetRegister)
-    loadp Callee[cfr], targetRegister
+    loadp Callee + CellOffset[cfr], targetRegister
     loadp JSFunction::m_executable[targetRegister], targetRegister
     loadp FunctionExecutable::m_codeBlockForConstruct[targetRegister], targetRegister
 end
@@ -696,6 +702,11 @@ _llint_op_loop_hint:
     loadp CodeBlock[cfr], t1
     loadp CodeBlock::m_vm[t1], t1
     loadb VM::watchdog+Watchdog::m_timerDidFire[t1], t0
+    if FOUR_BYTE_BOOL
+        loadi VM::watchdog+Watchdog::m_timerDidFire[t1], t0
+    else
+        loadb VM::watchdog+Watchdog::m_timerDidFire[t1], t0
+    end
     btbnz t0, .handleWatchdogTimer
 .afterWatchdogTimerCheck:
     checkSwitchToJITForLoop()