#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*/ displayStateAs16bitLanes(int, char const *, void *);
int /*<<< orphan*/ displayStateAs32bitLanes(int, char const *, void *);
int /*<<< orphan*/ displayStateAs64bitLanes(int, char const *, void *);
int /*<<< orphan*/ displayStateAs8bitLanes(int, char const *, void *);
void displayStateAsLanes(int level, const char *text, void *statePointer,
                         unsigned int width) {
  if (width == 1600)
    displayStateAs64bitLanes(level, text, statePointer);
  if (width == 800)
    displayStateAs32bitLanes(level, text, statePointer);
  if (width == 400)
    displayStateAs16bitLanes(level, text, statePointer);
  if (width == 200)
    displayStateAs8bitLanes(level, text, statePointer);
}


x86 assembly (clang, -O0):
<displayStateAsLanes>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
cmpl   $0x640,-0x1c(%rbp)
jne    1173 <displayStateAsLanes+0x33>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1040 <displayStateAs64bitLanes@plt>
cmpl   $0x320,-0x1c(%rbp)
jne    1190 <displayStateAsLanes+0x50>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1030 <displayStateAs32bitLanes@plt>
cmpl   $0x190,-0x1c(%rbp)
jne    11ad <displayStateAsLanes+0x6d>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1060 <displayStateAs16bitLanes@plt>
cmpl   $0xc8,-0x1c(%rbp)
jne    11ca <displayStateAsLanes+0x8a>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1050 <displayStateAs8bitLanes@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<displayStateAsLanes>:
cmp    $0x31f,%ecx
jg     115d <displayStateAsLanes+0x1d>
cmp    $0xc8,%ecx
je     1173 <displayStateAsLanes+0x33>
cmp    $0x190,%ecx
jne    1172 <displayStateAsLanes+0x32>
jmp    1060 <displayStateAs16bitLanes@plt>
cmp    $0x320,%ecx
je     1178 <displayStateAsLanes+0x38>
cmp    $0x640,%ecx
jne    1172 <displayStateAsLanes+0x32>
jmp    1040 <displayStateAs64bitLanes@plt>
ret
jmp    1050 <displayStateAs8bitLanes@plt>
jmp    1030 <displayStateAs32bitLanes@plt>

LLVM IR (-O0):
define void @displayStateAsLanes(i32 %0, i8* %1, i8* %2, i32 %3) {
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32
store i32 %0, i32* %5
store i8* %1, i8** %6
store i8* %2, i8** %7
store i32 %3, i32* %8
%9 = load i32, i32* %8
%10 = icmp eq i32 %9, 1600
br i1 %10, label %11, label %16
11: ; preds = %4
%12 = load i32, i32* %5
%13 = load i8*, i8** %6
%14 = load i8*, i8** %7
%15 = call i32 @displayStateAs64bitLanes(i32 %12, i8* %13, i8* %14)
br label %16
16: ; preds = %11, %4
%17 = load i32, i32* %8
%18 = icmp eq i32 %17, 800
br i1 %18, label %19, label %24
19: ; preds = %16
%20 = load i32, i32* %5
%21 = load i8*, i8** %6
%22 = load i8*, i8** %7
%23 = call i32 @displayStateAs32bitLanes(i32 %20, i8* %21, i8* %22)
br label %24
24: ; preds = %19, %16
%25 = load i32, i32* %8
%26 = icmp eq i32 %25, 400
br i1 %26, label %27, label %32
27: ; preds = %24
%28 = load i32, i32* %5
%29 = load i8*, i8** %6
%30 = load i8*, i8** %7
%31 = call i32 @displayStateAs16bitLanes(i32 %28, i8* %29, i8* %30)
br label %32
32: ; preds = %27, %24
%33 = load i32, i32* %8
%34 = icmp eq i32 %33, 200
br i1 %34, label %35, label %40
35: ; preds = %32
%36 = load i32, i32* %5
%37 = load i8*, i8** %6
%38 = load i8*, i8** %7
%39 = call i32 @displayStateAs8bitLanes(i32 %36, i8* %37, i8* %38)
br label %40
40: ; preds = %35, %32
ret void
}

LLVM IR (-O2):
define void @displayStateAsLanes(i32 %0, i8* %1, i8* %2, i32 %3) {
switch i32 %3, label %13 [
i32 1600, label %5
i32 800, label %7
i32 400, label %9
i32 200, label %11
]
5: ; preds = %4
%6 = tail call i32 @displayStateAs64bitLanes(i32 %0, i8* %1, i8* %2)
br label %13
7: ; preds = %4
%8 = tail call i32 @displayStateAs32bitLanes(i32 %0, i8* %1, i8* %2)
br label %13
9: ; preds = %4
%10 = tail call i32 @displayStateAs16bitLanes(i32 %0, i8* %1, i8* %2)
br label %13
11: ; preds = %4
%12 = tail call i32 @displayStateAs8bitLanes(i32 %0, i8* %1, i8* %2)
br label %13
13: ; preds = %9, %7, %5, %4, %11
ret void
}