#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*/ diagnostics(int /*<<< orphan*/, char *, char *);
char *getBraceParam();
int /*<<< orphan*/ *newHarvardCite(char *, char *, char *, char *);
void CmdAuxHarvardCite(int code) {
  char *key = getBraceParam();
  char *full = getBraceParam();
  char *abbr = getBraceParam();
  char *year = getBraceParam();
  if (NULL == newHarvardCite(key, full, abbr, year)) {
    diagnostics(0, "Memory overflow defining \\harvardcite(%s)", key);
  }
}


x86 assembly (clang, -O0):
<CmdAuxHarvardCite>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x0,%al
call   1030 <getBraceParam@plt>
mov    %rax,-0x10(%rbp)
mov    $0x0,%al
call   1030 <getBraceParam@plt>
mov    %rax,-0x18(%rbp)
mov    $0x0,%al
call   1030 <getBraceParam@plt>
mov    %rax,-0x20(%rbp)
mov    $0x0,%al
call   1030 <getBraceParam@plt>
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x20(%rbp),%rdx
mov    -0x28(%rbp),%rcx
call   1050 <newHarvardCite@plt>
mov    %rax,%rcx
xor    %eax,%eax
cmp    %rcx,%rax
jne    119c <CmdAuxHarvardCite+0x6c>
mov    -0x10(%rbp),%rdx
xor    %edi,%edi
lea    0xe69(%rip),%rsi
call   1040 <diagnostics@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<CmdAuxHarvardCite>:
push   %r15
push   %r14
push   %rbx
xor    %eax,%eax
call   1030 <getBraceParam@plt>
mov    %rax,%r14
xor    %eax,%eax
call   1030 <getBraceParam@plt>
mov    %rax,%r15
xor    %eax,%eax
call   1030 <getBraceParam@plt>
mov    %rax,%rbx
xor    %eax,%eax
call   1030 <getBraceParam@plt>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %rbx,%rdx
mov    %rax,%rcx
call   1050 <newHarvardCite@plt>
test   %rax,%rax
je     1176 <CmdAuxHarvardCite+0x46>
pop    %rbx
pop    %r14
pop    %r15
ret
lea    0xe83(%rip),%rsi
xor    %edi,%edi
mov    %r14,%rdx
pop    %rbx
pop    %r14
pop    %r15
jmp    1040 <diagnostics@plt>

LLVM IR (-O0):
@.str = [42 x i8] c"Memory overflow defining \\harvardcite(%s)\00"
define void @CmdAuxHarvardCite(i32 %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i8*
store i32 %0, i32* %2
%7 = call i8* (...) @getBraceParam()
store i8* %7, i8** %3
%8 = call i8* (...) @getBraceParam()
store i8* %8, i8** %4
%9 = call i8* (...) @getBraceParam()
store i8* %9, i8** %5
%10 = call i8* (...) @getBraceParam()
store i8* %10, i8** %6
%11 = load i8*, i8** %3
%12 = load i8*, i8** %4
%13 = load i8*, i8** %5
%14 = load i8*, i8** %6
%15 = call i32* @newHarvardCite(i8* %11, i8* %12, i8* %13, i8* %14)
%16 = icmp eq i32* null, %15
br i1 %16, label %17, label %20
17: ; preds = %1
%18 = load i8*, i8** %3
%19 = call i32 @diagnostics(i32 0, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str, i64 0, i64 0), i8* %18)
br label %20
20: ; preds = %17, %1
ret void
}

LLVM IR (-O2):
@.str = [42 x i8] c"Memory overflow defining \\harvardcite(%s)\00"
define void @CmdAuxHarvardCite(i32 %0) {
%2 = tail call i8* (...) @getBraceParam()
%3 = tail call i8* (...) @getBraceParam()
%4 = tail call i8* (...) @getBraceParam()
%5 = tail call i8* (...) @getBraceParam()
%6 = tail call i32* @newHarvardCite(i8* %2, i8* %3, i8* %4, i8* %5)
%7 = icmp eq i32* %6, null
br i1 %7, label %8, label %10
8: ; preds = %1
%9 = tail call i32 @diagnostics(i32 0, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str, i64 0, i64 0), i8* %2)
br label %10
10: ; preds = %8, %1
ret void
}