#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*/ first_element_artist(char *);
int /*<<< orphan*/ free_list();
int /*<<< orphan*/ populate();
int /*<<< orphan*/ print_entries_all();
int /*<<< orphan*/ print_node(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *);
void test_first_element_artist() {
  printf(
      "====================================================================\n");
  printf("TESTING FIRST ELEMENT ARTIST...\n");
  populate();
  print_node(first_element_artist("donny osmond"));
  print_node(first_element_artist("taylor swift"));
  print_node(first_element_artist("lin manuel miranda"));
  print_node(first_element_artist("sia"));
  print_node(first_element_artist("t"));
  print_node(first_element_artist("against the current"));
  print_entries_all();
  free_list();
  print_entries_all();
}


x86 assembly (clang, -O0):
<test_first_element_artist>:
push   %rbp
mov    %rsp,%rbp
lea    0xe95(%rip),%rdi
call   1040 <printf@plt>
lea    0xecf(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1050 <populate@plt>
lea    0xedd(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xed7(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xed1(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xed1(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xea9(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xeaf(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
mov    $0x0,%al
call   1030 <print_entries_all@plt>
mov    $0x0,%al
call   1060 <free_list@plt>
mov    $0x0,%al
call   1030 <print_entries_all@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_first_element_artist>:
push   %rax
lea    0xedd(%rip),%rdi
call   1030 <puts@plt>
lea    0xf16(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
call   1050 <populate@plt>
lea    0xe79(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xe73(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xe6d(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xe6d(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xe45(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
lea    0xe4b(%rip),%rdi
call   1070 <first_element_artist@plt>
mov    %eax,%edi
call   1080 <print_node@plt>
xor    %eax,%eax
call   1040 <print_entries_all@plt>
xor    %eax,%eax
call   1060 <free_list@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <print_entries_all@plt>

LLVM IR (-O0):
@.str = [70 x i8] c"====================================================================\0A\00"
@.str.1 = [33 x i8] c"TESTING FIRST ELEMENT ARTIST...\0A\00"
@.str.2 = [13 x i8] c"donny osmond\00"
@.str.3 = [13 x i8] c"taylor swift\00"
@.str.4 = [19 x i8] c"lin manuel miranda\00"
@.str.5 = [4 x i8] c"sia\00"
@.str.6 = [2 x i8] c"t\00"
@.str.7 = [20 x i8] c"against the current\00"
define void @test_first_element_artist() {
%1 = call i32 @printf(i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 (...) @populate()
%4 = call i32 @first_element_artist(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0))
%5 = call i32 @print_node(i32 %4)
%6 = call i32 @first_element_artist(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0))
%7 = call i32 @print_node(i32 %6)
%8 = call i32 @first_element_artist(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%9 = call i32 @print_node(i32 %8)
%10 = call i32 @first_element_artist(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%11 = call i32 @print_node(i32 %10)
%12 = call i32 @first_element_artist(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
%13 = call i32 @print_node(i32 %12)
%14 = call i32 @first_element_artist(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.7, i64 0, i64 0))
%15 = call i32 @print_node(i32 %14)
%16 = call i32 (...) @print_entries_all()
%17 = call i32 (...) @free_list()
%18 = call i32 (...) @print_entries_all()
ret void
}

LLVM IR (-O2):
@.str.2 = [13 x i8] c"donny osmond\00"
@.str.3 = [13 x i8] c"taylor swift\00"
@.str.4 = [19 x i8] c"lin manuel miranda\00"
@.str.5 = [4 x i8] c"sia\00"
@.str.6 = [2 x i8] c"t\00"
@.str.7 = [20 x i8] c"against the current\00"
@str = [69 x i8] c"====================================================================\00"
@str.8 = [32 x i8] c"TESTING FIRST ELEMENT ARTIST...\00"
define void @test_first_element_artist() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([69 x i8], [69 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.8, i64 0, i64 0))
%3 = tail call i32 (...) @populate()
%4 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0))
%5 = tail call i32 @print_node(i32 %4)
%6 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0))
%7 = tail call i32 @print_node(i32 %6)
%8 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%9 = tail call i32 @print_node(i32 %8)
%10 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0))
%11 = tail call i32 @print_node(i32 %10)
%12 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
%13 = tail call i32 @print_node(i32 %12)
%14 = tail call i32 @first_element_artist(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.7, i64 0, i64 0))
%15 = tail call i32 @print_node(i32 %14)
%16 = tail call i32 (...) @print_entries_all()
%17 = tail call i32 (...) @free_list()
%18 = tail call i32 (...) @print_entries_all()
ret void
}