Skip to content

Commit

Permalink
Reaisonable size
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Applencourt committed Jul 26, 2023
1 parent c98620a commit 31a3221
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .secret_cpp/bench_determinant.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#include "qpx.hpp"
#include <determinant.hpp>
#include <benchmark/benchmark.h>

static void ComputePhaseAndApplyExcitation(benchmark::State& state) {

const auto n_orbital = 1024;
const auto n_elec = 129;

auto alpha = spin_det_t(n_orbital);
auto beta = spin_det_t(n_elec);
alpha.set(0, n_elec, 1);

det_t s{alpha, beta};
for(auto _ : state) {
auto d = apply_single_spin_excitation(s, 0, 0, n_elec+1);
benchmark::DoNotOptimize(d);
}
}

BENCHMARK(ComputePhaseAndApplyExcitation);
BENCHMARK_MAIN();

0 comments on commit 31a3221

Please sign in to comment.