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

Unified Diff: runtime/vm/object.h

Issue 1799793002: Precompilation: Have instances calls load the entry point and Code object from the ic data array in… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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/flow_graph_compiler_x64.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.h
diff --git a/runtime/vm/object.h b/runtime/vm/object.h
index 78794a9e8897003b42791bcd48434c76d978ad85..4271a58f28d9962cb82ce48ebf1145cc89adfd1b 100644
--- a/runtime/vm/object.h
+++ b/runtime/vm/object.h
@@ -1926,6 +1926,10 @@ class ICData : public Object {
RawFunction* GetTargetAt(intptr_t index) const;
RawFunction* GetTargetForReceiverClassId(intptr_t class_id) const;
+ RawObject* GetTargetOrCodeAt(intptr_t index) const;
+ void SetCodeAt(intptr_t index, const Code& value) const;
+ void SetEntryPointAt(intptr_t index, const Smi& value) const;
+
void IncrementCountAt(intptr_t index, intptr_t value) const;
void SetCountAt(intptr_t index, intptr_t value) const;
intptr_t GetCountAt(intptr_t index) const;
@@ -1962,10 +1966,16 @@ class ICData : public Object {
static intptr_t TargetIndexFor(intptr_t num_args) {
return num_args;
}
+ static intptr_t CodeIndexFor(intptr_t num_args) {
+ return num_args;
+ }
static intptr_t CountIndexFor(intptr_t num_args) {
return (num_args + 1);
}
+ static intptr_t EntryPointIndexFor(intptr_t num_args) {
+ return (num_args + 1);
+ }
bool IsUsedAt(intptr_t i) const;
@@ -6094,6 +6104,11 @@ class Smi : public Integer {
return reinterpret_cast<RawSmi*>(raw_smi);
}
+ static RawSmi* FromAlignedAddress(uword address) {
+ ASSERT((address & kSmiTagMask) == kSmiTag);
+ return reinterpret_cast<RawSmi*>(address);
+ }
+
static RawClass* Class();
static intptr_t Value(const RawSmi* raw_smi) {
« no previous file with comments | « runtime/vm/flow_graph_compiler_x64.cc ('k') | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698