sgemm_wg: Output CPU data to binary
This commit is contained in:
@@ -258,7 +258,6 @@ void vx_spawn_tasks_cluster(int num_tasks, vx_spawn_tasks_cb callback, void *arg
|
|||||||
// threads, handle this in the last wave amongst other full warps.
|
// threads, handle this in the last wave amongst other full warps.
|
||||||
if (rem_threads_in_last_warp != 0 && core_id_in_cluster == 0) {
|
if (rem_threads_in_last_warp != 0 && core_id_in_cluster == 0) {
|
||||||
// adjust offset
|
// adjust offset
|
||||||
// FIXME: consider cluster_id here
|
|
||||||
// FIXME: use rem_threads_in_last_warp_this_core
|
// FIXME: use rem_threads_in_last_warp_this_core
|
||||||
wspawn_args.offset += (num_tasks_this_cluster - rem_threads_in_last_warp);
|
wspawn_args.offset += (num_tasks_this_cluster - rem_threads_in_last_warp);
|
||||||
|
|
||||||
|
|||||||
@@ -119,6 +119,14 @@ int run_test(const kernel_arg_t& kernel_arg,
|
|||||||
file.write(reinterpret_cast<char *>(staging_buf.data()), buf_size);
|
file.write(reinterpret_cast<char *>(staging_buf.data()), buf_size);
|
||||||
file.close();
|
file.close();
|
||||||
|
|
||||||
|
std::ofstream ref_file("reference.c.bin", std::ios::binary | std::ios::out);
|
||||||
|
if (!ref_file) {
|
||||||
|
std::cerr << "error: failed to open reference.c.bin for writing\n";
|
||||||
|
exit(EXIT_FAILURE);
|
||||||
|
}
|
||||||
|
ref_file.write(reinterpret_cast<char *>(ref_data.data()), buf_size);
|
||||||
|
ref_file.close();
|
||||||
|
|
||||||
// verify result
|
// verify result
|
||||||
std::cout << "verify result" << std::endl;
|
std::cout << "verify result" << std::endl;
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user