<feed xmlns='http://www.w3.org/2005/Atom'>
<title>slang.git/source/slang-capture-replay/slang-module.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>2024-07-23T15:45:26+00:00</updated>
<entry>
<title>Feature/capture (#4625)</title>
<updated>2024-07-23T15:45:26+00:00</updated>
<author>
<name>kaizhangNV</name>
<email>149626564+kaizhangNV@users.noreply.github.com</email>
</author>
<published>2024-07-23T15:45:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=986256ffb92ab7c8fc7cf9f2c424919a439a824f'/>
<id>urn:sha1:986256ffb92ab7c8fc7cf9f2c424919a439a824f</id>
<content type='text'>
* Add decoder

* Add a replay executable to consume the decoded content

Add file-processor.cpp/h where we implement the logic to process
the captured file block by block. Each block is:
function header + parameter buffer + function tailer + function
output[optional].

After reading one block, the block of data is sent to decoder module
to dispatch the corresponding API.

Add slang-decoder.cpp/h where we implement the logic to dispatch
the slang API according to the input block data.

- Rename api_callId.h to capture-format.h
- Renmae capture_utility.cpp to capture-utility.cpp
- Renmae capture_utility.h to capture-utility.h
- Change the #include file name accordingly.

* Reorganize source files structure

Move all the capture logic code into `capture` directory.
 - the capture code will be build with slang dll.

Move all the replay logic code into `relay` directoy.
 - the replay code is not part of slang dll, it will be built
   as a stand alone binary and link against slang dll.

Change the #include file names accordingly.

Add tools/slang-replay/main.cpp for the slang-replay stand alone
binary place holder. Will implement it later.

Update premake5.lua accordingly.

* Update cmake files

Update cmake files to change the build process for
capture and relay system.

 - capture component should be build with slang dll, so we
   should not include replay component.
 - replay component should be a separate executable tool, which
   should not include capture component.
 - In order to easy use our current cmake infrastructure, move
   the shared files to a `util` folder
 - change the header include path

* Redesgin the interfaces of consumers

Fix some issues in capture
Finish implementing all slang-decoder functions

* Fix the AppleClang build issue

* Address few comments

- Fix the weird indent issues.
- Correct the function name for CreateGlobalSession()
- Rename file-processor to captureFile-processor to be more specific.
- Use Slang::List instead of std::vector

* record/replay: name refactor change

Refactor the naming.

Change the name "encoder/capture" to "record".</content>
</entry>
<entry>
<title>Initial implementation for decl-tree reflection API (#4666)</title>
<updated>2024-07-18T17:11:19+00:00</updated>
<author>
<name>Sai Praveen Bangaru</name>
<email>31557731+saipraveenb25@users.noreply.github.com</email>
</author>
<published>2024-07-18T17:11:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=0d06ebcefb36a19710d87832fc1ea027e21281af'/>
<id>urn:sha1:0d06ebcefb36a19710d87832fc1ea027e21281af</id>
<content type='text'>
* Initial implementation for decl-tree reflection API

This patch adds Slang API methods for walking all the declarations in the AST.

We expose this functionality through an abstract `DeclReflection` class that can be a type, function or a variable declaration.
We also provide ways to cast the decl to a `FunctionReflection`, `TypeReflection` or `VariableReflection` and traverse through the child nodes (for instance, a struct type will have component variable declarations)

This patch also adds `ISlangInternal` as an internal COM interface to allow us to cast IGlobalSession to the internal Session pointer while bypassing any wrappers (such as the capture interface)

* Update slang.h

* Remove `ISlangInternal` (its causing a diamond pattern w.r.t `ISlangUnknown`) and use `ComPtr` for proper ref management.

* Update unit-test-decl-tree-reflection.cpp

* Change `FunctionDeclBase` to use `DeclRef` instead of directly using the decl.

* Update slang-reflection-api.cpp</content>
</entry>
<entry>
<title>Add API for querying dependency files on IModule (#4493)</title>
<updated>2024-06-27T15:35:17+00:00</updated>
<author>
<name>skallweitNV</name>
<email>64953474+skallweitNV@users.noreply.github.com</email>
</author>
<published>2024-06-27T15:35:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=cb610113605f62e784b63012b31b751acb6fac72'/>
<id>urn:sha1:cb610113605f62e784b63012b31b751acb6fac72</id>
<content type='text'>
* Add API for querying dependency files on IModule

* return nullptr</content>
</entry>
<entry>
<title>Add capture logic to other interfaces. (#4412)</title>
<updated>2024-06-21T03:59:33+00:00</updated>
<author>
<name>kaizhangNV</name>
<email>149626564+kaizhangNV@users.noreply.github.com</email>
</author>
<published>2024-06-21T03:59:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=d349fd9e1f65fd32b2f4ea0e38c5084256d0dd04'/>
<id>urn:sha1:d349fd9e1f65fd32b2f4ea0e38c5084256d0dd04</id>
<content type='text'>
* Add capture logic to other interfaces.

Add capture logics to ISession, IModule, ITypeConformance, IEntryPoint
ICompositeComponentType.

Add few encode methods to encode the array.

Fix some capture logic in global session. We will not need to encode
the null_ptr output before actual actual of the captured APIs.
Previously we used this as a place holder, but it's actually not
necessary, it can be detected if the output is not captured during
replay.

* capture/replay: dump the shader files to disk

Dump the shader files to disk.
Also set a default directory for the capture files.</content>
</entry>
<entry>
<title>Extend the COM-based API to support whole program compilation. (#4355)</title>
<updated>2024-06-12T16:45:50+00:00</updated>
<author>
<name>Yong He</name>
<email>yonghe@outlook.com</email>
</author>
<published>2024-06-12T16:45:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=ccc26c2d22d471ae649bf16f37ed1cd6cfbddd1b'/>
<id>urn:sha1:ccc26c2d22d471ae649bf16f37ed1cd6cfbddd1b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>capture/relay: Add capture interface classes (#4177)</title>
<updated>2024-05-17T16:43:08+00:00</updated>
<author>
<name>kaizhangNV</name>
<email>149626564+kaizhangNV@users.noreply.github.com</email>
</author>
<published>2024-05-17T16:43:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=9f786fdf71e90339e20979ef3ba8f073657f5a98'/>
<id>urn:sha1:9f786fdf71e90339e20979ef3ba8f073657f5a98</id>
<content type='text'>
* capture/relay: Add capture interface classes

Add `ModuleCapture` class for capturing `IModule`
  - The `IModule` can only be created from
    -- `ISession::loadModule`
    -- `ISession::loadModuleFromIRBlob`
    -- `ISession::loadModuleFromSource`
    -- `ISession::loadModuleFromSourceString`
    so, we create the `ModuleCapture` at those methods in `SessionCapture`
    class. We use a hash map to store a map from `IModule` to `ModuleCapture`
    to avoid creating new `ModuleCapture` when there is already an old one.
  - In `SessionCapture::getLoadedModule`, we will assert on not finding
    a `ModuleCapture` instance.

Add `EntryPointCapture` class for capturing `IEntryPoint`.
  - The `IEntryPoint` can only be created from:
    -- `IModule::findEntryPointByName`
    -- `IModule::findAndCheckEntryPoint`
    so, we create the `EntryPointCapture` at those methods in `ModuleCapture`.
    Similarly, we use a hash map to store a map from `IEntryPoint` to
    `EntryPointCapture`.
  - In `IModule::getDefinedEntryPoint`, we will assert on not finding
    a `EntryPointCapture` instance.

Add `CompositeComponentTypeCapture` class for capturing CompositeComponentType,
but since user is only exposed to `IComponentType`, so `CompositeComponentTypeCapture`
just inherits from `IComponentType`.
  - `CompositeComponentType` can only be created from:
    -- ISession::createCompositeComponentType
    so create it here.

Add `TypeConformanceCapture` class for capturing `ITypeConformance`.
  - The `ITypeConformance` can only be created from:
    -- `ISession::createTypeConformanceComponentType`
    so create it here.

In addition, because `EntryPointCapture` and `ModuleCapture` share a some
base class `IComponentType`, we generate the COM GUID for those two
classes to differentiate them.

* Fix the build issue

* Add nullptr check for output parameter

* define the SLANG_CAPTURE_ASSERT macro used in both debug and release build</content>
</entry>
</feed>
