This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
secureplt breaks ld on Alpha Linux
- From: Mikulas Patocka <mpatocka at redhat dot com>
- To: Richard Henderson <rth at twiddle dot net>
- Cc: binutils at sourceware dot org, bug-binutils at gnu dot org
- Date: Fri, 29 Aug 2014 15:29:36 -0400 (EDT)
- Subject: secureplt breaks ld on Alpha Linux
- Authentication-results: sourceware.org; auth=none
Hi
I found out that the patch cc75d373fdb9668f367959f99f0b67e056a6c18a
(Enable secureplt by default for alpha-linux) committed to binutils git
breaks ld on alpha.
This is a minimalized testcase that shows the breakage:
http://people.redhat.com/~mpatocka/testcases/alpha-ld-bug/ld-bug.tar.xz
To reproduce the bug, run ./ld-bug.sh to perform the linking, then run the
resulting binary:
LD_PRELOAD=./libots.so ./memset
The bug happens when using the Compaq C Compiler (ccc) on Alpha Linux (it
can be downloaded from
ftp://ftp.compaq.com/pub/products/C-CXX/linux/compaq_c/ ). When using
optimization, Compaq C replaces a call to memset with a call to _OtsZero
located in libots.so. The above patch breaks ld in such a way that the
resulting program crashes when performing the dynamic call to _OtsZero.
Mikulas