PowerPC64 stub: on syscall, real Linux trashes r13 and below

(except r1, r2, and input args!) So, r12 .e_entry for musl
must copy from a saved register.  [qemu-ppc64 doesn't trash registers!]
	modified:   ../.github/travis_testsuite_1.sh
	modified:   p_lx_elf.cpp
	modified:   stub/src/amd64-linux.elf-main.c
	modified:   stub/src/powerpc64le-linux.elf-fold.S
	also .h  .fold.map
This commit is contained in:
John Reiser
2017-10-27 20:07:32 -07:00
parent bb8e607442
commit 0430e7931e
12 changed files with 621 additions and 610 deletions
+1
View File
@@ -473,6 +473,7 @@ off_t PackLinuxElf64::pack3(OutputFile *fo, Filter &ft)
upx_uint64_t const pm = (
Elf64_Ehdr::EM_X86_64 ==e_machine
|| Elf64_Ehdr::EM_AARCH64==e_machine
//|| Elf64_Ehdr::EM_PPC64 ==e_machine /* DOES NOT WORK! */
)
? ((~(upx_uint64_t)0)<<12)
: page_mask;