Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 902459 Details for
Bug 1105030
valgrind do not build on ppc64le archi
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
valgrind_ppc64le_step1.patch
valgrind_ppc64le_step1.patch (text/plain), 42.88 KB, created by
Michel Normand
on 2014-06-05 09:11:48 UTC
(
hide
)
Description:
valgrind_ppc64le_step1.patch
Filename:
MIME Type:
Creator:
Michel Normand
Created:
2014-06-05 09:11:48 UTC
Size:
42.88 KB
patch
obsolete
>From 46cdb12fa1311732cafc86cb5103df0c0a4aee79 Mon Sep 17 00:00:00 2001 >From: Carl Love <carll@us.ibm.com> >Date: Mon, 2 Jun 2014 11:05:24 -0500 >Subject: [PATCH 1/3] POWER PC, add initial Little Endian support > >The IBM POWER processor now supports both Big Endian and Little Endian. >There are a number of files where the #if statements include the >Power Big Endian code. This patch adds the Little Endian to #if >statements for the files that do not require any additional changes. >The changes made by this patch are "trivial" and do not break building >on POWER BE. The next patch will make the functional changes to the >Valgrind source files. > >Signed-off-by: Carl Love <carll@us.ibm.com> >--- > cachegrind/cg_arch.c | 2 +- > cachegrind/cg_branchpred.c | 2 +- > coregrind/launcher-darwin.c | 11 ++++++----- > coregrind/m_aspacemgr/aspacemgr-common.c | 7 ++++--- > coregrind/m_cache.c | 6 ++++-- > coregrind/m_debugger.c | 2 +- > coregrind/m_debuginfo/d3basics.c | 4 ++-- > coregrind/m_debuginfo/readdwarf.c | 10 ++++++---- > coregrind/m_debuginfo/readmacho.c | 2 ++ > coregrind/m_debuginfo/storage.c | 2 +- > coregrind/m_debuglog.c | 2 +- > coregrind/m_gdbserver/target.c | 2 +- > coregrind/m_libcassert.c | 2 +- > coregrind/m_libcfile.c | 30 +++++++++++++++++------------- > coregrind/m_libcproc.c | 3 ++- > coregrind/m_machine.c | 24 ++++++++++++------------ > coregrind/m_scheduler/scheduler.c | 4 ++-- > coregrind/m_stacktrace.c | 7 ++++--- > coregrind/m_syswrap/priv_types_n_macros.h | 1 + > coregrind/m_syswrap/syswrap-linux.c | 6 ++++-- > coregrind/m_vki.c | 2 +- > coregrind/pub_core_aspacemgr.h | 3 ++- > coregrind/pub_core_basics.h | 2 +- > coregrind/pub_core_debuginfo.h | 2 +- > coregrind/pub_core_mallocfree.h | 1 + > coregrind/pub_core_threadstate.h | 2 +- > coregrind/pub_core_trampoline.h | 2 +- > coregrind/pub_core_transtab_asm.h | 4 ++-- > drd/drd_bitmap.h | 4 ++-- > drd/drd_load_store.c | 2 +- > drd/tests/unit_bitmap.c | 3 ++- > helgrind/tests/annotate_hbefore.c | 2 +- > include/pub_tool_basics.h | 6 +++--- > include/pub_tool_libcsetjmp.h | 2 +- > include/pub_tool_machine.h | 2 +- > include/pub_tool_vkiscnums_asm.h | 2 +- > include/valgrind.h | 1 + > include/vki/vki-linux.h | 4 ++-- > memcheck/mc_machine.c | 11 ++++++++--- > memcheck/tests/atomic_incs.c | 8 ++++---- > memcheck/tests/unit_libcbase.c | 3 ++- > 41 files changed, 112 insertions(+), 85 deletions(-) > >Index: valgrind-3.9.0-svn20140513r13961/cachegrind/cg_arch.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/cachegrind/cg_arch.c >+++ valgrind-3.9.0-svn20140513r13961/cachegrind/cg_arch.c >@@ -353,7 +353,7 @@ configure_caches(cache_t *I1c, cache_t * > *D1c = (cache_t) { 65536, 2, 64 }; > *LLc = (cache_t) { 262144, 8, 64 }; > >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > > // Default cache configuration > *I1c = (cache_t) { 65536, 2, 64 }; >Index: valgrind-3.9.0-svn20140513r13961/cachegrind/cg_branchpred.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/cachegrind/cg_branchpred.c >+++ valgrind-3.9.0-svn20140513r13961/cachegrind/cg_branchpred.c >@@ -44,7 +44,7 @@ > > /* How many bits at the bottom of an instruction address are > guaranteed to be zero? */ >-#if defined(VGA_ppc32) || defined(VGA_ppc64) \ >+#if defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) \ > || defined(VGA_mips32) || defined(VGA_mips64) || defined(VGA_arm64) > # define N_IADDR_LO_ZERO_BITS 2 > #elif defined(VGA_x86) || defined(VGA_amd64) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/launcher-darwin.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/launcher-darwin.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/launcher-darwin.c >@@ -59,11 +59,12 @@ static struct { > const char *apple_name; // e.g. x86_64 > const char *valgrind_name; // e.g. amd64 > } valid_archs[] = { >- { CPU_TYPE_X86, "i386", "x86" }, >- { CPU_TYPE_X86_64, "x86_64", "amd64" }, >- { CPU_TYPE_ARM, "arm", "arm" }, >- { CPU_TYPE_POWERPC, "ppc", "ppc32" }, >- { CPU_TYPE_POWERPC64, "ppc64", "ppc64" }, >+ { CPU_TYPE_X86, "i386", "x86" }, >+ { CPU_TYPE_X86_64, "x86_64", "amd64" }, >+ { CPU_TYPE_ARM, "arm", "arm" }, >+ { CPU_TYPE_POWERPC, "ppc", "ppc32" }, >+ { CPU_TYPE_POWERPC64, "ppc64", "ppc64" }, >+ { CPU_TYPE_POWERPC64LE, "ppc64le", "ppc64le" }, > }; > static int valid_archs_count = sizeof(valid_archs)/sizeof(valid_archs[0]); > >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_aspacemgr/aspacemgr-common.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_aspacemgr/aspacemgr-common.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_aspacemgr/aspacemgr-common.c >@@ -162,9 +162,10 @@ SysRes VG_(am_do_mmap_NO_NOTIFY)( Addr s > aspacem_assert((offset % 4096) == 0); > res = VG_(do_syscall6)(__NR_mmap2, (UWord)start, length, > prot, flags, fd, offset / 4096); >-# elif defined(VGP_amd64_linux) || defined(VGP_ppc64_linux) \ >- || defined(VGP_s390x_linux) || defined(VGP_mips32_linux) \ >- || defined(VGP_mips64_linux) || defined(VGP_arm64_linux) >+# elif defined(VGP_amd64_linux) || defined(VGP_s390x_linux) || \ >+ defined(VGP_ppc64le_linux) || defined(VGP_ppc64_linux) || \ >+ defined(VGP_mips32_linux) || defined(VGP_mips64_linux) || \ >+ defined(VGP_arm64_linux) > res = VG_(do_syscall6)(__NR_mmap, (UWord)start, length, > prot, flags, fd, offset); > # elif defined(VGP_x86_darwin) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_cache.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_cache.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_cache.c >@@ -538,8 +538,10 @@ get_cache_info(VexArchInfo *vai) > return ret == 0 ? True : False; > } > >-#elif defined(VGA_arm) || defined(VGA_ppc32) || defined(VGA_ppc64) || \ >- defined(VGA_mips32) || defined(VGA_mips64) || defined(VGA_arm64) >+ >+#elif defined(VGA_arm) || defined(VGA_arm64) || \ >+ defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) || \ >+ defined(VGA_mips32) > > static Bool > get_cache_info(VexArchInfo *vai) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debugger.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debugger.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debugger.c >@@ -152,7 +152,7 @@ static Int ptrace_setregs(Int pid, VexGu > (void*)LibVEX_GuestPPC32_get_XER(vex)); > return rc; > >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > Int rc = 0; > /* FRJ: copied nearly verbatim from the ppc32 case. I compared the > vki-ppc64-linux.h with its ppc32 counterpart and saw no >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/d3basics.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debuginfo/d3basics.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/d3basics.c >@@ -406,7 +406,7 @@ static Bool get_Dwarf_Reg( /*OUT*/Addr* > if (regno == 7/*RSP*/) { *a = regs->sp; return True; } > # elif defined(VGP_ppc32_linux) > if (regno == 1/*SP*/) { *a = regs->sp; return True; } >-# elif defined(VGP_ppc64_linux) >+# elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > if (regno == 1/*SP*/) { *a = regs->sp; return True; } > # elif defined(VGP_arm_linux) > if (regno == 13) { *a = regs->sp; return True; } >@@ -863,7 +863,7 @@ GXResult ML_(evaluate_Dwarf3_Expr) ( UCh > if (!regs) > FAIL("evaluate_Dwarf3_Expr: " > "DW_OP_call_frame_cfa but no reg info"); >-#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) >+#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > /* Valgrind on ppc32/ppc64 currently doesn't use unwind info. */ > uw1 = ML_(read_Addr)((UChar*)regs->sp); > #else >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/readdwarf.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debuginfo/readdwarf.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/readdwarf.c >@@ -1833,7 +1833,7 @@ void ML_(read_debuginfo_dwarf1) ( > # define FP_REG 1 > # define SP_REG 1 > # define RA_REG_DEFAULT 65 >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > # define FP_REG 1 > # define SP_REG 1 > # define RA_REG_DEFAULT 65 >@@ -1874,6 +1874,7 @@ void ML_(read_debuginfo_dwarf1) ( > 7 (DWARF for the ARM Architecture) specifies that values up to 320 > might exist, for Neon/VFP-v3. */ > #if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) \ > || defined(VGP_mips32_linux) || defined(VGP_mips64_linux) > # define N_CFI_REGS 72 > #elif defined(VGP_arm_linux) >@@ -2491,7 +2492,7 @@ static Bool summarise_context( /*OUT*/Di > > return True; > >-# elif defined(VGA_ppc32) || defined(VGA_ppc64) >+# elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > /* These don't use CFI based unwinding (is that really true?) */ > > # else >@@ -2585,7 +2586,7 @@ static Int copy_convert_CfiExpr_tree ( X > return ML_(CfiExpr_CfiReg)( dstxa, Creg_IA_IP ); > # elif defined(VGA_arm64) > I_die_here; >-# elif defined(VGA_ppc32) || defined(VGA_ppc64) >+# elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > # else > # error "Unknown arch" > # endif >@@ -3752,7 +3753,8 @@ void ML_(read_callframe_info_dwarf3) > if (!is_ehframe) > vg_assert(frame_avma == 0); > >-# if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) >+# if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) || \ >+ defined(VGP_ppc64le_linux) > /* These targets don't use CFI-based stack unwinding. */ > return; > # endif >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/readmacho.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debuginfo/readmacho.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/readmacho.c >@@ -199,6 +199,8 @@ static DiSlice map_image_aboard ( DebugI > Int cputype = CPU_TYPE_POWERPC; > # elif defined(VGA_ppc64) > Int cputype = CPU_TYPE_POWERPC64; >+# elif defined(VGA_ppc64le) >+ Int cputype = CPU_TYPE_POWERPC64LE; > # elif defined(VGA_x86) > Int cputype = CPU_TYPE_X86; > # elif defined(VGA_amd64) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/storage.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debuginfo/storage.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debuginfo/storage.c >@@ -195,7 +195,7 @@ void ML_(ppDiCfSI) ( XArray* /* of CfiEx > SHOW_HOW(si->r11_how, si->r11_off); > VG_(printf)(" R7="); > SHOW_HOW(si->r7_how, si->r7_off); >-# elif defined(VGA_ppc32) || defined(VGA_ppc64) >+# elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > # elif defined(VGA_s390x) || defined(VGA_mips32) || defined(VGA_mips64) > VG_(printf)(" SP="); > SHOW_HOW(si->sp_how, si->sp_off); >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_debuglog.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_debuglog.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_debuglog.c >@@ -189,7 +189,7 @@ static UInt local_sys_getpid ( void ) > return __res; > } > >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > > static UInt local_sys_write_stderr ( const HChar* buf, Int n ) > { >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_gdbserver/target.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_gdbserver/target.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_gdbserver/target.c >@@ -657,7 +657,7 @@ void valgrind_initialize_target(void) > arm64_init_architecture(&the_low_target); > #elif defined(VGA_ppc32) > ppc32_init_architecture(&the_low_target); >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > ppc64_init_architecture(&the_low_target); > #elif defined(VGA_s390x) > s390x_init_architecture(&the_low_target); >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_libcassert.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_libcassert.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_libcassert.c >@@ -98,7 +98,7 @@ > (srP)->r_sp = (ULong)r1; \ > (srP)->misc.PPC32.r_lr = lr; \ > } >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > # define GET_STARTREGS(srP) \ > { ULong cia, r1, lr; \ > __asm__ __volatile__( \ >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_libcfile.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_libcfile.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_libcfile.c >@@ -664,10 +664,9 @@ SysRes VG_(pread) ( Int fd, void* buf, I > res = VG_(do_syscall6)(__NR_pread64, fd, (UWord)buf, count, > 0, 0, offset); > return res; >-# elif defined(VGP_amd64_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) \ >- || defined(VGP_mips64_linux) \ >- || defined(VGP_arm64_linux) >+# elif defined(VGP_amd64_linux) || defined(VGP_s390x_linux) \ >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_mips64_linux) || defined(VGP_arm64_linux) > res = VG_(do_syscall4)(__NR_pread64, fd, (UWord)buf, count, offset); > return res; > # elif defined(VGP_amd64_darwin) >@@ -910,7 +909,8 @@ static Int parse_inet_addr_and_port ( co > Int VG_(socket) ( Int domain, Int type, Int protocol ) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) > SysRes res; > UWord args[3]; > args[0] = domain; >@@ -950,7 +950,8 @@ static > Int my_connect ( Int sockfd, struct vki_sockaddr_in* serv_addr, Int addrlen ) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) > SysRes res; > UWord args[3]; > args[0] = sockfd; >@@ -989,7 +990,8 @@ Int VG_(write_socket)( Int sd, const voi > SIGPIPE */ > > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) > SysRes res; > UWord args[4]; > args[0] = sd; >@@ -1020,8 +1022,8 @@ Int VG_(write_socket)( Int sd, const voi > Int VG_(getsockname) ( Int sd, struct vki_sockaddr *name, Int *namelen) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) \ >- || defined(VGP_mips32_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) || defined(VGP_mips32_linux) > SysRes res; > UWord args[3]; > args[0] = sd; >@@ -1051,8 +1053,8 @@ Int VG_(getsockname) ( Int sd, struct vk > Int VG_(getpeername) ( Int sd, struct vki_sockaddr *name, Int *namelen) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) \ >- || defined(VGP_mips32_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) || defined(VGP_mips32_linux) > SysRes res; > UWord args[3]; > args[0] = sd; >@@ -1083,7 +1085,8 @@ Int VG_(getsockopt) ( Int sd, Int level, > Int *optlen) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) > SysRes res; > UWord args[5]; > args[0] = sd; >@@ -1120,7 +1123,8 @@ Int VG_(setsockopt) ( Int sd, Int level, > Int optlen) > { > # if defined(VGP_x86_linux) || defined(VGP_ppc32_linux) \ >- || defined(VGP_ppc64_linux) || defined(VGP_s390x_linux) >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) > SysRes res; > UWord args[5]; > args[0] = sd; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_libcproc.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_libcproc.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_libcproc.c >@@ -556,6 +556,7 @@ Int VG_(getgroups)( Int size, UInt* list > return sr_Res(sres); > > # elif defined(VGP_amd64_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) \ > || defined(VGP_arm_linux) \ > || defined(VGO_darwin) || defined(VGP_s390x_linux) \ > || defined(VGP_mips32_linux) || defined(VGP_arm64_linux) >@@ -741,7 +742,7 @@ void VG_(invalidate_icache) ( void *ptr, > // If I-caches are coherent, nothing needs to be done here > if (vai.hwcache_info.icaches_maintain_coherence) return; > >-# if defined(VGA_ppc32) || defined(VGA_ppc64) >+# if defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > Addr startaddr = (Addr) ptr; > Addr endaddr = startaddr + nbytes; > Addr cls; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_machine.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_machine.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_machine.c >@@ -81,7 +81,7 @@ void VG_(get_UnwindStartRegs) ( /*OUT*/U > regs->r_sp = (ULong)VG_(threads)[tid].arch.vex.guest_GPR1; > regs->misc.PPC32.r_lr > = VG_(threads)[tid].arch.vex.guest_LR; >-# elif defined(VGA_ppc64) >+# elif defined(VGA_ppc64) || defined(VGA_ppc64le) > regs->r_pc = VG_(threads)[tid].arch.vex.guest_CIA; > regs->r_sp = VG_(threads)[tid].arch.vex.guest_GPR1; > regs->misc.PPC64.r_lr >@@ -212,7 +212,7 @@ static void apply_to_GPs_of_tid(ThreadId > (*f)(tid, "R13", vex->guest_R13); > (*f)(tid, "R14", vex->guest_R14); > (*f)(tid, "R15", vex->guest_R15); >-#elif defined(VGA_ppc32) || defined(VGA_ppc64) >+#elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > (*f)(tid, "GPR0" , vex->guest_GPR0 ); > (*f)(tid, "GPR1" , vex->guest_GPR1 ); > (*f)(tid, "GPR2" , vex->guest_GPR2 ); >@@ -442,7 +442,7 @@ UInt VG_(machine_x86_have_mxcsr) = 0; > UInt VG_(machine_ppc32_has_FP) = 0; > UInt VG_(machine_ppc32_has_VMX) = 0; > #endif >-#if defined(VGA_ppc64) >+#if defined(VGA_ppc64) || defined(VGA_ppc64le) > ULong VG_(machine_ppc64_has_VMX) = 0; > #endif > #if defined(VGA_arm) >@@ -452,7 +452,7 @@ Int VG_(machine_arm_archlevel) = 4; > > /* For hwcaps detection on ppc32/64, s390x, and arm we'll need to do SIGILL > testing, so we need a VG_MINIMAL_JMP_BUF. */ >-#if defined(VGA_ppc32) || defined(VGA_ppc64) \ >+#if defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) \ > || defined(VGA_arm) || defined(VGA_s390x) || defined(VGA_mips32) > #include "pub_core_libcsetjmp.h" > static VG_MINIMAL_JMP_BUF(env_unsup_insn); >@@ -470,7 +470,7 @@ static void handler_unsup_insn ( Int x ) > * Not very defensive: assumes that as long as the dcbz/dcbzl > * instructions don't raise a SIGILL, that they will zero an aligned, > * contiguous block of memory of a sensible size. */ >-#if defined(VGA_ppc32) || defined(VGA_ppc64) >+#if defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > static void find_ppc_dcbz_sz(VexArchInfo *arch_info) > { > Int dcbz_szB = 0; >@@ -523,7 +523,7 @@ static void find_ppc_dcbz_sz(VexArchInfo > dcbz_szB, dcbzl_szB); > # undef MAX_DCBZL_SZB > } >-#endif /* defined(VGA_ppc32) || defined(VGA_ppc64) */ >+#endif /* defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) */ > > #ifdef VGA_s390x > >@@ -1064,7 +1064,7 @@ Bool VG_(machine_get_hwcaps)( void ) > return True; > } > >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > { > /* Same instruction set detection algorithm as for ppc32. */ > vki_sigset_t saved_set, tmp_set; >@@ -1599,7 +1599,7 @@ void VG_(machine_ppc32_set_clszB)( Int s > > > /* Notify host cpu instruction cache line size. */ >-#if defined(VGA_ppc64) >+#if defined(VGA_ppc64) || defined(VGA_ppc64le) > void VG_(machine_ppc64_set_clszB)( Int szB ) > { > vg_assert(hwcaps_done); >@@ -1681,7 +1681,7 @@ Int VG_(machine_get_size_of_largest_gues > if (vai.hwcaps & VEX_HWCAPS_PPC32_DFP) return 16; > return 8; > >-# elif defined(VGA_ppc64) >+# elif defined(VGA_ppc64) || defined(VGA_ppc64le) > /* 8 if boring; 16 if signs of Altivec or other exotic stuff */ > if (vai.hwcaps & VEX_HWCAPS_PPC64_V) return 16; > if (vai.hwcaps & VEX_HWCAPS_PPC64_VX) return 16; >@@ -1719,9 +1719,9 @@ Int VG_(machine_get_size_of_largest_gues > void* VG_(fnptr_to_fnentry)( void* f ) > { > # if defined(VGP_x86_linux) || defined(VGP_amd64_linux) \ >- || defined(VGP_arm_linux) \ >- || defined(VGP_ppc32_linux) || defined(VGO_darwin) \ >- || defined(VGP_s390x_linux) || defined(VGP_mips32_linux) \ >+ || defined(VGP_arm_linux) || defined(VGO_darwin) \ >+ || defined(VGP_ppc32_linux) || defined(VGP_ppc64le_linux) \ >+ || defined(VGP_s390x_linux) || defined(VGP_mips32_linux) \ > || defined(VGP_mips64_linux) || defined(VGP_arm64_linux) > return f; > # elif defined(VGP_ppc64_linux) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_scheduler/scheduler.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_scheduler/scheduler.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_scheduler/scheduler.c >@@ -768,7 +768,7 @@ static void do_pre_run_checks ( ThreadSt > vg_assert(VG_IS_8_ALIGNED(offsetof(VexGuestAMD64State,guest_RIP))); > # endif > >-# if defined(VGA_ppc32) || defined(VGA_ppc64) >+# if defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > /* ppc guest_state vector regs must be 16 byte aligned for > loads/stores. This is important! */ > vg_assert(VG_IS_16_ALIGNED(& tst->arch.vex.guest_VSR0)); >@@ -1614,7 +1614,7 @@ void VG_(nuke_all_threads_except) ( Thre > #elif defined(VGA_amd64) > # define VG_CLREQ_ARGS guest_RAX > # define VG_CLREQ_RET guest_RDX >-#elif defined(VGA_ppc32) || defined(VGA_ppc64) >+#elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > # define VG_CLREQ_ARGS guest_GPR4 > # define VG_CLREQ_RET guest_GPR3 > #elif defined(VGA_arm) >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_stacktrace.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_stacktrace.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_stacktrace.c >@@ -620,7 +620,8 @@ UInt VG_(get_StackTrace_wrk) ( ThreadId > > /* -----------------------ppc32/64 ---------------------- */ > >-#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) >+#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) > > UInt VG_(get_StackTrace_wrk) ( ThreadId tid_if_known, > /*OUT*/Addr* ips, UInt max_n_ips, >@@ -648,7 +649,7 @@ UInt VG_(get_StackTrace_wrk) ( ThreadId > Addr fp = sp; > # if defined(VGP_ppc32_linux) > Addr lr = startRegs->misc.PPC32.r_lr; >-# elif defined(VGP_ppc64_linux) >+# elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > Addr lr = startRegs->misc.PPC64.r_lr; > # endif > Addr fp_min = sp; >@@ -740,7 +741,7 @@ UInt VG_(get_StackTrace_wrk) ( ThreadId > /* On ppc64-linux (ppc64-elf, really), the lr save > slot is 2 words back from sp, whereas on ppc32-elf(?) it's > only one word back. */ >-# if defined(VG_PLAT_USES_PPCTOC) >+# if defined(VG_PLAT_USES_PPCTOC) || defined(VGP_ppc64le_linux) > const Int lr_offset = 2; > # else > const Int lr_offset = 1; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_syswrap/priv_types_n_macros.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_syswrap/priv_types_n_macros.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_syswrap/priv_types_n_macros.h >@@ -91,6 +91,7 @@ typedef > Int o_sysno; > # if defined(VGP_x86_linux) || defined(VGP_amd64_linux) \ > || defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) \ > || defined(VGP_arm_linux) || defined(VGP_s390x_linux) \ > || defined(VGP_mips64_linux) || defined(VGP_arm64_linux) > Int o_arg1; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_syswrap/syswrap-linux.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_syswrap/syswrap-linux.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_syswrap/syswrap-linux.c >@@ -244,7 +244,8 @@ static void run_a_thread_NORETURN ( Word > : "n" (VgTs_Empty), "n" (__NR_exit), "m" (tst->os_state.exitcode) > : "rax", "rdi" > ); >-#elif defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) > { UInt vgts_empty = (UInt)VgTs_Empty; > asm volatile ( > "stw %1,%0\n\t" /* set tst->status = VgTs_Empty */ >@@ -385,7 +386,7 @@ void VG_(main_thread_wrapper_NORETURN)(T > sp -= 16; > sp &= ~0xF; > *(UWord *)sp = 0; >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > /* make a stack frame */ > sp -= 112; > sp &= ~((Addr)0xF); >@@ -439,6 +440,7 @@ SysRes ML_(do_fork_clone) ( ThreadId tid > VG_(clone) stuff */ > #if defined(VGP_x86_linux) \ > || defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) \ > || defined(VGP_arm_linux) || defined(VGP_mips32_linux) \ > || defined(VGP_mips64_linux) || defined(VGP_arm64_linux) > res = VG_(do_syscall5)( __NR_clone, flags, >Index: valgrind-3.9.0-svn20140513r13961/coregrind/m_vki.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/m_vki.c >+++ valgrind-3.9.0-svn20140513r13961/coregrind/m_vki.c >@@ -43,7 +43,7 @@ > the logical place to store that info. */ > > #if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >- || defined(VGP_arm64_linux) >+ || defined(VGP_ppc64le_linux) || defined(VGP_arm64_linux) > unsigned long VKI_PAGE_SHIFT = 12; > unsigned long VKI_PAGE_SIZE = 1UL << 12; > #endif >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_aspacemgr.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_aspacemgr.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_aspacemgr.h >@@ -334,7 +334,8 @@ extern Bool VG_(am_relocate_nooverlap_cl > // stacks. The address space manager provides and suitably > // protects such stacks. > >-#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+#if defined(VGP_ppc32_linux) \ >+ || defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) \ > || defined(VGP_mips32_linux) || defined(VGP_mips64_linux) \ > || defined(VGP_arm64_linux) > # define VG_STACK_GUARD_SZB 65536 // 1 or 16 pages >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_basics.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_basics.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_basics.h >@@ -54,7 +54,7 @@ > # include "libvex_guest_amd64.h" > #elif defined(VGA_ppc32) > # include "libvex_guest_ppc32.h" >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > # include "libvex_guest_ppc64.h" > #elif defined(VGA_arm) > # include "libvex_guest_arm.h" >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_debuginfo.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_debuginfo.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_debuginfo.h >@@ -116,7 +116,7 @@ typedef > typedef > struct { Addr pc; Addr sp; Addr x30; Addr x29; } /* PC, SP, LR, FP */ > D3UnwindRegs; >-#elif defined(VGA_ppc32) || defined(VGA_ppc64) >+#elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) > typedef > UChar /* should be void, but gcc complains at use points */ > D3UnwindRegs; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_mallocfree.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_mallocfree.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_mallocfree.h >@@ -74,6 +74,7 @@ typedef Int ArenaId; > #elif defined(VGP_amd64_linux) || \ > defined(VGP_ppc32_linux) || \ > defined(VGP_ppc64_linux) || \ >+ defined(VGP_ppc64le_linux) || \ > defined(VGP_s390x_linux) || \ > defined(VGP_mips64_linux) || \ > defined(VGP_x86_darwin) || \ >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_threadstate.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_threadstate.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_threadstate.h >@@ -84,7 +84,7 @@ typedef > typedef VexGuestAMD64State VexGuestArchState; > #elif defined(VGA_ppc32) > typedef VexGuestPPC32State VexGuestArchState; >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > typedef VexGuestPPC64State VexGuestArchState; > #elif defined(VGA_arm) > typedef VexGuestARMState VexGuestArchState; >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_trampoline.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_trampoline.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_trampoline.h >@@ -81,7 +81,7 @@ extern UInt VG_(ppc32_linux_REDIR_FOR_s > extern void* VG_(ppc32_linux_REDIR_FOR_strchr)( void*, Int ); > #endif > >-#if defined(VGP_ppc64_linux) >+#if defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > extern Addr VG_(ppc64_linux_SUBST_FOR_rt_sigreturn); > extern UInt VG_(ppc64_linux_REDIR_FOR_strlen)( void* ); > extern void* VG_(ppc64_linux_REDIR_FOR_strchr)( void*, Int ); >Index: valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_transtab_asm.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/coregrind/pub_core_transtab_asm.h >+++ valgrind-3.9.0-svn20140513r13961/coregrind/pub_core_transtab_asm.h >@@ -62,8 +62,8 @@ > #elif defined(VGA_s390x) || defined(VGA_arm) > # define VG_TT_FAST_HASH(_addr) ((((UWord)(_addr)) >> 1) & VG_TT_FAST_MASK) > >-#elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_mips32) \ >- || defined(VGA_mips64) || defined(VGA_arm64) >+#elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_ppc64le) \ >+ || defined(VGA_mips32) || defined(VGA_mips64) || defined(VGA_arm64) > # define VG_TT_FAST_HASH(_addr) ((((UWord)(_addr)) >> 2) & VG_TT_FAST_MASK) > > #else >Index: valgrind-3.9.0-svn20140513r13961/drd/drd_bitmap.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/drd/drd_bitmap.h >+++ valgrind-3.9.0-svn20140513r13961/drd/drd_bitmap.h >@@ -139,8 +139,8 @@ Addr make_address(const UWord a1, const > #if defined(VGA_x86) || defined(VGA_ppc32) || defined(VGA_arm) \ > || defined(VGA_mips32) > #define BITS_PER_BITS_PER_UWORD 5 >-#elif defined(VGA_amd64) || defined(VGA_ppc64) || defined(VGA_s390x) \ >- || defined(VGA_mips64) || defined(VGA_arm64) >+#elif defined(VGA_amd64) || defined(VGA_ppc64) || defined(VGA_ppc64le) \ >+ || defined(VGA_s390x) || defined(VGA_mips64) || defined(VGA_arm64) > #define BITS_PER_BITS_PER_UWORD 6 > #else > #error Unknown platform. >Index: valgrind-3.9.0-svn20140513r13961/drd/drd_load_store.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/drd/drd_load_store.c >+++ valgrind-3.9.0-svn20140513r13961/drd/drd_load_store.c >@@ -43,7 +43,7 @@ > #define STACK_POINTER_OFFSET OFFSET_amd64_RSP > #elif defined(VGA_ppc32) > #define STACK_POINTER_OFFSET OFFSET_ppc32_GPR1 >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > #define STACK_POINTER_OFFSET OFFSET_ppc64_GPR1 > #elif defined(VGA_arm) > #define STACK_POINTER_OFFSET OFFSET_arm_R13 >Index: valgrind-3.9.0-svn20140513r13961/drd/tests/unit_bitmap.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/drd/tests/unit_bitmap.c >+++ valgrind-3.9.0-svn20140513r13961/drd/tests/unit_bitmap.c >@@ -83,7 +83,8 @@ struct { Addr address; SizeT size; BmAcc > { 0x00ffffffULL, 1, eLoad }, > { 0xffffffffULL - (((1 << ADDR_LSB_BITS) + 1) << ADDR_IGNORED_BITS), > 1, eStore }, >-#if defined(VGP_amd64_linux) || defined(VGP_ppc64_linux) >+#if defined(VGP_amd64_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) > { 0xffffffffULL - (1 << ADDR_LSB_BITS << ADDR_IGNORED_BITS), > 1, eStore }, > { 0xffffffffULL, 1, eStore }, >Index: valgrind-3.9.0-svn20140513r13961/helgrind/tests/annotate_hbefore.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/helgrind/tests/annotate_hbefore.c >+++ valgrind-3.9.0-svn20140513r13961/helgrind/tests/annotate_hbefore.c >@@ -20,7 +20,7 @@ > > typedef unsigned long int UWord; > >-#if defined(VGA_ppc64) >+#if defined(VGA_ppc64) || defined(VGA_ppc64le) > > // ppc64 > /* return 1 if success, 0 if failure */ >Index: valgrind-3.9.0-svn20140513r13961/include/pub_tool_basics.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/pub_tool_basics.h >+++ valgrind-3.9.0-svn20140513r13961/include/pub_tool_basics.h >@@ -270,7 +270,7 @@ static inline Bool sr_EQ ( SysRes sr1, S > > #if defined(VGA_x86) || defined(VGA_amd64) || defined (VGA_arm) \ > || ((defined(VGA_mips32) || defined(VGA_mips64)) && defined (_MIPSEL)) \ >- || defined(VGA_arm64) >+ || defined(VGA_arm64) || defined(VGA_ppc32le) > # define VG_LITTLEENDIAN 1 > #elif defined(VGA_ppc32) || defined(VGA_ppc64) || defined(VGA_s390x) \ > || ((defined(VGA_mips32) || defined(VGA_mips64)) && defined (_MIPSEB)) >@@ -283,9 +283,9 @@ static inline Bool sr_EQ ( SysRes sr1, S > #if defined(VGA_x86) > # define VG_REGPARM(n) __attribute__((regparm(n))) > #elif defined(VGA_amd64) || defined(VGA_ppc32) \ >- || defined(VGA_ppc64) || defined(VGA_arm) || defined(VGA_s390x) \ >+ || defined(VGA_ppc64) || defined(VGA_ppc64le) || defined(VGA_s390x) \ > || defined(VGA_mips32) || defined(VGA_mips64) \ >- || defined(VGA_arm64) >+ || defined(VGA_arm64) || defined(VGA_arm) > # define VG_REGPARM(n) /* */ > #else > # error Unknown arch >Index: valgrind-3.9.0-svn20140513r13961/include/pub_tool_libcsetjmp.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/pub_tool_libcsetjmp.h >+++ valgrind-3.9.0-svn20140513r13961/include/pub_tool_libcsetjmp.h >@@ -82,7 +82,7 @@ __attribute__((noreturn)) > void VG_MINIMAL_LONGJMP(VG_MINIMAL_JMP_BUF(_env)); > > >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > > #define VG_MINIMAL_JMP_BUF(_name) ULong _name [32+1+1] > __attribute__((returns_twice)) >Index: valgrind-3.9.0-svn20140513r13961/include/pub_tool_machine.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/pub_tool_machine.h >+++ valgrind-3.9.0-svn20140513r13961/include/pub_tool_machine.h >@@ -53,7 +53,7 @@ > # define VG_CLREQ_SZB 20 > # define VG_STACK_REDZONE_SZB 0 > >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > # define VG_MIN_INSTR_SZB 4 > # define VG_MAX_INSTR_SZB 4 > # define VG_CLREQ_SZB 20 >Index: valgrind-3.9.0-svn20140513r13961/include/pub_tool_vkiscnums_asm.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/pub_tool_vkiscnums_asm.h >+++ valgrind-3.9.0-svn20140513r13961/include/pub_tool_vkiscnums_asm.h >@@ -42,7 +42,7 @@ > #elif defined(VGP_ppc32_linux) > # include "vki/vki-scnums-ppc32-linux.h" > >-#elif defined(VGP_ppc64_linux) >+#elif defined(VGP_ppc64_linux) || defined(VGP_ppc64le_linux) > # include "vki/vki-scnums-ppc64-linux.h" > > #elif defined(VGP_s390x_linux) >Index: valgrind-3.9.0-svn20140513r13961/include/valgrind.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/valgrind.h >+++ valgrind-3.9.0-svn20140513r13961/include/valgrind.h >@@ -5925,6 +5925,7 @@ VALGRIND_PRINTF_BACKTRACE(const char *fo > #undef PLAT_amd64_linux > #undef PLAT_ppc32_linux > #undef PLAT_ppc64_linux >+#undef PLAT_ppc64le_linux > #undef PLAT_arm_linux > #undef PLAT_s390x_linux > #undef PLAT_mips32_linux >Index: valgrind-3.9.0-svn20140513r13961/include/vki/vki-linux.h >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/include/vki/vki-linux.h >+++ valgrind-3.9.0-svn20140513r13961/include/vki/vki-linux.h >@@ -85,7 +85,7 @@ > # include "vki-posixtypes-amd64-linux.h" > #elif defined(VGA_ppc32) > # include "vki-posixtypes-ppc32-linux.h" >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > # include "vki-posixtypes-ppc64-linux.h" > #elif defined(VGA_arm) > # include "vki-posixtypes-arm-linux.h" >@@ -211,7 +211,7 @@ typedef unsigned int vki_uint; > # include "vki-amd64-linux.h" > #elif defined(VGA_ppc32) > # include "vki-ppc32-linux.h" >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > # include "vki-ppc64-linux.h" > #elif defined(VGA_arm) > # include "vki-arm-linux.h" >Index: valgrind-3.9.0-svn20140513r13961/memcheck/mc_machine.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/memcheck/mc_machine.c >+++ valgrind-3.9.0-svn20140513r13961/memcheck/mc_machine.c >@@ -61,7 +61,7 @@ > # define MC_SIZEOF_GUEST_STATE sizeof(VexGuestPPC32State) > #endif > >-#if defined(VGA_ppc64) >+#if defined(VGA_ppc64) || defined(VGA_ppc64le) > # include "libvex_guest_ppc64.h" > # define MC_SIZEOF_GUEST_STATE sizeof(VexGuestPPC64State) > #endif >@@ -150,7 +150,7 @@ static Int get_otrack_shadow_offset_wrk > { > /* -------------------- ppc64 -------------------- */ > >-# if defined(VGA_ppc64) >+# if defined(VGA_ppc64) || defined(VGA_ppc64le) > > # define GOF(_fieldname) \ > (offsetof(VexGuestPPC64State,guest_##_fieldname)) >@@ -160,7 +160,12 @@ static Int get_otrack_shadow_offset_wrk > Int sz = szB; > Int o = offset; > tl_assert(sz > 0); >+ >+#if defined(VGA_ppc64) > tl_assert(host_is_big_endian()); >+#elif defined(VGA_ppc64le) >+ tl_assert(host_is_little_endian()); >+#endif > > if (sz == 8 || sz == 4) { > /* The point of this is to achieve >@@ -1282,7 +1287,7 @@ static Int get_otrack_shadow_offset_wrk > IRType MC_(get_otrack_reg_array_equiv_int_type) ( IRRegArray* arr ) > { > /* -------------------- ppc64 -------------------- */ >-# if defined(VGA_ppc64) >+# if defined(VGA_ppc64) || defined(VGA_ppc64le) > /* The redir stack. */ > if (arr->base == offsetof(VexGuestPPC64State,guest_REDIR_STACK[0]) > && arr->elemTy == Ity_I64 >Index: valgrind-3.9.0-svn20140513r13961/memcheck/tests/atomic_incs.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/memcheck/tests/atomic_incs.c >+++ valgrind-3.9.0-svn20140513r13961/memcheck/tests/atomic_incs.c >@@ -62,7 +62,7 @@ __attribute__((noinline)) void atomic_ad > : /*trash*/ "memory", "cc", "r15" > ); > } while (success != 1); >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > /* Nasty hack. Does correctly atomically do *p += n, but only if p > is 8-aligned -- guaranteed by caller. */ > unsigned long success; >@@ -261,7 +261,7 @@ __attribute__((noinline)) void atomic_ad > : /*trash*/ "memory", "cc", "r15" > ); > } while (success != 1); >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > /* Nasty hack. Does correctly atomically do *p += n, but only if p > is 8-aligned -- guaranteed by caller. */ > unsigned long success; >@@ -457,7 +457,7 @@ __attribute__((noinline)) void atomic_ad > : /*trash*/ "memory", "cc", "r15" > ); > } while (success != 1); >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > /* Nasty hack. Does correctly atomically do *p += n, but only if p > is 8-aligned -- guaranteed by caller. */ > unsigned long success; >@@ -574,7 +574,7 @@ __attribute__((noinline)) void atomic_ad > "lock; addq %%rbx,(%%rax)" "\n" > : : "S"(&block[0])/* S means "rsi only" */ : "memory","cc","rax","rbx" > ); >-#elif defined(VGA_ppc64) >+#elif defined(VGA_ppc64) || defined(VGA_ppc64le) > unsigned long success; > do { > __asm__ __volatile__( >Index: valgrind-3.9.0-svn20140513r13961/memcheck/tests/unit_libcbase.c >=================================================================== >--- valgrind-3.9.0-svn20140513r13961.orig/memcheck/tests/unit_libcbase.c >+++ valgrind-3.9.0-svn20140513r13961/memcheck/tests/unit_libcbase.c >@@ -56,7 +56,8 @@ void test_VG_STREQN(void) > } > > // On PPC/Linux VKI_PAGE_SIZE is a variable, not a macro. >-#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) >+#if defined(VGP_ppc32_linux) || defined(VGP_ppc64_linux) \ >+ || defined(VGP_ppc64le_linux) > unsigned long VKI_PAGE_SIZE = 1UL << 12; > #elif defined(VGP_arm64_linux) > unsigned long VKI_PAGE_SIZE = 1UL << 16;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1105030
:
902458
| 902459 |
902460
|
902461
|
902565