Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
MIGraphX
Commits
7b7b3aad
Commit
7b7b3aad
authored
Jul 08, 2022
by
charlie
Browse files
Change to maintain const objectness
parent
38f0ed63
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
14 deletions
+5
-14
src/include/migraphx/check_shapes.hpp
src/include/migraphx/check_shapes.hpp
+5
-14
No files found.
src/include/migraphx/check_shapes.hpp
View file @
7b7b3aad
...
...
@@ -38,20 +38,20 @@ struct check_shapes
const
shape
*
begin
;
const
shape
*
end
;
const
std
::
string
name
;
bool
dynamic_allowed
=
false
;
const
bool
dynamic_allowed
;
check_shapes
(
const
shape
*
b
,
const
shape
*
e
,
const
std
::
string
&
n
)
:
begin
(
b
),
end
(
e
),
name
(
n
)
check_shapes
(
const
shape
*
b
,
const
shape
*
e
,
const
std
::
string
&
n
,
const
bool
d
=
false
)
:
begin
(
b
),
end
(
e
),
name
(
n
)
,
dynamic_allowed
(
d
)
{
}
template
<
class
Op
>
check_shapes
(
const
shape
*
b
,
const
shape
*
e
,
const
Op
&
op
)
:
begin
(
b
),
end
(
e
),
name
(
op
.
name
())
check_shapes
(
const
shape
*
b
,
const
shape
*
e
,
const
Op
&
op
,
const
bool
d
=
false
)
:
begin
(
b
),
end
(
e
),
name
(
op
.
name
())
,
dynamic_allowed
(
d
)
{
}
template
<
class
Op
>
check_shapes
(
const
std
::
vector
<
shape
>&
s
,
const
Op
&
op
)
:
begin
(
s
.
data
()),
end
(
s
.
data
()
+
s
.
size
()),
name
(
op
.
name
())
check_shapes
(
const
std
::
vector
<
shape
>&
s
,
const
Op
&
op
,
const
bool
d
=
false
)
:
begin
(
s
.
data
()),
end
(
s
.
data
()
+
s
.
size
()),
name
(
op
.
name
())
,
dynamic_allowed
(
d
)
{
}
...
...
@@ -286,15 +286,6 @@ struct check_shapes
return
*
this
;
}
/*!
* Denotes that the shapes can be dynamic for the operator.
*/
const
check_shapes
&
allow_dynamic
()
{
dynamic_allowed
=
true
;
return
*
this
;
}
template
<
class
F
>
bool
same
(
F
f
)
const
{
...
...
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