Revision: 22507
Author:   [email protected]
Date:     Mon Jul 21 13:51:42 2014 UTC
Log:      Use 0 instead of undefined for uninitialized stub key.

The CPU profiler looks at uninitialized code objects, which triggers an assertion.

[email protected]

Review URL: https://codereview.chromium.org/404113003
http://code.google.com/p/v8/source/detail?r=22507

Modified:
 /branches/bleeding_edge/src/factory.cc
 /branches/bleeding_edge/src/objects-debug.cc

=======================================
--- /branches/bleeding_edge/src/factory.cc      Mon Jul 21 09:58:01 2014 UTC
+++ /branches/bleeding_edge/src/factory.cc      Mon Jul 21 13:51:42 2014 UTC
@@ -1437,7 +1437,7 @@
   code->set_raw_kind_specific_flags2(0);
   code->set_is_crankshafted(crankshafted);
   code->set_deoptimization_data(*empty_fixed_array(), SKIP_WRITE_BARRIER);
-  code->set_raw_type_feedback_info(*undefined_value());
+  code->set_raw_type_feedback_info(Smi::FromInt(0));
   code->set_next_code_link(*undefined_value());
   code->set_handler_table(*empty_fixed_array(), SKIP_WRITE_BARRIER);
   code->set_prologue_offset(prologue_offset);
=======================================
--- /branches/bleeding_edge/src/objects-debug.cc Mon Jul 21 13:10:14 2014 UTC +++ /branches/bleeding_edge/src/objects-debug.cc Mon Jul 21 13:51:42 2014 UTC
@@ -639,7 +639,7 @@
       last_gc_pc = it.rinfo()->pc();
     }
   }
-  CHECK(raw_type_feedback_info()->IsUndefined() ||
+  CHECK(raw_type_feedback_info() == Smi::FromInt(0) ||
         raw_type_feedback_info()->IsSmi() == IsCodeStubOrIC());
 }

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to