CPU Performance Patch (Up to 30% faster physics, up to 60% more FPS)

Other CPU Performance Patch (Up to 30% faster physics, up to 60% more FPS)

Submitted v12. Newest version might be slightly slower on the baseline3 benchmark if you just set all to max, but should work better for more people.
Also a huge improvement in morph processing. If the character has a lot of morphs from itself, from @Acid Bubbles AtomTimeline or @everlaster Naturalis the animations should be a lot faster now. It really shows when you use all at once. Getting 120+ fps on dance scenes with naturalis, softbody, high quality physics and physics rate of 120 now.
 
Submitted v12. Newest version might be slightly slower on the baseline3 benchmark if you just set all to max, but should work better for more people.
Also a huge improvement in morph processing. If the character has a lot of morphs from itself, from @Acid Bubbles AtomTimeline or @everlaster Naturalis the animations should be a lot faster now. It really shows when you use all at once. Getting 120+ fps on dance scenes with naturalis, softbody, high quality physics and physics rate of 120 now.
Will this update fix the vr issues or are those still being worked out. V11 still offers no vr improvements at all
 
The latest update (version 12) has been approved, and I've whitelisted turtlebackgoofy so future updates will not require approval.
 
Taking off my moderator hat for a second and just speaking as a user, thanks for this fantastic patch! But I'd suggest you edit the "readme" to make a little more sense to us normal mortals. As I'm not familiar with the terms HT/SMT or CCD, and don't know why I wouldn't want to use all my cores all the time, the file raises more questions than it answers.

Again, this isn't a moderator request, just a suggestion from a user.

Am I right in thinking that since I have an intel chip with 8 performance cores (which I think have two threads each) and 16 efficiency cores, I should set affinity to to 1,3,5,7,9,11,13,15 so it uses one thread on each of the performance cores?
 
Last edited:
Taking off my moderator hat for a second and just speaking as a user, thanks for this fantastic patch! But I'd suggest you edit the "readme" to make a little more sense to us normal mortals. As I'm not familiar with the terms HT/SMT or CCD, and don't know why I wouldn't want to use all my cores all the time, the file raises more questions than it answers.

Am I right in thinking that since I have an intel chip with 8 performance cores (which I think have two threads each) and 16 efficiency cores, I should set affinity to to 1,3,5,7,9,11,13,15 so it uses one thread on each of the performance cores?
That is correct for my 5950x and probably all Ryzens, on Ryzen the unity engine is faster if you only use the non-HT/non-SMT cores, which translates to 1,3,5...
For Intel I have read reports that you should actually use HT and non-HT cores and even the efficiency cores. But since I dont own an Intel I cant confirm it.

For v12 you can try to just set affinity to all cores and set the other parameters to your core count.

[threads]
affinity=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
computeColliders=16
skinmeshPart=16
skinmeshPartMaxPerChar=16
applyMorphs=16
applyMorphMaxPerChar=16

This will heat up the CPU most though.
I am aware that this is kinda complicated to setup, I am still in the experimentation phase. Once we gather all information I will compile an automatic setup for the best possible setting.
 
"This will heat up the CPU most though."
I haven't actually noticed any overheating.
I will check the temps when I try the latest version.
 
Any chance there is a video showing the installation process?
I put the files into the directory but my characters just T-pose and I cant seem to move them at all.
Not sure after I install the files how to get to the settings to change any necessary settings....
Anyway, Would love to try it but not terribly savvy with the file side of things.
 
To put some numbers to the improvement I got...
I upgraded from a 3060 to a 4070 super. 3060 benchmarked at 90fps (gpu benchmark) and the 4070 super was at 184fps.
I was very happy with that increase.
Then I installed this patch. The 4070 GPU benchmark is now giving 218fps! That's the GPU benchmark...
The baseline benchmark went from 219fps with the 3060 to 310fps with v12 of this patch.
CPU High physics benchmark went from 141fps (4070super) to 211fps (same gpu, just v12 of the patch installed).

I hope those astounding numbers make it clear just what a difference this has made. I literally got more of an upgrade from this dll than buying the 4070 super.
 
Here is a breakdown why some see improvements and others dont. As you see, you see great improvements if your CPU is good and the GPU is atleast decent. As the characters threads got shorter now, you can add more morphs to the character without FPS penalty, however its pretty much only morphs and what they affect. Plugins and clothing is still in the main thread.

1.JPG

2.JPG

3.JPG

4.JPG

5.JPG

6.JPG

7.JPG

8.JPG

9.JPG
 
Last edited:
That is correct for my 5950x and probably all Ryzens, on Ryzen the unity engine is faster if you only use the non-HT/non-SMT cores, which translates to 1,3,5...
For Intel I have read reports that you should actually use HT and non-HT cores and even the efficiency cores. But since I dont own an Intel I cant confirm it.

For v12 you can try to just set affinity to all cores and set the other parameters to your core count.

[threads]
affinity=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
computeColliders=16
skinmeshPart=16
skinmeshPartMaxPerChar=16
applyMorphs=16
applyMorphMaxPerChar=16

This will heat up the CPU most though.
I am aware that this is kinda complicated to setup, I am still in the experimentation phase. Once we gather all information I will compile an automatic setup for the best possible setting.
isn't setting affinity to all cores the same as not setting affinity at all?
 
Any chance there is a video showing the installation process?
I put the files into the directory but my characters just T-pose and I cant seem to move them at all.
Not sure after I install the files how to get to the settings to change any necessary settings....
Anyway, Would love to try it but not terribly savvy with the file side of things.
1707600548831.png
Backup the original Vam_Data/Managed/Assembly-CSharp.dll, then copy and paste these files and folders to your Vam root directory. I believe other users reported the T-pose problem when they copied the files in PerformancePatches directly into their Vam folder, instead of copying the directory itself.
 
View attachment 333785Backup the original Vam_Data/Managed/Assembly-CSharp.dll, then copy and paste these files and folders to your Vam root directory. I believe other users reported the T-pose problem when they copied the files in PerformancePatches directly into their Vam folder, instead of copying the directory itself.
yeah I put them in the PerformancePatches folder because some bepinex plugins deleted .dlls from the main folder lol
 
Nice. But still, yikes, and my CPU doesn't handle AVX2 unfortunately. Hope this does end up implemented at least tentatively as an option in the base game. Maybe talk Meshed up and see if you can't get at least a couple bucks out of it?
Newest version doesnt need AVX anymore.
The issues I fixed will probably not happen in the newest unity engine, since it uses a newer version of physx which just is faster for the same physics. Also the burst compiler in newest unity engine might give the same improvements as I created. My work will most certainly not be needed in VaM2, but if @meshedvr wants, he can hire me for vam2 performance improvements.
I did the patch for myself as an excercise actually and people wanted to share, so enjoy it for free.
 
yeah I put them in the PerformancePatches folder because some bepinex plugins deleted .dlls from the main folder lol
You might want to do away with the "patched##" directory inside the zip, so you can just tell people to unzip into the Vam root directory.
 
Sorry, but any idea for the settings of?

Processor AMD Ryzen 9 5900X 12-Core Processor, 3701 Mhz, 12 Core(s), 24 Logical Processor(s)

I think you are going to win a gold VAM medal with this plugin!
 
With a 13900K and 4090 and using the default .INI settings in V12, I'm getting substantial improvements in the benchmark with all scenes except HairSim and ClothSim, which show no difference at all:
before
Benchmark-20240210-065927.png

after
Benchmark-20240210-063503.png

Also, loading a deliberately intense scene with 3 female characters running long, simmed hair and Naturalis, I get no difference at all - 38 FPS patch/no patch. Probably GPU limited.
 
With a 13900K and 4090 and using the default .INI settings in V12, I'm getting substantial improvements in the benchmark with all scenes except HairSim and ClothSim, which show no difference at all:

Also, loading a deliberately intense scene with 3 female characters running long, simmed hair and Naturalis, I get no difference at all - 38 FPS patch/no patch. Probably GPU limited.
3 characters MOVING and colliding with soft body enabled is very intense on "unity physics" which is sadly single threaded and there is no fix possible for that except new unity version (see the pictures I posted a few post earlier in this thread). Your improvements are actually great, but you only see it in Baseline3 benchmark where you had low FPS to begin with.
 
An issue I noticed in VR: If there is hair in a scene, it's a flat removal of your FPS, no matter how beefy your GPU is. I suspect that the vsync (that all HMD need) is applied before the hair is rendered by unity. My render time is about 1ms and doesnt change much with adding hair, it even slightly decreases. However my FPS drops from 90.0 to 85fps as soon as a single hair is visible.
 
Back
Top Bottom