[Ecls-list] [**SPAM**]Re: Flaw in subtypep ? / catching stack-overflow ? / memory-limits experience ?

Eckhard Wiederhold ecky at ecky.fr
Mon Nov 4 15:10:32 UTC 2013


Hello,

Here a work-around for my second question : catching stack-overflow.
If you catch a stack-overflow you need to issue (ext:set-limit 
'ext:c-stack #<my-stack-size>) in or after the condition-handler in 
order to avoid the observed (undesirable?) behaviour. Where 
#<my-stack-size> is any positive integer you may get beforehand by 
(ext:get-limit 'ext:c-stack).

ecky

PS: By the way, thanks for your answers I discovered them today when I 
checked the mail-archive for something else. I'll have a look why I 
didn't get them right away.




Le 28/10/2013 19:38, Eckhard Wiederhold a écrit :
> Hello,
>
> I encountered some trouble using ecl that I don't know how to resolve
> myself and I'd be very grateful to get some advice on what to do or
> pointers to background-information that I was unable to find :
>
> 1. I just tried to get all conditions that ecl is aware of by traversing
> all packages and all symbols calling
>      (subtypep _symbol 'condition) on any symbol in any package. I got my
> list finally by excluding the
>      following symbols: (mod si:property-list si::proper-list). It seems
> that
>      - (subtypep 'mod 'condition) raises "Wrong number of arguments ..."
> error-condition
>      - (subtypep 'si:property-list 'condition) and (subtypep
> 'si::proper-list 'condition) raise "Stack overflow."
>        serious-condition
>      Question: Is this some issue I need to report here:
> http://sourceforge.net/p/ecls/bugs/ ? Or is it normal
>      behaviour ?
>
> 2. Further I observed that I was only able to catch the stack-overflow
> condition using a handler-case for
>      exactly three times :
>      ECL (Embeddable Common-Lisp) 13.5.1 (git:UNKNOWN)
>      Copyright (C) 1984 Taiichi Yuasa and Masami Hagiya
>      Copyright (C) 1993 Giuseppe Attardi
>      Copyright (C) 2000 Juan J. Garcia-Ripoll
>      ECL is free software, and you are welcome to redistribute it
>      under certain conditions; see file 'Copyright' for details.
>      Type :h for Help.
>      Top level in: #<process TOP-LEVEL>.
>      > (handler-case (subtypep 'si:property-list 'condition)
> (ext:stack-overflow (e) (print "Caught it.")))
>
>      "Caught it."
>      "Caught it."
>      > (handler-case (subtypep 'si:property-list 'condition)
> (ext:stack-overflow (e) (print "Caught it.")))
>
>      "Caught it."
>      "Caught it."
>      > (handler-case (subtypep 'si:property-list 'condition)
> (ext:stack-overflow (e) (print "Caught it.")))
>
>      ;;;
>      ;;; Stack overflow.
>      ;;; Jumping to the outermost toplevel prompt
>      ;;;
>
>
>      Top level in: #<process TOP-LEVEL>.
>
>      Any attempt to catch it later failed and i ended up on toplevel ...
> this seems odd to me but it matches
>      in a strange way the fact that you may, if a stack-overflow occurs,
> resize the stack two times, after that
>      you're put to toplevel automatically. Is there any way to get around
> this?
>
> Thanks for any comment
> ecky
>
>
>
>
> ------------------------------------------------------------------------------
> October Webinars: Code for Performance
> Free Intel webinars can help you accelerate application performance.
> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
> the latest Intel processors and coprocessors. See abstracts and register >
> http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk
> _______________________________________________
> Ecls-list mailing list
> Ecls-list at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ecls-list





More information about the ecl-devel mailing list