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

Issue 10454049: Validate that all instructions dominate their inputs. And fix a bug where that did not happen. (Closed)

Created:
8 years, 6 months ago by ngeoffray
Modified:
8 years, 6 months ago
CC:
reviews_dartlang.org, karlklose, ahe, floitsch
Visibility:
Public.

Description

Validate that all instructions dominate their inputs. And fix a bug where that did not happen. Committed: https://code.google.com/p/dart/source/detail?r=8089

Patch Set 1 : #

Total comments: 4

Patch Set 2 : #

Total comments: 16
Unified diffs Side-by-side diffs Delta from patch set Stats (+71 lines, -23 lines) Patch
M lib/compiler/implementation/ssa/builder.dart View 1 6 chunks +25 lines, -11 lines 6 comments Download
M lib/compiler/implementation/ssa/closure.dart View 1 1 chunk +2 lines, -1 line 2 comments Download
M lib/compiler/implementation/ssa/codegen.dart View 1 1 chunk +1 line, -1 line 0 comments Download
M lib/compiler/implementation/ssa/nodes.dart View 1 2 chunks +9 lines, -0 lines 2 comments Download
M lib/compiler/implementation/ssa/tracer.dart View 1 3 chunks +10 lines, -10 lines 2 comments Download
M lib/compiler/implementation/ssa/validate.dart View 1 1 chunk +22 lines, -0 lines 4 comments Download
M lib/compiler/implementation/unparse_validator.dart View 1 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
ngeoffray
8 years, 6 months ago (2012-05-29 14:23:58 UTC) #1
floitsch
Please add a test case. Helps to figure out what went wrong.
8 years, 6 months ago (2012-05-29 14:50:45 UTC) #2
ngeoffray
I didn't add a new test, because our existing tests with try/catch/finally are failing the ...
8 years, 6 months ago (2012-05-29 14:52:40 UTC) #3
floitsch
L mostly GTM. There is still one part (getActivationValue) I haven't figured out yet, but ...
8 years, 6 months ago (2012-05-29 18:31:37 UTC) #4
ngeoffray
Thanks Florian https://chromiumcodereview.appspot.com/10454049/diff/4008/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/4008/lib/compiler/implementation/ssa/builder.dart#newcode440 lib/compiler/implementation/ssa/builder.dart:440: if (element.isParameter()) return directLocals[element]; On 2012/05/29 18:31:38, ...
8 years, 6 months ago (2012-05-30 08:31:45 UTC) #5
Lasse Reichstein Nielsen
LGTM https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart#newcode3126 lib/compiler/implementation/ssa/builder.dart:3126: // variables. This will make it look as ...
8 years, 6 months ago (2012-05-30 09:35:14 UTC) #6
ngeoffray
Thanks Lasse! New CL for addressing the comments: https://chromiumcodereview.appspot.com/10446080 https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart#newcode3126 lib/compiler/implementation/ssa/builder.dart:3126: ...
8 years, 6 months ago (2012-05-30 10:19:06 UTC) #7
floitsch
https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart#newcode440 lib/compiler/implementation/ssa/builder.dart:440: // If the element is a parameter, we already ...
8 years, 6 months ago (2012-05-30 11:52:38 UTC) #8
ngeoffray
https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart#newcode440 lib/compiler/implementation/ssa/builder.dart:440: // If the element is a parameter, we already ...
8 years, 6 months ago (2012-05-30 12:37:26 UTC) #9
floitsch
https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart File lib/compiler/implementation/ssa/builder.dart (right): https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implementation/ssa/builder.dart#newcode440 lib/compiler/implementation/ssa/builder.dart:440: // If the element is a parameter, we already ...
8 years, 6 months ago (2012-05-30 12:59:40 UTC) #10
ngeoffray
8 years, 6 months ago (2012-05-31 08:18:33 UTC) #11
https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implem...
File lib/compiler/implementation/ssa/builder.dart (right):

https://chromiumcodereview.appspot.com/10454049/diff/9001/lib/compiler/implem...
lib/compiler/implementation/ssa/builder.dart:440: // If the element is a
parameter, we already have a
On 2012/05/30 12:59:41, floitsch wrote:
> On 2012/05/30 12:37:26, ngeoffray wrote:
> > On 2012/05/30 11:52:38, floitsch wrote:
> > > Can you also add a comment, why we have this 'if'?
> > > Unless I'm wrong this is an optimization to avoid redundant assignments.
> > > Correct?
> > 
> > There is a comment:
> > If the element is a parameter, we already have a HParameterValue for it.
> > 
> > It's just to avoid adding unnecessary new HParameterValue. So I'm not sure
> what
> > you think is missing from the comment?
> 
> If I'm not wrong this is just to avoid wrapping parameters. Removing this line
> would not change anything.
> So what I would like to see (as comment): is this necessary, or just an
> optimization.

It is necessary because we need to share the same name between the
HParameterValue (real parameter) and the HFieldGet and HFieldSet instructions.
I'll add that as a comment.

Powered by Google App Engine
This is Rietveld 408576698