[PATCH] Pass correct address to __enable_execute_stack on alpha

Jason R Thorpe thorpej@wasabisystems.com
Thu Oct 17 13:58:00 GMT 2002


The incorrect address was being passed to __enable_execute_stack, which
would cause incorrect behavior if the trampoline was unlucky enough to
stradle a page boundary.

Patch pre-approved by Richard, checked in to mainline.

        * config/alpha/alpha.c (alpha_initialize_trampoline): Use
        tramp, not addr, to pass the trampoline address to
        __enable_execute_stack.

-- 
        -- Jason R. Thorpe <thorpej@wasabisystems.com>
-------------- next part --------------
Index: config/alpha/alpha.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/alpha/alpha.c,v
retrieving revision 1.277
diff -c -r1.277 alpha.c
*** config/alpha/alpha.c	27 Sep 2002 13:30:07 -0000	1.277
--- config/alpha/alpha.c	17 Oct 2002 20:47:21 -0000
***************
*** 6040,6046 ****
  
  #ifdef TRANSFER_FROM_TRAMPOLINE
    emit_library_call (gen_rtx_SYMBOL_REF (Pmode, "__enable_execute_stack"),
! 		     0, VOIDmode, 1, addr, Pmode);
  #endif
  
    if (jmpofs >= 0)
--- 6040,6046 ----
  
  #ifdef TRANSFER_FROM_TRAMPOLINE
    emit_library_call (gen_rtx_SYMBOL_REF (Pmode, "__enable_execute_stack"),
! 		     0, VOIDmode, 1, tramp, Pmode);
  #endif
  
    if (jmpofs >= 0)


More information about the Gcc-patches mailing list