]> git.ipfire.org Git - thirdparty/glibc.git/blame - sysdeps/x86_64/bsd-_setjmp.S
Prefer https to http for gnu.org and fsf.org URLs
[thirdparty/glibc.git] / sysdeps / x86_64 / bsd-_setjmp.S
CommitLineData
c9cf6dde 1/* BSD `_setjmp' entry point to `sigsetjmp (..., 0)'. x86-64 version.
04277e02 2 Copyright (C) 1994-2019 Free Software Foundation, Inc.
c9cf6dde
AJ
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
59ba27a6 16 License along with the GNU C Library; if not, see
5a82c748 17 <https://www.gnu.org/licenses/>. */
c9cf6dde
AJ
18
19/* This just does a tail-call to `__sigsetjmp (ARG, 0)'.
20 We cannot do it in C because it must be a tail-call, so frame-unwinding
21 in setjmp doesn't clobber the state restored by longjmp. */
22
23#include <sysdep.h>
24#define _ASM
25#define _SETJMP_H
26#include <bits/setjmp.h>
c9cf6dde 27
29691210 28ENTRY (_setjmp)
c9cf6dde 29 /* Set up arguments, we only need to set the second arg. */
ee618985 30 xorl %esi, %esi
cd2fbe58
UD
31#ifdef PIC
32 jmp HIDDEN_JUMPTARGET (__sigsetjmp)
c9cf6dde 33#else
29691210 34 jmp __sigsetjmp
c9cf6dde 35#endif
29691210 36END (_setjmp)
a4baf360 37libc_hidden_def (_setjmp)