[chrono] v0.4.1 + thread_clock implementation on Windows

Hi all, As suggested by Roland Bock on the Boost Users ML, I have implemented the thread_clock on Windows using FILETIME creationTime, exitTime, kernelTime, userTime; GetThreadTimes(GetCurrentThread (), &creationTime, &exitTime, &kernelTime,&userTime); I don't know Windows well, it would be very kind if someone of you can inspect the implementation. The implementation of thread_clock for Mac is still missing. I don't know even if thread cloks are provided on this platform. In addition, I have added also the function prototypes to Boost.Thread using Boost.Chrono as well as updated the tests. This could be used as a base for a possible Boost.Thread update using chrono (standard C++0x proposal), if the library is accepted, of course. Note the modifications of Boost.Thread have been done on the base of 1.43. The library can be downloaded from http://www.boostpro.com/vault/index.php?action=downloadfile&filename=chrono.zip&directory=System& and the documentation is online on the sandbox http://svn.boost.org/svn/boost/sandbox/chrono/libs/chrono/doc/html/index.htm.... Anthony Williams has accepted to manage the review. We have not yet fixed a date, but I expect we could communicate one soon. I will be very thankful, if people using the library already or that could be interested in, can do a review even before the date. Thanks, _____________________ Vicente Juan Botet Escribá http://viboes.blogspot.com/

vicente.botet wrote:
The library can be downloaded from http://www.boostpro.com/vault/index.php?action=downloadfile&filename=chrono.zip&directory=System& and the documentation is online on the sandbox http://svn.boost.org/svn/boost/sandbox/chrono/libs/chrono/doc/html/index.htm....
Hi, I am getting compile errors when performing installation like this: tar jxf ../Downloads/boost_1_43_0.tar.bz2 unzip ../Downloads/chrono.zip cp -rp chrono/* boost_1_43_0 cd boost_1_43_0 export EXPAT_LIBPATH=$INSTALL_ROOT/binaries/expat/2.0.1/lib export EXPAT_INCLUDE=$INSTALL_ROOT/binaries/expat/2.0.1/include ./bootstrap.sh --with-icu=$INSTALL_ROOT/binaries/icu/4.2 mkdir build ./bjam -q --build-dir=build --prefix=$INSTALL_ROOT/binaries/boost/1.43 link=shared runtime-link=shared install This procedure worked fine with 1.41 and chrono-0.4. It also works fine when omitting chrono. The messages start with this: gcc.compile.c++ build/boost/bin.v2/libs/thread/build/gcc-4.2.4/release/threading-multi/pthread/thread.o In file included from ./boost/thread/pthread/mutex.hpp:12, from ./boost/thread/mutex.hpp:16, from ./boost/thread/pthread/thread_data.hpp:12, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/locks.hpp:16:77: error: boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp: No such file or directory ./boost/thread/locks.hpp:17:76: error: boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp: No such file or directory Regards, Roland

Roland Bock-2 wrote:
vicente.botet wrote:
The library can be downloaded from http://www.boostpro.com/vault/index.php?action=downloadfile&filename=chrono.zip&directory=System& and the documentation is online on the sandbox http://svn.boost.org/svn/boost/sandbox/chrono/libs/chrono/doc/html/index.htm....
Hi,
I am getting compile errors when performing installation like this:
tar jxf ../Downloads/boost_1_43_0.tar.bz2 unzip ../Downloads/chrono.zip cp -rp chrono/* boost_1_43_0 cd boost_1_43_0 export EXPAT_LIBPATH=$INSTALL_ROOT/binaries/expat/2.0.1/lib export EXPAT_INCLUDE=$INSTALL_ROOT/binaries/expat/2.0.1/include ./bootstrap.sh --with-icu=$INSTALL_ROOT/binaries/icu/4.2 mkdir build ./bjam -q --build-dir=build --prefix=$INSTALL_ROOT/binaries/boost/1.43 link=shared runtime-link=shared install
This procedure worked fine with 1.41 and chrono-0.4. It also works fine when omitting chrono.
The messages start with this:
gcc.compile.c++ build/boost/bin.v2/libs/thread/build/gcc-4.2.4/release/threading-multi/pthread/thread.o In file included from ./boost/thread/pthread/mutex.hpp:12, from ./boost/thread/mutex.hpp:16, from ./boost/thread/pthread/thread_data.hpp:12, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/locks.hpp:16:77: error: boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp: No such file or directory ./boost/thread/locks.hpp:17:76: error: boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp: No such file or directory
Regards,
Roland _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Hi, I see the error. You can remove the installed part for Boost.Thread. There is a dependency to my own Converion library, which was not packaged on the zip file. Or add the Conversion library from the sandbox. I will release this evening the complete package? Thanks for the report, Vicente -- View this message in context: http://old.nabble.com/-chrono--v0.4.1-%2B-thread_clock-implementation-on-Win... Sent from the Boost - Dev mailing list archive at Nabble.com.

Vicente Botet Escriba wrote:
Hi,
I see the error. You can remove the installed part for Boost.Thread. There is a dependency to my own Converion library, which was not packaged on the zip file. Or add the Conversion library from the sandbox.
I will release this evening the complete package?
Thanks for the report, Vicente
Ok, will try again tomorrow morning :-) Regards, Roland

----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Thursday, June 17, 2010 5:20 PM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
Vicente Botet Escriba wrote:
Hi,
I see the error. You can remove the installed part for Boost.Thread. There is a dependency to my own Converion library, which was not packaged on the zip file. Or add the Conversion library from the sandbox.
I will release this evening the complete package?
Thanks for the report, Vicente
Ok, will try again tomorrow morning :-)
Done. I have update the sandbox and the vault. Vicente

vicente.botet wrote:
----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Thursday, June 17, 2010 5:20 PM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
Vicente Botet Escriba wrote:
Hi,
I see the error. You can remove the installed part for Boost.Thread. There is a dependency to my own Converion library, which was not packaged on the zip file. Or add the Conversion library from the sandbox.
I will release this evening the complete package?
Thanks for the report, Vicente
Ok, will try again tomorrow morning :-)
Done. I have update the sandbox and the vault.
Vicente
Hi, there's still something wrong, I'm afraid. Now I get gcc.compile.c++ build/boost/bin.v2/libs/thread/build/gcc-4.2.4/release/threading-multi/pthread/thread.o In file included from ./boost/thread/pthread/thread_data.hpp:15, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/pthread/condition_variable_fwd.hpp:21:45: error: boost/thread/detail/cv_status.hpp: No such file or directory In file included from ./boost/thread/pthread/thread_data.hpp:15, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/pthread/condition_variable_fwd.hpp:93: error: expected constructor, destructor, or type conversion before ‘(’ token ./boost/thread/pthread/condition_variable_fwd.hpp:106: error: expected constructor, destructor, or type conversion before ‘(’ token In file included from ./boost/thread/condition_variable.hpp:17, from ./boost/thread/pthread/shared_mutex.hpp:13, from ./boost/thread/shared_mutex.hpp:16, from ./boost/thread/detail/thread_group.hpp:9, from ./boost/thread/thread.hpp:24, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/pthread/condition_variable.hpp:164: error: expected constructor, destructor, or type conversion before ‘(’ token ./boost/thread/pthread/condition_variable.hpp:177: error: expected constructor, destructor, or type conversion before ‘(’ token Regards, Roland

----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Friday, June 18, 2010 9:36 AM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
vicente.botet wrote:
----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Thursday, June 17, 2010 5:20 PM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
Hi,
there's still something wrong, I'm afraid. Now I get
gcc.compile.c++ build/boost/bin.v2/libs/thread/build/gcc-4.2.4/release/threading-multi/pthread/thread.o In file included from ./boost/thread/pthread/thread_data.hpp:15, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/pthread/condition_variable_fwd.hpp:21:45: error: boost/thread/detail/cv_status.hpp: No such file or directory
Hi, I missed to commit the file boost/thread/detail/cv_status.hpp :( Done now and uploaded on the vault. Thanks for your report, Vicente

vicente.botet wrote:
----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Friday, June 18, 2010 9:36 AM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
vicente.botet wrote:
----- Original Message ----- From: "Roland Bock" <rbock@eudoxos.de> To: <boost@lists.boost.org> Sent: Thursday, June 17, 2010 5:20 PM Subject: Re: [boost] [chrono] v0.4.1 + thread_clock implementation on Windows
Hi,
there's still something wrong, I'm afraid. Now I get
gcc.compile.c++ build/boost/bin.v2/libs/thread/build/gcc-4.2.4/release/threading-multi/pthread/thread.o In file included from ./boost/thread/pthread/thread_data.hpp:15, from ./boost/thread/thread.hpp:17, from libs/thread/src/pthread/thread.cpp:10: ./boost/thread/pthread/condition_variable_fwd.hpp:21:45: error: boost/thread/detail/cv_status.hpp: No such file or directory
Hi,
I missed to commit the file boost/thread/detail/cv_status.hpp :(
Done now and uploaded on the vault.
Thanks for your report, Vicente
Hi, it compiles fine now :-) Regards, Roland

Roland Bock-2 wrote:
Hi,
it compiles fine now :-)
Hi Roland, which platform and compiler have you tested? Thanks, Vicente -- View this message in context: http://old.nabble.com/-chrono--v0.4.1-%2B-thread_clock-implementation-on-Win... Sent from the Boost - Dev mailing list archive at Nabble.com.
participants (3)
-
Roland Bock
-
Vicente Botet Escriba
-
vicente.botet