mirror of git://gcc.gnu.org/git/gcc.git
mark_rts.c (GC_approx_sp): Use __builtin_frame_address when compiling with GCC rather than taking the...
* mark_rts.c (GC_approx_sp): Use __builtin_frame_address when compiling with GCC rather than taking the address of a local variable. From-SVN: r154771
This commit is contained in:
parent
0761b46075
commit
2fc5ecb5a8
|
@ -1,3 +1,9 @@
|
||||||
|
2009-11-30 Ben Elliston <bje@au.ibm.com>
|
||||||
|
|
||||||
|
* mark_rts.c (GC_approx_sp): Use __builtin_frame_address when
|
||||||
|
compiling with GCC rather than taking the address of a local
|
||||||
|
variable.
|
||||||
|
|
||||||
2009-11-30 Ben Elliston <bje@au.ibm.com>
|
2009-11-30 Ben Elliston <bje@au.ibm.com>
|
||||||
|
|
||||||
* os_dep.c: Use the POSIX signal API in preference to the BSD API.
|
* os_dep.c: Use the POSIX signal API in preference to the BSD API.
|
||||||
|
|
|
@ -376,7 +376,13 @@ ptr_t GC_approx_sp()
|
||||||
# ifdef _MSC_VER
|
# ifdef _MSC_VER
|
||||||
# pragma warning(disable:4172)
|
# pragma warning(disable:4172)
|
||||||
# endif
|
# endif
|
||||||
return((ptr_t)(&dummy));
|
#ifdef __GNUC__
|
||||||
|
/* Eliminate a warning from GCC about taking the address of a
|
||||||
|
local variable. */
|
||||||
|
return __builtin_frame_address (0);
|
||||||
|
#else
|
||||||
|
return ((ptr_t)(&dummy));
|
||||||
|
#endif /* __GNUC__ */
|
||||||
# ifdef _MSC_VER
|
# ifdef _MSC_VER
|
||||||
# pragma warning(default:4172)
|
# pragma warning(default:4172)
|
||||||
# endif
|
# endif
|
||||||
|
|
Loading…
Reference in New Issue