From fd8632e70dd2ec7dc6b0b03f469e3281114d5048 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Fri, 29 May 2026 17:01:57 +0300 Subject: test(generate): lock in set_mempolicy_home_node classification Audit of the set_mempolicy_home_node(2) NUMA syscall (task mz) confirmed it is correctly classified: KindNull (name-only, ior does not capture the addr/len range), FamilyMemory (matching its siblings set_mempolicy, mbind, migrate_pages, move_pages and docs/syscall-tracing-plan.md), and an Unclassified return (0/-1 with no byte count). Add lock-in tests so the classification cannot silently drift: - family_test.go asserts FamilyMemory for set_mempolicy_home_node and its NUMA siblings, with a note that get_mempolicy is the lone sibling still on FamilySecurity (tracked separately, out of scope here). - retclassify_test.go asserts the exit stays UNCLASSIFIED. Co-Authored-By: Claude Opus 4.8 --- internal/generate/retclassify_test.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'internal/generate/retclassify_test.go') diff --git a/internal/generate/retclassify_test.go b/internal/generate/retclassify_test.go index 3adae6e..70ade1a 100644 --- a/internal/generate/retclassify_test.go +++ b/internal/generate/retclassify_test.go @@ -51,6 +51,11 @@ func TestClassifyRetUnclassified(t *testing.T) { // sequences area; it transfers no bytes, so its exit must stay // UNCLASSIFIED (plain ret_event), like its KindNull siblings. "rseq", + // set_mempolicy_home_node(2) sets the home NUMA node for a memory range + // and returns int 0/-1 (no byte count), so its exit carries a plain + // ret_event and must stay UNCLASSIFIED, like its NUMA siblings + // set_mempolicy/mbind/migrate_pages/move_pages. + "set_mempolicy_home_node", } for _, name := range unclassified { if got := ClassifyRet("sys_exit_" + name); got != Unclassified { -- cgit v1.2.3