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
7c9accb6
Commit
7c9accb6
authored
Oct 11, 2019
by
Ryan Harrison
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unnecessary semi-colons and add warning about them
These are causing integration issues with Chromium down stream since it is more strict about these.
parent
69670380
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
18 additions
and
17 deletions
+18
-17
BUILD.gn
BUILD.gn
+1
-0
CMakeLists.txt
CMakeLists.txt
+2
-2
GlslangToSpv.cpp
SPIRV/GlslangToSpv.cpp
+4
-4
Types.h
glslang/Include/Types.h
+2
-2
ParseHelper.h
glslang/MachineIndependent/ParseHelper.h
+1
-1
iomapper.h
glslang/MachineIndependent/iomapper.h
+6
-6
ShaderLang.h
glslang/Public/ShaderLang.h
+2
-2
No files found.
BUILD.gn
View file @
7c9accb6
...
...
@@ -168,6 +168,7 @@ source_set("glslang_sources") {
"-Wno-unused-variable",
"-Wno-missing-field-initializers",
"-Wno-newline-eof",
"-Wextra-semi",
]
}
if (is_win && !is_clang) {
...
...
CMakeLists.txt
View file @
7c9accb6
...
...
@@ -90,12 +90,12 @@ endif(WIN32)
if
(
${
CMAKE_CXX_COMPILER_ID
}
MATCHES
"GNU"
)
add_compile_options
(
-Wall -Wmaybe-uninitialized -Wuninitialized -Wunused -Wunused-local-typedefs
-Wunused-parameter -Wunused-value
-Wunused-variable -Wunused-but-set-parameter -Wunused-but-set-variable -fno-exceptions
)
-Wunused-parameter -Wunused-value
-Wunused-variable -Wunused-but-set-parameter -Wunused-but-set-variable -fno-exceptions -Wextra-semi
)
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
add_compile_options
(
-fno-rtti
)
elseif
(
${
CMAKE_CXX_COMPILER_ID
}
MATCHES
"Clang"
)
add_compile_options
(
-Wall -Wuninitialized -Wunused -Wunused-local-typedefs
-Wunused-parameter -Wunused-value
-Wunused-variable
)
-Wunused-parameter -Wunused-value
-Wunused-variable -Wextra-semi
)
add_compile_options
(
-Wno-reorder
)
# disable this from -Wall, since it happens all over.
add_compile_options
(
-fno-rtti
)
elseif
(
${
CMAKE_CXX_COMPILER_ID
}
MATCHES
"MSVC"
)
...
...
SPIRV/GlslangToSpv.cpp
View file @
7c9accb6
...
...
@@ -100,11 +100,11 @@ struct OpDecorations {
spv
::
Decoration
precision
;
#ifdef GLSLANG_WEB
void
addNoContraction
(
spv
::
Builder
&
,
spv
::
Id
)
const
{
}
;
void
addNonUniform
(
spv
::
Builder
&
,
spv
::
Id
)
const
{
}
;
void
addNoContraction
(
spv
::
Builder
&
,
spv
::
Id
)
const
{
}
void
addNonUniform
(
spv
::
Builder
&
,
spv
::
Id
)
const
{
}
#else
void
addNoContraction
(
spv
::
Builder
&
builder
,
spv
::
Id
t
)
{
builder
.
addDecoration
(
t
,
noContraction
);
}
;
void
addNonUniform
(
spv
::
Builder
&
builder
,
spv
::
Id
t
)
{
builder
.
addDecoration
(
t
,
nonUniform
);
}
;
void
addNoContraction
(
spv
::
Builder
&
builder
,
spv
::
Id
t
)
{
builder
.
addDecoration
(
t
,
noContraction
);
}
void
addNonUniform
(
spv
::
Builder
&
builder
,
spv
::
Id
t
)
{
builder
.
addDecoration
(
t
,
nonUniform
);
}
protected
:
spv
::
Decoration
noContraction
;
spv
::
Decoration
nonUniform
;
...
...
glslang/Include/Types.h
View file @
7c9accb6
...
...
@@ -135,8 +135,8 @@ struct TSampler { // misnomer now; includes images, textures without sampler,
bool
isYuv
()
const
{
return
yuv
;
}
#endif
void
setCombined
(
bool
c
)
{
combined
=
c
;
}
void
setBasicType
(
TBasicType
t
)
{
type
=
t
;
}
;
TBasicType
getBasicType
()
const
{
return
type
;
}
;
void
setBasicType
(
TBasicType
t
)
{
type
=
t
;
}
TBasicType
getBasicType
()
const
{
return
type
;
}
bool
isShadow
()
const
{
return
shadow
;
}
bool
isArrayed
()
const
{
return
arrayed
;
}
...
...
glslang/MachineIndependent/ParseHelper.h
View file @
7c9accb6
...
...
@@ -283,7 +283,7 @@ public:
const
TString
*
entryPoint
=
nullptr
);
virtual
~
TParseContext
();
bool
obeyPrecisionQualifiers
()
const
{
return
precisionManager
.
respectingPrecisionQualifiers
();
}
;
bool
obeyPrecisionQualifiers
()
const
{
return
precisionManager
.
respectingPrecisionQualifiers
();
}
void
setPrecisionDefaults
();
void
setLimits
(
const
TBuiltInResource
&
)
override
;
...
...
glslang/MachineIndependent/iomapper.h
View file @
7c9accb6
...
...
@@ -114,7 +114,7 @@ public:
bool
doAutoLocationMapping
()
const
;
TSlotSet
::
iterator
findSlot
(
int
set
,
int
slot
);
bool
checkEmpty
(
int
set
,
int
slot
);
bool
validateInOut
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
override
{
return
true
;
}
;
bool
validateInOut
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
override
{
return
true
;
}
int
reserveSlot
(
int
set
,
int
slot
,
int
size
=
1
);
int
getFreeSlot
(
int
set
,
int
base
,
int
size
=
1
);
int
resolveSet
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
)
override
;
...
...
@@ -125,7 +125,7 @@ public:
void
addStage
(
EShLanguage
stage
)
override
{
if
(
stage
<
EShLangCount
)
stageMask
[
stage
]
=
true
;
}
;
}
uint32_t
computeTypeLocationSize
(
const
TType
&
type
,
EShLanguage
stage
);
TSlotSetMap
slots
;
...
...
@@ -191,7 +191,7 @@ public:
typedef
std
::
map
<
TString
,
int
>
TVarSlotMap
;
// <resourceName, location/binding>
typedef
std
::
map
<
int
,
TVarSlotMap
>
TSlotMap
;
// <resourceKey, TVarSlotMap>
TDefaultGlslIoResolver
(
const
TIntermediate
&
intermediate
);
bool
validateBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
override
{
return
true
;
}
;
bool
validateBinding
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
/*ent*/
)
override
{
return
true
;
}
TResourceType
getResourceType
(
const
glslang
::
TType
&
type
)
override
;
int
resolveInOutLocation
(
EShLanguage
stage
,
TVarEntryInfo
&
ent
)
override
;
int
resolveUniformLocation
(
EShLanguage
/*stage*/
,
TVarEntryInfo
&
ent
)
override
;
...
...
@@ -209,7 +209,7 @@ public:
int
buildStorageKey
(
EShLanguage
stage
,
TStorageQualifier
type
)
{
assert
(
static_cast
<
uint32_t
>
(
stage
)
<=
0x0000ffff
&&
static_cast
<
uint32_t
>
(
type
)
<=
0x0000ffff
);
return
(
stage
<<
16
)
|
type
;
}
;
}
protected
:
// Use for mark pre stage, to get more interface symbol information.
...
...
@@ -242,7 +242,7 @@ struct TVarLivePair : std::pair<const TString, TVarEntryInfo> {
const_cast
<
TString
&>
(
first
)
=
_Right
.
first
;
second
=
_Right
.
second
;
return
(
*
this
);
}
;
}
};
typedef
std
::
vector
<
TVarLivePair
>
TVarLiveVector
;
...
...
@@ -253,7 +253,7 @@ public:
virtual
~
TIoMapper
()
{}
// grow the reflection stage by stage
bool
virtual
addStage
(
EShLanguage
,
TIntermediate
&
,
TInfoSink
&
,
TIoMapResolver
*
);
bool
virtual
doMap
(
TIoMapResolver
*
,
TInfoSink
&
)
{
return
true
;
}
;
bool
virtual
doMap
(
TIoMapResolver
*
,
TInfoSink
&
)
{
return
true
;
}
};
// I/O mapper for OpenGL
...
...
glslang/Public/ShaderLang.h
View file @
7c9accb6
...
...
@@ -487,7 +487,7 @@ public:
environment
.
target
.
version
=
version
;
}
void
getStrings
(
const
char
*
const
*
&
s
,
int
&
n
)
{
s
=
strings
;
n
=
numStrings
;
}
;
void
getStrings
(
const
char
*
const
*
&
s
,
int
&
n
)
{
s
=
strings
;
n
=
numStrings
;
}
#ifdef ENABLE_HLSL
void
setEnvTargetHlslFunctionality1
()
{
environment
.
target
.
hlslFunctionality1
=
true
;
}
...
...
@@ -775,7 +775,7 @@ public:
TProgram
();
virtual
~
TProgram
();
void
addShader
(
TShader
*
shader
)
{
stages
[
shader
->
stage
].
push_back
(
shader
);
}
std
::
list
<
TShader
*>&
getShaders
(
EShLanguage
stage
)
{
return
stages
[
stage
];
}
;
std
::
list
<
TShader
*>&
getShaders
(
EShLanguage
stage
)
{
return
stages
[
stage
];
}
// Link Validation interface
bool
link
(
EShMessages
);
const
char
*
getInfoLog
();
...
...
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