diff --git a/research/high-carry-streams/BENCHMARK.json b/research/high-carry-streams/BENCHMARK.json new file mode 100644 index 0000000000..db5442bd54 --- /dev/null +++ b/research/high-carry-streams/BENCHMARK.json @@ -0,0 +1,415 @@ +{ + "python": "3.12.14 (main, Sep 1 2026, 14:16:52) [Clang 22.1.3 ]", + "rows": [ + { + "kind": "kernel", + "optimized": false, + "process_seconds": 1.0161208030003763, + "repeat": 0, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 490620, + "reads": 456503, + "writes": 158244 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 1105367 + }, + "seconds": 0.6791377710032975 + }, + { + "kind": "kernel", + "optimized": true, + "process_seconds": 0.36837542400098755, + "repeat": 0, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23784, + "reads": 23397, + "writes": 6883 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54064 + }, + "seconds": 0.03489563400216866 + }, + { + "kind": "kernel", + "optimized": true, + "process_seconds": 0.36396113999944646, + "repeat": 1, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23784, + "reads": 23397, + "writes": 6883 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54064 + }, + "seconds": 0.03428106199862668 + }, + { + "kind": "kernel", + "optimized": false, + "process_seconds": 0.9994165770003747, + "repeat": 1, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 490620, + "reads": 456503, + "writes": 158244 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 1105367 + }, + "seconds": 0.6782465260002937 + }, + { + "kind": "kernel", + "optimized": false, + "process_seconds": 0.9940601010021055, + "repeat": 2, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 490620, + "reads": 456503, + "writes": 158244 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 1105367 + }, + "seconds": 0.6694716679994599 + }, + { + "kind": "kernel", + "optimized": true, + "process_seconds": 0.36097629799769493, + "repeat": 2, + "result": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23784, + "reads": 23397, + "writes": 6883 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54064 + }, + "seconds": 0.03446967000127188 + }, + { + "kind": "route", + "optimized": false, + "process_seconds": 0.954324397000164, + "repeat": 0, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 881379, + "parent_peak": 19, + "physical": { + "moves": 379890, + "reads": 380836, + "writes": 120653 + }, + "q": 3, + "total": 881379, + "width": 2 + }, + "seconds": 0.5526973259984516 + }, + { + "kind": "route", + "optimized": true, + "process_seconds": 0.6636808020011813, + "repeat": 0, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 410237, + "parent_peak": 18, + "physical": { + "moves": 177278, + "reads": 178666, + "writes": 54293 + }, + "q": 3, + "total": 410237, + "width": 2 + }, + "seconds": 0.2629306579983677 + }, + { + "kind": "route", + "optimized": true, + "process_seconds": 0.6471672059997218, + "repeat": 1, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 410237, + "parent_peak": 18, + "physical": { + "moves": 177278, + "reads": 178666, + "writes": 54293 + }, + "q": 3, + "total": 410237, + "width": 2 + }, + "seconds": 0.2556898099974205 + }, + { + "kind": "route", + "optimized": false, + "process_seconds": 0.9698975460014481, + "repeat": 1, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 881379, + "parent_peak": 19, + "physical": { + "moves": 379890, + "reads": 380836, + "writes": 120653 + }, + "q": 3, + "total": 881379, + "width": 2 + }, + "seconds": 0.5696523660008097 + }, + { + "kind": "route", + "optimized": false, + "process_seconds": 0.9412932739978714, + "repeat": 2, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 881379, + "parent_peak": 19, + "physical": { + "moves": 379890, + "reads": 380836, + "writes": 120653 + }, + "q": 3, + "total": 881379, + "width": 2 + }, + "seconds": 0.5485472809996281 + }, + { + "kind": "route", + "optimized": true, + "process_seconds": 0.6444888030018774, + "repeat": 2, + "result": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 410237, + "parent_peak": 18, + "physical": { + "moves": 177278, + "reads": 178666, + "writes": 54293 + }, + "q": 3, + "total": 410237, + "width": 2 + }, + "seconds": 0.25943314699907205 + } + ], + "summary": { + "kernel": { + "process_seconds": { + "after": 0.36396113999944646, + "before": 0.9994165770003747, + "speedup": 2.745943088874528 + }, + "seconds": { + "after": 0.03446967000127188, + "before": 0.6782465260002937, + "speedup": 19.676617907141768 + } + }, + "route": { + "process_seconds": { + "after": 0.6471672059997218, + "before": 0.954324397000164, + "speedup": 1.4746179784032107 + }, + "seconds": { + "after": 0.25943314699907205, + "before": 0.5526973259984516, + "speedup": 2.1304036604097796 + } + } + } +} diff --git a/research/high-carry-streams/CATALOGUE.json b/research/high-carry-streams/CATALOGUE.json new file mode 100644 index 0000000000..53d7fd9219 --- /dev/null +++ b/research/high-carry-streams/CATALOGUE.json @@ -0,0 +1,21 @@ +{ + "bound_source_types": 1123, + "chart_types": 1123, + "low": "identity", + "operations_sha256": "133d1fad71e2c34e00cf93c024d257cc2c46c08dde525bfd706cd643f313e78b", + "orientations": 2246, + "q": 3, + "registry_matrices": 1123, + "saved_primitive_calls": 22591680, + "source_catalogue_sha256": "63d467f79e7e13fffd1f3de277dd5c6372cdac87f3fcd24b36a69149d300f81f", + "weighted_carries": { + "-1": 6576320, + "-2": 1203520, + "-3": 264192, + "1": 2665152, + "2": 990464, + "3": 158720 + }, + "weighted_new_kernel_calls": 11858368, + "weighted_old_full_field_primitive_calls": 34450048 +} diff --git a/research/high-carry-streams/KERNEL.json b/research/high-carry-streams/KERNEL.json new file mode 100644 index 0000000000..3d4248c796 --- /dev/null +++ b/research/high-carry-streams/KERNEL.json @@ -0,0 +1,3074 @@ +[ + { + "after": { + "amount": -4, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 562, + "reads": 525, + "writes": 134 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1221 + }, + "before": { + "amount": -4, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 5710, + "reads": 5095, + "writes": 1527 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 12332 + } + }, + { + "after": { + "amount": -3, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 384, + "reads": 361, + "writes": 90 + }, + "q": 3, + "s": 1, + "scratch": 5, + "total": 835 + }, + "before": { + "amount": -3, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 4298, + "reads": 3835, + "writes": 1148 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 9281 + } + }, + { + "after": { + "amount": -2, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 464, + "reads": 432, + "writes": 107 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1003 + }, + "before": { + "amount": -2, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 2886, + "reads": 2575, + "writes": 769 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 6230 + } + }, + { + "after": { + "amount": -1, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 456, + "reads": 425, + "writes": 102 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 983 + }, + "before": { + "amount": -1, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 1474, + "reads": 1315, + "writes": 390 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 3179 + } + }, + { + "after": { + "amount": 1, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 446, + "reads": 403, + "writes": 116 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 965 + }, + "before": { + "amount": 1, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 446, + "reads": 403, + "writes": 116 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 965 + } + }, + { + "after": { + "amount": 2, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 464, + "reads": 432, + "writes": 107 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1003 + }, + "before": { + "amount": 2, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 830, + "reads": 751, + "writes": 221 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 1802 + } + }, + { + "after": { + "amount": 3, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 384, + "reads": 361, + "writes": 90 + }, + "q": 3, + "s": 1, + "scratch": 5, + "total": 835 + }, + "before": { + "amount": 3, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 1214, + "reads": 1099, + "writes": 326 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 2639 + } + }, + { + "after": { + "amount": 4, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 562, + "reads": 525, + "writes": 134 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1221 + }, + "before": { + "amount": 4, + "b": 1, + "columns": 3, + "dirty": 3, + "physical": { + "moves": 1598, + "reads": 1447, + "writes": 431 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 3476 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 788, + "reads": 740, + "writes": 195 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1723 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 9346, + "reads": 8348, + "writes": 2646 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 20340 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 470, + "reads": 446, + "writes": 112 + }, + "q": 3, + "s": 1, + "scratch": 5, + "total": 1028 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 7026, + "reads": 6276, + "writes": 1987 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 15289 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 690, + "reads": 647, + "writes": 168 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1505 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 4706, + "reads": 4204, + "writes": 1328 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 10238 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 682, + "reads": 640, + "writes": 163 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1485 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 2386, + "reads": 2132, + "writes": 669 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 5187 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 714, + "reads": 650, + "writes": 197 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1561 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 714, + "reads": 650, + "writes": 197 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1561 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 690, + "reads": 647, + "writes": 168 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1505 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 1362, + "reads": 1240, + "writes": 384 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 2986 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 470, + "reads": 446, + "writes": 112 + }, + "q": 3, + "s": 1, + "scratch": 5, + "total": 1028 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 2010, + "reads": 1830, + "writes": 571 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 4411 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 788, + "reads": 740, + "writes": 195 + }, + "q": 3, + "s": 1, + "scratch": 7, + "total": 1723 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 6, + "dirty": 3, + "physical": { + "moves": 2658, + "reads": 2420, + "writes": 758 + }, + "q": 3, + "s": 1, + "scratch": 8, + "total": 5836 + } + }, + { + "after": { + "amount": -4, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 886, + "reads": 837, + "writes": 236 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1959 + }, + "before": { + "amount": -4, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 9196, + "reads": 8446, + "writes": 2723 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 20365 + } + }, + { + "after": { + "amount": -3, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 540, + "reads": 511, + "writes": 138 + }, + "q": 3, + "s": 3, + "scratch": 6, + "total": 1189 + }, + "before": { + "amount": -3, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 6912, + "reads": 6348, + "writes": 2044 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 15304 + } + }, + { + "after": { + "amount": -2, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 788, + "reads": 744, + "writes": 209 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1741 + }, + "before": { + "amount": -2, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 4628, + "reads": 4250, + "writes": 1365 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 10243 + } + }, + { + "after": { + "amount": -1, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 780, + "reads": 737, + "writes": 204 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1721 + }, + "before": { + "amount": -1, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 2344, + "reads": 2152, + "writes": 686 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 5182 + } + }, + { + "after": { + "amount": 1, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 808, + "reads": 752, + "writes": 238 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1798 + }, + "before": { + "amount": 1, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 808, + "reads": 752, + "writes": 238 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1798 + } + }, + { + "after": { + "amount": 2, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 788, + "reads": 744, + "writes": 209 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1741 + }, + "before": { + "amount": 2, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 1556, + "reads": 1450, + "writes": 469 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 3475 + } + }, + { + "after": { + "amount": 3, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 540, + "reads": 511, + "writes": 138 + }, + "q": 3, + "s": 3, + "scratch": 6, + "total": 1189 + }, + "before": { + "amount": 3, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 2304, + "reads": 2148, + "writes": 700 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 5152 + } + }, + { + "after": { + "amount": 4, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 886, + "reads": 837, + "writes": 236 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 1959 + }, + "before": { + "amount": 4, + "b": 1, + "columns": 9, + "dirty": 3, + "physical": { + "moves": 3052, + "reads": 2846, + "writes": 931 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 6829 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1436, + "reads": 1364, + "writes": 399 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 3199 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 16292, + "reads": 15023, + "writes": 5036 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 36351 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 782, + "reads": 746, + "writes": 208 + }, + "q": 3, + "s": 3, + "scratch": 6, + "total": 1736 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 12232, + "reads": 11279, + "writes": 3777 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 27288 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1338, + "reads": 1271, + "writes": 372 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 2981 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 8172, + "reads": 7535, + "writes": 2518 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 18225 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1330, + "reads": 1264, + "writes": 367 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 2961 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 4112, + "reads": 3791, + "writes": 1259 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 9162 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1428, + "reads": 1337, + "writes": 439 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 3204 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1428, + "reads": 1337, + "writes": 439 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 3204 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1338, + "reads": 1271, + "writes": 372 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 2981 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 2804, + "reads": 2627, + "writes": 878 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 6309 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 782, + "reads": 746, + "writes": 208 + }, + "q": 3, + "s": 3, + "scratch": 6, + "total": 1736 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 4180, + "reads": 3917, + "writes": 1317 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 9414 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 1436, + "reads": 1364, + "writes": 399 + }, + "q": 3, + "s": 3, + "scratch": 8, + "total": 3199 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 18, + "dirty": 3, + "physical": { + "moves": 5556, + "reads": 5207, + "writes": 1756 + }, + "q": 3, + "s": 3, + "scratch": 9, + "total": 12519 + } + }, + { + "after": { + "amount": -4, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 586, + "reads": 558, + "writes": 142 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1286 + }, + "before": { + "amount": -4, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 9146, + "reads": 8219, + "writes": 2601 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 19966 + } + }, + { + "after": { + "amount": -3, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 572, + "reads": 545, + "writes": 134 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1251 + }, + "before": { + "amount": -3, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 6874, + "reads": 6177, + "writes": 1953 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 15004 + } + }, + { + "after": { + "amount": -2, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 564, + "reads": 537, + "writes": 132 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1233 + }, + "before": { + "amount": -2, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 4602, + "reads": 4135, + "writes": 1305 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 10042 + } + }, + { + "after": { + "amount": -1, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 558, + "reads": 532, + "writes": 128 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1218 + }, + "before": { + "amount": -1, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 2330, + "reads": 2093, + "writes": 657 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 5080 + } + }, + { + "after": { + "amount": 1, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 526, + "reads": 483, + "writes": 145 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1154 + }, + "before": { + "amount": 1, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 526, + "reads": 483, + "writes": 145 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1154 + } + }, + { + "after": { + "amount": 2, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 564, + "reads": 537, + "writes": 132 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1233 + }, + "before": { + "amount": 2, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 994, + "reads": 915, + "writes": 281 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 2190 + } + }, + { + "after": { + "amount": 3, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 572, + "reads": 545, + "writes": 134 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1251 + }, + "before": { + "amount": 3, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 1462, + "reads": 1347, + "writes": 417 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 3226 + } + }, + { + "after": { + "amount": 4, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 586, + "reads": 558, + "writes": 142 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1286 + }, + "before": { + "amount": 4, + "b": 1, + "columns": 5, + "dirty": 3, + "physical": { + "moves": 1930, + "reads": 1779, + "writes": 553 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 4262 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 892, + "reads": 855, + "writes": 223 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1970 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 15930, + "reads": 14308, + "writes": 4718 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 34956 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 874, + "reads": 838, + "writes": 213 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1925 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 11962, + "reads": 10744, + "writes": 3540 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 26246 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 866, + "reads": 830, + "writes": 211 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1907 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 7994, + "reads": 7180, + "writes": 2362 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 17536 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 864, + "reads": 829, + "writes": 209 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1902 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 4026, + "reads": 3616, + "writes": 1184 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 8826 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 862, + "reads": 798, + "writes": 252 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1912 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 862, + "reads": 798, + "writes": 252 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1912 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 866, + "reads": 830, + "writes": 211 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1907 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 1666, + "reads": 1544, + "writes": 498 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 3708 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 874, + "reads": 838, + "writes": 213 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1925 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 2470, + "reads": 2290, + "writes": 744 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 5504 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 892, + "reads": 855, + "writes": 223 + }, + "q": 5, + "s": 1, + "scratch": 7, + "total": 1970 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 10, + "dirty": 3, + "physical": { + "moves": 3274, + "reads": 3036, + "writes": 990 + }, + "q": 5, + "s": 1, + "scratch": 8, + "total": 7300 + } + }, + { + "after": { + "amount": -4, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1126, + "reads": 1078, + "writes": 312 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2516 + }, + "before": { + "amount": -4, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 15728, + "reads": 14522, + "writes": 4849 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 35099 + } + }, + { + "after": { + "amount": -3, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1112, + "reads": 1065, + "writes": 304 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2481 + }, + "before": { + "amount": -3, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 11808, + "reads": 10902, + "writes": 3637 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 26347 + } + }, + { + "after": { + "amount": -2, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1104, + "reads": 1057, + "writes": 302 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2463 + }, + "before": { + "amount": -2, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 7888, + "reads": 7282, + "writes": 2425 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 17595 + } + }, + { + "after": { + "amount": -1, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1098, + "reads": 1052, + "writes": 298 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2448 + }, + "before": { + "amount": -1, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 3968, + "reads": 3662, + "writes": 1213 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 8843 + } + }, + { + "after": { + "amount": 1, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1128, + "reads": 1060, + "writes": 347 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2535 + }, + "before": { + "amount": 1, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1128, + "reads": 1060, + "writes": 347 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2535 + } + }, + { + "after": { + "amount": 2, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1104, + "reads": 1057, + "writes": 302 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2463 + }, + "before": { + "amount": 2, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 2208, + "reads": 2078, + "writes": 693 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 4979 + } + }, + { + "after": { + "amount": 3, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1112, + "reads": 1065, + "writes": 304 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2481 + }, + "before": { + "amount": 3, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 3288, + "reads": 3096, + "writes": 1039 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 7423 + } + }, + { + "after": { + "amount": 4, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 1126, + "reads": 1078, + "writes": 312 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 2516 + }, + "before": { + "amount": 4, + "b": 1, + "columns": 15, + "dirty": 3, + "physical": { + "moves": 4368, + "reads": 4114, + "writes": 1385 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 9867 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1972, + "reads": 1895, + "writes": 563 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4430 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 29068, + "reads": 26887, + "writes": 9212 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 65167 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1954, + "reads": 1878, + "writes": 553 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4385 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 21808, + "reads": 20171, + "writes": 6906 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 48885 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1946, + "reads": 1870, + "writes": 551 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4367 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 14548, + "reads": 13455, + "writes": 4600 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 32603 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1944, + "reads": 1869, + "writes": 549 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4362 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 7288, + "reads": 6739, + "writes": 2294 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 16321 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 2056, + "reads": 1941, + "writes": 654 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4651 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 2056, + "reads": 1941, + "writes": 654 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4651 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1946, + "reads": 1870, + "writes": 551 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4367 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 4084, + "reads": 3859, + "writes": 1320 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 9263 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1954, + "reads": 1878, + "writes": 553 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4385 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 6112, + "reads": 5777, + "writes": 1986 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 13875 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 1972, + "reads": 1895, + "writes": 563 + }, + "q": 5, + "s": 3, + "scratch": 8, + "total": 4430 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 30, + "dirty": 3, + "physical": { + "moves": 8140, + "reads": 7695, + "writes": 2652 + }, + "q": 5, + "s": 3, + "scratch": 9, + "total": 18487 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2564, + "reads": 2478, + "writes": 736 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5778 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 41076, + "reads": 38063, + "writes": 13072 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 92211 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2552, + "reads": 2467, + "writes": 729 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5748 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 30808, + "reads": 28547, + "writes": 9798 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 69153 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2544, + "reads": 2459, + "writes": 727 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5730 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 20540, + "reads": 19031, + "writes": 6524 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 46095 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2504, + "reads": 2421, + "writes": 709 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5634 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 10272, + "reads": 9515, + "writes": 3250 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 23037 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2616, + "reads": 2485, + "writes": 838 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5939 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2616, + "reads": 2485, + "writes": 838 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5939 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2544, + "reads": 2459, + "writes": 727 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5730 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 5228, + "reads": 4971, + "writes": 1700 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 11899 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2552, + "reads": 2467, + "writes": 729 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5748 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 7840, + "reads": 7457, + "writes": 2562 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 17859 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 2564, + "reads": 2478, + "writes": 736 + }, + "q": 7, + "s": 3, + "scratch": 8, + "total": 5778 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 42, + "dirty": 3, + "physical": { + "moves": 10452, + "reads": 9943, + "writes": 3424 + }, + "q": 7, + "s": 3, + "scratch": 9, + "total": 23819 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3180, + "reads": 3085, + "writes": 919 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7184 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 53916, + "reads": 49991, + "writes": 17280 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 121187 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3130, + "reads": 3037, + "writes": 896 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7063 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 40432, + "reads": 37487, + "writes": 12951 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 90870 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3122, + "reads": 3029, + "writes": 894 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7045 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 26948, + "reads": 24983, + "writes": 8622 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 60553 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3126, + "reads": 3034, + "writes": 895 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7055 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 13464, + "reads": 12479, + "writes": 4293 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 30236 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3252, + "reads": 3097, + "writes": 1057 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7406 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3252, + "reads": 3097, + "writes": 1057 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7406 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3122, + "reads": 3029, + "writes": 894 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7045 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 6524, + "reads": 6219, + "writes": 2150 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 14893 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3130, + "reads": 3037, + "writes": 896 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7063 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 9796, + "reads": 9341, + "writes": 3243 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 22380 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 3180, + "reads": 3085, + "writes": 919 + }, + "q": 9, + "s": 3, + "scratch": 8, + "total": 7184 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 54, + "dirty": 3, + "physical": { + "moves": 13068, + "reads": 12463, + "writes": 4336 + }, + "q": 9, + "s": 3, + "scratch": 9, + "total": 29867 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7794, + "reads": 7633, + "writes": 2258 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17685 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 151132, + "reads": 140471, + "writes": 48668 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 340271 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7744, + "reads": 7585, + "writes": 2235 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17564 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 113296, + "reads": 105299, + "writes": 36468 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 255063 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7736, + "reads": 7577, + "writes": 2233 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17546 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 75460, + "reads": 70127, + "writes": 24268 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 169855 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7708, + "reads": 7551, + "writes": 2221 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17480 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 37624, + "reads": 34955, + "writes": 12068 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 84647 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7848, + "reads": 7557, + "writes": 2584 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17989 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7848, + "reads": 7557, + "writes": 2584 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17989 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7736, + "reads": 7577, + "writes": 2233 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17546 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 15908, + "reads": 15331, + "writes": 5300 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 36539 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7744, + "reads": 7585, + "writes": 2235 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17564 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 23968, + "reads": 23105, + "writes": 8016 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 55089 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 7794, + "reads": 7633, + "writes": 2258 + }, + "q": 25, + "s": 3, + "scratch": 8, + "total": 17685 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 150, + "dirty": 3, + "physical": { + "moves": 32028, + "reads": 30879, + "writes": 10732 + }, + "q": 25, + "s": 3, + "scratch": 9, + "total": 73639 + } + }, + { + "after": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23784, + "reads": 23397, + "writes": 6883 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54064 + }, + "before": { + "amount": -4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 490620, + "reads": 456503, + "writes": 158244 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 1105367 + } + }, + { + "after": { + "amount": -3, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23734, + "reads": 23349, + "writes": 6860 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 53943 + }, + "before": { + "amount": -3, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 367744, + "reads": 342155, + "writes": 118566 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 828465 + } + }, + { + "after": { + "amount": -2, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23726, + "reads": 23341, + "writes": 6858 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 53925 + }, + "before": { + "amount": -2, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 244868, + "reads": 227807, + "writes": 78888 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 551563 + } + }, + { + "after": { + "amount": -1, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23704, + "reads": 23321, + "writes": 6849 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 53874 + }, + "before": { + "amount": -1, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 121992, + "reads": 113459, + "writes": 39210 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 274661 + } + }, + { + "after": { + "amount": 1, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23872, + "reads": 23117, + "writes": 7902 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54891 + }, + "before": { + "amount": 1, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23872, + "reads": 23117, + "writes": 7902 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54891 + } + }, + { + "after": { + "amount": 2, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23726, + "reads": 23341, + "writes": 6858 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 53925 + }, + "before": { + "amount": 2, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 48628, + "reads": 47123, + "writes": 16272 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 112023 + } + }, + { + "after": { + "amount": 3, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23734, + "reads": 23349, + "writes": 6860 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 53943 + }, + "before": { + "amount": 3, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 73384, + "reads": 71129, + "writes": 24642 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 169155 + } + }, + { + "after": { + "amount": 4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 23784, + "reads": 23397, + "writes": 6883 + }, + "q": 81, + "s": 3, + "scratch": 8, + "total": 54064 + }, + "before": { + "amount": 4, + "b": 2, + "columns": 486, + "dirty": 3, + "physical": { + "moves": 98140, + "reads": 95135, + "writes": 33012 + }, + "q": 81, + "s": 3, + "scratch": 9, + "total": 226287 + } + } +] diff --git a/research/high-carry-streams/PROOF.md b/research/high-carry-streams/PROOF.md new file mode 100644 index 0000000000..2c42df2eb5 --- /dev/null +++ b/research/high-carry-streams/PROOF.md @@ -0,0 +1,143 @@ +# Direct bounded carry rotation + +This is a source-level argument for `rotation.py` and the opt-in adapter, not a +formal proof of the complete multiplication theorem. Jose Manuel's PR2915 +supplies the reached high-field route, its complete affine compiler, and its +inherited primitive/caller contracts. We change one bounded carry operation. +The exact base and executable/archive pins are in SOURCES.json. + +## Contract and exact coordinates + +Let B,Q,S be positive canonical encoded counts, with Q>1 for the actual Ring +interface, and V=BQS. A complete input contains the Boolean cells +`source[(b Q+x) S+s]`, in that order, for 0<=b0, split each Q-field row into intervals L=[0,Q-r), R=[Q-r,Q). Store all +L blocks in one sequential bucket and all R blocks in another, retaining the +complete S-bit suffix and the order of the B prefixes. Emit R then L for each +prefix. An old x=Q-r at x-(Q-r), exactly +x+a mod Q. For a<0 split at r instead: L=[0,r), R=[r,Q); emit R then L. These +coordinates are x-r mod Q. The bucket cursors advance by their exact per-prefix +lengths, so no suffix or neighboring prefix is interchanged. + +When r=0, the result is the identity but is still copied to a distinct owned +output. This covers, for example, carries ±3 at Q=3. The helper split itself +also has a valid Q=1 identity, but Ring rejects Q=1 and the enclosing PR2915 +executor skips all high operations there. The complete-route zero-high fixture +checks that unchanged boundary; no Q=1 Ring execution is claimed. + +The code checks input exhaustion at the actual end of the first pass, and both +bucket ends at the end of the second. It rewinds the source, clears both private +buckets and every count, and returns only the output lease at its origin. The +numerical bank is only read to obtain the modulus. Thus the column identity +holds on arbitrary Boolean input, without zero-filled-source assumptions. + +## Complete local cost and storage + +Count every Tape read, write and unit movement, including encoded setup, +countdown allocation/normalization, payload copies, rewinds, erasure and pool +acquisitions. Let I be the fixed encoded width scanned when copying the Ring +modulus. The direct kernel costs + + T_rotate(B,Q,S,I,a) = O(BQS + I), 0<|a|<=4. + +Here is the complete decomposition, with all constants independent of B,Q,S. +The initial modulus copy and normalization cost O(I). The bounded split uses +O(log Q) copying, at most four decrements and bounded zero-counter resets. Its +final copy and all split-count disposal cost O(log Q). A canonical countdown +from m through zero costs O(m+log(m+1)) including construction and disposal: +bit toggles and head travel have a geometric sum, and the final erasure costs +its encoded length. This is the actual retained Counter algorithm, not an +assumption of constant-time arbitrary integer subtraction. + +Each nonidentity route has two phases. Each phase has one B-countdown and at +most two Q-row subloops per prefix. There are exactly BQ suffix copies per +phase; each suffix copy costs O(S), including its S-countdown when S>1. The +one-bit branch is constant. Since log(m+1)<=m for positive integer m, all row, +prefix and suffix initialization costs are absorbed into O(BQS). There are two +full payload copy passes (2V copied bits), O(V) total bucket rewind/clear work, +O(V) source/output rewinds, and a fixed number of end checks and acquisitions. +The identity path uses one complete copy pass. Returned-output disposal is an +additional O(V) charge at the caller. No recursive child, source access, sign, +frame change, or restoration is hidden in this expression. + +For the reached canonical high bank I=O(log Q), this becomes O(V). Arbitrarily +padded encodings retain the separate I term. This is a constant-factor execution +change; it does not improve the recursive exponent or provide a total stock, +backing-capacity, uniform primitive coefficient or machine-admission theorem. + +At the nonidentity streaming peak there are three payload leases (left, right, +output), two split counts, and at most three nested counters (prefix, field, +suffix): **eight additional scratch roles**. The temporary modulus has already +been erased. Split construction uses at most four roles, including the temporary +literal constructor. For S=1 the deepest suffix counter is absent. An occupied +entry lease is not one of these eight. A literal fixture attains eight, and a +one-role-short allocator rejects. The kernel allocates **zero numerical words**. +Payload storage is at most V in the two buckets plus V in the output; including +the borrowed source gives 3V occupied payload cells. Count tapes, markers, +retained blank extents and enclosing caller payloads remain separate categories. +This is not a bound on the entire recursive machine's backing capacity. + +## Adapter and whole-route accounting + +`CarryAdapter` retains PR2915's complete execute lifecycle: source copy, +modulus setup, affine-operation order, intermediate disposal, final bank erasure +and source return. Only translations with a!=1 use the new kernel. All other +operations, including +1, use the original dispatcher. +1 already uses a single +translation pass; retaining it avoids the small setup regression observed at +B=S=1. This is a static opcode selection, not a benchmark-dependent guard. + +For compiled operations o_1,...,o_k the whole charge is + + T_new = T_setup_and_return + + sum_{unchanged o_j} T_original(o_j) + + sum_{replaced carries a_j} T_rotate(B_j,Q,S_j,I,a_j). + +The inherited setup term includes every original input copy, intermediate clear +and high-bank lifecycle. Every swap and reversed-ADD native interval is identical +and fully charged. There is no additional native child or new recursive profile. +We prove the replacement's completed contract and linear cost. We do not infer +an all-domain numerical speed ratio from this big-O statement or finite timings. + +Before replacement a positive carry a uses a calls to `translate_one`, whereas +a negative carry uses |a| repetitions of sign/translate/sign, or 3|a| full-field +primitive calls. The new path uses one direct kernel (including both buckets), +with +1 unchanged. The catalogue receipt counts these calls in one precisely +named source specialization. These different primitives have different costs; +that count is neither a runtime ratio nor a κ calculation. + +## Verification boundary + +The independent oracle maps each input column using host modular arithmetic, +separately from the encoded implementation. Random Boolean values are only an +additional check: the provenance observer propagates a distinct formal column +for every input cell, and a wrong-direction control also fails on all-zero data. +All input bits, old prefixes and suffixes are included. A raw Tape observer +meters setup through complete kernel/route return. Native route intervals are +additionally reported but are not subtracted from totals. + +The package checks 96 complete before/after kernel pairs, seven complete route +pairs, 2,056 independently decoded split identities, source pins, cardinality and +ownership restoration, occupied dirty leases, erased buckets, invalid carries, +trailing input and endpoint-preserving extra-traffic controls. Complete selected +GL64 payload execution, supplier admission, whole caller stock and inherited +native/analytic assumptions remain outside this result. No new κ is claimed. + +Tekalign (tekuuu), with substantial OpenAI Codex assistance. Apache-2.0. diff --git a/research/high-carry-streams/README.md b/research/high-carry-streams/README.md new file mode 100644 index 0000000000..c052eabbf1 --- /dev/null +++ b/research/high-carry-streams/README.md @@ -0,0 +1,117 @@ +# Direct signed carry streams for selected BIT routes + +PR2915 implements a negative high-field carry by repeating sign/shift/sign, +up to twelve complete primitive calls for a carry of −4. This package adds an +opt-in physical kernel that performs the same rotation with two sequential +buckets. It uses encoded counters, preserves complete prefix/suffix coordinates, +returns a distinct owned output and clears its private state. The existing +1 +path remains in use: replacing it exposed a small setup regression on tiny +packets. Frozen sources and the default adapter remain unchanged. + +On the 486-bit −4 fixture, complete kernel traffic falls from **1,105,367 to +54,064 tape operations (95.1%)**. A complete signed-scale route falls from +**881,379 to 410,237 operations (53.5%)**. Every read, write and unit movement +between entry and return is counted, including setup, rewinds, bucket erasure +and native intervals. Initial fixture creation and disposal of the returned +output are outside the measured interval; output disposal stays paid by the +caller. No mathematical coverage is dropped between the two implementations. + +The source proof gives `O(BQS + I)` physical work for a complete B×Q×S packet +and encoded modulus width I, hence `O(BQS)` for the reached canonical high bank. +The direct kernel requires at most **eight additional scratch roles** and no +numerical words. Borrowed source and occupied scratch roles are additional to +that local inventory. This is not a total backing-capacity or supplier proof. + +## Exact evidence + +- **96 complete kernel pairs:** all eight signed carries, Q in 3,5,7,9,25,81, + unit/nonunit suffixes, multiple prefixes, wrapping and zero-residue cases. + Every independent input column, borrowed count, source and dirty lease is + checked; success leaves only the distinct output lease owned. +- **Seven complete route pairs:** dyadic/scalar/noncommuting words, signed low + carries, two high radix digits, multiple old prefixes and spectators, and + the unchanged zero-high-width branch. Native calls are unchanged and remain + in the measured totals. All seven complete pairs pass the original independent + coordinate oracle with the new adapter. +- **2,056 split identities and controls:** exact separate modular arithmetic; + wrong direction also rejected on all-zero payloads; trailing input in active + and identity cases; one scratch role too few; extra endpoint-preserving I/O; + invalid carries, zero modulus and source corruption. +- **Actual selected registry exposure:** 1,123 chart types, 2,246 orientations, + q=3 and identity low class, using source occurrence multiplicities. Carries + take **34,450,048 old full-field primitive calls → 11,858,368 kernel calls**. + These different primitives have different prices. This is one finite low-class + specialization, not a distribution over all low classes, a runtime ratio or + executed selected GL64 payloads. + +[PROOF.md](PROOF.md) gives the all-width coordinate argument, role lifetimes, +complete cost decomposition and explicit inherited scope. [KERNEL.json](KERNEL.json), +[ROUTES.json](ROUTES.json) and [CATALOGUE.json](CATALOGUE.json) retain complete typed +receipts; replay compares their contents as well as their digests in +[RESULT.json](RESULT.json). [BENCHMARK.json](BENCHMARK.json) records three alternating +fresh-process Python 3.12 pairs on identical inputs: median instrumented kernel +execution is **19.68×** faster and complete signed-scale route execution **2.13×** +faster. Including process startup gives **2.75×** and **1.47×**, respectively. +These are instrumented reference fixtures, not multiplication timings. + +## Reproduce and use + +From the repository root with standard-library CPython 3.12: + +```sh +python3.12 -B scripts/research_package.py --package research/high-carry-streams +``` + +Expected: all four `PASS_HIGH_CARRY_*` suites and successful registered replay. +The control suite runs with optimization enabled. The same committed verifiers +can run from a source export with all declared inputs present. The generic +metadata/pin launcher additionally needs Git history. [VALIDATION.md](VALIDATION.md) +records actual checks and environments. + +In an authenticated PR2915 namespace, construct `adapter.CarryAdapter` instead +of `stage.Adapter`, with the same native backend, registry and capacity. Its +`StagePool` and enclosing `route_packet` interface are unchanged. The replacement +uses no runtime module patch; test-only observers patch the fixture namespace +to compare the two adapters. This adapter has not been combined with PR3330's +optional frame scheduler in this package, and their measured savings must not +be added. The changed carry map is independent of that schedule. + +Base: `6f100d4bb5083f8c35d96fd95a539811c62f245c`, priority revision 6, +OS assignment seed **6**. [TASK.json](TASK.json) records three candidates, +changed card scope, bounded coverage and stopping rule. [SOURCES.json](SOURCES.json) +pins every executable/archive input before predecessor loading. +[Canonical claim](https://github.com/CrocSwap/integer-mult-bounds/discussions/2319#discussioncomment-19007093). + +No new κ, recursive child profile, selected frontier, complete fitted GL64 +execution or supplier admission is claimed. Source-level proof and exact finite +replay do not discharge inherited native, numerical-capacity, whole-caller stock, +physical backing, analytic or formal-refinement obligations. Concurrent +[PR3340](https://github.com/CrocSwap/integer-mult-bounds/pull/3340)'s fitted-B1 bridge +addresses a separate boundary and is not used as an assumption here. + +## Open next questions + +1. Can one reached dyadic scale/carry pair be executed with fewer complete + passes? First derive its actual prefix/suffix permutation and full bucket, + scratch and restoration bill. The present kernel deliberately changes only + bounded translations. +2. Before adoption, independently review this kernel and join its eight-role + reserve and actual encoded width to one enclosing caller. The remaining + stock/backing and native-refinement obligations prevent a component benchmark + from serving as a whole-supplier admission. Structured handoffs are in TASK.json. + +## Credit + +Tekalign (`tekuuu`), with substantial OpenAI Codex assistance in source analysis, +implementation, proof, verification and writing. New material is Apache-2.0; +no independent human or formal-kernel review is claimed. + +Jose Manuel (`jmbarrancoml`) supplied PR2915's executor, kernel vocabulary and +registry, PR2899's backend, and the retained physical source chain. The execute +lifecycle is adapted with attribution, rather than attributed as a new algorithm. +David Arias supplied PR2753's recursive caller. The physical observer follows +this account's PR3330. Credit Nick Petalas, commdata2338, Sagar Thakrar, Arham +Tahir, ywz65, Ross Richardson and Krzysztof Wójt for the predecessor cost, +countdown, physical-lifetime and caller work, and the PR2157/PR589/PR555 lineage +for the retained factor words and geometry. Original notices remain in the +unchanged authenticated archives. diff --git a/research/high-carry-streams/RESULT.json b/research/high-carry-streams/RESULT.json new file mode 100644 index 0000000000..c4b18a5863 --- /dev/null +++ b/research/high-carry-streams/RESULT.json @@ -0,0 +1,6 @@ +{ + "kernel": "4d0230b41e688e23cabf3547076fba81526b680203a8fdc1035447a35b85cd44", + "routes": "d77cc2b15d5dc623e8af5431830a58b5c2e728be81ef92b8ee6e80757202a3ee", + "catalogue": "ed26829392d85fd8afcc377e3a68a5e3bccd80bb3588856fd25e7312f28d3f3c", + "controls": "960e219d8c74f5a6d6078779f7c038bcfdc78eb45cb3484cdc91b35c998880cc" +} diff --git a/research/high-carry-streams/ROUTES.json b/research/high-carry-streams/ROUTES.json new file mode 100644 index 0000000000..3d7cbade46 --- /dev/null +++ b/research/high-carry-streams/ROUTES.json @@ -0,0 +1,513 @@ +[ + { + "after": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 410237, + "parent_peak": 18, + "physical": { + "moves": 177278, + "reads": 178666, + "writes": 54293 + }, + "q": 3, + "total": 410237, + "width": 2 + }, + "before": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 8, + "outside_native": 881379, + "parent_peak": 19, + "physical": { + "moves": 379890, + "reads": 380836, + "writes": 120653 + }, + "q": 3, + "total": 881379, + "width": 2 + }, + "case": 0 + }, + { + "after": { + "calls": { + "cubes": 2, + "swaps": 72 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 72, + "moves": 1305648, + "reads": 1304640, + "writes": 406224 + }, + "operations": 30, + "outside_native": 2674757, + "parent_peak": 23, + "physical": { + "moves": 2475082, + "reads": 2462104, + "writes": 754083 + }, + "q": 3, + "total": 5691269, + "width": 2 + }, + "before": { + "calls": { + "cubes": 2, + "swaps": 72 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 72, + "moves": 1305648, + "reads": 1304640, + "writes": 406224 + }, + "operations": 30, + "outside_native": 2674757, + "parent_peak": 23, + "physical": { + "moves": 2475082, + "reads": 2462104, + "writes": 754083 + }, + "q": 3, + "total": 5691269, + "width": 2 + }, + "case": 1 + }, + { + "after": { + "calls": { + "cubes": 2, + "swaps": 12 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 12, + "moves": 217608, + "reads": 217440, + "writes": 67704 + }, + "operations": 15, + "outside_native": 900531, + "parent_peak": 23, + "physical": { + "moves": 610146, + "reads": 607392, + "writes": 185745 + }, + "q": 3, + "total": 1403283, + "width": 2 + }, + "before": { + "calls": { + "cubes": 2, + "swaps": 12 + }, + "columns": 486, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 12, + "moves": 217608, + "reads": 217440, + "writes": 67704 + }, + "operations": 15, + "outside_native": 1475517, + "parent_peak": 23, + "physical": { + "moves": 862446, + "reads": 846946, + "writes": 268877 + }, + "q": 3, + "total": 1978269, + "width": 2 + }, + "case": 2 + }, + { + "after": { + "calls": { + "cubes": 1, + "swaps": 6 + }, + "columns": 625, + "dirty_roles": 3, + "low": [ + [ + 1, + 4 + ], + [ + 2, + 1 + ] + ], + "native": { + "calls": 6, + "moves": 180552, + "reads": 183474, + "writes": 50844 + }, + "operations": 15, + "outside_native": 1230894, + "parent_peak": 23, + "physical": { + "moves": 721766, + "reads": 715297, + "writes": 208701 + }, + "q": 5, + "total": 1645764, + "width": 2 + }, + "before": { + "calls": { + "cubes": 1, + "swaps": 6 + }, + "columns": 625, + "dirty_roles": 3, + "low": [ + [ + 1, + 4 + ], + [ + 2, + 1 + ] + ], + "native": { + "calls": 6, + "moves": 180552, + "reads": 183474, + "writes": 50844 + }, + "operations": 15, + "outside_native": 1869829, + "parent_peak": 23, + "physical": { + "moves": 1005780, + "reads": 978672, + "writes": 300247 + }, + "q": 5, + "total": 2284699, + "width": 2 + }, + "case": 3 + }, + { + "after": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 6, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 22, + "outside_native": 1685, + "parent_peak": 10, + "physical": { + "moves": 766, + "reads": 724, + "writes": 195 + }, + "q": 3, + "total": 1685, + "width": 1 + }, + "before": { + "calls": { + "cubes": 2, + "swaps": 0 + }, + "columns": 6, + "dirty_roles": 3, + "low": [ + [ + 1, + 2 + ], + [ + 2, + 2 + ] + ], + "native": { + "calls": 0, + "moves": 0, + "reads": 0, + "writes": 0 + }, + "operations": 22, + "outside_native": 1685, + "parent_peak": 10, + "physical": { + "moves": 766, + "reads": 724, + "writes": 195 + }, + "q": 3, + "total": 1685, + "width": 1 + }, + "case": 4 + }, + { + "after": { + "calls": { + "cubes": 1, + "swaps": 6 + }, + "columns": 6561, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 6, + "moves": 2802288, + "reads": 2878284, + "writes": 822456 + }, + "operations": 16, + "outside_native": 11440235, + "parent_peak": 23, + "physical": { + "moves": 7777328, + "reads": 7847347, + "writes": 2318588 + }, + "q": 3, + "total": 17943263, + "width": 3 + }, + "before": { + "calls": { + "cubes": 1, + "swaps": 6 + }, + "columns": 6561, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 6, + "moves": 2802288, + "reads": 2878284, + "writes": 822456 + }, + "operations": 16, + "outside_native": 16972893, + "parent_peak": 23, + "physical": { + "moves": 10260060, + "reads": 10106553, + "writes": 3109308 + }, + "q": 3, + "total": 23475921, + "width": 3 + }, + "case": 5 + }, + { + "after": { + "calls": { + "cubes": 1, + "swaps": 10 + }, + "columns": 243, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 10, + "moves": 181340, + "reads": 181200, + "writes": 56420 + }, + "operations": 23, + "outside_native": 793246, + "parent_peak": 23, + "physical": { + "moves": 529360, + "reads": 524895, + "writes": 157951 + }, + "q": 3, + "total": 1212206, + "width": 2 + }, + "before": { + "calls": { + "cubes": 1, + "swaps": 10 + }, + "columns": 243, + "dirty_roles": 3, + "low": [ + [ + 2, + 1 + ], + [ + 1, + 1 + ] + ], + "native": { + "calls": 10, + "moves": 181340, + "reads": 181200, + "writes": 56420 + }, + "operations": 23, + "outside_native": 1016974, + "parent_peak": 23, + "physical": { + "moves": 627238, + "reads": 618225, + "writes": 190471 + }, + "q": 3, + "total": 1435934, + "width": 2 + }, + "case": 6 + } +] diff --git a/research/high-carry-streams/SOURCES.json b/research/high-carry-streams/SOURCES.json new file mode 100644 index 0000000000..3db5fdb8d4 --- /dev/null +++ b/research/high-carry-streams/SOURCES.json @@ -0,0 +1,230 @@ +{ + "schema_version": 1, + "base_commit": "6f100d4bb5083f8c35d96fd95a539811c62f245c", + "files": [ + { + "path": "certificates/selected-result.json", + "usage": "provenance", + "git_blob": "b1fea0c94436b236cc2b7d41a7be032811b94c81", + "sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "path": "docs/research/agent-task-catalog.json", + "usage": "provenance", + "git_blob": "67f085acd86acd7d4e03922d9cf4b26bca66fed5", + "sha256": "47b42433f5a85809a3aadd29c2c339da2c6ed728e4f7762df6b88bccb7874cf0" + }, + { + "path": "certificates/selected-result.json", + "usage": "input", + "git_blob": "b1fea0c94436b236cc2b7d41a7be032811b94c81", + "sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "path": "research/bit2234-stock-threshold/README.md", + "usage": "input", + "git_blob": "ede0d322c477af91d4c2cc33db0fd10958f45eab", + "sha256": "1e050c9f963421d751d9208092f9a15321ed77810e03912df8eb5eb56bbb06e7" + }, + { + "path": "research/community-frontier1094-audit/ASSEMBLY.json", + "usage": "input", + "git_blob": "5fd676df060f3b450782fdf5ff5f6beb63a5eeb0", + "sha256": "1122cb3a575f8c788345fc1bf4c108ac7c3250fb81a5988671f5eb04b3ab3045" + }, + { + "path": "research/community-hyperplane599-audit/pr589/bit589/v9/hosted/GLOBAL-TEMPLATE.json.gz", + "usage": "input", + "git_blob": "9eafb8776cbf78c72124f833534469ddfa5e98ec", + "sha256": "0357b7cfbd7c29b4983982baf153c8a9f1e1e412690cd7fa9fc3d23d7963b20f" + }, + { + "path": "research/community-hyperplane599-audit/pr589/bit589/v9/hosted/GLOBAL.json", + "usage": "input", + "git_blob": "1f648db9e63e7bfcaa6d5b1dd9fa6503caac47d2", + "sha256": "8de008a7978d4b7189cbec2470443619149a2b7b2f0f862540eeee4b23d3a819" + }, + { + "path": "research/community-hyperplane599-audit/pr589/bit589/v9/nine/GEOMETRY.json", + "usage": "input", + "git_blob": "44006542202ca6037533a754f0bcd00549d7e088", + "sha256": "0058c491d839142aa99ef86a5ec697ce99857632228531512ea3fa74fb24d734" + }, + { + "path": "research/e8-bit-p111-tuned/tune/EXPECTED.json", + "usage": "input", + "git_blob": "e293ddc557742637f9f679f083a1a282d87b1b13", + "sha256": "b9f0e5ca038abe837b0007c8fe006f366a6f02009244ac57705a8a200e2301f4" + }, + { + "path": "research/e8-bit-p111-tuned/tune/bitE8mut-p111-tuned.json.gz", + "usage": "input", + "git_blob": "85a4499bf9e4911a705d50567a2c2ef6cf23739a", + "sha256": "e3e301e62bc2b41dbf1ceac0acf3d35824ebeab1848c5a2142d4577b109da52f" + }, + { + "path": "research/idle-axis-hosting/PROOF.md", + "usage": "input", + "git_blob": "4468a00349b4f68dce103e785a8392099435e1d6", + "sha256": "cfe34bf0b64259661312dae22c3a23adc5bf6f6326951eee5c1488ccfc347542" + }, + { + "path": "research/pr589-five-helper-hosting/PROOF.md", + "usage": "input", + "git_blob": "bbd3f12b9a32b3ad3cba85a2d5a1b3054214fa02", + "sha256": "59cae781bfbe1a01ed9e66a8efeeb5a2b995e5ecdf908586b23ecc39f2b8d647" + }, + { + "path": "research/pr589-five-helper-hosting/verify.py", + "usage": "input", + "git_blob": "dbc71f56bb4205ebe378ada1f9f4ea88630d1d39", + "sha256": "cf90e19ae9991b0698be03d395a8cc29061ecb307eb7fea19adfb2d23c25a367" + }, + { + "path": "research/recursive-parking-boundary/README.md", + "usage": "input", + "git_blob": "251f335ebaccc11d69393ee7aeb5a2e84526d0bb", + "sha256": "491aa208391ee4c2936510b1a5c5c018dd5509d9a0e88687c72ab8406cd77b18" + }, + { + "path": "research/selected-bit-fast-primitives/check_caller.py", + "usage": "input", + "git_blob": "c3085e1d648ff2ba8d774d1739854306b84e5798", + "sha256": "75808ef9a1b65d620109717ab4af88598777a39cfc4d4bc2e42d3788233f029b" + }, + { + "path": "research/selected-bit-fast-primitives/check_catalogue.py", + "usage": "input", + "git_blob": "7368d63e1a7c54c29d622324e35f4115884adc10", + "sha256": "f7cc1c7907fd1877e310ba41904110a40e52f091ad38442ab2398c798afd3644" + }, + { + "path": "research/selected-bit-fast-primitives/check_complete.py", + "usage": "input", + "git_blob": "d4db3439979d347a1ab6a96b978c8d3dbfa5cb7e", + "sha256": "0751dd27a129823894cd7ade7ba73fcc84c825ecf5fcdd1fedac11ca08526d9d" + }, + { + "path": "research/selected-bit-fast-primitives/check_controls.py", + "usage": "input", + "git_blob": "bee3f603c989358b8e6169bd7770ebf9280b3a00", + "sha256": "d0b41aec46462f6b351935efdd8b200eb4de72fa2f8784cfa672fe3607711d91" + }, + { + "path": "research/selected-bit-fast-primitives/check_handoff.py", + "usage": "input", + "git_blob": "96051d7ca03bd38541d86289cdb6ec5fed98e707", + "sha256": "be1436e32bfad474330b69905aa6e4bfdb1a3538c295ace0f0ef96f40a34661a" + }, + { + "path": "research/selected-bit-fast-primitives/check_kernels.py", + "usage": "input", + "git_blob": "f4525ca47b90151f5461b01ed33ff80d64931ffe", + "sha256": "dd35d535e6986687bee112cef2003569252fc473acbce98f1a64b66e84083cc2" + }, + { + "path": "research/selected-bit-fast-primitives/check_outer.py", + "usage": "input", + "git_blob": "013b959cc9fc4a37f0c109cda4ffc37d639a5473", + "sha256": "b303f94091b1a09333532c57182808e5e049ad8b00dc77d491c664f5c5351ee3" + }, + { + "path": "research/selected-bit-fast-primitives/check_routes.py", + "usage": "input", + "git_blob": "0b05ab1e4de1e10fe651c72da883887cb44a643d", + "sha256": "28803eb270202e2742c713bf14ead47f44c8b5341a380c156bce7392ebed642d" + }, + { + "path": "research/selected-bit-fast-primitives/compile_routes.py", + "usage": "input", + "git_blob": "37263fdc327b4a300ccfaa0b7ad650012ab3d59c", + "sha256": "1bfef464dfb3e33d9d57f53b657b2d1fe3598bc453be49000a5e782b622e8585" + }, + { + "path": "research/selected-bit-fast-primitives/high_route.py", + "usage": "input", + "git_blob": "ec7481f890147be7763f4da729fd879a88a87e8e", + "sha256": "13d9c706e7bad2fa3b7d2a97d19b58f2c4efac06d2bb76b613b40069c38b1cd2" + }, + { + "path": "research/selected-bit-fast-primitives/inputs/pr2157.tar", + "usage": "input", + "git_blob": "9504807466071f56519f8663ccb532076a42a273", + "sha256": "db202c7b91b5b8b9340f96f870d54e275854f0b73839451c7c15bd7895ac3639" + }, + { + "path": "research/selected-bit-fast-primitives/inputs/pr2899.tar", + "usage": "input", + "git_blob": "e85ce82745879141e416ac6d9e3551ff959871aa", + "sha256": "fc4a2e07423835737c8fb3872664b16ff12aa4cf83b1e26e49878debef40c531" + }, + { + "path": "research/selected-bit-fast-primitives/kernels.py", + "usage": "input", + "git_blob": "de9fb08c35e92c8354ae622276866385fd07e3d2", + "sha256": "c4b91333817f7fcea44b1d32e01095cd71aeb673ed3608d2e25f4c06d56bb420" + }, + { + "path": "research/selected-bit-fast-primitives/stage.py", + "usage": "input", + "git_blob": "765ae9e11af3acb9458d7a1444a9e79112b72d96", + "sha256": "44e334162d12868ce6bb50c501cd2eba8c527f59ce7a144614edd8cd6f533647" + }, + { + "path": "research/selected-bit-fast-primitives/stage_sources.py", + "usage": "input", + "git_blob": "27383dd1553672f9c82139f80b628b2a094628d8", + "sha256": "55c6631cce4f76e14b66b6195468c36b544e2374cc6c59702135c664bff10822" + }, + { + "path": "research/selected-bit-fast-primitives/verify.py", + "usage": "input", + "git_blob": "a2f602c15cd413638116b4ea9bcffe613e4e3a7d", + "sha256": "90760db1526f73cfffc34eb8af3f2e5ec83f8f1015a780caa61d156f0d850c68" + }, + { + "path": "research/selected-bit-local-ring-sweeps/PROOF.md", + "usage": "input", + "git_blob": "4330de85dd9862ed15d84ab917887d249753df99", + "sha256": "846c59440cc99e28bae93ad2af99525bc769de29368080071b8427141215b4f7" + }, + { + "path": "research/selected-bit-recursive-closure/PROOF.md", + "usage": "input", + "git_blob": "6c410cab5713979214a45835091fbeb9ee9b8531", + "sha256": "74cc8de20f21acb5123fe2d20996fe0925ea6e51b3dec633bd5221fb719b3344" + }, + { + "path": "upstream/build/sections/02-streams.tex", + "usage": "input", + "git_blob": "088fceea1867abc76271d7efe7532b779fee9039", + "sha256": "606c80db61cad13aa0c3b6060dc4b88dbbe7ac60cdd831aa93f28d908fd09dab" + }, + { + "path": "research/high-route-permutation-frames/check_physical.py", + "usage": "provenance", + "git_blob": "85d4501b8fcc5df5b7d02d4958b4f1e3381c857e", + "sha256": "96911c5a55387bed6d252c1ac39f55b65da5c65c52e8fea327288b259b7b2c0b" + } + ], + "predecessors": [ + { + "pr": 2915, + "head": "fecc5a87574df441ddc3dad44f99fca9bd7fdd92", + "author": "Jose Manuel (jmbarrancoml)", + "scope": "reached executor and selected registry; main includes the documented catalogue cache adaptation" + }, + { + "pr": 2899, + "head": "2f0911ad735643a069b9790302fbf179e49f74f8", + "author": "Jose Manuel (jmbarrancoml)", + "scope": "B1 in the authenticated PR2915 archive" + }, + { + "pr": 3330, + "head": "aa14cb3a57a6170f645f13d140543b941227fca9", + "author": "Tekalign (tekuuu)", + "scope": "reused complete-route physical observer; schedule itself is unchanged and unused" + } + ] +} diff --git a/research/high-carry-streams/TASK.json b/research/high-carry-streams/TASK.json new file mode 100644 index 0000000000..752a189329 --- /dev/null +++ b/research/high-carry-streams/TASK.json @@ -0,0 +1,75 @@ +{ + "schema_version": 1, + "task_id": "bit-helper-contract", + "priority_revision": 6, + "base_commit": "6f100d4bb5083f8c35d96fd95a539811c62f245c", + "original_card": { + "id": "bit-helper-contract", + "question": "Can one precisely specified helper-mixing word satisfy a replacement for the inherited H2/K interface?", + "starting_points": [ + "docs/research/research-family-status.md", + "research/r439-bsection-stars-seed01/README.md", + "research/r439-copy-path-sharing-barrier/README.md" + ], + "methods": [ + "Derive a replacement interface lemma and price its implementation.", + "Seek an exact dirty-input or chronological-cut counterexample to the proposed replacement." + ], + "acceptance_gate": "A full boundary contract and paid profile; unchanged scalar counts alone are insufficient. A scoped local result may be retained without a complete supplier. Expanding it into further construction rounds requires the family-level budget and obligation gate in research-family-status.md; an optimistic passing relaxation alone is not acceptance.", + "first_step": { + "command": [ + "python3", + "-B", + "research/r439-bsection-stars-seed01/verify.py" + ], + "expected": "PASS_R439_BSECTION_STARS", + "inspect": "Compare the two false H2/K flags with the unchanged paid profile in its README.", + "scope": "Positive control / source-bound orientation only; this is not a new construction or full cold replay." + }, + "first_experiment": "Write one replacement H2/K implication for a single helper-star operation, then try to falsify it on dirty inputs.", + "bottleneck_link": "A legitimate replacement could admit a cheaper bit circuit; scalar savings alone do not alter the selected moment.", + "allowed_variations": [ + "Choose one helper-star or quartet instance; narrow to one boundary implication." + ], + "scope_change_triggers": [ + "Changing only source count or scalar addition count without an interface argument." + ], + "overlap_terms": [ + "H2_D_frame0_targets_from_helpers", + "K_equals_D", + "helper-star" + ] + }, + "scope_status": "changed", + "actual_scope": "Direct encoded signed carry rotation in the reached PR2915 BIT high route, with complete ownership, traffic and cleanup accounting.", + "scope_change_reason": "OS seed 6 assigns the Bit supplier track. The current route implementation exposes a distinct repeated sign/shift/sign expense; the fitted-B1 audit is separately claimed. This changes a reached implementation rather than the generic helper-star card.", + "bottleneck_link": "Remove repeated whole-field passes from the reached route without changing its map, recursive native calls or paid profile.", + "budget_minutes": 60, + "stop_rule": "One direct signed carry implementation; 96 complete kernel pairs, seven route pairs, fixed q=3 identity-low catalogue census, split identities and controls. No search for a new supplier.", + "outcome": "completed", + "evidence": "PROOF.md, RESULT.json, KERNEL.json, ROUTES.json, CATALOGUE.json and registered replay.", + "author": "Tekalign (tekuuu), with substantial OpenAI Codex assistance", + "ai_assistance": "Substantial OpenAI Codex assistance in derivation, implementation, source inspection, verification and writing; no independent human review or proof-assistant verification.", + "open_questions": [ + { + "question": "Can adjacent dyadic scale and carry operations be completed with fewer complete stream passes?", + "why_it_matters": "The present change eliminates repeated carry passes but preserves every scalar factor.", + "first_step": "Pin one reached scalar/carry pair and derive its complete prefix/suffix permutation and ownership budget before implementation.", + "blocked_by": "a complete bounded bucket/scratch and physical-cost proof" + }, + { + "question": "Should the opt-in adapter be adopted by an enclosing selected caller?", + "why_it_matters": "Component correctness and faster fixtures do not establish the full physical supplier.", + "first_step": "Independently review the source proof, then join its eight-role inventory and actual encoded width to the enclosing reserve.", + "blocked_by": "enclosing stock/backing, native refinement and independent admission review" + } + ], + "assignment_seed": 6, + "assignment_rng": "secrets.randbelow(100), operating-system randomness, drawn once on 2026-10-17", + "candidate_tasks": [ + "Direct signed carry streams.", + "Remove the initial high-cube copy using borrowed/owned lifetime tracking.", + "Fuse dyadic scale/carry factors." + ], + "coordination": "https://github.com/CrocSwap/integer-mult-bounds/discussions/2319#discussioncomment-19007093" +} diff --git a/research/high-carry-streams/VALIDATION.md b/research/high-carry-streams/VALIDATION.md new file mode 100644 index 0000000000..b796e1dae3 --- /dev/null +++ b/research/high-carry-streams/VALIDATION.md @@ -0,0 +1,40 @@ +# Validation + +Implementation and receipt freeze: `8376965a54f12604c23c45ca458d606d1c1f6f28`. +The complete registered CPython 3.12.14 replay passed at this commit. The +publication amendment changes only this validation record. +Base: 6f100d4bb5083f8c35d96fd95a539811c62f245c. Priority revision 6, seed 6. + +The author ran the complete kernel, route, catalogue and optimized control +suites with CPython 3.12.14 on Linux. The same-input benchmark uses that runtime +and three alternating fresh-process pairs. See BENCHMARK.json for every sample. +No formal kernel, independent human review, selected cold replay, whole-machine +execution or new κ is claimed. + +Overlap metadata at entry covered 249 open PRs, 2,761 closed/merged PRs and +2,171 Discussion records with complete pagination. A later refresh covered 256 +open PRs and the latest #2319 replies; main was unchanged. PR3340 addresses the +separate fitted native bridge. These metadata checks do not cover unpublished +work or every code diff. The only open issue remained #913's clarity concern. + +## Committed verification + +- All four registered suites pass, including the 1,123-chart catalogue census + and optimized controls; no artifact generation occurs during verification. +- A read-only Git-free export of all 51 package/input files passes the optimized + CPython 3.14.7 control suite and all 96 complete kernel comparisons. Every + exported byte matches the scientific commit. +- An AST comparison verifies that the adapted execute function is identical + to PR2915 except for the intended dispatch name. This was a separate local + check, not a formal proof or a registered additional suite. +- `git diff --check` passes. Runtime constructors and numerical inspection are + forbidden inside the physical fixtures. Counter traffic and source-column + provenance are observed together, without replacing the semantic observer. + +The registered comparison covers 6,624 independent kernel columns and 8,893 +complete-route columns. The opt-in path has no measured I/O regression in the +96 retained pairs; that finite observation is not a universal timing theorem. +The direct negative-carry cases use 66.8–95.1% less physical I/O in these inputs. + +The source/archive merge and hosted CI remain separate from scientific admission. +Hosted CI status is reported in the PR rather than inferred from local success. diff --git a/research/high-carry-streams/VERIFY.json b/research/high-carry-streams/VERIFY.json new file mode 100644 index 0000000000..efed187208 --- /dev/null +++ b/research/high-carry-streams/VERIFY.json @@ -0,0 +1,90 @@ +{ + "schema_version": 1, + "status": "ready", + "python": "3.12", + "requirements": [], + "inputs": [ + "certificates/selected-result.json", + "research/bit2234-stock-threshold/README.md", + "research/community-frontier1094-audit/ASSEMBLY.json", + "research/community-hyperplane599-audit/pr589/bit589/v9/hosted/GLOBAL-TEMPLATE.json.gz", + "research/community-hyperplane599-audit/pr589/bit589/v9/hosted/GLOBAL.json", + "research/community-hyperplane599-audit/pr589/bit589/v9/nine/GEOMETRY.json", + "research/e8-bit-p111-tuned/tune/EXPECTED.json", + "research/e8-bit-p111-tuned/tune/bitE8mut-p111-tuned.json.gz", + "research/idle-axis-hosting/PROOF.md", + "research/pr589-five-helper-hosting/PROOF.md", + "research/pr589-five-helper-hosting/verify.py", + "research/recursive-parking-boundary/README.md", + "research/selected-bit-fast-primitives/check_caller.py", + "research/selected-bit-fast-primitives/check_catalogue.py", + "research/selected-bit-fast-primitives/check_complete.py", + "research/selected-bit-fast-primitives/check_controls.py", + "research/selected-bit-fast-primitives/check_handoff.py", + "research/selected-bit-fast-primitives/check_kernels.py", + "research/selected-bit-fast-primitives/check_outer.py", + "research/selected-bit-fast-primitives/check_routes.py", + "research/selected-bit-fast-primitives/compile_routes.py", + "research/selected-bit-fast-primitives/high_route.py", + "research/selected-bit-fast-primitives/inputs/pr2157.tar", + "research/selected-bit-fast-primitives/inputs/pr2899.tar", + "research/selected-bit-fast-primitives/kernels.py", + "research/selected-bit-fast-primitives/stage.py", + "research/selected-bit-fast-primitives/stage_sources.py", + "research/selected-bit-fast-primitives/verify.py", + "research/selected-bit-local-ring-sweeps/PROOF.md", + "research/selected-bit-recursive-closure/PROOF.md", + "upstream/build/sections/02-streams.tex" + ], + "commands": [ + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/verify.py", + "--suite", + "kernel" + ], + "timeout_seconds": 120, + "checks": "96 complete signed-carry baseline/candidate pairs with exact columns, borrowed and dirty state, scratch and all physical I/O" + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/verify.py", + "--suite", + "routes" + ], + "timeout_seconds": 180, + "checks": "Seven complete PR2915 routes through the opt-in adapter with independent columns and every native interval retained" + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/verify.py", + "--suite", + "catalogue" + ], + "timeout_seconds": 600, + "checks": "Actual 1123 chart source specialization at q=3 identity low class; exact weighted carry exposure" + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "-O", + "{package}/verify.py", + "--suite", + "controls" + ], + "timeout_seconds": 30, + "checks": "2056 exact split identities, invalid/extra input, wrong sign including all-zero payload, one-role-short, extra-traffic and source-corruption controls" + } + ] +} diff --git a/research/high-carry-streams/adapter.py b/research/high-carry-streams/adapter.py new file mode 100644 index 0000000000..5584ff973a --- /dev/null +++ b/research/high-carry-streams/adapter.py @@ -0,0 +1,69 @@ +"""Opt-in adapter. Execute lifecycle retained from Jose Manuel, PR2915. + +Apache-2.0. The only changed dispatch is the bounded carry kernel. +""" +import bindings +bindings.activate() +from cardinal_counts import Count +from high_route import apply, extents +from routes import copy_rows +from session import initialize_marker +from words import BLANK, Ring, need +from stage import Adapter +from rotation import translated + + +def apply_carry(source, operation, route, ring, modulus, fibre, adapter, factory): + if operation[0] != "translate" or operation[2] == 1: + return apply(source, operation, route, ring, modulus, fibre, adapter, factory) + before, suffix = extents(modulus, fibre, route.dimension, operation[1]) + try: + return translated(source, ring, before, suffix, operation[2], factory) + finally: + before.close() + suffix.close() + + +def execute(source, route, context, fibre, adapter, factory): + need((route.q, route.dimension) == (context.q, context.dimension), "route/context binding") + operations = adapter.registry.compile(route) + current = factory() + source.rewind() + ring = modulus_word = None + modulus = Count(context.cap) + bank = adapter.high_bank + try: + copy_rows(source, current, context.highs, fibre) + need(source.read() == BLANK, "complete source high cube") + source.rewind() + current.rewind() + if context.raw.compare(context.cap, context.ring.one) > 0: + for word in (*bank.words, bank.template): + initialize_marker(word.tape) + bank.prepare(modulus) + modulus_word = bank.load(modulus) + ring = Ring(modulus_word) + for operation in operations: + following = apply_carry(current, operation, route, ring, modulus, fibre, adapter, factory) + current.clear() + current = following + result, current = current, None + return result + finally: + source.rewind() + if current is not None: + current.clear() + if ring is not None: + ring.close() + bank.free(modulus_word) + bank.erase_owned() + modulus.close() + + +class CarryAdapter(Adapter): + def route_cube(self, source, route, context, fibre, factory=None): + need(not self.in_base and self.scope is not None, "successor route stage") + result = execute(source, route, context, fibre, self, + self.scope.acquire if factory is None else factory) + self.calls["cubes"] += 1 + return result diff --git a/research/high-carry-streams/benchmark.py b/research/high-carry-streams/benchmark.py new file mode 100644 index 0000000000..4280ff4958 --- /dev/null +++ b/research/high-carry-streams/benchmark.py @@ -0,0 +1,53 @@ +"""Alternating fresh-process comparisons; exact results remain checked.""" +import argparse +import json +from pathlib import Path +import statistics +import subprocess +import sys +from time import perf_counter +HERE=Path(__file__).resolve().parent +sys.path.insert(0,str(HERE)) + + +def worker(kind,optimized): + if kind=='kernel': + from check_kernel import one_case + result,elapsed=one_case(81,2,3,-4,optimized) + else: + # Explicit loading avoids the predecessor's equally named check_routes. + import importlib.util + spec=importlib.util.spec_from_file_location('carry_benchmark_routes',HERE/'check_routes.py') + module=importlib.util.module_from_spec(spec);spec.loader.exec_module(module) + result,elapsed=module.run_case(module.cases()[0],optimized) + print(json.dumps(dict(result=result,seconds=elapsed))) + + +def main(): + parser=argparse.ArgumentParser() + parser.add_argument('--worker',choices=('kernel','route')) + parser.add_argument('--optimized',action='store_true') + parser.add_argument('--repeats',type=int,default=3) + args=parser.parse_args() + if args.worker:return worker(args.worker,args.optimized) + rows=[] + for kind in ('kernel','route'): + for repeat in range(args.repeats): + for opt in ((False,True) if repeat%2==0 else (True,False)): + command=[sys.executable,'-I','-B',str(Path(__file__).resolve()),'--worker',kind] + if opt:command.append('--optimized') + start=perf_counter() + output=subprocess.check_output(command,text=True) + row=json.loads(output);row.update(kind=kind,optimized=opt,repeat=repeat,process_seconds=perf_counter()-start) + rows.append(row) + summary={} + for kind in ('kernel','route'): + summary[kind]={} + for field in ('seconds','process_seconds'): + medians=[statistics.median(row[field] for row in rows if row['kind']==kind and row['optimized']==opt) + for opt in (False,True)] + summary[kind][field]=dict(before=medians[0],after=medians[1],speedup=medians[0]/medians[1]) + print(json.dumps(dict(python=sys.version,rows=rows,summary=summary),indent=2,sort_keys=True)) + + +if __name__=='__main__':main() diff --git a/research/high-carry-streams/bindings.py b/research/high-carry-streams/bindings.py new file mode 100644 index 0000000000..19391eb1e6 --- /dev/null +++ b/research/high-carry-streams/bindings.py @@ -0,0 +1,40 @@ +"""Authenticate every declared executable/archive before predecessor imports.""" +from hashlib import sha256 +import json +from pathlib import Path +import sys + +HERE = Path(__file__).resolve().parent +ROOT = HERE.parents[1] + + +def authenticate(root=ROOT, package=HERE): + manifest = json.loads((HERE / "SOURCES.json").read_text()) + for row in manifest["files"]: + if row["usage"] == "input": + data = (root / row["path"]).read_bytes() + if sha256(data).hexdigest() != row["sha256"]: + raise ValueError("source changed: " + row["path"]) + for row in manifest.get("external_proofs", []): + if sha256((package/row["path"]).read_bytes()).hexdigest() != row["sha256"]: + raise ValueError("inherited proof changed: " + row["path"]) + + +def activate(): + authenticate() + path = ROOT / "research/selected-bit-fast-primitives" + sys.path.insert(0, str(path)) + # This module is deliberately not named 'source' when imported: the + # unchanged archive loader reserves that name for its own predecessor. + import stage_sources + return stage_sources.activate() + + +def route_checks(): + import importlib.util + activate() + path = ROOT / "research/selected-bit-fast-primitives/check_routes.py" + spec = importlib.util.spec_from_file_location("carry_source_route_checks", path) + result = importlib.util.module_from_spec(spec) + spec.loader.exec_module(result) + return result diff --git a/research/high-carry-streams/check_catalogue.py b/research/high-carry-streams/check_catalogue.py new file mode 100644 index 0000000000..666b3014ff --- /dev/null +++ b/research/high-carry-streams/check_catalogue.py @@ -0,0 +1,53 @@ +"""Carry exposure in the actual selected registry at identity low class, q=3. + +This is a finite source specialization, not a selected GL64 payload execution +or a distribution over every low class. Occurrence weights are source weights. +""" +from collections import Counter +from fractions import Fraction as F +from hashlib import sha256 +import json +from unittest.mock import patch + +import bindings + + +def run(): + _source,retained,data=bindings.activate() + from catalogue import Catalogue + from compile_routes import selected_registry,matrix_key,inverse_word + from routes import Route + from words import need + names=(retained.GEOMETRY,retained.TEMPLATE,retained.GLOBAL,retained.WORD,retained.EXPECTED,retained.ASSEMBLY) + routes,source_receipt=retained.compile_catalog({name:data[name] for name in names}) + catalogue=Catalogue(3) + matrix=type(catalogue).chart_matrix.__wrapped__ + with patch.object(catalogue,'chart_matrix',lambda chart:matrix(catalogue,chart)): + registry,binding_receipt=selected_registry(catalogue) + identity=tuple(tuple(int(i==j) for j in range(64)) for i in range(64)) + histograms={} + digest=sha256() + for chart in sorted(registry.words,key=repr): + target=tuple(tuple(v.numerator*pow(v.denominator,-1,3)%3 for v in row) for row in chart) + route=Route(3,64,identity,target,chart) + operations=registry.compile(route) + carries=Counter(op[2] for op in operations if op[0]=='translate') + need(all(type(a) is int and 00 else -3*a) for a,count in total.items()) + after=sum(total.values()) + need(before>after,'nontrivial selected carry exposure') + return dict(q=3,low='identity',chart_types=len(routes),registry_matrices=len(registry.words), + orientations=2*len(routes),weighted_carries={str(k):v for k,v in sorted(total.items())}, + weighted_old_full_field_primitive_calls=before,weighted_new_kernel_calls=after, + saved_primitive_calls=before-after,operations_sha256=digest.hexdigest(), + source_catalogue_sha256=source_receipt['catalogue_sha256'], + bound_source_types=binding_receipt['source_types']) diff --git a/research/high-carry-streams/check_controls.py b/research/high-carry-streams/check_controls.py new file mode 100644 index 0000000000..bdb641c7be --- /dev/null +++ b/research/high-carry-streams/check_controls.py @@ -0,0 +1,76 @@ +"""Small independent identities and rejection tests, also run under -O.""" +from pathlib import Path +from tempfile import TemporaryDirectory +from unittest.mock import patch +import json + +import bindings +bindings.activate() +from cardinal_counts import Count +from words import need +from check_kernel import one_case +import rotation + + +def reject(call, fragment): + try: + call() + except ValueError as error: + need(fragment in str(error), "intended control rejection: " + str(error)) + return + raise ValueError("mutation unexpectedly accepted: " + fragment) + + +def split_checks(): + total=0 + for q in range(1,258): + modulus=Count.literal(q) + for amount in (-4,-3,-2,-1,1,2,3,4): + large,small=rotation.split_lengths(modulus,amount) + def value(count): + bits=count.tape.cells[1:] + digits=[] + for bit in bits: + if bit not in (0,1):break + digits.append(bit) + return sum(bit<= paid_native, "nonoverlapping paid intervals") + result.update(physical=counts, native=native, total=total, + outside_native=total-paid_native, dirty_roles=3) + return result, sum(elapsed) + + +def cases(): + word = (("add",0,1,F(1,2)), ("scale",1,1,F(-2)), ("swap",0,1,F(1))) + dense = (("add",0,1,F(-4)), ("scale",1,1,F(-1,2)), + ("add",0,1,F(1,2)), ("add",1,0,F(2)), ("swap",0,1,F(1))) + return [ + dict(q=3,width=2,low=((2,1),(1,1)),word=(("scale",0,0,F(-4)),), + old_prefixes=2,fibre_value=3), + dict(q=3,width=2,low=((1,2),(2,2)),word=(("add",0,1,F(1)),)*9, + old_prefixes=2,fibre_value=3), + dict(q=3,width=2,low=((1,2),(2,2)),word=word,old_prefixes=2,fibre_value=3), + dict(q=5,width=2,low=((1,4),(2,1)),word=word,old_prefixes=1,fibre_value=1), + dict(q=3,width=1,low=((1,2),(2,2)),word=dense,old_prefixes=2,fibre_value=3), + dict(q=3,width=3,low=((2,1),(1,1)),word=word,old_prefixes=1,fibre_value=1), + dict(q=3,width=2,low=((2,1),(1,1)),word=dense,old_prefixes=1,fibre_value=3), + ] + + +def run(): + results = [] + for index, case in enumerate(cases()): + before, _ = run_case(case, False) + after, _ = run_case(case, True) + need(before["columns"] == after["columns"], "same complete input") + need(after["calls"] == before["calls"], "unchanged complete route native call bill") + results.append(dict(case=index, before=before, after=after)) + need(results[0]["after"]["total"] < results[0]["before"]["total"], + "physical saving on compiled signed scale/carry fixture") + return results diff --git a/research/high-carry-streams/rotation.py b/research/high-carry-streams/rotation.py new file mode 100644 index 0000000000..12d84ff8cc --- /dev/null +++ b/research/high-carry-streams/rotation.py @@ -0,0 +1,98 @@ +"""Encoded bounded cyclic rotation with complete spectator blocks. + +Tekalign, with substantial OpenAI Codex assistance. Apache-2.0. +Uses the authenticated PR2915/PR2753 Count, Counter and copy operations. +No host integer is reconstructed from a tape. +""" +import bindings +bindings.activate() +from cardinal_counts import Count, positive +from routes import copy_rows +from stream import Counter +from words import BLANK, need + + +def split_lengths(modulus, amount): + """Return Q-r,r where r=abs(amount) mod Q, using at most four decrements.""" + need(type(amount) is int and 0 < abs(amount) <= 4, "fixed selected carry") + positive(modulus) + remaining = Counter(modulus) + small = Count.literal(0) + try: + for _ in range(abs(amount)): + remaining.decrement() + small.increment() + if remaining.finished: + remaining.close() + small.close() + remaining = Counter(modulus) + small = Count.literal(0) + large = Count(remaining.tape) + result, small = (large, small), None + return result + finally: + remaining.close() + if small is not None: + small.close() + + +def translated(source, ring, before, suffix, amount, factory): + """Borrow B*Q*S bits, return a distinct owned x -> x+amount mod Q cube.""" + need(type(amount) is int and 0 < abs(amount) <= 4, "fixed selected carry") + positive(before) + positive(suffix) + modulus = Count(ring.modulus) + large = small = left = right = output = None + try: + large, small = split_lengths(modulus, amount) + modulus.close() + modulus = None + output = factory() + if small.zero(): + outer = Counter(before) + try: + while not outer.finished: + copy_rows(source, output, large, suffix) + outer.decrement() + finally: + outer.close() + else: + left = factory() + right = factory() + first, second = (large, small) if amount > 0 else (small, large) + outer = Counter(before) + try: + while not outer.finished: + copy_rows(source, left, first, suffix) + copy_rows(source, right, second, suffix) + outer.decrement() + finally: + outer.close() + need(source.read() == BLANK, "complete rotation input") + source.rewind() + left.rewind() + right.rewind() + outer = Counter(before) + try: + while not outer.finished: + copy_rows(right, output, second, suffix) + copy_rows(left, output, first, suffix) + outer.decrement() + finally: + outer.close() + need(left.read() == right.read() == BLANK, "complete rotation buckets") + # The general path already rewound its source. Check the identity path + # at its actual end; never infer completeness from a known bit count. + if small.zero(): + need(source.read() == BLANK, "complete identity rotation source") + output.rewind() + result, output = output, None + return result + finally: + source.rewind() + for value in (left, right, output): + if value is not None: + value.clear() + for value in (large, small, modulus): + if value is not None: + value.close() diff --git a/research/high-carry-streams/verify.py b/research/high-carry-streams/verify.py new file mode 100644 index 0000000000..39fa67b367 --- /dev/null +++ b/research/high-carry-streams/verify.py @@ -0,0 +1,40 @@ +"""Read-only registered replay of complete typed receipts.""" +import argparse +from hashlib import sha256 +import importlib.util +import json +from pathlib import Path +import sys +HERE=Path(__file__).resolve().parent +sys.path.insert(0,str(HERE)) + + +def canonical(value): + return json.dumps(value,sort_keys=True,separators=(',',':'),allow_nan=False) + + +def main(): + parser=argparse.ArgumentParser() + parser.add_argument('--suite',required=True,choices=('kernel','routes','catalogue','controls')) + parser.add_argument('--emit',action='store_true') + args=parser.parse_args() + import bindings + bindings.authenticate() + # The predecessor loader places its packages first in sys.path. Load our + # checker by explicit path to keep similarly named frozen checkers distinct. + spec=importlib.util.spec_from_file_location('carry_check_'+args.suite,HERE/('check_'+args.suite+'.py')) + check=importlib.util.module_from_spec(spec);spec.loader.exec_module(check) + result=check.run() + digest=sha256(canonical(result).encode()).hexdigest() + if args.emit:print(canonical(result)) + else: + expected=json.loads((HERE/'RESULT.json').read_text()) + if digest!=expected[args.suite]:raise ValueError('complete typed receipt differs: '+args.suite) + if args.suite!='controls': + saved=json.loads((HERE/(args.suite.upper()+'.json')).read_text()) + if canonical(result)!=canonical(saved):raise ValueError('saved full receipt differs: '+args.suite) + print(canonical(dict(suite=args.suite,sha256=digest,cases=len(result)))) + print('PASS_HIGH_CARRY_'+args.suite.upper()) + + +if __name__=='__main__':main()