-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Virtual Lua filesystem is very slow on client #4650
Comments
If you're running x64 client and x86 server, that might be why. x64 has notably lower performance. |
Do you have a source or some data on this? |
@WinterPhoenix one example #4100 . You'll also see starfall and E2 use more cpu on x64 servers, there's probably more examples but haven't found them. |
After more measurements in best case scenario around 93% of loading time is spent on And no, this is not real file system bound since gmod is on a ssd and system file cache is a thing. |
I am not sure, but is this related to: #5674? So far I can tell it should be fixed by now. |
Continuation from Garry's Mod discord channel #next-update
Since i brought this ancient issue with Virtual Lua filesystem performance on client, i will open an issue ticket here.
Basically, Virtual Lua filesystem is very slow on client when joining non-local servers (probably also singleplayer?).
Since
include/CompileFIle/file.Find(..., 'LUA')
are handled by Virtual LuaFS, it is safe to assume on client performance of these functions is mostly affected by the FS performance. So here is the most simple test:Outputs:
Serverside and
Clientside
These results get drastically worse the more folders are present in addons/ folder serverside. At point of 30 folders inside addons/ serverside
Starting Lua
stage takes forever for client. (those were measured with only 2 folders inside addons/ serverside. One with quickly-being-developed addon on git, second is basically a folder containing only symbolic links to all files inside folders that could be in addons/, but they are not due to this slow performance)I suspect that either file.Find inside
LUA
also ask physical filesystem (even so, it shouldn't be this slow because of system cache!) or Virtual LuaFS is slow on itself, or both.As @Kefta pointed out, it might be related that each addon in addons/ get it's own virtual filesystem on client. If so, then it is safe to assume that if Virtual LuaFS is marginally slower than physical filesystem then separate instances of them make situation only worse.
From my Discord post:
The text was updated successfully, but these errors were encountered: