Mercurial > hg > tinycc
comparison tcc.c @ 574:1f1a692f7563
Rename o() to gen_multibyte().
author | Rob Landley <rob@landley.net> |
---|---|
date | Tue, 18 Mar 2008 18:52:00 -0500 |
parents | d89a6822b7e0 |
children | 8595fe33590f |
comparison
equal
deleted
inserted
replaced
573:09b424940c88 | 574:1f1a692f7563 |
---|---|
3692 sv.c.ul = loc; | 3692 sv.c.ul = loc; |
3693 store(r, &sv); | 3693 store(r, &sv); |
3694 #ifdef TINYCC_TARGET_I386 | 3694 #ifdef TINYCC_TARGET_I386 |
3695 /* x86 specific: need to pop fp register ST0 if saved */ | 3695 /* x86 specific: need to pop fp register ST0 if saved */ |
3696 if (r == TREG_ST0) { | 3696 if (r == TREG_ST0) { |
3697 o(0xd9dd); /* fstp %st(1) */ | 3697 gen_multibyte(0xd9dd); /* fstp %st(1) */ |
3698 } | 3698 } |
3699 #endif | 3699 #endif |
3700 /* special long long case */ | 3700 /* special long long case */ |
3701 if ((type->t & VT_BTYPE) == VT_LLONG) { | 3701 if ((type->t & VT_BTYPE) == VT_LLONG) { |
3702 sv.c.ul += 4; | 3702 sv.c.ul += 4; |
4133 int v; | 4133 int v; |
4134 v = vtop->r & VT_VALMASK; | 4134 v = vtop->r & VT_VALMASK; |
4135 #ifdef TINYCC_TARGET_I386 | 4135 #ifdef TINYCC_TARGET_I386 |
4136 /* for x86, we need to pop the FP stack */ | 4136 /* for x86, we need to pop the FP stack */ |
4137 if (v == TREG_ST0) { | 4137 if (v == TREG_ST0) { |
4138 o(0xd8dd); /* fstp %st(1) */ | 4138 gen_multibyte(0xd8dd); /* fstp %st(1) */ |
4139 } else | 4139 } else |
4140 #endif | 4140 #endif |
4141 if (v == VT_JMP || v == VT_JMPI) { | 4141 if (v == VT_JMP || v == VT_JMPI) { |
4142 /* need to put correct jump if && or || without test */ | 4142 /* need to put correct jump if && or || without test */ |
4143 gsym(vtop->c.ul); | 4143 gsym(vtop->c.ul); |
4386 } else { | 4386 } else { |
4387 #if defined(TINYCC_TARGET_I386) | 4387 #if defined(TINYCC_TARGET_I386) |
4388 b = psym(0x850f, 0); | 4388 b = psym(0x850f, 0); |
4389 #elif defined(TINYCC_TARGET_ARM) | 4389 #elif defined(TINYCC_TARGET_ARM) |
4390 b = ind; | 4390 b = ind; |
4391 o(0x1A000000 | encbranch(ind, 0, 1)); | 4391 gen_multibyte(0x1A000000 | encbranch(ind, 0, 1)); |
4392 #elif defined(TINYCC_TARGET_C67) | 4392 #elif defined(TINYCC_TARGET_C67) |
4393 error("not implemented"); | 4393 error("not implemented"); |
4394 #else | 4394 #else |
4395 #error not supported | 4395 #error not supported |
4396 #endif | 4396 #endif |