void def_instantiated_output(struct cnode *cnode, unsigned int indent) {
  printf("%*s<def-instantiated>\n", indent, "");
  printf("%*s<descriptive>\n", indent + 2, "");
  outputchildren(cnode, indent + 2, 0);
  printf("%*s</descriptive>\n", indent + 2, "");
  printf("%*s</def-instantiated>\n", indent, "");
}


x86 assembly (clang, -O0):
<def_instantiated_output>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%esi
lea    0xec7(%rip),%rdi
lea    0xf13(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%esi
add    $0x2,%esi
lea    0xec3(%rip),%rdi
lea    0xef8(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%rdi
mov    -0xc(%rbp),%esi
add    $0x2,%esi
xor    %edx,%edx
mov    $0x0,%al
call   1040 <outputchildren@plt>
mov    -0xc(%rbp),%esi
add    $0x2,%esi
lea    0xea7(%rip),%rdi
lea    0xeca(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%esi
lea    0xea2(%rip),%rdi
lea    0xeb2(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<def_instantiated_output>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %esi,%ebx
mov    %rdi,%r15
lea    0xecd(%rip),%rdi
lea    0xf19(%rip),%r14
mov    %r14,%rdx
xor    %eax,%eax
call   1030 <printf@plt>
lea    0x2(%rbx),%ebp
lea    0xec9(%rip),%rdi
mov    %ebp,%esi
mov    %r14,%rdx
xor    %eax,%eax
call   1030 <printf@plt>
mov    %r15,%rdi
mov    %ebp,%esi
xor    %edx,%edx
xor    %eax,%eax
call   1040 <outputchildren@plt>
lea    0xeba(%rip),%rdi
mov    %ebp,%esi
mov    %r14,%rdx
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xeba(%rip),%rdi
mov    %ebx,%esi
mov    %r14,%rdx
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <printf@plt>

LLVM IR (-O0):
%struct.cnode = type opaque
@.str = [23 x i8] c"%*s<def-instantiated>\0A\00"
@.str.1 = [1 x i8] zeroinitializer
@.str.2 = [18 x i8] c"%*s<descriptive>\0A\00"
@.str.3 = [19 x i8] c"%*s</descriptive>\0A\00"
@.str.4 = [24 x i8] c"%*s</def-instantiated>\0A\00"
define void @def_instantiated_output(%struct.cnode* %0, i32 %1) {
%3 = alloca %struct.cnode*
%4 = alloca i32
store %struct.cnode* %0, %struct.cnode** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0), i32 %5, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%7 = load i32, i32* %4
%8 = add i32 %7, 2
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 %8, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%10 = load %struct.cnode*, %struct.cnode** %3
%11 = load i32, i32* %4
%12 = add i32 %11, 2
%13 = call i32 (%struct.cnode*, i32, i32, ...) bitcast (i32 (...)* @outputchildren to i32 (%struct.cnode*, i32, i32, ...)*)(%struct.cnode* %10, i32 %12, i32 0)
%14 = load i32, i32* %4
%15 = add i32 %14, 2
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), i32 %15, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%17 = load i32, i32* %4
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), i32 %17, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
%struct.cnode = type opaque
@.str = [23 x i8] c"%*s<def-instantiated>\0A\00"
@.str.1 = [1 x i8] zeroinitializer
@.str.2 = [18 x i8] c"%*s<descriptive>\0A\00"
@.str.3 = [19 x i8] c"%*s</descriptive>\0A\00"
@.str.4 = [24 x i8] c"%*s</def-instantiated>\0A\00"
define void @def_instantiated_output(%struct.cnode* %0, i32 %1) {
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i64 0, i64 0), i32 %1, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%4 = add i32 %1, 2
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i32 %4, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%6 = tail call i32 (%struct.cnode*, i32, i32, ...) bitcast (i32 (...)* @outputchildren to i32 (%struct.cnode*, i32, i32, ...)*)(%struct.cnode* %0, i32 %4, i32 0)
%7 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.3, i64 0, i64 0), i32 %4, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @.str.4, i64 0, i64 0), i32 %1, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.1, i64 0, i64 0))
ret void
}