PostgreSQL Source Code
git master
|
#include "postgres.h"
#include <float.h>
#include <limits.h>
#include <math.h>
#include "optimizer/geqo_copy.h"
#include "optimizer/geqo_pool.h"
#include "optimizer/geqo_recombination.h"
Go to the source code of this file.
Functions | |
static int | compare (const void *arg1, const void *arg2) |
Pool * | alloc_pool (PlannerInfo *root, int pool_size, int string_length) |
void | free_pool (PlannerInfo *root, Pool *pool) |
void | random_init_pool (PlannerInfo *root, Pool *pool) |
void | sort_pool (PlannerInfo *root, Pool *pool) |
Chromosome * | alloc_chromo (PlannerInfo *root, int string_length) |
void | free_chromo (PlannerInfo *root, Chromosome *chromo) |
void | spread_chromo (PlannerInfo *root, Chromosome *chromo, Pool *pool) |
Chromosome* alloc_chromo | ( | PlannerInfo * | root, |
int | string_length | ||
) |
Definition at line 162 of file geqo_pool.c.
References palloc(), and Chromosome::string.
Referenced by geqo().
Pool* alloc_pool | ( | PlannerInfo * | root, |
int | pool_size, | ||
int | string_length | ||
) |
Definition at line 42 of file geqo_pool.c.
References Pool::data, for(), i, palloc(), Pool::size, and Pool::string_length.
Referenced by geqo().
|
static |
Definition at line 145 of file geqo_pool.c.
References Chromosome::worth.
Referenced by _bt_compare_array_elements(), _bt_load(), ApplyInt32SortComparator(), ApplySortAbbrevFullComparator(), ApplySortComparator(), ApplyUnsignedSortComparator(), binaryheap_allocate(), compare_scalars(), comparetup_cluster(), comparetup_cluster_tiebreak(), comparetup_datum(), comparetup_datum_tiebreak(), comparetup_heap(), comparetup_heap_tiebreak(), comparetup_index_btree(), comparetup_index_btree_tiebreak(), heap_compare_slots(), multi_sort_compare(), pairingheap_allocate(), qsort_tuple_int32_compare(), qsort_tuple_unsigned_compare(), qunique(), qunique_arg(), and sort_pool().
void free_chromo | ( | PlannerInfo * | root, |
Chromosome * | chromo | ||
) |
Definition at line 176 of file geqo_pool.c.
References pfree(), and Chromosome::string.
Referenced by geqo().
void free_pool | ( | PlannerInfo * | root, |
Pool * | pool | ||
) |
Definition at line 69 of file geqo_pool.c.
References Pool::data, for(), i, pfree(), and Pool::size.
Referenced by geqo().
void random_init_pool | ( | PlannerInfo * | root, |
Pool * | pool | ||
) |
Definition at line 91 of file geqo_pool.c.
References Pool::data, DEBUG1, elog, ERROR, geqo_eval(), i, init_tour(), root, size, Pool::size, Pool::string_length, while(), and Chromosome::worth.
Referenced by geqo().
void sort_pool | ( | PlannerInfo * | root, |
Pool * | pool | ||
) |
Definition at line 135 of file geqo_pool.c.
References compare(), Pool::data, qsort, and Pool::size.
Referenced by geqo().
void spread_chromo | ( | PlannerInfo * | root, |
Chromosome * | chromo, | ||
Pool * | pool | ||
) |
Definition at line 187 of file geqo_pool.c.
References Pool::data, geqo_copy(), i, root, Pool::size, Chromosome::string, Pool::string_length, and Chromosome::worth.
Referenced by geqo().