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

/* Variables and functions */
int /*<<< orphan*/ abort();
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int rotl_16a(int);
int rotl_16b(int, int);
int rotl_32a(int);
int rotl_32b(int, int);
int rotl_32c(int, int);
int rotl_32d(int, int);
int rotl_32e(int, int);
int rotl_64(int);
int rotl_64a(int, int);
int rotl_64b(int, int);
int rotl_64c(int, int);
int rotl_64d(int, int);
int rotl_64e(int, int);
int rotl_64f(int, int);
int rotl_64g(int, int);
int rotl_64h(int, int);
int main(void) {
  if (rotl_16a(0x1234) != 0x3412)
    abort();
  if (rotl_16b(0xAA55, 0x1234) != 0x3412)
    abort();
  uint32_t num32 = 0x12345678;
  if (rotl_32a(num32) != 0x34567812)
    abort();
  if (rotl_32b(0xAA55, num32) != 0x34567812)
    abort();
  if (rotl_32c(0xAA55, num32) != 0x56781234)
    abort();
  if (rotl_32d(0xAA55, num32) != 0x78123456)
    abort();
  if (rotl_32e(0x1122AA55, num32) != 0x78123456)
    abort();
  uint64_t num = 0x123456789ABCDEF0ULL;
  if (rotl_64(num) != 0xF0123456789ABCDEULL)
    abort();
  if (rotl_64a(0xAA55, num) != 0xF0123456789ABCDEULL)
    abort();
  if (rotl_64b(0xAA55, num) != 0xDEF0123456789ABCULL)
    abort();
  if (rotl_64c(0xAA55, num) != 0xBCDEF0123456789AULL)
    abort();
  if (rotl_64d(0xAA55, num) != 0x9ABCDEF012345678ULL)
    abort();
  if (rotl_64e(0xAA55, num) != 0x789ABCDEF0123456ULL)
    abort();
  if (rotl_64f(0xAA55, num) != 0x56789ABCDEF01234ULL)
    abort();
  if (rotl_64g(0xAA55, num) != 0x3456789ABCDEF012ULL)
    abort();
  if (rotl_64h(0x1122AA55, num) != 0x56789ABCDEF01234ULL)
    abort();
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x1234,%edi
call   1090 <rotl_16a@plt>
cmp    $0x3412,%eax
je     124b <main+0x2b>
mov    $0x0,%al
call   1040 <abort@plt>
mov    $0xaa55,%edi
mov    $0x1234,%esi
call   1100 <rotl_16b@plt>
cmp    $0x3412,%eax
je     126c <main+0x4c>
mov    $0x0,%al
call   1040 <abort@plt>
movl   $0x12345678,-0x8(%rbp)
mov    -0x8(%rbp),%edi
call   1030 <rotl_32a@plt>
cmp    $0x34567812,%eax
je     128d <main+0x6d>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0x8(%rbp),%esi
mov    $0xaa55,%edi
call   10b0 <rotl_32b@plt>
cmp    $0x34567812,%eax
je     12ac <main+0x8c>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0x8(%rbp),%esi
mov    $0xaa55,%edi
call   1120 <rotl_32c@plt>
cmp    $0x56781234,%eax
je     12cb <main+0xab>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0x8(%rbp),%esi
mov    $0xaa55,%edi
call   10a0 <rotl_32d@plt>
cmp    $0x78123456,%eax
je     12ea <main+0xca>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0x8(%rbp),%esi
mov    $0x1122aa55,%edi
call   1110 <rotl_32e@plt>
cmp    $0x78123456,%eax
je     1309 <main+0xe9>
mov    $0x0,%al
call   1040 <abort@plt>
movl   $0x9abcdef0,-0xc(%rbp)
mov    -0xc(%rbp),%edi
call   1130 <rotl_64@plt>
cltq
movabs $0xf0123456789abcde,%rcx
34 12 f0
cmp    %rcx,%rax
je     1334 <main+0x114>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   10d0 <rotl_64a@plt>
cltq
movabs $0xf0123456789abcde,%rcx
34 12 f0
cmp    %rcx,%rax
je     135d <main+0x13d>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   1050 <rotl_64b@plt>
cltq
movabs $0xdef0123456789abc,%rcx
12 f0 de
cmp    %rcx,%rax
je     1386 <main+0x166>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   10c0 <rotl_64c@plt>
cltq
movabs $0xbcdef0123456789a,%rcx
f0 de bc
cmp    %rcx,%rax
je     13af <main+0x18f>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   1060 <rotl_64d@plt>
cltq
movabs $0x9abcdef012345678,%rcx
de bc 9a
cmp    %rcx,%rax
je     13d8 <main+0x1b8>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   10e0 <rotl_64e@plt>
cltq
movabs $0x789abcdef0123456,%rcx
bc 9a 78
cmp    %rcx,%rax
je     1401 <main+0x1e1>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   1070 <rotl_64f@plt>
cltq
movabs $0x56789abcdef01234,%rcx
9a 78 56
cmp    %rcx,%rax
je     142a <main+0x20a>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0xaa55,%edi
call   10f0 <rotl_64g@plt>
cltq
movabs $0x3456789abcdef012,%rcx
78 56 34
cmp    %rcx,%rax
je     1453 <main+0x233>
mov    $0x0,%al
call   1040 <abort@plt>
mov    -0xc(%rbp),%esi
mov    $0x1122aa55,%edi
call   1080 <rotl_64h@plt>
cltq
movabs $0x56789abcdef01234,%rcx
9a 78 56
cmp    %rcx,%rax
je     147c <main+0x25c>
mov    $0x0,%al
call   1040 <abort@plt>
xor    %edi,%edi
call   1140 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rax
mov    $0x1234,%edi
call   1050 <rotl_16a@plt>
cmp    $0x3412,%eax
jne    122f <main+0x9f>
mov    $0xaa55,%edi
mov    $0x1234,%esi
call   1080 <rotl_16b@plt>
cmp    $0x3412,%eax
jne    122f <main+0x9f>
mov    $0x12345678,%edi
call   1030 <rotl_32a@plt>
cmp    $0x34567812,%eax
jne    122f <main+0x9f>
mov    $0xaa55,%edi
mov    $0x12345678,%esi
call   1070 <rotl_32b@plt>
cmp    $0x34567812,%eax
jne    122f <main+0x9f>
mov    $0xaa55,%edi
mov    $0x12345678,%esi
call   10a0 <rotl_32c@plt>
cmp    $0x56781234,%eax
jne    122f <main+0x9f>
mov    $0xaa55,%edi
mov    $0x12345678,%esi
call   1060 <rotl_32d@plt>
cmp    $0x78123456,%eax
jne    122f <main+0x9f>
mov    $0x1122aa55,%edi
mov    $0x12345678,%esi
call   1090 <rotl_32e@plt>
cmp    $0x78123456,%eax
jne    122f <main+0x9f>
mov    $0x9abcdef0,%edi
call   10b0 <rotl_64@plt>
xor    %eax,%eax
call   1040 <abort@plt>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
%4 = call i32 @rotl_16a(i32 4660)
%5 = icmp ne i32 %4, 13330
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 (...) @abort()
unreachable
8: ; preds = %0
%9 = call i32 @rotl_16b(i32 43605, i32 4660)
%10 = icmp ne i32 %9, 13330
br i1 %10, label %11, label %13
11: ; preds = %8
%12 = call i32 (...) @abort()
unreachable
13: ; preds = %8
store i32 305419896, i32* %2
%14 = load i32, i32* %2
%15 = call i32 @rotl_32a(i32 %14)
%16 = icmp ne i32 %15, 878082066
br i1 %16, label %17, label %19
17: ; preds = %13
%18 = call i32 (...) @abort()
unreachable
19: ; preds = %13
%20 = load i32, i32* %2
%21 = call i32 @rotl_32b(i32 43605, i32 %20)
%22 = icmp ne i32 %21, 878082066
br i1 %22, label %23, label %25
23: ; preds = %19
%24 = call i32 (...) @abort()
unreachable
25: ; preds = %19
%26 = load i32, i32* %2
%27 = call i32 @rotl_32c(i32 43605, i32 %26)
%28 = icmp ne i32 %27, 1450709556
br i1 %28, label %29, label %31
29: ; preds = %25
%30 = call i32 (...) @abort()
unreachable
31: ; preds = %25
%32 = load i32, i32* %2
%33 = call i32 @rotl_32d(i32 43605, i32 %32)
%34 = icmp ne i32 %33, 2014458966
br i1 %34, label %35, label %37
35: ; preds = %31
%36 = call i32 (...) @abort()
unreachable
37: ; preds = %31
%38 = load i32, i32* %2
%39 = call i32 @rotl_32e(i32 287484501, i32 %38)
%40 = icmp ne i32 %39, 2014458966
br i1 %40, label %41, label %43
41: ; preds = %37
%42 = call i32 (...) @abort()
unreachable
43: ; preds = %37
store i32 -1698898192, i32* %3
%44 = load i32, i32* %3
%45 = call i32 @rotl_64(i32 %44)
%46 = sext i32 %45 to i64
%47 = icmp ne i64 %46, -1147797409030816546
br i1 %47, label %48, label %50
48: ; preds = %43
%49 = call i32 (...) @abort()
unreachable
50: ; preds = %43
%51 = load i32, i32* %3
%52 = call i32 @rotl_64a(i32 43605, i32 %51)
%53 = sext i32 %52 to i64
%54 = icmp ne i64 %53, -1147797409030816546
br i1 %54, label %55, label %57
55: ; preds = %50
%56 = call i32 (...) @abort()
unreachable
57: ; preds = %50
%58 = load i32, i32* %3
%59 = call i32 @rotl_64b(i32 43605, i32 %58)
%60 = sext i32 %59 to i64
%61 = icmp ne i64 %60, -2382384186880648516
br i1 %61, label %62, label %64
62: ; preds = %57
%63 = call i32 (...) @abort()
unreachable
64: ; preds = %57
%65 = load i32, i32* %3
%66 = call i32 @rotl_64c(i32 43605, i32 %65)
%67 = sext i32 %66 to i64
%68 = icmp ne i64 %67, -4837164988771174246
br i1 %68, label %69, label %71
69: ; preds = %64
%70 = call i32 (...) @abort()
unreachable
71: ; preds = %64
%72 = load i32, i32* %3
%73 = call i32 @rotl_64d(i32 43605, i32 %72)
%74 = sext i32 %73 to i64
%75 = icmp ne i64 %74, -7296712173568108936
br i1 %75, label %76, label %78
76: ; preds = %71
%77 = call i32 (...) @abort()
unreachable
78: ; preds = %71
%79 = load i32, i32* %3
%80 = call i32 @rotl_64e(i32 43605, i32 %79)
%81 = sext i32 %80 to i64
%82 = icmp ne i64 %81, 8690466096661279830
br i1 %82, label %83, label %85
83: ; preds = %78
%84 = call i32 (...) @abort()
unreachable
85: ; preds = %78
%86 = load i32, i32* %3
%87 = call i32 @rotl_64f(i32 43605, i32 %86)
%88 = sext i32 %87 to i64
%89 = icmp ne i64 %88, 6230900220451885620
br i1 %89, label %90, label %92
90: ; preds = %85
%91 = call i32 (...) @abort()
unreachable
92: ; preds = %85
%93 = load i32, i32* %3
%94 = call i32 @rotl_64g(i32 43605, i32 %93)
%95 = sext i32 %94 to i64
%96 = icmp ne i64 %95, 3771334343958392850
br i1 %96, label %97, label %99
97: ; preds = %92
%98 = call i32 (...) @abort()
unreachable
99: ; preds = %92
%100 = load i32, i32* %3
%101 = call i32 @rotl_64h(i32 287484501, i32 %100)
%102 = sext i32 %101 to i64
%103 = icmp ne i64 %102, 6230900220451885620
br i1 %103, label %104, label %106
104: ; preds = %99
%105 = call i32 (...) @abort()
unreachable
106: ; preds = %99
%107 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @rotl_16a(i32 4660)
%2 = icmp eq i32 %1, 13330
br i1 %2, label %5, label %3
3: ; preds = %0
%4 = tail call i32 (...) @abort()
unreachable
5: ; preds = %0
%6 = tail call i32 @rotl_16b(i32 43605, i32 4660)
%7 = icmp eq i32 %6, 13330
br i1 %7, label %10, label %8
8: ; preds = %5
%9 = tail call i32 (...) @abort()
unreachable
10: ; preds = %5
%11 = tail call i32 @rotl_32a(i32 305419896)
%12 = icmp eq i32 %11, 878082066
br i1 %12, label %15, label %13
13: ; preds = %10
%14 = tail call i32 (...) @abort()
unreachable
15: ; preds = %10
%16 = tail call i32 @rotl_32b(i32 43605, i32 305419896)
%17 = icmp eq i32 %16, 878082066
br i1 %17, label %20, label %18
18: ; preds = %15
%19 = tail call i32 (...) @abort()
unreachable
20: ; preds = %15
%21 = tail call i32 @rotl_32c(i32 43605, i32 305419896)
%22 = icmp eq i32 %21, 1450709556
br i1 %22, label %25, label %23
23: ; preds = %20
%24 = tail call i32 (...) @abort()
unreachable
25: ; preds = %20
%26 = tail call i32 @rotl_32d(i32 43605, i32 305419896)
%27 = icmp eq i32 %26, 2014458966
br i1 %27, label %30, label %28
28: ; preds = %25
%29 = tail call i32 (...) @abort()
unreachable
30: ; preds = %25
%31 = tail call i32 @rotl_32e(i32 287484501, i32 305419896)
%32 = icmp eq i32 %31, 2014458966
br i1 %32, label %35, label %33
33: ; preds = %30
%34 = tail call i32 (...) @abort()
unreachable
35: ; preds = %30
%36 = tail call i32 @rotl_64(i32 -1698898192)
%37 = tail call i32 (...) @abort()
unreachable
}