// File: /workspace/github_cpp_makefile_star2_O2/yayuntian[P]user_agent/operatingSystem.cpp
// Function: gecko(UserAgent&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&, int)
void gecko(UserAgent& p, vector<string>& comment, int slen) {
    if (slen <= 1) {
        return;
    }

    if (comment[1] == "U") {
        if (slen > 2) {
            p.os = normalizeOS(comment[2]);
        } else {
            p.os = normalizeOS(comment[1]);
        }
    } else {
        if (p.platform == "Android") {
            p.mobile = true;
            p.os = p.platform;
            p.platform = normalizeOS(comment[1]);
        } else if (comment[0] == "Mobile" || comment[0] == "Tablet") {
            p.mobile = true;
            p.os = "FirefoxOS";
        } else {
            if (p.os == "") {
                p.os = normalizeOS(comment[1]);
            }
        }
    }

    if (slen > 3 && !starts_with(comment[3], "rv:")) {
        p.localization = comment[3];
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xa0, %rsp
cmpl $0x2, %edx
jl 0x1e171
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rdi
addq $0x20, %rdi
leaq 0x1123a(%rip), %rsi     # 0x2f233
callq 0xb1d5
testb %al, %al
je 0x1e053
cmpl $0x2, %ebp
jne 0x1e0bd
movq (%r14), %rsi
addq $0x20, %rsi
leaq 0x60(%rsp), %r14
movq %r14, %rdi
callq 0x7490
movq %rsp, %rdi
movq %r14, %rsi
callq 0x1dab9
addq $0x60, %rbx
movq %rsp, %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x7400
movq %r14, %rdi
callq 0x7748
leaq 0x60(%rsp), %rdi
callq 0x7748
jmp 0x1e171
leaq 0x40(%rbx), %r15
leaq 0xb349(%rip), %rsi      # 0x293a7
movq %r15, %rdi
callq 0xb1d5
testb %al, %al
je 0x1e105
movb $0x1, 0x121(%rbx)
leaq 0x60(%rbx), %rdi
movq %r15, %rsi
callq 0x71f0
movq (%r14), %rsi
addq $0x20, %rsi
leaq 0x40(%rsp), %r12
movq %r12, %rdi
callq 0x7490
movq %rsp, %rdi
movq %r12, %rsi
callq 0x1dab9
movq %rsp, %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x7400
movq %r12, %rdi
callq 0x7748
leaq 0x40(%rsp), %rdi
jmp 0x1e0fe
movq (%r14), %rsi
addq $0x40, %rsi
leaq 0x80(%rsp), %r15
movq %r15, %rdi
callq 0x7490
movq %rsp, %rdi
movq %r15, %rsi
callq 0x1dab9
leaq 0x60(%rbx), %rdi
movq %rsp, %r15
movq %r15, %rsi
callq 0x7400
movq %r15, %rdi
callq 0x7748
leaq 0x80(%rsp), %rdi
callq 0x7748
jmp 0x1e142
movq (%r14), %rdi
leaq 0x110f7(%rip), %rsi     # 0x2f206
callq 0xb1d5
testb %al, %al
jne 0x1e12b
movq (%r14), %rdi
leaq 0xaabc(%rip), %rsi      # 0x28bde
callq 0xb1d5
testb %al, %al
je 0x1e181
movb $0x1, 0x121(%rbx)
leaq 0x60(%rbx), %rdi
leaq 0xa9f2(%rip), %rsi      # 0x28b2f
callq 0x7700
cmpl $0x4, %ebp
jb 0x1e171
movq (%r14), %rdi
addq $0x60, %rdi
leaq 0x1109c(%rip), %rsi     # 0x2f1f1
callq 0x204c2
testb %al, %al
jne 0x1e171
movq (%r14), %rsi
addq $0x60, %rsi
subq $-0x80, %rbx
movq %rbx, %rdi
callq 0x71f0
addq $0xa0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x60(%rbx), %r15
leaq 0xd238(%rip), %rsi      # 0x2b3c4
movq %r15, %rdi
callq 0xb1d5
testb %al, %al
je 0x1e142
movq (%r14), %rsi
addq $0x20, %rsi
leaq 0x20(%rsp), %r12
movq %r12, %rdi
callq 0x7490
movq %rsp, %rdi
movq %r12, %rsi
callq 0x1dab9
movq %rsp, %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x7400
movq %r12, %rdi
callq 0x7748
leaq 0x20(%rsp), %rdi
jmp 0x1e0fe
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
jmp 0x1e200
movq %rax, %rbx
leaq 0x80(%rsp), %rdi
jmp 0x1e200
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
jmp 0x1e200
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x7748
movq %rbx, %rdi
callq 0x7640