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

Issue 10383065: Start creating a MemberSet abstraction, and use it to fold getters/setters into field accesses. (Closed)

Created:
8 years, 7 months ago by ngeoffray
Modified:
8 years, 7 months ago
Reviewers:
ahe, kasperl
CC:
reviews_dartlang.org, floitsch, karlklose, Lasse Reichstein Nielsen
Visibility:
Public.

Description

Start creating a MemberSet abstraction, and use it to fold getters/setters into field accesses. Committed: https://code.google.com/p/dart/source/detail?r=7451

Patch Set 1 : #

Total comments: 4

Patch Set 2 : #

Total comments: 6

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+130 lines, -27 lines) Patch
M lib/compiler/implementation/compiler.dart View 1 2 3 chunks +5 lines, -1 line 0 comments Download
M lib/compiler/implementation/leg.dart View 1 1 chunk +1 line, -0 lines 0 comments Download
M lib/compiler/implementation/ssa/builder.dart View 1 4 chunks +6 lines, -6 lines 0 comments Download
M lib/compiler/implementation/ssa/codegen.dart View 1 3 chunks +4 lines, -4 lines 0 comments Download
M lib/compiler/implementation/ssa/nodes.dart View 1 1 chunk +14 lines, -6 lines 0 comments Download
M lib/compiler/implementation/ssa/optimize.dart View 1 2 1 chunk +18 lines, -0 lines 0 comments Download
M lib/compiler/implementation/ssa/tracer.dart View 1 1 chunk +2 lines, -2 lines 0 comments Download
M lib/compiler/implementation/universe.dart View 1 1 chunk +1 line, -1 line 0 comments Download
A lib/compiler/implementation/world.dart View 1 2 1 chunk +77 lines, -0 lines 0 comments Download
M tests/co19/co19-leg.status View 1 1 chunk +0 lines, -1 line 0 comments Download
M tests/language/language.status View 1 4 chunks +2 lines, -6 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
ngeoffray
8 years, 7 months ago (2012-05-08 15:25:41 UTC) #1
kasperl
LGTM, but I'd like to have you discuss the member set stuff you added to ...
8 years, 7 months ago (2012-05-09 08:04:23 UTC) #2
ngeoffray
Thank you Kasper. PTAL https://chromiumcodereview.appspot.com/10383065/diff/4001/lib/compiler/implementation/ssa/nodes.dart File lib/compiler/implementation/ssa/nodes.dart (right): https://chromiumcodereview.appspot.com/10383065/diff/4001/lib/compiler/implementation/ssa/nodes.dart#newcode1233 lib/compiler/implementation/ssa/nodes.dart:1233: HFieldSet.fromActivation(SourceString this.name, HInstruction value) On ...
8 years, 7 months ago (2012-05-09 10:07:57 UTC) #3
kasperl
LGTM! https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implementation/compiler.dart File lib/compiler/implementation/compiler.dart (right): https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implementation/compiler.dart#newcode305 lib/compiler/implementation/compiler.dart:305: computeSubclasses(); Could we move this code to world? ...
8 years, 7 months ago (2012-05-09 11:13:03 UTC) #4
ngeoffray
8 years, 7 months ago (2012-05-09 11:34:21 UTC) #5
https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
File lib/compiler/implementation/compiler.dart (right):

https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
lib/compiler/implementation/compiler.dart:305: computeSubclasses();
On 2012/05/09 11:13:03, kasperl wrote:
> Could we move this code to world? That would seem logical to me. Maybe
something
> like:
> 
> world.populate(universe.libraries);

Done.

https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
File lib/compiler/implementation/ssa/optimize.dart (right):

https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
lib/compiler/implementation/ssa/optimize.dart:562: MemberSet memberSet =
compiler.world.memberSetFor(type, node.name);
On 2012/05/09 11:13:03, kasperl wrote:
> I would actually consider not using a MemberSet here. Maybe just do:
> 
>   compiler.world.isOnlyFields(type, node.name)?
> 
> That way it would be easier to cache information in the world and the API that
> the compiler depends on what be narrower.

Done.

https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
File lib/compiler/implementation/world.dart (right):

https://chromiumcodereview.appspot.com/10383065/diff/3009/lib/compiler/implem...
lib/compiler/implementation/world.dart:14: MemberSet memberSetFor(Type type,
SourceString member) {
On 2012/05/09 11:13:03, kasperl wrote:
> I'm not sure this functionality needs to be exposed directly to the optimizer.

Made it library private.

Powered by Google App Engine
This is Rietveld 408576698