// File: /workspace/github_cpp_makefile_star2_O1/jliesch[P]ofxget/pugixml/pugixml.cpp
// Function: pugi::impl::(anonymous namespace)::utf32_writer::value_type pugi::impl::(anonymous namespace)::utf8_decoder::process<pugi::impl::(anonymous namespace)::utf32_writer>(unsigned char const*, unsigned long, pugi::impl::(anonymous namespace)::utf32_writer::value_type, pugi::impl::(anonymous namespace)::utf32_writer)
static inline typename Traits::value_type process(const uint8_t* data, size_t size, typename Traits::value_type result, Traits)
		{
			const uint8_t utf8_byte_mask = 0x3f;

			while (size)
			{
				uint8_t lead = *data;

				// 0xxxxxxx -> U+0000..U+007F
				if (lead < 0x80)
				{
					result = Traits::low(result, lead);
					data += 1;
					size -= 1;

					// process aligned single-byte (ascii) blocks
					if ((reinterpret_cast<uintptr_t>(data) & 3) == 0)
					{
						// round-trip through void* to silence 'cast increases required alignment of target type' warnings
						while (size >= 4 && (*static_cast<const uint32_t*>(static_cast<const void*>(data)) & 0x80808080) == 0)
						{
							result = Traits::low(result, data[0]);
							result = Traits::low(result, data[1]);
							result = Traits::low(result, data[2]);
							result = Traits::low(result, data[3]);
							data += 4;
							size -= 4;
						}
					}
				}
				// 110xxxxx -> U+0080..U+07FF
				else if (static_cast<unsigned int>(lead - 0xC0) < 0x20 && size >= 2 && (data[1] & 0xc0) == 0x80)
				{
					result = Traits::low(result, ((lead & ~0xC0) << 6) | (data[1] & utf8_byte_mask));
					data += 2;
					size -= 2;
				}
				// 1110xxxx -> U+0800-U+FFFF
				else if (static_cast<unsigned int>(lead - 0xE0) < 0x10 && size >= 3 && (data[1] & 0xc0) == 0x80 && (data[2] & 0xc0) == 0x80)
				{
					result = Traits::low(result, ((lead & ~0xE0) << 12) | ((data[1] & utf8_byte_mask) << 6) | (data[2] & utf8_byte_mask));
					data += 3;
					size -= 3;
				}
				// 11110xxx -> U+10000..U+10FFFF
				else if (static_cast<unsigned int>(lead - 0xF0) < 0x08 && size >= 4 && (data[1] & 0xc0) == 0x80 && (data[2] & 0xc0) == 0x80 && (data[3] & 0xc0) == 0x80)
				{
					result = Traits::high(result, ((lead & ~0xF0) << 18) | ((data[1] & utf8_byte_mask) << 12) | ((data[2] & utf8_byte_mask) << 6) | (data[3] & utf8_byte_mask));
					data += 4;
					size -= 4;
				}
				// 10xxxxxx or 11111xxx -> invalid
				else
				{
					data += 1;
					size -= 1;
				}
			}

			return result;
		}

// Assembly:
movq %rdx, %rax
testq %rsi, %rsi
je 0x2aa1e
movzbl (%rdi), %ecx
testb %cl, %cl
js 0x2a8e4
movl %ecx, (%rax)
addq $0x4, %rax
incq %rdi
decq %rsi
cmpq $0x4, %rsi
jb 0x2a885
movl %edi, %ecx
andl $0x3, %ecx
jne 0x2a885
testl $0x80808080, (%rdi)     # imm = 0x80808080
jne 0x2a885
movzbl (%rdi), %ecx
movl %ecx, (%rax)
movzbl 0x1(%rdi), %ecx
movl %ecx, 0x4(%rax)
movzbl 0x2(%rdi), %ecx
movl %ecx, 0x8(%rax)
movzbl 0x3(%rdi), %ecx
movl %ecx, 0xc(%rax)
addq $0x10, %rax
addq $0x4, %rdi
addq $-0x4, %rsi
cmpq $0x3, %rsi
ja 0x2a8ae
jmp 0x2a885
cmpq $0x1, %rsi
je 0x2a929
movl %ecx, %edx
andl $-0x20, %edx
cmpl $0xc0, %edx
jne 0x2a929
movzbl 0x1(%rdi), %edx
movl %edx, %r8d
andl $-0x40, %r8d
cmpl $0x80, %r8d
jne 0x2a929
andl $0x1f, %ecx
shll $0x6, %ecx
andl $0x3f, %edx
orl %ecx, %edx
movl %edx, (%rax)
addq $0x4, %rax
addq $0x2, %rdi
addq $-0x2, %rsi
jmp 0x2a885
cmpq $0x3, %rsi
jb 0x2a98e
movl %ecx, %edx
andl $-0x10, %edx
cmpl $0xe0, %edx
jne 0x2a98e
movzbl 0x1(%rdi), %edx
movl %edx, %r8d
andl $-0x40, %r8d
cmpl $0x80, %r8d
jne 0x2a98e
movzbl 0x2(%rdi), %r8d
movl %r8d, %r9d
andl $-0x40, %r9d
cmpl $0x80, %r9d
jne 0x2a98e
shll $0xc, %ecx
movzwl %cx, %ecx
andl $0x3f, %edx
shll $0x6, %edx
orl %ecx, %edx
andl $0x3f, %r8d
orl %edx, %r8d
movl %r8d, (%rax)
addq $0x4, %rax
addq $0x3, %rdi
addq $-0x3, %rsi
jmp 0x2a885
cmpq $0x4, %rsi
jb 0x2aa13
movl %ecx, %edx
andl $-0x8, %edx
cmpl $0xf0, %edx
jne 0x2aa13
movzbl 0x1(%rdi), %edx
movl %edx, %r8d
andl $-0x40, %r8d
cmpl $0x80, %r8d
jne 0x2aa13
movzbl 0x2(%rdi), %r8d
movl %r8d, %r9d
andl $-0x40, %r9d
cmpl $0x80, %r9d
jne 0x2aa13
movzbl 0x3(%rdi), %r9d
movl %r9d, %r10d
andl $-0x40, %r10d
cmpl $0x80, %r10d
jne 0x2aa13
andl $0x7, %ecx
shll $0x12, %ecx
andl $0x3f, %edx
shll $0xc, %edx
orl %ecx, %edx
andl $0x3f, %r8d
shll $0x6, %r8d
orl %edx, %r8d
andl $0x3f, %r9d
orl %r8d, %r9d
movl %r9d, (%rax)
addq $0x4, %rax
addq $0x4, %rdi
addq $-0x4, %rsi
jmp 0x2a885
incq %rdi
decq %rsi
jmp 0x2a885
retq