Hi,
I got stack over flow error when doing asdf:load-op cl-objc. I think I need your help.
I'm using SBCL 1.0.12.3 (the latest :) on OS X Leopard x86.
Here's the error message:
----------------------
Compiling CLOS bindings for Foundation framework in /Users/ huangjianshi/.sbcl/site/cl-objc/src/frameworks/Foundation-CLOS.lisp Control stack guard page temporarily disabled: proceed with caution
debugger invoked on a SB-KERNEL::CONTROL-STACK-EXHAUSTED in thread #<THREAD "initial thread" {13E43A59}>: Control stack exhausted (no more space for function call frames). This is probably due to heavily nested or infinitely recursive function calls, or a tail call that SBCL cannot or has not optimized away.
Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL.
restarts (invokable by number or by possibly-abbreviated name): 0: [RETRY ] Retry performing #<ASDF:LOAD-OP NIL {13F151C1}> on #<ASDF:CL-SOURCE-FILE "generate-frameworks-bindings" {1404E311}>. 1: [ACCEPT] Continue, treating #<ASDF:LOAD-OP NIL {13F151C1}> on #<ASDF:CL-SOURCE-FILE "generate-frameworks-bindings" {1404E311}> as having been successful. 2: [ABORT ] Exit debugger, returning to top level.
(SB-KERNEL::CONTROL-STACK-EXHAUSTED-ERROR) 0] 2 Control stack guard page temporarily disabled: proceed with caution
-------------------------
Jianshi Huang jianshi.huang@gmail.com writes:
Hi,
I got stack over flow error when doing asdf:load-op cl-objc. I think I need your help.
I'm using SBCL 1.0.12.3 (the latest :) on OS X Leopard x86.
I am sorry but i don't have Leopard yet :-(
Anyway, can you send to the mailing list the full backtrace of the error and the file /Users/huangjianshi/.sbcl/site/cl-objc/src/frameworks/Foundation-CLOS.lisp?
Please include also the version of cffi you are using.
Other way to solve the error is to delete the Foundation-CLOS.lisp file and recompile cl-objc. The file (it contains the clos bindings for the Foundation framework) should be recreated and maybe the new file (made using information got from the objc runtime) works for Leopard too.
P.S. Actually i am merging cl-objc with the work coming from other incomplete objc bridge, so maybe in 1/2 weeks the new code can incidentally work also on Leopard, so stay tuned!
Bye
-- Luigi Panzeri
Hi,
Thanks for the reply. I'll paste the backtrace.
--------
0] :backtrace 20
0: (SB-KERNEL::CONTROL-STACK-EXHAUSTED-ERROR) 1: ("foreign function: call_into_lisp") 2: ("foreign function: call_into_lisp_tramp") 3: ((FLET #:BODY-FUN-[GETHASH3]995)) 4: (SB-IMPL::GETHASH3 :CHAR #<HASH-TABLE :TEST EQL :COUNT 55 {1044DFE1}> NIL) 5: (CFFI::FIND-TYPE-PARSER :CHAR) 6: (CFFI::PARSE-TYPE :CHAR) 7: ((SB-PCL::FAST-METHOD CFFI:FOREIGN-TYPE-SIZE (T)) #<unavailable argument> #<unavailable argument> :CHAR) 8: (CFFI:FOREIGN-ALLOC :CHAR) 9: (CFFI:FOREIGN-STRING-ALLOC #<unavailable argument>) 10: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-TO-FOREIGN (STRING CFFI::FOREIGN-STRING-TYPE)) #<unavailable argument> #<unavailable argument> "name" #<unavailable argument>) 11: (OBJC-CFFI::SEL-REGISTER-NAME "name") 12: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-TO-FOREIGN (STRING OBJC-CFFI::OBJC-SELECTOR-TYPE)) #<unavailable argument> #<unavailable argument> "name" #<unavailable argument>) 13: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-FROM-FOREIGN (T OBJC-CFFI::OBJC-PROTOCOL-TYPE)) #<unavailable argument> #<unavailable argument> #.(SB-SYS:INT-SAP #XA0544CD8) #<unavailable argument>) 14: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-FROM-FOREIGN (T OBJC-CFFI::OBJC-PROTOCOL-LIST-TYPE)) #<unavailable argument> #<unavailable argument> #.(SB-SYS:INT-SAP #X001047A0) #<unavailable argument>) 15: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-FROM-FOREIGN (T OBJC-CFFI::OBJC-CLASS-TYPE)) #<unavailable argument> #<unavailable argument> #.(SB-SYS:INT-SAP #XA090D100) #<unavailable argument>) 16: (OBJC-GET-CLASS "Protocol") 17: ((LAMBDA (SB-PCL::|.P0.| SB-PCL::|.P1.|)) #<unavailable argument> #<unavailable argument>) 18: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-FROM-FOREIGN (T OBJC-CFFI::OBJC-PROTOCOL-TYPE)) #<unavailable argument> #<unavailable argument> #.(SB-SYS:INT-SAP #XA0544CD8) #<unavailable argument>) 19: ((SB-PCL::FAST-METHOD CFFI:TRANSLATE-FROM-FOREIGN (T OBJC-CFFI::OBJC-PROTOCOL-LIST-TYPE)) #<unavailable argument> #<unavailable argument> #.(SB-SYS:INT-SAP #X001047A0) #<unavailable argument>)
0]
I am sorry but i don't have Leopard yet :-(
Anyway, can you send to the mailing list the full backtrace of the error and the file /Users/huangjianshi/.sbcl/site/cl-objc/src/frameworks/Foundation- CLOS.lisp?
Please include also the version of cffi you are using.
Other way to solve the error is to delete the Foundation-CLOS.lisp file and recompile cl-objc. The file (it contains the clos bindings for the Foundation framework) should be recreated and maybe the new file (made using information got from the objc runtime) works for Leopard too.
P.S. Actually i am merging cl-objc with the work coming from other incomplete objc bridge, so maybe in 1/2 weeks the new code can incidentally work also on Leopard, so stay tuned!
I'll wait for the next release. :)
Cheers, Jianshi