Skip to content

Commit 73d1b45

Browse files
committed
feat(notecard): Re-entrant run_operation chokepoint + request-lock seam
All Notecard entry points funnel through run_operation(), which holds an optional operation lock for the whole operation; nested entry points (e.g. execute(const T&) inside execute(T&)) re-enter as no-ops via a depth counter. The operation lock reuses the IBusLock seam (set_request_lock/clear_request_lock); null default = zero behavioral cost. RTX/readiness is wired in a later task.
1 parent 7f4950e commit 73d1b45

4 files changed

Lines changed: 439 additions & 236 deletions

File tree

ci.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,8 @@ NFEOF
196196
"$ROOT/tests/test_posix_serial.cpp" \
197197
"$ROOT/tests/test_notecard_move_semantics.cpp" \
198198
"$ROOT/tests/test_struct_sink_strings.cpp" \
199-
"$ROOT/tests/test_bus_lock.cpp"
199+
"$ROOT/tests/test_bus_lock.cpp" \
200+
"$ROOT/tests/test_operation_lock.cpp"
200201
/tmp/note-cpp-tests
201202
echo " tests: OK"
202203

cmake/note-cpp-sources.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ set(NOTE_CPP_TEST_SOURCES_FULL_ONLY
158158
test_transport_timing.cpp
159159
test_layered_transport.cpp
160160
test_txn_handshake.cpp
161+
test_operation_lock.cpp
161162
test_wire_format.cpp
162163
test_wire_format_jsonb.cpp
163164
)
@@ -194,6 +195,7 @@ set(NOTE_CPP_TEST_SOURCES_JSON_WIRE
194195
test_transport_serial.cpp
195196
test_transport_streaming.cpp
196197
test_txn_handshake.cpp
198+
test_operation_lock.cpp
197199
test_wire_format.cpp
198200
)
199201

0 commit comments

Comments
 (0)