	.file	"56476.c"
	.intel_syntax noprefix
	.text
	.globl	lenOfSubstring
	.type	lenOfSubstring, @function
lenOfSubstring:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 1088
	mov	QWORD PTR -1080[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -1080[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	DWORD PTR -1048[rbp], eax
	cmp	DWORD PTR -1048[rbp], 1
	jg	.L2
	mov	eax, DWORD PTR -1048[rbp]
	jmp	.L9
.L2:
	mov	DWORD PTR -1064[rbp], 0
	mov	DWORD PTR -1060[rbp], 0
	mov	DWORD PTR -1044[rbp], 0
	mov	DWORD PTR -1056[rbp], 0
	mov	DWORD PTR -1052[rbp], 0
	jmp	.L4
.L5:
	mov	eax, DWORD PTR -1052[rbp]
	cdqe
	mov	DWORD PTR -1040[rbp+rax*4], -1
	add	DWORD PTR -1052[rbp], 1
.L4:
	cmp	DWORD PTR -1052[rbp], 255
	jle	.L5
	jmp	.L6
.L8:
	mov	eax, DWORD PTR -1056[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -1080[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cdqe
	mov	eax, DWORD PTR -1040[rbp+rax*4]
	cmp	eax, -1
	je	.L7
	mov	eax, DWORD PTR -1056[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -1080[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cdqe
	mov	eax, DWORD PTR -1040[rbp+rax*4]
	cmp	DWORD PTR -1064[rbp], eax
	jg	.L7
	mov	eax, DWORD PTR -1056[rbp]
	sub	eax, DWORD PTR -1064[rbp]
	cmp	DWORD PTR -1060[rbp], eax
	cmovge	eax, DWORD PTR -1060[rbp]
	mov	DWORD PTR -1060[rbp], eax
	mov	eax, DWORD PTR -1056[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -1080[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cdqe
	mov	eax, DWORD PTR -1040[rbp+rax*4]
	add	eax, 1
	mov	DWORD PTR -1064[rbp], eax
.L7:
	mov	eax, DWORD PTR -1056[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -1080[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	eax, al
	cdqe
	mov	edx, DWORD PTR -1056[rbp]
	mov	DWORD PTR -1040[rbp+rax*4], edx
	add	DWORD PTR -1056[rbp], 1
.L6:
	mov	eax, DWORD PTR -1056[rbp]
	cmp	eax, DWORD PTR -1048[rbp]
	jl	.L8
	mov	eax, DWORD PTR -1048[rbp]
	sub	eax, DWORD PTR -1064[rbp]
	cmp	DWORD PTR -1060[rbp], eax
	cmovge	eax, DWORD PTR -1060[rbp]
	mov	DWORD PTR -1060[rbp], eax
	mov	eax, DWORD PTR -1060[rbp]
.L9:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L10
	call	__stack_chk_fail@PLT
.L10:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	lenOfSubstring, .-lenOfSubstring
	.section	.rodata
.LC0:
	.string	"%s"
.LC1:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -12[rbp], 0
	mov	edi, 256
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	lenOfSubstring
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	mov	esi, eax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"56476.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	lenOfSubstring
	.syntax unified
	.arm
	.fpu softvfp
	.type	lenOfSubstring, %function
lenOfSubstring:
	@ args = 0, pretend = 0, frame = 1064
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1056
	sub	sp, sp, #8
	str	r0, [fp, #-1064]
	ldr	r3, .L11
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r0, [fp, #-1064]
	bl	strlen
	mov	r3, r0
	str	r3, [fp, #-1040]
	ldr	r3, [fp, #-1040]
	cmp	r3, #1
	bgt	.L2
	ldr	r3, [fp, #-1040]
	b	.L9
.L2:
	mov	r3, #0
	str	r3, [fp, #-1056]
	mov	r3, #0
	str	r3, [fp, #-1052]
	mov	r3, #0
	str	r3, [fp, #-1036]
	mov	r3, #0
	str	r3, [fp, #-1048]
	mov	r3, #0
	str	r3, [fp, #-1044]
	b	.L4
.L5:
	ldr	r3, [fp, #-1044]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #-1028]
	ldr	r3, [fp, #-1044]
	add	r3, r3, #1
	str	r3, [fp, #-1044]
.L4:
	ldr	r3, [fp, #-1044]
	cmp	r3, #255
	ble	.L5
	b	.L6
.L8:
	ldr	r3, [fp, #-1048]
	ldr	r2, [fp, #-1064]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-1028]
	cmn	r3, #1
	beq	.L7
	ldr	r3, [fp, #-1048]
	ldr	r2, [fp, #-1064]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-1028]
	ldr	r2, [fp, #-1056]
	cmp	r2, r3
	bgt	.L7
	ldr	r2, [fp, #-1048]
	ldr	r3, [fp, #-1056]
	sub	r3, r2, r3
	ldr	r2, [fp, #-1052]
	cmp	r2, r3
	movge	r3, r2
	movlt	r3, r3
	str	r3, [fp, #-1052]
	ldr	r3, [fp, #-1048]
	ldr	r2, [fp, #-1064]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-1028]
	add	r3, r3, #1
	str	r3, [fp, #-1056]
.L7:
	ldr	r3, [fp, #-1048]
	ldr	r2, [fp, #-1064]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r2, [fp, #-1048]
	str	r2, [r3, #-1028]
	ldr	r3, [fp, #-1048]
	add	r3, r3, #1
	str	r3, [fp, #-1048]
.L6:
	ldr	r2, [fp, #-1048]
	ldr	r3, [fp, #-1040]
	cmp	r2, r3
	blt	.L8
	ldr	r2, [fp, #-1040]
	ldr	r3, [fp, #-1056]
	sub	r3, r2, r3
	ldr	r2, [fp, #-1052]
	cmp	r2, r3
	movge	r3, r2
	movlt	r3, r3
	str	r3, [fp, #-1052]
	ldr	r3, [fp, #-1052]
.L9:
	ldr	r2, .L11
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L10
	bl	__stack_chk_fail
.L10:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC0
	.size	lenOfSubstring, .-lenOfSubstring
	.section	.rodata
	.align	2
.LC1:
	.ascii	"%s\000"
	.align	2
.LC2:
	.ascii	"%d\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	mov	r3, #0
	str	r3, [fp, #-12]
	mov	r0, #256
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r1, [fp, #-8]
	ldr	r0, .L15
	bl	__isoc99_scanf
	ldr	r0, [fp, #-8]
	bl	lenOfSubstring
	str	r0, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L15+4
	bl	printf
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L16:
	.align	2
.L15:
	.word	.LC1
	.word	.LC2
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
