#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*/ chaz_ConfWriter_append_conf(char *);
int /*<<< orphan*/ chaz_ConfWriter_end_module();
int /*<<< orphan*/ chaz_ConfWriter_end_short_names();
int /*<<< orphan*/ chaz_ConfWriter_shorten_macro(char *);
int /*<<< orphan*/ chaz_ConfWriter_start_module(char *);
int /*<<< orphan*/ chaz_ConfWriter_start_short_names();
void chaz_UnusedVars_run(void) {
  chaz_ConfWriter_start_module("UnusedVars");
  chaz_ConfWriter_append_conf("#define CHY_UNUSED_VAR(x) ((void)x)\n");
  chaz_ConfWriter_append_conf(
      "#define CHY_UNREACHABLE_RETURN(type) return (type)0\n");
  chaz_ConfWriter_start_short_names();
  chaz_ConfWriter_shorten_macro("UNUSED_VAR");
  chaz_ConfWriter_shorten_macro("UNREACHABLE_RETURN");
  chaz_ConfWriter_end_short_names();
  chaz_ConfWriter_end_module();
}


x86 assembly (clang, -O0):
<chaz_UnusedVars_run>:
push   %rbp
mov    %rsp,%rbp
lea    0xe95(%rip),%rdi
call   1030 <chaz_ConfWriter_start_module@plt>
lea    0xe94(%rip),%rdi
call   1040 <chaz_ConfWriter_append_conf@plt>
lea    0xead(%rip),%rdi
call   1040 <chaz_ConfWriter_append_conf@plt>
mov    $0x0,%al
call   1080 <chaz_ConfWriter_start_short_names@plt>
lea    0xecf(%rip),%rdi
call   1050 <chaz_ConfWriter_shorten_macro@plt>
lea    0xece(%rip),%rdi
call   1050 <chaz_ConfWriter_shorten_macro@plt>
mov    $0x0,%al
call   1060 <chaz_ConfWriter_end_short_names@plt>
mov    $0x0,%al
call   1070 <chaz_ConfWriter_end_module@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<chaz_UnusedVars_run>:
push   %rax
lea    0xe98(%rip),%rdi
call   1030 <chaz_ConfWriter_start_module@plt>
lea    0xe97(%rip),%rdi
call   1040 <chaz_ConfWriter_append_conf@plt>
lea    0xeb0(%rip),%rdi
call   1040 <chaz_ConfWriter_append_conf@plt>
xor    %eax,%eax
call   1080 <chaz_ConfWriter_start_short_names@plt>
lea    0xed2(%rip),%rdi
call   1050 <chaz_ConfWriter_shorten_macro@plt>
lea    0xed1(%rip),%rdi
call   1050 <chaz_ConfWriter_shorten_macro@plt>
xor    %eax,%eax
call   1060 <chaz_ConfWriter_end_short_names@plt>
xor    %eax,%eax
pop    %rcx
jmp    1070 <chaz_ConfWriter_end_module@plt>

LLVM IR (-O0):
@.str = [11 x i8] c"UnusedVars\00"
@.str.1 = [37 x i8] c"#define CHY_UNUSED_VAR(x) ((void)x)\0A\00"
@.str.2 = [53 x i8] c"#define CHY_UNREACHABLE_RETURN(type) return (type)0\0A\00"
@.str.3 = [11 x i8] c"UNUSED_VAR\00"
@.str.4 = [19 x i8] c"UNREACHABLE_RETURN\00"
define void @chaz_UnusedVars_run() {
%1 = call i32 @chaz_ConfWriter_start_module(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @chaz_ConfWriter_append_conf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @chaz_ConfWriter_append_conf(i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 (...) @chaz_ConfWriter_start_short_names()
%5 = call i32 @chaz_ConfWriter_shorten_macro(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0))
%6 = call i32 @chaz_ConfWriter_shorten_macro(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%7 = call i32 (...) @chaz_ConfWriter_end_short_names()
%8 = call i32 (...) @chaz_ConfWriter_end_module()
ret void
}

LLVM IR (-O2):
@.str = [11 x i8] c"UnusedVars\00"
@.str.1 = [37 x i8] c"#define CHY_UNUSED_VAR(x) ((void)x)\0A\00"
@.str.2 = [53 x i8] c"#define CHY_UNREACHABLE_RETURN(type) return (type)0\0A\00"
@.str.3 = [11 x i8] c"UNUSED_VAR\00"
@.str.4 = [19 x i8] c"UNREACHABLE_RETURN\00"
define void @chaz_UnusedVars_run() {
%1 = tail call i32 @chaz_ConfWriter_start_module(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @chaz_ConfWriter_append_conf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @chaz_ConfWriter_append_conf(i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 (...) @chaz_ConfWriter_start_short_names()
%5 = tail call i32 @chaz_ConfWriter_shorten_macro(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0))
%6 = tail call i32 @chaz_ConfWriter_shorten_macro(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%7 = tail call i32 (...) @chaz_ConfWriter_end_short_names()
%8 = tail call i32 (...) @chaz_ConfWriter_end_module()
ret void
}