diff --git a/examples/array/.build/out.asm b/examples/array/.build/out.asm deleted file mode 100644 index 89bcb17..0000000 --- a/examples/array/.build/out.asm +++ /dev/null @@ -1,79 +0,0 @@ -.text -.cstring_len: - pushq %rbp - movq %rsp, %rbp - movl $0, %eax -.Lbb2: - movzbl (%rdi, %rax, 1), %ecx - cmpl $0, %ecx - jz .Lbb4 - addq $1, %rax - jmp .Lbb2 -.Lbb4: - leave - ret -.type .cstring_len, @function -.size .cstring_len, .-.cstring_len -/* end function .cstring_len */ - -.text -.memcpy: - pushq %rbp - movq %rsp, %rbp - movl $0, %eax -.Lbb7: - cmpq %rdx, %rax - jae .Lbb9 - movzbl (%rdi, %rax, 1), %ecx - movb %cl, (%rsi, %rax, 1) - addq $1, %rax - jmp .Lbb7 -.Lbb9: - leave - ret -.type .memcpy, @function -.size .memcpy, .-.memcpy -/* end function .memcpy */ - -.text -.memset: - pushq %rbp - movq %rsp, %rbp - movl $0, %eax -.Lbb12: - cmpq %rdx, %rax - jae .Lbb14 - movb %sil, (%rdi, %rax, 1) - addq $1, %rax - jmp .Lbb12 -.Lbb14: - leave - ret -.type .memset, @function -.size .memset, .-.memset -/* end function .memset */ - -.text -.array_size: - pushq %rbp - movq %rsp, %rbp - movq (%rdi), %rax - leave - ret -.type .array_size, @function -.size .array_size, .-.array_size -/* end function .array_size */ - -.text -.globl main -main: - pushq %rbp - movq %rsp, %rbp - movl $0, %eax - leave - ret -.type main, @function -.size main, .-main -/* end function main */ - -.section .note.GNU-stack,"",@progbits diff --git a/examples/array/.build/out.o b/examples/array/.build/out.o deleted file mode 100644 index 8e945ec..0000000 Binary files a/examples/array/.build/out.o and /dev/null differ diff --git a/examples/array/.build/out.ssa b/examples/array/.build/out.ssa deleted file mode 100644 index c647a88..0000000 --- a/examples/array/.build/out.ssa +++ /dev/null @@ -1,65 +0,0 @@ -# ========== Builtin functions ========== -function l $.cstring_len(l %str) { -@start - %count =l copy 0 -@loop - %address =l add %str, %count - %value =w loadub %address - jnz %value, @continue, @end -@continue - %count =l add %count, 1 - jmp @loop -@end - ret %count -} - -function $.memcpy(l %source, l %destination, l %length) { -@start - %count =l copy 0 -@loop - %condition =w cultl %count, %length - jnz %condition, @continue, @end -@continue - %source_address =l add %source, %count - %destination_address =l add %destination, %count - %value =w loadub %source_address - storeb %value, %destination_address - %count =l add %count, 1 - jmp @loop -@end - ret -} - -function $.memset(l %destination, l %value, l %length) { -@start - %count =l copy 0 -@loop - %condition =w cultl %count, %length - jnz %condition, @continue, @end -@continue - %destination_address =l add %destination, %count - storeb %value, %destination_address - %count =l add %count, 1 - jmp @loop -@end - ret -} - -function l $.array_size(l %array) { -@start - %size =l loadl %array - ret %size -} - -# ========== Referenced structs ========== - -# ========== Struct definitions ========== -# ========== Function definitions ========== -export function l $main(l %args) { -@start - ret 0 -} - -# ========== cstring literals ========== - -# ========== string literals ========== diff --git a/examples/array/out b/examples/array/out deleted file mode 100755 index 9c0edeb..0000000 Binary files a/examples/array/out and /dev/null differ