diff options
| author | kaizhangNV <149626564+kaizhangNV@users.noreply.github.com> | 2024-05-08 09:13:45 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-08 09:13:45 -0700 |
| commit | 4f2330d059ab5943ddf33bfed37be6a0378d43a8 (patch) | |
| tree | 9e3a0790deee6248343d49a644ab9f0be7909901 /premake5.lua | |
| parent | eb3970897049269602cc18cee644e437c0aff928 (diff) | |
capture/replay: interface implementation 1 (#4122)
* capture/replay: interface implementation 1
- Add global session, filesystem, and session capture interface classes:
GlobalSessionCapture for IGlobalSession
FileSystemCapture for ISlangFileSystemExt
SessionCapture for ISession
- Add environment variables to enable it
The 2 variables are SLANG_CAPTURE_LAYER and SLANG_CAPTURE_LOG_LEVEL
SLANG_CAPTURE_LAYER:
In slang_createGlobalSession(), after the compiling/loading stdlib,
we will check the capture environment variable, if it's set to 1,
we will create a GlobalSessionCapture object and return to user
code.
SLANG_CAPTURE_LOG_LEVEL: This is to set the log level, user can
choose the loglevel to debug. (We can remove this when the feature
is fully implemented).
- Update premake file and cmake file to add the capture/replay source folder
* Fix Windows build error
Fix windows build error by adding the "SLANG_MCALL" keyword.
Change to use Slang::ComPtr for those captured object pointers
to simplify the resource management.
Use __func__ macro to print the function name in the log.
Diffstat (limited to 'premake5.lua')
| -rw-r--r-- | premake5.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/premake5.lua b/premake5.lua index b14844c8e..28dacf6b5 100644 --- a/premake5.lua +++ b/premake5.lua @@ -1609,6 +1609,8 @@ if enableEmbedStdLib then "source/slang/slang-lookup-glslstd450.cpp", "source/slang/slang-lookup-capability-defs.cpp" } + addSourceDir("source/slang-capture-replay") + if not targetInfo.isWindows then links { "pthread" } end @@ -1732,6 +1734,7 @@ standardProject("slang", "source/slang") "source/slang/slang-generated-capability-defs-impl.h", } + addSourceDir("source/slang-capture-replay") -- -- The most challenging part of building `slang` is that we need -- to invoke generators such as slang-cpp-extractor and slang-generate |
