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
d7b1895a
Commit
d7b1895a
authored
Jul 07, 2023
by
Khalique Ahmed
Browse files
Merge branch 'develop' of
https://github.com/ROCmSoftwarePlatform/AMDMIGraphX
into nhwc_workaround
parents
1add453a
a83371ca
Changes
62
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
22 deletions
+39
-22
tools/include/operation.hpp
tools/include/operation.hpp
+5
-3
tools/include/target.hpp
tools/include/target.hpp
+34
-19
No files found.
tools/include/operation.hpp
View file @
d7b1895a
...
...
@@ -261,11 +261,13 @@ auto compute_op(rank<1>,
template
<
class
T
,
class
F
>
argument
compute_op
(
rank
<
0
>
,
const
T
&
x
,
const
shape
&
,
const
std
::
vector
<
argument
>&
,
const
std
::
vector
<
module_ref
>&
,
const
shape
&
output
,
const
std
::
vector
<
argument
>&
inputs
,
const
std
::
vector
<
module_ref
>&
module_args
,
F
)
{
if
(
module_args
.
empty
())
return
compute_op
(
x
,
output
,
inputs
);
std
::
string
name
=
x
.
name
();
MIGRAPHX_THROW
(
"Not computable: "
+
name
);
}
...
...
tools/include/target.hpp
View file @
d7b1895a
...
...
@@ -45,6 +45,8 @@
namespace
migraphx
{
inline
namespace
MIGRAPHX_INLINE_NS
{
struct
value
;
#ifdef DOXYGEN
/// An interface for a compilation target
...
...
@@ -123,28 +125,41 @@ supported_segments target_find_supported(T&, const_module_ref, support_metric)
}
<%
interface
(
'
target
'
,
virtual
(
'
name
'
,
returns
=
'
std
::
string
'
,
const
=
True
),
virtual
(
'
get_passes
'
,
ctx
=
'
context
&
'
,
options
=
'
const
compile_options
&
'
,
returns
=
'
std
::
vector
<
pass
>
'
,
const
=
True
),
virtual
(
'
get_context
'
,
returns
=
'
context
'
,
const
=
True
),
virtual
(
'
find_supported
'
,
returns
=
'
supported_segments
'
,
mod
=
'
const_module_ref
'
,
m
=
'
support_metric
'
,
const
=
True
,
default
=
'
target_find_supported
'
),
virtual
(
'
copy_to
'
,
returns
=
'
argument
'
,
input
=
'
const
argument
&
'
,
const
=
True
,
default
=
'
copy_to_target
'
),
virtual
(
'
copy_from
'
,
returns
=
'
argument
'
,
input
=
'
const
argument
&
'
,
const
=
True
,
default
=
'
copy_from_target
'
),
virtual
(
'
allocate
'
,
s
=
'
const
shape
&
'
,
returns
=
'
argument
'
,
const
=
True
,
default
=
'
target_allocate
'
)
)
%>
interface
(
'
target
'
,
virtual
(
'
name
'
,
returns
=
'
std
::
string
'
,
const
=
True
),
virtual
(
'
get_passes
'
,
ctx
=
'
context
&
'
,
options
=
'
const
compile_options
&
'
,
returns
=
'
std
::
vector
<
pass
>
'
,
const
=
True
),
virtual
(
'
get_context
'
,
returns
=
'
context
'
,
const
=
True
),
virtual
(
'
find_supported
'
,
returns
=
'
supported_segments
'
,
mod
=
'
const_module_ref
'
,
m
=
'
support_metric
'
,
const
=
True
,
default
=
'
target_find_supported
'
),
virtual
(
'
copy_to
'
,
returns
=
'
argument
'
,
input
=
'
const
argument
&
'
,
const
=
True
,
default
=
'
copy_to_target
'
),
virtual
(
'
copy_from
'
,
returns
=
'
argument
'
,
input
=
'
const
argument
&
'
,
const
=
True
,
default
=
'
copy_from_target
'
),
virtual
(
'
allocate
'
,
s
=
'
const
shape
&
'
,
returns
=
'
argument
'
,
const
=
True
,
default
=
'
target_allocate
'
))
%>
#endif
void
migraphx_to_value
(
value
&
v
,
const
target
&
t
);
void
migraphx_from_value
(
const
value
&
v
,
target
&
t
);
}
// namespace MIGRAPHX_INLINE_NS
}
// namespace migraphx
...
...
Prev
1
2
3
4
Next
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