#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 re_registers {
  int dummy;
};
struct re_pattern_buffer {
  int dummy;
};

/* Variables and functions */
int re_match_2_internal(struct re_pattern_buffer *, char const *, int,
                        char const *, int, int, struct re_registers *, int);
int re_match_2(struct re_pattern_buffer *bufp, const char *string1,
               const char *string2, int size1, int size2, int pos,
               struct re_registers *regs, int stop) {
  int result = re_match_2_internal(bufp, string1, size1, string2, size2, pos,
                                   regs, stop);
  return result;
}


x86 assembly (clang, -O0):
<re_match_2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
mov    %r8d,-0x20(%rbp)
mov    %r9d,-0x24(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x1c(%rbp),%edx
mov    -0x18(%rbp),%rcx
mov    -0x20(%rbp),%r8d
mov    -0x24(%rbp),%r9d
mov    0x10(%rbp),%r10
mov    0x18(%rbp),%eax
mov    %r10,(%rsp)
mov    %eax,0x8(%rsp)
call   1030 <re_match_2_internal@plt>
mov    %eax,-0x28(%rbp)
mov    -0x28(%rbp),%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<re_match_2>:
mov    %rdx,%rax
mov    %ecx,%edx
mov    %rax,%rcx
jmp    1030 <re_match_2_internal@plt>

LLVM IR (-O0):
%struct.re_pattern_buffer = type { i32 }
%struct.re_registers = type { i32 }
define i32 @re_match_2(%struct.re_pattern_buffer* %0, i8* %1, i8* %2, i32 %3, i32 %4, i32 %5, %struct.re_registers* %6, i32 %7) {
%9 = alloca %struct.re_pattern_buffer*
%10 = alloca i8*
%11 = alloca i8*
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca %struct.re_registers*
%16 = alloca i32
%17 = alloca i32
store %struct.re_pattern_buffer* %0, %struct.re_pattern_buffer** %9
store i8* %1, i8** %10
store i8* %2, i8** %11
store i32 %3, i32* %12
store i32 %4, i32* %13
store i32 %5, i32* %14
store %struct.re_registers* %6, %struct.re_registers** %15
store i32 %7, i32* %16
%18 = load %struct.re_pattern_buffer*, %struct.re_pattern_buffer** %9
%19 = load i8*, i8** %10
%20 = load i32, i32* %12
%21 = load i8*, i8** %11
%22 = load i32, i32* %13
%23 = load i32, i32* %14
%24 = load %struct.re_registers*, %struct.re_registers** %15
%25 = load i32, i32* %16
%26 = call i32 @re_match_2_internal(%struct.re_pattern_buffer* %18, i8* %19, i32 %20, i8* %21, i32 %22, i32 %23, %struct.re_registers* %24, i32 %25)
store i32 %26, i32* %17
%27 = load i32, i32* %17
ret i32 %27
}

LLVM IR (-O2):
%struct.re_pattern_buffer = type { i32 }
%struct.re_registers = type { i32 }
define i32 @re_match_2(%struct.re_pattern_buffer* %0, i8* %1, i8* %2, i32 %3, i32 %4, i32 %5, %struct.re_registers* %6, i32 %7) {
%9 = tail call i32 @re_match_2_internal(%struct.re_pattern_buffer* %0, i8* %1, i32 %3, i8* %2, i32 %4, i32 %5, %struct.re_registers* %6, i32 %7)
ret i32 %9
}