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
d309e02f
Unverified
Commit
d309e02f
authored
Jan 19, 2023
by
Paul Fultz II
Committed by
GitHub
Jan 19, 2023
Browse files
Only fuse add with layernorm when its used once (#1529)
This prevents multiple adds.
parent
8b651eee
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
src/targets/gpu/prefuse_ops.cpp
src/targets/gpu/prefuse_ops.cpp
+2
-1
No files found.
src/targets/gpu/prefuse_ops.cpp
View file @
d309e02f
...
...
@@ -100,7 +100,8 @@ struct find_add_layernorm
{
auto
matcher
()
const
{
return
match
::
layernorm
()(
match
::
var
(
"x"
)(
match
::
name
(
"add"
).
bind
(
"add"
)));
return
match
::
layernorm
()(
match
::
var
(
"x"
)(
match
::
name
(
"add"
)(
match
::
used_once
()).
bind
(
"add"
)));
}
void
apply
(
module
&
m
,
const
match
::
matcher_result
&
r
)
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