|
Stxxl
1.4.0
|
#include <algorithm>#include <functional>#include <limits>#include <stxxl/vector>#include <stxxl/stream>#include <stxxl/scan>#include <stxxl/sort>
Go to the source code of this file.
Defines | |
| #define | MCSTL_QUICKSORT_WORKAROUND 0 |
| #define | STXXL_NOT_CONSIDER_SORT_MEMORY_OVERHEAD 0 |
| #define | RECORD_SIZE 16 |
| #define | MAGIC 123 |
Typedefs | |
| typedef stxxl::vector< my_type, 4, stxxl::lru_pager < 8 >, block_size, STXXL_DEFAULT_ALLOC_STRATEGY > | vector_type |
Functions | |
| bool | operator< (const my_type &a, const my_type &b) |
| bool | operator== (const my_type &a, const my_type &b) |
| std::ostream & | operator<< (std::ostream &o, const my_type &obj) |
| stxxl::unsigned_type | checksum (vector_type &input) |
| void | linear_sort_normal (vector_type &input) |
| void | linear_sort_streamed (vector_type &input, vector_type &output) |
| int | main (int argc, const char **argv) |
Variables | |
| const unsigned long long | megabyte = 1024 * 1024 |
| const int | block_size = 4 * megabyte |
| stxxl::unsigned_type | run_size |
| stxxl::unsigned_type | buffer_size |
| #define MAGIC 123 |
Definition at line 45 of file test_parallel_sort.cpp.
| #define MCSTL_QUICKSORT_WORKAROUND 0 |
Definition at line 19 of file test_parallel_sort.cpp.
| #define RECORD_SIZE 16 |
Definition at line 44 of file test_parallel_sort.cpp.
| #define STXXL_NOT_CONSIDER_SORT_MEMORY_OVERHEAD 0 |
Definition at line 22 of file test_parallel_sort.cpp.
| typedef stxxl::vector<my_type, 4, stxxl::lru_pager<8>, block_size, STXXL_DEFAULT_ALLOC_STRATEGY> vector_type |
Definition at line 95 of file test_parallel_sort.cpp.
| stxxl::unsigned_type checksum | ( | vector_type & | input | ) |
Definition at line 97 of file test_parallel_sort.cpp.
References stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::begin(), and stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::end().
Referenced by linear_sort_normal(), and linear_sort_streamed().
| void linear_sort_normal | ( | vector_type & | input | ) |
Definition at line 105 of file test_parallel_sort.cpp.
References stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::begin(), checksum(), stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::end(), run_size, stxxl::sort(), STXXL_MSG, and stxxl::timestamp().
Referenced by main().
| void linear_sort_streamed | ( | vector_type & | input, |
| vector_type & | output | ||
| ) |
Definition at line 126 of file test_parallel_sort.cpp.
References stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::begin(), checksum(), stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::end(), stxxl::stream::materialize(), run_size, stxxl::stream::streamify(), STXXL_MSG, and stxxl::timestamp().
Referenced by main().
| int main | ( | int | argc, |
| const char ** | argv | ||
| ) |
Definition at line 163 of file test_parallel_sort.cpp.
References stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::begin(), buffer_size, stxxl::vector< Tp_, PgSz_, PgTp_, BlkSize_, AllocStr_, SzTp_ >::end(), stxxl::generate(), linear_sort_normal(), linear_sort_streamed(), megabyte, memory_to_use, stxxl::settings< must_be_int >::native_merge, run_size, STXXL_DEFAULT_BLOCK_SIZE, STXXL_MSG, and stxxl::timestamp().
| std::ostream& operator<< | ( | std::ostream & | o, |
| const my_type & | obj | ||
| ) | [inline] |
Definition at line 83 of file test_parallel_sort.cpp.
Definition at line 78 of file test_parallel_sort.cpp.
| const int block_size = 4 * megabyte |
Definition at line 42 of file test_parallel_sort.cpp.
Definition at line 48 of file test_parallel_sort.cpp.
Referenced by main().
| const unsigned long long megabyte = 1024 * 1024 |
Definition at line 39 of file test_parallel_sort.cpp.
Referenced by main().
Definition at line 47 of file test_parallel_sort.cpp.
Referenced by stxxl::stream::sorted_runs< TriggerEntryType, CompareType_ >::add_run(), stxxl::sort_local::create_runs(), stxxl::ksort_local::create_runs(), linear_sort_normal(), linear_sort_streamed(), and main().
1.7.6.1