$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [boost] [chrono] Valgrind complains
From: vicente.botet (vicente.botet_at_[hidden])
Date: 2010-06-22 18:41:00
----- Original Message -----
From: "Roland Bock" <rbock_at_[hidden]>
To: <boost_at_[hidden]>
Sent: Tuesday, June 22, 2010 8:23 PM
Subject: Re: [boost] [chrono] Valgrind complains
> vicente.botet wrote:
>> ----- Original Message -----
>> From: "Roland Bock" <rbock_at_[hidden]>
>> To: <boost_at_[hidden]>
>> Sent: Tuesday, June 22, 2010 5:34 PM
>> Subject: Re: [boost] [chrono] Valgrind complains
>>
>>
>>
>>>>> From: "Roland Bock" <rbock_at_[hidden]>
>>>>>
>>>>>
>>>>>> Valgrind complains about
>>>>>>
>>>>>> Conditional jump or move depends on uninitialised value(s)
>>>>>>
>>>>>>
>>>>>> several times for the following line:
>>>>>>
>>>>>> { boost::chrono::stopclock<> stopclock(std::cerr); }
>>>>>>
>>
>> Could you check if Valgrind complains with
>>
>> { boost::chrono::stopclock<> stopclock; }
>> or
>> { boost::chrono::stopclock<> stopclock(BOOST_CURRENT_FUNCTION); }
>> or
>> { boost::system::error_code ec;
>> boost::chrono::stopclock<> stopclock(std::cerr, ec); }
>>
>> Thanks,
>> Vicente
>>
>>
>>
> Hi,
>
> attached are
>
> * the source file containing the original test plus the three
> additional tests suggested by you
> * a file containing compiler warnings
> * the valgrind output (the latter two tests do not produce warnings,
> if I read it correctly)
>
>
> The program was compiled using the following compiler flags (gcc=4.2.4
> on Ubuntu 8.04, 64bit):
>
> -Wall -Wreorder -Wnon-virtual-dtor -Wno-non-template-friend
> -Woverloaded-virtual -Wsign-promo -Wextra -fvisibility=hidden
> -D_GNU_SOURCE -O0 -g
I have seen some places where the parameter system::error_code & ec is not initialized when the function succeed. I have update the code so the variable is initialized. Most of the tests are done with the default system::throws parameter so these errors are not catched. I will try to complete the tests for the no-throw cases soon.
Roland, please could you download the new version, and check if the Valgrind issue is resolved?
Thanks in advance,
Vicente