therubyracer 0.7.4 → 0.7.5
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/History.txt +11 -0
- data/Rakefile +1 -1
- data/ext/v8/extconf.rb +0 -18
- data/ext/v8/rr.cpp +2 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/AUTHORS +1 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/ChangeLog +239 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/LICENSE +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/SConstruct +29 -17
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/include/v8-debug.h +61 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/include/v8-profiler.h +182 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/include/v8.h +458 -257
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/SConscript +2 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/accessors.cc +2 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/accessors.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/allocation.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/allocation.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/api.cc +574 -30
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/api.h +12 -10
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/apinatives.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/apiutils.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arguments.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/assembler-arm-inl.h +38 -15
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/assembler-arm.cc +646 -101
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/assembler-arm.h +174 -15
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/builtins-arm.cc +56 -47
- data/ext/v8/upstream/2.3.3/src/arm/codegen-arm-inl.h +48 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/codegen-arm.cc +2957 -1448
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/codegen-arm.h +230 -74
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/constants-arm.cc +25 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/constants-arm.h +16 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/cpu-arm.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/debug-arm.cc +76 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/disasm-arm.cc +168 -20
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/fast-codegen-arm.cc +5 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/frames-arm.cc +4 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/frames-arm.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/full-codegen-arm.cc +1558 -248
- data/ext/v8/upstream/2.3.3/src/arm/ic-arm.cc +2258 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/jump-target-arm.cc +55 -103
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/macro-assembler-arm.cc +358 -185
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/macro-assembler-arm.h +136 -41
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/regexp-macro-assembler-arm.cc +26 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/regexp-macro-assembler-arm.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/register-allocator-arm-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/register-allocator-arm.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/register-allocator-arm.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/simulator-arm.cc +203 -22
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/simulator-arm.h +7 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/stub-cache-arm.cc +531 -324
- data/ext/v8/upstream/2.3.3/src/arm/virtual-frame-arm-inl.h +59 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/virtual-frame-arm.cc +247 -81
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/arm/virtual-frame-arm.h +99 -83
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/array.js +2 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/assembler.cc +6 -13
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/assembler.h +36 -10
- data/ext/v8/upstream/2.3.3/src/ast-inl.h +81 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ast.cc +14 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ast.h +20 -35
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/bootstrapper.cc +32 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/bootstrapper.h +0 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/builtins.cc +50 -33
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/builtins.h +2 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/bytecodes-irregexp.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/cached-powers.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/char-predicates-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/char-predicates.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/checks.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/checks.h +8 -6
- data/ext/v8/upstream/2.3.3/src/circular-queue-inl.h +53 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/circular-queue.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/circular-queue.h +0 -26
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/code-stubs.cc +2 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/code-stubs.h +1 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/code.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/codegen-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/codegen.cc +44 -13
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/codegen.h +310 -31
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/compilation-cache.cc +28 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/compilation-cache.h +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/compiler.cc +45 -14
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/compiler.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/contexts.cc +11 -11
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/contexts.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/conversions-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/conversions.cc +25 -11
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/conversions.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/counters.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/counters.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/cpu-profiler-inl.h +2 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/cpu-profiler.cc +68 -24
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/cpu-profiler.h +19 -11
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/cpu.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8-debug.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8-debug.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8-posix.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8-readline.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8-windows.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/d8.js +55 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/data-flow.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/data-flow.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/date.js +68 -137
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/dateparser-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/dateparser.cc +2 -8
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/dateparser.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/debug-agent.cc +3 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/debug-agent.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/debug-debugger.js +81 -23
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/debug.cc +275 -81
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/debug.h +85 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/disasm.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/disassembler.cc +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/disassembler.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/diy-fp.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/diy-fp.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/double.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/dtoa-config.c +0 -0
- data/ext/v8/upstream/2.3.3/src/dtoa.cc +77 -0
- data/ext/v8/upstream/2.3.3/src/dtoa.h +81 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/execution.cc +111 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/execution.h +12 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/factory.cc +25 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/factory.h +16 -9
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/fast-codegen.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/fast-codegen.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/fast-dtoa.cc +2 -9
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/fast-dtoa.h +1 -2
- data/ext/v8/upstream/2.3.3/src/fixed-dtoa.cc +405 -0
- data/ext/v8/upstream/{2.1.10/src/jump-target-light.cc → 2.3.3/src/fixed-dtoa.h} +22 -53
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/flag-definitions.h +14 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/flags.cc +5 -9
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/flags.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/flow-graph.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/flow-graph.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/frame-element.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/frame-element.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/frames-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/frames.cc +5 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/frames.h +1 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/full-codegen.cc +387 -20
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/full-codegen.h +102 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/func-name-inferrer.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/func-name-inferrer.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/global-handles.cc +8 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/global-handles.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/globals.h +44 -7
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/handles-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/handles.cc +19 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/handles.h +8 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/hashmap.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/hashmap.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/heap-inl.h +56 -14
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/heap-profiler.cc +85 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/heap-profiler.h +45 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/heap.cc +994 -396
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/heap.h +220 -65
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/assembler-ia32-inl.h +41 -12
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/assembler-ia32.cc +94 -24
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/assembler-ia32.h +32 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/builtins-ia32.cc +42 -30
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/codegen-ia32-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/codegen-ia32.cc +1758 -916
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/codegen-ia32.h +67 -74
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/cpu-ia32.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/debug-ia32.cc +46 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/disasm-ia32.cc +37 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/fast-codegen-ia32.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/fast-codegen-ia32.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/frames-ia32.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/frames-ia32.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/full-codegen-ia32.cc +1465 -198
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/ic-ia32.cc +688 -367
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/jump-target-ia32.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/macro-assembler-ia32.cc +82 -180
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/macro-assembler-ia32.h +41 -25
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/regexp-macro-assembler-ia32.cc +68 -24
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/regexp-macro-assembler-ia32.h +1 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/register-allocator-ia32-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/register-allocator-ia32.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/register-allocator-ia32.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/simulator-ia32.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/simulator-ia32.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/stub-cache-ia32.cc +649 -302
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/virtual-frame-ia32.cc +23 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ia32/virtual-frame-ia32.h +18 -27
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ic-inl.h +30 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ic.cc +384 -66
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/ic.h +65 -24
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/interpreter-irregexp.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/interpreter-irregexp.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/json.js +3 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jsregexp.cc +20 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jsregexp.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jump-target-heavy-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jump-target-heavy.cc +79 -13
- data/ext/v8/upstream/{2.1.10/src/jump-target.h → 2.3.3/src/jump-target-heavy.h} +5 -47
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jump-target-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jump-target-light-inl.h +16 -2
- data/ext/v8/upstream/2.3.3/src/jump-target-light.cc +110 -0
- data/ext/v8/upstream/2.3.3/src/jump-target-light.h +192 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/jump-target.cc +0 -64
- data/ext/v8/upstream/2.3.3/src/jump-target.h +90 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/list-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/list.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/liveedit-debugger.js +141 -28
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/liveedit.cc +19 -7
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/liveedit.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/log-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/log-utils.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/log-utils.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/log.cc +12 -11
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/log.h +12 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/macro-assembler.h +0 -16
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/macros.py +21 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mark-compact.cc +120 -109
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mark-compact.h +25 -37
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/math.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/memory.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/messages.cc +8 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/messages.h +2 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/messages.js +15 -7
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/assembler-mips-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/assembler-mips.cc +12 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/assembler-mips.h +4 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/builtins-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/codegen-mips-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/codegen-mips.cc +9 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/codegen-mips.h +1 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/constants-mips.cc +5 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/constants-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/cpu-mips.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/debug-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/disasm-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/fast-codegen-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/frames-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/frames-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/full-codegen-mips.cc +5 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/ic-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/jump-target-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/macro-assembler-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/macro-assembler-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/register-allocator-mips-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/register-allocator-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/register-allocator-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/simulator-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/simulator-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/stub-cache-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/virtual-frame-mips.cc +3 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mips/virtual-frame-mips.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mirror-debugger.js +46 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/mksnapshot.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/natives.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/objects-debug.cc +8 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/objects-inl.h +235 -62
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/objects.cc +497 -231
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/objects.h +355 -149
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/oprofile-agent.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/oprofile-agent.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/parser.cc +31 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/parser.h +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-freebsd.cc +9 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-linux.cc +26 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-macos.cc +11 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-nullos.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-openbsd.cc +6 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-posix.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-solaris.cc +69 -23
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform-win32.cc +15 -11
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/platform.h +10 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/powers-ten.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/prettyprinter.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/prettyprinter.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/profile-generator-inl.h +26 -2
- data/ext/v8/upstream/2.3.3/src/profile-generator.cc +1830 -0
- data/ext/v8/upstream/2.3.3/src/profile-generator.h +853 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/property.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/property.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler-irregexp-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler-irregexp.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler-irregexp.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler-tracer.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler-tracer.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler.cc +1 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-macro-assembler.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-stack.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp-stack.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/regexp.js +25 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/register-allocator-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/register-allocator.cc +4 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/register-allocator.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/rewriter.cc +85 -8
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/rewriter.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/runtime.cc +547 -221
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/runtime.h +5 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/runtime.js +23 -31
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scanner.cc +12 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scanner.h +60 -53
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scopeinfo.cc +156 -168
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scopeinfo.h +58 -62
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scopes.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/scopes.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/serialize.cc +320 -242
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/serialize.h +81 -48
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/shell.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/simulator.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/smart-pointer.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/snapshot-common.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/snapshot-empty.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/snapshot.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/spaces-inl.h +177 -74
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/spaces.cc +138 -315
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/spaces.h +155 -124
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/splay-tree-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/splay-tree.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/string-stream.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/string-stream.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/string.js +113 -119
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/stub-cache.cc +242 -97
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/stub-cache.h +118 -55
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/third_party/dtoa/COPYING +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/third_party/dtoa/dtoa.c +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/third_party/valgrind/valgrind.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/token.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/token.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/top.cc +107 -26
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/top.h +9 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/type-info.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/type-info.h +2 -2
- data/ext/v8/upstream/2.3.3/src/unbound-queue-inl.h +95 -0
- data/ext/v8/upstream/2.3.3/src/unbound-queue.h +67 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/unicode-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/unicode.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/unicode.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/uri.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/utils.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/utils.h +83 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8-counters.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8-counters.h +20 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8.cc +5 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8.h +0 -0
- data/ext/v8/upstream/2.3.3/src/v8dll-main.cc +39 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8natives.js +210 -33
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8threads.cc +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/v8threads.h +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/variables.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/variables.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/version.cc +3 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/version.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame-heavy-inl.h +40 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame-heavy.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame-light-inl.h +106 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame-light.cc +4 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/virtual-frame.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/vm-state-inl.h +6 -3
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/vm-state.cc +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/vm-state.h +6 -4
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/assembler-x64-inl.h +42 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/assembler-x64.cc +285 -53
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/assembler-x64.h +54 -18
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/builtins-x64.cc +31 -33
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/codegen-x64-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/codegen-x64.cc +9787 -8722
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/codegen-x64.h +82 -47
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/cpu-x64.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/debug-x64.cc +55 -6
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/disasm-x64.cc +42 -19
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/fast-codegen-x64.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/frames-x64.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/frames-x64.h +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/full-codegen-x64.cc +1487 -210
- data/ext/v8/upstream/2.3.3/src/x64/ic-x64.cc +1907 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/jump-target-x64.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/macro-assembler-x64.cc +366 -338
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/macro-assembler-x64.h +83 -38
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/regexp-macro-assembler-x64.cc +82 -23
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/regexp-macro-assembler-x64.h +1 -2
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/register-allocator-x64-inl.h +6 -5
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/register-allocator-x64.cc +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/register-allocator-x64.h +1 -1
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/simulator-x64.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/simulator-x64.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/stub-cache-x64.cc +556 -377
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/virtual-frame-x64.cc +197 -98
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/x64/virtual-frame-x64.h +37 -28
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/zone-inl.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/zone.cc +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/src/zone.h +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/codemap.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/consarray.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/csvparser.js +0 -0
- data/ext/v8/upstream/2.3.3/tools/gc-nvp-trace-processor.py +317 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/generate-ten-powers.scm +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/gyp/v8.gyp +87 -20
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/js2c.py +19 -15
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/jsmin.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/linux-tick-processor +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/linux-tick-processor.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/logreader.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/mac-nm +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/mac-tick-processor +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/annotate +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/common +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/dump +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/report +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/reset +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/run +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/shutdown +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/oprofile/start +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/presubmit.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/process-heap-prof.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/profile.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/profile_view.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/run-valgrind.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/splaytree.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/splaytree.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/stats-viewer.py +25 -13
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/test.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/tickprocessor-driver.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/tickprocessor.js +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/tickprocessor.py +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/utils.py +0 -0
- data/ext/v8/upstream/2.3.3/tools/v8.xcodeproj/project.pbxproj +1855 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/README.txt +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/arm.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/common.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/d8.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/d8_arm.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/d8_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/d8js2c.cmd +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/debug.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/ia32.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/js2c.cmd +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/release.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8.sln +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_arm.sln +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_arm.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_base.vcproj +40 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_base_arm.vcproj +20 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_base_x64.vcproj +16 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_cctest.vcproj +4 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_cctest_arm.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_cctest_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_mksnapshot.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_mksnapshot_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_process_sample.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_process_sample_arm.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_process_sample_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_shell_sample.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_shell_sample_arm.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_shell_sample_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_snapshot.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_snapshot_cc.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_snapshot_cc_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_snapshot_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_x64.sln +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/v8_x64.vcproj +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/visual_studio/x64.vsprops +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/windows-tick-processor.bat +0 -0
- data/ext/v8/upstream/{2.1.10 → 2.3.3}/tools/windows-tick-processor.py +0 -0
- data/ext/v8/upstream/Makefile +1 -1
- data/ext/v8/v8_template.cpp +94 -2
- data/ext/v8/v8_try_catch.cpp +2 -2
- data/lib/v8.rb +1 -1
- data/lib/v8/access.rb +93 -40
- data/lib/v8/cli.rb +1 -1
- data/lib/v8/function.rb +14 -2
- data/spec/redjs/jsapi_spec.rb +231 -42
- data/therubyracer.gemspec +3 -3
- metadata +463 -453
- data/ext/v8/upstream/2.1.10/src/arm/assembler-thumb2-inl.h +0 -263
- data/ext/v8/upstream/2.1.10/src/arm/assembler-thumb2.cc +0 -1878
- data/ext/v8/upstream/2.1.10/src/arm/assembler-thumb2.h +0 -1036
- data/ext/v8/upstream/2.1.10/src/arm/codegen-arm-inl.h +0 -72
- data/ext/v8/upstream/2.1.10/src/arm/ic-arm.cc +0 -1833
- data/ext/v8/upstream/2.1.10/src/circular-queue-inl.h +0 -101
- data/ext/v8/upstream/2.1.10/src/profile-generator.cc +0 -583
- data/ext/v8/upstream/2.1.10/src/profile-generator.h +0 -364
- data/ext/v8/upstream/2.1.10/src/x64/ic-x64.cc +0 -1621
@@ -1,1036 +0,0 @@
|
|
1
|
-
// Copyright (c) 1994-2006 Sun Microsystems Inc.
|
2
|
-
// All Rights Reserved.
|
3
|
-
//
|
4
|
-
// Redistribution and use in source and binary forms, with or without
|
5
|
-
// modification, are permitted provided that the following conditions
|
6
|
-
// are met:
|
7
|
-
//
|
8
|
-
// - Redistributions of source code must retain the above copyright notice,
|
9
|
-
// this list of conditions and the following disclaimer.
|
10
|
-
//
|
11
|
-
// - Redistribution in binary form must reproduce the above copyright
|
12
|
-
// notice, this list of conditions and the following disclaimer in the
|
13
|
-
// documentation and/or other materials provided with the
|
14
|
-
// distribution.
|
15
|
-
//
|
16
|
-
// - Neither the name of Sun Microsystems or the names of contributors may
|
17
|
-
// be used to endorse or promote products derived from this software without
|
18
|
-
// specific prior written permission.
|
19
|
-
//
|
20
|
-
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
21
|
-
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
22
|
-
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
23
|
-
// FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
24
|
-
// COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
25
|
-
// INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
26
|
-
// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
27
|
-
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
28
|
-
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
29
|
-
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
30
|
-
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
|
31
|
-
// OF THE POSSIBILITY OF SUCH DAMAGE.
|
32
|
-
|
33
|
-
// The original source code covered by the above license above has been
|
34
|
-
// modified significantly by Google Inc.
|
35
|
-
// Copyright 2010 the V8 project authors. All rights reserved.
|
36
|
-
|
37
|
-
// A light-weight ARM Assembler
|
38
|
-
// Generates user mode instructions for the ARM architecture up to version 5
|
39
|
-
|
40
|
-
#ifndef V8_ARM_ASSEMBLER_THUMB2_H_
|
41
|
-
#define V8_ARM_ASSEMBLER_THUMB2_H_
|
42
|
-
#include <stdio.h>
|
43
|
-
#include "assembler.h"
|
44
|
-
#include "serialize.h"
|
45
|
-
|
46
|
-
namespace v8 {
|
47
|
-
namespace internal {
|
48
|
-
|
49
|
-
// CPU Registers.
|
50
|
-
//
|
51
|
-
// 1) We would prefer to use an enum, but enum values are assignment-
|
52
|
-
// compatible with int, which has caused code-generation bugs.
|
53
|
-
//
|
54
|
-
// 2) We would prefer to use a class instead of a struct but we don't like
|
55
|
-
// the register initialization to depend on the particular initialization
|
56
|
-
// order (which appears to be different on OS X, Linux, and Windows for the
|
57
|
-
// installed versions of C++ we tried). Using a struct permits C-style
|
58
|
-
// "initialization". Also, the Register objects cannot be const as this
|
59
|
-
// forces initialization stubs in MSVC, making us dependent on initialization
|
60
|
-
// order.
|
61
|
-
//
|
62
|
-
// 3) By not using an enum, we are possibly preventing the compiler from
|
63
|
-
// doing certain constant folds, which may significantly reduce the
|
64
|
-
// code generated for some assembly instructions (because they boil down
|
65
|
-
// to a few constants). If this is a problem, we could change the code
|
66
|
-
// such that we use an enum in optimized mode, and the struct in debug
|
67
|
-
// mode. This way we get the compile-time error checking in debug mode
|
68
|
-
// and best performance in optimized code.
|
69
|
-
//
|
70
|
-
// Core register
|
71
|
-
struct Register {
|
72
|
-
bool is_valid() const { return 0 <= code_ && code_ < 16; }
|
73
|
-
bool is(Register reg) const { return code_ == reg.code_; }
|
74
|
-
int code() const {
|
75
|
-
ASSERT(is_valid());
|
76
|
-
return code_;
|
77
|
-
}
|
78
|
-
int bit() const {
|
79
|
-
ASSERT(is_valid());
|
80
|
-
return 1 << code_;
|
81
|
-
}
|
82
|
-
|
83
|
-
// Unfortunately we can't make this private in a struct.
|
84
|
-
int code_;
|
85
|
-
};
|
86
|
-
|
87
|
-
|
88
|
-
extern Register no_reg;
|
89
|
-
extern Register r0;
|
90
|
-
extern Register r1;
|
91
|
-
extern Register r2;
|
92
|
-
extern Register r3;
|
93
|
-
extern Register r4;
|
94
|
-
extern Register r5;
|
95
|
-
extern Register r6;
|
96
|
-
extern Register r7;
|
97
|
-
extern Register r8;
|
98
|
-
extern Register r9;
|
99
|
-
extern Register r10;
|
100
|
-
extern Register fp;
|
101
|
-
extern Register ip;
|
102
|
-
extern Register sp;
|
103
|
-
extern Register lr;
|
104
|
-
extern Register pc;
|
105
|
-
|
106
|
-
|
107
|
-
// Single word VFP register.
|
108
|
-
struct SwVfpRegister {
|
109
|
-
bool is_valid() const { return 0 <= code_ && code_ < 32; }
|
110
|
-
bool is(SwVfpRegister reg) const { return code_ == reg.code_; }
|
111
|
-
int code() const {
|
112
|
-
ASSERT(is_valid());
|
113
|
-
return code_;
|
114
|
-
}
|
115
|
-
int bit() const {
|
116
|
-
ASSERT(is_valid());
|
117
|
-
return 1 << code_;
|
118
|
-
}
|
119
|
-
|
120
|
-
int code_;
|
121
|
-
};
|
122
|
-
|
123
|
-
|
124
|
-
// Double word VFP register.
|
125
|
-
struct DwVfpRegister {
|
126
|
-
// Supporting d0 to d15, can be later extended to d31.
|
127
|
-
bool is_valid() const { return 0 <= code_ && code_ < 16; }
|
128
|
-
bool is(DwVfpRegister reg) const { return code_ == reg.code_; }
|
129
|
-
int code() const {
|
130
|
-
ASSERT(is_valid());
|
131
|
-
return code_;
|
132
|
-
}
|
133
|
-
int bit() const {
|
134
|
-
ASSERT(is_valid());
|
135
|
-
return 1 << code_;
|
136
|
-
}
|
137
|
-
|
138
|
-
int code_;
|
139
|
-
};
|
140
|
-
|
141
|
-
|
142
|
-
// Support for VFP registers s0 to s31 (d0 to d15).
|
143
|
-
// Note that "s(N):s(N+1)" is the same as "d(N/2)".
|
144
|
-
extern SwVfpRegister s0;
|
145
|
-
extern SwVfpRegister s1;
|
146
|
-
extern SwVfpRegister s2;
|
147
|
-
extern SwVfpRegister s3;
|
148
|
-
extern SwVfpRegister s4;
|
149
|
-
extern SwVfpRegister s5;
|
150
|
-
extern SwVfpRegister s6;
|
151
|
-
extern SwVfpRegister s7;
|
152
|
-
extern SwVfpRegister s8;
|
153
|
-
extern SwVfpRegister s9;
|
154
|
-
extern SwVfpRegister s10;
|
155
|
-
extern SwVfpRegister s11;
|
156
|
-
extern SwVfpRegister s12;
|
157
|
-
extern SwVfpRegister s13;
|
158
|
-
extern SwVfpRegister s14;
|
159
|
-
extern SwVfpRegister s15;
|
160
|
-
extern SwVfpRegister s16;
|
161
|
-
extern SwVfpRegister s17;
|
162
|
-
extern SwVfpRegister s18;
|
163
|
-
extern SwVfpRegister s19;
|
164
|
-
extern SwVfpRegister s20;
|
165
|
-
extern SwVfpRegister s21;
|
166
|
-
extern SwVfpRegister s22;
|
167
|
-
extern SwVfpRegister s23;
|
168
|
-
extern SwVfpRegister s24;
|
169
|
-
extern SwVfpRegister s25;
|
170
|
-
extern SwVfpRegister s26;
|
171
|
-
extern SwVfpRegister s27;
|
172
|
-
extern SwVfpRegister s28;
|
173
|
-
extern SwVfpRegister s29;
|
174
|
-
extern SwVfpRegister s30;
|
175
|
-
extern SwVfpRegister s31;
|
176
|
-
|
177
|
-
extern DwVfpRegister d0;
|
178
|
-
extern DwVfpRegister d1;
|
179
|
-
extern DwVfpRegister d2;
|
180
|
-
extern DwVfpRegister d3;
|
181
|
-
extern DwVfpRegister d4;
|
182
|
-
extern DwVfpRegister d5;
|
183
|
-
extern DwVfpRegister d6;
|
184
|
-
extern DwVfpRegister d7;
|
185
|
-
extern DwVfpRegister d8;
|
186
|
-
extern DwVfpRegister d9;
|
187
|
-
extern DwVfpRegister d10;
|
188
|
-
extern DwVfpRegister d11;
|
189
|
-
extern DwVfpRegister d12;
|
190
|
-
extern DwVfpRegister d13;
|
191
|
-
extern DwVfpRegister d14;
|
192
|
-
extern DwVfpRegister d15;
|
193
|
-
|
194
|
-
|
195
|
-
// Coprocessor register
|
196
|
-
struct CRegister {
|
197
|
-
bool is_valid() const { return 0 <= code_ && code_ < 16; }
|
198
|
-
bool is(CRegister creg) const { return code_ == creg.code_; }
|
199
|
-
int code() const {
|
200
|
-
ASSERT(is_valid());
|
201
|
-
return code_;
|
202
|
-
}
|
203
|
-
int bit() const {
|
204
|
-
ASSERT(is_valid());
|
205
|
-
return 1 << code_;
|
206
|
-
}
|
207
|
-
|
208
|
-
// Unfortunately we can't make this private in a struct.
|
209
|
-
int code_;
|
210
|
-
};
|
211
|
-
|
212
|
-
|
213
|
-
extern CRegister no_creg;
|
214
|
-
extern CRegister cr0;
|
215
|
-
extern CRegister cr1;
|
216
|
-
extern CRegister cr2;
|
217
|
-
extern CRegister cr3;
|
218
|
-
extern CRegister cr4;
|
219
|
-
extern CRegister cr5;
|
220
|
-
extern CRegister cr6;
|
221
|
-
extern CRegister cr7;
|
222
|
-
extern CRegister cr8;
|
223
|
-
extern CRegister cr9;
|
224
|
-
extern CRegister cr10;
|
225
|
-
extern CRegister cr11;
|
226
|
-
extern CRegister cr12;
|
227
|
-
extern CRegister cr13;
|
228
|
-
extern CRegister cr14;
|
229
|
-
extern CRegister cr15;
|
230
|
-
|
231
|
-
|
232
|
-
// Coprocessor number
|
233
|
-
enum Coprocessor {
|
234
|
-
p0 = 0,
|
235
|
-
p1 = 1,
|
236
|
-
p2 = 2,
|
237
|
-
p3 = 3,
|
238
|
-
p4 = 4,
|
239
|
-
p5 = 5,
|
240
|
-
p6 = 6,
|
241
|
-
p7 = 7,
|
242
|
-
p8 = 8,
|
243
|
-
p9 = 9,
|
244
|
-
p10 = 10,
|
245
|
-
p11 = 11,
|
246
|
-
p12 = 12,
|
247
|
-
p13 = 13,
|
248
|
-
p14 = 14,
|
249
|
-
p15 = 15
|
250
|
-
};
|
251
|
-
|
252
|
-
|
253
|
-
// Condition field in instructions.
|
254
|
-
enum Condition {
|
255
|
-
eq = 0 << 28, // Z set equal.
|
256
|
-
ne = 1 << 28, // Z clear not equal.
|
257
|
-
nz = 1 << 28, // Z clear not zero.
|
258
|
-
cs = 2 << 28, // C set carry set.
|
259
|
-
hs = 2 << 28, // C set unsigned higher or same.
|
260
|
-
cc = 3 << 28, // C clear carry clear.
|
261
|
-
lo = 3 << 28, // C clear unsigned lower.
|
262
|
-
mi = 4 << 28, // N set negative.
|
263
|
-
pl = 5 << 28, // N clear positive or zero.
|
264
|
-
vs = 6 << 28, // V set overflow.
|
265
|
-
vc = 7 << 28, // V clear no overflow.
|
266
|
-
hi = 8 << 28, // C set, Z clear unsigned higher.
|
267
|
-
ls = 9 << 28, // C clear or Z set unsigned lower or same.
|
268
|
-
ge = 10 << 28, // N == V greater or equal.
|
269
|
-
lt = 11 << 28, // N != V less than.
|
270
|
-
gt = 12 << 28, // Z clear, N == V greater than.
|
271
|
-
le = 13 << 28, // Z set or N != V less then or equal
|
272
|
-
al = 14 << 28 // always.
|
273
|
-
};
|
274
|
-
|
275
|
-
|
276
|
-
// Returns the equivalent of !cc.
|
277
|
-
INLINE(Condition NegateCondition(Condition cc));
|
278
|
-
|
279
|
-
|
280
|
-
// Corresponds to transposing the operands of a comparison.
|
281
|
-
inline Condition ReverseCondition(Condition cc) {
|
282
|
-
switch (cc) {
|
283
|
-
case lo:
|
284
|
-
return hi;
|
285
|
-
case hi:
|
286
|
-
return lo;
|
287
|
-
case hs:
|
288
|
-
return ls;
|
289
|
-
case ls:
|
290
|
-
return hs;
|
291
|
-
case lt:
|
292
|
-
return gt;
|
293
|
-
case gt:
|
294
|
-
return lt;
|
295
|
-
case ge:
|
296
|
-
return le;
|
297
|
-
case le:
|
298
|
-
return ge;
|
299
|
-
default:
|
300
|
-
return cc;
|
301
|
-
};
|
302
|
-
}
|
303
|
-
|
304
|
-
|
305
|
-
// Branch hints are not used on the ARM. They are defined so that they can
|
306
|
-
// appear in shared function signatures, but will be ignored in ARM
|
307
|
-
// implementations.
|
308
|
-
enum Hint { no_hint };
|
309
|
-
|
310
|
-
// Hints are not used on the arm. Negating is trivial.
|
311
|
-
inline Hint NegateHint(Hint ignored) { return no_hint; }
|
312
|
-
|
313
|
-
|
314
|
-
// -----------------------------------------------------------------------------
|
315
|
-
// Addressing modes and instruction variants
|
316
|
-
|
317
|
-
// Shifter operand shift operation
|
318
|
-
enum ShiftOp {
|
319
|
-
LSL = 0 << 5,
|
320
|
-
LSR = 1 << 5,
|
321
|
-
ASR = 2 << 5,
|
322
|
-
ROR = 3 << 5,
|
323
|
-
RRX = -1
|
324
|
-
};
|
325
|
-
|
326
|
-
|
327
|
-
// Condition code updating mode
|
328
|
-
enum SBit {
|
329
|
-
SetCC = 1 << 20, // set condition code
|
330
|
-
LeaveCC = 0 << 20 // leave condition code unchanged
|
331
|
-
};
|
332
|
-
|
333
|
-
|
334
|
-
// Status register selection
|
335
|
-
enum SRegister {
|
336
|
-
CPSR = 0 << 22,
|
337
|
-
SPSR = 1 << 22
|
338
|
-
};
|
339
|
-
|
340
|
-
|
341
|
-
// Status register fields
|
342
|
-
enum SRegisterField {
|
343
|
-
CPSR_c = CPSR | 1 << 16,
|
344
|
-
CPSR_x = CPSR | 1 << 17,
|
345
|
-
CPSR_s = CPSR | 1 << 18,
|
346
|
-
CPSR_f = CPSR | 1 << 19,
|
347
|
-
SPSR_c = SPSR | 1 << 16,
|
348
|
-
SPSR_x = SPSR | 1 << 17,
|
349
|
-
SPSR_s = SPSR | 1 << 18,
|
350
|
-
SPSR_f = SPSR | 1 << 19
|
351
|
-
};
|
352
|
-
|
353
|
-
// Status register field mask (or'ed SRegisterField enum values)
|
354
|
-
typedef uint32_t SRegisterFieldMask;
|
355
|
-
|
356
|
-
|
357
|
-
// Memory operand addressing mode
|
358
|
-
enum AddrMode {
|
359
|
-
// bit encoding P U W
|
360
|
-
Offset = (8|4|0) << 21, // offset (without writeback to base)
|
361
|
-
PreIndex = (8|4|1) << 21, // pre-indexed addressing with writeback
|
362
|
-
PostIndex = (0|4|0) << 21, // post-indexed addressing with writeback
|
363
|
-
NegOffset = (8|0|0) << 21, // negative offset (without writeback to base)
|
364
|
-
NegPreIndex = (8|0|1) << 21, // negative pre-indexed with writeback
|
365
|
-
NegPostIndex = (0|0|0) << 21 // negative post-indexed with writeback
|
366
|
-
};
|
367
|
-
|
368
|
-
|
369
|
-
// Load/store multiple addressing mode
|
370
|
-
enum BlockAddrMode {
|
371
|
-
// bit encoding P U W
|
372
|
-
da = (0|0|0) << 21, // decrement after
|
373
|
-
ia = (0|4|0) << 21, // increment after
|
374
|
-
db = (8|0|0) << 21, // decrement before
|
375
|
-
ib = (8|4|0) << 21, // increment before
|
376
|
-
da_w = (0|0|1) << 21, // decrement after with writeback to base
|
377
|
-
ia_w = (0|4|1) << 21, // increment after with writeback to base
|
378
|
-
db_w = (8|0|1) << 21, // decrement before with writeback to base
|
379
|
-
ib_w = (8|4|1) << 21 // increment before with writeback to base
|
380
|
-
};
|
381
|
-
|
382
|
-
|
383
|
-
// Coprocessor load/store operand size
|
384
|
-
enum LFlag {
|
385
|
-
Long = 1 << 22, // long load/store coprocessor
|
386
|
-
Short = 0 << 22 // short load/store coprocessor
|
387
|
-
};
|
388
|
-
|
389
|
-
|
390
|
-
// -----------------------------------------------------------------------------
|
391
|
-
// Machine instruction Operands
|
392
|
-
|
393
|
-
// Class Operand represents a shifter operand in data processing instructions
|
394
|
-
class Operand BASE_EMBEDDED {
|
395
|
-
public:
|
396
|
-
// immediate
|
397
|
-
INLINE(explicit Operand(int32_t immediate,
|
398
|
-
RelocInfo::Mode rmode = RelocInfo::NONE));
|
399
|
-
INLINE(explicit Operand(const ExternalReference& f));
|
400
|
-
INLINE(explicit Operand(const char* s));
|
401
|
-
explicit Operand(Handle<Object> handle);
|
402
|
-
INLINE(explicit Operand(Smi* value));
|
403
|
-
|
404
|
-
// rm
|
405
|
-
INLINE(explicit Operand(Register rm));
|
406
|
-
|
407
|
-
// rm <shift_op> shift_imm
|
408
|
-
explicit Operand(Register rm, ShiftOp shift_op, int shift_imm);
|
409
|
-
|
410
|
-
// rm <shift_op> rs
|
411
|
-
explicit Operand(Register rm, ShiftOp shift_op, Register rs);
|
412
|
-
|
413
|
-
// Return true if this is a register operand.
|
414
|
-
INLINE(bool is_reg() const);
|
415
|
-
|
416
|
-
Register rm() const { return rm_; }
|
417
|
-
|
418
|
-
private:
|
419
|
-
Register rm_;
|
420
|
-
Register rs_;
|
421
|
-
ShiftOp shift_op_;
|
422
|
-
int shift_imm_; // valid if rm_ != no_reg && rs_ == no_reg
|
423
|
-
int32_t imm32_; // valid if rm_ == no_reg
|
424
|
-
RelocInfo::Mode rmode_;
|
425
|
-
|
426
|
-
friend class Assembler;
|
427
|
-
};
|
428
|
-
|
429
|
-
|
430
|
-
// Class MemOperand represents a memory operand in load and store instructions
|
431
|
-
class MemOperand BASE_EMBEDDED {
|
432
|
-
public:
|
433
|
-
// [rn +/- offset] Offset/NegOffset
|
434
|
-
// [rn +/- offset]! PreIndex/NegPreIndex
|
435
|
-
// [rn], +/- offset PostIndex/NegPostIndex
|
436
|
-
// offset is any signed 32-bit value; offset is first loaded to register ip if
|
437
|
-
// it does not fit the addressing mode (12-bit unsigned and sign bit)
|
438
|
-
explicit MemOperand(Register rn, int32_t offset = 0, AddrMode am = Offset);
|
439
|
-
|
440
|
-
// [rn +/- rm] Offset/NegOffset
|
441
|
-
// [rn +/- rm]! PreIndex/NegPreIndex
|
442
|
-
// [rn], +/- rm PostIndex/NegPostIndex
|
443
|
-
explicit MemOperand(Register rn, Register rm, AddrMode am = Offset);
|
444
|
-
|
445
|
-
// [rn +/- rm <shift_op> shift_imm] Offset/NegOffset
|
446
|
-
// [rn +/- rm <shift_op> shift_imm]! PreIndex/NegPreIndex
|
447
|
-
// [rn], +/- rm <shift_op> shift_imm PostIndex/NegPostIndex
|
448
|
-
explicit MemOperand(Register rn, Register rm,
|
449
|
-
ShiftOp shift_op, int shift_imm, AddrMode am = Offset);
|
450
|
-
|
451
|
-
private:
|
452
|
-
Register rn_; // base
|
453
|
-
Register rm_; // register offset
|
454
|
-
int32_t offset_; // valid if rm_ == no_reg
|
455
|
-
ShiftOp shift_op_;
|
456
|
-
int shift_imm_; // valid if rm_ != no_reg && rs_ == no_reg
|
457
|
-
AddrMode am_; // bits P, U, and W
|
458
|
-
|
459
|
-
friend class Assembler;
|
460
|
-
};
|
461
|
-
|
462
|
-
// CpuFeatures keeps track of which features are supported by the target CPU.
|
463
|
-
// Supported features must be enabled by a Scope before use.
|
464
|
-
class CpuFeatures : public AllStatic {
|
465
|
-
public:
|
466
|
-
// Detect features of the target CPU. Set safe defaults if the serializer
|
467
|
-
// is enabled (snapshots must be portable).
|
468
|
-
static void Probe();
|
469
|
-
|
470
|
-
// Check whether a feature is supported by the target CPU.
|
471
|
-
static bool IsSupported(CpuFeature f) {
|
472
|
-
if (f == VFP3 && !FLAG_enable_vfp3) return false;
|
473
|
-
return (supported_ & (1u << f)) != 0;
|
474
|
-
}
|
475
|
-
|
476
|
-
// Check whether a feature is currently enabled.
|
477
|
-
static bool IsEnabled(CpuFeature f) {
|
478
|
-
return (enabled_ & (1u << f)) != 0;
|
479
|
-
}
|
480
|
-
|
481
|
-
// Enable a specified feature within a scope.
|
482
|
-
class Scope BASE_EMBEDDED {
|
483
|
-
#ifdef DEBUG
|
484
|
-
public:
|
485
|
-
explicit Scope(CpuFeature f) {
|
486
|
-
ASSERT(CpuFeatures::IsSupported(f));
|
487
|
-
ASSERT(!Serializer::enabled() ||
|
488
|
-
(found_by_runtime_probing_ & (1u << f)) == 0);
|
489
|
-
old_enabled_ = CpuFeatures::enabled_;
|
490
|
-
CpuFeatures::enabled_ |= 1u << f;
|
491
|
-
}
|
492
|
-
~Scope() { CpuFeatures::enabled_ = old_enabled_; }
|
493
|
-
private:
|
494
|
-
unsigned old_enabled_;
|
495
|
-
#else
|
496
|
-
public:
|
497
|
-
explicit Scope(CpuFeature f) {}
|
498
|
-
#endif
|
499
|
-
};
|
500
|
-
|
501
|
-
private:
|
502
|
-
static unsigned supported_;
|
503
|
-
static unsigned enabled_;
|
504
|
-
static unsigned found_by_runtime_probing_;
|
505
|
-
};
|
506
|
-
|
507
|
-
|
508
|
-
typedef int32_t Instr;
|
509
|
-
|
510
|
-
|
511
|
-
extern const Instr kMovLrPc;
|
512
|
-
extern const Instr kLdrPCPattern;
|
513
|
-
|
514
|
-
|
515
|
-
class Assembler : public Malloced {
|
516
|
-
public:
|
517
|
-
// Create an assembler. Instructions and relocation information are emitted
|
518
|
-
// into a buffer, with the instructions starting from the beginning and the
|
519
|
-
// relocation information starting from the end of the buffer. See CodeDesc
|
520
|
-
// for a detailed comment on the layout (globals.h).
|
521
|
-
//
|
522
|
-
// If the provided buffer is NULL, the assembler allocates and grows its own
|
523
|
-
// buffer, and buffer_size determines the initial buffer size. The buffer is
|
524
|
-
// owned by the assembler and deallocated upon destruction of the assembler.
|
525
|
-
//
|
526
|
-
// If the provided buffer is not NULL, the assembler uses the provided buffer
|
527
|
-
// for code generation and assumes its size to be buffer_size. If the buffer
|
528
|
-
// is too small, a fatal error occurs. No deallocation of the buffer is done
|
529
|
-
// upon destruction of the assembler.
|
530
|
-
Assembler(void* buffer, int buffer_size);
|
531
|
-
~Assembler();
|
532
|
-
|
533
|
-
// GetCode emits any pending (non-emitted) code and fills the descriptor
|
534
|
-
// desc. GetCode() is idempotent; it returns the same result if no other
|
535
|
-
// Assembler functions are invoked in between GetCode() calls.
|
536
|
-
void GetCode(CodeDesc* desc);
|
537
|
-
|
538
|
-
// Label operations & relative jumps (PPUM Appendix D)
|
539
|
-
//
|
540
|
-
// Takes a branch opcode (cc) and a label (L) and generates
|
541
|
-
// either a backward branch or a forward branch and links it
|
542
|
-
// to the label fixup chain. Usage:
|
543
|
-
//
|
544
|
-
// Label L; // unbound label
|
545
|
-
// j(cc, &L); // forward branch to unbound label
|
546
|
-
// bind(&L); // bind label to the current pc
|
547
|
-
// j(cc, &L); // backward branch to bound label
|
548
|
-
// bind(&L); // illegal: a label may be bound only once
|
549
|
-
//
|
550
|
-
// Note: The same Label can be used for forward and backward branches
|
551
|
-
// but it may be bound only once.
|
552
|
-
|
553
|
-
void bind(Label* L); // binds an unbound label L to the current code position
|
554
|
-
|
555
|
-
// Returns the branch offset to the given label from the current code position
|
556
|
-
// Links the label to the current position if it is still unbound
|
557
|
-
// Manages the jump elimination optimization if the second parameter is true.
|
558
|
-
int branch_offset(Label* L, bool jump_elimination_allowed);
|
559
|
-
|
560
|
-
// Puts a labels target address at the given position.
|
561
|
-
// The high 8 bits are set to zero.
|
562
|
-
void label_at_put(Label* L, int at_offset);
|
563
|
-
|
564
|
-
// Return the address in the constant pool of the code target address used by
|
565
|
-
// the branch/call instruction at pc.
|
566
|
-
INLINE(static Address target_address_address_at(Address pc));
|
567
|
-
|
568
|
-
// Read/Modify the code target address in the branch/call instruction at pc.
|
569
|
-
INLINE(static Address target_address_at(Address pc));
|
570
|
-
INLINE(static void set_target_address_at(Address pc, Address target));
|
571
|
-
|
572
|
-
// This sets the branch destination (which is in the constant pool on ARM).
|
573
|
-
// This is for calls and branches within generated code.
|
574
|
-
inline static void set_target_at(Address constant_pool_entry, Address target);
|
575
|
-
|
576
|
-
// This sets the branch destination (which is in the constant pool on ARM).
|
577
|
-
// This is for calls and branches to runtime code.
|
578
|
-
inline static void set_external_target_at(Address constant_pool_entry,
|
579
|
-
Address target) {
|
580
|
-
set_target_at(constant_pool_entry, target);
|
581
|
-
}
|
582
|
-
|
583
|
-
// Here we are patching the address in the constant pool, not the actual call
|
584
|
-
// instruction. The address in the constant pool is the same size as a
|
585
|
-
// pointer.
|
586
|
-
static const int kCallTargetSize = kPointerSize;
|
587
|
-
static const int kExternalTargetSize = kPointerSize;
|
588
|
-
|
589
|
-
// Size of an instruction.
|
590
|
-
static const int kInstrSize = sizeof(Instr);
|
591
|
-
|
592
|
-
// Distance between the instruction referring to the address of the call
|
593
|
-
// target (ldr pc, [target addr in const pool]) and the return address
|
594
|
-
static const int kCallTargetAddressOffset = kInstrSize;
|
595
|
-
|
596
|
-
// Distance between start of patched return sequence and the emitted address
|
597
|
-
// to jump to.
|
598
|
-
static const int kPatchReturnSequenceAddressOffset = kInstrSize;
|
599
|
-
|
600
|
-
// Difference between address of current opcode and value read from pc
|
601
|
-
// register.
|
602
|
-
static const int kPcLoadDelta = 8;
|
603
|
-
|
604
|
-
static const int kJSReturnSequenceLength = 4;
|
605
|
-
|
606
|
-
// ---------------------------------------------------------------------------
|
607
|
-
// Code generation
|
608
|
-
|
609
|
-
// Insert the smallest number of nop instructions
|
610
|
-
// possible to align the pc offset to a multiple
|
611
|
-
// of m. m must be a power of 2 (>= 4).
|
612
|
-
void Align(int m);
|
613
|
-
|
614
|
-
// Branch instructions
|
615
|
-
void b(int branch_offset, Condition cond = al);
|
616
|
-
void bl(int branch_offset, Condition cond = al);
|
617
|
-
void blx(int branch_offset); // v5 and above
|
618
|
-
void blx(Register target, Condition cond = al); // v5 and above
|
619
|
-
void bx(Register target, Condition cond = al); // v5 and above, plus v4t
|
620
|
-
|
621
|
-
// Convenience branch instructions using labels
|
622
|
-
void b(Label* L, Condition cond = al) {
|
623
|
-
b(branch_offset(L, cond == al), cond);
|
624
|
-
}
|
625
|
-
void b(Condition cond, Label* L) { b(branch_offset(L, cond == al), cond); }
|
626
|
-
void bl(Label* L, Condition cond = al) { bl(branch_offset(L, false), cond); }
|
627
|
-
void bl(Condition cond, Label* L) { bl(branch_offset(L, false), cond); }
|
628
|
-
void blx(Label* L) { blx(branch_offset(L, false)); } // v5 and above
|
629
|
-
|
630
|
-
// Data-processing instructions
|
631
|
-
void ubfx(Register dst, Register src1, const Operand& src2,
|
632
|
-
const Operand& src3, Condition cond = al);
|
633
|
-
|
634
|
-
void and_(Register dst, Register src1, const Operand& src2,
|
635
|
-
SBit s = LeaveCC, Condition cond = al);
|
636
|
-
|
637
|
-
void eor(Register dst, Register src1, const Operand& src2,
|
638
|
-
SBit s = LeaveCC, Condition cond = al);
|
639
|
-
|
640
|
-
void sub(Register dst, Register src1, const Operand& src2,
|
641
|
-
SBit s = LeaveCC, Condition cond = al);
|
642
|
-
void sub(Register dst, Register src1, Register src2,
|
643
|
-
SBit s = LeaveCC, Condition cond = al) {
|
644
|
-
sub(dst, src1, Operand(src2), s, cond);
|
645
|
-
}
|
646
|
-
|
647
|
-
void rsb(Register dst, Register src1, const Operand& src2,
|
648
|
-
SBit s = LeaveCC, Condition cond = al);
|
649
|
-
|
650
|
-
void add(Register dst, Register src1, const Operand& src2,
|
651
|
-
SBit s = LeaveCC, Condition cond = al);
|
652
|
-
|
653
|
-
void adc(Register dst, Register src1, const Operand& src2,
|
654
|
-
SBit s = LeaveCC, Condition cond = al);
|
655
|
-
|
656
|
-
void sbc(Register dst, Register src1, const Operand& src2,
|
657
|
-
SBit s = LeaveCC, Condition cond = al);
|
658
|
-
|
659
|
-
void rsc(Register dst, Register src1, const Operand& src2,
|
660
|
-
SBit s = LeaveCC, Condition cond = al);
|
661
|
-
|
662
|
-
void tst(Register src1, const Operand& src2, Condition cond = al);
|
663
|
-
void tst(Register src1, Register src2, Condition cond = al) {
|
664
|
-
tst(src1, Operand(src2), cond);
|
665
|
-
}
|
666
|
-
|
667
|
-
void teq(Register src1, const Operand& src2, Condition cond = al);
|
668
|
-
|
669
|
-
void cmp(Register src1, const Operand& src2, Condition cond = al);
|
670
|
-
void cmp(Register src1, Register src2, Condition cond = al) {
|
671
|
-
cmp(src1, Operand(src2), cond);
|
672
|
-
}
|
673
|
-
|
674
|
-
void cmn(Register src1, const Operand& src2, Condition cond = al);
|
675
|
-
|
676
|
-
void orr(Register dst, Register src1, const Operand& src2,
|
677
|
-
SBit s = LeaveCC, Condition cond = al);
|
678
|
-
void orr(Register dst, Register src1, Register src2,
|
679
|
-
SBit s = LeaveCC, Condition cond = al) {
|
680
|
-
orr(dst, src1, Operand(src2), s, cond);
|
681
|
-
}
|
682
|
-
|
683
|
-
void mov(Register dst, const Operand& src,
|
684
|
-
SBit s = LeaveCC, Condition cond = al);
|
685
|
-
void mov(Register dst, Register src, SBit s = LeaveCC, Condition cond = al) {
|
686
|
-
mov(dst, Operand(src), s, cond);
|
687
|
-
}
|
688
|
-
|
689
|
-
void bic(Register dst, Register src1, const Operand& src2,
|
690
|
-
SBit s = LeaveCC, Condition cond = al);
|
691
|
-
|
692
|
-
void mvn(Register dst, const Operand& src,
|
693
|
-
SBit s = LeaveCC, Condition cond = al);
|
694
|
-
|
695
|
-
// Multiply instructions
|
696
|
-
|
697
|
-
void mla(Register dst, Register src1, Register src2, Register srcA,
|
698
|
-
SBit s = LeaveCC, Condition cond = al);
|
699
|
-
|
700
|
-
void mul(Register dst, Register src1, Register src2,
|
701
|
-
SBit s = LeaveCC, Condition cond = al);
|
702
|
-
|
703
|
-
void smlal(Register dstL, Register dstH, Register src1, Register src2,
|
704
|
-
SBit s = LeaveCC, Condition cond = al);
|
705
|
-
|
706
|
-
void smull(Register dstL, Register dstH, Register src1, Register src2,
|
707
|
-
SBit s = LeaveCC, Condition cond = al);
|
708
|
-
|
709
|
-
void umlal(Register dstL, Register dstH, Register src1, Register src2,
|
710
|
-
SBit s = LeaveCC, Condition cond = al);
|
711
|
-
|
712
|
-
void umull(Register dstL, Register dstH, Register src1, Register src2,
|
713
|
-
SBit s = LeaveCC, Condition cond = al);
|
714
|
-
|
715
|
-
// Miscellaneous arithmetic instructions
|
716
|
-
|
717
|
-
void clz(Register dst, Register src, Condition cond = al); // v5 and above
|
718
|
-
|
719
|
-
// Status register access instructions
|
720
|
-
|
721
|
-
void mrs(Register dst, SRegister s, Condition cond = al);
|
722
|
-
void msr(SRegisterFieldMask fields, const Operand& src, Condition cond = al);
|
723
|
-
|
724
|
-
// Load/Store instructions
|
725
|
-
void ldr(Register dst, const MemOperand& src, Condition cond = al);
|
726
|
-
void str(Register src, const MemOperand& dst, Condition cond = al);
|
727
|
-
void ldrb(Register dst, const MemOperand& src, Condition cond = al);
|
728
|
-
void strb(Register src, const MemOperand& dst, Condition cond = al);
|
729
|
-
void ldrh(Register dst, const MemOperand& src, Condition cond = al);
|
730
|
-
void strh(Register src, const MemOperand& dst, Condition cond = al);
|
731
|
-
void ldrsb(Register dst, const MemOperand& src, Condition cond = al);
|
732
|
-
void ldrsh(Register dst, const MemOperand& src, Condition cond = al);
|
733
|
-
|
734
|
-
// Load/Store multiple instructions
|
735
|
-
void ldm(BlockAddrMode am, Register base, RegList dst, Condition cond = al);
|
736
|
-
void stm(BlockAddrMode am, Register base, RegList src, Condition cond = al);
|
737
|
-
|
738
|
-
// Semaphore instructions
|
739
|
-
void swp(Register dst, Register src, Register base, Condition cond = al);
|
740
|
-
void swpb(Register dst, Register src, Register base, Condition cond = al);
|
741
|
-
|
742
|
-
// Exception-generating instructions and debugging support
|
743
|
-
void stop(const char* msg);
|
744
|
-
|
745
|
-
void bkpt(uint32_t imm16); // v5 and above
|
746
|
-
void swi(uint32_t imm24, Condition cond = al);
|
747
|
-
|
748
|
-
// Coprocessor instructions
|
749
|
-
|
750
|
-
void cdp(Coprocessor coproc, int opcode_1,
|
751
|
-
CRegister crd, CRegister crn, CRegister crm,
|
752
|
-
int opcode_2, Condition cond = al);
|
753
|
-
|
754
|
-
void cdp2(Coprocessor coproc, int opcode_1,
|
755
|
-
CRegister crd, CRegister crn, CRegister crm,
|
756
|
-
int opcode_2); // v5 and above
|
757
|
-
|
758
|
-
void mcr(Coprocessor coproc, int opcode_1,
|
759
|
-
Register rd, CRegister crn, CRegister crm,
|
760
|
-
int opcode_2 = 0, Condition cond = al);
|
761
|
-
|
762
|
-
void mcr2(Coprocessor coproc, int opcode_1,
|
763
|
-
Register rd, CRegister crn, CRegister crm,
|
764
|
-
int opcode_2 = 0); // v5 and above
|
765
|
-
|
766
|
-
void mrc(Coprocessor coproc, int opcode_1,
|
767
|
-
Register rd, CRegister crn, CRegister crm,
|
768
|
-
int opcode_2 = 0, Condition cond = al);
|
769
|
-
|
770
|
-
void mrc2(Coprocessor coproc, int opcode_1,
|
771
|
-
Register rd, CRegister crn, CRegister crm,
|
772
|
-
int opcode_2 = 0); // v5 and above
|
773
|
-
|
774
|
-
void ldc(Coprocessor coproc, CRegister crd, const MemOperand& src,
|
775
|
-
LFlag l = Short, Condition cond = al);
|
776
|
-
void ldc(Coprocessor coproc, CRegister crd, Register base, int option,
|
777
|
-
LFlag l = Short, Condition cond = al);
|
778
|
-
|
779
|
-
void ldc2(Coprocessor coproc, CRegister crd, const MemOperand& src,
|
780
|
-
LFlag l = Short); // v5 and above
|
781
|
-
void ldc2(Coprocessor coproc, CRegister crd, Register base, int option,
|
782
|
-
LFlag l = Short); // v5 and above
|
783
|
-
|
784
|
-
void stc(Coprocessor coproc, CRegister crd, const MemOperand& dst,
|
785
|
-
LFlag l = Short, Condition cond = al);
|
786
|
-
void stc(Coprocessor coproc, CRegister crd, Register base, int option,
|
787
|
-
LFlag l = Short, Condition cond = al);
|
788
|
-
|
789
|
-
void stc2(Coprocessor coproc, CRegister crd, const MemOperand& dst,
|
790
|
-
LFlag l = Short); // v5 and above
|
791
|
-
void stc2(Coprocessor coproc, CRegister crd, Register base, int option,
|
792
|
-
LFlag l = Short); // v5 and above
|
793
|
-
|
794
|
-
// Support for VFP.
|
795
|
-
// All these APIs support S0 to S31 and D0 to D15.
|
796
|
-
// Currently these APIs do not support extended D registers, i.e, D16 to D31.
|
797
|
-
// However, some simple modifications can allow
|
798
|
-
// these APIs to support D16 to D31.
|
799
|
-
|
800
|
-
void vldr(const DwVfpRegister dst,
|
801
|
-
const Register base,
|
802
|
-
int offset, // Offset must be a multiple of 4.
|
803
|
-
const Condition cond = al);
|
804
|
-
void vstr(const DwVfpRegister src,
|
805
|
-
const Register base,
|
806
|
-
int offset, // Offset must be a multiple of 4.
|
807
|
-
const Condition cond = al);
|
808
|
-
void vmov(const DwVfpRegister dst,
|
809
|
-
const Register src1,
|
810
|
-
const Register src2,
|
811
|
-
const Condition cond = al);
|
812
|
-
void vmov(const Register dst1,
|
813
|
-
const Register dst2,
|
814
|
-
const DwVfpRegister src,
|
815
|
-
const Condition cond = al);
|
816
|
-
void vmov(const SwVfpRegister dst,
|
817
|
-
const Register src,
|
818
|
-
const Condition cond = al);
|
819
|
-
void vmov(const Register dst,
|
820
|
-
const SwVfpRegister src,
|
821
|
-
const Condition cond = al);
|
822
|
-
void vcvt(const DwVfpRegister dst,
|
823
|
-
const SwVfpRegister src,
|
824
|
-
const Condition cond = al);
|
825
|
-
void vcvt(const SwVfpRegister dst,
|
826
|
-
const DwVfpRegister src,
|
827
|
-
const Condition cond = al);
|
828
|
-
|
829
|
-
void vadd(const DwVfpRegister dst,
|
830
|
-
const DwVfpRegister src1,
|
831
|
-
const DwVfpRegister src2,
|
832
|
-
const Condition cond = al);
|
833
|
-
void vsub(const DwVfpRegister dst,
|
834
|
-
const DwVfpRegister src1,
|
835
|
-
const DwVfpRegister src2,
|
836
|
-
const Condition cond = al);
|
837
|
-
void vmul(const DwVfpRegister dst,
|
838
|
-
const DwVfpRegister src1,
|
839
|
-
const DwVfpRegister src2,
|
840
|
-
const Condition cond = al);
|
841
|
-
void vdiv(const DwVfpRegister dst,
|
842
|
-
const DwVfpRegister src1,
|
843
|
-
const DwVfpRegister src2,
|
844
|
-
const Condition cond = al);
|
845
|
-
void vcmp(const DwVfpRegister src1,
|
846
|
-
const DwVfpRegister src2,
|
847
|
-
const SBit s = LeaveCC,
|
848
|
-
const Condition cond = al);
|
849
|
-
void vmrs(const Register dst,
|
850
|
-
const Condition cond = al);
|
851
|
-
|
852
|
-
// Pseudo instructions
|
853
|
-
void nop() { mov(r0, Operand(r0)); }
|
854
|
-
|
855
|
-
void push(Register src, Condition cond = al) {
|
856
|
-
str(src, MemOperand(sp, 4, NegPreIndex), cond);
|
857
|
-
}
|
858
|
-
|
859
|
-
void pop(Register dst, Condition cond = al) {
|
860
|
-
ldr(dst, MemOperand(sp, 4, PostIndex), cond);
|
861
|
-
}
|
862
|
-
|
863
|
-
void pop() {
|
864
|
-
add(sp, sp, Operand(kPointerSize));
|
865
|
-
}
|
866
|
-
|
867
|
-
// Load effective address of memory operand x into register dst
|
868
|
-
void lea(Register dst, const MemOperand& x,
|
869
|
-
SBit s = LeaveCC, Condition cond = al);
|
870
|
-
|
871
|
-
// Jump unconditionally to given label.
|
872
|
-
void jmp(Label* L) { b(L, al); }
|
873
|
-
|
874
|
-
// Check the code size generated from label to here.
|
875
|
-
int InstructionsGeneratedSince(Label* l) {
|
876
|
-
return (pc_offset() - l->pos()) / kInstrSize;
|
877
|
-
}
|
878
|
-
|
879
|
-
// Check whether an immediate fits an addressing mode 1 instruction.
|
880
|
-
bool ImmediateFitsAddrMode1Instruction(int32_t imm32);
|
881
|
-
|
882
|
-
// Postpone the generation of the constant pool for the specified number of
|
883
|
-
// instructions.
|
884
|
-
void BlockConstPoolFor(int instructions);
|
885
|
-
|
886
|
-
// Debugging
|
887
|
-
|
888
|
-
// Mark address of the ExitJSFrame code.
|
889
|
-
void RecordJSReturn();
|
890
|
-
|
891
|
-
// Record a comment relocation entry that can be used by a disassembler.
|
892
|
-
// Use --debug_code to enable.
|
893
|
-
void RecordComment(const char* msg);
|
894
|
-
|
895
|
-
void RecordPosition(int pos);
|
896
|
-
void RecordStatementPosition(int pos);
|
897
|
-
void WriteRecordedPositions();
|
898
|
-
|
899
|
-
int pc_offset() const { return pc_ - buffer_; }
|
900
|
-
int current_position() const { return current_position_; }
|
901
|
-
int current_statement_position() const { return current_statement_position_; }
|
902
|
-
|
903
|
-
protected:
|
904
|
-
int buffer_space() const { return reloc_info_writer.pos() - pc_; }
|
905
|
-
|
906
|
-
// Read/patch instructions
|
907
|
-
static Instr instr_at(byte* pc) { return *reinterpret_cast<Instr*>(pc); }
|
908
|
-
void instr_at_put(byte* pc, Instr instr) {
|
909
|
-
*reinterpret_cast<Instr*>(pc) = instr;
|
910
|
-
}
|
911
|
-
Instr instr_at(int pos) { return *reinterpret_cast<Instr*>(buffer_ + pos); }
|
912
|
-
void instr_at_put(int pos, Instr instr) {
|
913
|
-
*reinterpret_cast<Instr*>(buffer_ + pos) = instr;
|
914
|
-
}
|
915
|
-
|
916
|
-
// Decode branch instruction at pos and return branch target pos
|
917
|
-
int target_at(int pos);
|
918
|
-
|
919
|
-
// Patch branch instruction at pos to branch to given branch target pos
|
920
|
-
void target_at_put(int pos, int target_pos);
|
921
|
-
|
922
|
-
// Check if is time to emit a constant pool for pending reloc info entries
|
923
|
-
void CheckConstPool(bool force_emit, bool require_jump);
|
924
|
-
|
925
|
-
// Block the emission of the constant pool before pc_offset
|
926
|
-
void BlockConstPoolBefore(int pc_offset) {
|
927
|
-
if (no_const_pool_before_ < pc_offset) no_const_pool_before_ = pc_offset;
|
928
|
-
}
|
929
|
-
|
930
|
-
private:
|
931
|
-
// Code buffer:
|
932
|
-
// The buffer into which code and relocation info are generated.
|
933
|
-
byte* buffer_;
|
934
|
-
int buffer_size_;
|
935
|
-
// True if the assembler owns the buffer, false if buffer is external.
|
936
|
-
bool own_buffer_;
|
937
|
-
|
938
|
-
// Buffer size and constant pool distance are checked together at regular
|
939
|
-
// intervals of kBufferCheckInterval emitted bytes
|
940
|
-
static const int kBufferCheckInterval = 1*KB/2;
|
941
|
-
int next_buffer_check_; // pc offset of next buffer check
|
942
|
-
|
943
|
-
// Code generation
|
944
|
-
// The relocation writer's position is at least kGap bytes below the end of
|
945
|
-
// the generated instructions. This is so that multi-instruction sequences do
|
946
|
-
// not have to check for overflow. The same is true for writes of large
|
947
|
-
// relocation info entries.
|
948
|
-
static const int kGap = 32;
|
949
|
-
byte* pc_; // the program counter; moves forward
|
950
|
-
|
951
|
-
// Constant pool generation
|
952
|
-
// Pools are emitted in the instruction stream, preferably after unconditional
|
953
|
-
// jumps or after returns from functions (in dead code locations).
|
954
|
-
// If a long code sequence does not contain unconditional jumps, it is
|
955
|
-
// necessary to emit the constant pool before the pool gets too far from the
|
956
|
-
// location it is accessed from. In this case, we emit a jump over the emitted
|
957
|
-
// constant pool.
|
958
|
-
// Constants in the pool may be addresses of functions that gets relocated;
|
959
|
-
// if so, a relocation info entry is associated to the constant pool entry.
|
960
|
-
|
961
|
-
// Repeated checking whether the constant pool should be emitted is rather
|
962
|
-
// expensive. By default we only check again once a number of instructions
|
963
|
-
// has been generated. That also means that the sizing of the buffers is not
|
964
|
-
// an exact science, and that we rely on some slop to not overrun buffers.
|
965
|
-
static const int kCheckConstIntervalInst = 32;
|
966
|
-
static const int kCheckConstInterval = kCheckConstIntervalInst * kInstrSize;
|
967
|
-
|
968
|
-
|
969
|
-
// Pools are emitted after function return and in dead code at (more or less)
|
970
|
-
// regular intervals of kDistBetweenPools bytes
|
971
|
-
static const int kDistBetweenPools = 1*KB;
|
972
|
-
|
973
|
-
// Constants in pools are accessed via pc relative addressing, which can
|
974
|
-
// reach +/-4KB thereby defining a maximum distance between the instruction
|
975
|
-
// and the accessed constant. We satisfy this constraint by limiting the
|
976
|
-
// distance between pools.
|
977
|
-
static const int kMaxDistBetweenPools = 4*KB - 2*kBufferCheckInterval;
|
978
|
-
|
979
|
-
// Emission of the constant pool may be blocked in some code sequences
|
980
|
-
int no_const_pool_before_; // block emission before this pc offset
|
981
|
-
|
982
|
-
// Keep track of the last emitted pool to guarantee a maximal distance
|
983
|
-
int last_const_pool_end_; // pc offset following the last constant pool
|
984
|
-
|
985
|
-
// Relocation info generation
|
986
|
-
// Each relocation is encoded as a variable size value
|
987
|
-
static const int kMaxRelocSize = RelocInfoWriter::kMaxSize;
|
988
|
-
RelocInfoWriter reloc_info_writer;
|
989
|
-
// Relocation info records are also used during code generation as temporary
|
990
|
-
// containers for constants and code target addresses until they are emitted
|
991
|
-
// to the constant pool. These pending relocation info records are temporarily
|
992
|
-
// stored in a separate buffer until a constant pool is emitted.
|
993
|
-
// If every instruction in a long sequence is accessing the pool, we need one
|
994
|
-
// pending relocation entry per instruction.
|
995
|
-
static const int kMaxNumPRInfo = kMaxDistBetweenPools/kInstrSize;
|
996
|
-
RelocInfo prinfo_[kMaxNumPRInfo]; // the buffer of pending relocation info
|
997
|
-
int num_prinfo_; // number of pending reloc info entries in the buffer
|
998
|
-
|
999
|
-
// The bound position, before this we cannot do instruction elimination.
|
1000
|
-
int last_bound_pos_;
|
1001
|
-
|
1002
|
-
// source position information
|
1003
|
-
int current_position_;
|
1004
|
-
int current_statement_position_;
|
1005
|
-
int written_position_;
|
1006
|
-
int written_statement_position_;
|
1007
|
-
|
1008
|
-
// Code emission
|
1009
|
-
inline void CheckBuffer();
|
1010
|
-
void GrowBuffer();
|
1011
|
-
inline void emit(Instr x);
|
1012
|
-
|
1013
|
-
// Instruction generation
|
1014
|
-
void addrmod1(Instr instr, Register rn, Register rd, const Operand& x);
|
1015
|
-
void addrmod2(Instr instr, Register rd, const MemOperand& x);
|
1016
|
-
void addrmod3(Instr instr, Register rd, const MemOperand& x);
|
1017
|
-
void addrmod4(Instr instr, Register rn, RegList rl);
|
1018
|
-
void addrmod5(Instr instr, CRegister crd, const MemOperand& x);
|
1019
|
-
|
1020
|
-
// Labels
|
1021
|
-
void print(Label* L);
|
1022
|
-
void bind_to(Label* L, int pos);
|
1023
|
-
void link_to(Label* L, Label* appendix);
|
1024
|
-
void next(Label* L);
|
1025
|
-
|
1026
|
-
// Record reloc info for current pc_
|
1027
|
-
void RecordRelocInfo(RelocInfo::Mode rmode, intptr_t data = 0);
|
1028
|
-
|
1029
|
-
friend class RegExpMacroAssemblerARM;
|
1030
|
-
friend class RelocInfo;
|
1031
|
-
friend class CodePatcher;
|
1032
|
-
};
|
1033
|
-
|
1034
|
-
} } // namespace v8::internal
|
1035
|
-
|
1036
|
-
#endif // V8_ARM_ASSEMBLER_THUMB2_H_
|