#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_eq(int, int);
int main(int argc, char **argv) {
  int a;
  a = 1;
  a += 101;
  assert_eq(a, 102);
  a = 10;
  a -= 101;
  assert_eq(a, -91);
  a = 10;
  a *= 101;
  assert_eq(a, 1010);
  a = 1;
  a += 3 * 4;
  assert_eq(a, 13);
  a = 1;
  a -= 3 * 4;
  assert_eq(a, -11);
  a = 2;
  a *= 3 * 4;
  assert_eq(a, 24);
  a = 10;
  a /= 5;
  assert_eq(a, 2);
  a = 4;
  a %= 3;
  assert_eq(a, 1);
  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   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0x65,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x66,%esi
call   1030 <assert_eq@plt>
movl   $0xa,-0x14(%rbp)
mov    -0x14(%rbp),%eax
sub    $0x65,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0xffffffa5,%esi
call   1030 <assert_eq@plt>
movl   $0xa,-0x14(%rbp)
imul   $0x65,-0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x3f2,%esi
call   1030 <assert_eq@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
add    $0xc,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0xd,%esi
call   1030 <assert_eq@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
sub    $0xc,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0xfffffff5,%esi
call   1030 <assert_eq@plt>
movl   $0x2,-0x14(%rbp)
imul   $0xc,-0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x18,%esi
call   1030 <assert_eq@plt>
movl   $0xa,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    $0x5,%ecx
cltd
idiv   %ecx
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x2,%esi
call   1030 <assert_eq@plt>
movl   $0x4,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %edx,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x1,%esi
call   1030 <assert_eq@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x66,%edi
mov    $0x66,%esi
call   1030 <assert_eq@plt>
mov    $0xffffffa5,%edi
mov    $0xffffffa5,%esi
call   1030 <assert_eq@plt>
mov    $0x3f2,%edi
mov    $0x3f2,%esi
call   1030 <assert_eq@plt>
mov    $0xd,%edi
mov    $0xd,%esi
call   1030 <assert_eq@plt>
mov    $0xfffffff5,%edi
mov    $0xfffffff5,%esi
call   1030 <assert_eq@plt>
mov    $0x18,%edi
mov    $0x18,%esi
call   1030 <assert_eq@plt>
mov    $0x2,%edi
mov    $0x2,%esi
call   1030 <assert_eq@plt>
mov    $0x1,%edi
mov    $0x1,%esi
call   1030 <assert_eq@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 1, i32* %6
%7 = load i32, i32* %6
%8 = add nsw i32 %7, 101
store i32 %8, i32* %6
%9 = load i32, i32* %6
%10 = call i32 @assert_eq(i32 %9, i32 102)
store i32 10, i32* %6
%11 = load i32, i32* %6
%12 = sub nsw i32 %11, 101
store i32 %12, i32* %6
%13 = load i32, i32* %6
%14 = call i32 @assert_eq(i32 %13, i32 -91)
store i32 10, i32* %6
%15 = load i32, i32* %6
%16 = mul nsw i32 %15, 101
store i32 %16, i32* %6
%17 = load i32, i32* %6
%18 = call i32 @assert_eq(i32 %17, i32 1010)
store i32 1, i32* %6
%19 = load i32, i32* %6
%20 = add nsw i32 %19, 12
store i32 %20, i32* %6
%21 = load i32, i32* %6
%22 = call i32 @assert_eq(i32 %21, i32 13)
store i32 1, i32* %6
%23 = load i32, i32* %6
%24 = sub nsw i32 %23, 12
store i32 %24, i32* %6
%25 = load i32, i32* %6
%26 = call i32 @assert_eq(i32 %25, i32 -11)
store i32 2, i32* %6
%27 = load i32, i32* %6
%28 = mul nsw i32 %27, 12
store i32 %28, i32* %6
%29 = load i32, i32* %6
%30 = call i32 @assert_eq(i32 %29, i32 24)
store i32 10, i32* %6
%31 = load i32, i32* %6
%32 = sdiv i32 %31, 5
store i32 %32, i32* %6
%33 = load i32, i32* %6
%34 = call i32 @assert_eq(i32 %33, i32 2)
store i32 4, i32* %6
%35 = load i32, i32* %6
%36 = srem i32 %35, 3
store i32 %36, i32* %6
%37 = load i32, i32* %6
%38 = call i32 @assert_eq(i32 %37, i32 1)
ret i32 0
}

LLVM IR (-O2):
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @assert_eq(i32 102, i32 102)
%4 = tail call i32 @assert_eq(i32 -91, i32 -91)
%5 = tail call i32 @assert_eq(i32 1010, i32 1010)
%6 = tail call i32 @assert_eq(i32 13, i32 13)
%7 = tail call i32 @assert_eq(i32 -11, i32 -11)
%8 = tail call i32 @assert_eq(i32 24, i32 24)
%9 = tail call i32 @assert_eq(i32 2, i32 2)
%10 = tail call i32 @assert_eq(i32 1, i32 1)
ret i32 0
}