#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 scalar_t__ uint8_t;
typedef int uint64_t;

/* Variables and functions */
void TtlUnmarshal_uint64_t(uint8_t **cursor, uint64_t *x) {
  uint8_t *buffer = *cursor;
  *x = (((uint64_t)buffer[0]) << 56) | (((uint64_t)buffer[1]) << 48) |
       (((uint64_t)buffer[2]) << 40) | (((uint64_t)buffer[3]) << 32) |
       (((uint64_t)buffer[4]) << 24) | (((uint64_t)buffer[5]) << 16) |
       (((uint64_t)buffer[6]) << 8) | (((uint64_t)buffer[7]) << 0);
  *cursor += 8;
}


x86 assembly (clang, -O0):
<TtlUnmarshal_uint64_t>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rax
mov    (%rax),%rax
mov    $0x38,%ecx
shl    %cl,%eax
mov    -0x18(%rbp),%rcx
mov    0x8(%rcx),%rcx
mov    %ecx,%edx
mov    $0x30,%ecx
shl    %cl,%edx
mov    %edx,%ecx
or     %ecx,%eax
mov    -0x18(%rbp),%rcx
mov    0x10(%rcx),%rcx
mov    %ecx,%edx
mov    $0x28,%ecx
shl    %cl,%edx
mov    %edx,%ecx
or     %ecx,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x18(%rbp),%rax
mov    0x18(%rax),%rax
mov    $0x20,%ecx
shl    %cl,%eax
mov    -0x1c(%rbp),%ecx
or     %eax,%ecx
mov    -0x18(%rbp),%rax
mov    0x20(%rax),%rax
shl    $0x18,%eax
or     %eax,%ecx
mov    -0x18(%rbp),%rax
mov    0x28(%rax),%rax
shl    $0x10,%eax
or     %eax,%ecx
mov    -0x18(%rbp),%rax
mov    0x30(%rax),%rax
shl    $0x8,%eax
or     %eax,%ecx
mov    -0x18(%rbp),%rax
mov    0x38(%rax),%rax
shl    $0x0,%eax
or     %eax,%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x8(%rbp),%rax
mov    (%rax),%rcx
add    $0x40,%rcx
mov    %rcx,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<TtlUnmarshal_uint64_t>:
addq   $0x40,(%rdi)
ret

LLVM IR (-O0):
define void @TtlUnmarshal_uint64_t(i64** %0, i32* %1) {
%3 = alloca i64**
%4 = alloca i32*
%5 = alloca i64*
store i64** %0, i64*** %3
store i32* %1, i32** %4
%6 = load i64**, i64*** %3
%7 = load i64*, i64** %6
store i64* %7, i64** %5
%8 = load i64*, i64** %5
%9 = getelementptr inbounds i64, i64* %8, i64 0
%10 = load i64, i64* %9
%11 = trunc i64 %10 to i32
%12 = shl i32 %11, 56
%13 = load i64*, i64** %5
%14 = getelementptr inbounds i64, i64* %13, i64 1
%15 = load i64, i64* %14
%16 = trunc i64 %15 to i32
%17 = shl i32 %16, 48
%18 = or i32 %12, %17
%19 = load i64*, i64** %5
%20 = getelementptr inbounds i64, i64* %19, i64 2
%21 = load i64, i64* %20
%22 = trunc i64 %21 to i32
%23 = shl i32 %22, 40
%24 = or i32 %18, %23
%25 = load i64*, i64** %5
%26 = getelementptr inbounds i64, i64* %25, i64 3
%27 = load i64, i64* %26
%28 = trunc i64 %27 to i32
%29 = shl i32 %28, 32
%30 = or i32 %24, %29
%31 = load i64*, i64** %5
%32 = getelementptr inbounds i64, i64* %31, i64 4
%33 = load i64, i64* %32
%34 = trunc i64 %33 to i32
%35 = shl i32 %34, 24
%36 = or i32 %30, %35
%37 = load i64*, i64** %5
%38 = getelementptr inbounds i64, i64* %37, i64 5
%39 = load i64, i64* %38
%40 = trunc i64 %39 to i32
%41 = shl i32 %40, 16
%42 = or i32 %36, %41
%43 = load i64*, i64** %5
%44 = getelementptr inbounds i64, i64* %43, i64 6
%45 = load i64, i64* %44
%46 = trunc i64 %45 to i32
%47 = shl i32 %46, 8
%48 = or i32 %42, %47
%49 = load i64*, i64** %5
%50 = getelementptr inbounds i64, i64* %49, i64 7
%51 = load i64, i64* %50
%52 = trunc i64 %51 to i32
%53 = shl i32 %52, 0
%54 = or i32 %48, %53
%55 = load i32*, i32** %4
store i32 %54, i32* %55
%56 = load i64**, i64*** %3
%57 = load i64*, i64** %56
%58 = getelementptr inbounds i64, i64* %57, i64 8
store i64* %58, i64** %56
ret void
}

LLVM IR (-O2):
define void @TtlUnmarshal_uint64_t(i64** nocapture %0, i32* nocapture readnone %1) {
%3 = load i64*, i64** %0
%4 = getelementptr inbounds i64, i64* %3, i64 8
store i64* %4, i64** %0
ret void
}