// File: /workspace/github_cpp_makefile_star2_O1/codebrainz[P]libutfxx/utf/string-demo.cxx
// Function: main
int main()
{
	utf::u8string s = "Hello World";

	s += ", How are you?";
	s += " Not too shabby";
	s += ", if I must say!";

	std::cout << s << std::endl;

	utf::u32string s1 = "Hello World";
	utf::u16string s2 = "Hello World";
	utf::u8string s3 = "Hi";

	std::cout <<s3<<std::endl;

	bool eq = (s1 == s2);
	bool neq = (s1 != s2);

	std::cout << "EQ: " << eq << std::endl;
	std::cout << "NEQ: " << neq << std::endl;

	//std::cout << "to_string(): " << std::to_string(s2) << std::endl;

	s2 += "Foo";

	std::cout << s1 << std::endl;
	std::cout << s2 << std::endl;

	//for (auto ch : s) {
	//	std::cout << ch << ", ";
	//}
	//std::cout << std::endl;

	return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xe8, %rsp
leaq 0x1cc4(%rip), %rsi      # 0x4004
leaq 0x68(%rsp), %rbx
movq %rbx, %rdi
callq 0x2952
leaq 0x1cbc(%rip), %rsi      # 0x4010
movq %rbx, %rdi
callq 0x2e30
leaq 0x1cbc(%rip), %rsi      # 0x401f
leaq 0x68(%rsp), %rdi
callq 0x2e30
leaq 0x1cbb(%rip), %rsi      # 0x402f
leaq 0x68(%rsp), %rdi
callq 0x2e30
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
leaq 0x68(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x2150
movq 0x8(%rsp), %rbx
testq %rbx, %rbx
je 0x23c8
movq %rbx, %rdi
callq 0x2080
movq 0x3c1d(%rip), %rdi      # 0x5fd8
movq %rbx, %rsi
movq %rax, %rdx
callq 0x2130
jmp 0x23e6
movq 0x3c09(%rip), %rax      # 0x5fd8
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
leaq (%rax,%rcx), %rdi
movl 0x20(%rax,%rcx), %esi
orl $0x1, %esi
callq 0x21a0
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x23fd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2110
movq 0x3bd4(%rip), %rdi      # 0x5fd8
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq 0x3bb9(%rip), %rbx      # 0x5fd8
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
leaq 0x1bce(%rip), %rsi      # 0x4004
leaq 0x48(%rsp), %rdi
callq 0x29f0
leaq 0x1bbd(%rip), %rsi      # 0x4004
leaq 0x28(%rsp), %rdi
callq 0x2a96
leaq 0x1be8(%rip), %rsi      # 0x4040
leaq 0xc8(%rsp), %rdi
callq 0x2952
leaq 0x8(%rsp), %rsi
movq %r15, (%rsi)
movq $0x0, 0x8(%rsi)
movb $0x0, 0x10(%rsi)
leaq 0xc8(%rsp), %rdi
callq 0x2150
movq 0x8(%rsp), %r14
testq %r14, %r14
je 0x24ac
movq %r14, %rdi
callq 0x2080
movq 0x3b39(%rip), %rdi      # 0x5fd8
movq %r14, %rsi
movq %rax, %rdx
callq 0x2130
jmp 0x24c3
movq (%rbx), %rax
movq -0x18(%rax), %rax
leaq (%rbx,%rax), %rdi
movl 0x20(%rbx,%rax), %esi
orl $0x1, %esi
callq 0x21a0
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x24da
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2110
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq 0x3ae0(%rip), %rdi      # 0x5fd8
callq 0x2030
movq %rax, %rdi
callq 0x20a0
leaq 0xb8(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rax
leaq (%rsi,%rax,2), %rdx
leaq 0xa8(%rsp), %rdi
callq 0x2c50
leaq 0x48(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x2b3c
movl %eax, %ebp
movq 0xa8(%rsp), %rdi
cmpq %r14, %rdi
je 0x2562
movq 0xb8(%rsp), %rax
leaq 0x2(,%rax,2), %rsi
callq 0x2110
leaq 0x98(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rax
leaq (%rsi,%rax,2), %rdx
leaq 0x88(%rsp), %rdi
callq 0x2c50
leaq 0x48(%rsp), %rdi
leaq 0x88(%rsp), %rsi
callq 0x2bc4
movl %eax, %ebx
movq 0x88(%rsp), %rdi
cmpq %r14, %rdi
je 0x25bf
movq 0x98(%rsp), %rax
leaq 0x2(,%rax,2), %rsi
callq 0x2110
movq 0x3a12(%rip), %rdi      # 0x5fd8
leaq 0x1a77(%rip), %rsi      # 0x4044
movl $0x4, %edx
callq 0x2130
movzbl %bpl, %esi
movq 0x39f6(%rip), %rdi      # 0x5fd8
callq 0x2190
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
movq 0x39c0(%rip), %rdi      # 0x5fd8
leaq 0x1a24(%rip), %rsi      # 0x4043
movl $0x5, %edx
callq 0x2130
movzbl %bl, %esi
movq 0x39a5(%rip), %rbx      # 0x5fd8
movq %rbx, %rdi
callq 0x2190
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
leaq 0x19dd(%rip), %rsi      # 0x4049
leaq 0x28(%rsp), %rdi
callq 0x317c
leaq 0x8(%rsp), %rsi
movq %r15, (%rsi)
movq $0x0, 0x8(%rsi)
movb $0x0, 0x10(%rsi)
leaq 0x48(%rsp), %rdi
callq 0x21d0
movq 0x8(%rsp), %r14
testq %r14, %r14
je 0x26ba
movq %r14, %rdi
callq 0x2080
movq 0x392b(%rip), %rdi      # 0x5fd8
movq %r14, %rsi
movq %rax, %rdx
callq 0x2130
jmp 0x26d1
movq (%rbx), %rax
movq -0x18(%rax), %rax
leaq (%rbx,%rax), %rdi
movl 0x20(%rbx,%rax), %esi
orl $0x1, %esi
callq 0x21a0
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x26e8
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2110
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq 0x38d2(%rip), %rbx      # 0x5fd8
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
leaq 0x8(%rsp), %rsi
movq %r15, (%rsi)
movq $0x0, 0x8(%rsi)
movb $0x0, 0x10(%rsi)
leaq 0x28(%rsp), %rdi
callq 0x2170
movq 0x8(%rsp), %r14
testq %r14, %r14
je 0x275a
movq %r14, %rdi
callq 0x2080
movq 0x388b(%rip), %rdi      # 0x5fd8
movq %r14, %rsi
movq %rax, %rdx
callq 0x2130
jmp 0x2771
movq (%rbx), %rax
movq -0x18(%rax), %rax
leaq (%rbx,%rax), %rdi
movl 0x20(%rbx,%rax), %esi
orl $0x1, %esi
callq 0x21a0
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x2788
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2110
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq 0x3832(%rip), %rdi      # 0x5fd8
callq 0x2030
movq %rax, %rdi
callq 0x20a0
leaq 0xd8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27d4
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x2110
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x27f4
movq 0x38(%rsp), %rax
leaq 0x2(,%rax,2), %rsi
callq 0x2110
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2814
movq 0x58(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x2110
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x282f
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2110
xorl %eax, %eax
addq $0xe8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x88(%rsp), %rdi
cmpq %r14, %rdi
je 0x28cd
movq 0x98(%rsp), %rax
jmp 0x2871
movq %rax, %rbx
movq 0xa8(%rsp), %rdi
cmpq %r14, %rdi
je 0x28cd
movq 0xb8(%rsp), %rax
leaq 0x2(,%rax,2), %rsi
jmp 0x28a5
jmp 0x28ca
movq %rax, %rbx
jmp 0x28ee
movq %rax, %rbx
jmp 0x290e
jmp 0x28c5
jmp 0x2890
jmp 0x2890
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x28cd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x2110
jmp 0x28cd
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x292e
movq 0x18(%rsp), %rsi
incq %rsi
jmp 0x2929
jmp 0x28ca
movq %rax, %rbx
jmp 0x292e
movq %rax, %rbx
leaq 0xd8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x28ee
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x2110
leaq 0x38(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x290e
movq 0x38(%rsp), %rax
leaq 0x2(,%rax,2), %rsi
callq 0x2110
leaq 0x58(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x292e
movq 0x58(%rsp), %rax
leaq 0x4(,%rax,4), %rsi
callq 0x2110
leaq 0x78(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2949
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x2110
movq %rbx, %rdi
callq 0x21b0
nop