#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_search_2_stub(struct re_pattern_buffer *, char const *, int,
                     char const *, int, int, int /*<<< orphan*/,
                     struct re_registers *, int, int);
int re_match_2(struct re_pattern_buffer *bufp, const char *string1, int length1,
               const char *string2, int length2, int start,
               struct re_registers *regs, int stop) {
  return re_search_2_stub(bufp, string1, length1, string2, length2, start, 0,
                          regs, stop, 1);
}


x86 assembly (clang, -O0):
<re_match_2>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%rax
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8d,-0x24(%rbp)
mov    %r9d,-0x28(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x14(%rbp),%edx
mov    -0x20(%rbp),%rcx
mov    -0x24(%rbp),%r8d
mov    -0x28(%rbp),%r9d
mov    0x10(%rbp),%r10
mov    0x18(%rbp),%eax
xor    %r11d,%r11d
movl   $0x0,(%rsp)
mov    %r10,0x8(%rsp)
mov    %eax,0x10(%rsp)
movl   $0x1,0x18(%rsp)
call   1030 <re_search_2_stub@plt>
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<re_match_2>:
push   %rax
mov    0x18(%rsp),%eax
push   $0x1
push   %rax
push   0x20(%rsp)
push   $0x0
call   1030 <re_search_2_stub@plt>
add    $0x20,%rsp
pop    %rcx
ret

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, i32 %2, i8* %3, i32 %4, i32 %5, %struct.re_registers* %6, i32 %7) {
%9 = alloca %struct.re_pattern_buffer*
%10 = alloca i8*
%11 = alloca i32
%12 = alloca i8*
%13 = alloca i32
%14 = alloca i32
%15 = alloca %struct.re_registers*
%16 = alloca i32
store %struct.re_pattern_buffer* %0, %struct.re_pattern_buffer** %9
store i8* %1, i8** %10
store i32 %2, i32* %11
store i8* %3, i8** %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
%17 = load %struct.re_pattern_buffer*, %struct.re_pattern_buffer** %9
%18 = load i8*, i8** %10
%19 = load i32, i32* %11
%20 = load i8*, i8** %12
%21 = load i32, i32* %13
%22 = load i32, i32* %14
%23 = load %struct.re_registers*, %struct.re_registers** %15
%24 = load i32, i32* %16
%25 = call i32 @re_search_2_stub(%struct.re_pattern_buffer* %17, i8* %18, i32 %19, i8* %20, i32 %21, i32 %22, i32 0, %struct.re_registers* %23, i32 %24, i32 1)
ret i32 %25
}

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, i32 %2, i8* %3, i32 %4, i32 %5, %struct.re_registers* %6, i32 %7) {
%9 = tail call i32 @re_search_2_stub(%struct.re_pattern_buffer* %0, i8* %1, i32 %2, i8* %3, i32 %4, i32 %5, i32 0, %struct.re_registers* %6, i32 %7, i32 1)
ret i32 %9
}