Wednesday May 24, 2006 Now I work on bug related to support friend template declaration. It's a quite complicated fix so unfortunately I have no progress on Boost regression test results.
Thanks a lot for comments on my previous post. List of libraries is very useful for me.
It looks like I missed one important thing related to Boost compilation. When you work with Boost you should use following command line options: -library=stlport4 -features=tmplife -features=tmplrefstatic. Also you may use -Qoption ccfe -complextmplexp. But C++ compiler from Sun Studio 11 does not fully support complex expression in template arguments so this option sometimes might lead to incorrect mangling names. Full support of complex template expression has been implemented in the development version of Sun C++.
Permalink
Comments [2]
Thursday May 11, 2006 Patches for Sun Studio 11 (121017-02/121018-02) have been released.
As I mentioned early I plan to fix all bugs in the C++ compiler frontend related to Boost 1.32.0. Some of changes in Boost source code have been integrated in the current library source tree already. Next I will switch to the latest Boost version. My primary goal is to fix as many as possible bugs in the compiler so I prefer remove Sun C++ related workarounds from Boost source code, get the error, fix it etc. I will send my changes of Boost source code to the Boost developers community on more regular basis than now.
Boost is a nice library but it is not the only useful C++ library. I'm interested to make a list of C++ libraries and/or applications which are incompatible with Sun C++ compiler now but necessary to Sun C++ community. So any links, suggestions or anything else will be very appreciated.
And as usually fresh Boost tests results.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 776 | 766 |
| Warn | 159 | 164 |
| Fail | 6 | 11 |
Friday April 28, 2006 Patches for Sun Studio 10 (117830-07/117831-07) have been released. Patches for Studio 11 (121017-02/121018-02) are almost ready.
Meanwhile number of failed Boost tests was reduced again. Please look at summary page - all optional, range, serialization, type_traits and utility tests are passed now. The still failed tests are known bugs and I continue to work on them.
Recently in the comments I found the question about downloaded version of Boost for Sun Studio. We don't plan to put Boost binaries on my blog or any other Sun related site because there is no binaries even on official Boost site. And the reason is quite clear - the biggest part of Boost code is templates.
And as usually fresh Boost tests results.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 772 | 762 |
| Warn | 159 | 164 |
| Fail | 10 | 15 |
Monday April 10, 2006 New patch for Studio 11 (121017-02/121018-02) is delayed. I think we will be able to release it in a couple of week. Patch for Sun Studio 10 is almost ready and we wait customer's feedback to release it.
Meanwhile number of failed Boost tests was reduced again. Please look at summary page - all regex tests are passed now.
Someone asked me about the only 'filesystem' failures. Actually it is not a bug. The failed tests just checks OS support large files (>4Gb). By default Boost is compiled in 32-bit mode. So that test is failed. But you can turn on 64-bit mode easily. Just pass -sBUILD="<instruction-set>v9" or -sBUILD="<instruction-set>athlon64" options to the bjam.
And as usually fresh Boost tests results.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 757 | 751 |
| Warn | 158 | 159 |
| Fail | 26 | 31 |
Tuesday March 28, 2006 New patch for Studio 11 (121017-02/121018-02) will be ready approximately in a week. You will be able to find it here. At the last moment I included some additional fix into this patch. So I expect when you install it and apply patch to Boost (see link in the right column) you will get 45 failed Boost test only.
And as usually fresh Boost tests results.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 761 | 755 |
| Warn | 155 | 156 |
| Fail | 33 | 38 |
Thursday March 16, 2006 I have fixed regression in Studio 11 code and now Studio 11 is better than Studio 10.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 749 | 743 |
| Warn | 155 | 156 |
| Fail | 45 | 50 |
New patches for Studio 11 (121017-02/121018-02) and Studio 10 (117830-07/117831-07) are on the road. Unfortunately I fix regression after Studio 11 patch was started. But we plan to start new patches for Studio 11 (121017-03/121018-03) soon.
Also we get significant progress with Boost 1.33.1. I post more detailed info later.
Permalink
Comments [3]
Wednesday March 01, 2006
Here you can find more detailed BOOST test results. The main difference between Studio 10 and Studio 11 results is in the MPL library. Failed Serialization and Variant tests are two known bugs. I almost ready to integrate a fix for one of them.
Permalink
Comments [1]
Sunday February 26, 2006 Sorry, small improvements only.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 697 | 726 |
| Warn | 154 | 155 |
| Fail | 98 | 68 |
Now users of Sun Studio C++ is able to define template friend function in the class body.
% cat test.cc templatestruct S { typedef T type; template friend void foo(U p1, S & p2) { // compiler could not find S and T typename S::type v; T p; } };
And use dependent template types with nested template arguments (see example below).
struct S
{
template < class SigArgs >
struct sig
{
typedef typename SigArgs :: head_type type;
};
};
template
struct cons
{
typedef Z head_type;
};
// compiler could not deduce return type
template
typename T1 :: template sig < cons > :: type
foo(T1, T2);
void test()
{
S v;
int i = foo( v, 1 );
}
Friday February 10, 2006 Actually I don't like that kind of music. But it's not the main today news topic. I reduced amount of failed tests again. Good job, isn't it? Link on the right side of this page goes to the updated patch for Boost 1.32.0. And it looks like we start to prepare new patch for Studio 10 and Studio 11. I will keep you informed.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 688 | 717 |
| Warn | 153 | 154 |
| Fail | 108 | 78 |
Monday February 06, 2006 There are no good news related to Boost regression test results. So to keep blog alive I want to answer some questions.
I build Studio 10 and Studio 11 compiler from the latest source code run Boost regression test and post results. Therefore external users right now can not obtain the same results. All fixes of C++ compiler's bug go to the next official patch. I don't have resources to run Boost tests with latest released patches regularly. But I plan to post a note here when new C++ patch is released, run Boost tests and post results. So we can compare our results.
Boost regression tests log is about 3Mb and I have 3Mb of disk space for this blog. I would be happy to post log files here but it's impossible.
In my previous post I mentioned Boost contains features which will be (or would be) included in the upcoming C++ standard. Actually, if we take a look at C++ standard proposal and Boost source code, Boost almost doesn't use any non-standard extensions to C++ itself. Some Boost libraries are candidate to include in the std namespace. So the main problem is in our compiler not Boost source code, though Boost source code need to be fixed too (__SUNPRO_CC usually point to place of fixes).
Why don't I post my patches to Boost community? Nothing important. Just time limit. Some of my fixes (small part) have been included in the Boost source code. Now I concentrate on bug fixing and work with Boost 1.32.0 mainly. When failed test rate drops under the 40-50 I switch to Boost 1.33.1 and post my fixes to Boost again. Why Boost 1.32.0? Because I think users prefer to have the most stable (not the latest) Boost release. Though my work is attempt to make the latest Boost release the most stable one. When I say 'stable' I mean the most compatible with Sun Studio C++.
Fell free to ask me more.
Permalink
Comments [1]
Thursday February 02, 2006 Almost all serialization tests are failed now. Some tests can't be linked and the other ones linked successfully but produce incorrect results. Link errors related to stlport. It looks like stlport should be linked as static library for this tests. I will check it. More complicated error breaks other tests. Test case below shows this bug:
% cat test.cc
struct S
{
template
void operator+(T & t)
{
const_cast(t);
}
};
void foo()
{
int array[] = {777};
S s;
s + array;
}
% CC -c test.cc
"test.cc", line 14: Error: The operation "S + int*" is illegal.
You know, Sun Studio C++ is a good compiler: excellent backend, OMP support etc. But it does not work with a very popular open source library - BOOST. There are a lot of open source libraries. Why support of BOOST is so important? I think BOOST is one of the most useful libraries for C++ development (I used it intensively when I worked here) and even more - it contains some features which will be included in the upcoming version of C++ standard.
I think it's time to include Sun Studio C++ in the list of compiler fully compatible with BOOST. A lot of work has been done already but there are some bugs still need to be fixed. I will post notes in this blog to inform community about course of events. Also I will post patches for BOOST. Sure I plan to send BOOST patches to developers and they will be included in the official BOOST release.
Somebody ask me about patches for Sun Studio C++. Sorry, I can not do that here. You can take patch from official site. Please keep in mind the test results posted on this blog obtained with latest version of compilers. Corresponded fixes will be included in the next patch for Sun Studio C++. I've just start to discuss with my manager and colleagues how to change schedule of patch releases. In other word I suggest to release patch for Sun Studio C++ regularly. For example once a month. If this idea is accepted moment of patch release with necessary fixes will be more predictable.
BTW any feedback from you is very helpful and necessary for me.
U-u-f, sorry for my English.
Permalink
Comments [2]
Wednesday February 01, 2006 Congratulate me! I've just integrated my latest fix and got Boost 1.32 test results. Sun Studio C++ 10 breaks 169 tests only. Sun Studio C++ 11 is very close to 200 boundary.
| Studio 11 | Studio 10 | |
|---|---|---|
| Pass | 627 | 658 |
| Warn | 113 | 114 |
| Fail | 201 | 169 |
Monday January 30, 2006 I've just made an attempt to build Boost 1.33.1 by Sun Studio 11. This patch reduces number of failed target to 28. There are two type of errors: "Initializing <variable name skipped> requires an lvalue" and "Redefining <type name skipped>". The first one can be reduced to following testcase:
struct S
{
template <typename T>
struct D
{
};
};
template <typename T1, typename T2>
typename T1 :: template D<T2> & foo();
void f()
{
S::D<int> & v = foo<S, int>();
}
So now I'm working on this bug.
Permalink
Comments [1]
Thursday January 26, 2006 This HOWTO describes Boost - 1.32.0. This version with applied patch is supported by Sun Studio C++ compiler so I recommend to use it now. I do not plan to make a patch for Boost 1.33.1 because upcoming Boost 1.34 works with Sun C++ well out of the box. Please note, Sun Microsystems does not support Boost library, i.e. we do not and we will not fix bugs in it. Please ask Boost developers.
This file contains all necessary fixes to Boost 1.32.0. You should use gnu patch.
tar xfj boost_1_32_0.tar.bz2
cd boost_1_32_0
gpatch -p1 < ../boost_1_32_0.patch
The Boost build system uses BJam, an extension of the Perforce Jam portable make replacement. Unfortunately there is no prebuilded binary version of bjam for Solaris. But we are professionals, aren't we? So let's build bjam. Suppose BOOST is the Boost's root folder. If you gonna use a compiler, which isn't in the /opt/SUNWspro folder you have to point to it by setting BOOST_JAM_TOOLSET_ROOT. It should point to the directory that contains folders like bin, lib, prod. For example for Studio Express export BOOST_JAM_TOOLSET_ROOT=/opt/SPROexpress/opt/SUNWspro/. Note trailing slash is important. All preparations are done. Let's make the rest few steps:
cd $BOOST/tools/jam/src
./build.sh sunpro
ln -s bin.solaris bin # to run regression tests later
Have you builded the bjam? Let's continue. Now you are almost ready to build the Boost. Suppose BOOST is the Boost's root folder and jam is on your path. You can start building the Boost.
If your compiler is installed in the standard folder just run:
cd $BOOST
bjam -sTOOLS=sunpro stage
If you need to setup compiler options, point to non-standard compiler installation folder run the following extended version of build command:
cd $BOOST
bjam -sTOOLS=sunpro \
-sSUNPRO_ROOT_DIRECTORY="/opt/SPROexpress/opt/SUNWspro/" \
-sSUNPRO_CXX="CC <options>" \
-j8 -d2 stage
Boost uses bjam to build and run tests and two additional programs to parse log and produce html formatted results. Let's run tests. As usually suppose BOOST is the Boost's root folder and bjam is on your path. Note if you want to produce html formatted log you cannot use -jn.
cd $BOOST/status
bjam -sTOOLS=sunpro --dump-tests &> test_log
If you want to work with html formatted results instead of raw data from test_log you need to build two additional utilities and run them.
cd $BOOST/tools/regression/build
bjam -sTOOLS=sunpro -sBUILD=release run
You've got two utilites process_jam_log and compiler_status in the $BOOST/tools/regression/build/run. To produce formatted log run them one by one. Important note: $BOOST should start with a domain name.
cd $BOOST/status
cat test_log | process_jam_log
compiler_status $BOOST log.html log-links.html
Test results are in the log.html and log-links.html. That's all.
When you work with Boost you should use the following command line options: -library=stlport4 -features=tmplife -features=tmplrefstatic. Also you may use -Qoption ccfe -complextmplexp. But C++ compiler from Sun Studio 11 does not fully support complex expression in template arguments so this option sometimes might lead to incorrect mangling names. Full support of complex template expression has been implemented in the development version of Sun C++.
Permalink
Comments [6]