#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*/ DEBUG_ASSERT(int);
void SysCtlLDOSet(unsigned long ulVoltage) {
  DEBUG_ASSERT((ulVoltage == 0x00000005) || (ulVoltage == 0x00000004) ||
               (ulVoltage == 0x00000003) || (ulVoltage == 0x00000002) ||
               (ulVoltage == 0x00000001) || (ulVoltage == 0x00000000) ||
               (ulVoltage == 0x0000001f) || (ulVoltage == 0x0000001e) ||
               (ulVoltage == 0x0000001d) || (ulVoltage == 0x0000001c) ||
               (ulVoltage == 0x0000001b));
  (*((volatile unsigned long *)(0x400FE034))) = ulVoltage;
}


x86 assembly (clang, -O0):
<SysCtlLDOSet>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    $0x1,%al
cmpq   $0x5,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x4,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x3,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x2,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x1,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x0,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x1f,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x1e,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x1d,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
mov    $0x1,%al
cmpq   $0x1c,-0x8(%rbp)
mov    %al,-0x9(%rbp)
je     11c7 <SysCtlLDOSet+0xb7>
cmpq   $0x1b,-0x8(%rbp)
sete   %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
and    $0x1,%al
movzbl %al,%edi
call   1030 <DEBUG_ASSERT@plt>
mov    -0x8(%rbp),%rcx
mov    $0x400fe034,%eax
mov    %rcx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SysCtlLDOSet>:
push   %rbx
mov    %rdi,%rbx
cmp    $0x1f,%rdi
ja     1139 <SysCtlLDOSet+0x29>
mov    $0x1,%edi
mov    $0xf000003f,%eax
bt     %rbx,%rax
jae    1139 <SysCtlLDOSet+0x29>
call   1030 <DEBUG_ASSERT@plt>
mov    %rbx,0x400fe034
40
pop    %rbx
ret
xor    %edi,%edi
cmp    $0x1b,%rbx
sete   %dil
jmp    112a <SysCtlLDOSet+0x1a>

LLVM IR (-O0):
define void @SysCtlLDOSet(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp eq i64 %3, 5
br i1 %4, label %35, label %5
5: ; preds = %1
%6 = load i64, i64* %2
%7 = icmp eq i64 %6, 4
br i1 %7, label %35, label %8
8: ; preds = %5
%9 = load i64, i64* %2
%10 = icmp eq i64 %9, 3
br i1 %10, label %35, label %11
11: ; preds = %8
%12 = load i64, i64* %2
%13 = icmp eq i64 %12, 2
br i1 %13, label %35, label %14
14: ; preds = %11
%15 = load i64, i64* %2
%16 = icmp eq i64 %15, 1
br i1 %16, label %35, label %17
17: ; preds = %14
%18 = load i64, i64* %2
%19 = icmp eq i64 %18, 0
br i1 %19, label %35, label %20
20: ; preds = %17
%21 = load i64, i64* %2
%22 = icmp eq i64 %21, 31
br i1 %22, label %35, label %23
23: ; preds = %20
%24 = load i64, i64* %2
%25 = icmp eq i64 %24, 30
br i1 %25, label %35, label %26
26: ; preds = %23
%27 = load i64, i64* %2
%28 = icmp eq i64 %27, 29
br i1 %28, label %35, label %29
29: ; preds = %26
%30 = load i64, i64* %2
%31 = icmp eq i64 %30, 28
br i1 %31, label %35, label %32
32: ; preds = %29
%33 = load i64, i64* %2
%34 = icmp eq i64 %33, 27
br label %35
35: ; preds = %32, %29, %26, %23, %20, %17, %14, %11, %8, %5, %1
%36 = phi i1 [ true, %29 ], [ true, %26 ], [ true, %23 ], [ true, %20 ], [ true, %17 ], [ true, %14 ], [ true, %11 ], [ true, %8 ], [ true, %5 ], [ true, %1 ], [ %34, %32 ]
%37 = zext i1 %36 to i32
%38 = call i32 @DEBUG_ASSERT(i32 %37)
%39 = load i64, i64* %2
store volatile i64 %39, i64* inttoptr (i64 1074782260 to i64*)
ret void
}

LLVM IR (-O2):
define void @SysCtlLDOSet(i64 %0) {
switch i64 %0, label %2 [
i64 31, label %5
i64 30, label %5
i64 29, label %5
i64 28, label %5
i64 5, label %5
i64 4, label %5
i64 3, label %5
i64 2, label %5
i64 1, label %5
i64 0, label %5
]
2: ; preds = %1
%3 = icmp eq i64 %0, 27
%4 = zext i1 %3 to i32
br label %5
5: ; preds = %1, %1, %1, %1, %1, %1, %1, %1, %1, %1, %2
%6 = phi i32 [ 1, %1 ], [ %4, %2 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ], [ 1, %1 ]
%7 = tail call i32 @DEBUG_ASSERT(i32 %6)
store volatile i64 %0, i64* inttoptr (i64 1074782260 to i64*)
ret void
}