summaryrefslogtreecommitdiffstats
path: root/tools/slang-test/test-context.cpp
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2025-01-22 09:40:15 -0800
committerGitHub <noreply@github.com>2025-01-22 09:40:15 -0800
commit8000e0ede34e920cc7f37d69a335d74a472eff42 (patch)
treeccf7b3c7fb97d3d5df3afd38fde9e3221e3349de /tools/slang-test/test-context.cpp
parent04353fb7602b7eb6a8b86193510ebe0c670b7724 (diff)
Cache and reuse glsl module. (#6152)
* Cache and reuse glsl module. * Fix. * Implement record/replay for the new api. * Fix record replay. * Fix test.
Diffstat (limited to 'tools/slang-test/test-context.cpp')
-rw-r--r--tools/slang-test/test-context.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/slang-test/test-context.cpp b/tools/slang-test/test-context.cpp
index bb9870dad..685ee1f2e 100644
--- a/tools/slang-test/test-context.cpp
+++ b/tools/slang-test/test-context.cpp
@@ -85,7 +85,10 @@ SlangResult TestContext::locateFileCheck()
Result TestContext::init(const char* inExePath)
{
- m_session = spCreateSession(nullptr);
+ SlangGlobalSessionDesc desc = {};
+ desc.enableGLSL = true;
+ slang_createGlobalSession2(&desc, &m_session);
+
if (!m_session)
{
return SLANG_FAIL;