#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 /*<<< orphan*/);
int /*<<< orphan*/ printf(char *);
int main(int argc, char *argv[]) {
  do {
    assert(((argc > 0)) && ("assertion failed in ASSUME"));
  } while (0);
  do {
    assert(((argv[argc] == NULL)) && ("assertion failed in ASSUME"));
  } while (0);
  printf("Hello world!\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
xor    %eax,%eax
cmpl   $0x0,-0x8(%rbp)
mov    %al,-0x11(%rbp)
jle    114f <main+0x2f>
mov    $0x1,%al
mov    %al,-0x11(%rbp)
jmp    114f <main+0x2f>
mov    -0x11(%rbp),%al
and    $0x1,%al
movzbl %al,%edi
call   1040 <assert@plt>
jmp    1161 <main+0x41>
mov    -0x10(%rbp),%rcx
movslq -0x8(%rbp),%rdx
xor    %eax,%eax
cmpq   $0x0,(%rcx,%rdx,8)
mov    %al,-0x12(%rbp)
jne    1183 <main+0x63>
mov    $0x1,%al
mov    %al,-0x12(%rbp)
jmp    1183 <main+0x63>
mov    -0x12(%rbp),%al
and    $0x1,%al
movzbl %al,%edi
call   1040 <assert@plt>
lea    0xe84(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %edi,%ebp
xor    %edi,%edi
test   %ebp,%ebp
setg   %dil
call   1040 <assert@plt>
movslq %ebp,%rax
xor    %edi,%edi
cmpq   $0x0,(%rbx,%rax,8)
sete   %dil
call   1040 <assert@plt>
lea    0xeb1(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [27 x i8] c"assertion failed in ASSUME\00"
@.str.1 = [14 x i8] c"Hello world!\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
br label %6
6: ; preds = %2
%7 = load i32, i32* %4
%8 = icmp sgt i32 %7, 0
br i1 %8, label %9, label %10
9: ; preds = %6
br label %10
10: ; preds = %9, %6
%11 = phi i1 [ false, %6 ], [ true, %9 ]
%12 = zext i1 %11 to i32
%13 = call i32 @assert(i32 %12)
br label %14
14: ; preds = %10
br label %15
15: ; preds = %14
%16 = load i8**, i8*** %5
%17 = load i32, i32* %4
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds i8*, i8** %16, i64 %18
%20 = load i8*, i8** %19
%21 = icmp eq i8* %20, null
br i1 %21, label %22, label %23
22: ; preds = %15
br label %23
23: ; preds = %22, %15
%24 = phi i1 [ false, %15 ], [ true, %22 ]
%25 = zext i1 %24 to i32
%26 = call i32 @assert(i32 %25)
br label %27
27: ; preds = %23
%28 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@str = [13 x i8] c"Hello world!\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp sgt i32 %0, 0
%4 = zext i1 %3 to i32
%5 = tail call i32 @assert(i32 %4)
%6 = sext i32 %0 to i64
%7 = getelementptr inbounds i8*, i8** %1, i64 %6
%8 = load i8*, i8** %7
%9 = icmp eq i8* %8, null
%10 = zext i1 %9 to i32
%11 = tail call i32 @assert(i32 %10)
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
ret i32 0
}