int test_jnxsignal() {
  jnx_log(0,
          "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
          "2022-01-22/02-19-57/repos/AlexsJones/jnxlibc/refs/heads/master/test/"
          "unit/test_jnxsignal.c",
          __FUNCTION__, 157, "Testing signals and slots\n");
  ;
  simple_test();
  simple_threaded_test();
  dual_slot_test();
  cross_thread_slot_test();
  sleep(1);
  return 0;
}


x86 assembly (clang, -O0):
<test_jnxsignal>:
push   %rbp
mov    %rsp,%rbp
xor    %edi,%edi
lea    0xe93(%rip),%rsi
lea    0xf26(%rip),%rdx
mov    $0x9d,%ecx
lea    0xf29(%rip),%r8
mov    $0x0,%al
call   1050 <jnx_log@plt>
mov    $0x0,%al
call   1040 <simple_test@plt>
mov    $0x0,%al
call   1080 <simple_threaded_test@plt>
mov    $0x0,%al
call   1030 <dual_slot_test@plt>
mov    $0x0,%al
call   1060 <cross_thread_slot_test@plt>
mov    $0x1,%edi
mov    $0x0,%al
call   1070 <sleep@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_jnxsignal>:
push   %rax
lea    0xe98(%rip),%rsi
lea    0xf2b(%rip),%rdx
lea    0xf33(%rip),%r8
xor    %edi,%edi
mov    $0x9d,%ecx
xor    %eax,%eax
call   1050 <jnx_log@plt>
xor    %eax,%eax
call   1040 <simple_test@plt>
xor    %eax,%eax
call   1080 <simple_threaded_test@plt>
xor    %eax,%eax
call   1030 <dual_slot_test@plt>
xor    %eax,%eax
call   1060 <cross_thread_slot_test@plt>
mov    $0x1,%edi
xor    %eax,%eax
call   1070 <sleep@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [154 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AlexsJones/jnxlibc/refs/heads/master/test/unit/test_jnxsignal.c\00"
@__FUNCTION__.test_jnxsignal = [15 x i8] c"test_jnxsignal\00"
@.str.1 = [27 x i8] c"Testing signals and slots\0A\00"
define i32 @test_jnxsignal() {
%1 = call i32 (i32, i8*, i8*, i32, i8*, ...) bitcast (i32 (...)* @jnx_log to i32 (i32, i8*, i8*, i32, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([154 x i8], [154 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @__FUNCTION__.test_jnxsignal, i64 0, i64 0), i32 157, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
%2 = call i32 (...) @simple_test()
%3 = call i32 (...) @simple_threaded_test()
%4 = call i32 (...) @dual_slot_test()
%5 = call i32 (...) @cross_thread_slot_test()
%6 = call i32 (i32, ...) bitcast (i32 (...)* @sleep to i32 (i32, ...)*)(i32 1)
ret i32 0
}

LLVM IR (-O2):
@.str = [154 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/AlexsJones/jnxlibc/refs/heads/master/test/unit/test_jnxsignal.c\00"
@__FUNCTION__.test_jnxsignal = [15 x i8] c"test_jnxsignal\00"
@.str.1 = [27 x i8] c"Testing signals and slots\0A\00"
define i32 @test_jnxsignal() {
%1 = tail call i32 (i32, i8*, i8*, i32, i8*, ...) bitcast (i32 (...)* @jnx_log to i32 (i32, i8*, i8*, i32, i8*, ...)*)(i32 0, i8* getelementptr inbounds ([154 x i8], [154 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @__FUNCTION__.test_jnxsignal, i64 0, i64 0), i32 157, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 (...) @simple_test()
%3 = tail call i32 (...) @simple_threaded_test()
%4 = tail call i32 (...) @dual_slot_test()
%5 = tail call i32 (...) @cross_thread_slot_test()
%6 = tail call i32 (i32, ...) bitcast (i32 (...)* @sleep to i32 (i32, ...)*)(i32 1)
ret i32 0
}