#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 */
struct Cyc_Absyn_Exp {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ Cyc_Evexp_same_const_exp(struct Cyc_Absyn_Exp *,
                                            struct Cyc_Absyn_Exp *);
int Cyc_Unify_unify_const_exp_opt(struct Cyc_Absyn_Exp *e1,
                                  struct Cyc_Absyn_Exp *e2) {
  if (e1 == 0 && e2 == 0)
    return 1;
  if (e1 == 0 || e2 == 0)
    return 0;
  return ({ Cyc_Evexp_same_const_exp(e1, e2); });
}


x86 assembly (clang, -O0):
<Cyc_Unify_unify_const_exp_opt>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1142 <Cyc_Unify_unify_const_exp_opt+0x32>
cmpq   $0x0,-0x18(%rbp)
jne    1142 <Cyc_Unify_unify_const_exp_opt+0x32>
movl   $0x1,-0x4(%rbp)
jmp    117a <Cyc_Unify_unify_const_exp_opt+0x6a>
cmpq   $0x0,-0x10(%rbp)
je     1158 <Cyc_Unify_unify_const_exp_opt+0x48>
cmpq   $0x0,-0x18(%rbp)
jne    1164 <Cyc_Unify_unify_const_exp_opt+0x54>
movl   $0x0,-0x4(%rbp)
jmp    117a <Cyc_Unify_unify_const_exp_opt+0x6a>
mov    -0x10(%rbp),%rdi
mov    -0x18(%rbp),%rsi
call   1030 <Cyc_Evexp_same_const_exp@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Cyc_Unify_unify_const_exp_opt>:
mov    $0x1,%eax
mov    %rdi,%rcx
or     %rsi,%rcx
je     112e <Cyc_Unify_unify_const_exp_opt+0x1e>
xor    %eax,%eax
test   %rdi,%rdi
je     112e <Cyc_Unify_unify_const_exp_opt+0x1e>
test   %rsi,%rsi
je     112e <Cyc_Unify_unify_const_exp_opt+0x1e>
jmp    1030 <Cyc_Evexp_same_const_exp@plt>
ret

LLVM IR (-O0):
%struct.Cyc_Absyn_Exp = type { i32 }
define i32 @Cyc_Unify_unify_const_exp_opt(%struct.Cyc_Absyn_Exp* %0, %struct.Cyc_Absyn_Exp* %1) {
%3 = alloca i32
%4 = alloca %struct.Cyc_Absyn_Exp*
%5 = alloca %struct.Cyc_Absyn_Exp*
%6 = alloca i32
store %struct.Cyc_Absyn_Exp* %0, %struct.Cyc_Absyn_Exp** %4
store %struct.Cyc_Absyn_Exp* %1, %struct.Cyc_Absyn_Exp** %5
%7 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %4
%8 = icmp eq %struct.Cyc_Absyn_Exp* %7, null
br i1 %8, label %9, label %13
9: ; preds = %2
%10 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %5
%11 = icmp eq %struct.Cyc_Absyn_Exp* %10, null
br i1 %11, label %12, label %13
12: ; preds = %9
store i32 1, i32* %3
br label %25
13: ; preds = %9, %2
%14 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %4
%15 = icmp eq %struct.Cyc_Absyn_Exp* %14, null
br i1 %15, label %19, label %16
16: ; preds = %13
%17 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %5
%18 = icmp eq %struct.Cyc_Absyn_Exp* %17, null
br i1 %18, label %19, label %20
19: ; preds = %16, %13
store i32 0, i32* %3
br label %25
20: ; preds = %16
%21 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %4
%22 = load %struct.Cyc_Absyn_Exp*, %struct.Cyc_Absyn_Exp** %5
%23 = call i32 @Cyc_Evexp_same_const_exp(%struct.Cyc_Absyn_Exp* %21, %struct.Cyc_Absyn_Exp* %22)
store i32 %23, i32* %6
%24 = load i32, i32* %6
store i32 %24, i32* %3
br label %25
25: ; preds = %20, %19, %12
%26 = load i32, i32* %3
ret i32 %26
}

LLVM IR (-O2):
%struct.Cyc_Absyn_Exp = type { i32 }
define i32 @Cyc_Unify_unify_const_exp_opt(%struct.Cyc_Absyn_Exp* %0, %struct.Cyc_Absyn_Exp* %1) {
%3 = icmp eq %struct.Cyc_Absyn_Exp* %0, null
%4 = icmp eq %struct.Cyc_Absyn_Exp* %1, null
%5 = and i1 %3, %4
br i1 %5, label %10, label %6
6: ; preds = %2
%7 = or i1 %3, %4
br i1 %7, label %10, label %8
8: ; preds = %6
%9 = tail call i32 @Cyc_Evexp_same_const_exp(%struct.Cyc_Absyn_Exp* %0, %struct.Cyc_Absyn_Exp* %1)
br label %10
10: ; preds = %6, %2, %8
%11 = phi i32 [ %9, %8 ], [ 1, %2 ], [ 0, %6 ]
ret i32 %11
}