Index: views.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/views.module,v
retrieving revision 1.332.2.12
diff -u -F '^f' -r1.332.2.12 views.module
--- views.module	11 Nov 2009 01:08:28 -0000	1.332.2.12
+++ views.module	17 Nov 2009 19:44:30 -0000
@@ -357,7 +357,6 @@ function views_block($op = 'list', $delt
 
       return $items;
     case 'view':
-      $start = views_microtime();
       // if this is 32, this should be an md5 hash.
       if (strlen($delta) == 32) {
         $hashes = variable_get('views_block_hashes', array());
@@ -389,7 +388,6 @@ function views_block($op = 'list', $delt
       if ($view = views_get_view($name)) {
         if ($view->access($display_id)) {
           $output = $view->execute_display($display_id);
-          vpr("Block $view->name execute time: " . (views_microtime() - $start) * 1000 . "ms");
           $view->destroy();
           return $output;
         }
Index: includes/view.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/views/includes/view.inc,v
retrieving revision 1.151.2.20
diff -u -F '^f' -r1.151.2.20 view.inc
--- includes/view.inc	16 Nov 2009 20:05:39 -0000	1.151.2.20
+++ includes/view.inc	17 Nov 2009 19:44:31 -0000
@@ -818,6 +818,8 @@
    * If you simply want to view the display, use view::preview() instead.
    */
   function execute_display($display_id = NULL, $args = array()) {
+    $timer_id = 'execute_display' . $display_id;
+    timer_start($timer_id);
     if (empty($this->current_display) || $this->current_display != $this->choose_display($display_id)) {
       if (!$this->set_display($display_id)) {
         return FALSE;
@@ -830,6 +832,11 @@
     $output = $this->display_handler->execute();
 
     $this->post_execute();
+
+    vpr("$this->name execute time: " . timer_read($timer_id) . " ms");
+
+    timer_stop($timer_id);
+
     return $output;
   }
 
@@ -841,6 +848,8 @@
    * normalized output.
    */
   function preview($display_id = NULL, $args = array()) {
+    $timer_id = 'preview' . $display_id;
+    timer_start($timer_id);
     if (empty($this->current_display) || $this->current_display != $display_id) {
       if (!$this->set_display($display_id)) {
         return FALSE;
@@ -853,6 +862,11 @@
     $output = $this->display_handler->preview();
 
     $this->post_execute();
+
+    vpr("$this->name execute time: " . timer_read($timer_id) . " ms");
+
+    timer_stop($timer_id);
+
     return $output;
   }
 
