This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] S/390 Reverting the jmp_buf/ucontext_t ABI change


Hi,

this patch-version changes in the following things:

On 07/29/2014 12:10 PM, Andreas Schwab wrote:> Stefan Liebler
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   but WITHOUT ANY WARRANTY; without even the implied waranty of

This adds a typo.
Fixed the typo.



On 07/29/2014 12:45 PM, Andreas Schwab wrote:> Stefan Liebler <stli@linux.vnet.ibm.com> writes:

On 07/28/2014 05:30 PM, Andreas Schwab wrote:
Stefan Liebler <stli@linux.vnet.ibm.com> writes:

+weak_extern (__sigsetjmp);

That should not be here.

Andreas.


simply removing weak_extern leads to
gcc -nostdlib -nostartfiles -r -o build/elf/librtld.map.o '-Wl,-('
build/elf/dl-allobjs.os build/libc_pic.a -lgcc '-Wl,-)'
-Wl,-Map,build/elf/librtld.mapT
build/libc_pic.a(setjmp.os):(*IND*+0x0): multiple definition of
`__sigsetjmp'
build/libc_pic.a(setjmp.os):(.text+0x18): first defined here
collect2: error: ld returned 1 exit status

The implementation of the function needs to have a unique name.

Andreas.
This patch removes the introduces weak_extern(xyz)
in
-sysdeps/unix/sysv/linux/s390/pt-longjmp.c
-sysdeps/s390/s390-32/setjmp.S
-sysdeps/s390/s390-64/setjmp.S
-sysdeps/unix/sysv/linux/s390/longjmp_chk.c

Instead the functions have a unique name in case of symbol versioning and the issue with multiple definition is resolved.

In case of longjmp_chk.c we had to copy the implementation for the symbol versioning case, because we need an unique name for __longjmp_chk, but it is already named via a define for __libc_siglongjmp in debug/longjmp_chk.c





On 07/29/2014 01:01 PM, Andreas Schwab wrote:> Martin Schwidefsky <schwidefsky@de.ibm.com> writes:

On Mon, 28 Jul 2014 17:30:22 +0200
Andreas Schwab <schwab@suse.de> wrote:

Stefan Liebler <stli@linux.vnet.ibm.com> writes:

+weak_extern (__sigsetjmp);

That should not be here.

The same kind of problem is present with setjmp and _setjmp, no?

They are non-weak on other architectures.

Andreas.
The bsd-entry-points setjmp/_setjmp have been moved around from path to path some times in history, but the very first checkin for s390 had introduced them as weak on s390.
Thus this revert patch will not change this behaviour!
If like you said, this should not be weak like on other architectures, then we will make them strong in a separate patch.

Thanks
Stefan


---
2014-07-30  Stefan Liebler  <stli@linux.vnet.ibm.com>

	* sysdeps/s390/Makefile: Delete file.
	* sysdeps/s390/Versions (GLIBC_2.19): Remove __setjmp.
	* sysdeps/s390/__longjmp.c: Delete file.
	* sysdeps/s390/bits/setjmp.h (__s390_jmp_buf):
	Remove fields __flags and __reserved.
	* sysdeps/s390/longjmp.c: Include setjmp/longjmp.c
	and add versioning.
	* sysdeps/s390/rtld-__longjmp.c: Delete file.
	* sysdeps/s390/rtld-global-offsets.sym: Likewise.
	* sysdeps/s390/rtld-setjmp.S: Likewise.
	* sysdeps/s390/s390-32/__longjmp-common.c: Move to ...
	* sysdeps/s390/s390-32/__longjmp.c: ... here.
	* sysdeps/s390/s390-32/setjmp-common.S: Move to ...
	* sysdeps/s390/s390-32/setjmp.S: ... here.
	Add versioning.
	(__sigsetjmp): Remove setting __flags field.
	* sysdeps/s390/s390-64/__longjmp-common.c:Move to ...
	* sysdeps/s390/s390-64/__longjmp.c: ... here.
	* sysdeps/s390/s390-64/setjmp-common.S: Move to ...
	* sysdeps/s390/s390-64/setjmp.S: ... here.
	Add versioning.
	(__sigsetjmp): Remove setting __flags field.
	* sysdeps/s390/setjmp.S: Delete file.
	* sysdeps/s390/sigjmp.c: Likewise.
	* sysdeps/s390/v1-longjmp.c: Likewise.
	* sysdeps/s390/v1-setjmp.h: Likewise.
	* sysdeps/s390/v1-sigjmp.c: Likewise.
	* sysdeps/unix/sysv/linux/s390/Makefile (sysdep_routines):
	Remove v1-longjmp_chk.
	* sysdeps/unix/sysv/linux/s390/getcontext.S: Delete file.
	* sysdeps/unix/sysv/linux/s390/longjmp_chk.c:
	Include debug/longjmp_chk.c and add versioning.
	* sysdeps/unix/sysv/linux/s390/pt-longjmp.c:
	Include nptl/pt-longjmp.c and add versioning.
	* sysdeps/unix/sysv/linux/s390/rtld-getcontext.S: Delete file.
	* sysdeps/unix/sysv/linux/s390/s390-32/____longjmp_chk.c:
	Include __longjmp.c.
	* sysdeps/unix/sysv/linux/s390/s390-32/getcontext-common.S:
	Move to ...
	* sysdeps/unix/sysv/linux/s390/s390-32/getcontext.S: ... here.
	(__getcontext): Remove setting __flags field.
	Add versioning.
	* sysdeps/unix/sysv/linux/s390/s390-32/setcontext.S:
	DonÂt restore upper high grps.
	* sysdeps/unix/sysv/linux/s390/s390-32/swapcontext.S:
	Likewise.
	(__swapcontext): Remove setting uc_flags field.
	* sysdeps/unix/sysv/linux/s390/s390-32/ucontext_i.sym:
	Delete file.
	* sysdeps/unix/sysv/linux/s390/s390-64/____longjmp_chk.c:
	Include __longjmp.c.
	* sysdeps/unix/sysv/linux/s390/s390-64/getcontext-common.S:
	Move to ...
	* sysdeps/unix/sysv/linux/s390/s390-64/getcontext.S: ... here.
	(__getcontext): Remove setting __flags field.
	Add versioning.
	* sysdeps/unix/sysv/linux/s390/s390-64/swapcontext.S:
	(__swapcontext): Remove setting uc_flags field.
	* unix/sysv/linux/s390/s390-64/ucontext_i.sym: Delete file.
	* sysdeps/unix/sysv/linux/s390/sys/ucontext.h (ucontext):
	Remove fields uc_high_gprs and __reserved.
	* sysdeps/unix/sysv/linux/s390/ucontext_i.sym:
	New file with reverted content.
	* sysdeps/unix/sysv/linux/s390/v1-longjmp_chk.c: Delete file.
	* sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist:
	Regenerated.
	* sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist:
	Regenerated.

Attachment: revert-all_3007_0845
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]