summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/arc/sigrestorer.S
blob: 60d35ab3ec15161f62c2de4f9ed2c52ed80fb757 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/*
 * Copyright (C) 2017-2022 Synopsys, Inc. (www.synopsys.com)
 *
 * Licensed under the LGPL v2.1 or later, see the file COPYING.LIB in this tarball.
 */

#include <sysdep.h>

/*
 * Default sigretrun stub if user doesn't specify SA_RESTORER.
 */

.section .text
.align 4
.global __default_rt_sa_restorer
.type __default_rt_sa_restorer, @function

; This "nop" is needed here, because debugger would assume that this function
; called the signal handler, therefore it cannot start on the "mov"
; instruction, at which execution will jump to.
	nop
__default_rt_sa_restorer:
	mov r8, __NR_rt_sigreturn
	ARC_TRAP_INSN
	j_s     [blink]