FOME-Tech / fome-fw

Free Open Motorsports ECU
https://www.fome.tech
Other
51 stars 29 forks source link

Simulator uses 100% CPU #222

Closed karniv00l closed 1 year ago

karniv00l commented 1 year ago

Bug or a feature?

mi-hol commented 1 year ago

@karniv00l did you look for similar reports in https://github.com/rusefi/rusefi/issues ? I never got simulator to work on Windows 11 using virtual serial port see https://github.com/rusefi/rusefi/issues/4817 Are you seeing 100% CPU on Linux, physical hardware or VM?

mi-hol commented 1 year ago

never got simulator to work on Windows 11 using virtual serial port

recommended workaround was to switch to a payed version of TunerStudio.

karniv00l commented 1 year ago

docker on mac and ubuntu vps, I don't have a bare metal linux atm however it's more like 80% CPU on a single core vps

mi-hol commented 1 year ago

@karniv00l suggest to update issue title with above info

Is https://github.com/hyper-tuner/fome-simulator-docker#fome-simulator-in-docker the correct link for describing what you try to accomplish?

mck1117 commented 1 year ago

I believe that's by design. The "idle thread" sits and spin waits to "serve interrupts", so you're going to get high cpu usage.

mck1117 commented 1 year ago

see _sim_check_for_interrupts()

mck1117 commented 1 year ago

and @mi-hol, please try to keep the issue on-topic. If you're having other simulator issues or questions, make a new issue. This one is about high CPU usage.

karniv00l commented 1 year ago

Alright, maybe not worth keeping this open then

mi-hol commented 1 year ago

@mi-hol, please try to keep the issue on-topic. If you're having other simulator issues or questions, make a new issue.

@mck1117 I thought the commonality with my issue was eventually usage of virtual serial port.

Regarding simulator for FOME it's unclear (at least to me) if that is actually a supported component because:

Considering above, is it worth to create an issue in FOME?