Commit Graph

15 Commits

Author SHA1 Message Date
jeremy moore
1e2070ad8d Make file cache block size configurable with (read only) CVar fc.BlockSize
#rb ben.ingram
#preflight 611d23203a81b0000133853f


#ROBOMERGE-SOURCE: CL 17216210
#ROBOMERGE-BOT: (v855-17104924)

[CL 17216219 by jeremy moore in ue5-main branch]
2021-08-18 12:05:05 -04:00
eric mcdaniel
3d26336c66 Fix for potential deadlock in shader preloads
FPreloadShaderTask takes the ShaderPreloadLock in FShaderCodeArchive::OnShaderPreloadFinished() and then issues an async read.  Another task can be picked up by the thread while waiting on that read.  If that new task is also a FPreloadShaderTask it will try to aquire the ShaderPreloadLock again and deadlock.

Introduce an EnsureReadNonBlocking method to IMemoryReadStream which can be called outside the lock to ensure the data is ready.  We can then lock and copy out the data without incuring a wait and the potential for another FPreloadShaderTask being run while we hold the lock.

#rb Ben.Ingram, Michal.Valient


#ROBOMERGE-SOURCE: CL 16917416
#ROBOMERGE-BOT: (v836-16769935)

[CL 16924675 by eric mcdaniel in ue5-main branch]
2021-07-22 11:45:06 -04:00
jeremy moore
eed322d13b Use a map to store the transient per line info in the FileCache.
Saves memory compared to allocating arrays for all lines.
#rb ben.ingram


#ROBOMERGE-SOURCE: CL 16680895
#ROBOMERGE-BOT: (v835-16672529)

[CL 16680907 by jeremy moore in ue5-main branch]
2021-06-15 18:10:29 -04:00
PJ Kack
3bf0f9d6c1 FileCache: Restore the UE4 default value fc.NumFileCacheBlocks=256.
#jira UE-117562
#rb carlmagnus.nordin
#rnx

[CL 16670408 by PJ Kack in ue5-main branch]
2021-06-15 04:05:03 -04:00
Marc Audy
cac1fe0019 Merge UE5/Release-Engine-Staging @ CL# 15299266 to UE5/Main
This represents UE4/Main @ CL# 15277572

[CL 15299962 by Marc Audy in ue5-main branch]
2021-02-03 14:57:28 -04:00
Tim Smith
3c24615072 Fixing PVS 7.7 Issues:
warning V1062: The 'XYZ' class defines a custom 'new' operator. The 'delete' operator must also be defined.

#rb steve.robb
#jira UE-91644

[CL 15019000 by Tim Smith in ue5-main branch]
2021-01-08 08:16:38 -04:00
Michal Valient
95d19f95b1 [REVERB] Merging //UE4/Private-Reverb-Development@13832732
#rb graham.wihlidal, rune.stubbe, brian.karis, andrew.lauritzen, jeff.farris

[CL 13834854 by Michal Valient in ue5-main branch]
2020-07-06 18:58:26 -04:00
Marc Audy
11f5b21210 Merging //UE5/Release-Engine-Staging @ 13752110 to Main (//UE5/Main)
#rnx

[CL 13753156 by Marc Audy in ue5-main branch]
2020-06-23 18:40:00 -04:00
Matt Kuhlenschmidt
603a4119c5 Fix HAL/PlatformFileManager.h non-portable casing CIS issues
#rb none

[CL 13214257 by Matt Kuhlenschmidt in ue5-main branch]
2020-05-06 17:58:18 -04:00
ben ingram
8cf693bdad Fix data race when IFileCache handle is used by multiple threads
#rb none

#ROBOMERGE-SOURCE: CL 13152458 via CL 13161669 via CL 13161725 via CL 13161836
#ROBOMERGE-BOT: RELEASE (Release-Engine-Staging -> Main) (v688-13145358)

[CL 13161907 by ben ingram in Main branch]
2020-05-04 21:14:35 -04:00
jeff newquist
9fa4defb8c Fixed all size variants of IAsyncReadRequest so they correctly wait inside of WaitCompletionImpl for a callback to be completed before returning.
Normal read requests have this behavior, but size requests were not respecting this, which caused problems when the constructor launches a callback on another thread and then immediately calls WaitCompletion, such as in the callback lambda inside FFileCacheHandle::FFileCacheHandle / PushCompletedRequest.
#rb rune.stubbe
#jira none
#rnx

#ROBOMERGE-SOURCE: CL 12974187 in //UE4/Release-4.25/... via CL 12974195 via CL 12974203
#ROBOMERGE-BOT: RELEASE (Release-Engine-Staging -> Main) (v682-12900288)

[CL 12974208 by jeff newquist in Main branch]
2020-04-22 09:27:31 -04:00
ben ingram
73961fa70d Updates to FileCache to work better with shader preloading
- FileCache can dynamically allocate/release memory as needed
- Preloaded lines are locked in the cache.  One the preloaded memory has been read, the line is unlocked.  This prevents preloaded lines from being evicted before they're needed.
- Cache line size changed from 64k to 16k, reduce fragmentation due to locked preloaded lines
#rb none

#ROBOMERGE-SOURCE: CL 12491121 via CL 12491126 via CL 12491130
#ROBOMERGE-BOT: RELEASE (Release-Engine-Staging -> Main) (v673-12478461)

[CL 12491133 by ben ingram in Main branch]
2020-03-30 17:41:29 -04:00
Brandon Schaefer
c57bf5c0dc Fix mis-match malloc/delete, which was causing a check to fail
#jira UE-91200
#rb Ben.Ingram

[CL 12455956 by Brandon Schaefer in 4.25 branch]
2020-03-26 15:30:52 -04:00
Ben Ingram
bf98b39a7c #jira UE-89879
Add extra logging to try to get more information about crash
#rb none

[CL 11964426 by Ben Ingram in 4.25 branch]
2020-03-05 16:37:13 -05:00
Josh Adams
aa9705149b Copying Private-LoadTimes-4.24 stream to Main. Biggest changes are in Materials/Shader memory freezing.
#rb none

[CL 11282608 by Josh Adams in Main branch]
2020-02-06 13:13:41 -05:00