#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*/ __m128i;

/* Variables and functions */
int /*<<< orphan*/ _mm_add_epi64(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ _mm_or_si128(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ _mm_slli_epi64(int /*<<< orphan*/, int);
int /*<<< orphan*/ _mm_srli_epi64(int /*<<< orphan*/, int);
int /*<<< orphan*/ _mm_xor_si128(int /*<<< orphan*/, int /*<<< orphan*/);
__m128i xoroshiro_vector_advance(__m128i *s0, __m128i *s1) {
  __m128i xmm1 = *s0;
  __m128i xmm2 = *s1;
  __m128i xmm0, xmm3, xmm4, xmm5;
  xmm3 = xmm1;
  xmm3 = _mm_xor_si128(xmm3, xmm2);
  xmm4 = xmm3;
  xmm4 = _mm_slli_epi64(xmm4, 14);
  xmm5 = xmm1;
  xmm5 = _mm_slli_epi64(xmm5, 55);
  xmm1 = _mm_srli_epi64(xmm1, 9);
  xmm1 = _mm_or_si128(xmm1, xmm5);
  xmm1 = _mm_xor_si128(xmm1, xmm3);
  xmm1 = _mm_xor_si128(xmm1, xmm4);
  xmm2 = _mm_xor_si128(xmm2, xmm3);
  xmm2 = _mm_slli_epi64(xmm2, 36);
  xmm3 = _mm_srli_epi64(xmm3, 28);
  xmm2 = _mm_or_si128(xmm2, xmm3);
  *s0 = xmm1;
  *s1 = xmm2;
  return _mm_add_epi64(xmm1, xmm2);
}


x86 assembly (clang, -O0):
<xoroshiro_vector_advance>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x20(%rbp)
mov    -0x20(%rbp),%edi
mov    -0x18(%rbp),%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,-0x20(%rbp)
mov    -0x20(%rbp),%eax
mov    %eax,-0x24(%rbp)
mov    -0x24(%rbp),%edi
mov    $0xe,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,-0x24(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x28(%rbp)
mov    -0x28(%rbp),%edi
mov    $0x37,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,-0x28(%rbp)
mov    -0x14(%rbp),%edi
mov    $0x9,%esi
call   1030 <_mm_srli_epi64@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    -0x28(%rbp),%esi
call   1040 <_mm_or_si128@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    -0x20(%rbp),%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%edi
mov    -0x24(%rbp),%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,-0x14(%rbp)
mov    -0x18(%rbp),%edi
mov    -0x20(%rbp),%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,-0x18(%rbp)
mov    -0x18(%rbp),%edi
mov    $0x24,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,-0x18(%rbp)
mov    -0x20(%rbp),%edi
mov    $0x1c,%esi
call   1030 <_mm_srli_epi64@plt>
mov    %eax,-0x20(%rbp)
mov    -0x18(%rbp),%edi
mov    -0x20(%rbp),%esi
call   1040 <_mm_or_si128@plt>
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x18(%rbp),%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x14(%rbp),%edi
mov    -0x18(%rbp),%esi
call   1060 <_mm_add_epi64@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<xoroshiro_vector_advance>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %rsi,(%rsp)
mov    %rdi,%r15
mov    (%rdi),%ebx
mov    (%rsi),%r12d
mov    %ebx,%edi
mov    %r12d,%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,%ebp
mov    %eax,%edi
mov    $0xe,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,%r13d
mov    %ebx,%edi
mov    $0x37,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,%r14d
mov    %ebx,%edi
mov    $0x9,%esi
call   1030 <_mm_srli_epi64@plt>
mov    %eax,%edi
mov    %r14d,%esi
call   1040 <_mm_or_si128@plt>
mov    %eax,%edi
mov    %ebp,%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,%edi
mov    %r13d,%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,%r14d
mov    %r12d,%edi
mov    %ebp,%esi
call   1050 <_mm_xor_si128@plt>
mov    %eax,%edi
mov    $0x24,%esi
call   1070 <_mm_slli_epi64@plt>
mov    %eax,%ebx
mov    %ebp,%edi
mov    $0x1c,%esi
call   1030 <_mm_srli_epi64@plt>
mov    %ebx,%edi
mov    %eax,%esi
call   1040 <_mm_or_si128@plt>
mov    %r14d,(%r15)
mov    (%rsp),%rcx
mov    %eax,(%rcx)
mov    %r14d,%edi
mov    %eax,%esi
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1060 <_mm_add_epi64@plt>

LLVM IR (-O0):
define i32 @xoroshiro_vector_advance(i32* %0, i32* %1) {
%3 = alloca i32*
%4 = alloca i32*
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32* %0, i32** %3
store i32* %1, i32** %4
%11 = load i32*, i32** %3
%12 = load i32, i32* %11
store i32 %12, i32* %5
%13 = load i32*, i32** %4
%14 = load i32, i32* %13
store i32 %14, i32* %6
%15 = load i32, i32* %5
store i32 %15, i32* %8
%16 = load i32, i32* %8
%17 = load i32, i32* %6
%18 = call i32 @_mm_xor_si128(i32 %16, i32 %17)
store i32 %18, i32* %8
%19 = load i32, i32* %8
store i32 %19, i32* %9
%20 = load i32, i32* %9
%21 = call i32 @_mm_slli_epi64(i32 %20, i32 14)
store i32 %21, i32* %9
%22 = load i32, i32* %5
store i32 %22, i32* %10
%23 = load i32, i32* %10
%24 = call i32 @_mm_slli_epi64(i32 %23, i32 55)
store i32 %24, i32* %10
%25 = load i32, i32* %5
%26 = call i32 @_mm_srli_epi64(i32 %25, i32 9)
store i32 %26, i32* %5
%27 = load i32, i32* %5
%28 = load i32, i32* %10
%29 = call i32 @_mm_or_si128(i32 %27, i32 %28)
store i32 %29, i32* %5
%30 = load i32, i32* %5
%31 = load i32, i32* %8
%32 = call i32 @_mm_xor_si128(i32 %30, i32 %31)
store i32 %32, i32* %5
%33 = load i32, i32* %5
%34 = load i32, i32* %9
%35 = call i32 @_mm_xor_si128(i32 %33, i32 %34)
store i32 %35, i32* %5
%36 = load i32, i32* %6
%37 = load i32, i32* %8
%38 = call i32 @_mm_xor_si128(i32 %36, i32 %37)
store i32 %38, i32* %6
%39 = load i32, i32* %6
%40 = call i32 @_mm_slli_epi64(i32 %39, i32 36)
store i32 %40, i32* %6
%41 = load i32, i32* %8
%42 = call i32 @_mm_srli_epi64(i32 %41, i32 28)
store i32 %42, i32* %8
%43 = load i32, i32* %6
%44 = load i32, i32* %8
%45 = call i32 @_mm_or_si128(i32 %43, i32 %44)
store i32 %45, i32* %6
%46 = load i32, i32* %5
%47 = load i32*, i32** %3
store i32 %46, i32* %47
%48 = load i32, i32* %6
%49 = load i32*, i32** %4
store i32 %48, i32* %49
%50 = load i32, i32* %5
%51 = load i32, i32* %6
%52 = call i32 @_mm_add_epi64(i32 %50, i32 %51)
ret i32 %52
}

LLVM IR (-O2):
define i32 @xoroshiro_vector_advance(i32* nocapture %0, i32* nocapture %1) {
%3 = load i32, i32* %0
%4 = load i32, i32* %1
%5 = tail call i32 @_mm_xor_si128(i32 %3, i32 %4)
%6 = tail call i32 @_mm_slli_epi64(i32 %5, i32 14)
%7 = tail call i32 @_mm_slli_epi64(i32 %3, i32 55)
%8 = tail call i32 @_mm_srli_epi64(i32 %3, i32 9)
%9 = tail call i32 @_mm_or_si128(i32 %8, i32 %7)
%10 = tail call i32 @_mm_xor_si128(i32 %9, i32 %5)
%11 = tail call i32 @_mm_xor_si128(i32 %10, i32 %6)
%12 = tail call i32 @_mm_xor_si128(i32 %4, i32 %5)
%13 = tail call i32 @_mm_slli_epi64(i32 %12, i32 36)
%14 = tail call i32 @_mm_srli_epi64(i32 %5, i32 28)
%15 = tail call i32 @_mm_or_si128(i32 %13, i32 %14)
store i32 %11, i32* %0
store i32 %15, i32* %1
%16 = tail call i32 @_mm_add_epi64(i32 %11, i32 %15)
ret i32 %16
}