// File: Silica[P]PSL/./PSL/pstring.h
// Function: PSL::variable::string::sethex(unsigned long, unsigned long)
void sethex(unsigned long i, size_t c = 0)
	{
		char *b = buf->buffer();
		#define C(n) if (i >= n){char a = (char)((i/n)&0xF);b[c++] = (char)(a<10 ? a+ZERO : a-10+'A');}
		C(0x10000000)
		C(0x1000000)
		C(0x100000)
		C(0x10000)
		C(0x1000)
		C(0x100)
		C(0x10)
		#undef C
		{char a = (char)(i&0xF);b[c++] = (char)(a<10 ? a+ZERO : a-10+'A');}
		buf->setlen(c);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x30(%rbp)
movq (%rax), %rdi
callq 0x13b70
movq %rax, -0x20(%rbp)
cmpq $0x10000000, -0x10(%rbp) # imm = 0x10000000
jb 0x1434e
movq -0x10(%rbp), %rax
shrq $0x1c, %rax
andq $0xf, %rax
movb %al, -0x21(%rbp)
movsbl -0x21(%rbp), %eax
cmpl $0xa, %eax
jge 0x14326
movsbl -0x21(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x34(%rbp)
jmp 0x14333
movsbl -0x21(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x1000000, -0x10(%rbp) # imm = 0x1000000
jb 0x143a4
movq -0x10(%rbp), %rax
shrq $0x18, %rax
andq $0xf, %rax
movb %al, -0x22(%rbp)
movsbl -0x22(%rbp), %eax
cmpl $0xa, %eax
jge 0x1437c
movsbl -0x22(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x38(%rbp)
jmp 0x14389
movsbl -0x22(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x38(%rbp)
movl -0x38(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x100000, -0x10(%rbp)  # imm = 0x100000
jb 0x143fa
movq -0x10(%rbp), %rax
shrq $0x14, %rax
andq $0xf, %rax
movb %al, -0x23(%rbp)
movsbl -0x23(%rbp), %eax
cmpl $0xa, %eax
jge 0x143d2
movsbl -0x23(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x3c(%rbp)
jmp 0x143df
movsbl -0x23(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x10000, -0x10(%rbp)   # imm = 0x10000
jb 0x14450
movq -0x10(%rbp), %rax
shrq $0x10, %rax
andq $0xf, %rax
movb %al, -0x24(%rbp)
movsbl -0x24(%rbp), %eax
cmpl $0xa, %eax
jge 0x14428
movsbl -0x24(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x40(%rbp)
jmp 0x14435
movsbl -0x24(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x40(%rbp)
movl -0x40(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x1000, -0x10(%rbp)    # imm = 0x1000
jb 0x144a6
movq -0x10(%rbp), %rax
shrq $0xc, %rax
andq $0xf, %rax
movb %al, -0x25(%rbp)
movsbl -0x25(%rbp), %eax
cmpl $0xa, %eax
jge 0x1447e
movsbl -0x25(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x44(%rbp)
jmp 0x1448b
movsbl -0x25(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x100, -0x10(%rbp)     # imm = 0x100
jb 0x144fc
movq -0x10(%rbp), %rax
shrq $0x8, %rax
andq $0xf, %rax
movb %al, -0x26(%rbp)
movsbl -0x26(%rbp), %eax
cmpl $0xa, %eax
jge 0x144d4
movsbl -0x26(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x48(%rbp)
jmp 0x144e1
movsbl -0x26(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x48(%rbp)
movl -0x48(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
cmpq $0x10, -0x10(%rbp)
jb 0x1454f
movq -0x10(%rbp), %rax
shrq $0x4, %rax
andq $0xf, %rax
movb %al, -0x27(%rbp)
movsbl -0x27(%rbp), %eax
cmpl $0xa, %eax
jge 0x14527
movsbl -0x27(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x4c(%rbp)
jmp 0x14534
movsbl -0x27(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x4c(%rbp)
movl -0x4c(%rbp), %eax
movb %al, %dl
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rcx
movq %rcx, %rsi
addq $0x1, %rsi
movq %rsi, -0x18(%rbp)
movb %dl, (%rax,%rcx)
movq -0x10(%rbp), %rax
andq $0xf, %rax
movb %al, -0x28(%rbp)
movsbl -0x28(%rbp), %eax
cmpl $0xa, %eax
jge 0x1456f
movsbl -0x28(%rbp), %eax
addl $0x30, %eax
movl %eax, -0x50(%rbp)
jmp 0x1457c
movsbl -0x28(%rbp), %eax
subl $0xa, %eax
addl $0x41, %eax
movl %eax, -0x50(%rbp)
movq -0x30(%rbp), %rax
movl -0x50(%rbp), %ecx
movb %cl, %sil
movq -0x20(%rbp), %rcx
movq -0x18(%rbp), %rdx
movq %rdx, %rdi
addq $0x1, %rdi
movq %rdi, -0x18(%rbp)
movb %sil, (%rcx,%rdx)
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
callq 0x13b90
addq $0x50, %rsp
popq %rbp
retq
nop