"docs/en_US/CustomizeAssessor.md" did not exist on "8b9bcf163f7704821ef430e94f0b8367d8434af2"
target.cpp 565 Bytes
Newer Older
Paul's avatar
Paul committed
1
2
3
4
#include <migraph/gpu/target.hpp>
#include <migraph/gpu/lowering.hpp>
#include <migraph/gpu/write_literals.hpp>
#include <migraph/gpu/context.hpp>
Paul's avatar
Paul committed
5
6

namespace migraph {
Paul's avatar
Paul committed
7
namespace gpu {
Paul's avatar
Paul committed
8

Paul's avatar
Paul committed
9
10
11
12
std::vector<pass> target::get_passes(migraph::context&) const
{
    return {lowering{}, write_literals{}};
}
Paul's avatar
Paul committed
13

Paul's avatar
Paul committed
14
std::string target::name() const { return "miopen"; }
Paul's avatar
Paul committed
15

Paul's avatar
Paul committed
16
migraph::context target::get_context() const
Paul's avatar
Paul committed
17
{
Paul's avatar
Paul committed
18
    return context{share(make_obj<miopen_handle>(&miopenCreate)),
Paul's avatar
Paul committed
19
                   share(create_rocblas_handle_ptr())};
Paul's avatar
Paul committed
20
21
}

Paul's avatar
Paul committed
22
} // namespace gpu
Paul's avatar
Paul committed
23

Paul's avatar
Paul committed
24
} // namespace migraph