64-bit yap on OS X 10.5?

View: New views
4 Messages — Rating Filter:   Alert me  

64-bit yap on OS X 10.5?

by Will Benton :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi all,

Has anyone successfully built and run yap as a 64-bit application on  
OS X 10.5?  (I'm using the current CVS version on a core 2 duo  
machine.)  I've run into a few problems, most notably:

1.  The CFLAGS I pass to configure aren't used for compiling parser.c  
and c_interface.c, so these two files are compiled for 32-bit OS X.  
(If I recompile them by hand, yap will link.)
2.  yap attempts to mmap its initial work space at a fixed address  
that isn't mmapable under 64-bit OS X.  (I tried with --enable-use-
malloc, too, but that just segfaulted.)

If I fix these two problems, I get segfaults when compiling the  
initial bootfile (stack trace below).  I guess I'm not sure whether or  
not yap will even work in this configuration without major surgery,  
but if anyone has gotten it to work, I'd be glad to hear how.


thanks,
wb

---

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x000000000000e758
0x00000001000ef674 in GetModuleEntry (at=0xe750) at modules.c:59
59  p0 = ae->PropsOfAE;
(gdb) bt
#0  0x00000001000ef674 in GetModuleEntry (at=0xe750) at modules.c:59
#1  0x00000001000ef645 in LookupModule (a=59217) at modules.c:112
#2  0x00000001000ef7f7 in Yap_NewModulePred (mod=59217,  
ap=0x400000065220) at modules.c:137
#3  0x000000010004688d in Yap_NewPredPropByFunctor (fe=0x4000000651f0,  
cur_mod=59217) at adtdefs.c:656
#4  0x0000000100046d2b in Yap_PredPropByFunctorNonThreadLocal  
(f=0x4000000651f0, cur_mod=59217) at adtdefs.c:810
#5  0x000000010008197f in c_goal (Goal=70368747454749, mod=59217,  
cglobs=0x7fff5fbfb8c0) at compiler.c:1492
#6  0x0000000100083884 in c_body (Body=70368747454805, mod=0,  
cglobs=0x7fff5fbfb8c0) at compiler.c:1949
#7  0x00000001000875af in Yap_cclause (inp_clause=70368747454853,  
NOfArgs=0, mod=0, src=70368747454853) at compiler.c:3307
#8  0x00000001001258f3 in YAP_CompileClause ()
#9  0x00000001000015f0 in do_bootfile (bootfilename=0x7fff5fbfd0aa "./
pl/boot.yap") at yap.c:215
#10 0x00000001000021fc in exec_top_level (BootMode=0,  
iap=0x7fff5fbfcd30) at yap.c:643
#11 0x00000001000024ed in main (argc=3, argv=0x7fff5fbfcdf8) at yap.c:
728


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Yap-users mailing list
Yap-users@...
https://lists.sourceforge.net/lists/listinfo/yap-users

Re: 64-bit yap on OS X 10.5?

by Will Benton :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi all,

The issues I had building and using 64-bit yap on an Intel Mac are now  
fixed in the CVS head.

If you're a Mac user and would like to use a 64-bit yap, here's how to  
build it:

0.  Update from CVS,
1.  Set the environment variable CC to 'gcc -arch x86_64'
2.  When you run configure, add "--build=x86_64-apple-darwin" to the  
other options you'd typically use, and
3.  Make and install as usual.


best,
wb

On Jan 21, 2008, at 8:38 PM, Will Benton wrote:

> Hi all,
>
> Has anyone successfully built and run yap as a 64-bit application on  
> OS X 10.5?  (I'm using the current CVS version on a core 2 duo  
> machine.)  I've run into a few problems, most notably:
>
> 1.  The CFLAGS I pass to configure aren't used for compiling  
> parser.c and c_interface.c, so these two files are compiled for 32-
> bit OS X.  (If I recompile them by hand, yap will link.)
> 2.  yap attempts to mmap its initial work space at a fixed address  
> that isn't mmapable under 64-bit OS X.  (I tried with --enable-use-
> malloc, too, but that just segfaulted.)
>
> If I fix these two problems, I get segfaults when compiling the  
> initial bootfile (stack trace below).  I guess I'm not sure whether  
> or not yap will even work in this configuration without major  
> surgery, but if anyone has gotten it to work, I'd be glad to hear how.


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Yap-users mailing list
Yap-users@...
https://lists.sourceforge.net/lists/listinfo/yap-users

Re: 64-bit yap on OS X 10.5?

by Paulo Moura :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On 2008/01/25, at 17:43, Will Benton wrote:

> The issues I had building and using 64-bit yap on an Intel Mac are now
> fixed in the CVS head.
>
> If you're a Mac user and would like to use a 64-bit yap, here's how to
> build it:
>
> 0.  Update from CVS,
> 1.  Set the environment variable CC to 'gcc -arch x86_64'
> 2.  When you run configure, add "--build=x86_64-apple-darwin" to the
> other options you'd typically use, and
> 3.  Make and install as usual.


Very handy when working with multi-threading applications due to the  
large (virtual) address space :-)

I tried to also compile YAP CVS 64 bits on Fedora Core 8 but I'm  
getting an error at the end of "make" ("using --build=x86_64-pc-
linux") :( Is anyone being able to compile the 64 bits version on Linux?

Cheers,

Paulo


-----------------------------------------------------------------
Paulo Jorge Lopes de Moura
Dep. of Computer Science, University of Beira Interior
6201-001 Covilhã, Portugal

Office 4.3  Ext. 3257
Phone: +351 275319891 Fax: +351 275319899
Email: <mailto:pmoura@...>

Home page: <http://www.di.ubi.pt/~pmoura>
Research: <http://logtalk.org/>
-----------------------------------------------------------------




-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Yap-users mailing list
Yap-users@...
https://lists.sourceforge.net/lists/listinfo/yap-users

Re: 64-bit yap on OS X 10.5?

by Vitor Santos Costa-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Paulo

I do use the 64 bits quite a lot, but I never used that option from
Linux. I just compile YAP and it builds the 64 bit version by default.

Cheers

Vitor

On Jan 31, 2008 5:47 PM, Paulo Moura <pmoura@...> wrote:

>
> On 2008/01/25, at 17:43, Will Benton wrote:
>
> > The issues I had building and using 64-bit yap on an Intel Mac are now
> > fixed in the CVS head.
> >
> > If you're a Mac user and would like to use a 64-bit yap, here's how to
> > build it:
> >
> > 0.  Update from CVS,
> > 1.  Set the environment variable CC to 'gcc -arch x86_64'
> > 2.  When you run configure, add "--build=x86_64-apple-darwin" to the
> > other options you'd typically use, and
> > 3.  Make and install as usual.
>
>
> Very handy when working with multi-threading applications due to the
> large (virtual) address space :-)
>
> I tried to also compile YAP CVS 64 bits on Fedora Core 8 but I'm
> getting an error at the end of "make" ("using --build=x86_64-pc-
> linux") :( Is anyone being able to compile the 64 bits version on Linux?
>
> Cheers,
>
> Paulo
>
>
> -----------------------------------------------------------------
> Paulo Jorge Lopes de Moura
> Dep. of Computer Science, University of Beira Interior
> 6201-001 Covilhã, Portugal
>
> Office 4.3  Ext. 3257
> Phone: +351 275319891 Fax: +351 275319899
> Email: <mailto:pmoura@...>
>
> Home page: <http://www.di.ubi.pt/~pmoura>
> Research: <http://logtalk.org/>
> -----------------------------------------------------------------
>
>
>
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Yap-users mailing list
> Yap-users@...
> https://lists.sourceforge.net/lists/listinfo/yap-users
>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Yap-users mailing list
Yap-users@...
https://lists.sourceforge.net/lists/listinfo/yap-users