Created
October 5, 2009 01:44
-
-
Save torus/201746 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/back.scm b/back.scm | |
index 138e882..55f1d07 100644 | |
--- a/back.scm | |
+++ b/back.scm | |
@@ -362,7 +362,7 @@ | |
(instructions | |
`(movl ap ,target) | |
`(addl ,(* n ws) ap) | |
- `(cmpl heap_end ap) | |
+ `(cmpl _heap_end ap) | |
`(jbe ,dontlab) | |
(overflow n) | |
`(label ,dontlab)))) | |
@@ -384,7 +384,7 @@ | |
`(pushl 0) | |
(error "Error in cg-allocate: Not implemented")) | |
`(pushl sp) | |
- `(call gc_collect) | |
+ `(call _gc_collect) | |
`(addl ,(* 3 ws) sp) ; skip sp,usedregs,stack_end | |
`(popl cp) | |
`(popl ap) | |
diff --git a/call_scheme.s b/call_scheme.s | |
index b191260..de8e524 100644 | |
--- a/call_scheme.s | |
+++ b/call_scheme.s | |
@@ -1,15 +1,15 @@ | |
.data | |
- .global heap_end | |
-heap_end: | |
+ .globl _heap_end | |
+_heap_end: | |
.long 0 | |
.text | |
.code32 | |
.align 4 | |
- .global call_scheme | |
-call_scheme: | |
+ .globl _call_scheme | |
+_call_scheme: | |
movl %esp, %eax | |
pushl %ebx | |
pushl %esi | |
diff --git a/emu.scm b/emu.scm | |
index 0542656..c3a3365 100644 | |
--- a/emu.scm | |
+++ b/emu.scm | |
@@ -58,7 +58,7 @@ | |
(cdr rands)))) | |
(printf "\t.code32\n") | |
(printf "\t.align 4\n") | |
- (printf "\t.global _scheme_entry\n") | |
+ (printf "\t.globl _scheme_entry\n") | |
(let loop ([ls (cdr ls)]) | |
(unless (null? ls) | |
(let ([inst (car ls)]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment