Dear All,
my project for the last couple of days has been building QuantLib under x64 i.e. with the 64 bit tool set for Visual Studio 9.0 Professional. Since there had been discussion on the list previously, I'm passing on my experiences. First, some parts of Boost seem to have issues with x64. In particular, lexical_cast seems to break. I therefore have commented out its uses in two files in QuantLib and replaced them with atoi . Second, as usual the hardest part of building QuantLib is installing boost. The pre-built installers don't seem to support x64. So you have to install bjam and build it yourself. The command line command I used was bjam address-model=64 --build-dir=mybuilddirectory stage run from the Visual C++ 64 bit tools command prompt in the directory C:\boost\boost_1_38_0 where i had unzipped Boost version 1.38 address-model = 64 ensures 64 bit addressing --build-dir=mybuilddirectory says do all the building in mybuilddirectory stage makes it copy all the produced library files into stage/lib I had also created a file user-config.jam in this directory (i.e. C:\boost\boost_1_38_0) with the single line using msvc : 9.0 : : <arch>amd64 ; in it. (I am not actually sure that this had any effect.) This produced a lot of libraries but only the ones suitable for release rather than release (static) . With these things done, I was able to build the test-suite in x64 mode and run it. However, there were 29 errors. These were typically of the form unknown location(0): fatal error in "QuantLib::detail::quantlib_test_case(&VarianceSwapTest::testMCVarianceSwap)": std::exception: timeSteps must be positive, 0 not allowed which means some number has been passed to a routine as zero when it should be positive. This is probably related to the large number of warnings when compiling about loss of data when casting numeric types. >Tests completed in 13 m 37 s 1>Test suite "Master Test Suite" failed with: 1> 510 assertions out of 539 passed 1> 29 assertions out of 539 failed 1> 366 test cases out of 395 passed 1> 29 test cases out of 395 failed 1> 29 test cases out of 395 aborted Other points to watch are that if you simply use the configuration manager to create the x64 project files then the same directories are used for win32 and x64, and building in one overwrites the other. And the compiler doesn't recompile the files on changing but simply complains that they are of the wrong sort. It may be time to consider whether QuantLib should start supporting x64 builds. I am happy to discuss further, best Mark ------------------------------------------------------------------------------ Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA -OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise -Strategies to boost innovation and cut costs with open source participation -Receive a $600 discount off the registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H _______________________________________________ QuantLib-dev mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
Free forum by Nabble | Edit this page |