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
ab236eec
Commit
ab236eec
authored
Aug 11, 2022
by
turneram
Browse files
Formatting
parent
b1126322
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
src/simplify_algebra.cpp
src/simplify_algebra.cpp
+6
-2
No files found.
src/simplify_algebra.cpp
View file @
ab236eec
...
@@ -816,14 +816,18 @@ struct find_conv_dot_horiz_fusion
...
@@ -816,14 +816,18 @@ struct find_conv_dot_horiz_fusion
auto
batch_size
=
input
->
get_shape
().
lens
().
front
();
auto
batch_size
=
input
->
get_shape
().
lens
().
front
();
auto
sequence_length
=
input
->
get_shape
().
lens
().
at
(
1
);
auto
sequence_length
=
input
->
get_shape
().
lens
().
at
(
1
);
auto
hidden_size
=
input
->
get_shape
().
lens
().
at
(
2
);
auto
hidden_size
=
input
->
get_shape
().
lens
().
at
(
2
);
auto
reshape
=
m
.
insert_instruction
(
std
::
next
(
input
),
make_op
(
"reshape"
,
{{
"dims"
,
{
batch_size
*
sequence_length
,
hidden_size
}}}),
input
);
auto
reshape
=
m
.
insert_instruction
(
std
::
next
(
input
),
make_op
(
"reshape"
,
{{
"dims"
,
{
batch_size
*
sequence_length
,
hidden_size
}}}),
input
);
auto
fused
=
m
.
insert_instruction
(
std
::
next
(
reshape
),
op
,
reshape
,
concat
);
auto
fused
=
m
.
insert_instruction
(
std
::
next
(
reshape
),
op
,
reshape
,
concat
);
int64_t
offset
=
0
;
int64_t
offset
=
0
;
for
(
auto
arg
:
range
(
start
,
last
))
for
(
auto
arg
:
range
(
start
,
last
))
{
{
fused
=
m
.
insert_instruction
(
fused
=
m
.
insert_instruction
(
std
::
next
(
fused
),
std
::
next
(
fused
),
make_op
(
"reshape"
,
{{
"dims"
,
{
batch_size
,
sequence_length
,
hidden_size
*
3
}}}),
make_op
(
"reshape"
,
{{
"dims"
,
{
batch_size
,
sequence_length
,
hidden_size
*
3
}}}),
fused
);
fused
);
int64_t
len
=
arg
->
get_shape
().
lens
()[
axis
];
int64_t
len
=
arg
->
get_shape
().
lens
()[
axis
];
m
.
replace_instruction
(
m
.
replace_instruction
(
...
...
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