-
-
Save faried/1de5a26447c38d72e0d5 to your computer and use it in GitHub Desktop.
hacks i needed to compile goo on a 32-bit ubuntu 12.04 system
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/c/g2c/goo/boot.c b/c/g2c/goo/boot.c | |
index 6fec110..3dc4c0d 100644 | |
--- a/c/g2c/goo/boot.c | |
+++ b/c/g2c/goo/boot.c | |
@@ -986,7 +986,7 @@ P YPallocate_stack(P num_) { | |
P retF1; | |
P T0,T1,T2,T3; | |
DEFCREGS(); | |
- (P)YPdef_regs(); | |
+ YPdef_regs(); | |
T3 = (P)YPsp_reg(); | |
retF1 = T3; | |
T1 = (P)YPsp_reg(); | |
@@ -6761,7 +6761,7 @@ P YPcons_args() { | |
P nF692; | |
P T0,T1,T2,T3,T4,T5,T6,T7,T8,T9; | |
DEFCREGS(); | |
- (P)YPdef_regs(); | |
+ YPdef_regs(); | |
T9 = (P)YPsp_elt((P)-2); | |
nF692 = T9; | |
T8 = (P)YPi_((P)-2,nF692); | |
@@ -6961,7 +6961,7 @@ P YPfun_val_check_type(P regs_,P res_,P fn_) { | |
P T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15; | |
P T16,T17,T18,T19,T20,T21,T22,T23,T24,T25,T26,T27,T28; | |
DEFCREGS(); | |
- (P)YPset_regs(regs_); | |
+ YPset_regs(regs_); | |
xF724 = fn_; | |
T28 = (P)YPprop_elt(xF724,(P)1); | |
xF725 = T28; | |
@@ -7061,7 +7061,7 @@ P YPcheck_type(P regs_,P res_,P type_) { | |
P T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15; | |
P T16,T17,T18,T19,T20,T21,T22,T23,T24,T25; | |
DEFCREGS(); | |
- (P)YPset_regs(regs_); | |
+ YPset_regs(regs_); | |
if (VARREF(YPclasses_readyQ) != YPfalse) { | |
oF747 = res_; | |
tF748 = type_; | |
@@ -7134,7 +7134,7 @@ DEFCREGS(); | |
INLINE P YPstack_check(P regs_) { | |
P T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15; | |
DEFCREGS(); | |
- (P)YPset_regs(regs_); | |
+ YPset_regs(regs_); | |
T4 = (P)YPmax_stack_len(); | |
T3 = (P)YPi_(T4,(P)1000); | |
T6 = (P)YPsp_reg(); | |
@@ -7202,7 +7202,7 @@ P YPPcheck_call_types(P regs_) { | |
P T16,T17,T18,T19,T20,T21,T22,T23,T24,T25,T26,T27,T28,T29,T30,T31; | |
P T32,T33,T34,T35,T36,T37,T38,T39,T40,T41,T42,T43; | |
DEFCREGS(); | |
- (P)YPset_regs(regs_); | |
+ YPset_regs(regs_); | |
T43 = (P)YPsp_elt((P)-1); | |
fnF767 = T43; | |
xF768 = fnF767; | |
diff --git a/src/eval/g2c.goo b/src/eval/g2c.goo | |
index 6ff7a1c..5916ed4 100644 | |
--- a/src/eval/g2c.goo | |
+++ b/src/eval/g2c.goo | |
@@ -1002,7 +1002,11 @@ | |
(for ((arg (application-arguments e))) | |
(to-pc arg f d out)) | |
(with-expression (e d out) | |
- (msg* out "(P)%s" (mangle-binding (application-binding e))) | |
+ (def mangled (mangle-binding (application-binding e))) | |
+ (if (or (= mangled "YPdef_regs") | |
+ (= mangled "YPset_regs")) | |
+ (msg* out "%s" mangled) | |
+ (msg* out "(P)%s" mangled)) | |
(between-parentheses (out) | |
(for-commas out ((arg (application-arguments e))) | |
(gen-ref arg f d out))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment