Skip to content

Commit

Permalink
CC: resync with upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
EtchedPixels committed Oct 22, 2023
1 parent 605cbc5 commit fcf93c9
Show file tree
Hide file tree
Showing 90 changed files with 9,004 additions and 1,161 deletions.
1,771 changes: 1,771 additions & 0 deletions Applications/CC/backend-6502.c

Large diffs are not rendered by default.

3,330 changes: 2,618 additions & 712 deletions Applications/CC/backend-65c816.c

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions Applications/CC/backend-6803.c
Original file line number Diff line number Diff line change
Expand Up @@ -791,13 +791,13 @@ void gen_prologue(const char *name)
}

/* Generate the stack frame */
void gen_frame(unsigned size)
void gen_frame(unsigned size, unsigned aframe)
{
frame_len = size;
grow_stack(size);
}

void gen_epilogue(unsigned size)
void gen_epilogue(unsigned size, unsigned argsize)
{
if (sp != size) {
error("sp");
Expand All @@ -814,6 +814,12 @@ void gen_label(const char *tail, unsigned n)
invalidate_x();
}

unsigned gen_exit(const char *tail, unsigned n)
{
printf("\tjmp L%d%s\n", n, tail);
return 0;
}

void gen_jump(const char *tail, unsigned n)
{
printf("\tjmp L%d%s\n", n, tail);
Expand Down
10 changes: 8 additions & 2 deletions Applications/CC/backend-6809.c
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ void gen_prologue(const char *name)
}

/* Generate the stack frame */
void gen_frame(unsigned size)
void gen_frame(unsigned size, unsigned aframe)
{
frame_len = size;
if (size) {
Expand All @@ -196,7 +196,7 @@ void gen_frame(unsigned size)
}
}

void gen_epilogue(unsigned size)
void gen_epilogue(unsigned size, unsigned argsize)
{
if (sp) {
fprintf(stderr, "sp out by %d\n", sp);
Expand All @@ -212,6 +212,12 @@ void gen_label(const char *tail, unsigned n)
printf("L%d%s:\n", n, tail);
}

unsigned gen_exit(const char *tail, unsigned n)
{
printf("\tjmp L%d%s\n", n, tail);
return 0;
}

void gen_jump(const char *tail, unsigned n)
{
printf("\tjmp L%d%s\n", n, tail);
Expand Down
4 changes: 2 additions & 2 deletions Applications/CC/backend-8070.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ void gen_prologue(const char *name)
}

/* Generate the stack frame */
void gen_frame(unsigned size)
void gen_frame(unsigned size, unsigned aframe)
{
/* Annoyingly we can't use autoindex on SP */
frame_len = size;
Expand All @@ -292,7 +292,7 @@ void gen_frame(unsigned size)
}
}

void gen_epilogue(unsigned size)
void gen_epilogue(unsigned size, unsigned argsize)
{
if (sp != size) {
error("sp");
Expand Down
Loading

0 comments on commit fcf93c9

Please sign in to comment.