[Openmcl-devel] Trace/BPT trap with cl-opengl loading
Gary Byers
gb at clozure.com
Thu Aug 5 08:20:00 PDT 2010
The "trace/bkpt trap" happens - as you've already confirmed - when
a thread other than the initial thread tries to open/initialize
a particular shared library. (I'm fairly sure that the library
in question is CoreFoundation, which is used by many other things
on OSX.)
Alex's XMLisp stuff runs on top of CCL's Cocoa environment, which
takes great care to ensure that the Cocoa framework (and therefore
CoreFoundation) are loaded on the initial thread. (If it didn't,
it would run into the same breakpoint trap. Honest.)
[~] gb at antinomial> ccl
Welcome to Clozure Common Lisp Version 1.6-dev-r14118M-trunk (DarwinX8632)!
;;; Two lisp processes are running: the listener, and the initial
;;; process. Each of these lisp processes is implemented as a
;;; native OS thread.
? :proc
1 : -> listener [Active]
0 : Initial [Sleep]
;;; Let's try to open the CoreFoundation library from the listener
;;; process.
? (open-shared-library "CoreFoundation.framework/CoreFoundation")
Trace/BPT trap
Lots of other OSX libraries will (directly or transitively) load
CoreFoundation. CoreFoundation's initialization code checks in 10.6
to see if it's being called on the initial thread; if not, it executes
an illegal debugging instruction and the process terminates. That's
not a particulary graceful way to fail, but that's what happens.
I hope that this is clear; apologies to everyone to which it was
already clear.
On Thu, 5 Aug 2010, k2msmith at gmail.com wrote:
> Are you running this on clozure 1.5 with Snow Leopard MAC OS (ie: version
> 10.6.4 ) ?
>
> On Aug 5, 2010 4:36am, Alexander Repenning <ralex at cs.colorado.edu> wrote:
> > XMLisp http://code.google.com/p/xmlisp/ works fine, i.e., it is not an
> OpenGL problem.
> >
> >
> > alex
> >
> >
> >
> >
> >
> > On Aug 2, 2010, at 4:11 AM, Kevin Smith wrote:
> >
> > further to this message.. I tried the lastest svn "trunk" release of ccl
> (which incidentally looks like it has some extra goodies in it for the mac
> platform).. Here is what I get (after startup)..
> >
> >
> > Welcome to Clozure Common Lisp Version 1.5-dev-r13523M-trunk
> (DarwinX8664)!
> > ? (require :cl-opengl)
> > Trace/BPT trap
> >
> >
> > All other require packages got loaded successfully on startup prior. I
> played around with "trace" and "step" but none of those debugging functions
> seem to give me the equivalent of a "stack trace' in C. Not sure how to
> proceed to find out where it is crashing...
> >
> >
> >
> > Thanks,
> > Kevin
> >
> >
> >
> >
> >
> >
> > On Sun, Aug 1, 2010 at 6:04 PM, Kevin Smith k2msmith at gmail.com> wrote:
> >
> > The only hurdle for me for trying out (and maybe switching) to clozure on
> the mac platform is that I can't seem to get the cl-opengl package loaded.
> I get the error: "Trace/BPT trap" when I try to load that package. (All
> other dependent packages like cffi, loaded successfully).
> >
> >
> >
> > I am using ccl64, version 1.5 on Darwin/MAC OS (DarwinX8664). Latest
> version of cl-opengl.
> >
> >
> > I believe I also tried it on the 32-bit ccl. Same problem. It looks like
> it only compiles a few source files in the cl-opengl package before it dies.
> >
> >
> >
> >
> > If someone can point out to me how I can trace this to provide more
> information on where it is crashing or maybe someone has run across this
> already with this particular package.
> >
> >
> >
> >
> > Thanks,
> > Kevin
> >
> >
> >
> >
> >
> >
> >
> >
> > _______________________________________________
> > Openmcl-devel mailing list
> > Openmcl-devel at clozure.com
> > http://clozure.com/mailman/listinfo/openmcl-devel
> >
> >
> >
> > Prof. Alexander Repenning
> > University of ColoradoComputer Science DepartmentBoulder, CO 80309-430
> > vCard: http://www.cs.colorado.edu/~ralex/AlexanderRepenning.vcf
> >
> >
> >
> >
> >
> >
>
More information about the Openmcl-devel
mailing list