int main(int argc, char *argv[]) {
  int i = 0;
  int j = 2;
  while (i < argc) {
    printf("i = %d; ", i);
    printf("argv [ %d ] = %s;\n", i, argv[i]);
    i++;
  }
  i = 0;
  while (i < argc) {
    printf("* ( argv + %d ) = %s;\n", i, *(argv + i));
    printf("* ( ( argv + %d ) + %d ) = %c;\n", i, j, *((argv + i) + j));
    i++;
  }
  while (argc > 0) {
    printf("argc = %d;", argc);
    printf(" i = %d;", i);
    printf(" * argv = %s;", *argv);
    printf(" argv [ %d ] = %s;", i, argv[i]);
    printf("\n");
    i++;
    argc--;
    *argv++;
  }
  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)
movl   $0x0,-0x14(%rbp)
movl   $0x2,-0x18(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    117c <main+0x6c>
mov    -0x14(%rbp),%esi
lea    0xeb6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%esi
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdx
lea    0xea2(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1134 <main+0x24>
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11e5 <main+0xd5>
mov    -0x14(%rbp),%esi
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdx
lea    0xe77(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%esi
mov    -0x18(%rbp),%edx
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
shl    $0x3,%rcx
add    %rcx,%rax
movslq -0x18(%rbp),%rcx
mov    (%rax,%rcx,8),%rcx
lea    0xe63(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1183 <main+0x73>
jmp    11ea <main+0xda>
cmpl   $0x0,-0x8(%rbp)
jle    1279 <main+0x169>
mov    -0x8(%rbp),%esi
lea    0xe55(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%esi
lea    0xe4f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xe43(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%esi
mov    -0x10(%rbp),%rax
movslq -0x14(%rbp),%rcx
mov    (%rax,%rcx,8),%rdx
lea    0xe34(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe02(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x8(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %rax,-0x10(%rbp)
jmp    11ea <main+0xda>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
test   %edi,%edi
jle    1242 <main+0x122>
mov    %rsi,%rbx
mov    %edi,%r12d
mov    %edi,%r13d
lea    0xebd(%rip),%r14
lea    0xebf(%rip),%r15
xor    %ebp,%ebp
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    (%rbx,%rbp,8),%rdx
mov    %r15,%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%rbp
cmp    %rbp,%r13
jne    1150 <main+0x30>
test   %r12d,%r12d
jle    1242 <main+0x122>
lea    0xe97(%rip),%r14
lea    0xea7(%rip),%r15
xor    %ebp,%ebp
xchg   %ax,%ax
mov    (%rbx,%rbp,8),%rdx
mov    %r14,%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x10(%rbx,%rbp,8),%rcx
mov    %r15,%rdi
mov    %ebp,%esi
mov    $0x2,%edx
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%rbp
cmp    %rbp,%r13
jne    1190 <main+0x70>
test   %r12d,%r12d
jle    1242 <main+0x122>
lea    (%rbx,%r13,8),%r15
lea    0xe98(%rip),%rbp
lea    0xe9f(%rip),%r13
mov    %r12d,%r14d
nopl   0x0(%rax)
lea    0xe6c(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe66(%rip),%rdi
mov    %r12d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    (%rbx),%rsi
mov    %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    (%r15),%rdx
mov    %r13,%rdi
mov    %r12d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    -0x1(%r14),%eax
add    $0x8,%rbx
add    $0x1,%r12d
add    $0x10,%r15
cmp    $0x1,%r14d
mov    %eax,%r14d
ja     11e0 <main+0xc0>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [9 x i8] c"i = %d; \00"
@.str.1 = [19 x i8] c"argv [ %d ] = %s;\0A\00"
@.str.2 = [23 x i8] c"* ( argv + %d ) = %s;\0A\00"
@.str.3 = [32 x i8] c"* ( ( argv + %d ) + %d ) = %c;\0A\00"
@.str.4 = [11 x i8] c"argc = %d;\00"
@.str.5 = [9 x i8] c" i = %d;\00"
@.str.6 = [14 x i8] c" * argv = %s;\00"
@.str.7 = [19 x i8] c" argv [ %d ] = %s;\00"
@.str.8 = [2 x i8] c"\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %6
store i32 2, i32* %7
br label %8
8: ; preds = %12, %2
%9 = load i32, i32* %6
%10 = load i32, i32* %4
%11 = icmp slt i32 %9, %10
br i1 %11, label %12, label %24
12: ; preds = %8
%13 = load i32, i32* %6
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %13)
%15 = load i32, i32* %6
%16 = load i8**, i8*** %5
%17 = load i32, i32* %6
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds i8*, i8** %16, i64 %18
%20 = load i8*, i8** %19
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0), i32 %15, i8* %20)
%22 = load i32, i32* %6
%23 = add nsw i32 %22, 1
store i32 %23, i32* %6
br label %8
24: ; preds = %8
store i32 0, i32* %6
br label %25
25: ; preds = %29, %24
%26 = load i32, i32* %6
%27 = load i32, i32* %4
%28 = icmp slt i32 %26, %27
br i1 %28, label %29, label %50
29: ; preds = %25
%30 = load i32, i32* %6
%31 = load i8**, i8*** %5
%32 = load i32, i32* %6
%33 = sext i32 %32 to i64
%34 = getelementptr inbounds i8*, i8** %31, i64 %33
%35 = load i8*, i8** %34
%36 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), i32 %30, i8* %35)
%37 = load i32, i32* %6
%38 = load i32, i32* %7
%39 = load i8**, i8*** %5
%40 = load i32, i32* %6
%41 = sext i32 %40 to i64
%42 = getelementptr inbounds i8*, i8** %39, i64 %41
%43 = load i32, i32* %7
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds i8*, i8** %42, i64 %44
%46 = load i8*, i8** %45
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3, i64 0, i64 0), i32 %37, i32 %38, i8* %46)
%48 = load i32, i32* %6
%49 = add nsw i32 %48, 1
store i32 %49, i32* %6
br label %25
50: ; preds = %25
br label %51
51: ; preds = %54, %50
%52 = load i32, i32* %4
%53 = icmp sgt i32 %52, 0
br i1 %53, label %54, label %77
54: ; preds = %51
%55 = load i32, i32* %4
%56 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.4, i64 0, i64 0), i32 %55)
%57 = load i32, i32* %6
%58 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.5, i64 0, i64 0), i32 %57)
%59 = load i8**, i8*** %5
%60 = load i8*, i8** %59
%61 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.6, i64 0, i64 0), i8* %60)
%62 = load i32, i32* %6
%63 = load i8**, i8*** %5
%64 = load i32, i32* %6
%65 = sext i32 %64 to i64
%66 = getelementptr inbounds i8*, i8** %63, i64 %65
%67 = load i8*, i8** %66
%68 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0), i32 %62, i8* %67)
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
%70 = load i32, i32* %6
%71 = add nsw i32 %70, 1
store i32 %71, i32* %6
%72 = load i32, i32* %4
%73 = add nsw i32 %72, -1
store i32 %73, i32* %4
%74 = load i8**, i8*** %5
%75 = getelementptr inbounds i8*, i8** %74, i32 1
store i8** %75, i8*** %5
%76 = load i8*, i8** %74
br label %51
77: ; preds = %51
ret i32 0
}

LLVM IR (-O2):
@.str = [9 x i8] c"i = %d; \00"
@.str.1 = [19 x i8] c"argv [ %d ] = %s;\0A\00"
@.str.2 = [23 x i8] c"* ( argv + %d ) = %s;\0A\00"
@.str.3 = [32 x i8] c"* ( ( argv + %d ) + %d ) = %c;\0A\00"
@.str.4 = [11 x i8] c"argc = %d;\00"
@.str.5 = [9 x i8] c" i = %d;\00"
@.str.6 = [14 x i8] c" * argv = %s;\00"
@.str.7 = [19 x i8] c" argv [ %d ] = %s;\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp sgt i32 %0, 0
br i1 %3, label %4, label %49
4: ; preds = %2
%5 = zext i32 %0 to i64
br label %9
6: ; preds = %9
br i1 %3, label %7, label %49
7: ; preds = %6
%8 = zext i32 %0 to i64
br label %21
9: ; preds = %4, %9
%10 = phi i64 [ 0, %4 ], [ %16, %9 ]
%11 = trunc i64 %10 to i32
%12 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32 %11)
%13 = getelementptr inbounds i8*, i8** %1, i64 %10
%14 = load i8*, i8** %13
%15 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0), i32 %11, i8* %14)
%16 = add nuw nsw i64 %10, 1
%17 = icmp eq i64 %16, %5
br i1 %17, label %6, label %9
18: ; preds = %21
br i1 %3, label %19, label %49
19: ; preds = %18
%20 = zext i32 %0 to i64
br label %32
21: ; preds = %7, %21
%22 = phi i64 [ 0, %7 ], [ %30, %21 ]
%23 = getelementptr inbounds i8*, i8** %1, i64 %22
%24 = load i8*, i8** %23
%25 = trunc i64 %22 to i32
%26 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), i32 %25, i8* %24)
%27 = getelementptr inbounds i8*, i8** %23, i64 2
%28 = load i8*, i8** %27
%29 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @.str.3, i64 0, i64 0), i32 %25, i32 2, i8* %28)
%30 = add nuw nsw i64 %22, 1
%31 = icmp eq i64 %30, %8
br i1 %31, label %18, label %21
32: ; preds = %19, %32
%33 = phi i64 [ %45, %32 ], [ %20, %19 ]
%34 = phi i32 [ %46, %32 ], [ %0, %19 ]
%35 = phi i8** [ %47, %32 ], [ %1, %19 ]
%36 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.4, i64 0, i64 0), i32 %34)
%37 = trunc i64 %33 to i32
%38 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.5, i64 0, i64 0), i32 %37)
%39 = load i8*, i8** %35
%40 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.6, i64 0, i64 0), i8* %39)
%41 = getelementptr inbounds i8*, i8** %35, i64 %33
%42 = load i8*, i8** %41
%43 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0), i32 %37, i8* %42)
%44 = tail call i32 @putchar(i32 10)
%45 = add nuw nsw i64 %33, 1
%46 = add nsw i32 %34, -1
%47 = getelementptr inbounds i8*, i8** %35, i64 1
%48 = icmp ugt i32 %34, 1
br i1 %48, label %32, label %49
49: ; preds = %32, %2, %6, %18
ret i32 0
}