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

Issue 1159013002: Subzero ARM: addProlog/addEpilogue -- share some code with x86. (Closed)

Created:
5 years, 7 months ago by jvoung (off chromium)
Modified:
5 years, 6 months ago
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Subzero ARM: addProlog/addEpilogue -- share some code with x86. Split out some of the addProlog code from x86 and reuse that for ARM. Mainly, the code that doesn't concern preserved registers or stack arguments is split out. ARM push and pop take a whole list of registers (not necessarily consecutive, but should be in ascending order). There is also "vpush" for callee-saved float/vector registers but we do not handle that yet (the register numbers for that have to be consecutive). Enable some of the int-arg.ll tests, which relied on addPrologue's finishArgumentLowering to pull from the correct argument stack slot. Test some of the frame pointer usage (push/pop) when handling a variable sized alloca. Also change the classification of LR, and PC so that they are not "CalleeSave". We don't want to push LR if it isn't overwritten by another call. It will certainly be "used" by the return however. The prologue code only checks if a CalleeSave register is used somewhere before deciding to preserve it. We could make that stricter and check if the register is also written to, but there are some additional writes that are not visible till after the push/pop are generated (e.g., copy from argument stack slot to the argument register). Instead, keep checking use only, and handle LR as a special case (IsLeafFunction). BUG= https://code.google.com/p/nativeclient/issues/detail?id=4076 R=stichnot@chromium.org Committed: https://gerrit.chromium.org/gerrit/gitweb?p=native_client/pnacl-subzero.git;a=commit;h=0fa6c5a062f465360448a672abed3b916b413ca8

Patch Set 1 #

Patch Set 2 : checkpoint some stuff #

Patch Set 3 : get argument stack slots for int-arg.ll test #

Patch Set 4 : addEpilogue too #

Patch Set 5 : clang-format and add comment #

Total comments: 1

Patch Set 6 : share align -- bleh #

Patch Set 7 : rename field #

Total comments: 4

Patch Set 8 : use std::sort #

Patch Set 9 : typo #

Unified diffs Side-by-side diffs Delta from patch set Stats (+782 lines, -217 lines) Patch
M src/IceInstARM32.h View 1 2 3 4 3 chunks +53 lines, -1 line 0 comments Download
M src/IceInstARM32.cpp View 1 2 3 4 5 6 7 3 chunks +75 lines, -1 line 0 comments Download
M src/IceInstARM32.def View 1 2 3 4 5 6 7 8 2 chunks +8 lines, -3 lines 0 comments Download
M src/IceTargetLowering.h View 1 2 3 4 5 6 7 2 chunks +57 lines, -0 lines 0 comments Download
M src/IceTargetLowering.cpp View 1 2 3 4 5 6 7 1 chunk +153 lines, -0 lines 0 comments Download
M src/IceTargetLoweringARM32.h View 1 2 3 4 5 6 7 4 chunks +14 lines, -0 lines 0 comments Download
M src/IceTargetLoweringARM32.cpp View 1 2 3 4 5 6 5 chunks +353 lines, -16 lines 0 comments Download
M src/IceTargetLoweringX8632.h View 1 2 3 4 5 6 7 4 chunks +3 lines, -9 lines 0 comments Download
M src/IceTargetLoweringX8632.cpp View 1 2 3 4 5 6 7 7 chunks +41 lines, -163 lines 0 comments Download
M tests_lit/llvm2ice_tests/alloc.ll View 1 2 3 4 2 chunks +8 lines, -0 lines 0 comments Download
M tests_lit/llvm2ice_tests/branch-opt.ll View 1 2 3 2 chunks +6 lines, -6 lines 0 comments Download
M tests_lit/llvm2ice_tests/int-arg.ll View 1 2 7 chunks +11 lines, -18 lines 0 comments Download

Messages

Total messages: 5 (1 generated)
jvoung (off chromium)
https://codereview.chromium.org/1159013002/diff/80001/tests_lit/llvm2ice_tests/branch-opt.ll File tests_lit/llvm2ice_tests/branch-opt.ll (left): https://codereview.chromium.org/1159013002/diff/80001/tests_lit/llvm2ice_tests/branch-opt.ll#oldcode96 tests_lit/llvm2ice_tests/branch-opt.ll:96: ; ARM32O2-NEXT: bx lr there's some popping now so ...
5 years, 6 months ago (2015-05-29 15:34:44 UTC) #2
Jim Stichnoth
otherwise lgtm https://codereview.chromium.org/1159013002/diff/110001/src/IceInstARM32.cpp File src/IceInstARM32.cpp (right): https://codereview.chromium.org/1159013002/diff/110001/src/IceInstARM32.cpp#newcode265 src/IceInstARM32.cpp:265: // We only track the first Dest ...
5 years, 6 months ago (2015-05-30 16:58:55 UTC) #3
jvoung (off chromium)
https://codereview.chromium.org/1159013002/diff/110001/src/IceInstARM32.cpp File src/IceInstARM32.cpp (right): https://codereview.chromium.org/1159013002/diff/110001/src/IceInstARM32.cpp#newcode265 src/IceInstARM32.cpp:265: // We only track the first Dest directly. Other ...
5 years, 6 months ago (2015-06-01 18:00:23 UTC) #4
jvoung (off chromium)
5 years, 6 months ago (2015-06-01 18:04:12 UTC) #5
Message was sent while issue was closed.
Committed patchset #9 (id:150001) manually as
0fa6c5a062f465360448a672abed3b916b413ca8 (tree was closed).

Powered by Google App Engine
This is Rietveld 408576698