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

/* Variables and functions */
void *FeatureGet(char *, char *);
void WordFormBuildLeFeat(char *in, char *out) {
  int c;
  if ('?' != (c = FeatureGet(in, "MFC"))) {
    *out = c;
    out++;
  }
  *out = FeatureGet(in, "NHVA9BDKRUx0«»");
  out++;
  *out = FeatureGet(in, "yz");
  out++;
  *out = '\0';
}


x86 assembly (clang, -O0):
<WordFormBuildLeFeat>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed5(%rip),%rsi
call   1030 <FeatureGet@plt>
mov    %eax,%ecx
mov    %ecx,-0x14(%rbp)
mov    $0x3f,%eax
cmp    %ecx,%eax
je     1159 <WordFormBuildLeFeat+0x49>
mov    -0x14(%rbp),%eax
mov    %al,%cl
mov    -0x10(%rbp),%rax
mov    %cl,(%rax)
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xea0(%rip),%rsi
call   1030 <FeatureGet@plt>
mov    %al,%cl
mov    -0x10(%rbp),%rax
mov    %cl,(%rax)
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xe8d(%rip),%rsi
call   1030 <FeatureGet@plt>
mov    %al,%cl
mov    -0x10(%rbp),%rax
mov    %cl,(%rax)
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movb   $0x0,(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<WordFormBuildLeFeat>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%rbx
mov    %rdi,%r14
lea    0xedf(%rip),%rsi
call   1030 <FeatureGet@plt>
cmp    $0x3f,%eax
je     1131 <WordFormBuildLeFeat+0x21>
mov    %al,(%rbx)
add    $0x1,%rbx
lea    0xecc(%rip),%rsi
mov    %r14,%rdi
call   1030 <FeatureGet@plt>
mov    %al,(%rbx)
lea    0xecc(%rip),%rsi
mov    %r14,%rdi
call   1030 <FeatureGet@plt>
mov    %al,0x1(%rbx)
movb   $0x0,0x2(%rbx)
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [4 x i8] c"MFC\00"
@.str.1 = [17 x i8] c"NHVA9BDKRUx0\C2\AB\C2\BB\00"
@.str.2 = [3 x i8] c"yz\00"
define void @WordFormBuildLeFeat(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%6 = load i8*, i8** %3
%7 = call i8* @FeatureGet(i8* %6, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%8 = ptrtoint i8* %7 to i32
store i32 %8, i32* %5
%9 = icmp ne i32 63, %8
br i1 %9, label %10, label %16
10: ; preds = %2
%11 = load i32, i32* %5
%12 = trunc i32 %11 to i8
%13 = load i8*, i8** %4
store i8 %12, i8* %13
%14 = load i8*, i8** %4
%15 = getelementptr inbounds i8, i8* %14, i32 1
store i8* %15, i8** %4
br label %16
16: ; preds = %10, %2
%17 = load i8*, i8** %3
%18 = call i8* @FeatureGet(i8* %17, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
%19 = ptrtoint i8* %18 to i8
%20 = load i8*, i8** %4
store i8 %19, i8* %20
%21 = load i8*, i8** %4
%22 = getelementptr inbounds i8, i8* %21, i32 1
store i8* %22, i8** %4
%23 = load i8*, i8** %3
%24 = call i8* @FeatureGet(i8* %23, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%25 = ptrtoint i8* %24 to i8
%26 = load i8*, i8** %4
store i8 %25, i8* %26
%27 = load i8*, i8** %4
%28 = getelementptr inbounds i8, i8* %27, i32 1
store i8* %28, i8** %4
%29 = load i8*, i8** %4
store i8 0, i8* %29
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"MFC\00"
@.str.1 = [17 x i8] c"NHVA9BDKRUx0\C2\AB\C2\BB\00"
@.str.2 = [3 x i8] c"yz\00"
define void @WordFormBuildLeFeat(i8* %0, i8* nocapture writeonly %1) {
%3 = tail call i8* @FeatureGet(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%4 = ptrtoint i8* %3 to i64
%5 = trunc i64 %4 to i32
%6 = icmp eq i32 %5, 63
br i1 %6, label %10, label %7
7: ; preds = %2
%8 = trunc i64 %4 to i8
store i8 %8, i8* %1
%9 = getelementptr inbounds i8, i8* %1, i64 1
br label %10
10: ; preds = %7, %2
%11 = phi i8* [ %9, %7 ], [ %1, %2 ]
%12 = tail call i8* @FeatureGet(i8* %0, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
%13 = ptrtoint i8* %12 to i64
%14 = trunc i64 %13 to i8
store i8 %14, i8* %11
%15 = getelementptr inbounds i8, i8* %11, i64 1
%16 = tail call i8* @FeatureGet(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%17 = ptrtoint i8* %16 to i64
%18 = trunc i64 %17 to i8
store i8 %18, i8* %15
%19 = getelementptr inbounds i8, i8* %11, i64 2
store i8 0, i8* %19
ret void
}