diff options
author | 2016-01-19 12:03:24 +0000 | |
---|---|---|
committer | 2016-01-19 12:03:24 +0000 | |
commit | 31abc14132ad3895d2da9bed4520e96baeffaeb0 (patch) | |
tree | 3ae5ddcaf4d2487dbc6974a40c13acf62286902b /compiler/optimizing/ssa_builder.h | |
parent | a27d59b2b98a02b2e9e5dbe40623e7a97aa1e8d8 (diff) | |
parent | 65902e86b91f984061657bd8cacf239edb53c39d (diff) |
Merge "ART: Optimize out redundant NewInstances of String"
Diffstat (limited to 'compiler/optimizing/ssa_builder.h')
-rw-r--r-- | compiler/optimizing/ssa_builder.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/optimizing/ssa_builder.h b/compiler/optimizing/ssa_builder.h index 28eef6a40c..ccef8ea380 100644 --- a/compiler/optimizing/ssa_builder.h +++ b/compiler/optimizing/ssa_builder.h @@ -57,6 +57,7 @@ class SsaBuilder : public HGraphVisitor { loop_headers_(graph->GetArena()->Adapter(kArenaAllocSsaBuilder)), ambiguous_agets_(graph->GetArena()->Adapter(kArenaAllocSsaBuilder)), ambiguous_asets_(graph->GetArena()->Adapter(kArenaAllocSsaBuilder)), + uninitialized_strings_(graph->GetArena()->Adapter(kArenaAllocSsaBuilder)), locals_for_(graph->GetBlocks().size(), ArenaVector<HInstruction*>(graph->GetArena()->Adapter(kArenaAllocSsaBuilder)), graph->GetArena()->Adapter(kArenaAllocSsaBuilder)) { @@ -105,6 +106,8 @@ class SsaBuilder : public HGraphVisitor { HPhi* GetFloatDoubleOrReferenceEquivalentOfPhi(HPhi* phi, Primitive::Type type); HArrayGet* GetFloatOrDoubleEquivalentOfArrayGet(HArrayGet* aget); + void RemoveRedundantUninitializedStrings(); + StackHandleScopeCollection* const handles_; // True if types of ambiguous ArrayGets have been resolved. @@ -119,6 +122,7 @@ class SsaBuilder : public HGraphVisitor { ArenaVector<HArrayGet*> ambiguous_agets_; ArenaVector<HArraySet*> ambiguous_asets_; + ArenaVector<HNewInstance*> uninitialized_strings_; // HEnvironment for each block. ArenaVector<ArenaVector<HInstruction*>> locals_for_; |