Commit 91cf4d88fbb174ba5a4ade9c4479f3b0775a5599
1 parent
a96fc003
gcc 3.2.2 bug workaround (RedHat 9 fix)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@326 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
1 changed file
with
6 additions
and
0 deletions
ops_template_mem.h
| ... | ... | @@ -44,6 +44,9 @@ void OPPROTO glue(glue(op_rol, MEM_SUFFIX), _T0_T1_cc)(void) |
| 44 | 44 | T0 = (T0 << count) | (T0 >> (DATA_BITS - count)); |
| 45 | 45 | #ifdef MEM_WRITE |
| 46 | 46 | glue(st, SUFFIX)((uint8_t *)A0, T0); |
| 47 | +#else | |
| 48 | + /* gcc 3.2 workaround. This is really a bug in gcc. */ | |
| 49 | + asm volatile("" : : "r" (T0)); | |
| 47 | 50 | #endif |
| 48 | 51 | CC_SRC = (cc_table[CC_OP].compute_all() & ~(CC_O | CC_C)) | |
| 49 | 52 | (lshift(src ^ T0, 11 - (DATA_BITS - 1)) & CC_O) | |
| ... | ... | @@ -63,6 +66,9 @@ void OPPROTO glue(glue(op_ror, MEM_SUFFIX), _T0_T1_cc)(void) |
| 63 | 66 | T0 = (T0 >> count) | (T0 << (DATA_BITS - count)); |
| 64 | 67 | #ifdef MEM_WRITE |
| 65 | 68 | glue(st, SUFFIX)((uint8_t *)A0, T0); |
| 69 | +#else | |
| 70 | + /* gcc 3.2 workaround. This is really a bug in gcc. */ | |
| 71 | + asm volatile("" : : "r" (T0)); | |
| 66 | 72 | #endif |
| 67 | 73 | CC_SRC = (cc_table[CC_OP].compute_all() & ~(CC_O | CC_C)) | |
| 68 | 74 | (lshift(src ^ T0, 11 - (DATA_BITS - 1)) & CC_O) | | ... | ... |