axiom-developer
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-developer] Re: debugging


From: Waldek Hebisch
Subject: Re: [Axiom-developer] Re: debugging
Date: Wed, 18 Jul 2007 02:49:08 +0200 (CEST)

Camm Maguire wrote:
> Greetings, and thanks!  The problem is that the global entries to the
> functions returning double float etc. are not being writtin into
> DFLOAT.c.  I'm trying to debug by reproducing the compile-file step on
> DFLOAT.lsp.  This fails at the lisp prompt:
> 
> (compile-file "DFLOAT.NRLIB/DFLOAT.lsp")
> 
> ; (DEFUN |DFLOAT;manexp| ...) is being compiled.
> ;;; The tag #:G2017215 is undefined.
> ; (DEFUN |DFLOAT;rationalApproximation;$2NniF;84| ...) is being compiled.
> ;;; The tag #:G2017237 is undefined.
> ;;; The tag G190 is undefined.
> ; (DEFUN |DFLOAT;**;$F$;85| ...) is being compiled.
> ;;; The tag #:G2017246 is undefined.
> ;;; The tag #:G2017246 is undefined.
> No FASL generated.
> 
> Error: 
> Fast links are on: do (si::use-fast-links nil) for debugging
> Signalled by BREAK.
> Condition in BREAK [or a callee]: INTERNAL-SIMPLE-PROGRAM-ERROR: Compilation 
> of "DFLOAT.NRLIB/DFLOAT.lsp" failed.
> 
> Broken at BREAK.  Type :H for Help.
>  1 Retry compiling file "DFLOAT.NRLIB/DFLOAT.lsp".
>  2 Retry compiling file "DFLOAT.NRLIB/DFLOAT.lsp".
>  3 (Abort) Return to debug level 2.
>  4 (Continue) Return from break.
>  5 Return to top level.
> COMPILER>>
>
> Then I try )co "DFLOAT.spad" from the axiom prompt:
> 
> )co "DFLOAT.spad"
>    Your command is ambiguous. The following are abbreviated by co :
>       compiler 
>       copyright 
> (1) -> )quit
>    Please enter y or yes if you really want to leave the interactive 
>       environment and return to the operating system:
> y
>    You have chosen to remain in the AXIOM interactive environment.
> (1) -> 
> (1) -> 
> Program exited normally.
> 
> So I try a fresh interpsys, set the stage 1 bootstrap mode flag, And
> find a very long chain of compiles which must proceed before I can
> compile DFLOAT.  
> 
> I'm sure I'm just making some simple mistake, but how can one rebuild
> just DFLOAT from any given stage in the build?  This will enable me to
> fix this.
>

All Axiom generated Lisp file use special macros, present in interpsys.
Theoretically all macros are also present in depsys image, but I did
not check if depsys works for Lisp compilation of algebra files.
Error messages from Lisp compilation probably can be explained by lack
of macros.  But behavoir of ')co' (and also ')quit') command looks
strange -- I prefer to always use full version ')compile', but for
me ')co' starts compilation.  Also the

"You have chosen to remain in the AXIOM interactive environment."

message looks like a bug.

Spad compilation is slightly more tricky: given spad file may require
that several other files are compiled earlier.  When Spad compiler
operates in default mode there are cyclic dependencies.  Basically the
whole bootstrap procedure is to fight with those cyclic dependencies.
Stage 1 of bootstrap must go in a rather rigid order.  After stage 1 of
bootstrap it should be possible to compile all Spad files using special
|$bootstrapDomains| flag.  Once Stage 2 is finished it should be
possible to compile all normal mode.  

If you want to compile a single file after stage 1 finished do the following.

1) start interpsys, you need to correctly set up AXIOM and DAASE variables,
   for me the it is below:

( export AXIOM=/h/axp62/ax-build2/target/x86_64-unknown-linux; export 
DAASE=/h/axp62/wh-sandbox/src/share; 
/h/axp62/ax-build2/build/x86_64-unknown-linux/bin/interpsys )

2) for stage 2 compilation set the |$bootstrapDomains| flag:

)lisp (setf |$bootstrapDomains| t)

Value = T

3) issue compilation command:

(2) -> )compile "DFLOAT.spad"


If you want you can also do Lisp compilation:

(1) -> )lisp (compile-file "DFLOAT.NRLIB/DFLOAT.lsp")

Value = #P"/h/axp62/ax-build2/src/algebra/DFLOAT.NRLIB/DFLOAT.o"
(1) ->

Trying the above I noticed that doing by hand stage 2 compilation of
"DFLOAT.spad" I can also do stage 3 compilation of "DFLOAT.spad".
So the problem seem to appear only if I do all compilations in a
single image...

Normally Lisp files from stage 2 compilation are deleted before
starting stage 3 compilation.  I changed the Makefile to capture
the result from stage 2 compilation.  Comparing with the Lisp file
obtained separately I see some differences, but none which can explain
different behavior of object code.

-- 
                              Waldek Hebisch
address@hidden 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]