"H.J. Lu" <hjl.to...@gmail.com> writes:

> diff --git a/libsanitizer/asan/asan_linux.cc b/libsanitizer/asan/asan_linux.cc
> index ea7ee9e..5c52ddc 100644
> --- a/libsanitizer/asan/asan_linux.cc
> +++ b/libsanitizer/asan/asan_linux.cc
> @@ -1,5 +1,7 @@
>  //===-- asan_linux.cc 
> -----------------------------------------------------===//
>  //
> +//                     The LLVM Compiler Infrastructure
> +//
>  // This file is distributed under the University of Illinois Open Source
>  // License. See LICENSE.TXT for details.
>  //
> @@ -66,20 +68,6 @@ void GetPcSpBp(void *context, uptr *pc, uptr *sp, uptr 
> *bp) {
>    *pc = ucontext->uc_mcontext.gregs[REG_EIP];
>    *bp = ucontext->uc_mcontext.gregs[REG_EBP];
>    *sp = ucontext->uc_mcontext.gregs[REG_ESP];
> -# elif defined(__sparc__)
> -  ucontext_t *ucontext = (ucontext_t*)context;
> -  uptr *stk_ptr;
> -# if defined (__arch64__)
> -  *pc = ucontext->uc_mcontext.mc_gregs[MC_PC];
> -  *sp = ucontext->uc_mcontext.mc_gregs[MC_O6];
> -  stk_ptr = (uptr *) (*sp + 2047);
> -  *bp = stk_ptr[15];
> -# else
> -  *pc = ucontext->uc_mcontext.gregs[REG_PC];
> -  *sp = ucontext->uc_mcontext.gregs[REG_O6];
> -  stk_ptr = (uptr *) *sp;
> -  *bp = stk_ptr[15];
> -# endif
>  #else
>  # error "Unsupported arch"
>  #endif

I don't think removing this code is desirable.  As discussed, there
needs to be one of the libsanitizer maintainers who takes care of
porting changes from the GCC side to upstream and importing upstream, as
Ian does for libgo.

Btw., is there some kind of libsanitizer porting guide, or is one
supposed to figure this out on one's own?

        Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

Reply via email to