int DistInitCDistList(Schema, A, D)
struct univStruct *Schema;
struct Course **A;
struct Teacher **D;
{
  if (AccessTeacherCDistListFirst(D) == 0)
    return (0);
  else
    (*A) = AccessTeacherCDistListFirst(D);
  return (1);
}


x86 assembly (clang, -O0):
<DistInitCDistList>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    -0x20(%rbp),%rdi
mov    $0x0,%al
call   1030 <AccessTeacherCDistListFirst@plt>
cmp    $0x0,%eax
jne    1144 <DistInitCDistList+0x34>
movl   $0x0,-0x4(%rbp)
jmp    1160 <DistInitCDistList+0x50>
mov    -0x20(%rbp),%rdi
mov    $0x0,%al
call   1030 <AccessTeacherCDistListFirst@plt>
movslq %eax,%rcx
mov    -0x18(%rbp),%rax
mov    %rcx,(%rax)
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<DistInitCDistList>:
push   %rbp
push   %r14
push   %rbx
mov    %rdx,%rbx
mov    %rsi,%r14
xor    %ebp,%ebp
mov    %rdx,%rdi
xor    %eax,%eax
call   1030 <AccessTeacherCDistListFirst@plt>
test   %eax,%eax
je     113e <DistInitCDistList+0x2e>
mov    %rbx,%rdi
xor    %eax,%eax
call   1030 <AccessTeacherCDistListFirst@plt>
cltq
mov    %rax,(%r14)
mov    $0x1,%ebp
mov    %ebp,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
%struct.univStruct = type opaque
%struct.Course = type opaque
%struct.Teacher = type opaque
define i32 @DistInitCDistList(%struct.univStruct* %0, %struct.Course** %1, %struct.Teacher** %2) {
%4 = alloca i32
%5 = alloca %struct.univStruct*
%6 = alloca %struct.Course**
%7 = alloca %struct.Teacher**
store %struct.univStruct* %0, %struct.univStruct** %5
store %struct.Course** %1, %struct.Course*** %6
store %struct.Teacher** %2, %struct.Teacher*** %7
%8 = load %struct.Teacher**, %struct.Teacher*** %7
%9 = call i32 (%struct.Teacher**, ...) bitcast (i32 (...)* @AccessTeacherCDistListFirst to i32 (%struct.Teacher**, ...)*)(%struct.Teacher** %8)
%10 = icmp eq i32 %9, 0
br i1 %10, label %11, label %12
11: ; preds = %3
store i32 0, i32* %4
br label %19
12: ; preds = %3
%13 = load %struct.Teacher**, %struct.Teacher*** %7
%14 = call i32 (%struct.Teacher**, ...) bitcast (i32 (...)* @AccessTeacherCDistListFirst to i32 (%struct.Teacher**, ...)*)(%struct.Teacher** %13)
%15 = sext i32 %14 to i64
%16 = inttoptr i64 %15 to %struct.Course*
%17 = load %struct.Course**, %struct.Course*** %6
store %struct.Course* %16, %struct.Course** %17
br label %18
18: ; preds = %12
store i32 1, i32* %4
br label %19
19: ; preds = %18, %11
%20 = load i32, i32* %4
ret i32 %20
}

LLVM IR (-O2):
%struct.univStruct = type opaque
%struct.Course = type opaque
%struct.Teacher = type opaque
define i32 @DistInitCDistList(%struct.univStruct* nocapture readnone %0, %struct.Course** nocapture writeonly %1, %struct.Teacher** %2) {
%4 = tail call i32 (%struct.Teacher**, ...) bitcast (i32 (...)* @AccessTeacherCDistListFirst to i32 (%struct.Teacher**, ...)*)(%struct.Teacher** %2)
%5 = icmp eq i32 %4, 0
br i1 %5, label %10, label %6
6: ; preds = %3
%7 = tail call i32 (%struct.Teacher**, ...) bitcast (i32 (...)* @AccessTeacherCDistListFirst to i32 (%struct.Teacher**, ...)*)(%struct.Teacher** %2)
%8 = sext i32 %7 to i64
%9 = inttoptr i64 %8 to %struct.Course*
store %struct.Course* %9, %struct.Course** %1
br label %10
10: ; preds = %3, %6
%11 = phi i32 [ 1, %6 ], [ 0, %3 ]
ret i32 %11
}