--- orig 2010-04-16 16:30:50.000000000 +0200 +++ sql_select.cc.base 2010-04-08 21:46:13.000000000 +0200 @@ -7340,6 +7340,8 @@ join->emb_sjm_nest->sj_inner_tables : ~(table_map)0)); + ulonglong now= my_getsystime(); + do { /* Find the extension of the current QEP with the lowest cost */ join->best_read= DBL_MAX; @@ -7355,6 +7357,8 @@ */ DBUG_EXECUTE("opt", print_plan(join, n_tables, record_count, read_time, read_time, "optimal");); + now= my_getsystime() - now; + fprintf(stderr, "greedy_search %d\n", (int)(((double)now)/1e4)); DBUG_RETURN(FALSE); }