Make sure to generate a CodeCreateEvent for the CPU features
authorkasperl@chromium.org <kasperl@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 25 Mar 2009 10:29:22 +0000 (10:29 +0000)
committerkasperl@chromium.org <kasperl@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 25 Mar 2009 10:29:22 +0000 (10:29 +0000)
probe code object, and really raise an exception if SplayTree.Remove
is called with a key that cannot be found.
Review URL: http://codereview.chromium.org/42597

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1606 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/assembler-ia32.cc
tools/splaytree.py

index ee51cb4..8549261 100644 (file)
@@ -139,6 +139,7 @@ void CpuFeatures::Probe() {
   Object* code =
       Heap::CreateCode(desc, NULL, Code::ComputeFlags(Code::STUB), NULL);
   if (!code->IsCode()) return;
+  LOG(CodeCreateEvent("Builtin", Code::cast(code), "CpuFeatures::Probe"));
   typedef uint64_t (*F0)();
   F0 probe = FUNCTION_CAST<F0>(Code::cast(code)->entry());
   supported_ = probe();
index 4353b64..c6b6414 100644 (file)
@@ -75,12 +75,12 @@ class SplayTree(object):
     """Remove the node with the given key from the SplayTree."""
     # Raise exception for key that is not found if the tree is empty.
     if self.IsEmpty():
-      raise 'KeyNotFound'
+      raise Exception('KeyNotFound')
     # Splay on the key to move the node with the given key to the top.
     self.Splay(key)
     # Raise exception for key that is not found.
     if self.root.key != key:
-      raise 'KeyNotFound'
+      raise Exception('KeyNotFound')
     removed = self.root
     # Link out the root node.
     if not self.root.left: