List:Commits« Previous MessageNext Message »
From:Marc Alff Date:September 24 2010 9:05pm
Subject:bzr push into mysql-next-mr-wl4816 branch (marc.alff:3198 to 3199)
View as plain text  
 3199 Marc Alff	2010-09-24
      Cleanup

    modified:
      mysql-test/suite/perfschema/r/innodb_table_io.result
      mysql-test/suite/perfschema/r/temp_table_io.result
      storage/perfschema/pfs.cc
      storage/perfschema/pfs_instr_class.cc
      storage/perfschema/pfs_setup_object.cc
 3198 Marc Alff	2010-09-24
      Test cleanup

    removed:
      mysql-test/suite/perfschema/r/schema.result
    modified:
      mysql-test/suite/perfschema/r/pfs_upgrade_lc1.result
      mysql-test/suite/perfschema/r/pfs_upgrade_lc2.result
      mysql-test/suite/perfschema/r/schema_lc1.result
      mysql-test/suite/perfschema/r/schema_lc2.result
=== modified file 'mysql-test/suite/perfschema/r/innodb_table_io.result'
--- a/mysql-test/suite/perfschema/r/innodb_table_io.result	2010-09-23 16:08:54 +0000
+++ b/mysql-test/suite/perfschema/r/innodb_table_io.result	2010-09-24 21:04:59 +0000
@@ -106,7 +106,9 @@ wait/io/table/sql/handler	handler.cc:	TA
 wait/io/table/sql/handler	handler.cc:	TABLE	test	no_index_tab	fetch	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	#sql-XXXX	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	#sql-XXXX	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	no_index_tab	fetch	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	no_index_tab	fetch	NULL

=== modified file 'mysql-test/suite/perfschema/r/temp_table_io.result'
--- a/mysql-test/suite/perfschema/r/temp_table_io.result	2010-09-23 16:08:54 +0000
+++ b/mysql-test/suite/perfschema/r/temp_table_io.result	2010-09-24 21:04:59 +0000
@@ -72,15 +72,42 @@ event_name	short_source	object_type	obje
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
-wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	update	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	update	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	update	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	delete	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
+wait/io/table/sql/handler	handler.cc:	TEMPORARY TABLE	test	no_index_tab	fetch	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 wait/io/table/sql/handler	handler.cc:	TABLE	test	marker	insert	NULL
 show status like 'performance_schema_%';

=== modified file 'storage/perfschema/pfs.cc'
--- a/storage/perfschema/pfs.cc	2010-09-24 01:31:02 +0000
+++ b/storage/perfschema/pfs.cc	2010-09-24 21:04:59 +0000
@@ -1196,9 +1196,6 @@ static void destroy_cond_v1(PSI_cond* co
 static PSI_table_share*
 get_table_share_v1(my_bool temporary, TABLE_SHARE *share)
 {
-  /* SETUP_OBJECTS does not allow to enable temporary tables. */
-  if (temporary)
-    return NULL;
   /* Do not instrument this table is all table instruments are disabled. */
   if (! global_table_io_class.m_enabled)
     return NULL;
@@ -1953,7 +1950,7 @@ get_thread_table_locker_v1(PSI_table_loc
     /* Refresh the enabled and timed flags from SETUP_OBJECTS */
     share->m_setup_objects_version= setup_objects_version;
     lookup_setup_object(pfs_thread,
-                        share->get_object_type(),
+                        OBJECT_TYPE_TABLE, /* even for temporary tables */
                         share->m_schema_name,
                         share->m_schema_name_length,
                         share->m_table_name,

=== modified file 'storage/perfschema/pfs_instr_class.cc'
--- a/storage/perfschema/pfs_instr_class.cc	2010-09-24 18:21:22 +0000
+++ b/storage/perfschema/pfs_instr_class.cc	2010-09-24 21:04:59 +0000
@@ -877,7 +877,7 @@ search:
   {
     version= setup_objects_version;
     lookup_setup_object(thread,
-                        (temporary ? OBJECT_TYPE_TEMPORARY_TABLE : OBJECT_TYPE_TABLE),
+                        OBJECT_TYPE_TABLE,
                         schema_name, schema_name_length,
                         table_name, table_name_length,
                         &enabled, &timed);

=== modified file 'storage/perfschema/pfs_setup_object.cc'
--- a/storage/perfschema/pfs_setup_object.cc	2010-09-24 18:21:22 +0000
+++ b/storage/perfschema/pfs_setup_object.cc	2010-09-24 21:04:59 +0000
@@ -279,6 +279,15 @@ void lookup_setup_object(PFS_thread *thr
   PFS_setup_object *pfs;
   int i;
 
+  /*
+    The table io instrumentation uses "TABLE" and "TEMPORARY TABLE".
+    SETUP_OBJECT uses "TABLE" for both concepts.
+    There is no way to provide a different setup for:
+    - TABLE foo.bar
+    - TEMPORARY TABLE foo.bar
+  */
+  DBUG_ASSERT(object_type != OBJECT_TYPE_TEMPORARY_TABLE);
+
   LF_PINS* pins= get_setup_object_hash_pins(thread);
   if (unlikely(pins == NULL))
   {
@@ -305,7 +314,7 @@ void lookup_setup_object(PFS_thread *thr
                            schema_name, schema_name_length, "%", 1);
       break;
     case 3:
-      /* Lookup OBJECT_TYPE + NULL + NULL in SETUP_OBJECTS */
+      /* Lookup OBJECT_TYPE + "%" + "%" in SETUP_OBJECTS */
       set_setup_object_key(&key, object_type, "%", 1, "%", 1);
       break;
     }


Attachment: [text/bzr-bundle] bzr/marc.alff@oracle.com-20100924210459-hyigvbqqi6llovwo.bundle
Thread
bzr push into mysql-next-mr-wl4816 branch (marc.alff:3198 to 3199) Marc Alff24 Sep