Guard ccomp per-file staging paths
This commit is contained in:
54
text6.txt
54
text6.txt
@@ -1863,3 +1863,57 @@ path helper,优先候选:
|
|||||||
建议下一批先处理 ccomp 4 组,因为 file manifest 固定为 `test.ngc`、`test.tbl`,
|
建议下一批先处理 ccomp 4 组,因为 file manifest 固定为 `test.ngc`、`test.tbl`,
|
||||||
且 Node/browser coverage 已成型。继续避免 blocked runtime promotion、browser full
|
且 Node/browser coverage 已成型。继续避免 blocked runtime promotion、browser full
|
||||||
inventory 扩面和 JS CNC 语义实现。
|
inventory 扩面和 JS CNC 语义实现。
|
||||||
|
|
||||||
|
四十三、2026-06-13 继续执行记录:ccomp per-file staging helper guard
|
||||||
|
|
||||||
|
本批按第 42 批建议处理 ccomp 专用 staged path helper:
|
||||||
|
|
||||||
|
- `lathe-comp`
|
||||||
|
- `mill-g90g91g92`
|
||||||
|
- `mill-line-arc-entry`
|
||||||
|
- `mill-zchanges`
|
||||||
|
|
||||||
|
完成内容:
|
||||||
|
|
||||||
|
- Node 侧将 `assertCcompRegressionStaging(...)` 拆分为
|
||||||
|
`assertCcompRegressionCoverage(...)` 和 `assertCcompRegressionFilesStaging(...)`;
|
||||||
|
- Node 侧保留 vendored `test.ngc`、`test.tbl` manifest coverage;
|
||||||
|
- Node 侧将 4 个 ccomp fixture 切换为 coverage helper 加 per-file staging helper;
|
||||||
|
- browser 侧将 ccomp helper 改为逐个文件检查
|
||||||
|
`/work/browser-ccomp/<name>/<file>` staged path;
|
||||||
|
- browser 侧同步替换 4 个 ccomp fixture 调用;
|
||||||
|
- `test.ini` 仍由 `writeCcompRegressionFiles(...)` 运行时生成,不纳入 vendored
|
||||||
|
staged manifest;
|
||||||
|
- browser 侧仍不枚举目录;
|
||||||
|
- 仅整理 host/filesystem staging guard,不改变 cutter compensation、tool table、
|
||||||
|
generated INI 或 interpreter 语义。
|
||||||
|
|
||||||
|
已运行验证:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git diff --check
|
||||||
|
wasm-port/tools/verify_vendor_sync.sh
|
||||||
|
wasm-port/tools/verify_no_standalone_cnc_semantics.sh
|
||||||
|
SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_interp_wasm.sh
|
||||||
|
SKIP_INI_BUILD=1 SKIP_INTERP_BUILD=1 wasm-port/tests/browser/verify_interp_browser.sh
|
||||||
|
SKIP_INTERP_BUILD=1 wasm-port/tests/wasm/node/verify_sim_configs_inventory_wasm.sh
|
||||||
|
wasm-port/tests/host/verify_host_smokes.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
结果:全部通过。
|
||||||
|
|
||||||
|
下一步建议:
|
||||||
|
|
||||||
|
继续处理 g10 专用 helper。当前候选:
|
||||||
|
|
||||||
|
- `g10-l1-l10`
|
||||||
|
- `g10-l11`
|
||||||
|
- `g10-l2-while-active`
|
||||||
|
- `g10-l20-while-active`
|
||||||
|
- `g10-with-g92`
|
||||||
|
|
||||||
|
这些已有 fixed file list 和 Node/browser coverage,可按 ccomp 模式将
|
||||||
|
`assertG10RegressionStaging(...)` 拆成 coverage helper 与 per-file staging helper。
|
||||||
|
注意 `test.tbl` 存在时 `test.ini` 仍由 `writeG10RegressionFiles(...)` 运行时生成,
|
||||||
|
不要纳入 vendored staged manifest。继续避免 blocked runtime promotion、browser full
|
||||||
|
inventory 扩面和 JS CNC 语义实现。
|
||||||
|
|||||||
@@ -4730,13 +4730,14 @@
|
|||||||
"test.tbl",
|
"test.tbl",
|
||||||
];
|
];
|
||||||
|
|
||||||
function assertCcompRegressionStaging(name, wasmDir) {
|
function assertCcompRegressionFilesStaging(name, wasmDir) {
|
||||||
if (ccompRegressionFiles.length !== 2 || new Set(ccompRegressionFiles).size !== ccompRegressionFiles.length) {
|
if (ccompRegressionFiles.length !== 2 || new Set(ccompRegressionFiles).size !== ccompRegressionFiles.length) {
|
||||||
throw new Error("browser_interp_ccomp_fixture_coverage: list drift");
|
throw new Error("browser_interp_ccomp_fixture_coverage: list drift");
|
||||||
}
|
}
|
||||||
const ccompStagedRelativeFiles = ccompRegressionFiles.map((file) => `${wasmDir}/${file}`.replace(`/work/browser-ccomp/${name}/`, ""));
|
for (const file of ccompRegressionFiles) {
|
||||||
if (ccompStagedRelativeFiles.join(",") !== ccompRegressionFiles.join(",")) {
|
if (`${wasmDir}/${file}` !== `/work/browser-ccomp/${name}/${file}`) {
|
||||||
throw new Error(`browser_interp_ccomp_${name}_staging_manifest: list drift`);
|
throw new Error(`browser_interp_ccomp_${name}_${file}_staging_manifest: list drift`);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -6791,7 +6792,7 @@
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompLatheCompDir = await writeCcompRegressionFiles(interp, "lathe-comp");
|
const ccompLatheCompDir = await writeCcompRegressionFiles(interp, "lathe-comp");
|
||||||
assertCcompRegressionStaging("lathe-comp", ccompLatheCompDir);
|
assertCcompRegressionFilesStaging("lathe-comp", ccompLatheCompDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"browser_interp_ccomp_lathe_comp",
|
"browser_interp_ccomp_lathe_comp",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
@@ -6816,7 +6817,7 @@
|
|||||||
interp,
|
interp,
|
||||||
"mill-g90g91g92",
|
"mill-g90g91g92",
|
||||||
);
|
);
|
||||||
assertCcompRegressionStaging("mill-g90g91g92", ccompMillG90G91G92Dir);
|
assertCcompRegressionFilesStaging("mill-g90g91g92", ccompMillG90G91G92Dir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"browser_interp_ccomp_mill_g90g91g92",
|
"browser_interp_ccomp_mill_g90g91g92",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
@@ -6840,7 +6841,7 @@
|
|||||||
interp,
|
interp,
|
||||||
"mill-line-arc-entry",
|
"mill-line-arc-entry",
|
||||||
);
|
);
|
||||||
assertCcompRegressionStaging("mill-line-arc-entry", ccompMillLineArcEntryDir);
|
assertCcompRegressionFilesStaging("mill-line-arc-entry", ccompMillLineArcEntryDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"browser_interp_ccomp_mill_line_arc_entry",
|
"browser_interp_ccomp_mill_line_arc_entry",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
@@ -6861,7 +6862,7 @@
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompMillZchangesDir = await writeCcompRegressionFiles(interp, "mill-zchanges");
|
const ccompMillZchangesDir = await writeCcompRegressionFiles(interp, "mill-zchanges");
|
||||||
assertCcompRegressionStaging("mill-zchanges", ccompMillZchangesDir);
|
assertCcompRegressionFilesStaging("mill-zchanges", ccompMillZchangesDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"browser_interp_ccomp_mill_zchanges",
|
"browser_interp_ccomp_mill_zchanges",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
|
|||||||
@@ -377,7 +377,7 @@ const ccompRegressionFiles = [
|
|||||||
"test.tbl",
|
"test.tbl",
|
||||||
];
|
];
|
||||||
|
|
||||||
function assertCcompRegressionStaging(name, wasmDir) {
|
function assertCcompRegressionCoverage(name) {
|
||||||
const sourceDir = resolve(rootDir, "vendor/linuxcnc/tests/ccomp", name);
|
const sourceDir = resolve(rootDir, "vendor/linuxcnc/tests/ccomp", name);
|
||||||
assert.deepEqual(
|
assert.deepEqual(
|
||||||
readdirSync(sourceDir)
|
readdirSync(sourceDir)
|
||||||
@@ -386,12 +386,17 @@ function assertCcompRegressionStaging(name, wasmDir) {
|
|||||||
ccompRegressionFiles,
|
ccompRegressionFiles,
|
||||||
`interp ccomp ${name} fixture coverage drift`,
|
`interp ccomp ${name} fixture coverage drift`,
|
||||||
);
|
);
|
||||||
assert.deepEqual(
|
}
|
||||||
ccompRegressionFiles.map((file) => `${wasmDir}/${file}`),
|
|
||||||
ccompRegressionFiles.map((file) => `/work/ccomp/${name}/${file}`),
|
function assertCcompRegressionFilesStaging(name, wasmDir) {
|
||||||
`interp ccomp ${name} staging manifest drift`,
|
for (const file of ccompRegressionFiles) {
|
||||||
|
assert.equal(
|
||||||
|
`${wasmDir}/${file}`,
|
||||||
|
`/work/ccomp/${name}/${file}`,
|
||||||
|
`interp ccomp ${name}/${file} staging manifest drift`,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function writeG10RegressionFiles(name, files) {
|
function writeG10RegressionFiles(name, files) {
|
||||||
const sourceDir = resolve(rootDir, "vendor/linuxcnc/tests/interp/g10", name);
|
const sourceDir = resolve(rootDir, "vendor/linuxcnc/tests/interp/g10", name);
|
||||||
@@ -1763,7 +1768,8 @@ verifyExpectedOutput(
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompLatheCompDir = writeCcompRegressionFiles("lathe-comp");
|
const ccompLatheCompDir = writeCcompRegressionFiles("lathe-comp");
|
||||||
assertCcompRegressionStaging("lathe-comp", ccompLatheCompDir);
|
assertCcompRegressionCoverage("lathe-comp");
|
||||||
|
assertCcompRegressionFilesStaging("lathe-comp", ccompLatheCompDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"interp_ccomp_lathe_comp_wasm",
|
"interp_ccomp_lathe_comp_wasm",
|
||||||
interp.runFileWithIni(`${ccompLatheCompDir}/test.ngc`, `${ccompLatheCompDir}/test.ini`),
|
interp.runFileWithIni(`${ccompLatheCompDir}/test.ngc`, `${ccompLatheCompDir}/test.ini`),
|
||||||
@@ -1782,7 +1788,8 @@ verifyExpectedOutput(
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompMillG90G91G92Dir = writeCcompRegressionFiles("mill-g90g91g92");
|
const ccompMillG90G91G92Dir = writeCcompRegressionFiles("mill-g90g91g92");
|
||||||
assertCcompRegressionStaging("mill-g90g91g92", ccompMillG90G91G92Dir);
|
assertCcompRegressionCoverage("mill-g90g91g92");
|
||||||
|
assertCcompRegressionFilesStaging("mill-g90g91g92", ccompMillG90G91G92Dir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"interp_ccomp_mill_g90g91g92_wasm",
|
"interp_ccomp_mill_g90g91g92_wasm",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
@@ -1803,7 +1810,8 @@ verifyExpectedOutput(
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompMillLineArcEntryDir = writeCcompRegressionFiles("mill-line-arc-entry");
|
const ccompMillLineArcEntryDir = writeCcompRegressionFiles("mill-line-arc-entry");
|
||||||
assertCcompRegressionStaging("mill-line-arc-entry", ccompMillLineArcEntryDir);
|
assertCcompRegressionCoverage("mill-line-arc-entry");
|
||||||
|
assertCcompRegressionFilesStaging("mill-line-arc-entry", ccompMillLineArcEntryDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"interp_ccomp_mill_line_arc_entry_wasm",
|
"interp_ccomp_mill_line_arc_entry_wasm",
|
||||||
interp.runFileWithIni(
|
interp.runFileWithIni(
|
||||||
@@ -1824,7 +1832,8 @@ verifyExpectedOutput(
|
|||||||
);
|
);
|
||||||
|
|
||||||
const ccompMillZchangesDir = writeCcompRegressionFiles("mill-zchanges");
|
const ccompMillZchangesDir = writeCcompRegressionFiles("mill-zchanges");
|
||||||
assertCcompRegressionStaging("mill-zchanges", ccompMillZchangesDir);
|
assertCcompRegressionCoverage("mill-zchanges");
|
||||||
|
assertCcompRegressionFilesStaging("mill-zchanges", ccompMillZchangesDir);
|
||||||
verifyExpectedOutput(
|
verifyExpectedOutput(
|
||||||
"interp_ccomp_mill_zchanges_wasm",
|
"interp_ccomp_mill_zchanges_wasm",
|
||||||
interp.runFileWithIni(`${ccompMillZchangesDir}/test.ngc`, `${ccompMillZchangesDir}/test.ini`),
|
interp.runFileWithIni(`${ccompMillZchangesDir}/test.ngc`, `${ccompMillZchangesDir}/test.ini`),
|
||||||
|
|||||||
Reference in New Issue
Block a user