// File: /workspace/github_c_makefile_star2_O0/creationix[P]color-control/src/compile.c
// Function: generate_number
static void generate_number(uint32_t num) {
  // fprintf(stderr, "Generate Num %u - %08x\n", num, num);
  if (num < 0x80) {
    pushchar((char)num);
  }
  else if (num < 0x100) {
    pushchar(UINT8);
    pushchar(num);
  }
  else if (num < 0x10000) {
    pushchar(UINT16);
    pushchar(num >> 8);
    pushchar(num);
  }
  else if (num < 0x1000000) {
    pushchar(UINT24);
    pushchar(num >> 16);
    pushchar(num >> 8);
    pushchar(num);
  }
  else {
    pushchar(UINT32);
    pushchar(num >> 24);
    pushchar(num >> 16);
    pushchar(num >> 8);
    pushchar(num);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
cmpl $0x80, -0x4(%rbp)
jae 0xfa9e
movl -0x4(%rbp), %eax
movb %al, %dl
movw 0x7744(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7736(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x781a(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
jmp 0xfd12
cmpl $0x100, -0x4(%rbp)      # imm = 0x100
jae 0xfafa
movw 0x7712(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7704(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x77e8(%rip), %rax      # 0x172b0
movb $-0x80, (%rax,%rcx)
movl -0x4(%rbp), %eax
movb %al, %dl
movw 0x76e8(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x76da(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x77be(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
jmp 0xfd10
cmpl $0x10000, -0x4(%rbp)    # imm = 0x10000
jae 0xfb82
movw 0x76b6(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x76a8(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x778c(%rip), %rax      # 0x172b0
movb $-0x7f, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x8, %eax
movb %al, %dl
movw 0x7689(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x767b(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x775f(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
movb %al, %dl
movw 0x7660(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7652(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x7736(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
jmp 0xfd0e
cmpl $0x1000000, -0x4(%rbp)  # imm = 0x1000000
jae 0xfc3a
movw 0x762a(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x761c(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x7700(%rip), %rax      # 0x172b0
movb $-0x7e, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x10, %eax
movb %al, %dl
movw 0x75fd(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x75ef(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x76d3(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x8, %eax
movb %al, %dl
movw 0x75d1(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x75c3(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x76a7(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
movb %al, %dl
movw 0x75a8(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x759a(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x767e(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
jmp 0xfd0c
movw 0x757f(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7571(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x7655(%rip), %rax      # 0x172b0
movb $-0x7d, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x18, %eax
movb %al, %dl
movw 0x7552(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7544(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x7628(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x10, %eax
movb %al, %dl
movw 0x7526(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x7518(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x75fc(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
shrl $0x8, %eax
movb %al, %dl
movw 0x74fa(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x74ec(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x75d0(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
movl -0x4(%rbp), %eax
movb %al, %dl
movw 0x74d1(%rip), %ax       # 0x171c0
movw %ax, %cx
addw $0x1, %cx
movw %cx, 0x74c3(%rip)       # 0x171c0
movzwl %ax, %eax
movl %eax, %ecx
leaq 0x75a7(%rip), %rax      # 0x172b0
movb %dl, (%rax,%rcx)
jmp 0xfd0e
jmp 0xfd10
jmp 0xfd12
popq %rbp
retq
nopw %cs:(%rax,%rax)