<feed xmlns='http://www.w3.org/2005/Atom'>
<title>slang.git/source/compiler-core/slang-source-loc.h, branch master</title>
<subtitle>Making it easier to work with shaders</subtitle>
<id>https://git.yummers.dev/slang.git/atom?h=master</id>
<link rel='self' href='https://git.yummers.dev/slang.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/'/>
<updated>2025-06-05T05:55:11+00:00</updated>
<entry>
<title>Fix missing debug info for the included slang file (#7281)</title>
<updated>2025-06-05T05:55:11+00:00</updated>
<author>
<name>Lujin Wang</name>
<email>143145775+lujinwangnv@users.noreply.github.com</email>
</author>
<published>2025-06-05T05:55:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=0c4c63b4a575f45f5dcf03f26b78becd36b0efca'/>
<id>urn:sha1:0c4c63b4a575f45f5dcf03f26b78becd36b0efca</id>
<content type='text'>
* Fix missing debug info in the included slang file

Issue:
https://github.com/shader-slang/slang/issues/7271

Debug info including DebugFunction, DebugLocation, and DebugValue
are missing in IR for "#included" Slang shader file.

The included shader file was not added to TranslationUnit's source
file list, therefore mapSourceFileToDebugSourceInst.add() was not
called for the source in generateIRForTranslationUnit(), and later
mapSourceFileToDebugSourceInst.tryGetValue() could not get value
for the source to add DebugLocationDecoration, which led to missing
DebugFunction, DebugLocation and other debug info for the included
file in IR.

Adding the include file in TranslationUnit's source file list fixes
the issue.

* Add source file using PreprocessorHandler

Call _addSourceFile from FrontEndPreprocessorHandler::handleFileDependency.

* Just use FrontEndPreprocessorHandler

* Make _addSourceFile public

* format code

* Distingush the included source file

* Add m_includedFileSet to avoid adding dup file

HashSet&lt;SourceFile*&gt; m_includedFileSet;

---------

Co-authored-by: ArielG-NV &lt;159081215+ArielG-NV@users.noreply.github.com&gt;
Co-authored-by: slangbot &lt;186143334+slangbot@users.noreply.github.com&gt;</content>
</entry>
<entry>
<title>Implemented #pragma warning (#6748)</title>
<updated>2025-04-24T22:48:37+00:00</updated>
<author>
<name>Ronan</name>
<email>ro.cailleau@gmail.com</email>
</author>
<published>2025-04-24T22:48:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=5f632cd204b7a85f3a97b6c316c5a34f9fc8193e'/>
<id>urn:sha1:5f632cd204b7a85f3a97b6c316c5a34f9fc8193e</id>
<content type='text'>
* Implemented #pragma warning

Based on https://learn.microsoft.com/en-us/cpp/preprocessor/warning?view=msvc-170

* Make #pragma warning work with #includes.

- SourceLoc are not sorted by inclusion order.
- Construct a mapping from SourceLoc to "absolute locations" that are sorted by inclusion order (roughly represents a location in a raw file with all #include resolved).
- The absolute location can be used in the pragma warning timeline

* Added preprocessor #pragma warning tests.

- Fixed #pragma warning (push / pop) SourceLoc
- Fixed unused directiveLoc in #pragma warning parsing

* #pragma warning: Added some comments and fixed some typos

* Cleaned #pragma warning preprocessor implementation.

---------

Co-authored-by: Yong He &lt;yonghe@outlook.com&gt;</content>
</entry>
<entry>
<title>format</title>
<updated>2024-10-29T06:49:26+00:00</updated>
<author>
<name>Ellie Hermaszewska</name>
<email>ellieh@nvidia.com</email>
</author>
<published>2024-10-29T06:49:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=f65d756bff8d4c5cbc15bd0322a2ae8e6b896a21'/>
<id>urn:sha1:f65d756bff8d4c5cbc15bd0322a2ae8e6b896a21</id>
<content type='text'>
* format

* Minor test fixes

* enable checking cpp format in ci</content>
</entry>
<entry>
<title>Move the file public header files to `include` dir (#4636)</title>
<updated>2024-07-17T17:53:19+00:00</updated>
<author>
<name>kaizhangNV</name>
<email>149626564+kaizhangNV@users.noreply.github.com</email>
</author>
<published>2024-07-17T17:53:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=2db15080085856ed9b5f20642dbb354aac59a888'/>
<id>urn:sha1:2db15080085856ed9b5f20642dbb354aac59a888</id>
<content type='text'>
* Move the file public header files to `include` dir

Close the issue (#4635).

Move the following headers files to a `include` dir
located at root dir of slang repo:

 slang-com-helper.h -&gt; include/slang-com-helper.h
 slang-com-ptr.h -&gt; include/slang-com-ptr.h
 slang-gfx.h -&gt; include/slang-gfx.h
 slang.h -&gt; include/slang.h

Change cmake/SlangTarget.cmake to add include path to
every target, and change the source file to use
"#include &lt;slang.h&gt;" to include the public headers.

The source code update is by the script like follow:

```
fileNames_slang=$(grep -r "\".*slang\.h\"" source/ -l)

for fileName in "${fileNames_slang[@]}"
do
    echo "$fileName"
    sed -i "s/\".*slang\.h\"/\"slang\.h\"/" $fileName
done
```

* Fix the test issues

* Fix cpu test issues by adding include seach path

* Update cmake to not add include path for every target

Also change "#include &lt;slang.h&gt;" to "include "slang.h" " to
make the coding style consistent with other slang code.

* Change public include to private include for unit-test and slang-glslang</content>
</entry>
<entry>
<title>Add slangc interface to compile and use ir modules. (#3615)</title>
<updated>2024-02-24T00:39:46+00:00</updated>
<author>
<name>Yong He</name>
<email>yonghe@outlook.com</email>
</author>
<published>2024-02-24T00:39:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=401d8cdb12ae69aeb216c80c9bb90240d8359649'/>
<id>urn:sha1:401d8cdb12ae69aeb216c80c9bb90240d8359649</id>
<content type='text'>
* Add slangc interface to compile and use ir modules.

* Fix glsl scalar layout settings not copied to target.

* Fix.

* Cleanups.</content>
</entry>
<entry>
<title>Add API for querying and reusing precompiled binary modules. (#3614)</title>
<updated>2024-02-22T15:14:55+00:00</updated>
<author>
<name>Yong He</name>
<email>yonghe@outlook.com</email>
</author>
<published>2024-02-22T15:14:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=8ec5b3e6ef2e7e5c3adaa5accb375676b1c09ff0'/>
<id>urn:sha1:8ec5b3e6ef2e7e5c3adaa5accb375676b1c09ff0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Support `include` for pulling file into the current module. (#3377)</title>
<updated>2023-12-05T18:06:19+00:00</updated>
<author>
<name>Yong He</name>
<email>yonghe@outlook.com</email>
</author>
<published>2023-12-05T18:06:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=1050e0eb96d6c8e7a6cfb253458155e1014625c3'/>
<id>urn:sha1:1050e0eb96d6c8e7a6cfb253458155e1014625c3</id>
<content type='text'>
* Support `include` for pulling file into the current module.

* Add auto-completion, hover info and goto-def support.

* Disable warning for missing `module` declaration for now.

---------

Co-authored-by: Yong He &lt;yhe@nvidia.com&gt;</content>
</entry>
<entry>
<title>nsight Aftermath crash example (#2984)</title>
<updated>2023-07-18T22:45:38+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2023-07-18T22:45:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=1fe5e83f3dcc8ef0efa2dd083ebdfab5d0f101a9'/>
<id>urn:sha1:1fe5e83f3dcc8ef0efa2dd083ebdfab5d0f101a9</id>
<content type='text'>
* Small fixes and improvements around reflection tool.

* Make PrettyWriter printing a class.

* Aftermath crash demo WIP.

* Enable aftermath in test project.

* Setting failCount.

* Dumping out of source maps.

* Improve comments.
Simplify handling of compile products.

* Other small fixes to aftermath example.

* Added Emit SourceLocType.
Track sourcemap association meaning.
Improved documentation.

* Small improvements.

* Capture debug information for D3D11/D3D12/Vulkan.

* Enable debug info.

* Small improvements.

* Improve aftermath example README.md.</content>
</entry>
<entry>
<title>Make SourceMap a value type (#2812)</title>
<updated>2023-04-19T21:06:56+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2023-04-19T21:06:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=588991f6df3d6813378721166a7260990835817e'/>
<id>urn:sha1:588991f6df3d6813378721166a7260990835817e</id>
<content type='text'>
* #include an absolute path didn't work - because paths were taken to always be relative.

* Moved JSON source map writing logic to JSONSourceMapUtil.

* Use ArtifactHandler to read/write SourceMaps.
Use ObjectCastableAdapter to hold SourceMap
Only serialize SourceMap &lt;-&gt; JSON on demand.

* Make some types swappable.

* BoxValue impl.

* Added asBoxValue.

* Remove const get funcs.

* Fix typo in asBoxValue.

* Fix another typo in asBoxValue.

* Slightly simplify conversion to blob of SourceMap.

* Small fix for asBoxValue</content>
</entry>
<entry>
<title>Round trip source map (#2810)</title>
<updated>2023-04-17T19:09:37+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2023-04-17T19:09:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=90a9f43573ec0777c2ae4fa20c8fdc51a4ae7b3a'/>
<id>urn:sha1:90a9f43573ec0777c2ae4fa20c8fdc51a4ae7b3a</id>
<content type='text'>
* #include an absolute path didn't work - because paths were taken to always be relative.

* Make output of obfuscation locs work in a slang-module.

* Tidy up detection for writing serialized source locs.

* Support for .zip references.
Handling of obfuscated source maps read from containers.
A test to check obfuscated source map working on a module.

* When using obfuscation, always obfuscate locs instead of stripping them. We keep a source map, so we can still produce reasonable errors.

* Write out source locs if debug information is enabled.

* Check output without sourcemap.

* Small fixes.

* Small improvements around hash calculation for source map name.

* Disable test that fails on x86 gcc linux for now.

* Fix issues around obfuscated source map using lines rather than columns.
Fix some issues around encoding/decoding.

* Make column calculation of source locs take into account utf8/tabs.
Don't special case obfuscated source map for lookup for source loc.

* Support following multiple source maps.

* Small fixes/improvements around SourceMap lookup.</content>
</entry>
</feed>
