Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wasm-watermarker
Project
Project
Details
Activity
Releases
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
nagayama15
wasm-watermarker
Commits
49bcfa57
Commit
49bcfa57
authored
Jul 19, 2019
by
nagayama15
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix order to visit expression node
parent
7ecdae7b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
1 deletion
+3
-1
Comparator.inl.hpp
src/kyut/Comparator.inl.hpp
+2
-0
OperandSwappingWatermarker.cpp
src/kyut/watermarker/OperandSwappingWatermarker.cpp
+1
-1
No files found.
src/kyut/Comparator.inl.hpp
View file @
49bcfa57
...
@@ -34,6 +34,8 @@ namespace wasm {
...
@@ -34,6 +34,8 @@ namespace wasm {
}
}
[[
nodiscard
]]
inline
bool
operator
<
(
const
Expression
&
a
,
const
Expression
&
b
)
{
[[
nodiscard
]]
inline
bool
operator
<
(
const
Expression
&
a
,
const
Expression
&
b
)
{
static_assert
(
Expression
::
NumExpressionIds
==
36
);
constexpr
auto
opt
=
[](
const
Expression
*
p
)
->
boost
::
optional
<
const
Expression
&>
{
constexpr
auto
opt
=
[](
const
Expression
*
p
)
->
boost
::
optional
<
const
Expression
&>
{
if
(
p
==
nullptr
)
{
if
(
p
==
nullptr
)
{
return
boost
::
none
;
return
boost
::
none
;
...
...
src/kyut/watermarker/OperandSwappingWatermarker.cpp
View file @
49bcfa57
...
@@ -156,9 +156,9 @@ namespace kyut::watermarker {
...
@@ -156,9 +156,9 @@ namespace kyut::watermarker {
SideEffect
visitSelect
(
wasm
::
Select
*
expr
)
{
SideEffect
visitSelect
(
wasm
::
Select
*
expr
)
{
return
(
std
::
max
)({
return
(
std
::
max
)({
visit
(
expr
->
condition
),
visit
(
expr
->
ifTrue
),
visit
(
expr
->
ifTrue
),
visit
(
expr
->
ifFalse
),
visit
(
expr
->
ifFalse
),
visit
(
expr
->
condition
),
});
});
}
}
...
...
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