wiremod / wire-cpu

Legacy CPU/GPU/SPU as a separate addon.
Apache License 2.0
8 stars 6 forks source link

Some GPU Instructions are failing #34

Closed DerelictDrone closed 9 months ago

DerelictDrone commented 9 months ago

Seems to have begun after #27, and isn't fixed by #28

Error that shows up

[wire-cpu] ZVM:[0:48: ')' expected (to close '(' at line 47) near 'local'
  1. Precompile_Finalize - addons/wire-cpu/lua/wire/zvm/zvm_core.lua:361
   2. Step - addons/wire-cpu/lua/wire/zvm/zvm_core.lua:642
    3. Run - addons/wire-cpu/lua/entities/gmod_wire_gpu/cl_init.lua:159
     4. RenderGPU - addons/wire-cpu/lua/entities/gmod_wire_gpu/cl_init.lua:249
      5. unknown - addons/wire-cpu/lua/entities/gmod_wire_gpu/cl_init.lua:354

[ZVM ERROR]: unknown error

For 3D examples, the code is being finalized while it's half finished (trailing "variable +" something from what I could tell by printing the entire emitblock on error)

For other examples(like the trig one), instructions using % for modulo or trying to check if a character is "%" have errors due to string.format attempting to parse them as a replacement.

Needs further investigation.