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
8fbb7af9
Commit
8fbb7af9
authored
Aug 01, 2023
by
Khalique Ahmed
Browse files
some mlir changes
parent
94cf1bf3
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
src/targets/gpu/fuse_mlir.cpp
src/targets/gpu/fuse_mlir.cpp
+1
-1
src/targets/gpu/mlir.cpp
src/targets/gpu/mlir.cpp
+3
-3
No files found.
src/targets/gpu/fuse_mlir.cpp
View file @
8fbb7af9
...
...
@@ -179,7 +179,7 @@ struct find_mlir_op
}
top_inputs
.
push_back
(
input
);
instruction_ref
prev_input
=
mm
->
add_parameter
(
"y"
+
std
::
to_string
(
input_cnt
++
),
input
->
get_shape
());
mm
->
add_parameter
(
"y"
+
std
::
to_string
(
input_cnt
++
),
{
input
->
get_shape
()
.
type
(),
input
->
get_shape
().
lens
()}
);
for
(
const
auto
&
op
:
reverse
(
op_stream
))
{
prev_input
=
mm
->
add_instruction
(
op
,
{
prev_input
});
...
...
src/targets/gpu/mlir.cpp
View file @
8fbb7af9
...
...
@@ -767,9 +767,9 @@ void adjust_param_shapes(module& m, const std::vector<instruction_ref>& inputs)
{
auto
perm
=
find_permutation
(
input
);
auto
iperm
=
invert_permutation
(
perm
);
lens
=
reorder_dims
(
lens
,
i
perm
);
strides
=
reorder_dims
(
strides
,
i
perm
);
ops
.
push_back
(
make_op
(
"transpose"
,
{{
"permutation"
,
perm
}}));
lens
=
reorder_dims
(
lens
,
perm
);
strides
=
reorder_dims
(
strides
,
perm
);
ops
.
push_back
(
make_op
(
"transpose"
,
{{
"permutation"
,
i
perm
}}));
}
if
(
input
.
broadcasted
())
{
...
...
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