#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*/ fgets(char *, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ isspace(char);
int /*<<< orphan*/ sscanf(char *, char *, char *, char *, ...);
scalar_t__ strcmp(char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
scalar_t__ strlen(char *);
void getLine(FILE *fpSource, char *parsedInfo[]) {
  int length = 0;
  char strBuffer[100];
  fgets(strBuffer, 100, fpSource);
  length = (unsigned int)strlen(strBuffer);
  if (strBuffer[length - 1] == '\n') {
    strBuffer[length - 1] = '\0';
  }
  strcpy(parsedInfo[0], strBuffer);
  parsedInfo[1][0] = parsedInfo[2][0] = parsedInfo[3][0] = '\0';
  if (parsedInfo[0][0] != '.') {
    if (!isspace(parsedInfo[0][0])) {
      sscanf(parsedInfo[0], "%s%s%s", parsedInfo[1], parsedInfo[2],
             parsedInfo[3]);
    } else {
      sscanf(parsedInfo[0], "%s%s", parsedInfo[2], parsedInfo[3]);
    }
    if ((strcmp(parsedInfo[2], "RSUB") == 0) &&
        (strcmp(parsedInfo[3], "4C") != 0)) {
      parsedInfo[3][0] = '\0';
    }
  }
}


x86 assembly (clang, -O0):
<getLine>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
lea    -0x80(%rbp),%rdi
mov    -0x8(%rbp),%rdx
mov    $0x64,%esi
call   1060 <fgets@plt>
lea    -0x80(%rbp),%rdi
call   1040 <strlen@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
sub    $0x1,%eax
cltq
movsbl -0x80(%rbp,%rax,1),%eax
cmp    $0xa,%eax
jne    11bb <getLine+0x5b>
mov    -0x14(%rbp),%eax
sub    $0x1,%eax
cltq
movb   $0x0,-0x80(%rbp,%rax,1)
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
lea    -0x80(%rbp),%rsi
call   1030 <strcpy@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rax
movb   $0x0,(%rax)
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rax
movb   $0x0,(%rax)
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
movb   $0x0,(%rax)
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
movsbl (%rax),%eax
cmp    $0x2e,%eax
je     12ba <getLine+0x15a>
mov    -0x10(%rbp),%rax
mov    (%rax),%rax
movsbl (%rax),%edi
call   1050 <isspace@plt>
cmp    $0x0,%eax
jne    1249 <getLine+0xe9>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdx
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rcx
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%r8
lea    0xdc3(%rip),%rsi
mov    $0x0,%al
call   1080 <sscanf@plt>
jmp    126e <getLine+0x10e>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdx
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rcx
lea    0xd9b(%rip),%rsi
mov    $0x0,%al
call   1080 <sscanf@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
lea    0xd8a(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%rax
jne    12b5 <getLine+0x155>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
lea    0xd71(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%rax
je     12b5 <getLine+0x155>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rax
movb   $0x0,(%rax)
jmp    12ba <getLine+0x15a>
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getLine>:
push   %r14
push   %rbx
sub    $0x68,%rsp
mov    %rsi,%rbx
mov    %rdi,%rdx
mov    %rsp,%r14
mov    %r14,%rdi
mov    $0x64,%esi
call   1060 <fgets@plt>
mov    %r14,%rdi
call   1040 <strlen@plt>
add    $0xffffffff,%eax
cltq
cmpb   $0xa,(%rsp,%rax,1)
jne    1194 <getLine+0x34>
movb   $0x0,(%rsp,%rax,1)
mov    (%rbx),%rdi
mov    %rsp,%rsi
call   1030 <strcpy@plt>
mov    0x18(%rbx),%rax
movb   $0x0,(%rax)
mov    0x10(%rbx),%rax
movb   $0x0,(%rax)
mov    0x8(%rbx),%rax
movb   $0x0,(%rax)
mov    (%rbx),%rax
mov    (%rax),%al
cmp    $0x2e,%al
je     122f <getLine+0xcf>
movsbl %al,%edi
call   1050 <isspace@plt>
mov    (%rbx),%rdi
test   %eax,%eax
je     11e4 <getLine+0x84>
mov    0x10(%rbx),%rdx
mov    0x18(%rbx),%rcx
lea    0xe27(%rip),%rsi
xor    %eax,%eax
call   1080 <sscanf@plt>
jmp    11fe <getLine+0x9e>
mov    0x8(%rbx),%rdx
mov    0x10(%rbx),%rcx
mov    0x18(%rbx),%r8
lea    0xe09(%rip),%rsi
xor    %eax,%eax
call   1080 <sscanf@plt>
mov    0x10(%rbx),%rdi
lea    0xdfe(%rip),%rsi
call   1070 <strcmp@plt>
test   %rax,%rax
jne    122f <getLine+0xcf>
mov    0x18(%rbx),%rdi
lea    0xdee(%rip),%rsi
call   1070 <strcmp@plt>
test   %rax,%rax
je     122f <getLine+0xcf>
mov    0x18(%rbx),%rax
movb   $0x0,(%rax)
add    $0x68,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [7 x i8] c"%s%s%s\00"
@.str.1 = [5 x i8] c"%s%s\00"
@.str.2 = [5 x i8] c"RSUB\00"
@.str.3 = [3 x i8] c"4C\00"
define void @getLine(i32* %0, i8** %1) {
%3 = alloca i32*
%4 = alloca i8**
%5 = alloca i32
%6 = alloca [100 x i8]
store i32* %0, i32** %3
store i8** %1, i8*** %4
store i32 0, i32* %5
%7 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%8 = load i32*, i32** %3
%9 = call i32 @fgets(i8* %7, i32 100, i32* %8)
%10 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%11 = call i64 @strlen(i8* %10)
%12 = trunc i64 %11 to i32
store i32 %12, i32* %5
%13 = load i32, i32* %5
%14 = sub nsw i32 %13, 1
%15 = sext i32 %14 to i64
%16 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 %15
%17 = load i8, i8* %16
%18 = sext i8 %17 to i32
%19 = icmp eq i32 %18, 10
br i1 %19, label %20, label %25
20: ; preds = %2
%21 = load i32, i32* %5
%22 = sub nsw i32 %21, 1
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 %23
store i8 0, i8* %24
br label %25
25: ; preds = %20, %2
%26 = load i8**, i8*** %4
%27 = getelementptr inbounds i8*, i8** %26, i64 0
%28 = load i8*, i8** %27
%29 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%30 = call i32 @strcpy(i8* %28, i8* %29)
%31 = load i8**, i8*** %4
%32 = getelementptr inbounds i8*, i8** %31, i64 3
%33 = load i8*, i8** %32
%34 = getelementptr inbounds i8, i8* %33, i64 0
store i8 0, i8* %34
%35 = load i8**, i8*** %4
%36 = getelementptr inbounds i8*, i8** %35, i64 2
%37 = load i8*, i8** %36
%38 = getelementptr inbounds i8, i8* %37, i64 0
store i8 0, i8* %38
%39 = load i8**, i8*** %4
%40 = getelementptr inbounds i8*, i8** %39, i64 1
%41 = load i8*, i8** %40
%42 = getelementptr inbounds i8, i8* %41, i64 0
store i8 0, i8* %42
%43 = load i8**, i8*** %4
%44 = getelementptr inbounds i8*, i8** %43, i64 0
%45 = load i8*, i8** %44
%46 = getelementptr inbounds i8, i8* %45, i64 0
%47 = load i8, i8* %46
%48 = sext i8 %47 to i32
%49 = icmp ne i32 %48, 46
br i1 %49, label %50, label %101
50: ; preds = %25
%51 = load i8**, i8*** %4
%52 = getelementptr inbounds i8*, i8** %51, i64 0
%53 = load i8*, i8** %52
%54 = getelementptr inbounds i8, i8* %53, i64 0
%55 = load i8, i8* %54
%56 = call i32 @isspace(i8 signext %55)
%57 = icmp ne i32 %56, 0
br i1 %57, label %72, label %58
58: ; preds = %50
%59 = load i8**, i8*** %4
%60 = getelementptr inbounds i8*, i8** %59, i64 0
%61 = load i8*, i8** %60
%62 = load i8**, i8*** %4
%63 = getelementptr inbounds i8*, i8** %62, i64 1
%64 = load i8*, i8** %63
%65 = load i8**, i8*** %4
%66 = getelementptr inbounds i8*, i8** %65, i64 2
%67 = load i8*, i8** %66
%68 = load i8**, i8*** %4
%69 = getelementptr inbounds i8*, i8** %68, i64 3
%70 = load i8*, i8** %69
%71 = call i32 (i8*, i8*, i8*, i8*, ...) @sscanf(i8* %61, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %64, i8* %67, i8* %70)
br label %83
72: ; preds = %50
%73 = load i8**, i8*** %4
%74 = getelementptr inbounds i8*, i8** %73, i64 0
%75 = load i8*, i8** %74
%76 = load i8**, i8*** %4
%77 = getelementptr inbounds i8*, i8** %76, i64 2
%78 = load i8*, i8** %77
%79 = load i8**, i8*** %4
%80 = getelementptr inbounds i8*, i8** %79, i64 3
%81 = load i8*, i8** %80
%82 = call i32 (i8*, i8*, i8*, i8*, ...) @sscanf(i8* %75, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* %78, i8* %81)
br label %83
83: ; preds = %72, %58
%84 = load i8**, i8*** %4
%85 = getelementptr inbounds i8*, i8** %84, i64 2
%86 = load i8*, i8** %85
%87 = call i64 @strcmp(i8* %86, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%88 = icmp eq i64 %87, 0
br i1 %88, label %89, label %100
89: ; preds = %83
%90 = load i8**, i8*** %4
%91 = getelementptr inbounds i8*, i8** %90, i64 3
%92 = load i8*, i8** %91
%93 = call i64 @strcmp(i8* %92, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%94 = icmp ne i64 %93, 0
br i1 %94, label %95, label %100
95: ; preds = %89
%96 = load i8**, i8*** %4
%97 = getelementptr inbounds i8*, i8** %96, i64 3
%98 = load i8*, i8** %97
%99 = getelementptr inbounds i8, i8* %98, i64 0
store i8 0, i8* %99
br label %100
100: ; preds = %95, %89, %83
br label %101
101: ; preds = %100, %25
ret void
}

LLVM IR (-O2):
@.str = [7 x i8] c"%s%s%s\00"
@.str.1 = [5 x i8] c"%s%s\00"
@.str.2 = [5 x i8] c"RSUB\00"
@.str.3 = [3 x i8] c"4C\00"
define void @getLine(i32* nocapture %0, i8** nocapture %1) {
%3 = alloca [100 x i8]
%4 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%5 = call i32 @fgets(i8* %4, i32 100, i32* %0)
%6 = call i64 @strlen(i8* %4)
%7 = shl i64 %6, 32
%8 = add i64 %7, -4294967296
%9 = ashr exact i64 %8, 32
%10 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 %9
%11 = load i8, i8* %10
%12 = icmp eq i8 %11, 10
br i1 %12, label %13, label %14
13: ; preds = %2
store i8 0, i8* %10
br label %14
14: ; preds = %13, %2
%15 = load i8*, i8** %1
%16 = call i32 @strcpy(i8* %15, i8* %4)
%17 = getelementptr inbounds i8*, i8** %1, i64 3
%18 = load i8*, i8** %17
store i8 0, i8* %18
%19 = getelementptr inbounds i8*, i8** %1, i64 2
%20 = load i8*, i8** %19
store i8 0, i8* %20
%21 = getelementptr inbounds i8*, i8** %1, i64 1
%22 = load i8*, i8** %21
store i8 0, i8* %22
%23 = load i8*, i8** %1
%24 = load i8, i8* %23
%25 = icmp eq i8 %24, 46
br i1 %25, label %49, label %26
26: ; preds = %14
%27 = call i32 @isspace(i8 signext %24)
%28 = icmp eq i32 %27, 0
%29 = load i8*, i8** %1
br i1 %28, label %30, label %35
30: ; preds = %26
%31 = load i8*, i8** %21
%32 = load i8*, i8** %19
%33 = load i8*, i8** %17
%34 = call i32 (i8*, i8*, i8*, i8*, ...) @sscanf(i8* %29, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* %31, i8* %32, i8* %33)
br label %39
35: ; preds = %26
%36 = load i8*, i8** %19
%37 = load i8*, i8** %17
%38 = call i32 (i8*, i8*, i8*, i8*, ...) @sscanf(i8* %29, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i8* %36, i8* %37)
br label %39
39: ; preds = %35, %30
%40 = load i8*, i8** %19
%41 = call i64 @strcmp(i8* %40, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%42 = icmp eq i64 %41, 0
br i1 %42, label %43, label %49
43: ; preds = %39
%44 = load i8*, i8** %17
%45 = call i64 @strcmp(i8* %44, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%46 = icmp eq i64 %45, 0
br i1 %46, label %49, label %47
47: ; preds = %43
%48 = load i8*, i8** %17
store i8 0, i8* %48
br label %49
49: ; preds = %39, %43, %47, %14
ret void
}