增加解释器WASM程序结束夹具

结论:解释器核心WASM验证新增program_end_modal_reset夹具,并通过LinuxCNC _setup状态读回覆盖程序结束后的modal复位行为。
This commit is contained in:
2026-06-08 05:35:23 +08:00
parent ef5638e0a7
commit 1fcfc7943c
3 changed files with 19 additions and 7 deletions

View File

@@ -201,13 +201,14 @@ for `minimal_linear`, `arc_semantics`, `length_units`, `modal_incremental`,
`comment_logging`, `numbered_params`, `tool_semantics`, `tool_table_setup`, `comment_logging`, `numbered_params`, `tool_semantics`, `tool_table_setup`,
`tool_reload`, `canned_cycles`, `cutter_comp_motion`, `threading_sync`, `tool_reload`, `canned_cycles`, `cutter_comp_motion`, `threading_sync`,
`nurbs_g5_semantics`, `nurbs_g6_semantics`, `state_tag_motion`, `nurbs_g5_semantics`, `nurbs_g6_semantics`, `state_tag_motion`,
`canon_runtime_edges`, and `namedparam_semantics`, plus the `g1_zero_feed`, `canon_runtime_edges`, `program_end_modal_reset`, and `namedparam_semantics`,
`arc_radius_mismatch`, `arc_zero_radius`, `g53_incremental`, `tool_not_found`, plus the `g1_zero_feed`, `arc_radius_mismatch`, `arc_zero_radius`,
and `tool_length_offset_not_found` negative fixtures. The WASM interpreter `g53_incremental`, `tool_not_found`, and `tool_length_offset_not_found`
file path additionally covers `file_open_reset`, `percent_file_finish`, and negative fixtures. The WASM interpreter file path additionally covers
`oword_subroutine`. OPFS validation is limited to the JavaScript host-boundary `file_open_reset`, `percent_file_finish`, and `oword_subroutine`. OPFS
adapter plus the INI browser smoke harness. Full browser coverage, full SDK validation is limited to the JavaScript host-boundary adapter plus the INI
coverage, and full machine-session validation remain future work. browser smoke harness. Full browser coverage, full SDK coverage, and full
machine-session validation remain future work.
The current fixture expectations validate standalone behavior against both the The current fixture expectations validate standalone behavior against both the
vendored LinuxCNC source path and an upstream `rs274` side-by-side baseline for vendored LinuxCNC source path and an upstream `rs274` side-by-side baseline for

View File

@@ -124,6 +124,16 @@ void append_events_and_state(std::ostringstream &output, const Interp &interp)
output << "setup.parameter_5420=" << interp._setup.parameters[5420] << "\n"; output << "setup.parameter_5420=" << interp._setup.parameters[5420] << "\n";
output << "setup.parameter_5421=" << interp._setup.parameters[5421] << "\n"; output << "setup.parameter_5421=" << interp._setup.parameters[5421] << "\n";
output << "setup.parameter_5422=" << interp._setup.parameters[5422] << "\n"; output << "setup.parameter_5422=" << interp._setup.parameters[5422] << "\n";
output << "post_execute.plane=" << static_cast<int>(interp._setup.plane) << "\n";
output << "post_execute.distance_mode=" << static_cast<int>(interp._setup.distance_mode) << "\n";
output << "post_execute.feed_mode=" << static_cast<int>(interp._setup.feed_mode) << "\n";
output << "post_execute.motion_mode=" << interp._setup.motion_mode << "\n";
output << "post_execute.origin_index=" << interp._setup.origin_index << "\n";
output << "post_execute.feed_override=" << interp._setup.feed_override << "\n";
output << "post_execute.speed_override_0=" << interp._setup.speed_override[0] << "\n";
output << "post_execute.spindle_turning_0=" << interp._setup.spindle_turning[0] << "\n";
output << "post_execute.mist=" << interp._setup.mist << "\n";
output << "post_execute.flood=" << interp._setup.flood << "\n";
} }
} // namespace } // namespace

View File

@@ -126,6 +126,7 @@ const fixtureNames = [
"nurbs_g6_semantics", "nurbs_g6_semantics",
"state_tag_motion", "state_tag_motion",
"canon_runtime_edges", "canon_runtime_edges",
"program_end_modal_reset",
]; ];
for (const fixtureName of fixtureNames) { for (const fixtureName of fixtureNames) {