Revision 48ae5496516878768d7de241b9b7fbba91fbaa74 authored by Tim Foley on 19 June 2019, 14:23:49 UTC, committed by GitHub on 19 June 2019, 14:23:49 UTC
* Start exposing a new COM-lite API This change is mostly about exposing a new API to the Slang compiler that allows more fine-grained control over the compilation flow. The basic concepts in the new API are: * An `IGlobalSession` is the granularity at which we load/parse the Slang stdlib, and therefore gives applications a way to amortize startup cost for the library across multiple compiles. This is a concept that might be able to go away in a future version of Slang. * An `ISession` owns all the code that gets loaded/compiled/generated. Any `import`ed modules are shared across everything in a session (we don't re-parse/-check the code when we see another `import` for the same module). Any generic- or interface-based code in the session can be specialized using types from the same session (but not necessarily across sessions). * An `IModule` is the unit of code loading and scoping. It doesn't expose any API in this change, but would be the right scope for looking up types or entry points by name. * An `IProgram` is a "linked" combination of modules and entry points from which code can be generated and reflection information queried. This change re-uses the existing reflection API types, rather than introduce a new API that duplicates that functionality. That will probably change in a future revision. There are two major pieces of functionality added here that aren't related to the new API: * We now have an API concept of "entry point groups" which are one or more entry points that are intended to be used together so that they need to have non-overlapping parameters. For now this is being used to handle "hit groups" and local root signatures for ray tracing, but I'm not sure this is a concept we will keep in the long run. * We have a very special-case (client-application-specific) flag that ascribes special meaning to the `shared` keyword, so that it can be attached to global parameters to indicate that they are actually to be part of the local root signature rather than the global one for DXR. None of the API design (including naming) here is finalized; the only reason to check in the changes at this point to avoid having a long-running branch that leads to merge pain. Clients should *not* try to depend on the new API just yet, since it is still a work in progress. * fixup: clang warning * fixup: try to detect clang C++11 support * fixup * fixup * fixup * fixup * fixup: review feedback
1 parent 7c9298d
File | Mode | Size |
---|---|---|
docs | ||
examples | ||
external | ||
source | ||
tests | ||
tools | ||
.editorconfig | -rw-r--r-- | 937 bytes |
.gitattributes | -rw-r--r-- | 95 bytes |
.gitignore | -rw-r--r-- | 419 bytes |
.gitmodules | -rw-r--r-- | 406 bytes |
.travis.yml | -rw-r--r-- | 1.7 KB |
CODE_OF_CONDUCT.md | -rw-r--r-- | 3.1 KB |
LICENSE | -rw-r--r-- | 1.1 KB |
README.md | -rw-r--r-- | 6.7 KB |
appveyor.yml | -rw-r--r-- | 3.7 KB |
premake5.lua | -rw-r--r-- | 26.7 KB |
slang-com-helper.h | -rw-r--r-- | 4.8 KB |
slang-com-ptr.h | -rw-r--r-- | 4.8 KB |
slang.h | -rw-r--r-- | 106.8 KB |
slang.sln | -rw-r--r-- | 9.8 KB |
test.bat | -rw-r--r-- | 1.4 KB |
travis_build.sh | -rw-r--r-- | 304 bytes |
travis_test.sh | -rw-r--r-- | 435 bytes |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...