Commit 30067609 authored by Ted Themistokleous's avatar Ted Themistokleous
Browse files

More debug

parent 6a331a5b
...@@ -49,7 +49,7 @@ struct parse_topk : op_parser<parse_topk> ...@@ -49,7 +49,7 @@ struct parse_topk : op_parser<parse_topk>
} }
else if(contains(info.attributes, "k")) else if(contains(info.attributes, "k"))
{ {
k = 5;//info.attributes.at("k").i(); k = 5; // info.attributes.at("k").i();
} }
bool largest = true; bool largest = true;
......
...@@ -46,7 +46,7 @@ argument nonzero(hipStream_t stream, const argument& result, const argument& arg ...@@ -46,7 +46,7 @@ argument nonzero(hipStream_t stream, const argument& result, const argument& arg
auto* ptr = result.cast<int64_t>(); auto* ptr = result.cast<int64_t>();
gs_launch(stream, block_size, block_size)([=](auto, auto idx) __device__ { gs_launch(stream, block_size, block_size)([=](auto, auto idx) __device__ {
// fill all output to 0 first // fill all output to 0 first
idx.local_stride(out_elem_num-1, [&](auto j) { ptr[j] = 0; }); idx.local_stride(out_elem_num, [&](auto j) { ptr[j] = 0; });
block_scan<block_size>( block_scan<block_size>(
idx, idx,
......
...@@ -41,6 +41,7 @@ struct test_gather : verify_program<test_gather<Axis>> ...@@ -41,6 +41,7 @@ struct test_gather : verify_program<test_gather<Axis>>
auto a1 = mm->add_literal(migraphx::literal{s_indices, indices}); auto a1 = mm->add_literal(migraphx::literal{s_indices, indices});
int axis = Axis; int axis = Axis;
mm->add_instruction(migraphx::make_op("gather", {{"axis", axis}}), a0, a1); mm->add_instruction(migraphx::make_op("gather", {{"axis", axis}}), a0, a1);
p.debug_print();
return p; return p;
} }
}; };
......
...@@ -38,6 +38,7 @@ struct test_gathernd_default : verify_program<test_gathernd_default> ...@@ -38,6 +38,7 @@ struct test_gathernd_default : verify_program<test_gathernd_default>
auto a0 = mm->add_parameter("data", ds); auto a0 = mm->add_parameter("data", ds);
auto a1 = mm->add_literal(migraphx::literal{is, indices}); auto a1 = mm->add_literal(migraphx::literal{is, indices});
mm->add_instruction(migraphx::make_op("gathernd"), a0, a1); mm->add_instruction(migraphx::make_op("gathernd"), a0, a1);
p.debug_print();
return p; return p;
} }
}; };
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