#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 */
int /*<<< orphan*/ del_DFA_by_name(char *);
int /*<<< orphan*/ fgets_eof(char *, int);
int /*<<< orphan*/ find_DFA_by_name(char *);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ puts(char *);
void del_node() {
  char linebuf[0x100];
  printf("name of node: ");
  fgets_eof(linebuf, 0x100);
  if (!find_DFA_by_name(linebuf)) {
    puts("can't find node");
    return;
  }
  del_DFA_by_name(linebuf);
  puts("del successful\n");
  return;
}


x86 assembly (clang, -O0):
<del_node>:
push   %rbp
mov    %rsp,%rbp
sub    $0x100,%rsp
lea    0xe9e(%rip),%rdi
call   1040 <printf@plt>
lea    -0x100(%rbp),%rdi
mov    $0x100,%esi
call   1060 <fgets_eof@plt>
lea    -0x100(%rbp),%rdi
call   1050 <find_DFA_by_name@plt>
cmp    $0x0,%eax
jne    119e <del_node+0x4e>
lea    0xe7b(%rip),%rdi
call   1030 <puts@plt>
jmp    11b6 <del_node+0x66>
lea    -0x100(%rbp),%rdi
call   1070 <del_DFA_by_name@plt>
lea    0xe6e(%rip),%rdi
call   1030 <puts@plt>
add    $0x100,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<del_node>:
push   %rbx
sub    $0x100,%rsp
lea    0xea1(%rip),%rdi
call   1040 <printf@plt>
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0x100,%esi
call   1060 <fgets_eof@plt>
mov    %rbx,%rdi
call   1050 <find_DFA_by_name@plt>
test   %eax,%eax
je     1191 <del_node+0x41>
mov    %rsp,%rdi
call   1070 <del_DFA_by_name@plt>
lea    0xe90(%rip),%rdi
jmp    1198 <del_node+0x48>
lea    0xe77(%rip),%rdi
call   1030 <puts@plt>
add    $0x100,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [15 x i8] c"name of node: \00"
@.str.1 = [16 x i8] c"can't find node\00"
@.str.2 = [16 x i8] c"del successful\0A\00"
define void @del_node() {
%1 = alloca [256 x i8]
%2 = call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%3 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%4 = call i32 @fgets_eof(i8* %3, i32 256)
%5 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%6 = call i32 @find_DFA_by_name(i8* %5)
%7 = icmp ne i32 %6, 0
br i1 %7, label %10, label %8
8: ; preds = %0
%9 = call i32 @puts(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0))
br label %14
10: ; preds = %0
%11 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%12 = call i32 @del_DFA_by_name(i8* %11)
%13 = call i32 @puts(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0))
br label %14
14: ; preds = %10, %8
ret void
}

LLVM IR (-O2):
@.str = [15 x i8] c"name of node: \00"
@.str.1 = [16 x i8] c"can't find node\00"
@.str.2 = [16 x i8] c"del successful\0A\00"
define void @del_node() {
%1 = alloca [256 x i8]
%2 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%3 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @fgets_eof(i8* %2, i32 256)
%5 = call i32 @find_DFA_by_name(i8* %2)
%6 = icmp eq i32 %5, 0
br i1 %6, label %9, label %7
7: ; preds = %0
%8 = call i32 @del_DFA_by_name(i8* %2)
br label %9
9: ; preds = %0, %7
%10 = phi i8* [ getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), %7 ], [ getelementptr inbounds ([16 x i8], [16 x i8]* @.str.1, i64 0, i64 0), %0 ]
%11 = call i32 @puts(i8* dereferenceable(1) %10)
ret void
}