I am very glad your problem is solved. My opinion is that this is not a problem with nlopt itself.
Dale Smith, Ph.D. Senior Financial Quantitative Analyst Financial & Risk Management Solutions Fiserv Office: 678-375-5315 www.fiserv.com -----Original Message----- From: Tobias Schmidt [mailto:[email protected]] Sent: Friday, January 10, 2014 11:10 AM To: Smith, Dale (Norcross) Cc: [email protected] Subject: Re: [NLopt-discuss] Using NLopt on BeagleBone Black with QNX You are great! I changed all the optimization levels to -O0 and the program runs without fault. With -O1 the program fails again. It is depressing that the cross-compiler causes the program to fail by optimizing the code -.- Thanks a lot. Tobias Schmidt Am 10.01.2014 14:33, schrieb Smith, Dale (Norcross): > Build with -O0, that is, with no optimizations. Compiler optimization levels > can re-arrange your code. If it runs with -O0 builds, try -O1, etc. > > If it doesn't work with -O0, start that version with a debugger. You will > need to step thru the code to find any misaligned pointers, and it helps to > have no optimizations to do that. > > Perhaps the vendor has run into similar problems and can help you out. > > Dale Smith, Ph.D. > Senior Financial Quantitative Analyst > Financial & Risk Management Solutions > Fiserv > Office: 678-375-5315 > www.fiserv.com > > -----Original Message----- > From: Tobias Schmidt [mailto:[email protected]] > Sent: Friday, January 10, 2014 8:24 AM > To: Smith, Dale (Norcross) > Cc: [email protected] > Subject: Re: [NLopt-discuss] Using NLopt on BeagleBone Black with QNX > > Hi, > > thanks for your reply. > > ldqnx.so links to libc.so which is used by a simple Hello World program, too. > I successfully run such a test program on the board. > > I don't think that Cygwin causes the fault. Within Cygwin I did only build > the Makefiles. The "make all" command is executed from QNX Momentics IDE. If > there would be any dependency to Cygwin, the program won't start on the board > because there is no Cygwin library. > > I tried to use NLopt both as dynamic and static library. Both versions fails > with indicated SIGBUS. > > Do anybody have any other suggestions? > > Regards, > Tobias Schmidt > > > Am 09.01.2014 15:42, schrieb Smith, Dale (Norcross): >> The only other thing I can think of is to build nlopt using --enable-shared >> and compile with -mno-cygwin to avoid a reference to the Cygwin dll. This is >> the way to get code that doesn't reference Cygwin when running outside of >> Cygwin. >> >> http://www.delorie.com/howto/cygwin/mno-cygwin-howto.html >> >> Dale Smith, Ph.D. >> Senior Financial Quantitative Analyst Financial & Risk Management >> Solutions Fiserv >> Office: 678-375-5315 >> www.fiserv.com >> >> >> -----Original Message----- >> From: NLopt-discuss [mailto:[email protected]] >> On Behalf Of Smith, Dale (Norcross) >> Sent: Thursday, January 09, 2014 9:17 AM >> To: Tobias Schmidt; [email protected] >> Subject: Re: [NLopt-discuss] Using NLopt on BeagleBone Black with QNX >> >> Can you successfully build and run a simple test program that loads ldqnx.so >> but does not link with nlopt? If not, then it's not an nlopt problem. Does >> the board have a test suite you can run to verify programs built in Cygwin >> work properly? >> >> Have you tried building nlopt as a static lib and linking with that? >> >> Dale Smith, Ph.D. >> Senior Financial Quantitative Analyst Financial & Risk Management >> Solutions Fiserv >> Office: 678-375-5315 >> www.fiserv.com >> >> >> -----Original Message----- >> From: NLopt-discuss [mailto:[email protected]] >> On Behalf Of Tobias Schmidt >> Sent: Thursday, January 09, 2014 5:06 AM >> To: [email protected] >> Subject: [NLopt-discuss] Using NLopt on BeagleBone Black with QNX >> >> Hi nlopt-community, >> >> I'm trying to use NLopt to solve optimization problems on my BeagleBone >> Black running QNX 6.5.0. The board has an ARM Cortex-A8 processor. >> >> Did anybody cross-compile the NLopt library for QNX on BBB or a similar >> board with ARM processor? >> >> Up to now I did following steps to configure and build the library: >> >> 1. Created a new QNX C Project in Momentics 2. Configured the >> Makefile by running <code>./configure --without-octave >> --without-python --without-guile --enable-shared >> --host=arm-unknown-nto-qnx6.5.0 --build=i486-pc-nto-qnx6.5.0 CC="qcc >> -V4.4.2,gcc_ntoarmv7le" CPP="qcc -V4.4.2,gcc_ntoarmv7le -E" CXX="QCC >> -V4.4.2,gcc_ntoarmv7le" CXXCPP="QCC -V4.4.2,gcc_ntoarmv7le -E" >> LD="arm-unknown-nto-qnx6.5.0-ld" NM="arm-unknown-nto-qnx6.5.0-nm -B"</code> >> within Cygwin environment. >> 3. Run "Build Project" in Momentics >> >> The build process succeed, but if I want to use the library within another >> Project the execution fails with the message: >> >> Process 36886 (nlopt_test_ctschmidt138926111541656) terminated SIGBUS >> code=1 fltno=5 >> ip=01024c34(/usr/lib/ldqnx.so.2@_band_get_aligned+0x168) >> mapaddr=00024c34. ref=bee2e36a >> >> Does anybody know what I'm doing wrong? Does anybody has an idea where the >> fault could be located? >> >> Regards, >> Tobias Schmidt >> >> _______________________________________________ >> NLopt-discuss mailing list >> [email protected] >> http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/nlopt-discuss >> >> _______________________________________________ >> NLopt-discuss mailing list >> [email protected] >> http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/nlopt-discuss >> > _______________________________________________ NLopt-discuss mailing list [email protected] http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/nlopt-discuss
