pad.cpp 669 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include <migraphx/gpu/pad.hpp>
#include <migraphx/operators.hpp>
#include <migraphx/manage_ptr.hpp>
#include <migraphx/gpu/miopen.hpp>
#include <migraphx/gpu/device/pad.hpp>
#include <utility>

namespace migraphx {
inline namespace MIGRAPHX_INLINE_NS {
namespace gpu {

shape hip_pad::compute_shape(std::vector<shape> inputs) const
{
    inputs.pop_back();
    return op.compute_shape(inputs);
}

Khalique's avatar
Khalique committed
18
argument hip_pad::compute(context& ctx, const shape&, const std::vector<argument>& args) const
19
20
21
22
23
24
25
{
    return device::pad(ctx.get_stream().get(), args.back(), args.front(), op.value, op.pads);
}

} // namespace gpu
} // namespace MIGRAPHX_INLINE_NS
} // namespace migraphx