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

Unified Diff: src/code-stubs.cc

Issue 15735020: trace compare_nil_ic state in --trace-ic output (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 7 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 | « src/code-stubs.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/code-stubs.cc
diff --git a/src/code-stubs.cc b/src/code-stubs.cc
index 312febc1aa5701d0de3d3a10534d809f0db74647..cf3a6f59918346c5b7014ea8d78bd4d01bf3eea6 100644
--- a/src/code-stubs.cc
+++ b/src/code-stubs.cc
@@ -410,6 +410,7 @@ void ICCompareStub::Generate(MacroAssembler* masm) {
void CompareNilICStub::Record(Handle<Object> object) {
ASSERT(types_ != Types::FullCompare());
+ Types old_types(types_);
if (equality_kind_ == kStrictEquality) {
// When testing for strict equality only one value will evaluate to true
types_.RemoveAll();
@@ -430,6 +431,22 @@ void CompareNilICStub::Record(Handle<Object> object) {
types_.Add(MONOMORPHIC_MAP);
}
}
+ old_types.TraceTransition(types_);
Sven Panne 2013/05/24 09:02:44 For consistency, call the tracing in CompareNilIC:
+}
+
+
+void CompareNilICStub::Types::TraceTransition(Types to) const {
+ if (!FLAG_trace_ic) return;
+ char buffer[100];
+ NoAllocationStringAllocator allocator(buffer,
+ static_cast<unsigned>(sizeof(buffer)));
+ StringStream stream(&allocator);
+ stream.Add("[CompareNilIC (");
Sven Panne 2013/05/24 09:02:44 Nit: To make things gradually more consistent, rem
+ Print(&stream);
+ stream.Add("->");
+ to.Print(&stream);
+ stream.Add(")]\n");
+ stream.OutputToStdOut();
}
« no previous file with comments | « src/code-stubs.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698