<feed xmlns='http://www.w3.org/2005/Atom'>
<title>slang.git/source/slang/slang-serialize-source-loc.cpp, 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-05-12T17:28:05+00:00</updated>
<entry>
<title>Cleanups related to RIFF support (#7041)</title>
<updated>2025-05-12T17:28:05+00:00</updated>
<author>
<name>Theresa Foley</name>
<email>10618364+tangent-vector@users.noreply.github.com</email>
</author>
<published>2025-05-12T17:28:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=4c76b275907cf2d764f3fc51468d1c58635a10c1'/>
<id>urn:sha1:4c76b275907cf2d764f3fc51468d1c58635a10c1</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Remove support for ad hoc Slang IR compression (#6834)</title>
<updated>2025-04-16T19:28:39+00:00</updated>
<author>
<name>Theresa Foley</name>
<email>10618364+tangent-vector@users.noreply.github.com</email>
</author>
<published>2025-04-16T19:28:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=2b20e9e150225f8cb75f7be2061f5ec99cbb2f66'/>
<id>urn:sha1:2b20e9e150225f8cb75f7be2061f5ec99cbb2f66</id>
<content type='text'>
* Remove support for ad hoc Slang IR compression

This change is part of a larger effort to clean up the approach to
serialization in the Slang compiler. The overall goal is to simplify
and streamline all of the serialization-related logic, so that we are
left with code that is less "clever," and easier to understand for
contributors to the codebase.

Removing support for compression of serialized Slang IR has
benefits that include:

* Reduction in code complexity: consider things like the subtle way
  that the `FOURCC`s for compressed chunks were being computed from
  the uncompressed versions, and the mental overhead that goes into
  understanding that, for anybody who would dare to touch this code.

* Reduction in testing burden: there have been, de facto, two
  very different code paths for serialization of the Slang IR, and
  it is not clear that the existing test corpus for Slang has
  sufficient coverage for both options. By having only a single code
  path, every test that performs any amount of IR serialization helps
  with test coverage of that one path.

* Opportunity to explore alternatives. This is perhaps a reiteration
  of the first point, but once the code is stripped down to the
  simplest thing that could possibly work (I am not claiming it has
  reached that point yet), it becomes easier for contributors to
  understand, and it becomes more tractable for somebody to come along
  with an improved approach that performs better (in either
  compression ratio or performance) while still being maintainable.

In my own local setup, I found that removing support for Slang IR
compression led to the `slang-core-module-generated.h` file increasing
in size from 46.1MB to 47.4MB. This increase in the `.h` file size
for the core library binary only resulted in a release build of
`slang.dll` increasing from 20.0MB to 20.2MB. Removing the ad hoc
compression support has almost no impact on the size of actual binary
Slang modules *so long* as the additional LZ4 compression step is
being applied to them.

* format code

---------

Co-authored-by: slangbot &lt;186143334+slangbot@users.noreply.github.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>Use ankerl/unordered_dense as a hashmap implementation (#3036)</title>
<updated>2023-08-16T00:57:47+00:00</updated>
<author>
<name>Ellie Hermaszewska</name>
<email>ellieh@nvidia.com</email>
</author>
<published>2023-08-16T00:57:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=45d9961a6a86d184248ef84f6a07125b0c224f97'/>
<id>urn:sha1:45d9961a6a86d184248ef84f6a07125b0c224f97</id>
<content type='text'>
* Correct namespace for getClockFrequency

* missing const

* Add missing assignment operator

* Remove unused variables

* Return correct modified variable

* Use stable hash code for file system identity

* terse static_assert

* Structured binding for map iteration

* Make (==) and getHashCode const on many structs

* Add ConstIterator for LinkedList

* Replace uses of ItemProxy::getValue with Dictionary::at

* Extract list of loads from gradientsMap before updating it

* Const correctness in type layout

* Add unordered_dense hashmap submodule

* Use wyhash or getHashCode in slang-hash.h

* refactor slang-hash.h

* Use ankerl/unordered_dense as a hashmap implementation

Notable changes:
- The subscript operator returns a reference directly to the value,
  rather than a lazy ItemProxy (pair of dict pointer and key)

slang-profile time (95% over 10 runs):

- Before: 6.3913906 (±0.0746)
- After:  5.9276123 (±0.0964)

* 64 bit hash for strings

So they have the same hash as char buffers with the same contents

* Narrowing warnings for gcc to match msvc

* revert back to c++17

* Correct c++ version for msvc

* Use path to unordered_dense which keeps tests happy

* Do not assign to and read from map in same expression

* Remove redundant map operations in primal-hoist

* Split out stable hash functions into slang-stable-hash.h

* 64 bit hash by default

* regenerate vs projects

* Correct return type from HashSetBase::getCount()

* correct width for call to Dictionary::reserve

* Use stable hash for obfuscated module ids

* Signed int for reserve

* clearer variable naming

* Parameterize Dictionary on hash and equality functors

* Allow heterogenous lookup for Dictionary

* missing const

* Use set over operator[] in some places

* Remove unused function

* s/at/getValue</content>
</entry>
<entry>
<title>Dictionary using lowerCamel (#2835)</title>
<updated>2023-04-25T14:43:29+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2023-04-25T14:43:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0'/>
<id>urn:sha1:7b7c095b37e85ca3a8f55eff1c3d9643d467b8e0</id>
<content type='text'>
* #include an absolute path didn't work - because paths were taken to always be relative.

* WIP lowerCamel Dictionary.

* WIP more lowerCamel fixes for Dictionary.

* Add/Remove/Clear

* GetValue/Contains

* Fix tabs in dictionary.
Count -&gt; getCount

* Fix fields with caps.

* Key -&gt; key
Value -&gt; value
Use m_ for members where appropriate.
Use lowerCamel in linked list.

* Some small fixes/improvements to Dictionary.

* Kick CI.</content>
</entry>
<entry>
<title>Language Server improvements. (#2269)</title>
<updated>2022-06-13T19:20:35+00:00</updated>
<author>
<name>Yong He</name>
<email>yonghe@outlook.com</email>
</author>
<published>2022-06-13T19:20:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=c90c6ab750ab05dd6d337e4f857958b8f3d00153'/>
<id>urn:sha1:c90c6ab750ab05dd6d337e4f857958b8f3d00153</id>
<content type='text'>
* Language Server improvements.
- Improve parser robustness around `attribute_syntax`.
- Exclude instance members in a static query.
- Coloring accessors
- Improved signature help cursor range check.

* Add expected test result.

* Language server: support configuring predefined macros.

* Fix constructor highlighting.

* Improving performance by supporting incremental text change notifications.

* Fix UTF16 positions and highlighting of constructor calls.

* Add completion suggestions for HLSL semantics.

* Fix tests.

* Fix: don't skip static variables in a static query.

* Include literal init expr value in hover text.

* Fix scenarios where completion failed to trigger.

* Fixing language server protocol field initializations.

Co-authored-by: Yong He &lt;yhe@nvidia.com&gt;</content>
</entry>
<entry>
<title>Serialized stdlib working (#1603)</title>
<updated>2020-11-18T19:52:58+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2020-11-18T19:52:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=d898d561e3c76ecf38db434ec7fbb4bbd0e25cb2'/>
<id>urn:sha1:d898d561e3c76ecf38db434ec7fbb4bbd0e25cb2</id>
<content type='text'>
* #include an absolute path didn't work - because paths were taken to always be relative.

* Mangling/module name extraction for GenericDecl

* Add comment on SerialFilter to explain re-enabling Stmt.

* Support setting up SyntaxDecl when reconstructed after deserialization.

* Improvements to setup SyntaxDecl.

* Fix typo so can read compressed SourceLocs.

* Fix issue with SourceManger.</content>
</entry>
<entry>
<title>Include hierarchy output (#1595)</title>
<updated>2020-11-11T14:56:50+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2020-11-11T14:56:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=8f0895e0f8257da2fd10b6325931627a9a1792ba'/>
<id>urn:sha1:8f0895e0f8257da2fd10b6325931627a9a1792ba</id>
<content type='text'>
* #include an absolute path didn't work - because paths were taken to always be relative.

* Improve diagnostic for token pasting.

* Token paste location test.

* Output include hierarchy.

* WIP on includes hierarchy.

* Improved include hierarchy output - to handle source files without tokens.
Improved test case.

* Small comment improvements.
Fixed a typo with not returning a reference.

* Slight simplification of the ViewInitiatingHierarchy, by adding GetOrAddValue to Dictionary.

* Remove the need for ViewInitiatingHierarchy type.

* Improve output of path in diagnostic for includes hierarchy.

* Remove comment in diagnostic for token-paste-location.slang

* Update command line docs to include `-output-includes`

Co-authored-by: Yong He &lt;yonghe@outlook.com&gt;</content>
</entry>
<entry>
<title>Generalizing Serialization (#1563)</title>
<updated>2020-09-30T17:28:56+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2020-09-30T17:28:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=274c20a5eb133779a9d890ca79120815fb92b04e'/>
<id>urn:sha1:274c20a5eb133779a9d890ca79120815fb92b04e</id>
<content type='text'>
* First pass at generalizing serializer.

* Split out ReflectClassInfo

* Use the general ReflectClassInfo

* Fix some typos in debug generalized serialization.

* Add calculation of classIds.
Make distinct addCopy/add on SerialClasses.

* Write up of more generalized serialization

* WIP to transition from ASTSerialReader/Writer etc to generalized SerialReader/Writer and associated types.

* Improvements to SerialExtraObjects.
Keep RefObjects in scope in factory

* Compiles with Serial refactor - doesn't quite work yet.

* First pass serialization appears to work with refector.

* Split out type info for general slang types.

* Split out slang-serialize-misc-type-info.h

* DebugSerialData -&gt; SerialSourecLocData
DebugSerialReader -&gt; SerialSourceLocReader
DebugSerialWriter -&gt; SerialSourceLocWriter

* Remove unused template that only compiles on VS.

* Fix warning around unused function on non-VS.</content>
</entry>
</feed>
