Download

LocalShaderCache-PC-D3D-SM3.upk

I regularly get pop-up warnings in the editor saying “LocalShaderCache-PC-D3D-SM3.upk is 380mb in size. This exceeds the recommended package size…”.

This package has been slowly growing over the years.

Does anyone know what exactly it is and if it will regenerate itself if I delete it?

Thanks

I’ve never tried deleting it, but I have noticed that package myself a few times.

When I copy files into my Steam image, I only copy the most recent changed files. This file is always among them, even though the size has stayed the same for me for quite some time. I therefore often leave it out of updates, and I haven’t noticed any problems.

If you wanted to experiment, you could always move the file, start the game, and see what happens.

P.S.: I just now realized that if that’s a upk file, you should be able to see it in the editor, right?

it’s… the shader cache :smiley:
meaning it’s the precomputed result of all your shaders so that the end users doesn’t have to wait 1 hour for shaders to compile upon starting the game

if I remember correctly you can delete it and then next time you start the editor it will have to recompile all the shaders again. or maybe that kills everything, so instead of deleting it just replace it with the default one from a clean UDK installation.
why do that though? well it might result in a smaller shadercache file, because if I remember correctly, the shader cache isn’t always properly cleaned of shaders that are no longer there

Just a public service announcement to run the fixupredirects commandlet every time you move or delete something. http://api.unrealengine.com/udk/Three/FixUpRedirectsCommandlet.html

I don’t think fixupredirects cleans the shadercache, and also when cooking packages they will have correct/cleaned references without redirectors
but yeah for development it’s good to keep things tidy running a fixupredirects every so often

Thanks for the info guys. Seems a little odd that my shader cache would have grown beyond the recommended size. My game packages down into just over a gig (which is pretty tiny). I wonder how other huge games managed this.

Also, I was recently doing some material testing on a test landscape map. I made some changes and compiled the material. After doing this the cache size increased by 10mb. I undid the change and the cache remained the same size. So it seems this is slowly compounding over time. Just a little concerned for the future.

it is probably as I said then :slight_smile:

just delete it or replace it with the stock UDK one, launch the editor and take a coffee. compare sizes, see if there’s profit

you can alter the package size in a config file i think make it bigger

@RoyceVagner Do you happen to know where in the config files this would be located? I always assumed this was something hard coded into the compiled UDK binary.

Edit: I think i’ve found it in DefaultEngine.ini:



[Core.System]
PackageSizeSoftLimit=300


@RoyceVagner I seems you have some understanding of UDK, I was wondering if you might have some insight into this issue:

https://forums.unrealengine.com/legacy-tools-unreal-engine-3-udk/udk-programming-and-unrealscript/1477370-ran-out-of-virtual-memory-while-cooking-map

Basically the cookpackages commandlet crashes when cooking a large map (in my case over 400mb) in Frontend.

I get around this, by first doing a “clean and full cook” on a smaller map, then adding the larger map and doing just a “cook”. However this workaround is a bit worrying as my game continues to grow in size. This workaround also doesn’t work for me on the full licenced UE3, which is preventing me moving from UDK to UE3.

Any ideas are welcome.

Apologies for the necro bump :smiley:
Just posted a similar thread but in my case is the **LocalShaderCache-PC-D3D-SM5.upk **
Wanted to ask you how it went with you.Did you deleted the cache and it auto generates or you replaced it with one from a clean build?

Yeah, I ended up replacing it with one from a default install of UDK. It re-cached a bunch of shaders, but the file size was very small after. So there is some kind of error in UDK that allows redundant data to build-up in that file.

I’m pretty sure you can just delete that file and it will regenerate.

Thank you :smiley: Suspected it was a error.Glad is a simple one.

From curiosity, do you guys see when you post, that your topic is moved to the top of the page? Ive been posting for the past few days and my threads never reach the top when i view them from the main unreal forums page.Only when I enter a section where I posted I can see that the topic where I posted is on the top.

Amazing i read what you guys were talking about. Thought wow i should redo mine, what a difference in size. from 37.3mb to 20,000kb on LocalShaderCache-PC-D3D-SM3 and on
LocalShaderCache-PC-D3D-SM5 from 79,8 mb to 47,000kb. Sure helped performance on the build end. It seems it keep redundant data and does not get rid of it. Until you delete it and let it make new one. Took me 4 hours to redo and make new shader caches :slight_smile: