Blame src/signal/nt64/sigsetjmp.s

66b804
.text
66b804
.globl	__sigsetjmp
66b804
.globl	sigsetjmp
66b804
66b804
.def __sigsetjmp; .scl 2; .type 32; .endef
66b804
.def sigsetjmp; .scl 2; .type 32; .endef
66b804
66b804
__sigsetjmp:
66b804
sigsetjmp:
66b804
	test  %rdx,%rdx		# save signal mask?
66b804
	jnz   1f		# yes: save mask
66b804
	jmp   setjmp		# no:  setjmp
66b804
66b804
1:
66b804
				# typedef unsigned long __jmp_buf[10];
66b804
				#
66b804
				# typedef struct __jmp_buf_tag {
66b804
				#	__jmp_buf __jb;
66b804
				#	unsigned long __fl;
66b804
				# 	unsigned long __ss[16];
66b804
				# }
66b804
				#
66b804
66b804
	popq  0x68(%rcx) 	# save return address to .__ss[2]
66b804
	movq  %rbx,0x70(%rcx)	# save rbx (arbitrary choice) to .__ss[3]
66b804
	movq  %rcx,%rbx		# save pointer to __jmp_buf to rbx
66b804
66b804
	call  __setjmp
66b804
66b804
	pushq 0x68(%rbx) 	# push previously saved return address
66b804
	movq  %rbx,%rcx 	# save pointer to __jmp_buf to rcx (arg 0)
66b804
	movl  %eax,%edx		# save setjmp return value to rdx (arg 1)
66b804
	movq  0x70(%rcx),%rbx	# restore rbx from .__ss[3]
66b804
66b804
66b804
	jmp __sigsetjmp_tail	# defer to __sigsetjmp_tail
66b804
66b804
66b804
	.section .got$sigsetjmp,"r"
66b804
	.global __imp_sigsetjmp
66b804
__imp_sigsetjmp:
66b804
	.quad	sigsetjmp
66b804
	.linkonce discard