#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 object {
  int dummy;
};
struct expr {
  int dummy;
};
struct binary_expr {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ binary_expr_init(struct binary_expr *, struct expr *,
                                    struct expr *, char);
int /*<<< orphan*/ concat_expr_class_get();
struct object *object_new(int /*<<< orphan*/);
struct expr *concat_expr_new(struct expr *left, struct expr *right) {
  struct object *expr = object_new(concat_expr_class_get());
  binary_expr_init(((struct binary_expr *)(expr)), left, right, '.');
  return ((struct expr *)(expr));
}


x86 assembly (clang, -O0):
<concat_expr_new>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1040 <concat_expr_class_get@plt>
mov    %eax,%edi
call   1030 <object_new@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    $0x2e,%ecx
call   1050 <binary_expr_init@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<concat_expr_new>:
push   %r15
push   %r14
push   %rbx
mov    %rsi,%r14
mov    %rdi,%r15
xor    %eax,%eax
call   1040 <concat_expr_class_get@plt>
mov    %eax,%edi
call   1030 <object_new@plt>
mov    %rax,%rbx
mov    %rax,%rdi
mov    %r15,%rsi
mov    %r14,%rdx
mov    $0x2e,%ecx
call   1050 <binary_expr_init@plt>
mov    %rbx,%rax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
%struct.expr = type { i32 }
%struct.object = type { i32 }
%struct.binary_expr = type { i32 }
define %struct.expr* @concat_expr_new(%struct.expr* %0, %struct.expr* %1) {
%3 = alloca %struct.expr*
%4 = alloca %struct.expr*
%5 = alloca %struct.object*
store %struct.expr* %0, %struct.expr** %3
store %struct.expr* %1, %struct.expr** %4
%6 = call i32 (...) @concat_expr_class_get()
%7 = call %struct.object* @object_new(i32 %6)
store %struct.object* %7, %struct.object** %5
%8 = load %struct.object*, %struct.object** %5
%9 = bitcast %struct.object* %8 to %struct.binary_expr*
%10 = load %struct.expr*, %struct.expr** %3
%11 = load %struct.expr*, %struct.expr** %4
%12 = call i32 @binary_expr_init(%struct.binary_expr* %9, %struct.expr* %10, %struct.expr* %11, i8 signext 46)
%13 = load %struct.object*, %struct.object** %5
%14 = bitcast %struct.object* %13 to %struct.expr*
ret %struct.expr* %14
}

LLVM IR (-O2):
%struct.expr = type { i32 }
%struct.object = type { i32 }
%struct.binary_expr = type { i32 }
define %struct.expr* @concat_expr_new(%struct.expr* %0, %struct.expr* %1) {
%3 = tail call i32 (...) @concat_expr_class_get()
%4 = tail call %struct.object* @object_new(i32 %3)
%5 = bitcast %struct.object* %4 to %struct.binary_expr*
%6 = tail call i32 @binary_expr_init(%struct.binary_expr* %5, %struct.expr* %0, %struct.expr* %1, i8 signext 46)
%7 = bitcast %struct.object* %4 to %struct.expr*
ret %struct.expr* %7
}