#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*/ poller;
typedef int /*<<< orphan*/ path;

/* Variables and functions */
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, ...);
int /*<<< orphan*/ replTerm(char *);
int /*<<< orphan*/ stdin;
int /*<<< orphan*/ stdout;
void scanConfig() {
  char path[1024], poller[3];
  fprintf(stdout, "スキャンディレクトリ\n> ");
  fgets(path, sizeof(path) / sizeof(path[0]), stdin);
  replTerm(path);
  fprintf(stdout, "スキャン間隔(分指定,最大60分)\n> ");
  fgets(poller, sizeof(poller) / sizeof(poller[0]), stdin);
  replTerm(poller);
  fprintf(stdout, "スキャンディレクトリ：%s\n", path);
  fprintf(stdout, "スキャン間隔：%s\n", poller);
  exit(0);
}


x86 assembly (clang, -O0):
<scanConfig>:
push   %rbp
mov    %rsp,%rbp
sub    $0x410,%rsp
mov    0x2e86(%rip),%rax
mov    (%rax),%edi
lea    0xea5(%rip),%rsi
mov    $0x0,%al
call   1050 <fprintf@plt>
lea    -0x400(%rbp),%rdi
mov    0x2e78(%rip),%rax
mov    (%rax),%edx
mov    $0x400,%esi
call   1030 <fgets@plt>
lea    -0x400(%rbp),%rdi
call   1040 <replTerm@plt>
mov    0x2e49(%rip),%rax
mov    (%rax),%edi
lea    0xe8a(%rip),%rsi
mov    $0x0,%al
call   1050 <fprintf@plt>
lea    -0x403(%rbp),%rdi
mov    0x2e3b(%rip),%rax
mov    (%rax),%edx
mov    $0x3,%esi
call   1030 <fgets@plt>
lea    -0x403(%rbp),%rdi
call   1040 <replTerm@plt>
mov    0x2e0c(%rip),%rax
mov    (%rax),%edi
lea    -0x400(%rbp),%rdx
lea    0xe73(%rip),%rsi
mov    $0x0,%al
call   1050 <fprintf@plt>
mov    0x2dee(%rip),%rax
mov    (%rax),%edi
lea    -0x403(%rbp),%rdx
lea    0xe7a(%rip),%rsi
mov    $0x0,%al
call   1050 <fprintf@plt>
xor    %edi,%edi
call   1060 <exit@plt>

x86 assembly (clang, -O2):
<scanConfig>:
push   %r15
push   %r14
push   %rbx
sub    $0x410,%rsp
mov    0x2e85(%rip),%r15
mov    (%r15),%edi
lea    0xea3(%rip),%rsi
xor    %eax,%eax
call   1050 <fprintf@plt>
mov    0x2e7d(%rip),%rbx
mov    (%rbx),%edx
lea    0x10(%rsp),%r14
mov    %r14,%rdi
mov    $0x400,%esi
call   1030 <fgets@plt>
mov    %r14,%rdi
call   1040 <replTerm@plt>
mov    (%r15),%edi
lea    0xe91(%rip),%rsi
xor    %eax,%eax
call   1050 <fprintf@plt>
mov    (%rbx),%edx
lea    0xd(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x3,%esi
call   1030 <fgets@plt>
mov    %rbx,%rdi
call   1040 <replTerm@plt>
mov    (%r15),%edi
lea    0xe91(%rip),%rsi
mov    %r14,%rdx
xor    %eax,%eax
call   1050 <fprintf@plt>
mov    (%r15),%edi
lea    0xea2(%rip),%rsi
mov    %rbx,%rdx
xor    %eax,%eax
call   1050 <fprintf@plt>
xor    %edi,%edi
call   1060 <exit@plt>

LLVM IR (-O0):
@stdout = global i32 0
@.str = [34 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E3\83\87\E3\82\A3\E3\83\AC\E3\82\AF\E3\83\88\E3\83\AA\0A> \00"
@stdin = global i32 0
@.str.1 = [45 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E9\96\93\E9\9A\94(\E5\88\86\E6\8C\87\E5\AE\9A,\E6\9C\80\E5\A4\A760\E5\88\86)\0A> \00"
@.str.2 = [37 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E3\83\87\E3\82\A3\E3\83\AC\E3\82\AF\E3\83\88\E3\83\AA\EF\BC\9A%s\0A\00"
@.str.3 = [25 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E9\96\93\E9\9A\94\EF\BC\9A%s\0A\00"
define void @scanConfig() {
%1 = alloca [1024 x i8]
%2 = alloca [3 x i8]
%3 = load i32, i32* @stdout
%4 = call i32 (i32, i8*, ...) @fprintf(i32 %3, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0))
%5 = getelementptr inbounds [1024 x i8], [1024 x i8]* %1, i64 0, i64 0
%6 = load i32, i32* @stdin
%7 = call i32 @fgets(i8* %5, i32 1024, i32 %6)
%8 = getelementptr inbounds [1024 x i8], [1024 x i8]* %1, i64 0, i64 0
%9 = call i32 @replTerm(i8* %8)
%10 = load i32, i32* @stdout
%11 = call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.1, i64 0, i64 0))
%12 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%13 = load i32, i32* @stdin
%14 = call i32 @fgets(i8* %12, i32 3, i32 %13)
%15 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%16 = call i32 @replTerm(i8* %15)
%17 = load i32, i32* @stdout
%18 = getelementptr inbounds [1024 x i8], [1024 x i8]* %1, i64 0, i64 0
%19 = call i32 (i32, i8*, ...) @fprintf(i32 %17, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0), i8* %18)
%20 = load i32, i32* @stdout
%21 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%22 = call i32 (i32, i8*, ...) @fprintf(i32 %20, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.3, i64 0, i64 0), i8* %21)
%23 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [34 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E3\83\87\E3\82\A3\E3\83\AC\E3\82\AF\E3\83\88\E3\83\AA\0A> \00"
@stdin = global i32 0
@.str.1 = [45 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E9\96\93\E9\9A\94(\E5\88\86\E6\8C\87\E5\AE\9A,\E6\9C\80\E5\A4\A760\E5\88\86)\0A> \00"
@.str.2 = [37 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E3\83\87\E3\82\A3\E3\83\AC\E3\82\AF\E3\83\88\E3\83\AA\EF\BC\9A%s\0A\00"
@.str.3 = [25 x i8] c"\E3\82\B9\E3\82\AD\E3\83\A3\E3\83\B3\E9\96\93\E9\9A\94\EF\BC\9A%s\0A\00"
define void @scanConfig() {
%1 = alloca [1024 x i8]
%2 = alloca [3 x i8]
%3 = getelementptr inbounds [1024 x i8], [1024 x i8]* %1, i64 0, i64 0
%4 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%5 = load i32, i32* @stdout
%6 = tail call i32 (i32, i8*, ...) @fprintf(i32 %5, i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str, i64 0, i64 0))
%7 = load i32, i32* @stdin
%8 = call i32 @fgets(i8* %3, i32 1024, i32 %7)
%9 = call i32 @replTerm(i8* %3)
%10 = load i32, i32* @stdout
%11 = call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.1, i64 0, i64 0))
%12 = load i32, i32* @stdin
%13 = call i32 @fgets(i8* %4, i32 3, i32 %12)
%14 = call i32 @replTerm(i8* %4)
%15 = load i32, i32* @stdout
%16 = call i32 (i32, i8*, ...) @fprintf(i32 %15, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0), i8* %3)
%17 = load i32, i32* @stdout
%18 = call i32 (i32, i8*, ...) @fprintf(i32 %17, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.3, i64 0, i64 0), i8* %4)
%19 = call i32 @exit(i32 0)
unreachable
}