garrysmod-issues icon indicating copy to clipboard operation
garrysmod-issues copied to clipboard

[Linux DS 64] file.AsyncRead isn't Async

Open RaphaelIT7 opened this issue 4 months ago • 1 comments

Details

On Linux 64x file.AsyncRead doesn't seem to be Async.

My guess is that the filesystem's threadpool isn't started properly / same issue as https://github.com/Facepunch/garrysmod-issues/issues/5310 but I didn't verify this yet. https://github.com/perilouswithadollarsign/cstrike15_src/blob/master/filesystem/filesystem_async.cpp#L639

Steps to reproduce

  1. Start a Linux DS Server
  2. Run lua_run local a=SysTime() for k=1, 50 do file.AsyncRead("steamclient.so", "BASE_PATH", function() end) end print(SysTime()-a)
  3. Watch it freeze the main thread

RaphaelIT7 avatar Oct 15 '24 10:10 RaphaelIT7