<feed xmlns='http://www.w3.org/2005/Atom'>
<title>slang.git/source/slang/slang-emit-precedence.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-11-05T17:47:26+00:00</updated>
<entry>
<title>Move switch statement bodies to their own lines (#5493)</title>
<updated>2024-11-05T17:47:26+00:00</updated>
<author>
<name>Ellie Hermaszewska</name>
<email>ellieh@nvidia.com</email>
</author>
<published>2024-11-05T17:47:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=b118451e301d734e3e783b3acdf871f3f6ea851c'/>
<id>urn:sha1:b118451e301d734e3e783b3acdf871f3f6ea851c</id>
<content type='text'>
* Move switch statement bodies to their own lines

* format

---------

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>Clean up some behavior of operator% (#1060)</title>
<updated>2019-09-18T20:20:22+00:00</updated>
<author>
<name>Tim Foley</name>
<email>tfoleyNV@users.noreply.github.com</email>
</author>
<published>2019-09-18T20:20:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=a431d4f6da9e463c349c2e3819e87a83c8f2e043'/>
<id>urn:sha1:a431d4f6da9e463c349c2e3819e87a83c8f2e043</id>
<content type='text'>
Work on #1059

The `%` operator in the Slang implementation had several issues, and this change tries to address some of them:

* Renamed most occurences of "mod" describing this operator to be "rem" for "remainder" to better match its semantics in HLSL

* Split the operator into distinct integer and floating-point variants (`IRem` and `FRem`) to simplify having different codegen for the two

* Added floating-point variants of `operator%` and `operator%=` to the stdlib.

* Added custom C++ codegen for `kIROp_FRem` such that it maps to the standard C/C++ `remainder()` function

* Added custom GLSL codegen so that `kIROp_FRem` maps to the GLSL `mod()` function (which isn't correct...)

* Added a test case to confirm that D3D11, D3D12, and CPU targets all agree on the definition of floating-point `%`

* Fixed `render-test-tool` to allow a negative integer in a `data=...` specification. This didn't end up being used in the final test, but still seems like a good fix.

* Added a customized baseline for the Vulkan flavor of that test to confirm that we are *not* compiling correctly to SPIR-V just yet

Addressing the correctness of the output for GLSL/SPIR-V will have to come as a later change given that the operation we want is not exposed directly by unextended GLSL.</content>
</entry>
<entry>
<title>Split out target code generation from CLikeSourceEmitter (#976)</title>
<updated>2019-06-06T21:48:39+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2019-06-06T21:48:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=fc083a75b94ac4b4e735b4a7ff566191b9123f74'/>
<id>urn:sha1:fc083a75b94ac4b4e735b4a7ff566191b9123f74</id>
<content type='text'>
* * Added SourceStyle to CLikeSourceEmitter, to limit cases to actual target types.
* Made Impl methods _ prefixed
* Small tidyup

* * SourceStream -&gt; SourceWriter
* use slang-emit- prefix on SourceWriter file

* * Remove EmitContext -&gt; merge into CLikeSourceEmitter

* slang-c-like-source-emitter -&gt; slang-emit-source.cpp

* ExtensionUsageTracker -&gt; GLSLExtensionTracker
slang-extension-usage-tracker.cpp/.h -&gt; slang-emit-glsl-extension-tracker.cpp/.h

* emit-source.cpp.h -&gt; emit-c-like.cpp/.h

* Small fix to move where some _ prefixed functions are declared in CLikeSourceEmitter.

* * CLikeSourceEmitter::CInfo -&gt; Desc
* Functions to get and find CodeGenTarget by name
* Split out empty language impls
* Create an impl based on SourceStyle

* * CodeGenTarget conversion to and from string

* Move HLSL specific functions to HLSLEmitSource.

* Emitting texture and image types.

* Move move GLSL specific functionality to GLSLSourceEmitter

* Split more out of slang-emit-c-like

* Refactor more out of slang-emit-c-like

* * tryEmitIRInstExprImpl(IRInst* inst, IREmitMode mode, const EmitOpInfo&amp; inOuterPrec)
* Fix bug around output of uintBitsToFloat

* More work refactoring out target specifics from slang-emit-c-like

* Move functions that are only implemented once in GLSL impl into their Impl method.

* Move rate qualification out of slang-emit-c-like

* * Added getEmitOpForOp - allows for table usage so different ops can be dealt with the same way
* Moved vector comparison to slang-emit-glsl
*

* * Use EmitOpInfo to control output in slang-emit-c-like.cpp for unary ops

* Move more functionality from CLikeSourceEmitter to HLSLSourceEmitter

* Make output of parameters implementaion specific.

* Extracted interpolation modifiers.

* Remove IR from methods that don't need them.

* Remove IR from method names.

* Refactor handling of output of types - to make the impls implement the full path without lots of cases for specific impls

* Add variable declaration modifiers and matrix layout to larget specific in slang-emit.

* Make target specific internal functions _ prefixed.
</content>
</entry>
<entry>
<title>WIP: Support for other source target language (#971)</title>
<updated>2019-05-31T17:17:34+00:00</updated>
<author>
<name>jsmall-nvidia</name>
<email>jsmall@nvidia.com</email>
</author>
<published>2019-05-31T17:17:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.yummers.dev/slang.git/commit/?id=b81ff3ef968d1cc4e954b31a1812b3c391d17b02'/>
<id>urn:sha1:b81ff3ef968d1cc4e954b31a1812b3c391d17b02</id>
<content type='text'>
* WIP: Setting up C/Cpp source compilation targets.

* WIP: Emitting C/CPP.

* WIP: Split out SourceSink, and use it for source output on emit.

* SourceSink -&gt; SourceStream

* * Made SourceStream use m_ prefixing of members.
* Make all methods use lower camel
* Removed methods from SourceStream interface that are not used externally (use _ prefixing)
* Improvements to documentation

* EmitContext is now effectively empty, so just use SharedEmitContext as EmitContext.

* SharedEmitContext -&gt; EmitContext

* Methods to LowerCamel in emit.cpp

* Split out EmitContext and ExtensionUsageTracker into separate files.

* Split out EmitVisitor into slang-c-like-source-emitter files.

* EmitVisitor -&gt; CLikeSourceEmitter

* Tidy up around CLikeSourceEmitter - simplify header.

* Small tidy up - removing repeated comments that are in header.

* Remove EmitContext paramter threading.

* Small tidy up.
Use prefixed macros for slang-c-like-source-emitter.h

* Small tidy up in slang-c-like-source-emitter.cpp

* First pass at splitting out UnmangleContext.

* MangledNameParser -&gt; MangledLexer.

* WIP making EmitOp (EOp) enum available outside of cpp

* Generating EmitOpInfo from macro.

* Split out emit precedence handling.
Don't use kOp_ style anymore, just use an array indexed by EmitOp.

* Disable C simple test for now.

* Keep g++/clang happy with token pasting.

* Fix win32 narrowing warning.
</content>
</entry>
</feed>
