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
3628df8c
Commit
3628df8c
authored
Aug 04, 2023
by
Khalique Ahmed
Browse files
skip adding contiguous for scalars
parent
8b28251b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/auto_contiguous.cpp
src/auto_contiguous.cpp
+2
-2
No files found.
src/auto_contiguous.cpp
View file @
3628df8c
...
@@ -68,9 +68,9 @@ void auto_contiguous::apply(module& m) const
...
@@ -68,9 +68,9 @@ void auto_contiguous::apply(module& m) const
auto
new_args
=
args
;
auto
new_args
=
args
;
std
::
transform
(
args
.
begin
(),
args
.
end
(),
new_args
.
begin
(),
[
&
](
auto
in
)
{
std
::
transform
(
args
.
begin
(),
args
.
end
(),
new_args
.
begin
(),
[
&
](
auto
in
)
{
if
(
in
->
name
()
==
"contiguous"
or
in
->
name
()
==
"layout"
)
if
(
in
->
name
()
==
"contiguous"
or
in
->
name
()
==
"layout"
)
{
return
in
;
return
in
;
}
if
(
in
->
name
()
==
"@literal"
and
in
->
get_shape
().
standard
())
return
in
;
return
m
.
insert_instruction
(
ins
,
make_op
(
"contiguous"
),
in
);
return
m
.
insert_instruction
(
ins
,
make_op
(
"contiguous"
),
in
);
});
});
...
...
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