"vscode:/vscode.git/clone" did not exist on "dbe6e77472126174ad151b2ce5467bbca33a4d51"
sin.cpp 658 Bytes
Newer Older
1
2
3
4
5
#include <migraphx/gpu/sin.hpp>
#include <migraphx/operators.hpp>
#include <migraphx/manage_ptr.hpp>
#include <migraphx/config.hpp>
#include <migraphx/gpu/miopen.hpp>
6
7
#include <utility>

8
namespace migraphx {
Paul's avatar
Paul committed
9
inline namespace MIGRAPHX_INLINE_NS {
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
namespace gpu {

shape hip_sin::compute_shape(const std::vector<shape>& inputs) const
{
    check_shapes{inputs, *this}.has(2);
    return inputs.at(0);
}

argument hip_sin::compute(context& ctx, const shape&, const std::vector<argument>& args) const
{
    device::sin(ctx.get_stream().get(), args[1], args[0]);
    return args[1];
}

} // namespace gpu
Paul's avatar
Paul committed
25
} // namespace MIGRAPHX_INLINE_NS
Shucai Xiao's avatar
Shucai Xiao committed
26
} // namespace migraphx