qvm: model transform records
Browse files- docs/ASSET_PIPELINE_TODO.md +3 -0
- docs/FINDINGS.md +3 -0
- docs/PROVISIONAL_TODO.md +3 -0
- docs/RESEARCH_LEDGER.md +5 -0
- docs/REVERSE_ENGINEERING_TODO.md +3 -0
- docs/research/QVM_MODEL_TRANSFORMS.md +7 -0
- docs/research/README.md +3 -0
- docs/research/qvm-model-transforms.json +0 -0
- scripts/analyze_qvm_model_transforms.py +37 -0
- scripts/test_qvm_model_transforms.py +27 -0
docs/ASSET_PIPELINE_TODO.md
CHANGED
|
@@ -646,3 +646,6 @@ Research progress: RE-654 [report](research/QVM_SWING_CONTROLLER.md); remaining
|
|
| 646 |
|
| 647 |
|
| 648 |
Research progress: RE-655 [report](research/QVM_HIT_PUBLICATION.md); remaining native/content/runtime/platform scope stays open.
|
|
|
|
|
|
|
|
|
|
|
|
| 646 |
|
| 647 |
|
| 648 |
Research progress: RE-655 [report](research/QVM_HIT_PUBLICATION.md); remaining native/content/runtime/platform scope stays open.
|
| 649 |
+
|
| 650 |
+
|
| 651 |
+
Research progress: RE-656 [report](research/QVM_MODEL_TRANSFORMS.md); remaining native/content/runtime/platform scope stays open.
|
docs/FINDINGS.md
CHANGED
|
@@ -992,3 +992,6 @@ Bounded qagame paths recover bomb-plant/inactivity correction requests, direct f
|
|
| 992 |
|
| 993 |
|
| 994 |
**RE-655 — Hit-record ordering and trace publication:** 25835 stably sorts five-word records by float key then prioritizes type3 over a leading5/6;146582 publishes context vectors and target ID only for nonzero count. [Evidence](research/QVM_HIT_PUBLICATION.md).
|
|
|
|
|
|
|
|
|
|
|
|
| 992 |
|
| 993 |
|
| 994 |
**RE-655 — Hit-record ordering and trace publication:** 25835 stably sorts five-word records by float key then prioritizes type3 over a leading5/6;146582 publishes context vectors and target ID only for nonzero count. [Evidence](research/QVM_HIT_PUBLICATION.md).
|
| 995 |
+
|
| 996 |
+
|
| 997 |
+
**RE-656 — Model-hit transform record construction:** 144985 constructs four88-byte records from three supplied pose triplets, client fields and one target translation before requesting25341. [Evidence](research/QVM_MODEL_TRANSFORMS.md).
|
docs/PROVISIONAL_TODO.md
CHANGED
|
@@ -966,3 +966,6 @@ Research progress: RE-654 [report](research/QVM_SWING_CONTROLLER.md); remaining
|
|
| 966 |
|
| 967 |
|
| 968 |
Research progress: RE-655 [report](research/QVM_HIT_PUBLICATION.md); remaining native/content/runtime/platform scope stays open.
|
|
|
|
|
|
|
|
|
|
|
|
| 966 |
|
| 967 |
|
| 968 |
Research progress: RE-655 [report](research/QVM_HIT_PUBLICATION.md); remaining native/content/runtime/platform scope stays open.
|
| 969 |
+
|
| 970 |
+
|
| 971 |
+
Research progress: RE-656 [report](research/QVM_MODEL_TRANSFORMS.md); remaining native/content/runtime/platform scope stays open.
|
docs/RESEARCH_LEDGER.md
CHANGED
|
@@ -942,3 +942,8 @@ Complete279820 updates attacker/victim hit/location/value counters;33715 enables
|
|
| 942 |
## 2026-10-20 — RE-655 Hit-record ordering and trace publication (separate task commit)
|
| 943 |
|
| 944 |
25835 stably sorts five-word records by float key then prioritizes type3 over a leading5/6;146582 publishes context vectors and target ID only for nonzero count. 18 supplied geometry fixtures independently check whole-record stability, priority swaps, exact trace writes and empty preservation. Full suite: 1088 tests pass. Report regenerates byte-identically (36771 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 942 |
## 2026-10-20 — RE-655 Hit-record ordering and trace publication (separate task commit)
|
| 943 |
|
| 944 |
25835 stably sorts five-word records by float key then prioritizes type3 over a leading5/6;146582 publishes context vectors and target ID only for nonzero count. 18 supplied geometry fixtures independently check whole-record stability, priority swaps, exact trace writes and empty preservation. Full suite: 1088 tests pass. Report regenerates byte-identically (36771 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
| 945 |
+
|
| 946 |
+
|
| 947 |
+
## 2026-10-20 — RE-656 Model-hit transform record construction (separate task commit)
|
| 948 |
+
|
| 949 |
+
144985 constructs four88-byte records from three supplied pose triplets, client fields and one target translation before requesting25341. 24 selector/pose/origin fixtures independently check all88 bytes of every record and exact22-call zero-fill/trig ordering. Full suite: 1092 tests pass. Report regenerates byte-identically (335368 bytes). Storage/filter, links and whitespace checks pass. No assets/Rust runtime/shared VM evaluator changed; native/reference/legal/full platform scope remains open.
|
docs/REVERSE_ENGINEERING_TODO.md
CHANGED
|
@@ -1009,3 +1009,6 @@ Purpose: turn the supplied installation into an evidence-backed specification of
|
|
| 1009 |
|
| 1010 |
|
| 1011 |
- [x] RE-655 Hit-record ordering and trace publication ([report](research/QVM_HIT_PUBLICATION.md)).
|
|
|
|
|
|
|
|
|
|
|
|
| 1009 |
|
| 1010 |
|
| 1011 |
- [x] RE-655 Hit-record ordering and trace publication ([report](research/QVM_HIT_PUBLICATION.md)).
|
| 1012 |
+
|
| 1013 |
+
|
| 1014 |
+
- [x] RE-656 Model-hit transform record construction ([report](research/QVM_MODEL_TRANSFORMS.md)).
|
docs/research/QVM_MODEL_TRANSFORMS.md
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Model-hit transform record construction
|
| 2 |
+
|
| 3 |
+
RE-656. Reproduce with `python3 scripts/analyze_qvm_model_transforms.py`; check with `python3 scripts/test_qvm_model_transforms.py`. The [machine report](qvm-model-transforms.json) retains source identity and bounded fixtures.
|
| 4 |
+
|
| 5 |
+
Actual144985–146550 selects four pointers from a16-byte-stride table, zero-fills each88-byte record, builds three float32 bases and copies the third basis to both last records. Basis vectors occupy12/28/44; the middle vector is zero minus the recovered right vector. Offset72 is float1, while60/64/68 and interleaved padding remain zero. Only the first record receives target+24 translation at76/80/84. First-record words0/4/8 copy client6196/6204/6212; second-record words0/4/8 copy6248/6256/6264. No extra translations are composed in this slice. Four explicit bounded native zero-fill models and18 finite sin/cos models execute; original library bit parity remains unverified. Pose triplets are supplied fixtures because32254 is incomplete. The slice stops before25341 intersection and asserts no successful geometry or model identity.
|
| 6 |
+
|
| 7 |
+
No original executable/full QVM/native collision/physics/rendering executes. Native responses and legal input domains are supplied or unverified where stated; full runtime/macOS/Linux Rust/Bevy/Solari gameplay remains open.
|
docs/research/README.md
CHANGED
|
@@ -567,3 +567,6 @@ The extension collector adds five focused tests for native tail calls, command-r
|
|
| 567 |
|
| 568 |
|
| 569 |
[RE-655: Hit-record ordering and trace publication](QVM_HIT_PUBLICATION.md). Reproduce with `python3 scripts/analyze_qvm_hit_publication.py`; check with `python3 scripts/test_qvm_hit_publication.py`.
|
|
|
|
|
|
|
|
|
|
|
|
| 567 |
|
| 568 |
|
| 569 |
[RE-655: Hit-record ordering and trace publication](QVM_HIT_PUBLICATION.md). Reproduce with `python3 scripts/analyze_qvm_hit_publication.py`; check with `python3 scripts/test_qvm_hit_publication.py`.
|
| 570 |
+
|
| 571 |
+
|
| 572 |
+
[RE-656: Model-hit transform record construction](QVM_MODEL_TRANSFORMS.md). Reproduce with `python3 scripts/analyze_qvm_model_transforms.py`; check with `python3 scripts/test_qvm_model_transforms.py`.
|
docs/research/qvm-model-transforms.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
scripts/analyze_qvm_model_transforms.py
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
"""144766 transform records from explicit supplied pose outputs, before25341."""
|
| 3 |
+
import itertools
|
| 4 |
+
from pathlib import Path
|
| 5 |
+
from qvm_research_support import source,execute,constants
|
| 6 |
+
from qvm_shot_math_support import TRIG
|
| 7 |
+
from analyze_qvm_acceleration import word
|
| 8 |
+
from analyze_qvm import write_json
|
| 9 |
+
LOCAL=0x78040000
|
| 10 |
+
TARGET=0x78081000
|
| 11 |
+
CLIENT=0x78082000
|
| 12 |
+
BUFFERS=[0x78083000+256*j for j in range(4)]
|
| 13 |
+
TABLES=[35023864,35023860,35023868,35023872]
|
| 14 |
+
|
| 15 |
+
def transform(ins,m,selector,angles,origin):
|
| 16 |
+
m=dict(m);m[LOCAL+196]=selector;m[LOCAL+212]=TARGET;m[TARGET+520]=CLIENT
|
| 17 |
+
for j,triplet in enumerate(angles):
|
| 18 |
+
for k,v in enumerate(triplet):m[LOCAL+52+12*j+4*k]=word(v)
|
| 19 |
+
for j,v in enumerate(origin):m[TARGET+24+4*j]=word(v)
|
| 20 |
+
fields=[6196,6204,6212,6248,6256,6264]
|
| 21 |
+
for j,o in enumerate(fields):m[CLIENT+o]=100+j
|
| 22 |
+
for table,pointer in zip(TABLES,BUFFERS):
|
| 23 |
+
m[table+16*selector]=pointer
|
| 24 |
+
for o in range(0,88,4):m[pointer+o]=0xcc000000+o
|
| 25 |
+
def zero(i,m,args,cmd):
|
| 26 |
+
assert args[8] in BUFFERS and args[12]==0 and args[16]==88
|
| 27 |
+
for o in range(0,88,4):m[args[8]+o]=0
|
| 28 |
+
return m,cmd,0,{'modeled_zero_fill':args,'original_native_executed':False}
|
| 29 |
+
m,_,e=execute(ins,144985,146551,m,(0,0,0),LOCAL,{**TRIG,-101:zero})
|
| 30 |
+
return {'selector':selector,'supplied_pose_angles':[[word(v) for v in a] for a in angles],'origin':[word(v) for v in origin],'client_fields':{str(o):m[CLIENT+o] for o in fields},'zero_vector':[m[21348+4*j] for j in range(3)],'buffers':[[m[p+o]&0xffffffff for o in range(0,88,4)] for p in BUFFERS],'execution':e}
|
| 31 |
+
|
| 32 |
+
def main():
|
| 33 |
+
q,raw,h,ins=source();m=constants(raw,h,[21348,21352,21356]);rows=[]
|
| 34 |
+
poses=[[(0,0,0)]*3,[(10,45,3),(-20,90,-5),(30,180,12)],[(90,0,0),(0,270,90),(-90,-180,-90)],[(12.25,-359.5,17),(4,725,30),(-17,-45,8)]]
|
| 35 |
+
for selector,angles,origin in itertools.product([0,1,7],poses,[(0,0,0),(100,-50,25)]):rows.append(transform(ins,m,selector,angles,origin))
|
| 36 |
+
write_json(Path('docs/research/qvm-model-transforms.json'),{'source':q['source'],'sha256':q['sha256'],'probes':rows,'limits':'Actual144985–146550 with supplied pose outputs, modeled bounded zero fill and finite math.sin/cos rounded tofloat32.32254 completion,25341 geometry,original libm parity and live model identities remain unverified.'})
|
| 37 |
+
if __name__=='__main__':main()
|
scripts/test_qvm_model_transforms.py
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import json,unittest
|
| 2 |
+
from pathlib import Path
|
| 3 |
+
from test_qvm_ground import word,n,f
|
| 4 |
+
from test_qvm_server_fire_basis import vectors
|
| 5 |
+
class ModelTransformTests(unittest.TestCase):
|
| 6 |
+
@classmethod
|
| 7 |
+
def setUpClass(cls):cls.rows=json.loads(Path('docs/research/qvm-model-transforms.json').read_text())['probes']
|
| 8 |
+
def test_independent_entire_88_byte_records(self):
|
| 9 |
+
self.assertEqual(len(self.rows),24)
|
| 10 |
+
for p in self.rows:
|
| 11 |
+
expected=[]
|
| 12 |
+
for index,angles in enumerate(p['supplied_pose_angles']+[p['supplied_pose_angles'][2]]):
|
| 13 |
+
fw,right,up=vectors(angles);row=[0]*22;row[3:6]=fw;row[7:10]=[word(f(n(z)-n(v))) for z,v in zip(p['zero_vector'],right)];row[11:14]=up;row[18]=word(1)
|
| 14 |
+
if index==0:row[:3]=[p['client_fields'][str(o)] for o in [6196,6204,6212]];row[19:22]=p['origin']
|
| 15 |
+
if index==1:row[:3]=[p['client_fields'][str(o)] for o in [6248,6256,6264]]
|
| 16 |
+
expected.append(row)
|
| 17 |
+
self.assertEqual(p['buffers'],expected)
|
| 18 |
+
def test_native_model_and_exact_trig_order(self):
|
| 19 |
+
for p in self.rows:
|
| 20 |
+
calls=p['execution']['calls'];self.assertEqual([c['target'] for c in calls],[-101]*4+[-104,-105]*9)
|
| 21 |
+
expected=[word(f(n(a[j])*n(1016003125))) for a in p['supplied_pose_angles'] for j in [1,1,0,0,2,2]];self.assertEqual([c['args']['8']&0xffffffff for c in calls[4:]],expected)
|
| 22 |
+
for c in calls[:4]:self.assertEqual(c['args']['12'],0);self.assertEqual(c['args']['16'],88)
|
| 23 |
+
def test_c_and_d_identical_and_translation_only_in_a(self):
|
| 24 |
+
for p in self.rows:self.assertEqual(p['buffers'][2],p['buffers'][3]);self.assertEqual([row[19:22] for row in p['buffers'][1:]],[[0,0,0]]*3)
|
| 25 |
+
def test_no_pose_or_intersection_child_fabricated(self):
|
| 26 |
+
for p in self.rows:self.assertNotIn(32254,[c['target'] for c in p['execution']['calls']]);self.assertNotIn(25341,[c['target'] for c in p['execution']['calls']]);self.assertEqual(p['zero_vector'],[0,0,0])
|
| 27 |
+
if __name__=='__main__':unittest.main()
|