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

Unified Diff: runtime/vm/object_test.cc

Issue 17421003: Store arguments descriptor in ICData. Remove loading of arguments descriptor at unoptimized call si… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 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/object.cc ('k') | runtime/vm/parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object_test.cc
===================================================================
--- runtime/vm/object_test.cc (revision 24207)
+++ runtime/vm/object_test.cc (working copy)
@@ -7,6 +7,7 @@
#include "vm/bigint_operations.h"
#include "vm/class_finalizer.h"
#include "vm/dart_api_impl.h"
+#include "vm/dart_entry.h"
#include "vm/isolate.h"
#include "vm/object.h"
#include "vm/object_store.h"
@@ -2495,13 +2496,16 @@
const intptr_t id = 12;
const intptr_t num_args_tested = 1;
const String& target_name = String::Handle(String::New("Thun"));
+ const Array& args_descriptor =
+ Array::Handle(ArgumentsDescriptor::New(1, Object::null_array()));
ICData& o1 = ICData::Handle();
- o1 = ICData::New(function, target_name, id, num_args_tested);
+ o1 = ICData::New(function, target_name, args_descriptor, id, num_args_tested);
EXPECT_EQ(1, o1.num_args_tested());
EXPECT_EQ(id, o1.deopt_id());
EXPECT_EQ(function.raw(), o1.function());
EXPECT_EQ(0, o1.NumberOfChecks());
EXPECT_EQ(target_name.raw(), o1.target_name());
+ EXPECT_EQ(args_descriptor.raw(), o1.arguments_descriptor());
const Function& target1 = Function::Handle(GetDummyTarget("Thun"));
o1.AddReceiverCheck(kSmiCid, target1);
@@ -2525,7 +2529,7 @@
EXPECT_EQ(target2.raw(), test_target.raw());
ICData& o2 = ICData::Handle();
- o2 = ICData::New(function, target_name, 57, 2);
+ o2 = ICData::New(function, target_name, args_descriptor, 57, 2);
EXPECT_EQ(2, o2.num_args_tested());
EXPECT_EQ(57, o2.deopt_id());
EXPECT_EQ(function.raw(), o2.function());
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698