void IntPendClear(unsigned long ulInterrupt) {
  ;
  if (ulInterrupt == 14) {
    (*((volatile unsigned long *)(0xE000ED04))) |= 0x08000000;
  } else if (ulInterrupt == 15) {
    (*((volatile unsigned long *)(0xE000ED04))) |= 0x02000000;
  } else if ((ulInterrupt >= 16) && (ulInterrupt <= 47)) {
    (*((volatile unsigned long *)(0xE000E280))) = 1 << (ulInterrupt - 16);
  } else if ((ulInterrupt >= 48) && (ulInterrupt <= 79)) {
    (*((volatile unsigned long *)(0xE000E284))) = 1 << (ulInterrupt - 48);
  } else if (ulInterrupt >= 80) {
    (*((volatile unsigned long *)(0xE000E288))) = 1 << (ulInterrupt - 80);
  }
}


x86 assembly (clang, -O0):
<IntPendClear>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
cmpq   $0xe,-0x8(%rbp)
jne    112f <IntPendClear+0x2f>
mov    $0xe000ed04,%eax
mov    (%rax),%rcx
or     $0x8000000,%rcx
mov    $0xe000ed04,%eax
mov    %rcx,(%rax)
jmp    11ff <IntPendClear+0xff>
cmpq   $0xf,-0x8(%rbp)
jne    1156 <IntPendClear+0x56>
mov    $0xe000ed04,%eax
mov    (%rax),%rcx
or     $0x2000000,%rcx
mov    $0xe000ed04,%eax
mov    %rcx,(%rax)
jmp    11fa <IntPendClear+0xfa>
cmpq   $0x10,-0x8(%rbp)
jb     118d <IntPendClear+0x8d>
cmpq   $0x2f,-0x8(%rbp)
ja     118d <IntPendClear+0x8d>
mov    -0x8(%rbp),%rax
sub    $0x10,%rax
mov    %eax,%ecx
mov    $0x1,%eax
shl    %cl,%eax
movslq %eax,%rcx
mov    $0xe000e280,%eax
mov    %rcx,(%rax)
jmp    11f5 <IntPendClear+0xf5>
cmpq   $0x30,-0x8(%rbp)
jb     11c4 <IntPendClear+0xc4>
cmpq   $0x4f,-0x8(%rbp)
ja     11c4 <IntPendClear+0xc4>
mov    -0x8(%rbp),%rax
sub    $0x30,%rax
mov    %eax,%ecx
mov    $0x1,%eax
shl    %cl,%eax
movslq %eax,%rcx
mov    $0xe000e284,%eax
mov    %rcx,(%rax)
jmp    11f0 <IntPendClear+0xf0>
cmpq   $0x50,-0x8(%rbp)
jb     11eb <IntPendClear+0xeb>
mov    -0x8(%rbp),%rax
sub    $0x50,%rax
mov    %eax,%ecx
mov    $0x1,%eax
shl    %cl,%eax
movslq %eax,%rcx
mov    $0xe000e288,%eax
mov    %rcx,(%rax)
jmp    11f0 <IntPendClear+0xf0>
jmp    11f5 <IntPendClear+0xf5>
jmp    11fa <IntPendClear+0xfa>
jmp    11ff <IntPendClear+0xff>
pop    %rbp
ret

x86 assembly (clang, -O2):
<IntPendClear>:
cmp    $0xf,%rdi
je     1119 <IntPendClear+0x19>
cmp    $0xe,%rdi
jne    1126 <IntPendClear+0x26>
mov    $0xe000ed04,%eax
orq    $0x8000000,(%rax)
ret
mov    $0xe000ed04,%eax
orq    $0x2000000,(%rax)
ret
lea    -0x10(%rdi),%rax
cmp    $0x1f,%rax
ja     114c <IntPendClear+0x4c>
add    $0xf0,%dil
mov    $0x1,%eax
mov    %edi,%ecx
shl    %cl,%eax
cltq
mov    $0xe000ed04,%ecx
mov    %rax,-0xa84(%rcx)
ret
lea    -0x30(%rdi),%rax
cmp    $0x1f,%rax
ja     1172 <IntPendClear+0x72>
add    $0xd0,%dil
mov    $0x1,%eax
mov    %edi,%ecx
shl    %cl,%eax
cltq
mov    $0xe000ed04,%ecx
mov    %rax,-0xa80(%rcx)
ret
cmp    $0x50,%rdi
jb     1193 <IntPendClear+0x93>
add    $0xb0,%dil
mov    $0x1,%eax
mov    %edi,%ecx
shl    %cl,%eax
cltq
mov    $0xe000ed04,%ecx
mov    %rax,-0xa7c(%rcx)
ret

LLVM IR (-O0):
define void @IntPendClear(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp eq i64 %3, 14
br i1 %4, label %5, label %8
5: ; preds = %1
%6 = load volatile i64, i64* inttoptr (i64 3758157060 to i64*)
%7 = or i64 %6, 134217728
store volatile i64 %7, i64* inttoptr (i64 3758157060 to i64*)
br label %51
8: ; preds = %1
%9 = load i64, i64* %2
%10 = icmp eq i64 %9, 15
br i1 %10, label %11, label %14
11: ; preds = %8
%12 = load volatile i64, i64* inttoptr (i64 3758157060 to i64*)
%13 = or i64 %12, 33554432
store volatile i64 %13, i64* inttoptr (i64 3758157060 to i64*)
br label %50
14: ; preds = %8
%15 = load i64, i64* %2
%16 = icmp uge i64 %15, 16
br i1 %16, label %17, label %26
17: ; preds = %14
%18 = load i64, i64* %2
%19 = icmp ule i64 %18, 47
br i1 %19, label %20, label %26
20: ; preds = %17
%21 = load i64, i64* %2
%22 = sub i64 %21, 16
%23 = trunc i64 %22 to i32
%24 = shl i32 1, %23
%25 = sext i32 %24 to i64
store volatile i64 %25, i64* inttoptr (i64 3758154368 to i64*)
br label %49
26: ; preds = %17, %14
%27 = load i64, i64* %2
%28 = icmp uge i64 %27, 48
br i1 %28, label %29, label %38
29: ; preds = %26
%30 = load i64, i64* %2
%31 = icmp ule i64 %30, 79
br i1 %31, label %32, label %38
32: ; preds = %29
%33 = load i64, i64* %2
%34 = sub i64 %33, 48
%35 = trunc i64 %34 to i32
%36 = shl i32 1, %35
%37 = sext i32 %36 to i64
store volatile i64 %37, i64* inttoptr (i64 3758154372 to i64*)
br label %48
38: ; preds = %29, %26
%39 = load i64, i64* %2
%40 = icmp uge i64 %39, 80
br i1 %40, label %41, label %47
41: ; preds = %38
%42 = load i64, i64* %2
%43 = sub i64 %42, 80
%44 = trunc i64 %43 to i32
%45 = shl i32 1, %44
%46 = sext i32 %45 to i64
store volatile i64 %46, i64* inttoptr (i64 3758154376 to i64*)
br label %47
47: ; preds = %41, %38
br label %48
48: ; preds = %47, %32
br label %49
49: ; preds = %48, %20
br label %50
50: ; preds = %49, %11
br label %51
51: ; preds = %50, %5
ret void
}

LLVM IR (-O2):
define void @IntPendClear(i64 %0) {
switch i64 %0, label %8 [
i64 14, label %2
i64 15, label %5
]
2: ; preds = %1
%3 = load volatile i64, i64* inttoptr (i64 3758157060 to i64*)
%4 = or i64 %3, 134217728
store volatile i64 %4, i64* inttoptr (i64 3758157060 to i64*)
br label %31
5: ; preds = %1
%6 = load volatile i64, i64* inttoptr (i64 3758157060 to i64*)
%7 = or i64 %6, 33554432
store volatile i64 %7, i64* inttoptr (i64 3758157060 to i64*)
br label %31
8: ; preds = %1
%9 = add i64 %0, -16
%10 = icmp ult i64 %9, 32
br i1 %10, label %11, label %16
11: ; preds = %8
%12 = trunc i64 %0 to i32
%13 = add nsw i32 %12, -16
%14 = shl nuw i32 1, %13
%15 = sext i32 %14 to i64
store volatile i64 %15, i64* inttoptr (i64 3758154368 to i64*)
br label %31
16: ; preds = %8
%17 = add i64 %0, -48
%18 = icmp ult i64 %17, 32
br i1 %18, label %19, label %24
19: ; preds = %16
%20 = trunc i64 %0 to i32
%21 = add nsw i32 %20, -48
%22 = shl nuw i32 1, %21
%23 = sext i32 %22 to i64
store volatile i64 %23, i64* inttoptr (i64 3758154372 to i64*)
br label %31
24: ; preds = %16
%25 = icmp ugt i64 %0, 79
br i1 %25, label %26, label %31
26: ; preds = %24
%27 = trunc i64 %0 to i32
%28 = add i32 %27, -80
%29 = shl nuw i32 1, %28
%30 = sext i32 %29 to i64
store volatile i64 %30, i64* inttoptr (i64 3758154376 to i64*)
br label %31
31: ; preds = %5, %19, %26, %24, %11, %2
ret void
}