#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 */
uint32_t xor160() {
  static uint32_t x = 123456789, y = 362436069, z = 521288629, w = 88675123,
                  v = 5783321;
  uint32_t t = (x ^ (x << 2));
  x = y;
  y = z;
  z = w;
  w = v;
  return v = (v ^ (v >> 4)) ^ (t ^ (t >> 1));
}


x86 assembly (clang, -O0):
<xor160>:
push   %rbp
mov    %rsp,%rbp
mov    0x2f16(%rip),%eax
mov    0x2f10(%rip),%ecx
shl    $0x2,%ecx
xor    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    0x2f06(%rip),%eax
mov    %eax,0x2efc(%rip)
mov    0x2efe(%rip),%eax
mov    %eax,0x2ef4(%rip)
mov    0x2ef6(%rip),%eax
mov    %eax,0x2eec(%rip)
mov    0x2eee(%rip),%eax
mov    %eax,0x2ee4(%rip)
mov    0x2ee2(%rip),%eax
mov    0x2edc(%rip),%ecx
sar    $0x4,%ecx
xor    %ecx,%eax
mov    -0x4(%rbp),%ecx
mov    -0x4(%rbp),%edx
sar    $0x1,%edx
xor    %edx,%ecx
xor    %ecx,%eax
mov    %eax,0x2ec4(%rip)
pop    %rbp
ret

x86 assembly (clang, -O2):
<xor160>:
mov    0x2f1a(%rip),%ecx
lea    0x0(,%rcx,4),%eax
xor    %ecx,%eax
mov    0x2f0f(%rip),%ecx
mov    %ecx,0x2f05(%rip)
mov    0x2f07(%rip),%ecx
mov    %ecx,0x2efd(%rip)
mov    0x2eff(%rip),%ecx
mov    %ecx,0x2ef5(%rip)
mov    0x2ef7(%rip),%ecx
mov    %ecx,0x2eed(%rip)
mov    %eax,%edx
sar    %edx
xor    %ecx,%eax
sar    $0x4,%ecx
xor    %edx,%eax
xor    %ecx,%eax
mov    %eax,0x2ede(%rip)
ret

LLVM IR (-O0):
@xor160.x = internal global i32 123456789
@xor160.y = internal global i32 362436069
@xor160.z = internal global i32 521288629
@xor160.w = internal global i32 88675123
@xor160.v = internal global i32 5783321
define i32 @xor160() {
%1 = alloca i32
%2 = load i32, i32* @xor160.x
%3 = load i32, i32* @xor160.x
%4 = shl i32 %3, 2
%5 = xor i32 %2, %4
store i32 %5, i32* %1
%6 = load i32, i32* @xor160.y
store i32 %6, i32* @xor160.x
%7 = load i32, i32* @xor160.z
store i32 %7, i32* @xor160.y
%8 = load i32, i32* @xor160.w
store i32 %8, i32* @xor160.z
%9 = load i32, i32* @xor160.v
store i32 %9, i32* @xor160.w
%10 = load i32, i32* @xor160.v
%11 = load i32, i32* @xor160.v
%12 = ashr i32 %11, 4
%13 = xor i32 %10, %12
%14 = load i32, i32* %1
%15 = load i32, i32* %1
%16 = ashr i32 %15, 1
%17 = xor i32 %14, %16
%18 = xor i32 %13, %17
store i32 %18, i32* @xor160.v
ret i32 %18
}

LLVM IR (-O2):
@xor160.x = internal unnamed_addr global i32 123456789
@xor160.y = internal unnamed_addr global i32 362436069
@xor160.z = internal unnamed_addr global i32 521288629
@xor160.w = internal unnamed_addr global i32 88675123
@xor160.v = internal unnamed_addr global i32 5783321
define i32 @xor160() {
%1 = load i32, i32* @xor160.x
%2 = shl i32 %1, 2
%3 = xor i32 %2, %1
%4 = load i32, i32* @xor160.y
store i32 %4, i32* @xor160.x
%5 = load i32, i32* @xor160.z
store i32 %5, i32* @xor160.y
%6 = load i32, i32* @xor160.w
store i32 %6, i32* @xor160.z
%7 = load i32, i32* @xor160.v
store i32 %7, i32* @xor160.w
%8 = ashr i32 %7, 4
%9 = ashr i32 %3, 1
%10 = xor i32 %9, %3
%11 = xor i32 %10, %7
%12 = xor i32 %11, %8
store i32 %12, i32* @xor160.v
ret i32 %12
}