summaryrefslogtreecommitdiff
path: root/compiler/dex/mir_analysis.cc
diff options
context:
space:
mode:
author Vladimir Marko <vmarko@google.com> 2014-09-22 14:50:02 +0100
committer Vladimir Marko <vmarko@google.com> 2014-09-23 14:42:17 +0100
commite39c54ea575ec710d5e84277fcdcc049f8acb3c9 (patch)
tree407209e732961074488043f6ccba8f1d692298a6 /compiler/dex/mir_analysis.cc
parentb36bba6d35e88687852b108c8d4b73b3ec2a9397 (diff)
Deprecate GrowableArray, use ArenaVector instead.
Purge GrowableArray from Quick and Portable. Remove GrowableArray<T>::Iterator. Change-Id: I92157d3a6ea5975f295662809585b2dc15caa1c6
Diffstat (limited to 'compiler/dex/mir_analysis.cc')
-rw-r--r--compiler/dex/mir_analysis.cc24
1 files changed, 12 insertions, 12 deletions
diff --git a/compiler/dex/mir_analysis.cc b/compiler/dex/mir_analysis.cc
index 9fa5facd19..1111e4cf1d 100644
--- a/compiler/dex/mir_analysis.cc
+++ b/compiler/dex/mir_analysis.cc
@@ -1218,25 +1218,25 @@ void MIRGraph::DoCacheFieldLoweringInfo() {
if (ifield_pos != 0u) {
// Resolve instance field infos.
- DCHECK_EQ(ifield_lowering_infos_.Size(), 0u);
- ifield_lowering_infos_.Resize(ifield_pos);
+ DCHECK_EQ(ifield_lowering_infos_.size(), 0u);
+ ifield_lowering_infos_.reserve(ifield_pos);
for (size_t pos = 0u; pos != ifield_pos; ++pos) {
- ifield_lowering_infos_.Insert(MirIFieldLoweringInfo(field_idxs[pos]));
+ ifield_lowering_infos_.push_back(MirIFieldLoweringInfo(field_idxs[pos]));
}
MirIFieldLoweringInfo::Resolve(cu_->compiler_driver, GetCurrentDexCompilationUnit(),
- ifield_lowering_infos_.GetRawStorage(), ifield_pos);
+ ifield_lowering_infos_.data(), ifield_pos);
}
if (sfield_pos != max_refs) {
// Resolve static field infos.
- DCHECK_EQ(sfield_lowering_infos_.Size(), 0u);
- sfield_lowering_infos_.Resize(max_refs - sfield_pos);
+ DCHECK_EQ(sfield_lowering_infos_.size(), 0u);
+ sfield_lowering_infos_.reserve(max_refs - sfield_pos);
for (size_t pos = max_refs; pos != sfield_pos;) {
--pos;
- sfield_lowering_infos_.Insert(MirSFieldLoweringInfo(field_idxs[pos]));
+ sfield_lowering_infos_.push_back(MirSFieldLoweringInfo(field_idxs[pos]));
}
MirSFieldLoweringInfo::Resolve(cu_->compiler_driver, GetCurrentDexCompilationUnit(),
- sfield_lowering_infos_.GetRawStorage(), max_refs - sfield_pos);
+ sfield_lowering_infos_.data(), max_refs - sfield_pos);
}
}
@@ -1338,9 +1338,9 @@ void MIRGraph::DoCacheMethodLoweringInfo() {
}
// Prepare unique method infos, set method info indexes for their MIRs.
- DCHECK_EQ(method_lowering_infos_.Size(), 0u);
+ DCHECK_EQ(method_lowering_infos_.size(), 0u);
const size_t count = invoke_map.size();
- method_lowering_infos_.Resize(count);
+ method_lowering_infos_.reserve(count);
for (size_t pos = 0u; pos != count; ++pos) {
const MapEntry* entry = sequential_entries[pos];
MirMethodLoweringInfo method_info(entry->target_method_idx,
@@ -1348,10 +1348,10 @@ void MIRGraph::DoCacheMethodLoweringInfo() {
if (entry->devirt_target != nullptr) {
method_info.SetDevirtualizationTarget(*entry->devirt_target);
}
- method_lowering_infos_.Insert(method_info);
+ method_lowering_infos_.push_back(method_info);
}
MirMethodLoweringInfo::Resolve(cu_->compiler_driver, GetCurrentDexCompilationUnit(),
- method_lowering_infos_.GetRawStorage(), count);
+ method_lowering_infos_.data(), count);
}
bool MIRGraph::SkipCompilationByName(const std::string& methodname) {