Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Issue 22825023: Uses an object pool on x64 (Closed)

Created:
7 years, 4 months ago by zra
Modified:
7 years, 3 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Sets a register aside on x64 for use as a pool-pointer. It is loaded and restored from the code object on Frame entry and exit. All LoadObject calls that can, and many calls and jumps through ExternalLabels now use the pool-pointer. The --compiler-stats flag when running dart2js indicates that code size is reduced ~13%, and more is probably possible. R=fschneider@google.com, srdjan@google.com Committed: https://code.google.com/p/dart/source/detail?r=27295

Patch Set 1 #

Patch Set 2 : #

Total comments: 3

Patch Set 3 : #

Patch Set 4 : #

Patch Set 5 : #

Patch Set 6 : #

Patch Set 7 : #

Patch Set 8 : #

Total comments: 34

Patch Set 9 : #

Total comments: 26

Patch Set 10 : #

Total comments: 44

Patch Set 11 : #

Total comments: 24

Patch Set 12 : #

Patch Set 13 : #

Total comments: 1

Patch Set 14 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1030 lines, -558 lines) Patch
M runtime/tests/vm/vm.status View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -0 lines 0 comments Download
M runtime/vm/assembler_x64.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 11 chunks +57 lines, -13 lines 0 comments Download
M runtime/vm/assembler_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +269 lines, -60 lines 0 comments Download
M runtime/vm/assembler_x64_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +30 lines, -3 lines 0 comments Download
M runtime/vm/code_patcher.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +5 lines, -5 lines 0 comments Download
M runtime/vm/code_patcher_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +60 lines, -48 lines 0 comments Download
M runtime/vm/code_patcher_x64_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -2 lines 0 comments Download
M runtime/vm/constants_x64.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -2 lines 0 comments Download
M runtime/vm/debugger_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +17 lines, -23 lines 0 comments Download
M runtime/vm/find_code_object_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/flow_graph_compiler.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +0 lines, -42 lines 0 comments Download
M runtime/vm/flow_graph_compiler_arm.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +41 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_compiler_ia32.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +41 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_compiler_mips.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +41 lines, -0 lines 0 comments Download
M runtime/vm/flow_graph_compiler_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 43 chunks +159 lines, -84 lines 0 comments Download
M runtime/vm/instructions_arm.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/instructions_arm.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/instructions_arm_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -2 lines 0 comments Download
M runtime/vm/instructions_ia32.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -1 line 0 comments Download
M runtime/vm/instructions_ia32_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -2 lines 0 comments Download
M runtime/vm/instructions_mips.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/instructions_mips.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/instructions_mips_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -2 lines 0 comments Download
M runtime/vm/instructions_x64.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +22 lines, -18 lines 0 comments Download
M runtime/vm/instructions_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +28 lines, -5 lines 0 comments Download
M runtime/vm/instructions_x64_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +8 lines, -5 lines 0 comments Download
M runtime/vm/intermediate_language_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 31 chunks +55 lines, -73 lines 0 comments Download
M runtime/vm/intrinsifier_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +41 lines, -30 lines 0 comments Download
M runtime/vm/object_x64_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +4 lines, -2 lines 0 comments Download
M runtime/vm/runtime_entry_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -1 line 0 comments Download
M runtime/vm/stack_frame_x64.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +11 lines, -7 lines 0 comments Download
M runtime/vm/stub_code.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -1 line 0 comments Download
M runtime/vm/stub_code_x64.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 57 chunks +109 lines, -117 lines 0 comments Download
M runtime/vm/stub_code_x64_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +5 lines, -5 lines 0 comments Download

Messages

Total messages: 16 (0 generated)
Ivan Posva
https://codereview.chromium.org/22825023/diff/11001/runtime/vm/assembler_x64.cc File runtime/vm/assembler_x64.cc (right): https://codereview.chromium.org/22825023/diff/11001/runtime/vm/assembler_x64.cc#newcode2352 runtime/vm/assembler_x64.cc:2352: leaq(RSP, Address(RBP, -2 * kWordSize)); // Restore stack pointer. ...
7 years, 4 months ago (2013-08-22 05:26:25 UTC) #1
zra
7 years, 3 months ago (2013-08-27 18:29:17 UTC) #2
Ivan Posva
Florian, Could you please take a look at this? Thanks, -Ivan
7 years, 3 months ago (2013-09-03 17:31:32 UTC) #3
Florian Schneider
First round of comments. https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc File runtime/vm/assembler_x64.cc (right): https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc#newcode173 runtime/vm/assembler_x64.cc:173: LoadExternalLabel(label, kNotPatchable); This assumes LoadExternalLabel ...
7 years, 3 months ago (2013-09-04 09:39:47 UTC) #4
zra
Thanks. PTAL https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc File runtime/vm/assembler_x64.cc (right): https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc#newcode173 runtime/vm/assembler_x64.cc:173: LoadExternalLabel(label, kNotPatchable); On 2013/09/04 09:39:47, Florian Schneider ...
7 years, 3 months ago (2013-09-04 21:00:40 UTC) #5
srdjan
For next CL suggesting to use fixed addresses for null, true and false, instead of ...
7 years, 3 months ago (2013-09-04 22:57:22 UTC) #6
zra
https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc File runtime/vm/assembler_x64.cc (right): https://codereview.chromium.org/22825023/diff/68001/runtime/vm/assembler_x64.cc#newcode2260 runtime/vm/assembler_x64.cc:2260: if (Utils::IsInt(8, offset) && (patchable == kPatchable)) { On ...
7 years, 3 months ago (2013-09-05 00:23:11 UTC) #7
Florian Schneider
Looking already much better! Here is another round of comments: Mostly I tried to make ...
7 years, 3 months ago (2013-09-05 10:57:45 UTC) #8
zra
Forgot to mention earlier that going with a fixed-size imm32 offset on the load from ...
7 years, 3 months ago (2013-09-05 20:29:25 UTC) #9
Florian Schneider
https://codereview.chromium.org/22825023/diff/99001/runtime/vm/assembler_x64.h File runtime/vm/assembler_x64.h (right): https://codereview.chromium.org/22825023/diff/99001/runtime/vm/assembler_x64.h#newcode663 runtime/vm/assembler_x64.h:663: void LoadObjectFromPool(Register dst, const Object& obj, Register pp); On ...
7 years, 3 months ago (2013-09-06 09:58:15 UTC) #10
srdjan
LGTM after addressing Florian's comments.
7 years, 3 months ago (2013-09-06 15:55:51 UTC) #11
srdjan
https://codereview.chromium.org/22825023/diff/110001/runtime/vm/assembler_x64.cc File runtime/vm/assembler_x64.cc (right): https://codereview.chromium.org/22825023/diff/110001/runtime/vm/assembler_x64.cc#newcode2217 runtime/vm/assembler_x64.cc:2217: Patchability patchable) { fix indent https://codereview.chromium.org/22825023/diff/110001/runtime/vm/assembler_x64.cc#newcode2235 runtime/vm/assembler_x64.cc:2235: } Could ...
7 years, 3 months ago (2013-09-06 16:22:44 UTC) #12
zra
https://codereview.chromium.org/22825023/diff/99001/runtime/vm/assembler_x64.h File runtime/vm/assembler_x64.h (right): https://codereview.chromium.org/22825023/diff/99001/runtime/vm/assembler_x64.h#newcode663 runtime/vm/assembler_x64.h:663: void LoadObjectFromPool(Register dst, const Object& obj, Register pp); On ...
7 years, 3 months ago (2013-09-06 17:53:25 UTC) #13
Florian Schneider
LGTM. https://codereview.chromium.org/22825023/diff/141001/runtime/vm/debugger_x64.cc File runtime/vm/debugger_x64.cc (right): https://codereview.chromium.org/22825023/diff/141001/runtime/vm/debugger_x64.cc#newcode70 runtime/vm/debugger_x64.cc:70: MemoryRegion code_region(reinterpret_cast<void*>(pc_ - 13), 13); MemoryRegion code_region(reinterpret_cast<void*>(code), 13); ...
7 years, 3 months ago (2013-09-09 09:55:59 UTC) #14
zra
Thanks!
7 years, 3 months ago (2013-09-09 15:38:25 UTC) #15
zra
7 years, 3 months ago (2013-09-09 15:39:41 UTC) #16
Message was sent while issue was closed.
Committed patchset #14 manually as r27295 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698