#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 /*<<< orphan*/ value;
typedef int /*<<< orphan*/ uint64_t;
typedef uintptr_t uint32_t;

/* Variables and functions */
int UINT32_MAX;
int htole64(int /*<<< orphan*/);
int /*<<< orphan*/ rgph_murmur32_finalise(int, uintptr_t *);
int /*<<< orphan*/ rgph_murmur32_mix0(int, uintptr_t *);
int /*<<< orphan*/ rgph_murmur32_mix1(int, uintptr_t *);
void rgph_u32x4_murmur32v_u64(uint64_t value, uintptr_t seed, uint32_t *h) {
  h[0] = h[1] = h[2] = h[3] = seed;
  rgph_murmur32_mix1(htole64(value) >> 32, h);
  rgph_murmur32_mix0(htole64(value) & UINT32_MAX, h);
  rgph_murmur32_finalise(sizeof(value), h);
}


x86 assembly (clang, -O0):
<rgph_u32x4_murmur32v_u64>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x10(%rbp),%rcx
mov    -0x18(%rbp),%rax
mov    %rcx,0x18(%rax)
mov    -0x18(%rbp),%rax
mov    %rcx,0x10(%rax)
mov    -0x18(%rbp),%rax
mov    %rcx,0x8(%rax)
mov    -0x18(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x4(%rbp),%edi
call   1060 <htole64@plt>
mov    %eax,%edi
mov    $0x20,%ecx
sar    %cl,%edi
mov    -0x18(%rbp),%rsi
call   1040 <rgph_murmur32_mix1@plt>
mov    -0x4(%rbp),%edi
call   1060 <htole64@plt>
mov    %eax,%edi
mov    0x2e57(%rip),%rax
and    (%rax),%edi
mov    -0x18(%rbp),%rsi
call   1050 <rgph_murmur32_mix0@plt>
mov    -0x18(%rbp),%rsi
mov    $0x4,%edi
call   1030 <rgph_murmur32_finalise@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<rgph_u32x4_murmur32v_u64>:
push   %rbp
push   %rbx
push   %rax
mov    %rdx,%rbx
mov    %edi,%ebp
mov    %rsi,0x18(%rdx)
mov    %rsi,0x10(%rdx)
mov    %rsi,0x8(%rdx)
mov    %rsi,(%rdx)
call   1060 <htole64@plt>
mov    %rbx,%rsi
call   1040 <rgph_murmur32_mix1@plt>
mov    %ebp,%edi
call   1060 <htole64@plt>
mov    0x2e86(%rip),%rcx
and    (%rcx),%eax
mov    %eax,%edi
mov    %rbx,%rsi
call   1050 <rgph_murmur32_mix0@plt>
mov    $0x4,%edi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <rgph_murmur32_finalise@plt>

LLVM IR (-O0):
@UINT32_MAX = global i32 0
define void @rgph_u32x4_murmur32v_u64(i32 %0, i64 %1, i64* %2) {
%4 = alloca i32
%5 = alloca i64
%6 = alloca i64*
store i32 %0, i32* %4
store i64 %1, i64* %5
store i64* %2, i64** %6
%7 = load i64, i64* %5
%8 = load i64*, i64** %6
%9 = getelementptr inbounds i64, i64* %8, i64 3
store i64 %7, i64* %9
%10 = load i64*, i64** %6
%11 = getelementptr inbounds i64, i64* %10, i64 2
store i64 %7, i64* %11
%12 = load i64*, i64** %6
%13 = getelementptr inbounds i64, i64* %12, i64 1
store i64 %7, i64* %13
%14 = load i64*, i64** %6
%15 = getelementptr inbounds i64, i64* %14, i64 0
store i64 %7, i64* %15
%16 = load i32, i32* %4
%17 = call i32 @htole64(i32 %16)
%18 = ashr i32 %17, 32
%19 = load i64*, i64** %6
%20 = call i32 @rgph_murmur32_mix1(i32 %18, i64* %19)
%21 = load i32, i32* %4
%22 = call i32 @htole64(i32 %21)
%23 = load i32, i32* @UINT32_MAX
%24 = and i32 %22, %23
%25 = load i64*, i64** %6
%26 = call i32 @rgph_murmur32_mix0(i32 %24, i64* %25)
%27 = load i64*, i64** %6
%28 = call i32 @rgph_murmur32_finalise(i32 4, i64* %27)
ret void
}

LLVM IR (-O2):
@UINT32_MAX = global i32 0
define void @rgph_u32x4_murmur32v_u64(i32 %0, i64 %1, i64* %2) {
%4 = getelementptr inbounds i64, i64* %2, i64 3
store i64 %1, i64* %4
%5 = getelementptr inbounds i64, i64* %2, i64 2
store i64 %1, i64* %5
%6 = getelementptr inbounds i64, i64* %2, i64 1
store i64 %1, i64* %6
store i64 %1, i64* %2
%7 = tail call i32 @htole64(i32 %0)
%8 = tail call i32 @rgph_murmur32_mix1(i32 poison, i64* %2)
%9 = tail call i32 @htole64(i32 %0)
%10 = load i32, i32* @UINT32_MAX
%11 = and i32 %10, %9
%12 = tail call i32 @rgph_murmur32_mix0(i32 %11, i64* %2)
%13 = tail call i32 @rgph_murmur32_finalise(i32 4, i64* %2)
ret void
}