Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
glslang
Commits
137e071c
Unverified
Commit
137e071c
authored
Mar 27, 2019
by
John Kessenich
Committed by
GitHub
Mar 27, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1740 from ewerness-nv/callableincoming
Callables shouldn't have incoming ray flags
parents
5125eb58
659060b9
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
32 additions
and
45 deletions
+32
-45
spv.RayCallable.rcall.out
Test/baseResults/spv.RayCallable.rcall.out
+25
-38
spv.RayCallable_Errors.rcall.out
Test/baseResults/spv.RayCallable_Errors.rcall.out
+6
-4
spv.RayCallable.rcall
Test/spv.RayCallable.rcall
+0
-2
spv.RayCallable_Errors.rcall
Test/spv.RayCallable_Errors.rcall
+1
-0
Initialize.cpp
glslang/MachineIndependent/Initialize.cpp
+0
-1
No files found.
Test/baseResults/spv.RayCallable.rcall.out
View file @
137e071c
spv.RayCallable.rcall
spv.RayCallable.rcall
// Module Version 10000
// Module Version 10000
// Generated by (magic number): 80007
// Generated by (magic number): 80007
// Id's are bound by 3
8
// Id's are bound by 3
0
Capability RayTracingNV
Capability RayTracingNV
Extension "SPV_NV_ray_tracing"
Extension "SPV_NV_ray_tracing"
1: ExtInstImport "GLSL.std.450"
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
MemoryModel Logical GLSL450
EntryPoint CallableNV 4 "main" 11 14
19
EntryPoint CallableNV 4 "main" 11 14
Source GLSL 460
Source GLSL 460
SourceExtension "GL_NV_ray_tracing"
SourceExtension "GL_NV_ray_tracing"
Name 4 "main"
Name 4 "main"
...
@@ -15,18 +15,15 @@ spv.RayCallable.rcall
...
@@ -15,18 +15,15 @@ spv.RayCallable.rcall
Name 11 "gl_LaunchIDNV"
Name 11 "gl_LaunchIDNV"
Name 13 "size"
Name 13 "size"
Name 14 "gl_LaunchSizeNV"
Name 14 "gl_LaunchSizeNV"
Name 17 "curFlags"
Name 16 "dataBlock"
Name 19 "gl_IncomingRayFlagsNV"
MemberName 16(dataBlock) 0 "data1"
Name 24 "dataBlock"
Name 18 ""
MemberName 24(dataBlock) 0 "data1"
Name 29 "data0"
Name 26 ""
Name 37 "data0"
Decorate 11(gl_LaunchIDNV) BuiltIn LaunchIdNV
Decorate 11(gl_LaunchIDNV) BuiltIn LaunchIdNV
Decorate 14(gl_LaunchSizeNV) BuiltIn LaunchSizeNV
Decorate 14(gl_LaunchSizeNV) BuiltIn LaunchSizeNV
Decorate 19(gl_IncomingRayFlagsNV) BuiltIn IncomingRayFlagsNV
Decorate 16(dataBlock) Block
Decorate 24(dataBlock) Block
Decorate 18 Location 1
Decorate 26 Location 1
Decorate 29(data0) Location 0
Decorate 37(data0) Location 0
2: TypeVoid
2: TypeVoid
3: TypeFunction 2
3: TypeFunction 2
6: TypeInt 32 0
6: TypeInt 32 0
...
@@ -35,39 +32,29 @@ spv.RayCallable.rcall
...
@@ -35,39 +32,29 @@ spv.RayCallable.rcall
10: TypePointer Input 7(ivec3)
10: TypePointer Input 7(ivec3)
11(gl_LaunchIDNV): 10(ptr) Variable Input
11(gl_LaunchIDNV): 10(ptr) Variable Input
14(gl_LaunchSizeNV): 10(ptr) Variable Input
14(gl_LaunchSizeNV): 10(ptr) Variable Input
16: TypePointer Function 6(int)
16(dataBlock): TypeStruct 6(int)
18: TypePointer Input 6(int)
17: TypePointer IncomingCallableDataNV 16(dataBlock)
19(gl_IncomingRayFlagsNV): 18(ptr) Variable Input
18: 17(ptr) Variable IncomingCallableDataNV
22: 6(int) Constant 1
19: TypeInt 32 1
24(dataBlock): TypeStruct 6(int)
20: 19(int) Constant 0
25: TypePointer IncomingCallableDataNV 24(dataBlock)
21: 6(int) Constant 256
26: 25(ptr) Variable IncomingCallableDataNV
22: TypePointer IncomingCallableDataNV 6(int)
27: TypeInt 32 1
24: 6(int) Constant 2
28: 27(int) Constant 0
25: 19(int) Constant 1
29: 6(int) Constant 256
26: TypeFloat 32
30: TypePointer IncomingCallableDataNV 6(int)
27: TypeVector 26(float) 4
32: 6(int) Constant 2
28: TypePointer CallableDataNV 27(fvec4)
33: 27(int) Constant 1
29(data0): 28(ptr) Variable CallableDataNV
34: TypeFloat 32
35: TypeVector 34(float) 4
36: TypePointer CallableDataNV 35(fvec4)
37(data0): 36(ptr) Variable CallableDataNV
4(main): 2 Function None 3
4(main): 2 Function None 3
5: Label
5: Label
9(id): 8(ptr) Variable Function
9(id): 8(ptr) Variable Function
13(size): 8(ptr) Variable Function
13(size): 8(ptr) Variable Function
17(curFlags): 16(ptr) Variable Function
12: 7(ivec3) Load 11(gl_LaunchIDNV)
12: 7(ivec3) Load 11(gl_LaunchIDNV)
Store 9(id) 12
Store 9(id) 12
15: 7(ivec3) Load 14(gl_LaunchSizeNV)
15: 7(ivec3) Load 14(gl_LaunchSizeNV)
Store 13(size) 15
Store 13(size) 15
20: 6(int) Load 19(gl_IncomingRayFlagsNV)
23: 22(ptr) AccessChain 18 20
Store 17(curFlags) 20
Store 23 21
21: 6(int) Load 17(curFlags)
ExecuteCallableNV 24 25
23: 6(int) BitwiseAnd 21 22
Store 17(curFlags) 23
31: 30(ptr) AccessChain 26 28
Store 31 29
ExecuteCallableNV 32 33
Return
Return
FunctionEnd
FunctionEnd
Test/baseResults/spv.RayCallable_Errors.rcall.out
View file @
137e071c
...
@@ -24,10 +24,12 @@ ERROR: 0:19: 'gl_WorldToObjectNV' : undeclared identifier
...
@@ -24,10 +24,12 @@ ERROR: 0:19: 'gl_WorldToObjectNV' : undeclared identifier
ERROR: 0:19: '=' : cannot convert from ' temp float' to ' temp highp 4X3 matrix of float'
ERROR: 0:19: '=' : cannot convert from ' temp float' to ' temp highp 4X3 matrix of float'
ERROR: 0:20: 'gl_HitTNV' : undeclared identifier
ERROR: 0:20: 'gl_HitTNV' : undeclared identifier
ERROR: 0:21: 'gl_HitKindNV' : undeclared identifier
ERROR: 0:21: 'gl_HitKindNV' : undeclared identifier
ERROR: 0:22: 'reportIntersectionNV' : no matching overloaded function found
ERROR: 0:22: 'gl_IncomingRayFlagsNV' : undeclared identifier
ERROR: 0:23: 'ignoreIntersectionNV' : no matching overloaded function found
ERROR: 0:22: '=' : cannot convert from ' temp float' to ' temp highp uint'
ERROR: 0:24: 'terminateRayNV' : no matching overloaded function found
ERROR: 0:23: 'reportIntersectionNV' : no matching overloaded function found
ERROR: 28 compilation errors. No code generated.
ERROR: 0:24: 'ignoreIntersectionNV' : no matching overloaded function found
ERROR: 0:25: 'terminateRayNV' : no matching overloaded function found
ERROR: 30 compilation errors. No code generated.
SPIR-V is not generated for failed compile or link
SPIR-V is not generated for failed compile or link
Test/spv.RayCallable.rcall
View file @
137e071c
...
@@ -8,8 +8,6 @@ void main()
...
@@ -8,8 +8,6 @@ void main()
{
{
uvec3 id = gl_LaunchIDNV;
uvec3 id = gl_LaunchIDNV;
uvec3 size = gl_LaunchSizeNV;
uvec3 size = gl_LaunchSizeNV;
uint curFlags = gl_IncomingRayFlagsNV;
curFlags = curFlags & gl_RayFlagsOpaqueNV;
data1 = 256U;
data1 = 256U;
executeCallableNV(2,1);
executeCallableNV(2,1);
}
}
Test/spv.RayCallable_Errors.rcall
View file @
137e071c
...
@@ -19,6 +19,7 @@ void main()
...
@@ -19,6 +19,7 @@ void main()
mat4x3 e11 = gl_WorldToObjectNV; // ERROR, unsupported builtin in stage
mat4x3 e11 = gl_WorldToObjectNV; // ERROR, unsupported builtin in stage
float e12 = gl_HitTNV; // ERROR, unsupported builtin in stage
float e12 = gl_HitTNV; // ERROR, unsupported builtin in stage
float e13 = gl_HitKindNV; // ERROR, unsupported builtin in stage
float e13 = gl_HitKindNV; // ERROR, unsupported builtin in stage
uint curFlags = gl_IncomingRayFlagsNV; // ERROR, unsupported builtin in stage
reportIntersectionNV(1.0, 1U); // ERROR, unsupported builtin in stage
reportIntersectionNV(1.0, 1U); // ERROR, unsupported builtin in stage
ignoreIntersectionNV(); // ERROR, unsupported builtin in stage
ignoreIntersectionNV(); // ERROR, unsupported builtin in stage
terminateRayNV(); // ERROR, unsupported builtin in stage
terminateRayNV(); // ERROR, unsupported builtin in stage
...
...
glslang/MachineIndependent/Initialize.cpp
View file @
137e071c
...
@@ -6242,7 +6242,6 @@ void TBuiltIns::initialize(int version, EProfile profile, const SpvVersion& spvV
...
@@ -6242,7 +6242,6 @@ void TBuiltIns::initialize(int version, EProfile profile, const SpvVersion& spvV
const
char
*
callableDecls
=
const
char
*
callableDecls
=
"in uvec3 gl_LaunchIDNV;"
"in uvec3 gl_LaunchIDNV;"
"in uvec3 gl_LaunchSizeNV;"
"in uvec3 gl_LaunchSizeNV;"
"in uint gl_IncomingRayFlagsNV;"
"
\n
"
;
"
\n
"
;
stageBuiltins
[
EShLangRayGenNV
].
append
(
rayGenDecls
);
stageBuiltins
[
EShLangRayGenNV
].
append
(
rayGenDecls
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment