#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 */

/* Variables and functions */
int EXIT_SUCCESS;
int /*<<< orphan*/ free(char *);
char *make_containSubstring_DFA(char *, char *, int /*<<< orphan*/ *);
int /*<<< orphan*/ printf(char *, char *);
char *strlen(char *);
int main(int argc, char **argv) {
  char *string1 = "ADSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "DDSADASDASDASDSADSADSADASDAS"
                  "CBABACBCBA";
  char *string2 = "CBABACBCBA";
  char *string =
      make_containSubstring_DFA(string2, "ABCDEFGHIJKLMNOPQRSTUVWXYZ", NULL);
  printf("%s\n", string);
  printf("String length: %zu\n", strlen(string));
  free(string);
  return (EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xea3(%rip),%rax
mov    %rax,-0x18(%rbp)
lea    0x10ac(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rdi
lea    0x10a8(%rip),%rsi
xor    %eax,%eax
mov    %eax,%edx
call   1060 <make_containSubstring_DFA@plt>
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rsi
lea    0x10ab(%rip),%rdi
call   1050 <printf@plt>
mov    -0x28(%rbp),%rdi
call   1040 <strlen@plt>
mov    %rax,%rsi
lea    0x1097(%rip),%rdi
call   1050 <printf@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
mov    0x2e24(%rip),%rax
mov    (%rax),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xeb8(%rip),%rdi
lea    0xebc(%rip),%rsi
xor    %edx,%edx
call   1060 <make_containSubstring_DFA@plt>
mov    %rax,%rbx
lea    0xec6(%rip),%rdi
mov    %rax,%rsi
call   1050 <printf@plt>
mov    %rbx,%rdi
call   1040 <strlen@plt>
lea    0xeb3(%rip),%rdi
mov    %rax,%rsi
call   1050 <printf@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    0x2e52(%rip),%rax
mov    (%rax),%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [543 x i8] c"ADSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASDDSADASDASDASDSADSADSADASDASCBABACBCBA\00"
@.str.1 = [11 x i8] c"CBABACBCBA\00"
@.str.2 = [27 x i8] c"ABCDEFGHIJKLMNOPQRSTUVWXYZ\00"
@.str.3 = [4 x i8] c"%s\0A\00"
@.str.4 = [20 x i8] c"String length: %zu\0A\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i8*
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i8* getelementptr inbounds ([543 x i8], [543 x i8]* @.str, i64 0, i64 0), i8** %6
store i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8** %7
%9 = load i8*, i8** %7
%10 = call i8* @make_containSubstring_DFA(i8* %9, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.2, i64 0, i64 0), i32* null)
store i8* %10, i8** %8
%11 = load i8*, i8** %8
%12 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), i8* %11)
%13 = load i8*, i8** %8
%14 = call i8* @strlen(i8* %13)
%15 = call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* %14)
%16 = load i8*, i8** %8
%17 = call i32 @free(i8* %16)
%18 = load i32, i32* @EXIT_SUCCESS
ret i32 %18
}

LLVM IR (-O2):
@.str.1 = [11 x i8] c"CBABACBCBA\00"
@.str.2 = [27 x i8] c"ABCDEFGHIJKLMNOPQRSTUVWXYZ\00"
@.str.3 = [4 x i8] c"%s\0A\00"
@.str.4 = [20 x i8] c"String length: %zu\0A\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i8* @make_containSubstring_DFA(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.2, i64 0, i64 0), i32* null)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), i8* %3)
%5 = tail call i8* @strlen(i8* %3)
%6 = tail call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* %5)
%7 = tail call i32 @free(i8* %3)
%8 = load i32, i32* @EXIT_SUCCESS
ret i32 %8
}