Function at 0x40b330
Capabilities:
Query environment variable

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
mov r12, rdx
mov ebp, ecx
call fcn.00404b20
lea rcx, str.GCC_EXEC_PREFIX
mov rbx, qword [r12]
call sub.msvcrt.dll_getenv
test rax, rax
je 0x40b372
lea rdx, str.gcc_nm
xor r8d, r8d
mov rcx, rax
call fcn.00401af0
mov rbx, rax
lea r8, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_lib_gcc_
lea rdx, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_bin_
mov rcx, rbx
call fcn.004023e0
lea rdx, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_lib_gcc_
test rax, rax
lea r8, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_libexec_gcc_
mov rcx, rbx
lea rbx, [0x0040d167]
cmove rax, rdx
lea rdx, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_bin_
mov qword [0x00411070], rax
call fcn.004023e0
lea rdx, str._builds_idf_crosstool_NG_builds_xtensa_esp32_elf_libexec_gcc_
test rax, rax
lea r8, [0x0040d167]
lea rcx, str..._.._.._.._
cmove rax, rdx
lea rdx, str.xtensa_esp32_elf
xor r9d, r9d
mov qword [0x00411068], rax
call fcn.00401af0
mov rcx, qword [0x00411070]
lea r9, str.8.4.0
lea rdx, str.xtensa_esp32_elf
mov r8, rbx
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbx
call fcn.00401af0
lea rdx, [0x0040d08a]
xor r8d, r8d
mov rcx, rax
call fcn.00401af0
lea rdx, [0x00411050]
mov rcx, rax
call fcn.00401860
mov rcx, qword [0x00411068]
lea r9, str.8.4.0
lea rdx, str.xtensa_esp32_elf
mov r8, rbx
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], rbx
call fcn.00401af0
lea rdx, [0x00411050]
mov rcx, rax
mov qword [0x00411068], rax
call fcn.00401860
lea rdx, [0x00411030]
lea rcx, [0x0040d08e]
call fcn.00401990
test ebp, ebp
jle 0x40b563
lea r8d, [rbp - 1]
mov r9, r12
xor eax, eax
lea r10, [0x0040d093]
mov r14, r8
add r8, 1
jmp 0x40b4c3
add rax, 1
add r9, 8
cmp r8, rax
je 0x40b563
mov rbx, qword [r9]
mov ecx, 2
mov rdi, r10
mov r13d, eax
mov rsi, rbx
repe cmpsb byte [rsi], byte [rdi]
jne 0x40b4b2
lea r8d, [rbp + 1]
lea rsi, [r12 + rax*8 + 8]
mov rcx, r9
sub r8d, eax
mov rdx, rsi
movsxd r8, r8d
shl r8, 3
call sub.msvcrt.dll_memmove
cmp byte [rbx + 2], 0
je 0x40b6ee
add rbx, 2
mov ebp, r14d
xor eax, eax
or rcx, 0xffffffffffffffff
mov rdi, rbx
repne scasb al, byte [rdi]
not rcx
cmp rcx, 1
je 0x40b545
lea rax, [rbx + rcx - 2]
cmp rbx, rax
jae 0x40b545
movzx eax, byte [rax]
cmp al, 0x5c
je 0x40b545
cmp al, 0x2f
je 0x40b545
lea rdx, [0x0040d165]
mov rcx, rbx
xor r8d, r8d
call fcn.00401af0
mov rbx, rax
lea rcx, [0x00411030]
mov rdx, rbx
call fcn.00401850
lea rcx, [0x00411050]
mov rdx, rbx
call fcn.00401850
lea rdx, str.liblto_plugin_0.dll
lea rcx, [0x00411050]
mov r8d, 4
call fcn.004015c0
test rax, rax
mov rdi, rax
je 0x40b7a1
lea rdx, [0x0040d0f5]
lea rcx, [0x00411050]
mov r8d, 1
call fcn.004015c0
test rax, rax
mov rsi, rax
je 0x40b722
lea ecx, [rbp + 4]
mov edx, 8
movsxd rcx, ecx
call fcn.00403620
mov rbx, rax
mov qword [rax], rsi
lea rax, str.__plugin
cmp ebp, 1
mov qword [rbx + 0x10], rdi
mov qword [rbx + 8], rax
jle 0x40b78d
mov eax, 1
mov rdx, qword [r12 + rax*8]
mov qword [rbx + rax*8 + 0x10], rdx
add rax, 1
cmp ebp, eax
jg 0x40b5e0
add ebp, 2
lea rcx, str.gcc_
xor r8d, r8d
movsxd rbp, ebp
mov rdx, rsi
mov qword [rbx + rbp*8], 0
call fcn.00401af0
mov r9, rax
lea rax, [rsp + 0x4c]
mov r8, rbx
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov rdx, rsi
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x48]
mov ecx, 3
mov qword [rsp + 0x30], rax
call fcn.00402400
test rax, rax
mov rbx, rax
je 0x40b682
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str.Error_running__s:__s_n
lea rcx, [rax + 0x60]
mov r9, rbx
mov r8, rsi
call fcn.0040b300
mov eax, 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov eax, dword [rsp + 0x48]
test eax, eax
je 0x40b673
movzx edx, al
test edx, edx
je 0x40b71a
cmp edx, 0x7f
je 0x40b797
mov edi, eax
lea rbx, str.__core_dumped
and edi, 0x7f
test al, 0x80
lea rax, [0x0040d04e]
mov ecx, edi
cmove rbx, rax
call fcn.00403390
mov rbp, rax
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str._s_terminated_with_signal__d___s__s_n
lea rcx, [rax + 0x60]
mov qword [rsp + 0x28], rbx
mov qword [rsp + 0x20], rbp
mov r9d, edi
mov r8, rsi
call fcn.0040b300
mov eax, 1
jmp 0x40b673
mov rbx, qword [rax]
test rbx, rbx
je 0x40b7cf
mov r8d, ebp
mov rdx, rsi
mov rcx, rax
sub r8d, r13d
sub ebp, 2
movsxd r8, r8d
shl r8, 3
call sub.msvcrt.dll_memmove
jmp 0x40b507
movzx eax, ah
jmp 0x40b673
lea r8, [0x0040d0f5]
lea rdx, [0x0040d0f8]
lea rcx, str.xtensa_esp32_elf
xor r9d, r9d
call fcn.00401af0
lea rcx, [0x00411030]
mov r8d, 1
mov rdx, rax
mov rbx, rax
call fcn.004015c0
test rax, rax
mov rsi, rax
jne 0x40b5ad
mov rsi, qword [r12]
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str._s:_Cannot_find_binary__s_n
lea rcx, [rax + 0x60]
mov r9, rbx
mov r8, rsi
call fcn.0040b300
mov ecx, 1
call sub.msvcrt.dll_exit
mov ebp, 1
jmp 0x40b5f1
mov eax, 1
jmp 0x40b673
mov rbx, qword [r12]
call qword [sym.imp.msvcrt.dll___iob_func]
lea r9, str.liblto_plugin_0.dll
lea rcx, [rax + 0x60]
lea rdx, str._s:_Cannot_find_plugin__s_n
mov r8, rbx
call fcn.0040b300
mov ecx, 1
call sub.msvcrt.dll_exit
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str.Usage:_gcc_ar___B_prefix__ar_arguments_..._n
lea rcx, [rax + 0x60]
call fcn.0040b300
mov ecx, 1
call sub.msvcrt.dll_exit
nop
push rbp
mov rbp, rsp
pop rbp
jmp fcn.00401540