#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 get32le();
char get8();
int dds_test(void) {
  if (get8() != 'D')
    return 0;
  if (get8() != 'D')
    return 0;
  if (get8() != 'S')
    return 0;
  if (get8() != ' ')
    return 0;
  if (get32le() != 124)
    return 0;
  return 1;
}


x86 assembly (clang, -O0):
<dds_test>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    $0x0,%al
call   1030 <get8@plt>
movsbl %al,%eax
cmp    $0x44,%eax
je     1147 <dds_test+0x27>
movl   $0x0,-0x4(%rbp)
jmp    11c7 <dds_test+0xa7>
mov    $0x0,%al
call   1030 <get8@plt>
movsbl %al,%eax
cmp    $0x44,%eax
je     1166 <dds_test+0x46>
movl   $0x0,-0x4(%rbp)
jmp    11c7 <dds_test+0xa7>
mov    $0x0,%al
call   1030 <get8@plt>
movsbl %al,%eax
cmp    $0x53,%eax
je     1185 <dds_test+0x65>
movl   $0x0,-0x4(%rbp)
jmp    11c7 <dds_test+0xa7>
mov    $0x0,%al
call   1030 <get8@plt>
movsbl %al,%eax
cmp    $0x20,%eax
je     11a4 <dds_test+0x84>
movl   $0x0,-0x4(%rbp)
jmp    11c7 <dds_test+0xa7>
mov    $0x0,%al
call   1040 <get32le@plt>
cmp    $0x7c,%eax
je     11c0 <dds_test+0xa0>
movl   $0x0,-0x4(%rbp)
jmp    11c7 <dds_test+0xa7>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dds_test>:
push   %rbx
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <get8@plt>
cmp    $0x44,%al
jne    1164 <dds_test+0x44>
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <get8@plt>
cmp    $0x44,%al
jne    1164 <dds_test+0x44>
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <get8@plt>
cmp    $0x53,%al
jne    1164 <dds_test+0x44>
xor    %ebx,%ebx
xor    %eax,%eax
call   1030 <get8@plt>
cmp    $0x20,%al
jne    1164 <dds_test+0x44>
xor    %eax,%eax
call   1040 <get32le@plt>
xor    %ebx,%ebx
cmp    $0x7c,%eax
sete   %bl
mov    %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
define i32 @dds_test() {
%1 = alloca i32
%2 = call signext i8 (...) @get8()
%3 = sext i8 %2 to i32
%4 = icmp ne i32 %3, 68
br i1 %4, label %5, label %6
5: ; preds = %0
store i32 0, i32* %1
br label %26
6: ; preds = %0
%7 = call signext i8 (...) @get8()
%8 = sext i8 %7 to i32
%9 = icmp ne i32 %8, 68
br i1 %9, label %10, label %11
10: ; preds = %6
store i32 0, i32* %1
br label %26
11: ; preds = %6
%12 = call signext i8 (...) @get8()
%13 = sext i8 %12 to i32
%14 = icmp ne i32 %13, 83
br i1 %14, label %15, label %16
15: ; preds = %11
store i32 0, i32* %1
br label %26
16: ; preds = %11
%17 = call signext i8 (...) @get8()
%18 = sext i8 %17 to i32
%19 = icmp ne i32 %18, 32
br i1 %19, label %20, label %21
20: ; preds = %16
store i32 0, i32* %1
br label %26
21: ; preds = %16
%22 = call i32 (...) @get32le()
%23 = icmp ne i32 %22, 124
br i1 %23, label %24, label %25
24: ; preds = %21
store i32 0, i32* %1
br label %26
25: ; preds = %21
store i32 1, i32* %1
br label %26
26: ; preds = %25, %24, %20, %15, %10, %5
%27 = load i32, i32* %1
ret i32 %27
}

LLVM IR (-O2):
define i32 @dds_test() {
%1 = tail call signext i8 (...) @get8()
%2 = icmp eq i8 %1, 68
br i1 %2, label %3, label %16
3: ; preds = %0
%4 = tail call signext i8 (...) @get8()
%5 = icmp eq i8 %4, 68
br i1 %5, label %6, label %16
6: ; preds = %3
%7 = tail call signext i8 (...) @get8()
%8 = icmp eq i8 %7, 83
br i1 %8, label %9, label %16
9: ; preds = %6
%10 = tail call signext i8 (...) @get8()
%11 = icmp eq i8 %10, 32
br i1 %11, label %12, label %16
12: ; preds = %9
%13 = tail call i32 (...) @get32le()
%14 = icmp eq i32 %13, 124
%15 = zext i1 %14 to i32
br label %16
16: ; preds = %12, %9, %6, %3, %0
%17 = phi i32 [ 0, %0 ], [ 0, %3 ], [ 0, %6 ], [ 0, %9 ], [ %15, %12 ]
ret i32 %17
}