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

Unified Diff: runtime/vm/profiler_test.cc

Issue 2949803002: New growth strategy for growable arrays (Closed)
Patch Set: Branch-free grow size computation. Renamed function names to be clearer. Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/precompiler.cc ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/profiler_test.cc
diff --git a/runtime/vm/profiler_test.cc b/runtime/vm/profiler_test.cc
index 17f0fdc41ee36058bd50a75dcfd336b06bdc4650..f14deacd30680edf625c019d8b2572a36b1067c9 100644
--- a/runtime/vm/profiler_test.cc
+++ b/runtime/vm/profiler_test.cc
@@ -1027,24 +1027,9 @@ TEST_CASE(Profiler_ArrayAllocation) {
Profile profile(isolate);
AllocationFilter filter(isolate->main_port(), array_class.id());
profile.Build(thread, &filter, Profile::kNoTags);
- // We should still only have one allocation sample.
- EXPECT_EQ(1, profile.sample_count());
- ProfileTrieWalker walker(&profile);
-
- walker.Reset(Profile::kExclusiveCode);
- EXPECT(walker.Down());
- EXPECT_STREQ("DRT_AllocateArray", walker.CurrentName());
- EXPECT(walker.Down());
- EXPECT_STREQ("[Stub] AllocateArray", walker.CurrentName());
- EXPECT(walker.Down());
- EXPECT_STREQ("new _List", walker.CurrentName());
- EXPECT(walker.Down());
- EXPECT_STREQ("new _GrowableList", walker.CurrentName());
- EXPECT(walker.Down());
- EXPECT_STREQ("new List._internal", walker.CurrentName());
- EXPECT(walker.Down());
- EXPECT_STREQ("bar", walker.CurrentName());
- EXPECT(!walker.Down());
+ // We should have no allocation samples, since empty
+ // growable lists use a shared backing.
+ EXPECT_EQ(0, profile.sample_count());
}
}
« no previous file with comments | « runtime/vm/precompiler.cc ('k') | runtime/vm/raw_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698