#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 /*<<< orphan*/ assert(int);
int is_subsequence(char *, char *);
int main() {
  assert(is_subsequence("a", "ab"));
  assert(!is_subsequence("c", "ab"));
  assert(is_subsequence("abc", "axbxcxxxx"));
  assert(!is_subsequence("abcd", "abc"));
  assert(is_subsequence("", "abcd"));
  assert(is_subsequence("abcd", "ABCD"));
  assert(!is_subsequence("aBcd", "AbCD"));
  assert(is_subsequence("aBcd", "ABCD"));
  assert(is_subsequence("olálá", "olálá"));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    0xec5(%rip),%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xeb7(%rip),%rdi
lea    0xeab(%rip),%rsi
call   1040 <is_subsequence@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
lea    0xe90(%rip),%rdi
lea    0xe8d(%rip),%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe84(%rip),%rdi
lea    0xe6f(%rip),%rsi
call   1040 <is_subsequence@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
lea    0xe68(%rip),%rdi
lea    0xe58(%rip),%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe45(%rip),%rdi
lea    0xe43(%rip),%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe35(%rip),%rdi
lea    0xe33(%rip),%rsi
call   1040 <is_subsequence@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
lea    0xe10(%rip),%rdi
lea    0xe04(%rip),%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe00(%rip),%rsi
mov    %rsi,%rdi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %rbx
lea    0xed4(%rip),%rdi
lea    0xecf(%rip),%rbx
mov    %rbx,%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xebe(%rip),%rdi
mov    %rbx,%rsi
call   1040 <is_subsequence@plt>
xor    %edi,%edi
test   %eax,%eax
sete   %dil
call   1030 <assert@plt>
lea    0xea0(%rip),%rbx
lea    0xe9d(%rip),%rsi
mov    %rbx,%rdi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe91(%rip),%r14
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <is_subsequence@plt>
xor    %edi,%edi
test   %eax,%eax
sete   %dil
call   1030 <assert@plt>
lea    0xe7b(%rip),%rdi
mov    %r14,%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe61(%rip),%r15
mov    %r14,%rdi
mov    %r15,%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe4d(%rip),%rbx
lea    0xe4b(%rip),%rsi
mov    %rbx,%rdi
call   1040 <is_subsequence@plt>
xor    %edi,%edi
test   %eax,%eax
sete   %dil
call   1030 <assert@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
lea    0xe22(%rip),%rdi
mov    %rdi,%rsi
call   1040 <is_subsequence@plt>
mov    %eax,%edi
call   1030 <assert@plt>
xor    %eax,%eax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [2 x i8] c"a\00"
@.str.1 = [3 x i8] c"ab\00"
@.str.2 = [2 x i8] c"c\00"
@.str.3 = [4 x i8] c"abc\00"
@.str.4 = [10 x i8] c"axbxcxxxx\00"
@.str.5 = [5 x i8] c"abcd\00"
@.str.6 = [1 x i8] zeroinitializer
@.str.7 = [5 x i8] c"ABCD\00"
@.str.8 = [5 x i8] c"aBcd\00"
@.str.9 = [5 x i8] c"AbCD\00"
@.str.10 = [8 x i8] c"ol\C3\A1l\C3\A1\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @is_subsequence(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @assert(i32 %2)
%4 = call i32 @is_subsequence(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%5 = icmp ne i32 %4, 0
%6 = xor i1 %5, true
%7 = zext i1 %6 to i32
%8 = call i32 @assert(i32 %7)
%9 = call i32 @is_subsequence(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0))
%10 = call i32 @assert(i32 %9)
%11 = call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%12 = icmp ne i32 %11, 0
%13 = xor i1 %12, true
%14 = zext i1 %13 to i32
%15 = call i32 @assert(i32 %14)
%16 = call i32 @is_subsequence(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%17 = call i32 @assert(i32 %16)
%18 = call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.7, i64 0, i64 0))
%19 = call i32 @assert(i32 %18)
%20 = call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%21 = icmp ne i32 %20, 0
%22 = xor i1 %21, true
%23 = zext i1 %22 to i32
%24 = call i32 @assert(i32 %23)
%25 = call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.7, i64 0, i64 0))
%26 = call i32 @assert(i32 %25)
%27 = call i32 @is_subsequence(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0))
%28 = call i32 @assert(i32 %27)
ret i32 0
}

LLVM IR (-O2):
@.str = [2 x i8] c"a\00"
@.str.1 = [3 x i8] c"ab\00"
@.str.2 = [2 x i8] c"c\00"
@.str.3 = [4 x i8] c"abc\00"
@.str.4 = [10 x i8] c"axbxcxxxx\00"
@.str.5 = [5 x i8] c"abcd\00"
@.str.6 = [1 x i8] zeroinitializer
@.str.7 = [5 x i8] c"ABCD\00"
@.str.8 = [5 x i8] c"aBcd\00"
@.str.9 = [5 x i8] c"AbCD\00"
@.str.10 = [8 x i8] c"ol\C3\A1l\C3\A1\00"
define i32 @main() {
%1 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 @assert(i32 %1)
%3 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%4 = icmp eq i32 %3, 0
%5 = zext i1 %4 to i32
%6 = tail call i32 @assert(i32 %5)
%7 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0))
%8 = tail call i32 @assert(i32 %7)
%9 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%10 = icmp eq i32 %9, 0
%11 = zext i1 %10 to i32
%12 = tail call i32 @assert(i32 %11)
%13 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%14 = tail call i32 @assert(i32 %13)
%15 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.7, i64 0, i64 0))
%16 = tail call i32 @assert(i32 %15)
%17 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%18 = icmp eq i32 %17, 0
%19 = zext i1 %18 to i32
%20 = tail call i32 @assert(i32 %19)
%21 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.7, i64 0, i64 0))
%22 = tail call i32 @assert(i32 %21)
%23 = tail call i32 @is_subsequence(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0))
%24 = tail call i32 @assert(i32 %23)
ret i32 0
}