// File: /workspace/github_c_makefile_star2_O3/s3lase[P]v6shell/pexec.c
// Function: err_pexec
void
err_pexec(const char *file, char *const *argv)
{
	const char *f, *n;

	(void)pexec(file, argv);

	f = (file == NULL) ? "(null)" : file;
	n = getmyname();

	if (EQUAL(n, "glob6")) {
		if (errno == ENOEXEC)
			err(SH_ERR, FMT1S, ERR_NOSHELL);
		if (errno == E2BIG)
			err(SH_ERR, FMT1S, ERR_E2BIG);
		err(SH_ERR, FMT1S, ERR_GNOTFOUND);
	} else if (EQUAL(n, "sh6")) {
		if (errno == ENOEXEC)
			err(125, FMT1S, ERR_NOSHELL);
		if (errno == E2BIG)
			err(126, FMT2S, f, ERR_E2BIG);
		if (errno != ENOENT && errno != ENOTDIR)
			err(126, FMT2S, f, ERR_EXEC);
		err(127, FMT2S, f, ERR_NOTFOUND);
	} else {
		if (errno == ENOEXEC)
			err(125, FMT3S, n, f, ERR_NOSHELL);
		if (errno == E2BIG)
			err(126, FMT3S, n, f, ERR_E2BIG);
		if (errno != ENOENT && errno != ENOTDIR)
			err(126, FMT3S, n, f, ERR_EXEC);
		err(127, FMT3S, n, f, ERR_NOTFOUND);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
callq 0x1cb4
testq %r14, %r14
leaq 0x11d6(%rip), %rbx      # 0x319a
cmovneq %r14, %rbx
callq 0x1bf7
movq %rax, %r14
movzbl (%rax), %eax
cmpl $0x73, %eax
je 0x2065
cmpl $0x67, %eax
jne 0x207c
leaq 0x11f5(%rip), %rsi      # 0x31e1
movq %r14, %rdi
callq 0x1140
testl %eax, %eax
jne 0x207c
callq 0x1060
movq %rax, %rbx
movl (%rax), %eax
cmpl $0x8, %eax
jne 0x2027
leaq 0x1217(%rip), %rsi      # 0x3229
leaq 0x11ce(%rip), %rdx      # 0x31e7
movl $0x2, %edi
xorl %eax, %eax
callq 0x19b0
movl (%rbx), %eax
cmpl $0x7, %eax
jne 0x2046
leaq 0x11f6(%rip), %rsi      # 0x3229
leaq 0x1126(%rip), %rdx      # 0x3160
movl $0x2, %edi
xorl %eax, %eax
callq 0x19b0
leaq 0x11dc(%rip), %rsi      # 0x3229
leaq 0x119d(%rip), %rdx      # 0x31f1
movl $0x2, %edi
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
jmp 0x19b0
leaq 0x1198(%rip), %rsi      # 0x3204
movq %r14, %rdi
callq 0x1140
testl %eax, %eax
je 0x2125
callq 0x1060
movq %rax, %r15
movl (%rax), %eax
cmpl $0x8, %eax
jne 0x20ae
leaq 0x118f(%rip), %rsi      # 0x3221
leaq 0x114e(%rip), %r8       # 0x31e7
movl $0x7d, %edi
movq %r14, %rdx
movq %rbx, %rcx
xorl %eax, %eax
callq 0x19b0
movl (%r15), %eax
cmpl $0x7, %eax
jne 0x20d6
leaq 0x1167(%rip), %rsi      # 0x3221
leaq 0x109f(%rip), %r8       # 0x3160
movl $0x7e, %edi
movq %r14, %rdx
movq %rbx, %rcx
xorl %eax, %eax
callq 0x19b0
movl (%r15), %eax
cmpl $0x2, %eax
je 0x2100
cmpl $0x14, %eax
je 0x2100
leaq 0x113a(%rip), %rsi      # 0x3221
leaq 0x111a(%rip), %r8       # 0x3208
movl $0x7e, %edi
movq %r14, %rdx
movq %rbx, %rcx
xorl %eax, %eax
callq 0x19b0
leaq 0x111a(%rip), %rsi      # 0x3221
leaq 0x1109(%rip), %r8       # 0x3217
movl $0x7f, %edi
movq %r14, %rdx
movq %rbx, %rcx
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
jmp 0x19b0
callq 0x1060
movq %rax, %r14
movl (%rax), %eax
cmpl $0x8, %eax
jne 0x2151
leaq 0x10ee(%rip), %rsi      # 0x3229
leaq 0x10a5(%rip), %rdx      # 0x31e7
movl $0x7d, %edi
xorl %eax, %eax
callq 0x19b0
movl (%r14), %eax
cmpl $0x7, %eax
jne 0x2176
leaq 0x10c8(%rip), %rsi      # 0x3225
leaq 0xffc(%rip), %rcx       # 0x3160
movl $0x7e, %edi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x19b0
movl (%r14), %eax
cmpl $0x2, %eax
je 0x219d
cmpl $0x14, %eax
je 0x219d
leaq 0x109e(%rip), %rsi      # 0x3225
leaq 0x107a(%rip), %rcx      # 0x3208
movl $0x7e, %edi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x19b0
leaq 0x1081(%rip), %rsi      # 0x3225
leaq 0x106c(%rip), %rcx      # 0x3217
movl $0x7f, %edi
movq %rbx, %rdx
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
jmp 0x19b0