Files
wasm-simulator/docs/linuxcnc-wasm-blockers-source-map.md

4.1 KiB

LinuxCNC WASM blockers source map

This map records the source basis for the WASM blocker categories used by analyze-linuxcnc-wasm-blockers.sh and test-linuxcnc-wasm-blockers.sh. It is a source-link/build guard only; it does not add CNC behavior and must not become smoke parser behavior.

LinuxCNC Source Basis

  • src/emc/rs274ngc/gcodemodule.cc, canonmodule.cc, interpmodule.cc, and py*.cc provide the Python and Boost.Python module binding blockers.
  • src/emc/rs274ngc/interp_python.cc, interp_remap.cc, interp_namedparams.cc, interp_o_word.cc, interp_setup.cc, and rs274ngc_pre.cc keep Python/Boost.Python remap paths as shimmed core sources.
  • src/emc/rs274ngc/interp_base.cc is the core source that still carries dlopen use satisfied by the wasm dlfcn shim.
  • src/emc/tooldata/tooldata_mmap.cc is the native mmap backend blocker replaced by the wasm-safe tooldata mmap backend shim.
  • src/emc/rs274ngc/interp_o_word.cc uses native directory traversal for O-word subroutine lookup; browser persistence remains OPFS-only.

Manifest Coverage

Manifest group Count Role
core 26 LinuxCNC RS274/tooldata/INI/NML sources compiled or shim-satisfied by WASM probes.
blocked 9 LinuxCNC Python binding and native tooldata sources tracked but replaced for WASM.
header 26 LinuxCNC headers needed by the WASM-safe source probes and shims.
blocked-header 1 Boost.Python helper header tracked as blocked browser API surface.
metadata 15 LinuxCNC build/source-basis files for shim coverage.

Analyzer Coverage

Analyzer section Count Boundary
python 8 Blocked Python/Boost.Python module sources.
dlopen 0 blocked dlopen and blocked tooldata-users remain empty.
tooldata 1 Native tooldata mmap blocker.
tooldata-users 0 Blocked tooldata user sources remain empty.
native-backend 1 Native backend source excluded from browser linking.
native-fs 1 Native filesystem blocker excluded from browser linking.
blocked-replacements 9 Blocked LinuxCNC sources mapped to wasm-safe shim files.
core-python-shimmed 6 Core LinuxCNC Python/remap users compiled with Python/Boost.Python shims.
core-dlopen-shimmed 1 Core LinuxCNC dlopen user compiled with dlfcn shim.
core-tooldata-shimmed 1 Core LinuxCNC tooldata source compiled with wasm tooldata shims.
core-tooldata-users-shimmed 2 Core RS274/NML users of tooldata declarations.
core-native-fs-shimmed 16 Core sources with native filesystem includes or calls covered by WASM shims.

Required replacement set:

  • src/emc/rs274ngc/canonmodule.cc -> core/wasm_shims/linuxcnc_runtime_shim.cc
  • src/emc/rs274ngc/gcodemodule.cc -> core/wasm_shims/linuxcnc_runtime_shim.cc
  • src/emc/rs274ngc/interpmodule.cc -> core/wasm_shims/linuxcnc_runtime_shim.cc
  • src/emc/rs274ngc/pyarrays.cc -> core/wasm_shims/python_c_api_shim.cc
  • src/emc/rs274ngc/pyblock.cc -> core/wasm_shims/python_c_api_shim.cc
  • src/emc/rs274ngc/pyemctypes.cc -> core/wasm_shims/python_c_api_shim.cc
  • src/emc/rs274ngc/pyinterp1.cc -> core/wasm_shims/python_c_api_shim.cc
  • src/emc/rs274ngc/pyparamclass.cc -> core/wasm_shims/python_c_api_shim.cc
  • src/emc/tooldata/tooldata_mmap.cc -> core/wasm_shims/tooldata/tooldata_mmap_backend.cc

Required tracked core examples:

  • src/emc/rs274ngc/gcodemodule.cc
  • src/emc/rs274ngc/interpmodule.cc
  • src/emc/tooldata/tooldata_mmap.cc
  • src/emc/rs274ngc/interp_base.cc
  • src/emc/rs274ngc/interp_o_word.cc
  • src/emc/rs274ngc/rs274ngc_pre.cc

Checks

Run:

./check-linuxcnc-wasm-blockers-source-map.sh
./test-linuxcnc-wasm-blockers.sh linuxcnc-rs274-wasm-source-files.txt
./test-native.sh
./test-linuxcnc-source-link.sh

check-linuxcnc-wasm-blockers-source-map.sh keeps this document, the RS274/WASM manifest, LinuxCNC source anchors, analyzer output, and wasm-safe shim replacement set synchronized. Python/Boost.Python remap paths remain tracked blockers until they are ported, wrapped, or replaced by source-backed browser-safe LinuxCNC adaptations.