Skip to content

Commit 27fa59b

Browse files
luisleo526claude
andcommitted
Register the exposure fold tests through a lane file and keep the CMake tail intact
Register the two exposure fold test executables from their own lane file instead of inserting them into the middle of the main test list, and place the opt-in oracle option immediately before the lane include block, so no earlier line of the main CMake file moves and the fast-row registration block stays the last CMake code. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
1 parent 81ae80f commit 27fa59b

2 files changed

Lines changed: 37 additions & 35 deletions

File tree

‎tests/CMakeLists.txt‎

Lines changed: 31 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1385,10 +1385,6 @@ list(APPEND TEST_SOURCES test_native_match_allocations)
13851385
list(APPEND TEST_SOURCES test_adapter_command_allocations)
13861386
list(APPEND TEST_SOURCES test_adapter_exit_scratch)
13871387
list(APPEND TEST_SOURCES test_reversal_exit_owner_gate)
1388-
# The acceptance-ordered exposure fold against the frozen position selector.
1389-
list(APPEND TEST_SOURCES test_cohort_exposure_fold)
1390-
# Deterministic work counts on reused-id and distinct-id opening runs.
1391-
list(APPEND TEST_SOURCES test_cohort_exposure_work)
13921388
# R5 lane PERF-L1: NativeStrategyHost's consumer, aggregate and lifecycle reads
13931389
# against the lookups they replaced, inside every host hook of randomized
13941390
# runs. Source-free, so it also runs in the kernel-only profile.
@@ -7487,6 +7483,37 @@ if(PINEFORGE_BUILD_SOURCE_LAYER AND UNIX
74877483
endforeach()
74887484
endif()
74897485

7486+
option(PINEFORGE_COHORT_EXPOSURE_FIXTURES
7487+
"Compare every cohort exposure call with the frozen selector" OFF)
7488+
if(PINEFORGE_COHORT_EXPOSURE_FIXTURES)
7489+
target_compile_definitions(pineforge PRIVATE PINEFORGE_COHORT_EXPOSURE_FIXTURES)
7490+
if(TARGET pineforge_source_quiet_ungated)
7491+
target_compile_definitions(pineforge_source_quiet_ungated PRIVATE
7492+
PINEFORGE_COHORT_EXPOSURE_FIXTURES)
7493+
endif()
7494+
if(TARGET pineforge_source_quiet_probe)
7495+
target_compile_definitions(pineforge_source_quiet_probe PRIVATE
7496+
PINEFORGE_COHORT_EXPOSURE_FIXTURES)
7497+
endif()
7498+
# These TUs compile the adapter directly, including two through the
7499+
# position-tail retirement fixture header. Source properties also cover
7500+
# any additional target built from the same TU in this directory.
7501+
foreach(_pf_cohort_adapter_tu IN ITEMS
7502+
test_adapter_growth_storage.cpp
7503+
test_adapter_reversal_storage.cpp
7504+
test_adapter_tree_ram.cpp
7505+
test_cohort_exposure_work.cpp
7506+
test_live_source_key_alias_adapter.cpp
7507+
test_live_source_key_spellings_strict_adapter.cpp
7508+
test_position_tail_retirement.cpp
7509+
test_position_tail_retirement_work.cpp
7510+
test_position_tail_summary_scale.cpp
7511+
test_reversal_exit_owner_gate.cpp)
7512+
set_property(SOURCE ${_pf_cohort_adapter_tu} APPEND PROPERTY
7513+
COMPILE_DEFINITIONS PINEFORGE_COHORT_EXPOSURE_FIXTURES)
7514+
endforeach()
7515+
endif()
7516+
74907517
# CR-150: one file per lane in tests/cr150.d/<lane>.cmake (see tests/cr150.d/README.md).
74917518
file(GLOB CR150_LANE_CMAKE CONFIGURE_DEPENDS "${CMAKE_CURRENT_SOURCE_DIR}/cr150.d/*.cmake")
74927519
list(SORT CR150_LANE_CMAKE)
@@ -8012,34 +8039,3 @@ endforeach()
80128039
if(PINEFORGE_BUILD_SOURCE_LAYER)
80138040
add_custom_target(pineforge_pr_smoke DEPENDS ${PINEFORGE_PR_FAST_TESTS})
80148041
endif()
8015-
8016-
option(PINEFORGE_COHORT_EXPOSURE_FIXTURES
8017-
"Compare every cohort exposure call with the frozen selector" OFF)
8018-
if(PINEFORGE_COHORT_EXPOSURE_FIXTURES)
8019-
target_compile_definitions(pineforge PRIVATE PINEFORGE_COHORT_EXPOSURE_FIXTURES)
8020-
if(TARGET pineforge_source_quiet_ungated)
8021-
target_compile_definitions(pineforge_source_quiet_ungated PRIVATE
8022-
PINEFORGE_COHORT_EXPOSURE_FIXTURES)
8023-
endif()
8024-
if(TARGET pineforge_source_quiet_probe)
8025-
target_compile_definitions(pineforge_source_quiet_probe PRIVATE
8026-
PINEFORGE_COHORT_EXPOSURE_FIXTURES)
8027-
endif()
8028-
# These TUs compile the adapter directly, including two through the
8029-
# position-tail retirement fixture header. Source properties also cover
8030-
# any additional target built from the same TU in this directory.
8031-
foreach(_pf_cohort_adapter_tu IN ITEMS
8032-
test_adapter_growth_storage.cpp
8033-
test_adapter_reversal_storage.cpp
8034-
test_adapter_tree_ram.cpp
8035-
test_cohort_exposure_work.cpp
8036-
test_live_source_key_alias_adapter.cpp
8037-
test_live_source_key_spellings_strict_adapter.cpp
8038-
test_position_tail_retirement.cpp
8039-
test_position_tail_retirement_work.cpp
8040-
test_position_tail_summary_scale.cpp
8041-
test_reversal_exit_owner_gate.cpp)
8042-
set_property(SOURCE ${_pf_cohort_adapter_tu} APPEND PROPERTY
8043-
COMPILE_DEFINITIONS PINEFORGE_COHORT_EXPOSURE_FIXTURES)
8044-
endforeach()
8045-
endif()
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
if(PINEFORGE_BUILD_SOURCE_LAYER)
2+
list(APPEND TEST_SOURCES test_cohort_exposure_fold)
3+
pineforge_add_unit_test(test_cohort_exposure_fold)
4+
list(APPEND TEST_SOURCES test_cohort_exposure_work)
5+
pineforge_add_unit_test(test_cohort_exposure_work)
6+
endif()

0 commit comments

Comments
 (0)