#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 */
typedef int uint32_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, int, int, int);
int main(int argc, char *argv[]) {
  uint32_t op1;
  uint32_t op2;
  uint32_t i;
  op1 = 0x10001000;
  op2 = 0;
  i = 32;
  for (i = 0; i < 32; ++i) {
    printf("0x%08x,0x%08x,0x%08x\n", op1, op2, op1 * op2);
    op2++;
  }
  op1 = 0x10001000;
  op2 = 0;
  i = 32;
  for (i = 0; i < 32; ++i) {
    printf("%u,%u,%u\n", op1, op2, op1 * op2);
    op2++;
  }
  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   $0x10001000,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
movl   $0x20,-0x1c(%rbp)
movl   $0x0,-0x1c(%rbp)
cmpl   $0x20,-0x1c(%rbp)
jge    117c <main+0x6c>
mov    -0x14(%rbp),%esi
mov    -0x18(%rbp),%edx
mov    -0x14(%rbp),%ecx
imul   -0x18(%rbp),%ecx
lea    0xea0(%rip),%rdi
call   1030 <printf@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1142 <main+0x32>
movl   $0x10001000,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
movl   $0x20,-0x1c(%rbp)
movl   $0x0,-0x1c(%rbp)
cmpl   $0x20,-0x1c(%rbp)
jge    11d2 <main+0xc2>
mov    -0x14(%rbp),%esi
mov    -0x18(%rbp),%edx
mov    -0x14(%rbp),%ecx
imul   -0x18(%rbp),%ecx
lea    0xe60(%rip),%rdi
call   1030 <printf@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1198 <main+0x88>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
xor    %ebx,%ebx
lea    0xee3(%rip),%r14
xor    %ebp,%ebp
nop
mov    %r14,%rdi
mov    $0x10001000,%esi
mov    %ebp,%edx
mov    %ebx,%ecx
call   1030 <printf@plt>
add    $0x1,%ebp
add    $0x10001000,%ebx
cmp    $0x20,%ebp
jne    1120 <main+0x10>
xor    %ebx,%ebx
lea    0xece(%rip),%r14
xor    %ebp,%ebp
nopw   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    $0x10001000,%esi
mov    %ebp,%edx
mov    %ebx,%ecx
call   1030 <printf@plt>
add    $0x1,%ebp
add    $0x10001000,%ebx
cmp    $0x20,%ebp
jne    1150 <main+0x40>
xor    %eax,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@.str = [22 x i8] c"0x%08x,0x%08x,0x%08x\0A\00"
@.str.1 = [10 x i8] c"%u,%u,%u\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 268439552, i32* %6
store i32 0, i32* %7
store i32 32, i32* %8
store i32 0, i32* %8
br label %9
9: ; preds = %21, %2
%10 = load i32, i32* %8
%11 = icmp slt i32 %10, 32
br i1 %11, label %12, label %24
12: ; preds = %9
%13 = load i32, i32* %6
%14 = load i32, i32* %7
%15 = load i32, i32* %6
%16 = load i32, i32* %7
%17 = mul nsw i32 %15, %16
%18 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 %13, i32 %14, i32 %17)
%19 = load i32, i32* %7
%20 = add nsw i32 %19, 1
store i32 %20, i32* %7
br label %21
21: ; preds = %12
%22 = load i32, i32* %8
%23 = add nsw i32 %22, 1
store i32 %23, i32* %8
br label %9
24: ; preds = %9
store i32 268439552, i32* %6
store i32 0, i32* %7
store i32 32, i32* %8
store i32 0, i32* %8
br label %25
25: ; preds = %37, %24
%26 = load i32, i32* %8
%27 = icmp slt i32 %26, 32
br i1 %27, label %28, label %40
28: ; preds = %25
%29 = load i32, i32* %6
%30 = load i32, i32* %7
%31 = load i32, i32* %6
%32 = load i32, i32* %7
%33 = mul nsw i32 %31, %32
%34 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i32 %29, i32 %30, i32 %33)
%35 = load i32, i32* %7
%36 = add nsw i32 %35, 1
store i32 %36, i32* %7
br label %37
37: ; preds = %28
%38 = load i32, i32* %8
%39 = add nsw i32 %38, 1
store i32 %39, i32* %8
br label %25
40: ; preds = %25
ret i32 0
}

LLVM IR (-O2):
@.str = [22 x i8] c"0x%08x,0x%08x,0x%08x\0A\00"
@.str.1 = [10 x i8] c"%u,%u,%u\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
br label %3
3: ; preds = %2, %3
%4 = phi i32 [ 0, %2 ], [ %7, %3 ]
%5 = mul nuw nsw i32 %4, 268439552
%6 = tail call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 268439552, i32 %4, i32 %5)
%7 = add nuw nsw i32 %4, 1
%8 = icmp eq i32 %7, 32
br i1 %8, label %9, label %3
9: ; preds = %3, %9
%10 = phi i32 [ %13, %9 ], [ 0, %3 ]
%11 = mul nuw nsw i32 %10, 268439552
%12 = tail call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0), i32 268439552, i32 %10, i32 %11)
%13 = add nuw nsw i32 %10, 1
%14 = icmp eq i32 %13, 32
br i1 %14, label %15, label %9
15: ; preds = %9
ret i32 0
}