Search
lxdream.org :: lxdream/src/sh4/sh4x86.in :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/sh4/sh4x86.in
changeset 1198:407659e01ef0
prev1197:904fba59a705
next1214:49152b3d8b75
author Nathan Keynes <nkeynes@lxdream.org>
date Fri Dec 16 10:08:45 2011 +1000 (10 years ago)
permissions -rw-r--r--
last change Add volatile qualifier to return-address frobbing - works around optimizer
bug in GCC versions after 4.2
file annotate diff log raw
1.1 --- a/src/sh4/sh4x86.in Wed Dec 14 23:23:32 2011 +1000
1.2 +++ b/src/sh4/sh4x86.in Fri Dec 16 10:08:45 2011 +1000
1.3 @@ -604,7 +604,7 @@
1.4 *(void **)(backpatch+5) = XLAT_BLOCK_FOR_CODE(target)->use_list;
1.5 XLAT_BLOCK_FOR_CODE(target)->use_list = backpatch;
1.6
1.7 - uint8_t **retptr = ((uint8_t **)__builtin_frame_address(0))+1;
1.8 + uint8_t * volatile *retptr = ((uint8_t * volatile *)__builtin_frame_address(0))+1;
1.9 assert( *retptr == ((uint8_t *)__builtin_return_address(0)) );
1.10 *retptr = backpatch;
1.11 }
.