~drizzle-trunk/drizzle/jenkins-Drizzle-Builder-203

« back to all changes in this revision

Viewing changes to drizzled/optimizer/range.cc

  • Committer: Continuous Integration
  • Date: 2013-01-08 12:21:05 UTC
  • mfrom: (2611.1.2 drizzle-7.2)
  • Revision ID: ci@drizzle.org-20130108122105-2tvma6orqzbcabrj
Merge lp:~brianaker/drizzle/fix-warnings Build: jenkins-Drizzle-Builder-151

Show diffs side-by-side

added added

removed removed

Lines of Context:
1002
1002
  }
1003
1003
 
1004
1004
  if (imerge_too_expensive || (imerge_cost > read_time) ||
1005
 
      ((non_cpk_scan_records+cpk_scan_records >= param->table->cursor->stats.records) && read_time != DBL_MAX))
 
1005
      ((non_cpk_scan_records+cpk_scan_records >= param->table->cursor->stats.records) && compare_ne_double(read_time, DBL_MAX)))
1006
1006
  {
1007
1007
    /*
1008
1008
      Bail out if it is obvious that both index_merge and ROR-union will be
1226
1226
{
1227
1227
  double val1= static_cast<double>((*a)->records) * (*a)->key_rec_length;
1228
1228
  double val2= static_cast<double>((*b)->records) * (*b)->key_rec_length;
1229
 
  return (val1 < val2)? -1: (val1 == val2)? 0 : 1;
 
1229
  return (val1 < val2)? -1: (compare_double(val1, val2))? 0 : 1;
1230
1230
}
1231
1231
 
1232
1232
 
1522
1522
  double selectivity_mult= 1.0;
1523
1523
 
1524
1524
  selectivity_mult = ror_scan_selectivity(info, ror_scan);
1525
 
  if (selectivity_mult == 1.0)
 
1525
  if (compare_double(selectivity_mult, 1.0))
1526
1526
  {
1527
1527
    /* Don't add this scan if it doesn't improve selectivity. */
1528
1528
    return false;