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

Unified Diff: runtime/vm/object_service.cc

Issue 2307673002: Remove dead code for writing ICData entries. (Closed)
Patch Set: Created 4 years, 3 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.h ('k') | runtime/vm/source_report.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object_service.cc
diff --git a/runtime/vm/object_service.cc b/runtime/vm/object_service.cc
index 322d856b73b059e2e4bc8874e7e0b89ca5fcbc2a..fc8552baf520613fd56379f40474e8f7ab6f7fbf 100644
--- a/runtime/vm/object_service.cc
+++ b/runtime/vm/object_service.cc
@@ -765,44 +765,7 @@ void ICData::PrintJSONImpl(JSONStream* stream, bool ref) const {
void ICData::PrintToJSONArray(const JSONArray& jsarray,
- TokenPosition token_pos,
- bool is_static_call) const {
- Isolate* isolate = Isolate::Current();
- Class& cls = Class::Handle();
- Function& func = Function::Handle();
-
- JSONObject jsobj(&jsarray);
- jsobj.AddProperty("name", String::Handle(target_name()).ToCString());
- jsobj.AddProperty("tokenPos", token_pos);
- // TODO(rmacnak): Figure out how to stringify DeoptReasons().
- // jsobj.AddProperty("deoptReasons", ...);
-
- JSONArray cache_entries(&jsobj, "cacheEntries");
- for (intptr_t i = 0; i < NumberOfChecks(); i++) {
- func = GetTargetAt(i);
- if (is_static_call) {
- cls ^= func.Owner();
- } else {
- intptr_t cid = GetReceiverClassIdAt(i);
- cls ^= isolate->class_table()->At(cid);
- }
- intptr_t count = GetCountAt(i);
- JSONObject cache_entry(&cache_entries);
- if (cls.IsTopLevel()) {
- cache_entry.AddProperty("receiverContainer",
- Library::Handle(cls.library()));
- } else {
- cache_entry.AddProperty("receiverContainer", cls);
- }
- cache_entry.AddProperty("count", count);
- cache_entry.AddProperty("target", func);
- }
-}
-
-
-void ICData::PrintToJSONArrayNew(const JSONArray& jsarray,
- TokenPosition token_pos,
- bool is_static_call) const {
+ TokenPosition token_pos) const {
Isolate* isolate = Isolate::Current();
Class& cls = Class::Handle();
Function& func = Function::Handle();
@@ -818,7 +781,7 @@ void ICData::PrintToJSONArrayNew(const JSONArray& jsarray,
JSONObject cache_entry(&cache_entries);
func = GetTargetAt(i);
intptr_t count = GetCountAt(i);
- if (!is_static_call) {
+ if (!is_static_call()) {
intptr_t cid = GetReceiverClassIdAt(i);
cls ^= isolate->class_table()->At(cid);
cache_entry.AddProperty("receiver", cls);
« no previous file with comments | « runtime/vm/object.h ('k') | runtime/vm/source_report.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698