https://github.com/shader-slang/slang
Revision 90444f8366255f274993ce4699738d9ab7cf4ee1 authored by Yong He on 15 June 2020, 16:04:53 UTC, committed by GitHub on 15 June 2020, 16:04:53 UTC
* Generate IRType for interfaces, and use them as the type of IRWitnessTable values. This results the following IR for the included test case: ``` [export("_S3tu010IInterface7Computep1pii")] let %1 : _ = key [export("_ST3tu010IInterface")] [nameHint("IInterface")] interface %IInterface : _(%1); [export("_S3tu04Impl7Computep1pii")] [nameHint("Impl.Compute")] func %Implx5FCompute : Func(Int, Int) { block %2( [nameHint("inVal")] param %inVal : Int): let %3 : Int = mul(%inVal, %inVal) return_val(%3) } [export("_SW3tu04Impl3tu010IInterface")] witness_table %4 : %IInterface { witness_table_entry(%1,%Implx5FCompute) } ``` * Fixes per code review comments. Moved interface type reference in IRWitnessTable from their type to operand[0]. * Fix typo in comment.
1 parent 36a06f1
Tip revision: 90444f8366255f274993ce4699738d9ab7cf4ee1 authored by Yong He on 15 June 2020, 16:04:53 UTC
Generate IRType for interfaces, and reference them as `operand[0]` in IRWitnessTable values (#1387)
Generate IRType for interfaces, and reference them as `operand[0]` in IRWitnessTable values (#1387)
Tip revision: 90444f8
File | Mode | Size |
---|---|---|
docs | ||
examples | ||
external | ||
prelude | ||
source | ||
tests | ||
tools | ||
.editorconfig | -rw-r--r-- | 937 bytes |
.gitattributes | -rw-r--r-- | 95 bytes |
.gitignore | -rw-r--r-- | 686 bytes |
.gitmodules | -rw-r--r-- | 774 bytes |
.travis.yml | -rw-r--r-- | 2.1 KB |
CODE_OF_CONDUCT.md | -rw-r--r-- | 3.1 KB |
LICENSE | -rw-r--r-- | 1.1 KB |
README.md | -rw-r--r-- | 7.4 KB |
appveyor.yml | -rw-r--r-- | 4.0 KB |
premake5.lua | -rw-r--r-- | 34.8 KB |
slang-com-helper.h | -rw-r--r-- | 4.8 KB |
slang-com-ptr.h | -rw-r--r-- | 4.8 KB |
slang-tag-version.h | -rw-r--r-- | 36 bytes |
slang.h | -rw-r--r-- | 128.0 KB |
slang.sln | -rw-r--r-- | 11.7 KB |
test.bat | -rw-r--r-- | 1.4 KB |
travis_build.sh | -rw-r--r-- | 460 bytes |
travis_test.sh | -rw-r--r-- | 435 bytes |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...