diff options
| author | jsmall-nvidia <jsmall@nvidia.com> | 2020-08-06 17:15:55 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-06 17:15:55 -0400 |
| commit | 20af567033dedea15abb22fb7d344d116d7b99c5 (patch) | |
| tree | fe176cd9d8366cbbd78889f8c8b51acf8a0d1653 /source/slang/slang-file-system.cpp | |
| parent | 3231048b328551edff9a923dec3f7bd46ed5aff8 (diff) | |
Emit spir-v using MemoryArena to stop memory leak (#1479)
* Use m_style for OSFindFilesResult
* Refactor of FindFilesResult.
* Fixes on linux for FindFiles.
* Simplify FindFilesState, and linux support for pattern matching.
* Small fixes to linux FindFilesState
* Fix typo on linux FindFiles
* Fix typo in linux FindFiles.
* Renamed some variables, and improved comments on FindFiles.
* Improve comments on FildFiles
* Small improvements around FindFiles.
* Refactor FindFiles again.. into a visitor and function in Path.
* Fix some problems on linux.
* Fix linux typo.
* Renamed os -> find-file-util
* find-file-utl -> directory-util
* Make delete of PathInfo explicit.
* Initialize alwaysCreateCollectedParam .
* WIP spir-v emit using MemoryArena
* Fix bug in spirv emit.
* Fix bug with handling null termination on strings in spirv emit.
* Small improvements in comments around emit spirv
* Remove the 'dst' from emitOperand - we can only emit to the current inst.
* Improve SpirV emit comments.
* Don't store the created instruction in the InstConstructScope - as it's always the m_currentInst.
Don't return the instruction after _beginInst.
Slight comment improvements.
Diffstat (limited to 'source/slang/slang-file-system.cpp')
| -rw-r--r-- | source/slang/slang-file-system.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/slang/slang-file-system.cpp b/source/slang/slang-file-system.cpp index ebe1eeb61..d3d1fd9f5 100644 --- a/source/slang/slang-file-system.cpp +++ b/source/slang/slang-file-system.cpp @@ -210,7 +210,8 @@ CacheFileSystem::~CacheFileSystem() { for (const auto& pair : m_uniqueIdentityMap) { - delete pair.Value; + PathInfo* pathInfo = pair.Value; + delete pathInfo; } } @@ -261,7 +262,8 @@ void CacheFileSystem::clearCache() { for (const auto& pair : m_uniqueIdentityMap) { - delete pair.Value; + PathInfo* pathInfo = pair.Value; + delete pathInfo; } m_uniqueIdentityMap.Clear(); |
