#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*/ f();
int /*<<< orphan*/ g();
int main() {
  long a, b, x, y, t, gcd, lcm;
  a = x;
  b = -1300900;
  a++;
  while (b != 0) {
    t = b;
    g();
    f();
    b = a / b;
    a = t;
  }
  f();
  f();
  gcd = a;
  lcm = (x * y) / (a - b);
  t = a + b + x + y + t;
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
mov    -0x20(%rbp),%rax
mov    %rax,-0x10(%rbp)
movq   $0xffffffffffec265c,-0x18(%rbp)
ff
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     1187 <main+0x67>
mov    -0x18(%rbp),%rax
mov    %rax,-0x30(%rbp)
mov    $0x0,%al
call   1040 <g@plt>
mov    $0x0,%al
call   1030 <f@plt>
mov    -0x10(%rbp),%rax
cqto
idivq  -0x18(%rbp)
mov    %rax,-0x18(%rbp)
mov    -0x30(%rbp),%rax
mov    %rax,-0x10(%rbp)
jmp    114b <main+0x2b>
mov    $0x0,%al
call   1030 <f@plt>
mov    $0x0,%al
call   1030 <f@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x38(%rbp)
mov    -0x20(%rbp),%rax
imul   -0x28(%rbp),%rax
mov    -0x10(%rbp),%rcx
sub    -0x18(%rbp),%rcx
cqto
idiv   %rcx
mov    %rax,-0x40(%rbp)
mov    -0x10(%rbp),%rax
add    -0x18(%rbp),%rax
add    -0x20(%rbp),%rax
add    -0x28(%rbp),%rax
add    -0x30(%rbp),%rax
mov    %rax,-0x30(%rbp)
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1040 <g@plt>
xor    %eax,%eax
call   1030 <f@plt>
xor    %eax,%eax
call   1030 <f@plt>
xor    %eax,%eax
call   1030 <f@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i64
%3 = alloca i64
%4 = alloca i64
%5 = alloca i64
%6 = alloca i64
%7 = alloca i64
%8 = alloca i64
store i32 0, i32* %1
%9 = load i64, i64* %4
store i64 %9, i64* %2
store i64 -1300900, i64* %3
%10 = load i64, i64* %2
%11 = add nsw i64 %10, 1
store i64 %11, i64* %2
br label %12
12: ; preds = %15, %0
%13 = load i64, i64* %3
%14 = icmp ne i64 %13, 0
br i1 %14, label %15, label %23
15: ; preds = %12
%16 = load i64, i64* %3
store i64 %16, i64* %6
%17 = call i32 (...) @g()
%18 = call i32 (...) @f()
%19 = load i64, i64* %2
%20 = load i64, i64* %3
%21 = sdiv i64 %19, %20
store i64 %21, i64* %3
%22 = load i64, i64* %6
store i64 %22, i64* %2
br label %12
23: ; preds = %12
%24 = call i32 (...) @f()
%25 = call i32 (...) @f()
%26 = load i64, i64* %2
store i64 %26, i64* %7
%27 = load i64, i64* %4
%28 = load i64, i64* %5
%29 = mul nsw i64 %27, %28
%30 = load i64, i64* %2
%31 = load i64, i64* %3
%32 = sub nsw i64 %30, %31
%33 = sdiv i64 %29, %32
store i64 %33, i64* %8
%34 = load i64, i64* %2
%35 = load i64, i64* %3
%36 = add nsw i64 %34, %35
%37 = load i64, i64* %4
%38 = add nsw i64 %36, %37
%39 = load i64, i64* %5
%40 = add nsw i64 %38, %39
%41 = load i64, i64* %6
%42 = add nsw i64 %40, %41
store i64 %42, i64* %6
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @g()
%2 = tail call i32 (...) @f()
%3 = tail call i32 (...) @f()
%4 = tail call i32 (...) @f()
ret i32 0
}