I added some packpatching

This commit is contained in:
Meyer Simon
2025-04-30 08:20:11 -04:00
parent 0189c2d937
commit cd4393d052
6 changed files with 138 additions and 110 deletions

View File

@ -108,13 +108,13 @@ typedef struct TFList {
TFList * next;
} TFList;
TFList * make_list(Instruction * i);
// TFList * make_list(Instruction * i);
// - makelist(i) function to create instruction lists
void merge(TFList * l1, TFList * l2);
// void merge(TFList * l1, TFList * l2);
// - merge(p1,p2) function to concatenate lists
void backpatch(TFList * l, int label);
// void backpatch(TFList * l, int label);
// - backpatch(p,i) function to fill in jump targets
void bp_temp(int n);
// void bp_temp(int n);
extern Instruction * begin;
@ -159,3 +159,4 @@ int get_index(Instruction * i);
void set_label(Instruction * i, int label);
bool isConst(TNodeOrConst * tnc);
int label_gen();
void backpatch(Stack *s, int l);