github.com/bytedance/sonic@v1.11.7-0.20240517092252-d2edb31b167b/internal/native/avx/validate_utf8_text_amd64.go (about) 1 // +build amd64 2 // Code generated by asm2asm, DO NOT EDIT. 3 4 package avx 5 6 var _text_validate_utf8 = []byte{ 7 // .p2align 4, 0x90 8 // _validate_utf8 9 0x55, // pushq %rbp 10 0x48, 0x89, 0xe5, //0x00000001 movq %rsp, %rbp 11 0x41, 0x57, //0x00000004 pushq %r15 12 0x41, 0x56, //0x00000006 pushq %r14 13 0x41, 0x54, //0x00000008 pushq %r12 14 0x53, //0x0000000a pushq %rbx 15 0x50, //0x0000000b pushq %rax 16 0x4c, 0x8b, 0x17, //0x0000000c movq (%rdi), %r10 17 0x4c, 0x8b, 0x5f, 0x08, //0x0000000f movq $8(%rdi), %r11 18 0x48, 0x8b, 0x0e, //0x00000013 movq (%rsi), %rcx 19 0x4c, 0x01, 0xd1, //0x00000016 addq %r10, %rcx 20 0x4f, 0x8d, 0x44, 0x1a, 0xfd, //0x00000019 leaq $-3(%r10,%r11), %r8 21 0xe9, 0x10, 0x00, 0x00, 0x00, //0x0000001e jmp LBB0_1 22 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, //0x00000023 .p2align 4, 0x90 23 //0x00000030 LBB0_19 24 0x48, 0x01, 0xd9, //0x00000030 addq %rbx, %rcx 25 //0x00000033 LBB0_1 26 0x4c, 0x39, 0xc1, //0x00000033 cmpq %r8, %rcx 27 0x0f, 0x83, 0xe1, 0x00, 0x00, 0x00, //0x00000036 jae LBB0_2 28 0xbb, 0x01, 0x00, 0x00, 0x00, //0x0000003c movl $1, %ebx 29 0x80, 0x39, 0x00, //0x00000041 cmpb $0, (%rcx) 30 0x0f, 0x89, 0xe6, 0xff, 0xff, 0xff, //0x00000044 jns LBB0_19 31 0x8b, 0x01, //0x0000004a movl (%rcx), %eax 32 0x89, 0xc7, //0x0000004c movl %eax, %edi 33 0x81, 0xe7, 0xf0, 0xc0, 0xc0, 0x00, //0x0000004e andl $12632304, %edi 34 0x81, 0xff, 0xe0, 0x80, 0x80, 0x00, //0x00000054 cmpl $8421600, %edi 35 0x0f, 0x85, 0x30, 0x00, 0x00, 0x00, //0x0000005a jne LBB0_10 36 0x89, 0xc7, //0x00000060 movl %eax, %edi 37 0x81, 0xe7, 0x0f, 0x20, 0x00, 0x00, //0x00000062 andl $8207, %edi 38 0x81, 0xff, 0x0d, 0x20, 0x00, 0x00, //0x00000068 cmpl $8205, %edi 39 0x0f, 0x84, 0x1c, 0x00, 0x00, 0x00, //0x0000006e je LBB0_10 40 0xbb, 0x03, 0x00, 0x00, 0x00, //0x00000074 movl $3, %ebx 41 0x85, 0xff, //0x00000079 testl %edi, %edi 42 0x0f, 0x85, 0xaf, 0xff, 0xff, 0xff, //0x0000007b jne LBB0_19 43 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, //0x00000081 .p2align 4, 0x90 44 //0x00000090 LBB0_10 45 0x89, 0xc7, //0x00000090 movl %eax, %edi 46 0x81, 0xe7, 0xe0, 0xc0, 0x00, 0x00, //0x00000092 andl $49376, %edi 47 0x81, 0xff, 0xc0, 0x80, 0x00, 0x00, //0x00000098 cmpl $32960, %edi 48 0x0f, 0x85, 0x10, 0x00, 0x00, 0x00, //0x0000009e jne LBB0_12 49 0x89, 0xc7, //0x000000a4 movl %eax, %edi 50 0xbb, 0x02, 0x00, 0x00, 0x00, //0x000000a6 movl $2, %ebx 51 0x83, 0xe7, 0x1e, //0x000000ab andl $30, %edi 52 0x0f, 0x85, 0x7c, 0xff, 0xff, 0xff, //0x000000ae jne LBB0_19 53 //0x000000b4 LBB0_12 54 0x89, 0xc7, //0x000000b4 movl %eax, %edi 55 0x81, 0xe7, 0xf8, 0xc0, 0xc0, 0xc0, //0x000000b6 andl $-1061109512, %edi 56 0x81, 0xff, 0xf0, 0x80, 0x80, 0x80, //0x000000bc cmpl $-2139062032, %edi 57 0x0f, 0x85, 0x26, 0x00, 0x00, 0x00, //0x000000c2 jne LBB0_16 58 0x89, 0xc7, //0x000000c8 movl %eax, %edi 59 0x81, 0xe7, 0x07, 0x30, 0x00, 0x00, //0x000000ca andl $12295, %edi 60 0x0f, 0x84, 0x18, 0x00, 0x00, 0x00, //0x000000d0 je LBB0_16 61 0xbb, 0x04, 0x00, 0x00, 0x00, //0x000000d6 movl $4, %ebx 62 0xa8, 0x04, //0x000000db testb $4, %al 63 0x0f, 0x84, 0x4d, 0xff, 0xff, 0xff, //0x000000dd je LBB0_19 64 0x25, 0x03, 0x30, 0x00, 0x00, //0x000000e3 andl $12291, %eax 65 0x0f, 0x84, 0x42, 0xff, 0xff, 0xff, //0x000000e8 je LBB0_19 66 //0x000000ee LBB0_16 67 0x48, 0x89, 0xcf, //0x000000ee movq %rcx, %rdi 68 0x4c, 0x29, 0xd7, //0x000000f1 subq %r10, %rdi 69 0x48, 0x8b, 0x1a, //0x000000f4 movq (%rdx), %rbx 70 0x48, 0x81, 0xfb, 0x00, 0x10, 0x00, 0x00, //0x000000f7 cmpq $4096, %rbx 71 0x0f, 0x83, 0x87, 0x01, 0x00, 0x00, //0x000000fe jae LBB0_17 72 0x48, 0x63, 0xc7, //0x00000104 movslq %edi, %rax 73 0x48, 0x8d, 0x7b, 0x01, //0x00000107 leaq $1(%rbx), %rdi 74 0x48, 0x89, 0x3a, //0x0000010b movq %rdi, (%rdx) 75 0x48, 0x89, 0x44, 0xda, 0x08, //0x0000010e movq %rax, $8(%rdx,%rbx,8) 76 0xbb, 0x01, 0x00, 0x00, 0x00, //0x00000113 movl $1, %ebx 77 0xe9, 0x13, 0xff, 0xff, 0xff, //0x00000118 jmp LBB0_19 78 //0x0000011d LBB0_2 79 0x4d, 0x01, 0xd3, //0x0000011d addq %r10, %r11 80 0x4c, 0x39, 0xd9, //0x00000120 cmpq %r11, %rcx 81 0x0f, 0x83, 0x3e, 0x01, 0x00, 0x00, //0x00000123 jae LBB0_36 82 0x4c, 0x8d, 0x45, 0xdc, //0x00000129 leaq $-36(%rbp), %r8 83 0x4c, 0x8d, 0x4d, 0xda, //0x0000012d leaq $-38(%rbp), %r9 84 0xe9, 0x16, 0x00, 0x00, 0x00, //0x00000131 jmp LBB0_4 85 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, //0x00000136 .p2align 4, 0x90 86 //0x00000140 LBB0_5 87 0x48, 0xff, 0xc1, //0x00000140 incq %rcx 88 0x4c, 0x39, 0xd9, //0x00000143 cmpq %r11, %rcx 89 0x0f, 0x83, 0x1b, 0x01, 0x00, 0x00, //0x00000146 jae LBB0_36 90 //0x0000014c LBB0_4 91 0x80, 0x39, 0x00, //0x0000014c cmpb $0, (%rcx) 92 0x0f, 0x89, 0xeb, 0xff, 0xff, 0xff, //0x0000014f jns LBB0_5 93 0xc6, 0x45, 0xdc, 0x00, //0x00000155 movb $0, $-36(%rbp) 94 0xc6, 0x45, 0xda, 0x00, //0x00000159 movb $0, $-38(%rbp) 95 0x4c, 0x89, 0xdb, //0x0000015d movq %r11, %rbx 96 0x48, 0x29, 0xcb, //0x00000160 subq %rcx, %rbx 97 0x48, 0x83, 0xfb, 0x02, //0x00000163 cmpq $2, %rbx 98 0x0f, 0x82, 0x35, 0x00, 0x00, 0x00, //0x00000167 jb LBB0_21 99 0x44, 0x0f, 0xb6, 0x21, //0x0000016d movzbl (%rcx), %r12d 100 0x44, 0x0f, 0xb6, 0x71, 0x01, //0x00000171 movzbl $1(%rcx), %r14d 101 0x44, 0x88, 0x65, 0xdc, //0x00000176 movb %r12b, $-36(%rbp) 102 0x4c, 0x8d, 0x79, 0x02, //0x0000017a leaq $2(%rcx), %r15 103 0x48, 0x83, 0xc3, 0xfe, //0x0000017e addq $-2, %rbx 104 0x4c, 0x89, 0xcf, //0x00000182 movq %r9, %rdi 105 0x48, 0x85, 0xdb, //0x00000185 testq %rbx, %rbx 106 0x0f, 0x84, 0x29, 0x00, 0x00, 0x00, //0x00000188 je LBB0_24 107 //0x0000018e LBB0_25 108 0x41, 0x0f, 0xb6, 0x07, //0x0000018e movzbl (%r15), %eax 109 0x88, 0x07, //0x00000192 movb %al, (%rdi) 110 0x44, 0x0f, 0xb6, 0x65, 0xdc, //0x00000194 movzbl $-36(%rbp), %r12d 111 0x0f, 0xb6, 0x7d, 0xda, //0x00000199 movzbl $-38(%rbp), %edi 112 0xe9, 0x17, 0x00, 0x00, 0x00, //0x0000019d jmp LBB0_26 113 //0x000001a2 LBB0_21 114 0x45, 0x31, 0xe4, //0x000001a2 xorl %r12d, %r12d 115 0x45, 0x31, 0xf6, //0x000001a5 xorl %r14d, %r14d 116 0x4c, 0x89, 0xc7, //0x000001a8 movq %r8, %rdi 117 0x49, 0x89, 0xcf, //0x000001ab movq %rcx, %r15 118 0x48, 0x85, 0xdb, //0x000001ae testq %rbx, %rbx 119 0x0f, 0x85, 0xd7, 0xff, 0xff, 0xff, //0x000001b1 jne LBB0_25 120 //0x000001b7 LBB0_24 121 0x31, 0xff, //0x000001b7 xorl %edi, %edi 122 //0x000001b9 LBB0_26 123 0x40, 0x0f, 0xb6, 0xc7, //0x000001b9 movzbl %dil, %eax 124 0xc1, 0xe0, 0x10, //0x000001bd shll $16, %eax 125 0x41, 0x0f, 0xb6, 0xde, //0x000001c0 movzbl %r14b, %ebx 126 0xc1, 0xe3, 0x08, //0x000001c4 shll $8, %ebx 127 0x41, 0x0f, 0xb6, 0xfc, //0x000001c7 movzbl %r12b, %edi 128 0x09, 0xdf, //0x000001cb orl %ebx, %edi 129 0x09, 0xf8, //0x000001cd orl %edi, %eax 130 0x25, 0xf0, 0xc0, 0xc0, 0x00, //0x000001cf andl $12632304, %eax 131 0x3d, 0xe0, 0x80, 0x80, 0x00, //0x000001d4 cmpl $8421600, %eax 132 0x0f, 0x85, 0x21, 0x00, 0x00, 0x00, //0x000001d9 jne LBB0_29 133 0x89, 0xf8, //0x000001df movl %edi, %eax 134 0x25, 0x0f, 0x20, 0x00, 0x00, //0x000001e1 andl $8207, %eax 135 0x3d, 0x0d, 0x20, 0x00, 0x00, //0x000001e6 cmpl $8205, %eax 136 0x0f, 0x84, 0x0f, 0x00, 0x00, 0x00, //0x000001eb je LBB0_29 137 0xbb, 0x03, 0x00, 0x00, 0x00, //0x000001f1 movl $3, %ebx 138 0x85, 0xc0, //0x000001f6 testl %eax, %eax 139 0x0f, 0x85, 0x23, 0x00, 0x00, 0x00, //0x000001f8 jne LBB0_34 140 0x90, 0x90, //0x000001fe .p2align 4, 0x90 141 //0x00000200 LBB0_29 142 0x41, 0xf6, 0xc4, 0x1e, //0x00000200 testb $30, %r12b 143 0x0f, 0x84, 0x28, 0x00, 0x00, 0x00, //0x00000204 je LBB0_31 144 0x81, 0xe7, 0xe0, 0xc0, 0x00, 0x00, //0x0000020a andl $49376, %edi 145 0xbb, 0x02, 0x00, 0x00, 0x00, //0x00000210 movl $2, %ebx 146 0x81, 0xff, 0xc0, 0x80, 0x00, 0x00, //0x00000215 cmpl $32960, %edi 147 0x0f, 0x85, 0x11, 0x00, 0x00, 0x00, //0x0000021b jne LBB0_31 148 //0x00000221 LBB0_34 149 0x48, 0x01, 0xd9, //0x00000221 addq %rbx, %rcx 150 0x4c, 0x39, 0xd9, //0x00000224 cmpq %r11, %rcx 151 0x0f, 0x82, 0x1f, 0xff, 0xff, 0xff, //0x00000227 jb LBB0_4 152 0xe9, 0x35, 0x00, 0x00, 0x00, //0x0000022d jmp LBB0_36 153 //0x00000232 LBB0_31 154 0x48, 0x89, 0xc8, //0x00000232 movq %rcx, %rax 155 0x4c, 0x29, 0xd0, //0x00000235 subq %r10, %rax 156 0x48, 0x8b, 0x3a, //0x00000238 movq (%rdx), %rdi 157 0x48, 0x81, 0xff, 0x00, 0x10, 0x00, 0x00, //0x0000023b cmpq $4096, %rdi 158 0x0f, 0x83, 0x34, 0x00, 0x00, 0x00, //0x00000242 jae LBB0_32 159 0x48, 0x98, //0x00000248 cltq 160 0x48, 0x8d, 0x5f, 0x01, //0x0000024a leaq $1(%rdi), %rbx 161 0x48, 0x89, 0x1a, //0x0000024e movq %rbx, (%rdx) 162 0x48, 0x89, 0x44, 0xfa, 0x08, //0x00000251 movq %rax, $8(%rdx,%rdi,8) 163 0xbb, 0x01, 0x00, 0x00, 0x00, //0x00000256 movl $1, %ebx 164 0x48, 0x01, 0xd9, //0x0000025b addq %rbx, %rcx 165 0x4c, 0x39, 0xd9, //0x0000025e cmpq %r11, %rcx 166 0x0f, 0x82, 0xe5, 0xfe, 0xff, 0xff, //0x00000261 jb LBB0_4 167 //0x00000267 LBB0_36 168 0x4c, 0x29, 0xd1, //0x00000267 subq %r10, %rcx 169 0x48, 0x89, 0x0e, //0x0000026a movq %rcx, (%rsi) 170 0x31, 0xc0, //0x0000026d xorl %eax, %eax 171 //0x0000026f LBB0_37 172 0x48, 0x83, 0xc4, 0x08, //0x0000026f addq $8, %rsp 173 0x5b, //0x00000273 popq %rbx 174 0x41, 0x5c, //0x00000274 popq %r12 175 0x41, 0x5e, //0x00000276 popq %r14 176 0x41, 0x5f, //0x00000278 popq %r15 177 0x5d, //0x0000027a popq %rbp 178 0xc3, //0x0000027b retq 179 //0x0000027c LBB0_32 180 0x48, 0x89, 0x06, //0x0000027c movq %rax, (%rsi) 181 0x48, 0xc7, 0xc0, 0xff, 0xff, 0xff, 0xff, //0x0000027f movq $-1, %rax 182 0xe9, 0xe4, 0xff, 0xff, 0xff, //0x00000286 jmp LBB0_37 183 //0x0000028b LBB0_17 184 0x48, 0x89, 0x3e, //0x0000028b movq %rdi, (%rsi) 185 0x48, 0xc7, 0xc0, 0xff, 0xff, 0xff, 0xff, //0x0000028e movq $-1, %rax 186 0xe9, 0xd5, 0xff, 0xff, 0xff, //0x00000295 jmp LBB0_37 187 0x00, 0x00, //0x0000029a .p2align 2, 0x00 188 //0x0000029c _MASK_USE_NUMBER 189 0x02, 0x00, 0x00, 0x00, //0x0000029c .long 2 190 } 191