therubyracer 0.6.3 → 0.7.0.pre
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of therubyracer might be problematic. Click here for more details.
- data/Rakefile +10 -9
- data/ext/v8/callbacks.cpp +15 -8
- data/ext/v8/converters.cpp +7 -8
- data/ext/v8/converters.h +0 -2
- data/ext/v8/extconf.rb +2 -0
- data/ext/v8/rr.cpp +169 -0
- data/ext/v8/rr.h +34 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/AUTHORS +8 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/ChangeLog +198 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/LICENSE +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/SConstruct +152 -38
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/include/v8-debug.h +52 -4
- data/ext/v8/upstream/2.1.10/include/v8-profiler.h +176 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/include/v8.h +227 -48
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/SConscript +60 -10
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/accessors.cc +5 -39
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/accessors.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/allocation.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/allocation.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/api.cc +477 -57
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/api.h +8 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/apinatives.js +1 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/apiutils.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arguments.h +5 -6
- data/ext/v8/upstream/{2.0.6/src/arm/assembler-thumb2-inl.h → 2.1.10/src/arm/assembler-arm-inl.h} +42 -27
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/assembler-arm.cc +430 -216
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/assembler-arm.h +199 -110
- data/ext/v8/upstream/{2.0.6/src/arm/assembler-arm-inl.h → 2.1.10/src/arm/assembler-thumb2-inl.h} +4 -18
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/assembler-thumb2.cc +142 -85
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/assembler-thumb2.h +18 -9
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/builtins-arm.cc +127 -87
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/codegen-arm-inl.h +3 -5
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/codegen-arm.cc +4634 -1427
- data/ext/v8/upstream/2.1.10/src/arm/codegen-arm.h +946 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/constants-arm.cc +21 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/constants-arm.h +39 -13
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/cpu-arm.cc +9 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/debug-arm.cc +34 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/disasm-arm.cc +262 -117
- data/ext/v8/upstream/2.1.10/src/arm/fast-codegen-arm.cc +238 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/frames-arm.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/frames-arm.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/arm/fast-codegen-arm.cc → 2.1.10/src/arm/full-codegen-arm.cc} +453 -283
- data/ext/v8/upstream/2.1.10/src/arm/ic-arm.cc +1833 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/jump-target-arm.cc +3 -29
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/macro-assembler-arm.cc +564 -104
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/macro-assembler-arm.h +255 -46
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/regexp-macro-assembler-arm.cc +78 -104
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/regexp-macro-assembler-arm.h +6 -22
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/register-allocator-arm-inl.h +0 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/register-allocator-arm.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/register-allocator-arm.h +2 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/simulator-arm.cc +557 -180
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/simulator-arm.h +52 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/arm/stub-cache-arm.cc +904 -240
- data/ext/v8/upstream/2.1.10/src/arm/virtual-frame-arm.cc +668 -0
- data/ext/v8/upstream/2.1.10/src/arm/virtual-frame-arm.h +503 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/array.js +82 -109
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/assembler.cc +49 -13
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/assembler.h +27 -5
- data/ext/v8/upstream/2.1.10/src/ast.cc +1138 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ast.h +354 -53
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/bootstrapper.cc +609 -501
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/bootstrapper.h +27 -8
- data/ext/v8/upstream/2.1.10/src/builtins.cc +1512 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/builtins.h +41 -25
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/bytecodes-irregexp.h +0 -0
- data/ext/v8/upstream/2.1.10/src/cached-powers.h +119 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/char-predicates-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/char-predicates.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/checks.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/checks.h +25 -1
- data/ext/v8/upstream/2.1.10/src/circular-queue-inl.h +101 -0
- data/ext/v8/upstream/2.1.10/src/circular-queue.cc +121 -0
- data/ext/v8/upstream/2.1.10/src/circular-queue.h +129 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/code-stubs.cc +23 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/code-stubs.h +16 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/code.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/codegen-inl.h +6 -34
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/codegen.cc +73 -92
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/codegen.h +164 -68
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/compilation-cache.cc +117 -73
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/compilation-cache.h +18 -17
- data/ext/v8/upstream/2.1.10/src/compiler.cc +623 -0
- data/ext/v8/upstream/2.1.10/src/compiler.h +299 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/contexts.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/contexts.h +8 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/conversions-inl.h +28 -13
- data/ext/v8/upstream/2.1.10/src/conversions.cc +1105 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/conversions.h +9 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/counters.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/counters.h +1 -1
- data/ext/v8/upstream/2.1.10/src/cpu-profiler-inl.h +99 -0
- data/ext/v8/upstream/2.1.10/src/cpu-profiler.cc +494 -0
- data/ext/v8/upstream/2.1.10/src/cpu-profiler.h +277 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/cpu.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8-debug.cc +15 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8-debug.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8-posix.cc +18 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8-readline.cc +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8-windows.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8.cc +10 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8.h +2 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/d8.js +43 -38
- data/ext/v8/upstream/2.1.10/src/data-flow.cc +755 -0
- data/ext/v8/upstream/2.1.10/src/data-flow.h +278 -0
- data/ext/v8/upstream/{2.0.6/src/date-delay.js → 2.1.10/src/date.js} +100 -110
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/dateparser-inl.h +11 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/dateparser.cc +24 -26
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/dateparser.h +8 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/debug-agent.cc +3 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/debug-agent.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/debug-delay.js → 2.1.10/src/debug-debugger.js} +111 -15
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/debug.cc +156 -96
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/debug.h +53 -5
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/disasm.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/disassembler.cc +2 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/disassembler.h +0 -0
- data/ext/v8/upstream/2.1.10/src/diy-fp.cc +58 -0
- data/ext/v8/upstream/2.1.10/src/diy-fp.h +117 -0
- data/ext/v8/upstream/2.1.10/src/double.h +169 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/dtoa-config.c +4 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/execution.cc +22 -22
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/execution.h +17 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/factory.cc +70 -46
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/factory.h +27 -17
- data/ext/v8/upstream/2.1.10/src/fast-codegen.cc +746 -0
- data/ext/v8/upstream/2.1.10/src/fast-codegen.h +161 -0
- data/ext/v8/upstream/2.1.10/src/fast-dtoa.cc +512 -0
- data/ext/v8/upstream/2.1.10/src/fast-dtoa.h +59 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/flag-definitions.h +32 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/flags.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/flags.h +0 -0
- data/ext/v8/upstream/2.1.10/src/flow-graph.cc +763 -0
- data/ext/v8/upstream/2.1.10/src/flow-graph.h +180 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/frame-element.cc +1 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/frame-element.h +49 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/frames-inl.h +2 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/frames.cc +91 -17
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/frames.h +24 -2
- data/ext/v8/upstream/{2.0.6/src/fast-codegen.cc → 2.1.10/src/full-codegen.cc} +549 -198
- data/ext/v8/upstream/{2.0.6/src/fast-codegen.h → 2.1.10/src/full-codegen.h} +109 -29
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/func-name-inferrer.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/func-name-inferrer.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/global-handles.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/global-handles.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/globals.h +67 -43
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/handles-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/handles.cc +124 -129
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/handles.h +33 -15
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/hashmap.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/hashmap.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/heap-inl.h +56 -12
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/heap-profiler.cc +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/heap-profiler.h +2 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/heap.cc +413 -221
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/heap.h +192 -67
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/assembler-ia32-inl.h +6 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/assembler-ia32.cc +187 -32
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/assembler-ia32.h +31 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/builtins-ia32.cc +160 -133
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/codegen-ia32-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/codegen-ia32.cc +5533 -2177
- data/ext/v8/upstream/{2.0.6/src/x64/codegen-x64.h → 2.1.10/src/ia32/codegen-ia32.h} +453 -134
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/cpu-ia32.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/debug-ia32.cc +63 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/disasm-ia32.cc +99 -16
- data/ext/v8/upstream/2.1.10/src/ia32/fast-codegen-ia32.cc +950 -0
- data/ext/v8/upstream/2.1.10/src/ia32/fast-codegen-ia32.h +155 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/frames-ia32.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/frames-ia32.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/ia32/fast-codegen-ia32.cc → 2.1.10/src/ia32/full-codegen-ia32.cc} +454 -253
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/ic-ia32.cc +545 -390
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/jump-target-ia32.cc +1 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/macro-assembler-ia32.cc +330 -139
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/macro-assembler-ia32.h +96 -30
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/regexp-macro-assembler-ia32.cc +73 -89
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/regexp-macro-assembler-ia32.h +6 -21
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/register-allocator-ia32-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/register-allocator-ia32.cc +59 -5
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/register-allocator-ia32.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/simulator-ia32.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/simulator-ia32.h +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/stub-cache-ia32.cc +745 -303
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/virtual-frame-ia32.cc +278 -71
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ia32/virtual-frame-ia32.h +78 -22
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ic-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ic.cc +172 -89
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/ic.h +51 -20
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/interpreter-irregexp.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/interpreter-irregexp.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/json-delay.js → 2.1.10/src/json.js} +26 -12
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/jsregexp.cc +151 -118
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/jsregexp.h +31 -7
- data/ext/v8/upstream/2.1.10/src/jump-target-heavy-inl.h +51 -0
- data/ext/v8/upstream/{2.0.6/src/jump-target.cc → 2.1.10/src/jump-target-heavy.cc} +164 -184
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/jump-target-inl.h +8 -9
- data/ext/v8/upstream/{2.0.6/src/usage-analyzer.h → 2.1.10/src/jump-target-light-inl.h} +9 -7
- data/ext/v8/upstream/2.1.10/src/jump-target-light.cc +86 -0
- data/ext/v8/upstream/2.1.10/src/jump-target.cc +155 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/jump-target.h +6 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/list-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/list.h +2 -1
- data/ext/v8/upstream/2.1.10/src/liveedit-debugger.js +944 -0
- data/ext/v8/upstream/2.1.10/src/liveedit.cc +1468 -0
- data/ext/v8/upstream/2.1.10/src/liveedit.h +170 -0
- data/ext/v8/upstream/2.1.10/src/log-inl.h +59 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/log-utils.cc +3 -9
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/log-utils.h +1 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/log.cc +198 -95
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/log.h +50 -49
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/macro-assembler.h +9 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/macros.py +30 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/mark-compact.cc +464 -152
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/mark-compact.h +41 -20
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/math.js +9 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/memory.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/messages.cc +1 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/messages.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/messages.js +46 -9
- data/ext/v8/upstream/2.1.10/src/mips/assembler-mips-inl.h +215 -0
- data/ext/v8/upstream/2.1.10/src/mips/assembler-mips.cc +1208 -0
- data/ext/v8/upstream/2.1.10/src/mips/assembler-mips.h +665 -0
- data/ext/v8/upstream/2.1.10/src/mips/builtins-mips.cc +202 -0
- data/ext/v8/upstream/2.1.10/src/mips/codegen-mips-inl.h +70 -0
- data/ext/v8/upstream/2.1.10/src/mips/codegen-mips.cc +1428 -0
- data/ext/v8/upstream/{2.0.6/src/arm/codegen-arm.h → 2.1.10/src/mips/codegen-mips.h} +103 -205
- data/ext/v8/upstream/2.1.10/src/mips/constants-mips.cc +323 -0
- data/ext/v8/upstream/2.1.10/src/mips/constants-mips.h +525 -0
- data/ext/v8/upstream/2.1.10/src/mips/cpu-mips.cc +69 -0
- data/ext/v8/upstream/2.1.10/src/mips/debug-mips.cc +128 -0
- data/ext/v8/upstream/2.1.10/src/mips/disasm-mips.cc +784 -0
- data/ext/v8/upstream/2.1.10/src/mips/fast-codegen-mips.cc +74 -0
- data/ext/v8/upstream/2.1.10/src/mips/frames-mips.cc +99 -0
- data/ext/v8/upstream/2.1.10/src/mips/frames-mips.h +164 -0
- data/ext/v8/upstream/2.1.10/src/mips/full-codegen-mips.cc +273 -0
- data/ext/v8/upstream/2.1.10/src/mips/ic-mips.cc +217 -0
- data/ext/v8/upstream/2.1.10/src/mips/jump-target-mips.cc +172 -0
- data/ext/v8/upstream/2.1.10/src/mips/macro-assembler-mips.cc +1323 -0
- data/ext/v8/upstream/2.1.10/src/mips/macro-assembler-mips.h +461 -0
- data/ext/v8/upstream/2.1.10/src/mips/register-allocator-mips-inl.h +137 -0
- data/ext/v8/upstream/2.1.10/src/mips/register-allocator-mips.cc +60 -0
- data/ext/v8/upstream/2.1.10/src/mips/register-allocator-mips.h +46 -0
- data/ext/v8/upstream/2.1.10/src/mips/simulator-mips.cc +1648 -0
- data/ext/v8/upstream/2.1.10/src/mips/simulator-mips.h +311 -0
- data/ext/v8/upstream/2.1.10/src/mips/stub-cache-mips.cc +400 -0
- data/ext/v8/upstream/2.1.10/src/mips/virtual-frame-mips.cc +316 -0
- data/ext/v8/upstream/{2.0.6/src/arm/virtual-frame-arm.h → 2.1.10/src/mips/virtual-frame-mips.h} +87 -71
- data/ext/v8/upstream/{2.0.6/src/mirror-delay.js → 2.1.10/src/mirror-debugger.js} +51 -45
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/mksnapshot.cc +97 -10
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/natives.h +6 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/objects-debug.cc +47 -5
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/objects-inl.h +154 -38
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/objects.cc +528 -280
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/objects.h +302 -95
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/oprofile-agent.cc +25 -33
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/oprofile-agent.h +9 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/parser.cc +444 -72
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/parser.h +4 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-freebsd.cc +32 -13
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-linux.cc +59 -25
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-macos.cc +30 -13
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-nullos.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-openbsd.cc +21 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-posix.cc +0 -18
- data/ext/v8/upstream/2.1.10/src/platform-solaris.cc +607 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform-win32.cc +16 -17
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/platform.h +25 -8
- data/ext/v8/upstream/2.1.10/src/powers-ten.h +2461 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/prettyprinter.cc +49 -29
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/prettyprinter.h +3 -1
- data/ext/v8/upstream/2.1.10/src/profile-generator-inl.h +124 -0
- data/ext/v8/upstream/2.1.10/src/profile-generator.cc +583 -0
- data/ext/v8/upstream/2.1.10/src/profile-generator.h +364 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/property.cc +1 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/property.h +12 -24
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler-irregexp-inl.h +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler-irregexp.cc +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler-irregexp.h +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler-tracer.cc +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler-tracer.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler.cc +33 -10
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-macro-assembler.h +12 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-stack.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/regexp-stack.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/regexp-delay.js → 2.1.10/src/regexp.js} +180 -58
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/register-allocator-inl.h +68 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/register-allocator.cc +5 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/register-allocator.h +42 -17
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/rewriter.cc +110 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/rewriter.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/runtime.cc +2733 -623
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/runtime.h +43 -20
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/runtime.js +46 -35
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scanner.cc +278 -36
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scanner.h +97 -26
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scopeinfo.cc +3 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scopeinfo.h +1 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scopes.cc +11 -12
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/scopes.h +0 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/serialize.cc +298 -175
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/serialize.h +184 -40
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/shell.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/simulator.h +2 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/smart-pointer.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/snapshot-common.cc +16 -31
- data/ext/v8/upstream/2.1.10/src/snapshot-empty.cc +50 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/snapshot.h +13 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/spaces-inl.h +35 -27
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/spaces.cc +256 -42
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/spaces.h +136 -42
- data/ext/v8/upstream/{2.0.6/src/zone-inl.h → 2.1.10/src/splay-tree-inl.h} +102 -89
- data/ext/v8/upstream/2.1.10/src/splay-tree.h +203 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/string-stream.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/string-stream.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/string.js +260 -149
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/stub-cache.cc +195 -69
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/stub-cache.h +127 -12
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/third_party/dtoa/COPYING +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/third_party/dtoa/dtoa.c +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/third_party/valgrind/valgrind.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/token.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/token.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/top.cc +26 -31
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/top.h +3 -4
- data/ext/v8/upstream/2.1.10/src/type-info.cc +53 -0
- data/ext/v8/upstream/2.1.10/src/type-info.h +244 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/unicode-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/unicode.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/unicode.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/uri.js +6 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/utils.cc +0 -37
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/utils.h +121 -50
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8-counters.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8-counters.h +130 -98
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8.cc +42 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8.h +4 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8natives.js +202 -37
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8threads.cc +11 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/v8threads.h +15 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/variables.cc +7 -51
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/variables.h +5 -35
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/version.cc +3 -3
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/version.h +0 -0
- data/ext/v8/upstream/2.1.10/src/virtual-frame-heavy-inl.h +152 -0
- data/ext/v8/upstream/{2.0.6/src/virtual-frame.cc → 2.1.10/src/virtual-frame-heavy.cc} +107 -176
- data/ext/v8/upstream/2.1.10/src/virtual-frame-inl.h +39 -0
- data/ext/v8/upstream/2.1.10/src/virtual-frame-light-inl.h +69 -0
- data/ext/v8/upstream/2.1.10/src/virtual-frame-light.cc +49 -0
- data/ext/v8/upstream/2.1.10/src/virtual-frame.cc +49 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/virtual-frame.h +2 -0
- data/ext/v8/upstream/{2.0.6/src/log-inl.h → 2.1.10/src/vm-state-inl.h} +28 -20
- data/ext/v8/upstream/{2.0.6/src/snapshot-empty.cc → 2.1.10/src/vm-state.cc} +5 -6
- data/ext/v8/upstream/2.1.10/src/vm-state.h +75 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/assembler-x64-inl.h +11 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/assembler-x64.cc +285 -93
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/assembler-x64.h +81 -78
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/builtins-x64.cc +130 -87
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/codegen-x64-inl.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/codegen-x64.cc +4520 -1317
- data/ext/v8/upstream/{2.0.6/src/ia32/codegen-ia32.h → 2.1.10/src/x64/codegen-x64.h} +362 -141
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/cpu-x64.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/debug-x64.cc +20 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/disasm-x64.cc +121 -44
- data/ext/v8/upstream/2.1.10/src/x64/fast-codegen-x64.cc +246 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/frames-x64.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/frames-x64.h +0 -0
- data/ext/v8/upstream/{2.0.6/src/x64/fast-codegen-x64.cc → 2.1.10/src/x64/full-codegen-x64.cc} +404 -231
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/ic-x64.cc +346 -117
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/jump-target-x64.cc +1 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/macro-assembler-x64.cc +537 -181
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/macro-assembler-x64.h +140 -34
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/regexp-macro-assembler-x64.cc +74 -96
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/regexp-macro-assembler-x64.h +8 -25
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/register-allocator-x64-inl.h +1 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/register-allocator-x64.cc +3 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/register-allocator-x64.h +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/simulator-x64.cc +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/simulator-x64.h +2 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/stub-cache-x64.cc +785 -288
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/virtual-frame-x64.cc +128 -52
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/x64/virtual-frame-x64.h +40 -19
- data/ext/v8/upstream/2.1.10/src/zone-inl.h +82 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/zone.cc +1 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/src/zone.h +6 -90
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/codemap.js +12 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/consarray.js +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/csvparser.js +22 -37
- data/ext/v8/upstream/2.1.10/tools/generate-ten-powers.scm +286 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/gyp/v8.gyp +86 -24
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/js2c.py +22 -22
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/jsmin.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/linux-tick-processor +10 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/linux-tick-processor.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/logreader.js +34 -16
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/mac-nm +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/mac-tick-processor +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/annotate +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/common +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/dump +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/report +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/reset +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/run +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/shutdown +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/oprofile/start +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/presubmit.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/process-heap-prof.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/profile.js +70 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/profile_view.js +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/run-valgrind.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/splaytree.js +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/splaytree.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/stats-viewer.py +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/test.py +7 -7
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/tickprocessor-driver.js +7 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/tickprocessor.js +140 -9
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/tickprocessor.py +40 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/utils.py +6 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/README.txt +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/arm.vsprops +1 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/common.vsprops +1 -2
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/d8.vcproj +0 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/d8_arm.vcproj +193 -199
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/d8_x64.vcproj +16 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/d8js2c.cmd +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/debug.vsprops +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/ia32.vsprops +5 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/js2c.cmd +1 -1
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/release.vsprops +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8.sln +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8.vcproj +11 -7
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_arm.sln +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_arm.vcproj +227 -223
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_base.vcproj +137 -5
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_base_arm.vcproj +116 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_base_x64.vcproj +125 -4
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_cctest.vcproj +12 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_cctest_arm.vcproj +12 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_cctest_x64.vcproj +11 -11
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_mksnapshot.vcproj +0 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_mksnapshot_x64.vcproj +0 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_process_sample.vcproj +0 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_process_sample_arm.vcproj +145 -151
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_process_sample_x64.vcproj +16 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_shell_sample.vcproj +0 -6
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_shell_sample_arm.vcproj +145 -151
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_shell_sample_x64.vcproj +16 -8
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_snapshot.vcproj +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_snapshot_cc.vcproj +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_snapshot_cc_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_snapshot_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_x64.sln +0 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/v8_x64.vcproj +11 -7
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/visual_studio/x64.vsprops +5 -1
- data/ext/v8/upstream/2.1.10/tools/windows-tick-processor.bat +29 -0
- data/ext/v8/upstream/{2.0.6 → 2.1.10}/tools/windows-tick-processor.py +0 -0
- data/ext/v8/upstream/Makefile +8 -2
- data/ext/v8/v8.cpp +21 -73
- data/ext/v8/v8_array.cpp +56 -0
- data/ext/v8/v8_array.h +8 -0
- data/ext/v8/v8_callbacks.cpp +121 -0
- data/ext/v8/v8_callbacks.h +8 -0
- data/ext/v8/v8_cxt.cpp +74 -77
- data/ext/v8/v8_cxt.h +2 -9
- data/ext/v8/v8_date.cpp +26 -0
- data/ext/v8/v8_date.h +6 -0
- data/ext/v8/v8_exception.cpp +55 -0
- data/ext/v8/v8_exception.h +6 -0
- data/ext/v8/v8_external.cpp +50 -0
- data/ext/v8/v8_external.h +8 -0
- data/ext/v8/v8_func.cpp +76 -18
- data/ext/v8/v8_func.h +5 -4
- data/ext/v8/v8_msg.cpp +55 -46
- data/ext/v8/v8_msg.h +3 -11
- data/ext/v8/v8_obj.cpp +67 -36
- data/ext/v8/v8_obj.h +6 -8
- data/ext/v8/v8_ref.cpp +25 -9
- data/ext/v8/v8_ref.h +3 -5
- data/ext/v8/v8_script.cpp +17 -10
- data/ext/v8/v8_script.h +3 -3
- data/ext/v8/v8_str.cpp +34 -6
- data/ext/v8/v8_str.h +4 -2
- data/ext/v8/v8_template.cpp +195 -33
- data/ext/v8/v8_template.h +4 -5
- data/ext/v8/v8_try_catch.cpp +99 -0
- data/ext/v8/v8_try_catch.h +5 -0
- data/ext/v8/v8_value.cpp +164 -0
- data/ext/v8/v8_value.h +10 -0
- data/lib/v8.rb +3 -1
- data/lib/v8/access.rb +60 -0
- data/lib/v8/array.rb +15 -0
- data/lib/v8/callbacks.rb +88 -0
- data/lib/v8/cli.rb +1 -1
- data/lib/v8/context.rb +55 -66
- data/lib/v8/function.rb +20 -2
- data/lib/v8/object.rb +14 -12
- data/lib/v8/ruby_error.rb +3 -0
- data/lib/v8/to.rb +59 -7
- data/spec/ext/cxt_spec.rb +2 -15
- data/spec/ext/func_spec.rb +17 -10
- data/spec/ext/try_catch_spec.rb +32 -0
- data/spec/foo.rb +17 -0
- data/spec/redjs/jsapi_spec.rb +173 -96
- data/spec/spec_helper.rb +7 -0
- data/spec/v8/to_spec.rb +0 -1
- data/therubyracer.gemspec +6 -6
- metadata +493 -386
- data/ext/v8/upstream/2.0.6/src/arm/ic-arm.cc +0 -849
- data/ext/v8/upstream/2.0.6/src/arm/virtual-frame-arm.cc +0 -412
- data/ext/v8/upstream/2.0.6/src/ast.cc +0 -512
- data/ext/v8/upstream/2.0.6/src/builtins.cc +0 -851
- data/ext/v8/upstream/2.0.6/src/compiler.cc +0 -1132
- data/ext/v8/upstream/2.0.6/src/compiler.h +0 -107
- data/ext/v8/upstream/2.0.6/src/conversions.cc +0 -709
- data/ext/v8/upstream/2.0.6/src/usage-analyzer.cc +0 -426
- data/ext/v8/upstream/2.0.6/tools/windows-tick-processor.bat +0 -5
- data/ext/v8/upstream/no-strict-aliasing.patch +0 -13
- data/ext/v8/v8_standalone.cpp +0 -69
- data/ext/v8/v8_standalone.h +0 -31
- data/spec/ext/obj_spec.rb +0 -13
@@ -113,56 +113,28 @@ struct Register {
|
|
113
113
|
return code_ & 0x7;
|
114
114
|
}
|
115
115
|
|
116
|
-
//
|
117
|
-
// by assignment.
|
116
|
+
// Unfortunately we can't make this private in a struct when initializing
|
117
|
+
// by assignment.
|
118
118
|
int code_;
|
119
119
|
};
|
120
120
|
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
struct MMXRegister {
|
141
|
-
bool is_valid() const { return 0 <= code_ && code_ < 2; }
|
142
|
-
int code() const {
|
143
|
-
ASSERT(is_valid());
|
144
|
-
return code_;
|
145
|
-
}
|
146
|
-
|
147
|
-
int code_;
|
148
|
-
};
|
149
|
-
|
150
|
-
extern MMXRegister mm0;
|
151
|
-
extern MMXRegister mm1;
|
152
|
-
extern MMXRegister mm2;
|
153
|
-
extern MMXRegister mm3;
|
154
|
-
extern MMXRegister mm4;
|
155
|
-
extern MMXRegister mm5;
|
156
|
-
extern MMXRegister mm6;
|
157
|
-
extern MMXRegister mm7;
|
158
|
-
extern MMXRegister mm8;
|
159
|
-
extern MMXRegister mm9;
|
160
|
-
extern MMXRegister mm10;
|
161
|
-
extern MMXRegister mm11;
|
162
|
-
extern MMXRegister mm12;
|
163
|
-
extern MMXRegister mm13;
|
164
|
-
extern MMXRegister mm14;
|
165
|
-
extern MMXRegister mm15;
|
121
|
+
const Register rax = { 0 };
|
122
|
+
const Register rcx = { 1 };
|
123
|
+
const Register rdx = { 2 };
|
124
|
+
const Register rbx = { 3 };
|
125
|
+
const Register rsp = { 4 };
|
126
|
+
const Register rbp = { 5 };
|
127
|
+
const Register rsi = { 6 };
|
128
|
+
const Register rdi = { 7 };
|
129
|
+
const Register r8 = { 8 };
|
130
|
+
const Register r9 = { 9 };
|
131
|
+
const Register r10 = { 10 };
|
132
|
+
const Register r11 = { 11 };
|
133
|
+
const Register r12 = { 12 };
|
134
|
+
const Register r13 = { 13 };
|
135
|
+
const Register r14 = { 14 };
|
136
|
+
const Register r15 = { 15 };
|
137
|
+
const Register no_reg = { -1 };
|
166
138
|
|
167
139
|
|
168
140
|
struct XMMRegister {
|
@@ -186,22 +158,22 @@ struct XMMRegister {
|
|
186
158
|
int code_;
|
187
159
|
};
|
188
160
|
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
161
|
+
const XMMRegister xmm0 = { 0 };
|
162
|
+
const XMMRegister xmm1 = { 1 };
|
163
|
+
const XMMRegister xmm2 = { 2 };
|
164
|
+
const XMMRegister xmm3 = { 3 };
|
165
|
+
const XMMRegister xmm4 = { 4 };
|
166
|
+
const XMMRegister xmm5 = { 5 };
|
167
|
+
const XMMRegister xmm6 = { 6 };
|
168
|
+
const XMMRegister xmm7 = { 7 };
|
169
|
+
const XMMRegister xmm8 = { 8 };
|
170
|
+
const XMMRegister xmm9 = { 9 };
|
171
|
+
const XMMRegister xmm10 = { 10 };
|
172
|
+
const XMMRegister xmm11 = { 11 };
|
173
|
+
const XMMRegister xmm12 = { 12 };
|
174
|
+
const XMMRegister xmm13 = { 13 };
|
175
|
+
const XMMRegister xmm14 = { 14 };
|
176
|
+
const XMMRegister xmm15 = { 15 };
|
205
177
|
|
206
178
|
enum Condition {
|
207
179
|
// any value < 0 is considered no_condition
|
@@ -308,7 +280,6 @@ enum ScaleFactor {
|
|
308
280
|
times_4 = 2,
|
309
281
|
times_8 = 3,
|
310
282
|
times_int_size = times_4,
|
311
|
-
times_half_pointer_size = times_4,
|
312
283
|
times_pointer_size = times_8
|
313
284
|
};
|
314
285
|
|
@@ -574,6 +545,13 @@ class Assembler : public Malloced {
|
|
574
545
|
void movzxwq(Register dst, const Operand& src);
|
575
546
|
void movzxwl(Register dst, const Operand& src);
|
576
547
|
|
548
|
+
// Repeated moves.
|
549
|
+
|
550
|
+
void repmovsb();
|
551
|
+
void repmovsw();
|
552
|
+
void repmovsl();
|
553
|
+
void repmovsq();
|
554
|
+
|
577
555
|
// New x64 instruction to load from an immediate 64-bit pointer into RAX.
|
578
556
|
void load_rax(void* ptr, RelocInfo::Mode rmode);
|
579
557
|
void load_rax(ExternalReference ext);
|
@@ -738,6 +716,9 @@ class Assembler : public Malloced {
|
|
738
716
|
arithmetic_op_32(0x23, dst, src);
|
739
717
|
}
|
740
718
|
|
719
|
+
void andb(Register dst, Immediate src) {
|
720
|
+
immediate_arithmetic_op_8(0x4, dst, src);
|
721
|
+
}
|
741
722
|
|
742
723
|
void decq(Register dst);
|
743
724
|
void decq(const Operand& dst);
|
@@ -761,14 +742,16 @@ class Assembler : public Malloced {
|
|
761
742
|
void imul(Register dst, Register src); // dst = dst * src.
|
762
743
|
void imul(Register dst, const Operand& src); // dst = dst * src.
|
763
744
|
void imul(Register dst, Register src, Immediate imm); // dst = src * imm.
|
764
|
-
//
|
765
|
-
void imull(Register dst, Register src);
|
745
|
+
// Signed 32-bit multiply instructions.
|
746
|
+
void imull(Register dst, Register src); // dst = dst * src.
|
747
|
+
void imull(Register dst, Register src, Immediate imm); // dst = src * imm.
|
766
748
|
|
767
749
|
void incq(Register dst);
|
768
750
|
void incq(const Operand& dst);
|
769
751
|
void incl(const Operand& dst);
|
770
752
|
|
771
753
|
void lea(Register dst, const Operand& src);
|
754
|
+
void leal(Register dst, const Operand& src);
|
772
755
|
|
773
756
|
// Multiply rax by src, put the result in rdx:rax.
|
774
757
|
void mul(Register src);
|
@@ -779,6 +762,7 @@ class Assembler : public Malloced {
|
|
779
762
|
|
780
763
|
void not_(Register dst);
|
781
764
|
void not_(const Operand& dst);
|
765
|
+
void notl(Register dst);
|
782
766
|
|
783
767
|
void or_(Register dst, Register src) {
|
784
768
|
arithmetic_op(0x0B, dst, src);
|
@@ -916,6 +900,10 @@ class Assembler : public Malloced {
|
|
916
900
|
arithmetic_op_32(0x2B, dst, src);
|
917
901
|
}
|
918
902
|
|
903
|
+
void subl(Register dst, const Operand& src) {
|
904
|
+
arithmetic_op_32(0x2B, dst, src);
|
905
|
+
}
|
906
|
+
|
919
907
|
void subl(const Operand& dst, Immediate src) {
|
920
908
|
immediate_arithmetic_op_32(0x5, dst, src);
|
921
909
|
}
|
@@ -931,6 +919,7 @@ class Assembler : public Malloced {
|
|
931
919
|
void testb(Register dst, Register src);
|
932
920
|
void testb(Register reg, Immediate mask);
|
933
921
|
void testb(const Operand& op, Immediate mask);
|
922
|
+
void testb(const Operand& op, Register reg);
|
934
923
|
void testl(Register dst, Register src);
|
935
924
|
void testl(Register reg, Immediate mask);
|
936
925
|
void testl(const Operand& op, Immediate mask);
|
@@ -1030,6 +1019,7 @@ class Assembler : public Malloced {
|
|
1030
1019
|
|
1031
1020
|
void fld1();
|
1032
1021
|
void fldz();
|
1022
|
+
void fldpi();
|
1033
1023
|
|
1034
1024
|
void fld_s(const Operand& adr);
|
1035
1025
|
void fld_d(const Operand& adr);
|
@@ -1047,6 +1037,7 @@ class Assembler : public Malloced {
|
|
1047
1037
|
void fistp_d(const Operand& adr);
|
1048
1038
|
|
1049
1039
|
void fisttp_s(const Operand& adr);
|
1040
|
+
void fisttp_d(const Operand& adr);
|
1050
1041
|
|
1051
1042
|
void fabs();
|
1052
1043
|
void fchs();
|
@@ -1089,9 +1080,15 @@ class Assembler : public Malloced {
|
|
1089
1080
|
void sahf();
|
1090
1081
|
|
1091
1082
|
// SSE2 instructions
|
1083
|
+
void movd(XMMRegister dst, Register src);
|
1084
|
+
void movd(Register dst, XMMRegister src);
|
1085
|
+
void movq(XMMRegister dst, Register src);
|
1086
|
+
void movq(Register dst, XMMRegister src);
|
1087
|
+
void extractps(Register dst, XMMRegister src, byte imm8);
|
1088
|
+
|
1092
1089
|
void movsd(const Operand& dst, XMMRegister src);
|
1093
|
-
void movsd(XMMRegister
|
1094
|
-
void movsd(XMMRegister
|
1090
|
+
void movsd(XMMRegister dst, XMMRegister src);
|
1091
|
+
void movsd(XMMRegister dst, const Operand& src);
|
1095
1092
|
|
1096
1093
|
void cvttss2si(Register dst, const Operand& src);
|
1097
1094
|
void cvttsd2si(Register dst, const Operand& src);
|
@@ -1101,15 +1098,24 @@ class Assembler : public Malloced {
|
|
1101
1098
|
void cvtqsi2sd(XMMRegister dst, const Operand& src);
|
1102
1099
|
void cvtqsi2sd(XMMRegister dst, Register src);
|
1103
1100
|
|
1101
|
+
void cvtss2sd(XMMRegister dst, XMMRegister src);
|
1102
|
+
|
1104
1103
|
void addsd(XMMRegister dst, XMMRegister src);
|
1105
1104
|
void subsd(XMMRegister dst, XMMRegister src);
|
1106
1105
|
void mulsd(XMMRegister dst, XMMRegister src);
|
1107
1106
|
void divsd(XMMRegister dst, XMMRegister src);
|
1108
1107
|
|
1108
|
+
void xorpd(XMMRegister dst, XMMRegister src);
|
1109
|
+
void sqrtsd(XMMRegister dst, XMMRegister src);
|
1109
1110
|
|
1111
|
+
void comisd(XMMRegister dst, XMMRegister src);
|
1112
|
+
void ucomisd(XMMRegister dst, XMMRegister src);
|
1113
|
+
|
1114
|
+
// The first argument is the reg field, the second argument is the r/m field.
|
1110
1115
|
void emit_sse_operand(XMMRegister dst, XMMRegister src);
|
1111
1116
|
void emit_sse_operand(XMMRegister reg, const Operand& adr);
|
1112
1117
|
void emit_sse_operand(XMMRegister dst, Register src);
|
1118
|
+
void emit_sse_operand(Register dst, XMMRegister src);
|
1113
1119
|
|
1114
1120
|
// Use either movsd or movlpd.
|
1115
1121
|
// void movdbl(XMMRegister dst, const Operand& src);
|
@@ -1152,14 +1158,6 @@ class Assembler : public Malloced {
|
|
1152
1158
|
static const int kMaximalBufferSize = 512*MB;
|
1153
1159
|
static const int kMinimalBufferSize = 4*KB;
|
1154
1160
|
|
1155
|
-
protected:
|
1156
|
-
// void movsd(XMMRegister dst, const Operand& src);
|
1157
|
-
// void movsd(const Operand& dst, XMMRegister src);
|
1158
|
-
|
1159
|
-
// void emit_sse_operand(XMMRegister reg, const Operand& adr);
|
1160
|
-
// void emit_sse_operand(XMMRegister dst, XMMRegister src);
|
1161
|
-
|
1162
|
-
|
1163
1161
|
private:
|
1164
1162
|
byte* addr_at(int pos) { return buffer_ + pos; }
|
1165
1163
|
byte byte_at(int pos) { return buffer_[pos]; }
|
@@ -1184,8 +1182,9 @@ class Assembler : public Malloced {
|
|
1184
1182
|
// the top bit of both register codes.
|
1185
1183
|
// High bit of reg goes to REX.R, high bit of rm_reg goes to REX.B.
|
1186
1184
|
// REX.W is set.
|
1187
|
-
inline void emit_rex_64(Register reg, Register rm_reg);
|
1188
1185
|
inline void emit_rex_64(XMMRegister reg, Register rm_reg);
|
1186
|
+
inline void emit_rex_64(Register reg, XMMRegister rm_reg);
|
1187
|
+
inline void emit_rex_64(Register reg, Register rm_reg);
|
1189
1188
|
|
1190
1189
|
// Emits a REX prefix that encodes a 64-bit operand size and
|
1191
1190
|
// the top bit of the destination, index, and base register codes.
|
@@ -1243,9 +1242,13 @@ class Assembler : public Malloced {
|
|
1243
1242
|
inline void emit_optional_rex_32(XMMRegister reg, XMMRegister base);
|
1244
1243
|
|
1245
1244
|
// As for emit_optional_rex_32(Register, Register), except that
|
1246
|
-
// the registers
|
1245
|
+
// one of the registers is an XMM registers.
|
1247
1246
|
inline void emit_optional_rex_32(XMMRegister reg, Register base);
|
1248
1247
|
|
1248
|
+
// As for emit_optional_rex_32(Register, Register), except that
|
1249
|
+
// one of the registers is an XMM registers.
|
1250
|
+
inline void emit_optional_rex_32(Register reg, XMMRegister base);
|
1251
|
+
|
1249
1252
|
// As for emit_optional_rex_32(Register, const Operand&), except that
|
1250
1253
|
// the register is an XMM register.
|
1251
1254
|
inline void emit_optional_rex_32(XMMRegister reg, const Operand& op);
|
@@ -34,17 +34,37 @@ namespace internal {
|
|
34
34
|
|
35
35
|
#define __ ACCESS_MASM(masm)
|
36
36
|
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
//
|
44
|
-
//
|
45
|
-
//
|
46
|
-
|
47
|
-
|
37
|
+
|
38
|
+
void Builtins::Generate_Adaptor(MacroAssembler* masm,
|
39
|
+
CFunctionId id,
|
40
|
+
BuiltinExtraArguments extra_args) {
|
41
|
+
// ----------- S t a t e -------------
|
42
|
+
// -- rax : number of arguments excluding receiver
|
43
|
+
// -- rdi : called function (only guaranteed when
|
44
|
+
// extra_args requires it)
|
45
|
+
// -- rsi : context
|
46
|
+
// -- rsp[0] : return address
|
47
|
+
// -- rsp[8] : last argument
|
48
|
+
// -- ...
|
49
|
+
// -- rsp[8 * argc] : first argument (argc == rax)
|
50
|
+
// -- rsp[8 * (argc +1)] : receiver
|
51
|
+
// -----------------------------------
|
52
|
+
|
53
|
+
// Insert extra arguments.
|
54
|
+
int num_extra_args = 0;
|
55
|
+
if (extra_args == NEEDS_CALLED_FUNCTION) {
|
56
|
+
num_extra_args = 1;
|
57
|
+
__ pop(kScratchRegister); // Save return address.
|
58
|
+
__ push(rdi);
|
59
|
+
__ push(kScratchRegister); // Restore return address.
|
60
|
+
} else {
|
61
|
+
ASSERT(extra_args == NO_EXTRA_ARGUMENTS);
|
62
|
+
}
|
63
|
+
|
64
|
+
// JumpToExternalReference expects rax to contain the number of arguments
|
65
|
+
// including the receiver and the extra arguments.
|
66
|
+
__ addq(rax, Immediate(num_extra_args + 1));
|
67
|
+
__ JumpToExternalReference(ExternalReference(id), 1);
|
48
68
|
}
|
49
69
|
|
50
70
|
|
@@ -165,14 +185,14 @@ void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) {
|
|
165
185
|
|
166
186
|
void Builtins::Generate_FunctionCall(MacroAssembler* masm) {
|
167
187
|
// Stack Layout:
|
168
|
-
// rsp:
|
169
|
-
//
|
170
|
-
//
|
188
|
+
// rsp[0]: Return address
|
189
|
+
// rsp[1]: Argument n
|
190
|
+
// rsp[2]: Argument n-1
|
171
191
|
// ...
|
172
|
-
//
|
173
|
-
//
|
192
|
+
// rsp[n]: Argument 1
|
193
|
+
// rsp[n+1]: Receiver (function to call)
|
174
194
|
//
|
175
|
-
// rax contains the number of arguments, n, not counting the
|
195
|
+
// rax contains the number of arguments, n, not counting the receiver.
|
176
196
|
//
|
177
197
|
// 1. Make sure we have at least one argument.
|
178
198
|
{ Label done;
|
@@ -185,31 +205,23 @@ void Builtins::Generate_FunctionCall(MacroAssembler* masm) {
|
|
185
205
|
__ bind(&done);
|
186
206
|
}
|
187
207
|
|
188
|
-
// 2. Get the function to call from the stack
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
// Non-function called: Clear the function to force exception.
|
197
|
-
__ bind(&non_function);
|
198
|
-
__ xor_(rdi, rdi);
|
199
|
-
__ jmp(&done);
|
208
|
+
// 2. Get the function to call (passed as receiver) from the stack, check
|
209
|
+
// if it is a function.
|
210
|
+
Label non_function;
|
211
|
+
// The function to call is at position n+1 on the stack.
|
212
|
+
__ movq(rdi, Operand(rsp, rax, times_pointer_size, 1 * kPointerSize));
|
213
|
+
__ JumpIfSmi(rdi, &non_function);
|
214
|
+
__ CmpObjectType(rdi, JS_FUNCTION_TYPE, rcx);
|
215
|
+
__ j(not_equal, &non_function);
|
200
216
|
|
201
|
-
|
202
|
-
|
217
|
+
// 3a. Patch the first argument if necessary when calling a function.
|
218
|
+
Label shift_arguments;
|
219
|
+
{ Label convert_to_object, use_global_receiver, patch_receiver;
|
220
|
+
// Change context eagerly in case we need the global receiver.
|
203
221
|
__ movq(rsi, FieldOperand(rdi, JSFunction::kContextOffset));
|
204
222
|
|
205
|
-
__ bind(&done);
|
206
|
-
}
|
207
|
-
|
208
|
-
// 3. Make sure first argument is an object; convert if necessary.
|
209
|
-
{ Label call_to_object, use_global_receiver, patch_receiver, done;
|
210
223
|
__ movq(rbx, Operand(rsp, rax, times_pointer_size, 0));
|
211
|
-
|
212
|
-
__ JumpIfSmi(rbx, &call_to_object);
|
224
|
+
__ JumpIfSmi(rbx, &convert_to_object);
|
213
225
|
|
214
226
|
__ CompareRoot(rbx, Heap::kNullValueRootIndex);
|
215
227
|
__ j(equal, &use_global_receiver);
|
@@ -217,31 +229,28 @@ void Builtins::Generate_FunctionCall(MacroAssembler* masm) {
|
|
217
229
|
__ j(equal, &use_global_receiver);
|
218
230
|
|
219
231
|
__ CmpObjectType(rbx, FIRST_JS_OBJECT_TYPE, rcx);
|
220
|
-
__ j(below, &
|
232
|
+
__ j(below, &convert_to_object);
|
221
233
|
__ CmpInstanceType(rcx, LAST_JS_OBJECT_TYPE);
|
222
|
-
__ j(below_equal, &
|
234
|
+
__ j(below_equal, &shift_arguments);
|
223
235
|
|
224
|
-
__ bind(&
|
225
|
-
__ EnterInternalFrame(); //
|
226
|
-
|
227
|
-
// Store the arguments count on the stack (smi tagged).
|
236
|
+
__ bind(&convert_to_object);
|
237
|
+
__ EnterInternalFrame(); // In order to preserve argument count.
|
228
238
|
__ Integer32ToSmi(rax, rax);
|
229
239
|
__ push(rax);
|
230
240
|
|
231
|
-
__ push(rdi); // save edi across the call
|
232
241
|
__ push(rbx);
|
233
242
|
__ InvokeBuiltin(Builtins::TO_OBJECT, CALL_FUNCTION);
|
234
243
|
__ movq(rbx, rax);
|
235
|
-
__ pop(rdi); // restore edi after the call
|
236
244
|
|
237
|
-
// Get the arguments count and untag it.
|
238
245
|
__ pop(rax);
|
239
246
|
__ SmiToInteger32(rax, rax);
|
240
|
-
|
241
247
|
__ LeaveInternalFrame();
|
248
|
+
// Restore the function to rdi.
|
249
|
+
__ movq(rdi, Operand(rsp, rax, times_pointer_size, 1 * kPointerSize));
|
242
250
|
__ jmp(&patch_receiver);
|
243
251
|
|
244
|
-
// Use the global receiver object from the called function as the
|
252
|
+
// Use the global receiver object from the called function as the
|
253
|
+
// receiver.
|
245
254
|
__ bind(&use_global_receiver);
|
246
255
|
const int kGlobalIndex =
|
247
256
|
Context::kHeaderSize + Context::GLOBAL_INDEX * kPointerSize;
|
@@ -253,48 +262,57 @@ void Builtins::Generate_FunctionCall(MacroAssembler* masm) {
|
|
253
262
|
__ bind(&patch_receiver);
|
254
263
|
__ movq(Operand(rsp, rax, times_pointer_size, 0), rbx);
|
255
264
|
|
256
|
-
__
|
265
|
+
__ jmp(&shift_arguments);
|
257
266
|
}
|
258
267
|
|
259
|
-
|
268
|
+
|
269
|
+
// 3b. Patch the first argument when calling a non-function. The
|
270
|
+
// CALL_NON_FUNCTION builtin expects the non-function callee as
|
271
|
+
// receiver, so overwrite the first argument which will ultimately
|
272
|
+
// become the receiver.
|
273
|
+
__ bind(&non_function);
|
274
|
+
__ movq(Operand(rsp, rax, times_pointer_size, 0), rdi);
|
275
|
+
__ xor_(rdi, rdi);
|
276
|
+
|
277
|
+
// 4. Shift arguments and return address one slot down on the stack
|
278
|
+
// (overwriting the original receiver). Adjust argument count to make
|
279
|
+
// the original first argument the new receiver.
|
280
|
+
__ bind(&shift_arguments);
|
260
281
|
{ Label loop;
|
261
|
-
__
|
282
|
+
__ movq(rcx, rax);
|
262
283
|
__ bind(&loop);
|
263
284
|
__ movq(rbx, Operand(rsp, rcx, times_pointer_size, 0));
|
264
285
|
__ movq(Operand(rsp, rcx, times_pointer_size, 1 * kPointerSize), rbx);
|
265
286
|
__ decq(rcx);
|
266
|
-
__ j(
|
287
|
+
__ j(not_sign, &loop); // While non-negative (to copy return address).
|
288
|
+
__ pop(rbx); // Discard copy of return address.
|
289
|
+
__ decq(rax); // One fewer argument (first argument is new receiver).
|
267
290
|
}
|
268
291
|
|
269
|
-
//
|
270
|
-
|
271
|
-
__ pop(rcx);
|
272
|
-
__ push(rbx);
|
273
|
-
__ decq(rax);
|
274
|
-
|
275
|
-
// 6. Check that function really was a function and get the code to
|
276
|
-
// call from the function and check that the number of expected
|
277
|
-
// arguments matches what we're providing.
|
278
|
-
{ Label invoke, trampoline;
|
292
|
+
// 5a. Call non-function via tail call to CALL_NON_FUNCTION builtin.
|
293
|
+
{ Label function;
|
279
294
|
__ testq(rdi, rdi);
|
280
|
-
__ j(not_zero, &
|
295
|
+
__ j(not_zero, &function);
|
281
296
|
__ xor_(rbx, rbx);
|
282
297
|
__ GetBuiltinEntry(rdx, Builtins::CALL_NON_FUNCTION);
|
283
|
-
__ bind(&trampoline);
|
284
298
|
__ Jump(Handle<Code>(builtin(ArgumentsAdaptorTrampoline)),
|
285
299
|
RelocInfo::CODE_TARGET);
|
286
|
-
|
287
|
-
__ bind(&invoke);
|
288
|
-
__ movq(rdx, FieldOperand(rdi, JSFunction::kSharedFunctionInfoOffset));
|
289
|
-
__ movsxlq(rbx,
|
290
|
-
FieldOperand(rdx, SharedFunctionInfo::kFormalParameterCountOffset));
|
291
|
-
__ movq(rdx, FieldOperand(rdx, SharedFunctionInfo::kCodeOffset));
|
292
|
-
__ lea(rdx, FieldOperand(rdx, Code::kHeaderSize));
|
293
|
-
__ cmpq(rax, rbx);
|
294
|
-
__ j(not_equal, &trampoline);
|
300
|
+
__ bind(&function);
|
295
301
|
}
|
296
302
|
|
297
|
-
//
|
303
|
+
// 5b. Get the code to call from the function and check that the number of
|
304
|
+
// expected arguments matches what we're providing. If so, jump
|
305
|
+
// (tail-call) to the code in register edx without checking arguments.
|
306
|
+
__ movq(rdx, FieldOperand(rdi, JSFunction::kSharedFunctionInfoOffset));
|
307
|
+
__ movsxlq(rbx,
|
308
|
+
FieldOperand(rdx, SharedFunctionInfo::kFormalParameterCountOffset));
|
309
|
+
__ movq(rdx, FieldOperand(rdx, SharedFunctionInfo::kCodeOffset));
|
310
|
+
__ lea(rdx, FieldOperand(rdx, Code::kHeaderSize));
|
311
|
+
__ cmpq(rax, rbx);
|
312
|
+
__ j(not_equal,
|
313
|
+
Handle<Code>(builtin(ArgumentsAdaptorTrampoline)),
|
314
|
+
RelocInfo::CODE_TARGET);
|
315
|
+
|
298
316
|
ParameterCount expected(0);
|
299
317
|
__ InvokeCode(rdx, expected, expected, JUMP_FUNCTION);
|
300
318
|
}
|
@@ -566,6 +584,7 @@ static void AllocateJSArray(MacroAssembler* masm,
|
|
566
584
|
JSFunction::kPrototypeOrInitialMapOffset));
|
567
585
|
|
568
586
|
// Check whether an empty sized array is requested.
|
587
|
+
__ SmiToInteger64(array_size, array_size);
|
569
588
|
__ testq(array_size, array_size);
|
570
589
|
__ j(not_zero, ¬_empty);
|
571
590
|
|
@@ -585,7 +604,7 @@ static void AllocateJSArray(MacroAssembler* masm,
|
|
585
604
|
__ bind(¬_empty);
|
586
605
|
ASSERT(kSmiTagSize == 1 && kSmiTag == 0);
|
587
606
|
__ AllocateInNewSpace(JSArray::kSize + FixedArray::kHeaderSize,
|
588
|
-
|
607
|
+
times_pointer_size,
|
589
608
|
array_size,
|
590
609
|
result,
|
591
610
|
elements_array_end,
|
@@ -598,19 +617,20 @@ static void AllocateJSArray(MacroAssembler* masm,
|
|
598
617
|
// result: JSObject
|
599
618
|
// elements_array: initial map
|
600
619
|
// elements_array_end: start of next object
|
601
|
-
// array_size: size of array
|
620
|
+
// array_size: size of array
|
602
621
|
__ bind(&allocated);
|
603
622
|
__ movq(FieldOperand(result, JSObject::kMapOffset), elements_array);
|
604
623
|
__ Move(elements_array, Factory::empty_fixed_array());
|
605
624
|
__ movq(FieldOperand(result, JSArray::kPropertiesOffset), elements_array);
|
606
625
|
// Field JSArray::kElementsOffset is initialized later.
|
607
|
-
__
|
626
|
+
__ Integer32ToSmi(scratch, array_size);
|
627
|
+
__ movq(FieldOperand(result, JSArray::kLengthOffset), scratch);
|
608
628
|
|
609
629
|
// Calculate the location of the elements array and set elements array member
|
610
630
|
// of the JSArray.
|
611
631
|
// result: JSObject
|
612
632
|
// elements_array_end: start of next object
|
613
|
-
// array_size: size of array
|
633
|
+
// array_size: size of array
|
614
634
|
__ lea(elements_array, Operand(result, JSArray::kSize));
|
615
635
|
__ movq(FieldOperand(result, JSArray::kElementsOffset), elements_array);
|
616
636
|
|
@@ -618,9 +638,8 @@ static void AllocateJSArray(MacroAssembler* masm,
|
|
618
638
|
// result: JSObject
|
619
639
|
// elements_array: elements array
|
620
640
|
// elements_array_end: start of next object
|
621
|
-
// array_size: size of array
|
641
|
+
// array_size: size of array
|
622
642
|
ASSERT(kSmiTag == 0);
|
623
|
-
__ SmiToInteger64(array_size, array_size);
|
624
643
|
__ Move(FieldOperand(elements_array, JSObject::kMapOffset),
|
625
644
|
Factory::fixed_array_map());
|
626
645
|
Label not_empty_2, fill_array;
|
@@ -880,7 +899,11 @@ void Builtins::Generate_JSConstructCall(MacroAssembler* masm) {
|
|
880
899
|
// edi: called object
|
881
900
|
// eax: number of arguments
|
882
901
|
__ bind(&non_function_call);
|
883
|
-
//
|
902
|
+
// CALL_NON_FUNCTION expects the non-function constructor as receiver
|
903
|
+
// (instead of the original receiver from the call site). The receiver is
|
904
|
+
// stack element argc+1.
|
905
|
+
__ movq(Operand(rsp, rax, times_pointer_size, kPointerSize), rdi);
|
906
|
+
// Set expected number of arguments to zero (not changing rax).
|
884
907
|
__ movq(rbx, Immediate(0));
|
885
908
|
__ GetBuiltinEntry(rdx, Builtins::CALL_NON_FUNCTION_AS_CONSTRUCTOR);
|
886
909
|
__ Jump(Handle<Code>(builtin(ArgumentsAdaptorTrampoline)),
|
@@ -888,7 +911,8 @@ void Builtins::Generate_JSConstructCall(MacroAssembler* masm) {
|
|
888
911
|
}
|
889
912
|
|
890
913
|
|
891
|
-
void
|
914
|
+
static void Generate_JSConstructStubHelper(MacroAssembler* masm,
|
915
|
+
bool is_api_function) {
|
892
916
|
// Enter a construct frame.
|
893
917
|
__ EnterConstructFrame();
|
894
918
|
|
@@ -1091,8 +1115,17 @@ void Builtins::Generate_JSConstructStubGeneric(MacroAssembler* masm) {
|
|
1091
1115
|
__ j(greater_equal, &loop);
|
1092
1116
|
|
1093
1117
|
// Call the function.
|
1094
|
-
|
1095
|
-
|
1118
|
+
if (is_api_function) {
|
1119
|
+
__ movq(rsi, FieldOperand(rdi, JSFunction::kContextOffset));
|
1120
|
+
Handle<Code> code = Handle<Code>(
|
1121
|
+
Builtins::builtin(Builtins::HandleApiCallConstruct));
|
1122
|
+
ParameterCount expected(0);
|
1123
|
+
__ InvokeCode(code, expected, expected,
|
1124
|
+
RelocInfo::CODE_TARGET, CALL_FUNCTION);
|
1125
|
+
} else {
|
1126
|
+
ParameterCount actual(rax);
|
1127
|
+
__ InvokeFunction(rdi, actual, CALL_FUNCTION);
|
1128
|
+
}
|
1096
1129
|
|
1097
1130
|
// Restore context from the frame.
|
1098
1131
|
__ movq(rsi, Operand(rbp, StandardFrameConstants::kContextOffset));
|
@@ -1129,6 +1162,16 @@ void Builtins::Generate_JSConstructStubGeneric(MacroAssembler* masm) {
|
|
1129
1162
|
}
|
1130
1163
|
|
1131
1164
|
|
1165
|
+
void Builtins::Generate_JSConstructStubGeneric(MacroAssembler* masm) {
|
1166
|
+
Generate_JSConstructStubHelper(masm, false);
|
1167
|
+
}
|
1168
|
+
|
1169
|
+
|
1170
|
+
void Builtins::Generate_JSConstructStubApi(MacroAssembler* masm) {
|
1171
|
+
Generate_JSConstructStubHelper(masm, true);
|
1172
|
+
}
|
1173
|
+
|
1174
|
+
|
1132
1175
|
static void Generate_JSEntryTrampolineHelper(MacroAssembler* masm,
|
1133
1176
|
bool is_construct) {
|
1134
1177
|
// Expects five C++ function parameters.
|
@@ -1169,7 +1212,7 @@ static void Generate_JSEntryTrampolineHelper(MacroAssembler* masm,
|
|
1169
1212
|
__ movq(rbx, Operand(kScratchRegister, EntryFrameConstants::kArgvOffset));
|
1170
1213
|
// Load the function pointer into rdi.
|
1171
1214
|
__ movq(rdi, rdx);
|
1172
|
-
#else //
|
1215
|
+
#else // _WIN64
|
1173
1216
|
// GCC parameters in:
|
1174
1217
|
// rdi : entry (ignored)
|
1175
1218
|
// rsi : function
|
@@ -1197,7 +1240,7 @@ static void Generate_JSEntryTrampolineHelper(MacroAssembler* masm,
|
|
1197
1240
|
|
1198
1241
|
// Set up the roots register.
|
1199
1242
|
ExternalReference roots_address = ExternalReference::roots_address();
|
1200
|
-
__ movq(
|
1243
|
+
__ movq(kRootRegister, roots_address);
|
1201
1244
|
|
1202
1245
|
// Current stack contents:
|
1203
1246
|
// [rsp + 2 * kPointerSize ... ]: Internal frame
|