#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 uint32_t;

/* Variables and functions */
int /*<<< orphan*/ ASSERT(int);
bool AESDataWriteNonBlocking(uint32_t ui32Base, uint32_t *pui32Src) {
  ASSERT(ui32Base == 0x44036000);
  if (!(0x00000002 & ((*((volatile uint32_t *)(ui32Base + 0x00000050)))))) {
    return (false);
  }
  (*((volatile uint32_t *)(ui32Base + 0x0000006C))) = pui32Src[0];
  (*((volatile uint32_t *)(ui32Base + 0x00000068))) = pui32Src[1];
  (*((volatile uint32_t *)(ui32Base + 0x00000064))) = pui32Src[2];
  (*((volatile uint32_t *)(ui32Base + 0x00000060))) = pui32Src[3];
  return (true);
}


x86 assembly (clang, -O0):
<AESDataWriteNonBlocking>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x44036000,-0x8(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <ASSERT@plt>
mov    -0x8(%rbp),%eax
add    $0x50,%eax
cltq
mov    (%rax),%eax
and    $0x2,%eax
cmp    $0x0,%eax
jne    1155 <AESDataWriteNonBlocking+0x45>
movl   $0x0,-0x4(%rbp)
jmp    119f <AESDataWriteNonBlocking+0x8f>
mov    -0x10(%rbp),%rax
mov    (%rax),%ecx
mov    -0x8(%rbp),%eax
add    $0x6c,%eax
cltq
mov    %ecx,(%rax)
mov    -0x10(%rbp),%rax
mov    0x4(%rax),%ecx
mov    -0x8(%rbp),%eax
add    $0x68,%eax
cltq
mov    %ecx,(%rax)
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%ecx
mov    -0x8(%rbp),%eax
add    $0x64,%eax
cltq
mov    %ecx,(%rax)
mov    -0x10(%rbp),%rax
mov    0xc(%rax),%ecx
mov    -0x8(%rbp),%eax
add    $0x60,%eax
cltq
mov    %ecx,(%rax)
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<AESDataWriteNonBlocking>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
xor    %edi,%edi
cmp    $0x44036000,%ebp
sete   %dil
call   1030 <ASSERT@plt>
movslq %ebp,%rcx
xor    %eax,%eax
testl  $0x2,0x50(%rcx)
je     1153 <AESDataWriteNonBlocking+0x43>
mov    (%rbx),%eax
mov    %eax,0x6c(%rcx)
mov    0x4(%rbx),%eax
mov    %eax,0x68(%rcx)
mov    0x8(%rbx),%eax
mov    %eax,0x64(%rcx)
mov    0xc(%rbx),%eax
mov    %eax,0x60(%rcx)
mov    $0x1,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @AESDataWriteNonBlocking(i32 %0, i32* %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32*
store i32 %0, i32* %4
store i32* %1, i32** %5
%6 = load i32, i32* %4
%7 = icmp eq i32 %6, 1141071872
%8 = zext i1 %7 to i32
%9 = call i32 @ASSERT(i32 %8)
%10 = load i32, i32* %4
%11 = add nsw i32 %10, 80
%12 = sext i32 %11 to i64
%13 = inttoptr i64 %12 to i32*
%14 = load volatile i32, i32* %13
%15 = and i32 2, %14
%16 = icmp ne i32 %15, 0
br i1 %16, label %18, label %17
17: ; preds = %2
store i32 0, i32* %3
br label %47
18: ; preds = %2
%19 = load i32*, i32** %5
%20 = getelementptr inbounds i32, i32* %19, i64 0
%21 = load i32, i32* %20
%22 = load i32, i32* %4
%23 = add nsw i32 %22, 108
%24 = sext i32 %23 to i64
%25 = inttoptr i64 %24 to i32*
store volatile i32 %21, i32* %25
%26 = load i32*, i32** %5
%27 = getelementptr inbounds i32, i32* %26, i64 1
%28 = load i32, i32* %27
%29 = load i32, i32* %4
%30 = add nsw i32 %29, 104
%31 = sext i32 %30 to i64
%32 = inttoptr i64 %31 to i32*
store volatile i32 %28, i32* %32
%33 = load i32*, i32** %5
%34 = getelementptr inbounds i32, i32* %33, i64 2
%35 = load i32, i32* %34
%36 = load i32, i32* %4
%37 = add nsw i32 %36, 100
%38 = sext i32 %37 to i64
%39 = inttoptr i64 %38 to i32*
store volatile i32 %35, i32* %39
%40 = load i32*, i32** %5
%41 = getelementptr inbounds i32, i32* %40, i64 3
%42 = load i32, i32* %41
%43 = load i32, i32* %4
%44 = add nsw i32 %43, 96
%45 = sext i32 %44 to i64
%46 = inttoptr i64 %45 to i32*
store volatile i32 %42, i32* %46
store i32 1, i32* %3
br label %47
47: ; preds = %18, %17
%48 = load i32, i32* %3
ret i32 %48
}

LLVM IR (-O2):
define i32 @AESDataWriteNonBlocking(i32 %0, i32* nocapture %1) {
%3 = icmp eq i32 %0, 1141071872
%4 = zext i1 %3 to i32
%5 = tail call i32 @ASSERT(i32 %4)
%6 = add nsw i32 %0, 80
%7 = sext i32 %6 to i64
%8 = inttoptr i64 %7 to i32*
%9 = load volatile i32, i32* %8
%10 = and i32 %9, 2
%11 = icmp eq i32 %10, 0
br i1 %11, label %32, label %12
12: ; preds = %2
%13 = load i32, i32* %1
%14 = add nsw i32 %0, 108
%15 = sext i32 %14 to i64
%16 = inttoptr i64 %15 to i32*
store volatile i32 %13, i32* %16
%17 = getelementptr inbounds i32, i32* %1, i64 1
%18 = load i32, i32* %17
%19 = add nsw i32 %0, 104
%20 = sext i32 %19 to i64
%21 = inttoptr i64 %20 to i32*
store volatile i32 %18, i32* %21
%22 = getelementptr inbounds i32, i32* %1, i64 2
%23 = load i32, i32* %22
%24 = add nsw i32 %0, 100
%25 = sext i32 %24 to i64
%26 = inttoptr i64 %25 to i32*
store volatile i32 %23, i32* %26
%27 = getelementptr inbounds i32, i32* %1, i64 3
%28 = load i32, i32* %27
%29 = add nsw i32 %0, 96
%30 = sext i32 %29 to i64
%31 = inttoptr i64 %30 to i32*
store volatile i32 %28, i32* %31
br label %32
32: ; preds = %2, %12
%33 = phi i32 [ 1, %12 ], [ 0, %2 ]
ret i32 %33
}