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

Issue 1691193002: Subzero: Prototype to make use of RegNumT::No Register more concise (Closed)

Created:
4 years, 10 months ago by rkotlerimgtec
Modified:
4 years, 10 months ago
CC:
native-client-reviews_googlegroups.com, rich.fuhler_imgtec.com
Base URL:
https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Subzero: Avoid explicit references to RegNumT sentinel value. There are many occurrences of if (RegNum == RegNumT::NoRegister). This patch eliminates NoRegister and provides a simpler mechanism for declaring and testing RegNumT values to see if they are undefined. BUG= none R=stichnot@chromium.org Committed: https://gerrit.chromium.org/gerrit/gitweb?p=native_client/pnacl-subzero.git;a=commit;h=5fa0a5f7f730f33e6987527a261de8d833d7585c

Patch Set 1 #

Total comments: 2

Patch Set 2 : changes suggested by stichnot #

Total comments: 1

Patch Set 3 : changes suggested by stichnot #

Patch Set 4 : changes suggested by stichnot #

Patch Set 5 : changes suggested by stichnot #

Total comments: 14

Patch Set 6 : changes suggested by stichnot #

Patch Set 7 : changes suggested by stichnot #

Patch Set 8 : remove NoRegister #

Patch Set 9 : One more place with hasNoValue changed #

Patch Set 10 : get rid of unneccessary initialization. #

Total comments: 8

Patch Set 11 : changes suggested by stichnot #

Unified diffs Side-by-side diffs Delta from patch set Stats (+99 lines, -105 lines) Patch
M src/IceInstARM32.h View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M src/IceInstX86BaseImpl.h View 1 2 3 4 5 6 7 2 chunks +2 lines, -3 lines 0 comments Download
M src/IceOperand.h View 1 2 3 4 5 6 7 8 9 10 6 chunks +16 lines, -15 lines 0 comments Download
M src/IceOperand.cpp View 1 2 3 4 5 6 7 2 chunks +1 line, -2 lines 0 comments Download
M src/IceRegAlloc.h View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M src/IceRegAlloc.cpp View 1 2 3 4 5 6 7 3 chunks +3 lines, -3 lines 0 comments Download
M src/IceRegistersARM32.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M src/IceTargetLoweringARM32.h View 1 2 3 4 5 6 7 2 chunks +7 lines, -7 lines 0 comments Download
M src/IceTargetLoweringARM32.cpp View 1 2 3 4 5 6 4 chunks +7 lines, -7 lines 0 comments Download
M src/IceTargetLoweringMIPS32.h View 1 2 3 4 5 6 7 2 chunks +6 lines, -6 lines 0 comments Download
M src/IceTargetLoweringMIPS32.cpp View 1 2 3 4 5 3 chunks +7 lines, -7 lines 0 comments Download
M src/IceTargetLoweringX8632Traits.h View 1 2 3 4 5 6 7 3 chunks +3 lines, -3 lines 0 comments Download
M src/IceTargetLoweringX8664.cpp View 1 2 3 4 5 6 7 1 chunk +1 line, -2 lines 0 comments Download
M src/IceTargetLoweringX8664Traits.h View 1 2 3 4 5 6 7 2 chunks +3 lines, -3 lines 0 comments Download
M src/IceTargetLoweringX86Base.h View 1 2 3 4 5 6 7 6 chunks +15 lines, -17 lines 0 comments Download
M src/IceTargetLoweringX86BaseImpl.h View 1 2 3 4 5 6 7 8 14 chunks +25 lines, -27 lines 0 comments Download

Messages

Total messages: 29 (5 generated)
Jim Stichnoth
https://codereview.chromium.org/1691193002/diff/1/src/IceOperand.h File src/IceOperand.h (right): https://codereview.chromium.org/1691193002/diff/1/src/IceOperand.h#newcode446 src/IceOperand.h:446: bool noRegister() {return Value == NoRegisterValue;} This seems OK. ...
4 years, 10 months ago (2016-02-12 02:20:15 UTC) #3
rkotlerimgtec
How do we want to handle making the related usage changes? Do you want me ...
4 years, 10 months ago (2016-02-12 03:00:16 UTC) #4
Jim Stichnoth
Please make the changes everywhere, not just the mips code, and be sure to check ...
4 years, 10 months ago (2016-02-12 03:16:52 UTC) #5
rkotlerimgtec
I will make the appropriate code change != for hasValue Do we want to make ...
4 years, 10 months ago (2016-02-12 03:22:50 UTC) #6
rkotlerimgtec
How about hasNoValue ? Otherwise everywhere we will be checking !Reg.hasValue where now we have ...
4 years, 10 months ago (2016-02-12 03:24:53 UTC) #7
rkotlerimgtec
4 years, 10 months ago (2016-02-12 03:27:06 UTC) #8
rkotlerimgtec
I kind of like to have the pair hasValue and hasNoValue
4 years, 10 months ago (2016-02-12 03:34:11 UTC) #9
Jim Stichnoth
On 2016/02/12 03:22:50, rkotlerimgtec wrote: > I will make the appropriate code change != for ...
4 years, 10 months ago (2016-02-12 03:38:36 UTC) #10
rkotlerimgtec
Ok. I will separate out the two changes internally. If there are no more uses ...
4 years, 10 months ago (2016-02-12 03:41:19 UTC) #11
rkotlerimgtec
I decided to do the changes in several commits; this first being to add the ...
4 years, 10 months ago (2016-02-12 05:17:17 UTC) #12
Jim Stichnoth
https://codereview.chromium.org/1691193002/diff/80001/src/IceOperand.cpp File src/IceOperand.cpp (right): https://codereview.chromium.org/1691193002/diff/80001/src/IceOperand.cpp#newcode204 src/IceOperand.cpp:204: V->RegNum = NewRegNum.hasNoValue() ? RegNum : NewRegNum; NewRegNum.hasValue() ? ...
4 years, 10 months ago (2016-02-12 18:29:54 UTC) #13
rkotlerimgtec
https://codereview.chromium.org/1691193002/diff/80001/src/IceOperand.cpp File src/IceOperand.cpp (right): https://codereview.chromium.org/1691193002/diff/80001/src/IceOperand.cpp#newcode204 src/IceOperand.cpp:204: V->RegNum = NewRegNum.hasNoValue() ? RegNum : NewRegNum; On 2016/02/12 ...
4 years, 10 months ago (2016-02-12 22:02:01 UTC) #14
Jim Stichnoth
Were you planning to do the other part in this CL, or a separate CL? ...
4 years, 10 months ago (2016-02-12 23:14:24 UTC) #15
rkotlerimgtec
https://codereview.chromium.org/1691193002/diff/80001/src/IceTargetLoweringARM32.cpp File src/IceTargetLoweringARM32.cpp (right): https://codereview.chromium.org/1691193002/diff/80001/src/IceTargetLoweringARM32.cpp#newcode6090 src/IceTargetLoweringARM32.cpp:6090: if (RegNum.hasNoValue()) On 2016/02/12 18:29:54, stichnot wrote: > if ...
4 years, 10 months ago (2016-02-13 00:56:53 UTC) #16
rkotlerimgtec
4 years, 10 months ago (2016-02-13 00:57:49 UTC) #17
rkotlerimgtec
On 2016/02/12 23:14:24, stichnot wrote: > Were you planning to do the other part in ...
4 years, 10 months ago (2016-02-13 00:59:13 UTC) #18
rkotlerimgtec
On 2016/02/13 00:59:13, rkotlerimgtec wrote: > On 2016/02/12 23:14:24, stichnot wrote: > > Were you ...
4 years, 10 months ago (2016-02-13 01:07:13 UTC) #20
rkotlerimgtec
Seems to be okay. On Fri, Feb 12, 2016 at 5:07 PM, <rkotlerimgtec@gmail.com> wrote: > ...
4 years, 10 months ago (2016-02-13 01:08:32 UTC) #21
rkotlerimgtec
4 years, 10 months ago (2016-02-13 01:14:04 UTC) #22
rkotlerimgtec
4 years, 10 months ago (2016-02-13 04:02:37 UTC) #23
Jim Stichnoth
Thanks! Just a few more comment corrections... https://codereview.chromium.org/1691193002/diff/180001/src/IceOperand.h File src/IceOperand.h (right): https://codereview.chromium.org/1691193002/diff/180001/src/IceOperand.h#newcode406 src/IceOperand.h:406: /// value ...
4 years, 10 months ago (2016-02-13 18:58:10 UTC) #24
rkotlerimgtec
https://codereview.chromium.org/1691193002/diff/180001/src/IceOperand.h File src/IceOperand.h (right): https://codereview.chromium.org/1691193002/diff/180001/src/IceOperand.h#newcode406 src/IceOperand.h:406: /// value NoRegister. Its public ctor allows direct use ...
4 years, 10 months ago (2016-02-14 00:04:05 UTC) #26
Jim Stichnoth
LGTM. Sorry for the delay.
4 years, 10 months ago (2016-02-16 03:40:41 UTC) #27
Jim Stichnoth
4 years, 10 months ago (2016-02-16 04:01:43 UTC) #29
Message was sent while issue was closed.
Committed patchset #11 (id:200001) manually as
5fa0a5f7f730f33e6987527a261de8d833d7585c (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698