#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ GenPrintInstr2Operands(int, int, int, long, int, long);
int /*<<< orphan*/ GenPrintInstrNoOperand(int, int);
int /*<<< orphan*/ GenPrintInstrOneOperand(int, int /*<<< orphan*/, int, long);
void GenPrintInstr1Operand(int instr, int instrval, int operand,
                           long operandval) {
  if (instr == 0x10) {
    GenPrintInstr2Operands(instr, instrval, operand, operandval, operand,
                           operandval);
  } else {
    GenPrintInstrOneOperand(operand < 0x80 ? 0x81 : 0x80, 0, operand,
                            operandval);
    GenPrintInstrNoOperand(instr, instrval);
  }
}


x86 assembly (clang, -O0):
<GenPrintInstr1Operand>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
cmpl   $0x10,-0x4(%rbp)
jne    116e <GenPrintInstr1Operand+0x3e>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
mov    -0x18(%rbp),%rcx
mov    -0xc(%rbp),%r8d
mov    -0x18(%rbp),%r9
call   1040 <GenPrintInstr2Operands@plt>
jmp    119d <GenPrintInstr1Operand+0x6d>
mov    -0xc(%rbp),%ecx
mov    $0x80,%edi
mov    $0x81,%eax
cmp    $0x80,%ecx
cmovl  %eax,%edi
mov    -0xc(%rbp),%edx
mov    -0x18(%rbp),%rcx
xor    %esi,%esi
call   1030 <GenPrintInstrOneOperand@plt>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
call   1050 <GenPrintInstrNoOperand@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<GenPrintInstr1Operand>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebx
cmp    $0x10,%edi
jne    1152 <GenPrintInstr1Operand+0x22>
mov    $0x10,%edi
mov    %ebx,%esi
mov    %edx,%r8d
mov    %rcx,%r9
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1040 <GenPrintInstr2Operands@plt>
mov    %edi,%ebp
xor    %edi,%edi
cmp    $0x80,%edx
setl   %dil
or     $0x80,%edi
xor    %esi,%esi
call   1030 <GenPrintInstrOneOperand@plt>
mov    %ebp,%edi
mov    %ebx,%esi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1050 <GenPrintInstrNoOperand@plt>

LLVM IR (-O0):
define void @GenPrintInstr1Operand(i32 %0, i32 %1, i32 %2, i64 %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i64
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i64 %3, i64* %8
%9 = load i32, i32* %5
%10 = icmp eq i32 %9, 16
br i1 %10, label %11, label %19
11: ; preds = %4
%12 = load i32, i32* %5
%13 = load i32, i32* %6
%14 = load i32, i32* %7
%15 = load i64, i64* %8
%16 = load i32, i32* %7
%17 = load i64, i64* %8
%18 = call i32 @GenPrintInstr2Operands(i32 %12, i32 %13, i32 %14, i64 %15, i32 %16, i64 %17)
br label %30
19: ; preds = %4
%20 = load i32, i32* %7
%21 = icmp slt i32 %20, 128
%22 = zext i1 %21 to i64
%23 = select i1 %21, i32 129, i32 128
%24 = load i32, i32* %7
%25 = load i64, i64* %8
%26 = call i32 @GenPrintInstrOneOperand(i32 %23, i32 0, i32 %24, i64 %25)
%27 = load i32, i32* %5
%28 = load i32, i32* %6
%29 = call i32 @GenPrintInstrNoOperand(i32 %27, i32 %28)
br label %30
30: ; preds = %19, %11
ret void
}

LLVM IR (-O2):
define void @GenPrintInstr1Operand(i32 %0, i32 %1, i32 %2, i64 %3) {
%5 = icmp eq i32 %0, 16
br i1 %5, label %6, label %8
6: ; preds = %4
%7 = tail call i32 @GenPrintInstr2Operands(i32 16, i32 %1, i32 %2, i64 %3, i32 %2, i64 %3)
br label %13
8: ; preds = %4
%9 = icmp slt i32 %2, 128
%10 = select i1 %9, i32 129, i32 128
%11 = tail call i32 @GenPrintInstrOneOperand(i32 %10, i32 0, i32 %2, i64 %3)
%12 = tail call i32 @GenPrintInstrNoOperand(i32 %0, i32 %1)
br label %13
13: ; preds = %8, %6
ret void
}