summaryrefslogtreecommitdiffhomepage
path: root/benchmarks/cpque_benchmark.cpp
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2020-12-28 18:18:48 +0100
committerTyge Løvset <[email protected]>2020-12-28 18:18:48 +0100
commit74a75b3a8d155ea155358674d3bf8251658183a5 (patch)
tree19886986b9ce6943b826311cda40f67ebc8dd7b1 /benchmarks/cpque_benchmark.cpp
parent83b7be31a1d0fc0be4e013dbfc97bb6cdc3600db (diff)
downloadSTC-modified-74a75b3a8d155ea155358674d3bf8251658183a5.tar.gz
STC-modified-74a75b3a8d155ea155358674d3bf8251658183a5.zip
Reverted crand.h API back to rename crand_* to stc64_*, and crand_next() -> stc64_rand().
Diffstat (limited to 'benchmarks/cpque_benchmark.cpp')
-rw-r--r--benchmarks/cpque_benchmark.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/benchmarks/cpque_benchmark.cpp b/benchmarks/cpque_benchmark.cpp
index 625bb056..396d763d 100644
--- a/benchmarks/cpque_benchmark.cpp
+++ b/benchmarks/cpque_benchmark.cpp
@@ -10,15 +10,15 @@ using_cpque(f, cvec_f, >);
int main()
{
uint32_t seed = time(NULL);
- crand_t rng;
+ stc64_t rng;
int N = 10000000, M = 10;
cpque_f pq = cpque_f_init();
- rng = crand_init(seed);
+ rng = stc64_init(seed);
clock_t start = clock();
c_forrange (i, int, N)
- cvec_f_push_back(&pq, (float) crand_nextf(&rng)*100000);
+ cvec_f_push_back(&pq, (float) stc64_randf(&rng)*100000);
cpque_f_make_heap(&pq);
printf("Built priority queue: %f secs\n", (clock() - start) / (float) CLOCKS_PER_SEC);
@@ -35,7 +35,7 @@ int main()
start = clock();
c_forrange (i, int, N)
- cpque_f_push(&pq, (float) crand_nextf(&rng)*100000);
+ cpque_f_push(&pq, (float) stc64_randf(&rng)*100000);
printf("pushed PQ: %f secs\n", (clock() - start) / (float) CLOCKS_PER_SEC);
c_forrange (i, int, M) {