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
548c3ade
Commit
548c3ade
authored
May 30, 2016
by
John Kessenich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Front-end: Complete GL_ARB_compute_shader, previous commit was missing new barriers.
This amends the previous commit, which ommitted barriers in version 420 for compute shader.
parent
d94c003f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
2 deletions
+32
-2
420.comp
Test/420.comp
+9
-0
420.comp.out
Test/baseResults/420.comp.out
+14
-0
Initialize.cpp
glslang/MachineIndependent/Initialize.cpp
+9
-2
No files found.
Test/420.comp
View file @
548c3ade
...
@@ -19,4 +19,12 @@ void main()
...
@@ -19,4 +19,12 @@ void main()
gl_MaxComputeImageUniforms +
gl_MaxComputeImageUniforms +
gl_MaxComputeAtomicCounters +
gl_MaxComputeAtomicCounters +
gl_MaxComputeAtomicCounterBuffers;
gl_MaxComputeAtomicCounterBuffers;
barrier();
memoryBarrier();
memoryBarrierAtomicCounter();
memoryBarrierBuffer();
memoryBarrierImage();
memoryBarrierShared();
groupMemoryBarrier();
}
}
\ No newline at end of file
Test/baseResults/420.comp.out
View file @
548c3ade
...
@@ -46,6 +46,13 @@ ERROR: node is still EOpNull!
...
@@ -46,6 +46,13 @@ ERROR: node is still EOpNull!
0:17 'sfoo' (shared 3-component vector of float)
0:17 'sfoo' (shared 3-component vector of float)
0:17 Constant:
0:17 Constant:
0:17 1057.000000
0:17 1057.000000
0:23 Barrier (global void)
0:24 MemoryBarrier (global void)
0:25 MemoryBarrierAtomicCounter (global void)
0:26 MemoryBarrierBuffer (global void)
0:27 MemoryBarrierImage (global void)
0:28 MemoryBarrierShared (global void)
0:29 GroupMemoryBarrier (global void)
0:? Linker Objects
0:? Linker Objects
0:? 'gl_WorkGroupSize' (const 3-component vector of uint WorkGroupSize)
0:? 'gl_WorkGroupSize' (const 3-component vector of uint WorkGroupSize)
0:? 2 (const uint)
0:? 2 (const uint)
...
@@ -99,6 +106,13 @@ ERROR: node is still EOpNull!
...
@@ -99,6 +106,13 @@ ERROR: node is still EOpNull!
0:17 'sfoo' (shared 3-component vector of float)
0:17 'sfoo' (shared 3-component vector of float)
0:17 Constant:
0:17 Constant:
0:17 1057.000000
0:17 1057.000000
0:23 Barrier (global void)
0:24 MemoryBarrier (global void)
0:25 MemoryBarrierAtomicCounter (global void)
0:26 MemoryBarrierBuffer (global void)
0:27 MemoryBarrierImage (global void)
0:28 MemoryBarrierShared (global void)
0:29 GroupMemoryBarrier (global void)
0:? Linker Objects
0:? Linker Objects
0:? 'gl_WorkGroupSize' (const 3-component vector of uint WorkGroupSize)
0:? 'gl_WorkGroupSize' (const 3-component vector of uint WorkGroupSize)
0:? 2 (const uint)
0:? 2 (const uint)
...
...
glslang/MachineIndependent/Initialize.cpp
View file @
548c3ade
...
@@ -1572,7 +1572,7 @@ void TBuiltIns::initialize(int version, EProfile profile, int spv, int vulkan)
...
@@ -1572,7 +1572,7 @@ void TBuiltIns::initialize(int version, EProfile profile, int spv, int vulkan)
stageBuiltins
[
EShLangTessControl
].
append
(
stageBuiltins
[
EShLangTessControl
].
append
(
"void barrier();"
"void barrier();"
);
);
if
((
profile
!=
EEsProfile
&&
version
>=
4
3
0
)
||
esBarrier
)
if
((
profile
!=
EEsProfile
&&
version
>=
4
2
0
)
||
esBarrier
)
stageBuiltins
[
EShLangCompute
].
append
(
stageBuiltins
[
EShLangCompute
].
append
(
"void barrier();"
"void barrier();"
);
);
...
@@ -1580,7 +1580,7 @@ void TBuiltIns::initialize(int version, EProfile profile, int spv, int vulkan)
...
@@ -1580,7 +1580,7 @@ void TBuiltIns::initialize(int version, EProfile profile, int spv, int vulkan)
commonBuiltins
.
append
(
commonBuiltins
.
append
(
"void memoryBarrier();"
"void memoryBarrier();"
);
);
if
((
profile
!=
EEsProfile
&&
version
>=
4
3
0
)
||
esBarrier
)
{
if
((
profile
!=
EEsProfile
&&
version
>=
4
2
0
)
||
esBarrier
)
{
commonBuiltins
.
append
(
commonBuiltins
.
append
(
"void memoryBarrierAtomicCounter();"
"void memoryBarrierAtomicCounter();"
"void memoryBarrierBuffer();"
"void memoryBarrierBuffer();"
...
@@ -3912,6 +3912,13 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, int spv, int vul
...
@@ -3912,6 +3912,13 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, int spv, int vul
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeImageUniforms"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeImageUniforms"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeAtomicCounters"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeAtomicCounters"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeAtomicCounterBuffers"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setVariableExtensions
(
"gl_MaxComputeAtomicCounterBuffers"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"barrier"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"memoryBarrierAtomicCounter"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"memoryBarrierBuffer"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"memoryBarrierImage"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"memoryBarrierShared"
,
1
,
&
E_GL_ARB_compute_shader
);
symbolTable
.
setFunctionExtensions
(
"groupMemoryBarrier"
,
1
,
&
E_GL_ARB_compute_shader
);
}
}
break
;
break
;
...
...
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