"src/git@developer.sourcefind.cn:gaoqiong/migraphx.git" did not exist on "0e9eb89f614083d9d2ba50c29ced9475ce72c812"
Commit 7eaffe8f authored by Shucai Xiao's avatar Shucai Xiao
Browse files

clang format

parent 90cfe474
...@@ -15,8 +15,7 @@ struct hip_int8_gemm_pack_a ...@@ -15,8 +15,7 @@ struct hip_int8_gemm_pack_a
{ {
std::string name() const { return "gpu::int8_gemm_pack_a"; } std::string name() const { return "gpu::int8_gemm_pack_a"; }
shape compute_shape(const std::vector<shape>& inputs) const; shape compute_shape(const std::vector<shape>& inputs) const;
argument argument compute(context& ctx, const shape&, const std::vector<argument>& args) const;
compute(context& ctx, const shape&, const std::vector<argument>& args) const;
std::ptrdiff_t output_alias(const std::vector<shape>& shapes) const std::ptrdiff_t output_alias(const std::vector<shape>& shapes) const
{ {
return shapes.size() - 1; return shapes.size() - 1;
...@@ -27,8 +26,7 @@ struct hip_int8_gemm_pack_b ...@@ -27,8 +26,7 @@ struct hip_int8_gemm_pack_b
{ {
std::string name() const { return "gpu::int8_gemm_pack_b"; } std::string name() const { return "gpu::int8_gemm_pack_b"; }
shape compute_shape(const std::vector<shape>& inputs) const; shape compute_shape(const std::vector<shape>& inputs) const;
argument argument compute(context& ctx, const shape&, const std::vector<argument>& args) const;
compute(context& ctx, const shape&, const std::vector<argument>& args) const;
std::ptrdiff_t output_alias(const std::vector<shape>& shapes) const std::ptrdiff_t output_alias(const std::vector<shape>& shapes) const
{ {
return shapes.size() - 1; return shapes.size() - 1;
......
...@@ -12,9 +12,8 @@ shape hip_int8_gemm_pack_a::compute_shape(const std::vector<shape>& inputs) cons ...@@ -12,9 +12,8 @@ shape hip_int8_gemm_pack_a::compute_shape(const std::vector<shape>& inputs) cons
return inputs.at(0); return inputs.at(0);
} }
argument hip_int8_gemm_pack_a::compute(context& ctx, argument
const shape&, hip_int8_gemm_pack_a::compute(context& ctx, const shape&, const std::vector<argument>& args) const
const std::vector<argument>& args) const
{ {
device::int8_gemm_pack_a(ctx.get_stream().get(), args[1], args[0]); device::int8_gemm_pack_a(ctx.get_stream().get(), args[1], args[0]);
return args[1]; return args[1];
...@@ -26,9 +25,8 @@ shape hip_int8_gemm_pack_b::compute_shape(const std::vector<shape>& inputs) cons ...@@ -26,9 +25,8 @@ shape hip_int8_gemm_pack_b::compute_shape(const std::vector<shape>& inputs) cons
return inputs.at(0); return inputs.at(0);
} }
argument hip_int8_gemm_pack_b::compute(context& ctx, argument
const shape&, hip_int8_gemm_pack_b::compute(context& ctx, const shape&, const std::vector<argument>& args) const
const std::vector<argument>& args) const
{ {
device::int8_gemm_pack_b(ctx.get_stream().get(), args[1], args[0]); device::int8_gemm_pack_b(ctx.get_stream().get(), args[1], args[0]);
return args[1]; return args[1];
......
...@@ -133,7 +133,7 @@ struct miopen_apply ...@@ -133,7 +133,7 @@ struct miopen_apply
add_lrn_op(); add_lrn_op();
add_convolution_op(); add_convolution_op();
add_quant_convolution_op(); add_quant_convolution_op();
//add_quant_dot_op(); // add_quant_dot_op();
add_pooling_op(); add_pooling_op();
add_batch_norm_inference_op(); add_batch_norm_inference_op();
} }
...@@ -189,10 +189,12 @@ struct miopen_apply ...@@ -189,10 +189,12 @@ struct miopen_apply
auto args = ins->inputs(); auto args = ins->inputs();
auto arg_x_vec4 = insert_allocation(ins, conv.pack_int8_shape(args[0]->get_shape())); auto arg_x_vec4 = insert_allocation(ins, conv.pack_int8_shape(args[0]->get_shape()));
auto arg_x_packed = prog->insert_instruction(ins, miopen_int8_conv_pack{}, {args[0], arg_x_vec4}); auto arg_x_packed =
prog->insert_instruction(ins, miopen_int8_conv_pack{}, {args[0], arg_x_vec4});
auto arg_y_vec4 = insert_allocation(ins, conv.pack_int8_shape(args[1]->get_shape())); auto arg_y_vec4 = insert_allocation(ins, conv.pack_int8_shape(args[1]->get_shape()));
auto arg_y_packed = prog->insert_instruction(ins, miopen_int8_conv_pack{}, {args[1], arg_y_vec4}); auto arg_y_packed =
prog->insert_instruction(ins, miopen_int8_conv_pack{}, {args[1], arg_y_vec4});
auto workspace = insert_allocation(ins, ws, "workspace"); auto workspace = insert_allocation(ins, ws, "workspace");
auto output = insert_allocation(ins, ins->get_shape()); auto output = insert_allocation(ins, ins->get_shape());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment