Skip to content

Commit

Permalink
Disable PERF tests in GTC_bitfield
Browse files Browse the repository at this point in the history
  • Loading branch information
christophe-lunarg committed Mar 5, 2024
1 parent 8d6442f commit d804b3e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
4 changes: 4 additions & 0 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ option(GLM_QUIET "No CMake Message" OFF)
option(GLM_TEST_ENABLE "Build unit tests" ON)
option(GLM_PERF_TEST_ENABLE "Build perf tests" OFF)

if(GLM_PERF_TEST_ENABLE)
add_definitions(-DGLM_TEST_PERF)
endif()

# Compiler and default options

if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
Expand Down
16 changes: 10 additions & 6 deletions test/gtc/gtc_bitfield.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1021,9 +1021,10 @@ int main()
{
int Error = 0;

std::clock_t const LastTime = std::clock();

Error += ::bitfieldInterleave::test();

#ifdef GLM_TEST_PERF

Error += ::bitfieldInterleave3::test();
Error += ::bitfieldInterleave4::test();

Expand All @@ -1033,15 +1034,18 @@ int main()

Error += ::bitfieldInterleave::perf();

#endif//GLM_TEST_PERF

Error += ::mask::test();

#ifdef GLM_TEST_PERF

Error += ::mask::perf();

#endif//GLM_TEST_PERF

Error += test_bitfieldRotateRight();
Error += test_bitfieldRotateLeft();

std::clock_t const Time = std::clock() - LastTime;

std::printf("gtc_bitfield %d clocks\n", static_cast<int>(Time));

return Error;
}

0 comments on commit d804b3e

Please sign in to comment.