SSBM Decomp
Loading...
Searching...
No Matches
texpdag.c File Reference
#include "texpdag.h"
#include "texp.h"
#include "tobj.h"
#include "baselib/debug.h"

Macros

#define CLEAR_ARG(arg)
#define BIAS_TO_INT(bias)
#define INT_TO_BIAS(v)
#define RESOURCE_CONFLICT(tex_obj, chan_id, src_exp)

Functions

int assign_reg (int num, u32 *unused, HSD_TExpDag *list, int *order)
void order_dag (int num, u32 *dep, u32 *full_dep, HSD_TExpDag *list, int depth, int idx, u32 done_set, u32 ready_set, int *order, int *min, int *min_order)
void CalcDistance (HSD_TExp **tevs, int *dist, HSD_TExp *tev, int num, int depth)
int HSD_TExpMakeDag (HSD_TExp *root, HSD_TExpDag *list)
static void make_dependancy_mtx (int num, HSD_TExpDag *list, u32 *dep_mtx)
void make_full_dependancy_mtx (int num, u32 *dep, u32 *full)
void HSD_TExpSchedule (int num, HSD_TExpDag *list, HSD_TExp **result, HSD_TExpRes *resource)
int SimplifySrc (HSD_TExp *arg0)
int SimplifyThis (HSD_TExp *arg0)
int SimplifyByMerge (HSD_TExp *arg0)
int HSD_TExpSimplify (HSD_TExp *texp_)
int HSD_TExpSimplify2 (HSD_TExp *texp)

Variables

static int HSD_TEXP_MAX_NUM = 20
static u8 pad [0x44] = { 0 }
static s32 HSD_TExpDag_804D5FF8 = 0x7FF00
static HSD_TExpHSD_TExpDag_804D5FFC = NULL

Macro Definition Documentation

◆ CLEAR_ARG

#define CLEAR_ARG ( arg)
Value:
do { \
*(u32*) &(arg) = HSD_TExpDag_804D5FF8; \
(arg).exp = HSD_TExpDag_804D5FFC; \
} while (0)
static HSD_TExp * HSD_TExpDag_804D5FFC
Definition texpdag.c:594
static s32 HSD_TExpDag_804D5FF8
Definition texpdag.c:593

◆ BIAS_TO_INT

#define BIAS_TO_INT ( bias)
Value:
((bias) == 1 ? 1 : ((bias) == 2 ? -1 : 0))

◆ INT_TO_BIAS

#define INT_TO_BIAS ( v)
Value:
((v) == 1 ? 1 : ((v) == -1 ? 2 : 0))

◆ RESOURCE_CONFLICT

#define RESOURCE_CONFLICT ( tex_obj,
chan_id,
src_exp )
Value:
((((tex_obj) != NULL) && ((src_exp)->tev.tex != NULL) && \
((tex_obj) != (src_exp)->tev.tex)) || \
(((chan_id) != 0xFF) && ((src_exp)->tev.chan != 0xFF) && \
((chan_id) != (src_exp)->tev.chan)))
#define NULL
Definition stddef.h:19

Function Documentation

◆ assign_reg()

int assign_reg ( int num,
u32 * unused,
HSD_TExpDag * list,
int * order )

◆ order_dag()

void order_dag ( int num,
u32 * dep,
u32 * full_dep,
HSD_TExpDag * list,
int depth,
int idx,
u32 done_set,
u32 ready_set,
int * order,
int * min,
int * min_order )

◆ CalcDistance()

void CalcDistance ( HSD_TExp ** tevs,
int * dist,
HSD_TExp * tev,
int num,
int depth )

◆ HSD_TExpMakeDag()

int HSD_TExpMakeDag ( HSD_TExp * root,
HSD_TExpDag * list )

◆ make_dependancy_mtx()

void make_dependancy_mtx ( int num,
HSD_TExpDag * list,
u32 * dep_mtx )
static

◆ make_full_dependancy_mtx()

void make_full_dependancy_mtx ( int num,
u32 * dep,
u32 * full )

◆ HSD_TExpSchedule()

void HSD_TExpSchedule ( int num,
HSD_TExpDag * list,
HSD_TExp ** result,
HSD_TExpRes * resource )

◆ SimplifySrc()

int SimplifySrc ( HSD_TExp * arg0)

◆ SimplifyThis()

int SimplifyThis ( HSD_TExp * arg0)

◆ SimplifyByMerge()

int SimplifyByMerge ( HSD_TExp * arg0)

◆ HSD_TExpSimplify()

int HSD_TExpSimplify ( HSD_TExp * texp_)

◆ HSD_TExpSimplify2()

int HSD_TExpSimplify2 ( HSD_TExp * texp)

Variable Documentation

◆ HSD_TEXP_MAX_NUM

int HSD_TEXP_MAX_NUM = 20
static

◆ pad

u8 pad[0x44] = { 0 }
static

◆ HSD_TExpDag_804D5FF8

s32 HSD_TExpDag_804D5FF8 = 0x7FF00
static

◆ HSD_TExpDag_804D5FFC

HSD_TExp* HSD_TExpDag_804D5FFC = NULL
static