Python native extension to use CXX/CUDA standard of NVBench library

This fixes cryptic build failure with GNU compiler 14
This commit is contained in:
Oleksandr Pavlyk
2025-08-01 15:33:39 -05:00
parent 3fea652d16
commit 4fc628c4d7
2 changed files with 2 additions and 3 deletions

View File

@@ -32,7 +32,6 @@ target_link_libraries(_nvbench PRIVATE CUDA::cudart_static)
set_target_properties(_nvbench PROPERTIES INSTALL_RPATH "$ORIGIN")
set_target_properties(_nvbench PROPERTIES INTERPROCEDURAL_OPTIMIZATION ON)
set_target_properties(_nvbench PROPERTIES POSITION_INDEPENDENT_CODE ON)
set_target_properties(_nvbench PROPERTIES CXX_STANDARD 20)
install(TARGETS _nvbench DESTINATION cuda/nvbench)

View File

@@ -102,7 +102,7 @@ private:
class nvbench_run_error : std::runtime_error
{};
constinit py::handle benchmark_exc{};
py::handle benchmark_exc{};
class GlobalBenchmarkRegistry
{
@@ -215,7 +215,7 @@ py::dict py_get_axis_values(const nvbench::state &state)
}
// essentially a global variable, but allocated on the heap during module initialization
constinit std::unique_ptr<GlobalBenchmarkRegistry, py::nodelete> global_registry{};
std::unique_ptr<GlobalBenchmarkRegistry, py::nodelete> global_registry{};
} // end of anonymous namespace