#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*/ AssertFailure(char *, int);
void SysCtlGPIOAHBEnable(unsigned long ulGPIOPeripheral) {
  {
    if (!((ulGPIOPeripheral == 0x20000001) ||
          (ulGPIOPeripheral == 0x20000002) ||
          (ulGPIOPeripheral == 0x20000004) ||
          (ulGPIOPeripheral == 0x20000008) ||
          (ulGPIOPeripheral == 0x20000010) ||
          (ulGPIOPeripheral == 0x20000020) ||
          (ulGPIOPeripheral == 0x20000040) ||
          (ulGPIOPeripheral == 0x20000080) ||
          (ulGPIOPeripheral == 0x20000100))) {
      AssertFailure(
          "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
          "2022-01-22/02-19-57/repos/AmesianX/OpenBLT/refs/heads/master/Target/"
          "Demo/ARMCM3_LM3S_EK_LM3S6965_Crossworks/Boot/lib/driverlib/sysctl.c",
          2869);
    }
  };
  (*((volatile unsigned long *)(0x400FE06C))) |= ulGPIOPeripheral & 0xFFFF;
}


x86 assembly (clang, -O0):
<SysCtlGPIOAHBEnable>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x20000001,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000002,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000004,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000008,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000010,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000020,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000040,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000080,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
cmpq   $0x20000100,-0x8(%rbp)
20
je     11ab <SysCtlGPIOAHBEnable+0x9b>
lea    0xe5f(%rip),%rdi
mov    $0xb35,%esi
call   1030 <AssertFailure@plt>
mov    -0x8(%rbp),%rax
and    $0xffff,%rax
mov    $0x400fe06c,%ecx
mov    (%rcx),%rcx
or     %rax,%rcx
mov    $0x400fe06c,%eax
mov    %rcx,(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<SysCtlGPIOAHBEnable>:
push   %rbx
mov    %rdi,%rbx
lea    -0x20000001(%rdi),%rax
cmp    $0x3f,%rax
ja     113e <SysCtlGPIOAHBEnable+0x2e>
movabs $0x800000008000808b,%rcx
bt     %rax,%rcx
jae    113e <SysCtlGPIOAHBEnable+0x2e>
movzwl %bx,%eax
or     %rax,0x400fe06c
40
pop    %rbx
ret
cmp    $0x20000080,%rbx
je     1131 <SysCtlGPIOAHBEnable+0x21>
cmp    $0x20000100,%rbx
je     1131 <SysCtlGPIOAHBEnable+0x21>
lea    0xea9(%rip),%rdi
mov    $0xb35,%esi
call   1030 <AssertFailure@plt>
jmp    1131 <SysCtlGPIOAHBEnable+0x21>

LLVM IR (-O0):
@.str = [200 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AmesianX/OpenBLT/refs/heads/master/Target/Demo/ARMCM3_LM3S_EK_LM3S6965_Crossworks/Boot/lib/driverlib/sysctl.c\00"
define void @SysCtlGPIOAHBEnable(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp eq i64 %3, 536870913
br i1 %4, label %31, label %5
5: ; preds = %1
%6 = load i64, i64* %2
%7 = icmp eq i64 %6, 536870914
br i1 %7, label %31, label %8
8: ; preds = %5
%9 = load i64, i64* %2
%10 = icmp eq i64 %9, 536870916
br i1 %10, label %31, label %11
11: ; preds = %8
%12 = load i64, i64* %2
%13 = icmp eq i64 %12, 536870920
br i1 %13, label %31, label %14
14: ; preds = %11
%15 = load i64, i64* %2
%16 = icmp eq i64 %15, 536870928
br i1 %16, label %31, label %17
17: ; preds = %14
%18 = load i64, i64* %2
%19 = icmp eq i64 %18, 536870944
br i1 %19, label %31, label %20
20: ; preds = %17
%21 = load i64, i64* %2
%22 = icmp eq i64 %21, 536870976
br i1 %22, label %31, label %23
23: ; preds = %20
%24 = load i64, i64* %2
%25 = icmp eq i64 %24, 536871040
br i1 %25, label %31, label %26
26: ; preds = %23
%27 = load i64, i64* %2
%28 = icmp eq i64 %27, 536871168
br i1 %28, label %31, label %29
29: ; preds = %26
%30 = call i32 @AssertFailure(i8* getelementptr inbounds ([200 x i8], [200 x i8]* @.str, i64 0, i64 0), i32 2869)
br label %31
31: ; preds = %29, %26, %23, %20, %17, %14, %11, %8, %5, %1
%32 = load i64, i64* %2
%33 = and i64 %32, 65535
%34 = load volatile i64, i64* inttoptr (i64 1074782316 to i64*)
%35 = or i64 %34, %33
store volatile i64 %35, i64* inttoptr (i64 1074782316 to i64*)
ret void
}

LLVM IR (-O2):
@.str = [200 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AmesianX/OpenBLT/refs/heads/master/Target/Demo/ARMCM3_LM3S_EK_LM3S6965_Crossworks/Boot/lib/driverlib/sysctl.c\00"
define void @SysCtlGPIOAHBEnable(i64 %0) {
switch i64 %0, label %2 [
i64 536871168, label %4
i64 536871040, label %4
i64 536870976, label %4
i64 536870944, label %4
i64 536870928, label %4
i64 536870920, label %4
i64 536870916, label %4
i64 536870914, label %4
i64 536870913, label %4
]
2: ; preds = %1
%3 = tail call i32 @AssertFailure(i8* getelementptr inbounds ([200 x i8], [200 x i8]* @.str, i64 0, i64 0), i32 2869)
br label %4
4: ; preds = %1, %1, %1, %1, %1, %1, %1, %1, %1, %2
%5 = and i64 %0, 65535
%6 = load volatile i64, i64* inttoptr (i64 1074782316 to i64*)
%7 = or i64 %6, %5
store volatile i64 %7, i64* inttoptr (i64 1074782316 to i64*)
ret void
}