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

/* Variables and functions */
int /*<<< orphan*/ out_hand0(int /*<<< orphan*/ *, int, char const *, char *);
void out_hand(FILE *pf, unsigned int hand, const char *str_prefix) {
  out_hand0(pf, (int)(((hand) >> 0) & 0x1f), str_prefix, "00FU");
  out_hand0(pf, (int)(((hand) >> 5) & 0x07), str_prefix, "00KY");
  out_hand0(pf, (int)(((hand) >> 8) & 0x07), str_prefix, "00KE");
  out_hand0(pf, (int)(((hand) >> 11) & 0x07), str_prefix, "00GI");
  out_hand0(pf, (int)(((hand) >> 14) & 0x07), str_prefix, "00KI");
  out_hand0(pf, (int)(((hand) >> 17) & 0x03), str_prefix, "00KA");
  out_hand0(pf, (int)((hand) >> 19), str_prefix, "00HI");
}


x86 assembly (clang, -O0):
<out_hand>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0x0,%esi
and    $0x1f,%esi
mov    -0x18(%rbp),%rdx
lea    0xec5(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0x5,%esi
and    $0x7,%esi
mov    -0x18(%rbp),%rdx
lea    0xead(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0x8,%esi
and    $0x7,%esi
mov    -0x18(%rbp),%rdx
lea    0xe95(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0xb,%esi
and    $0x7,%esi
mov    -0x18(%rbp),%rdx
lea    0xe7d(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0xe,%esi
and    $0x7,%esi
mov    -0x18(%rbp),%rdx
lea    0xe65(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0x11,%esi
and    $0x3,%esi
mov    -0x18(%rbp),%rdx
lea    0xe4d(%rip),%rcx
call   1030 <out_hand0@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
shr    $0x13,%esi
mov    -0x18(%rbp),%rdx
lea    0xe38(%rip),%rcx
call   1030 <out_hand0@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<out_hand>:
push   %rbp
push   %r14
push   %rbx
mov    %rdx,%r14
mov    %esi,%ebp
mov    %rdi,%rbx
and    $0x1f,%esi
lea    0xeda(%rip),%rcx
call   1030 <out_hand0@plt>
mov    %ebp,%esi
shr    $0x5,%esi
and    $0x7,%esi
lea    0xecb(%rip),%rcx
mov    %rbx,%rdi
mov    %r14,%rdx
call   1030 <out_hand0@plt>
mov    %ebp,%esi
shr    $0x8,%esi
and    $0x7,%esi
lea    0xeb6(%rip),%rcx
mov    %rbx,%rdi
mov    %r14,%rdx
call   1030 <out_hand0@plt>
mov    %ebp,%esi
shr    $0xb,%esi
and    $0x7,%esi
lea    0xea1(%rip),%rcx
mov    %rbx,%rdi
mov    %r14,%rdx
call   1030 <out_hand0@plt>
mov    %ebp,%esi
shr    $0xe,%esi
and    $0x7,%esi
lea    0xe8c(%rip),%rcx
mov    %rbx,%rdi
mov    %r14,%rdx
call   1030 <out_hand0@plt>
mov    %ebp,%esi
shr    $0x11,%esi
and    $0x3,%esi
lea    0xe77(%rip),%rcx
mov    %rbx,%rdi
mov    %r14,%rdx
call   1030 <out_hand0@plt>
shr    $0x13,%ebp
lea    0xe67(%rip),%rcx
mov    %rbx,%rdi
mov    %ebp,%esi
mov    %r14,%rdx
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <out_hand0@plt>

LLVM IR (-O0):
@.str = [5 x i8] c"00FU\00"
@.str.1 = [5 x i8] c"00KY\00"
@.str.2 = [5 x i8] c"00KE\00"
@.str.3 = [5 x i8] c"00GI\00"
@.str.4 = [5 x i8] c"00KI\00"
@.str.5 = [5 x i8] c"00KA\00"
@.str.6 = [5 x i8] c"00HI\00"
define void @out_hand(i32* %0, i32 %1, i8* %2) {
%4 = alloca i32*
%5 = alloca i32
%6 = alloca i8*
store i32* %0, i32** %4
store i32 %1, i32* %5
store i8* %2, i8** %6
%7 = load i32*, i32** %4
%8 = load i32, i32* %5
%9 = lshr i32 %8, 0
%10 = and i32 %9, 31
%11 = load i8*, i8** %6
%12 = call i32 @out_hand0(i32* %7, i32 %10, i8* %11, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%13 = load i32*, i32** %4
%14 = load i32, i32* %5
%15 = lshr i32 %14, 5
%16 = and i32 %15, 7
%17 = load i8*, i8** %6
%18 = call i32 @out_hand0(i32* %13, i32 %16, i8* %17, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%19 = load i32*, i32** %4
%20 = load i32, i32* %5
%21 = lshr i32 %20, 8
%22 = and i32 %21, 7
%23 = load i8*, i8** %6
%24 = call i32 @out_hand0(i32* %19, i32 %22, i8* %23, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%25 = load i32*, i32** %4
%26 = load i32, i32* %5
%27 = lshr i32 %26, 11
%28 = and i32 %27, 7
%29 = load i8*, i8** %6
%30 = call i32 @out_hand0(i32* %25, i32 %28, i8* %29, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.3, i64 0, i64 0))
%31 = load i32*, i32** %4
%32 = load i32, i32* %5
%33 = lshr i32 %32, 14
%34 = and i32 %33, 7
%35 = load i8*, i8** %6
%36 = call i32 @out_hand0(i32* %31, i32 %34, i8* %35, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i64 0, i64 0))
%37 = load i32*, i32** %4
%38 = load i32, i32* %5
%39 = lshr i32 %38, 17
%40 = and i32 %39, 3
%41 = load i8*, i8** %6
%42 = call i32 @out_hand0(i32* %37, i32 %40, i8* %41, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%43 = load i32*, i32** %4
%44 = load i32, i32* %5
%45 = lshr i32 %44, 19
%46 = load i8*, i8** %6
%47 = call i32 @out_hand0(i32* %43, i32 %45, i8* %46, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [5 x i8] c"00FU\00"
@.str.1 = [5 x i8] c"00KY\00"
@.str.2 = [5 x i8] c"00KE\00"
@.str.3 = [5 x i8] c"00GI\00"
@.str.4 = [5 x i8] c"00KI\00"
@.str.5 = [5 x i8] c"00KA\00"
@.str.6 = [5 x i8] c"00HI\00"
define void @out_hand(i32* %0, i32 %1, i8* %2) {
%4 = and i32 %1, 31
%5 = tail call i32 @out_hand0(i32* %0, i32 %4, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%6 = lshr i32 %1, 5
%7 = and i32 %6, 7
%8 = tail call i32 @out_hand0(i32* %0, i32 %7, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0))
%9 = lshr i32 %1, 8
%10 = and i32 %9, 7
%11 = tail call i32 @out_hand0(i32* %0, i32 %10, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%12 = lshr i32 %1, 11
%13 = and i32 %12, 7
%14 = tail call i32 @out_hand0(i32* %0, i32 %13, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.3, i64 0, i64 0))
%15 = lshr i32 %1, 14
%16 = and i32 %15, 7
%17 = tail call i32 @out_hand0(i32* %0, i32 %16, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i64 0, i64 0))
%18 = lshr i32 %1, 17
%19 = and i32 %18, 3
%20 = tail call i32 @out_hand0(i32* %0, i32 %19, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%21 = lshr i32 %1, 19
%22 = tail call i32 @out_hand0(i32* %0, i32 %21, i8* %2, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0))
ret void
}