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
3c52207e
Commit
3c52207e
authored
Feb 14, 2016
by
John Kessenich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SPV capabilities: Add int16, int64, float16, and float64.
parent
103bef9d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
0 deletions
+26
-0
SpvBuilder.cpp
SPIRV/SpvBuilder.cpp
+24
-0
spv.400.frag.out
Test/baseResults/spv.400.frag.out
+1
-0
spv.double.comp.out
Test/baseResults/spv.double.comp.out
+1
-0
No files found.
SPIRV/SpvBuilder.cpp
View file @
3c52207e
...
...
@@ -165,6 +165,18 @@ Id Builder::makeIntegerType(int width, bool hasSign)
constantsTypesGlobals
.
push_back
(
std
::
unique_ptr
<
Instruction
>
(
type
));
module
.
mapInstruction
(
type
);
// deal with capabilities
switch
(
width
)
{
case
16
:
addCapability
(
CapabilityInt16
);
break
;
case
64
:
addCapability
(
CapabilityInt64
);
break
;
default
:
break
;
}
return
type
->
getResultId
();
}
...
...
@@ -185,6 +197,18 @@ Id Builder::makeFloatType(int width)
constantsTypesGlobals
.
push_back
(
std
::
unique_ptr
<
Instruction
>
(
type
));
module
.
mapInstruction
(
type
);
// deal with capabilities
switch
(
width
)
{
case
16
:
addCapability
(
CapabilityFloat16
);
break
;
case
64
:
addCapability
(
CapabilityFloat64
);
break
;
default
:
break
;
}
return
type
->
getResultId
();
}
...
...
Test/baseResults/spv.400.frag.out
View file @
3c52207e
...
...
@@ -10,6 +10,7 @@ Linked fragment stage:
// Id's are bound by 1104
Capability Shader
Capability Float64
Capability ClipDistance
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
...
...
Test/baseResults/spv.double.comp.out
View file @
3c52207e
...
...
@@ -10,6 +10,7 @@ Linked compute stage:
// Id's are bound by 62
Capability Shader
Capability Float64
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint GLCompute 4 "main" 26 33
...
...
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