Loading...
Searching...
No Matches
gpr::startup Namespace Reference

Typedefs

using Field = std::pair<std::string, std::string>

Functions

std::string line (const std::string &topic, const std::vector< Field > &fields)
constexpr bool annealStageCompiled () noexcept
 Whether the anneal box-ensemble stage is compiled into this build.
std::string annealLine (bool requested)
 "[startup] anneal stage=compiled|absent requested=true|false".
std::string linalgLine (const std::string &mode, int threads)
 "[startup] linalg mode=reproducible|library threads=N".

Typedef Documentation

◆ Field

using gpr::startup::Field = std::pair<std::string, std::string>

Definition at line 16 of file StartupReport.h.

Function Documentation

◆ annealLine()

std::string gpr::startup::annealLine ( bool requested)
inlinenodiscard

"[startup] anneal stage=compiled|absent requested=true|false".

Definition at line 38 of file StartupReport.h.

39{
40 return line("anneal",
41 {{"stage", annealStageCompiled() ? "compiled" : "absent"},
42 {"requested", requested ? "true" : "false"}});
43}
constexpr bool annealStageCompiled() noexcept
Whether the anneal box-ensemble stage is compiled into this build.
std::string line(const std::string &topic, const std::vector< Field > &fields)

◆ annealStageCompiled()

bool gpr::startup::annealStageCompiled ( )
nodiscardconstexprnoexcept

Whether the anneal box-ensemble stage is compiled into this build.

Definition at line 28 of file StartupReport.h.

29{
30#ifdef USE_ANNEAL
31 return true;
32#else
33 return false;
34#endif
35}

◆ linalgLine()

std::string gpr::startup::linalgLine ( const std::string & mode,
int threads )
inlinenodiscard

"[startup] linalg mode=reproducible|library threads=N".

Definition at line 46 of file StartupReport.h.

48{
49 return line("linalg",
50 {{"mode", mode}, {"threads", std::to_string(threads)}});
51}

◆ line()

std::string gpr::startup::line ( const std::string & topic,
const std::vector< Field > & fields )
inlinenodiscard

Definition at line 18 of file StartupReport.h.

20{
21 std::string out = "[startup] " + topic;
22 for (const auto& [key, value]: fields)
23 out += " " + key + "=" + value;
24 return out;
25}
eon_relax_band_t eon_relax_surface_fn void eon_relax_outcome_t * out