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
fe36d210
Commit
fe36d210
authored
Nov 02, 2023
by
Manupa Karunaratne
Browse files
* clang tidy issues
parent
fc5db1ad
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
9 deletions
+7
-9
src/targets/gpu/fuse_mlir.cpp
src/targets/gpu/fuse_mlir.cpp
+7
-9
No files found.
src/targets/gpu/fuse_mlir.cpp
View file @
fe36d210
...
...
@@ -482,7 +482,7 @@ struct find_mlir_standalone_attention_op
{
continue
;
}
if
(
scale_ins
.
name
()
==
"mul"
&&
!
found_mul
)
if
(
scale_ins
.
name
()
==
"mul"
&&
not
found_mul
)
{
found_mul
=
true
;
continue
;
...
...
@@ -504,7 +504,7 @@ struct find_mlir_standalone_attention_op
void
apply
(
module_pass_manager
&
mpm
,
const
match
::
matcher_result
&
r
)
const
{
if
(
!
check
(
r
))
if
(
not
check
(
r
))
{
return
;
}
...
...
@@ -524,23 +524,21 @@ struct find_mlir_attention_fused_ops : public find_mlir_standalone_attention_op
bool
check
(
const
match
::
matcher_result
&
r
)
const
{
if
(
!
find_mlir_standalone_attention_op
::
check
(
r
))
if
(
not
find_mlir_standalone_attention_op
::
check
(
r
))
{
return
false
;
}
auto
trailing_pm_ins
=
r
.
instructions
[
"trailing_pm"
];
// input after contiguous
auto
*
trailing_pm
=
trailing_pm_ins
->
module_inputs
().
front
();
// Whitelist pointwise operators.
if
(
std
::
any_of
(
trailing_pm
->
begin
(),
trailing_pm
->
end
(),
[
&
](
const
auto
&
i
)
{
return
not
is_pointwise_op_supported_by_mlir
(
i
);
}))
return
false
;
return
true
;
return
not
(
std
::
any_of
(
trailing_pm
->
begin
(),
trailing_pm
->
end
(),
[
&
](
const
auto
&
i
)
{
return
not
is_pointwise_op_supported_by_mlir
(
i
);
}));
}
void
apply
(
module_pass_manager
&
mpm
,
const
match
::
matcher_result
&
r
)
const
{
if
(
!
check
(
r
))
if
(
not
check
(
r
))
{
return
;
}
...
...
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