#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 */
typedef int uint8_t;
typedef int uint32_t;

/* Variables and functions */
void USBIntEnableControl(uint32_t ui32Base, uint32_t ui32Flags) {
  ;
  ;
  if (ui32Flags & 0x000000FF) {
    (*((volatile uint8_t *)(ui32Base + 0x0000000B))) |= ui32Flags;
  }
  if (ui32Flags & 0x00000100) {
    (*((volatile uint32_t *)(ui32Base + 0x00000408))) = 0x00000001;
  }
  if (ui32Flags & 0x00000200) {
    (*((volatile uint32_t *)(0x40050000 + 0x00000448))) = 0x00000001;
  }
}


x86 assembly (clang, -O0):
<USBIntEnableControl>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x8(%rbp),%eax
and    $0xff,%eax
cmp    $0x0,%eax
je     112c <USBIntEnableControl+0x2c>
mov    -0x8(%rbp),%edx
mov    -0x4(%rbp),%eax
add    $0xb,%eax
cltq
mov    (%rax),%ecx
or     %edx,%ecx
mov    %ecx,(%rax)
mov    -0x8(%rbp),%eax
and    $0x100,%eax
cmp    $0x0,%eax
je     114d <USBIntEnableControl+0x4d>
mov    -0x4(%rbp),%eax
add    $0x408,%eax
cltq
movl   $0x1,(%rax)
mov    -0x8(%rbp),%eax
and    $0x200,%eax
cmp    $0x0,%eax
je     1169 <USBIntEnableControl+0x69>
mov    $0x40050448,%eax
movl   $0x1,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<USBIntEnableControl>:
movslq %edi,%rax
test   %sil,%sil
je     110b <USBIntEnableControl+0xb>
or     %esi,0xb(%rax)
test   $0x100,%esi
jne    111c <USBIntEnableControl+0x1c>
test   $0x200,%esi
jne    112e <USBIntEnableControl+0x2e>
ret
movl   $0x1,0x408(%rax)
test   $0x200,%esi
je     111b <USBIntEnableControl+0x1b>
movl   $0x1,0x40050448
ret

LLVM IR (-O0):
define void @USBIntEnableControl(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = and i32 %5, 255
%7 = icmp ne i32 %6, 0
br i1 %7, label %8, label %16
8: ; preds = %2
%9 = load i32, i32* %4
%10 = load i32, i32* %3
%11 = add nsw i32 %10, 11
%12 = sext i32 %11 to i64
%13 = inttoptr i64 %12 to i32*
%14 = load volatile i32, i32* %13
%15 = or i32 %14, %9
store volatile i32 %15, i32* %13
br label %16
16: ; preds = %8, %2
%17 = load i32, i32* %4
%18 = and i32 %17, 256
%19 = icmp ne i32 %18, 0
br i1 %19, label %20, label %25
20: ; preds = %16
%21 = load i32, i32* %3
%22 = add nsw i32 %21, 1032
%23 = sext i32 %22 to i64
%24 = inttoptr i64 %23 to i32*
store volatile i32 1, i32* %24
br label %25
25: ; preds = %20, %16
%26 = load i32, i32* %4
%27 = and i32 %26, 512
%28 = icmp ne i32 %27, 0
br i1 %28, label %29, label %30
29: ; preds = %25
store volatile i32 1, i32* inttoptr (i64 1074070600 to i32*)
br label %30
30: ; preds = %29, %25
ret void
}

LLVM IR (-O2):
define void @USBIntEnableControl(i32 %0, i32 %1) {
%3 = and i32 %1, 255
%4 = icmp eq i32 %3, 0
br i1 %4, label %11, label %5
5: ; preds = %2
%6 = add nsw i32 %0, 11
%7 = sext i32 %6 to i64
%8 = inttoptr i64 %7 to i32*
%9 = load volatile i32, i32* %8
%10 = or i32 %9, %1
store volatile i32 %10, i32* %8
br label %11
11: ; preds = %5, %2
%12 = and i32 %1, 256
%13 = icmp eq i32 %12, 0
br i1 %13, label %18, label %14
14: ; preds = %11
%15 = add nsw i32 %0, 1032
%16 = sext i32 %15 to i64
%17 = inttoptr i64 %16 to i32*
store volatile i32 1, i32* %17
br label %18
18: ; preds = %14, %11
%19 = and i32 %1, 512
%20 = icmp eq i32 %19, 0
br i1 %20, label %22, label %21
21: ; preds = %18
store volatile i32 1, i32* inttoptr (i64 1074070600 to i32*)
br label %22
22: ; preds = %21, %18
ret void
}