Fixed some bad mcg ir code generation: only nodes which have been appendir'd
may be used multiple times.
This commit is contained in:
parent
692caa2b0a
commit
52ee317878
|
@ -85,6 +85,8 @@ static struct ir* pop(int size)
|
||||||
}
|
}
|
||||||
else if ((size == EM_wordsize) && (ir->size == (EM_wordsize*2)))
|
else if ((size == EM_wordsize) && (ir->size == (EM_wordsize*2)))
|
||||||
{
|
{
|
||||||
|
appendir(ir);
|
||||||
|
|
||||||
/* Tried to read an int, but we got a long. */
|
/* Tried to read an int, but we got a long. */
|
||||||
push(
|
push(
|
||||||
new_ir1(
|
new_ir1(
|
||||||
|
@ -553,6 +555,7 @@ static void insn_simple(int opcode)
|
||||||
{
|
{
|
||||||
struct ir* label = new_labelir(".trppc");
|
struct ir* label = new_labelir(".trppc");
|
||||||
struct ir* value = pop(EM_pointersize);
|
struct ir* value = pop(EM_pointersize);
|
||||||
|
appendir(label); /* because we need to use label twice */
|
||||||
push(
|
push(
|
||||||
load(
|
load(
|
||||||
EM_pointersize,
|
EM_pointersize,
|
||||||
|
|
Loading…
Reference in a new issue