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
4e06d7a2
Unverified
Commit
4e06d7a2
authored
Jan 20, 2019
by
John Kessenich
Committed by
GitHub
Jan 20, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1663 from jeffbolznv/reference_vs_memorymodel
More precisely check for the qualifiers that enable the vulkan memory model for buffer references.
parents
493dee0a
e135a489
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
4 deletions
+7
-4
spv.bufferhandle13.frag.out
Test/baseResults/spv.bufferhandle13.frag.out
+1
-3
Types.h
glslang/Include/Types.h
+5
-0
ParseHelper.cpp
glslang/MachineIndependent/ParseHelper.cpp
+1
-1
No files found.
Test/baseResults/spv.bufferhandle13.frag.out
View file @
4e06d7a2
...
...
@@ -4,13 +4,11 @@ spv.bufferhandle13.frag
// Id's are bound by 58
Capability Shader
Capability CapabilityVulkanMemoryModelKHR
Capability CapabilityPhysicalStorageBufferAddressesEXT
Extension "SPV_EXT_physical_storage_buffer"
Extension "SPV_KHR_storage_buffer_storage_class"
Extension "SPV_KHR_vulkan_memory_model"
1: ExtInstImport "GLSL.std.450"
MemoryModel PhysicalStorageBuffer64EXT
VulkanKHR
MemoryModel PhysicalStorageBuffer64EXT
GLSL450
EntryPoint Fragment 4 "main"
ExecutionMode 4 OriginUpperLeft
Source GLSL 450
...
...
glslang/Include/Types.h
View file @
4e06d7a2
...
...
@@ -537,6 +537,11 @@ public:
{
return
subgroupcoherent
||
workgroupcoherent
||
queuefamilycoherent
||
devicecoherent
||
coherent
||
volatil
||
restrict
||
readonly
||
writeonly
;
}
bool
bufferReferenceNeedsVulkanMemoryModel
()
const
{
// include qualifiers that map to load/store availability/visibility/nonprivate memory access operands
return
subgroupcoherent
||
workgroupcoherent
||
queuefamilycoherent
||
devicecoherent
||
coherent
||
nonprivate
;
}
bool
isInterpolation
()
const
{
...
...
glslang/MachineIndependent/ParseHelper.cpp
View file @
4e06d7a2
...
...
@@ -355,7 +355,7 @@ TIntermTyped* TParseContext::handleVariable(const TSourceLoc& loc, TSymbol* symb
intermediate
.
addIoAccessed
(
*
string
);
if
(
variable
->
getType
().
getBasicType
()
==
EbtReference
&&
variable
->
getType
().
getQualifier
().
isMemory
())
{
variable
->
getType
().
getQualifier
().
bufferReferenceNeedsVulkanMemoryModel
())
{
intermediate
.
setUseVulkanMemoryModel
();
}
...
...
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