- tools/stdmac_matrix.py: raw_add/and/or/xor/inc 全量对拍(真链路:probe_dump 汇编 -> ROT-8 VM -> 读 out) - tools/stdmac_xor_fix_probe.py + tests/xor_fix_probe.r8asm.frag: 候选体 = OR 体删末块 %3 set_1,121/121 通过 - tools/stdmac_inc_fix_probe.py + tests/inc_fix_probe.r8asm.frag: 最小修法 = 对调 bit_raw_inc 第 3/4 实参,22/22 + 链式通过 - tools/stdmac_preserve.py: 五个 raw_ 宏均保留输入(A/B/Ci) - tests/probe_dump.cc: 任意 .r8asm -> tape 的驱动(须在 r8asm_rev 根目录跑,include 是相对 cwd)
16 lines
439 B
C++
16 lines
439 B
C++
#include "r8asm/r8asm.hh"
|
|
#include <iostream>
|
|
|
|
// 探针驱动:把任意 .r8asm 文件汇编成 ROT-8 tape 打到 stdout。
|
|
// 必须在 r8asm_rev 仓库根目录运行(文件内的 %include "asm/..." 是相对 cwd 的路径)。
|
|
int main(int argc, char **argv) {
|
|
if (argc < 2) {
|
|
std::cerr << "usage: probe_dump <file.r8asm>\n";
|
|
return (1);
|
|
}
|
|
r8asm a;
|
|
a.import_file(argv[1]);
|
|
std::cout << a.export_rot8();
|
|
return (0);
|
|
}
|