copy_string_to_graph_interface.s 1.06 KB
Newer Older
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 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82

	.globl	collect_1

	.globl	_copy_string_to_graph
	.globl	_remove_forwarding_pointers_from_string

	.text

	.intel_syntax noprefix

	.globl	__copy__string__to__graph

__copy__string__to__graph:
	push	rcx

	sub	rsp,8

	mov	r12,rsi
	mov	r13,rdi

	mov	rdi,rcx
	mov	rsi,r13
	lea	rdx,[r13+r15*8]
	mov	rcx,rsp

	mov	rbp,rsp
	and	rsp,-8
	.att_syntax
	call	_copy_string_to_graph
	.intel_syntax noprefix
	mov	rsp,rbp

	mov	rsi,r12
	mov	rdi,r13

	test	rax,1
	.att_syntax
	je	__copy__string__to__graph_1
	.intel_syntax noprefix

	mov	rcx,qword ptr 8[rsp]
	and	rax,-8

	mov	r12,rsi
	mov	r13,rdi

	mov	rdi,rcx
	mov	rsi,rax

	mov	rbp,rsp
	and	rsp,-8
	.att_syntax
	call	_remove_forwarding_pointers_from_string
	.intel_syntax noprefix
	mov	rsp,rbp

	mov	rsi,r12
	mov	rdi,r13

	pop	rbx
	pop	rcx

	sub	rbx,rdi
	sar	rbx,3
	sub	r15,rbx
	.att_syntax
	call	collect_1
	.intel_syntax noprefix
	add	r15,rbx
	.att_syntax
	jmp	__copy__string__to__graph
	.intel_syntax noprefix

__copy__string__to__graph_1:
	mov	rbx,rdi
	mov	rdi,qword ptr [rsp]
	mov	rcx,rax
	sub	rbx,rdi
	sar	rbx,3
	add	r15,rbx
	add	rsp,16
	ret