#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 hash_int_impl(uint32_t a) {
  a = (a + 0x7ed55d16) + (a << 12);
  a = (a ^ 0xc761c23c) ^ (a >> 19);
  a = (a + 0x165667b1) + (a << 5);
  a = (a + 0xd3a2646c) ^ (a << 9);
  a = (a + 0xfd7046c5) + (a << 3);
  a = (a ^ 0xb55a4f09) ^ (a >> 16);
  return a;
}


x86 assembly (clang, -O0):
<hash_int_impl>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x7ed55d16,%eax
mov    -0x4(%rbp),%ecx
shl    $0xc,%ecx
add    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
xor    $0xc761c23c,%eax
mov    -0x4(%rbp),%ecx
sar    $0x13,%ecx
xor    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x165667b1,%eax
mov    -0x4(%rbp),%ecx
shl    $0x5,%ecx
add    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xd3a2646c,%eax
mov    -0x4(%rbp),%ecx
shl    $0x9,%ecx
xor    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xfd7046c5,%eax
mov    -0x4(%rbp),%ecx
shl    $0x3,%ecx
add    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
xor    $0xb55a4f09,%eax
mov    -0x4(%rbp),%ecx
sar    $0x10,%ecx
xor    %ecx,%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<hash_int_impl>:
mov    %edi,%eax
shl    $0xc,%eax
add    %edi,%eax
add    $0x7ed55d16,%eax
mov    %eax,%ecx
sar    $0x13,%ecx
xor    %eax,%ecx
xor    $0xc761c23c,%ecx
mov    %ecx,%eax
shl    $0x5,%eax
lea    (%rcx,%rax,1),%edx
shl    $0x9,%edx
add    %ecx,%eax
add    $0xe9f8cc1d,%eax
add    $0xaccf6200,%edx
xor    %eax,%edx
lea    (%rdx,%rdx,8),%ecx
add    $0xfd7046c5,%ecx
mov    %ecx,%eax
sar    $0x10,%eax
xor    %ecx,%eax
xor    $0xb55a4f09,%eax
ret

LLVM IR (-O0):
define i32 @hash_int_impl(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = add nsw i32 %3, 2127912214
%5 = load i32, i32* %2
%6 = shl i32 %5, 12
%7 = add nsw i32 %4, %6
store i32 %7, i32* %2
%8 = load i32, i32* %2
%9 = xor i32 %8, -949894596
%10 = load i32, i32* %2
%11 = ashr i32 %10, 19
%12 = xor i32 %9, %11
store i32 %12, i32* %2
%13 = load i32, i32* %2
%14 = add nsw i32 %13, 374761393
%15 = load i32, i32* %2
%16 = shl i32 %15, 5
%17 = add nsw i32 %14, %16
store i32 %17, i32* %2
%18 = load i32, i32* %2
%19 = add i32 %18, -744332180
%20 = load i32, i32* %2
%21 = shl i32 %20, 9
%22 = xor i32 %19, %21
store i32 %22, i32* %2
%23 = load i32, i32* %2
%24 = add i32 %23, -42973499
%25 = load i32, i32* %2
%26 = shl i32 %25, 3
%27 = add i32 %24, %26
store i32 %27, i32* %2
%28 = load i32, i32* %2
%29 = xor i32 %28, -1252372727
%30 = load i32, i32* %2
%31 = ashr i32 %30, 16
%32 = xor i32 %29, %31
store i32 %32, i32* %2
%33 = load i32, i32* %2
ret i32 %33
}

LLVM IR (-O2):
define i32 @hash_int_impl(i32 %0) {
%2 = add nsw i32 %0, 2127912214
%3 = shl i32 %0, 12
%4 = add nsw i32 %2, %3
%5 = ashr i32 %4, 19
%6 = xor i32 %4, %5
%7 = xor i32 %6, -949894596
%8 = add nsw i32 %7, 374761393
%9 = shl i32 %7, 5
%10 = add nsw i32 %8, %9
%11 = add i32 %10, -744332180
%12 = shl i32 %10, 9
%13 = xor i32 %11, %12
%14 = add i32 %13, -42973499
%15 = shl i32 %13, 3
%16 = add i32 %14, %15
%17 = ashr i32 %16, 16
%18 = xor i32 %16, %17
%19 = xor i32 %18, -1252372727
ret i32 %19
}