pan/bi: Add bi_print_bundle for printing bi_bundle

Post-schedule, nops are significnat here.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4061>
This commit is contained in:
Alyssa Rosenzweig 2020-03-05 07:57:49 -05:00 committed by Marge Bot
parent bde54cb6d3
commit 919cdf15b3
2 changed files with 15 additions and 0 deletions

View File

@ -328,3 +328,17 @@ bi_print_instruction(bi_instruction *ins, FILE *fp)
fprintf(fp, "\n"); fprintf(fp, "\n");
} }
void
bi_print_bundle(bi_bundle *bundle, FILE *fp)
{
bi_instruction *ins[2] = { bundle->fma, bundle->add };
for (unsigned i = 0; i < 2; ++i) {
if (ins[i])
bi_print_instruction(ins[i], fp);
else
fprintf(fp, "nop\n");
}
}

View File

@ -39,5 +39,6 @@ const char * bi_interp_mode_name(enum bifrost_interp_mode mode);
const char * bi_ldst_type_name(enum bifrost_ldst_type type); const char * bi_ldst_type_name(enum bifrost_ldst_type type);
void bi_print_instruction(bi_instruction *ins, FILE *fp); void bi_print_instruction(bi_instruction *ins, FILE *fp);
void bi_print_bundle(bi_bundle *bundle, FILE *fp);
#endif #endif