Skip to content

Commit

Permalink
Moved print_whole_ir() up next to print_ir().
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Mar 20, 2011
1 parent e2c6111 commit 2993607
Showing 1 changed file with 13 additions and 15 deletions.
28 changes: 13 additions & 15 deletions mojoshader_compiler.c
Expand Up @@ -5819,6 +5819,19 @@ static void print_ir(FILE *io, unsigned int depth, void *_ir)
} // switch
} // print_ir

static void print_whole_ir(Context *ctx, FILE *io)
{
if (ctx->ir != NULL)
{
int i;
for (i = 0; i <= ctx->user_func_index; i++)
{
printf("[FUNCTION %d ]\n", i);
print_ir(io, 1, ctx->ir[i]);
} // for
} // if
} // print_whole_ir

static void delete_ir(Context *ctx, void *_ir)
{
MOJOSHADER_irNode *ir = (MOJOSHADER_irNode *) _ir;
Expand Down Expand Up @@ -5896,21 +5909,6 @@ static void delete_ir(Context *ctx, void *_ir)
Free(ctx, ir);
} // delete_ir


static void print_whole_ir(Context *ctx, FILE *io)
{
if (ctx->ir != NULL)
{
int i;
for (i = 0; i <= ctx->user_func_index; i++)
{
printf("[FUNCTION %d ]\n", i);
print_ir(io, 1, ctx->ir[i]);
} // for
} // if
} // print_whole_ir


static void intermediate_representation(Context *ctx)
{
const MOJOSHADER_astCompilationUnit *ast = NULL;
Expand Down

0 comments on commit 2993607

Please sign in to comment.