|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r77797 - in trunk: boost/chrono/io boost/chrono/io_v1 libs/chrono/build libs/chrono/doc libs/chrono/perf libs/chrono/test
From: vicente.botet_at_[hidden]
Date: 2012-04-06 20:19:40
Author: viboes
Date: 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
New Revision: 77797
URL: http://svn.boost.org/trac/boost/changeset/77797
Log:
Chrono: Remove traces + try __typeof__ trink on sun + update history
Text files modified:
trunk/boost/chrono/io/time_point_io.hpp | 74 ++++++++++++++++++++--------------------
trunk/boost/chrono/io_v1/chrono_io.hpp | 74 ++++++++++++++++++++--------------------
trunk/libs/chrono/build/Jamfile.v2 | 10 +++-
trunk/libs/chrono/doc/chrono.qbk | 10 +++++
trunk/libs/chrono/perf/store_now_in_vector.cpp | 9 +++-
trunk/libs/chrono/test/Jamfile.v2 | 5 ++
6 files changed, 101 insertions(+), 81 deletions(-)
Modified: trunk/boost/chrono/io/time_point_io.hpp
==============================================================================
--- trunk/boost/chrono/io/time_point_io.hpp (original)
+++ trunk/boost/chrono/io/time_point_io.hpp 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -276,24 +276,24 @@
std::basic_istream<CharT, Traits>&
operator>>(std::basic_istream<CharT, Traits>& is, time_point<Clock, Duration>& tp)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
std::ios_base::iostate err = std::ios_base::goodbit;
try
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
typename std::basic_istream<CharT, Traits>::sentry ipfx(is);
if (ipfx)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (!std::has_facet<time_point_get<CharT> >(is.getloc()))
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
time_point_get<CharT> ().get(is, std::istreambuf_iterator<CharT, Traits>(), is, err, tp);
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
std::use_facet<time_point_get<CharT> >(is.getloc()).get(is, std::istreambuf_iterator<CharT, Traits>(), is,
err, tp);
}
@@ -301,24 +301,24 @@
}
catch (...)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
bool flag = false;
try
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(std::ios_base::failbit);
}
catch (std::ios_base::failure )
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
flag = true;
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (flag) throw;
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
}
if (err) is.setstate(err);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
return is;
}
@@ -389,15 +389,15 @@
std::basic_ostream<CharT, Traits>&
operator<<(std::basic_ostream<CharT, Traits>& os, const time_point<system_clock, Duration>& tp)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
typename std::basic_ostream<CharT, Traits>::sentry ok(os);
if (ok)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
bool failed = false;
try
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
const CharT* pb = 0; //nullptr;
const CharT* pe = pb;
std::basic_string<CharT> fmt = get_time_fmt<CharT> (os);
@@ -410,7 +410,7 @@
std::tm tm;
if (tz == timezone::local)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
#if defined BOOST_WINDOWS && ! defined(__CYGWIN__)
std::tm *tmp = 0;
if ((tmp=localtime(&t)) == 0)
@@ -422,7 +422,7 @@
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
#if defined BOOST_WINDOWS && ! defined(__CYGWIN__)
std::tm *tmp = 0;
if((tmp = gmtime(&t)) == 0)
@@ -433,14 +433,14 @@
#endif
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (!failed)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
const std::time_put<CharT>& tpf = std::use_facet<std::time_put<CharT> >(loc);
if (pb == pe)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
CharT pattern[] =
{ '%', 'Y', '-', '%', 'm', '-', '%', 'd', ' ', '%', 'H', ':', '%', 'M', ':' };
pb = pattern;
@@ -448,34 +448,34 @@
failed = tpf.put(os, os, os.fill(), &tm, pb, pe).failed();
if (!failed)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
duration<double> d = tp - system_clock::from_time_t(t) + seconds(tm.tm_sec);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (d.count() < 10) os << CharT('0');
if (! os.good()) {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
throw "exception";
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
std::ios::fmtflags flgs = os.flags();
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
os.setf(std::ios::fixed, std::ios::floatfield);
if (! os.good()) {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
throw "exception";
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< " " << d.count() << std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< " " << d.count() << std::endl;
os << d.count();
if (! os.good()) {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
throw "exception";
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< " " << d.count() << std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< " " << d.count() << std::endl;
os.flags(flgs);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (tz == timezone::local)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
CharT sub_pattern[] =
{ ' ', '%', 'z' };
pb = sub_pattern;
@@ -484,34 +484,34 @@
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
CharT sub_pattern[] =
{ ' ', '+', '0', '0', '0', '0', 0 };
os << sub_pattern;
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
failed = tpf.put(os, os, os.fill(), &tm, pb, pe).failed();
}
}
}
catch (...)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
failed = true;
}
if (failed)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
os.setstate(std::ios_base::failbit | std::ios_base::badbit);
}
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
return os;
}
Modified: trunk/boost/chrono/io_v1/chrono_io.hpp
==============================================================================
--- trunk/boost/chrono/io_v1/chrono_io.hpp (original)
+++ trunk/boost/chrono/io_v1/chrono_io.hpp 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -265,59 +265,59 @@
std::basic_istream<CharT, Traits>&
operator>>(std::basic_istream<CharT, Traits>& is, duration<Rep, Period>& d)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
typedef duration_punct<CharT> Facet;
std::locale loc = is.getloc();
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (!std::has_facet<Facet>(loc)) {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.imbue(std::locale(loc, new Facet));
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
loc = is.getloc();
const Facet& f = std::use_facet<Facet>(loc);
typedef typename chrono_detail::duration_io_intermediate<Rep>::type intermediate_type;
intermediate_type r;
std::ios_base::iostate err = std::ios_base::goodbit;
// read value into r
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is >> r;
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (is.good())
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// now determine unit
typedef std::istreambuf_iterator<CharT, Traits> in_iterator;
in_iterator i(is);
in_iterator e;
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (i != e && *i == ' ') // mandatory ' ' after value
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
++i;
if (i != e)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// unit is num / den (yet to be determined)
unsigned long long num = 0;
unsigned long long den = 0;
if (*i == '[')
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// parse [N/D]s or [N/D]seconds format
++i;
CharT x;
is >> num >> x >> den;
if (!is.good() || (x != '/'))
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(is.failbit);
return is;
}
i = in_iterator(is);
if (*i != ']')
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(is.failbit);
return is;
}
@@ -328,27 +328,27 @@
f.template plural<ratio<1> >(),
f.template short_name<ratio<1> >()
};
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
const std::basic_string<CharT>* k = chrono_detail::scan_keyword(i, e,
units, units + sizeof(units)/sizeof(units[0]),
//~ std::use_facet<std::ctype<CharT> >(loc),
err);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(err);
switch ((k - units) / 3)
{
case 0:
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
break;
default:
is.setstate(err);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
return is;
}
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// parse SI name, short or long
const std::basic_string<CharT> units[] =
{
@@ -410,12 +410,12 @@
f.template plural<ratio<3600> >(),
f.template short_name<ratio<3600> >()
};
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
const std::basic_string<CharT>* k = chrono_detail::scan_keyword(i, e,
units, units + sizeof(units)/sizeof(units[0]),
//~ std::use_facet<std::ctype<CharT> >(loc),
err);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
switch ((k - units) / 3)
{
case 0:
@@ -495,12 +495,12 @@
den = 1;
break;
default:
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(err|is.failbit);
return is;
}
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// unit is num/den
// r should be multiplied by (num/den) / Period
// Reduce (num/den) / Period to lowest terms
@@ -513,7 +513,7 @@
if (num > (std::numeric_limits<unsigned long long>::max)() / d2 ||
den > (std::numeric_limits<unsigned long long>::max)() / n2)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// (num/den) / Period overflows
is.setstate(err|is.failbit);
return is;
@@ -523,68 +523,68 @@
typedef typename common_type<intermediate_type, unsigned long long>::type common_type_t;
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// num / den is now factor to multiply by r
if (!chrono_detail::reduce(r, den, err))
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(err|is.failbit);
return is;
}
//if (r > ((duration_values<common_type_t>::max)() / num))
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (chrono::detail::gt(r,((duration_values<common_type_t>::max)() / num)))
{
// Conversion to Period overflowed
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(err|is.failbit);
return is;
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
common_type_t t = r * num;
t /= den;
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (t > 0)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
Rep pt = t;
if ( (duration_values<Rep>::max)() < pt)
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// Conversion to Period overflowed
is.setstate(err|is.failbit);
return is;
}
}
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
// Success! Store it.
r = Rep(t);
d = duration<Rep, Period>(r);
is.setstate(err);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
return is;
}
else {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
is.setstate(is.failbit | is.eofbit);
return is;
}
}
else
{
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
if (i == e)
is.setstate(is.failbit|is.eofbit);
else
is.setstate(is.failbit);
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
return is;
}
}
else {
- std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
+ //std::cerr << __FILE__ << "[" << __LINE__ << "]"<< std::endl;
//is.setstate(is.failbit);
return is;
}
Modified: trunk/libs/chrono/build/Jamfile.v2
==============================================================================
--- trunk/libs/chrono/build/Jamfile.v2 (original)
+++ trunk/libs/chrono/build/Jamfile.v2 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -25,7 +25,9 @@
#<define>BOOST_COMMON_TYPE_USES_ARRAY_ASSERT
#<define>BOOST_RATIO_USES_ARRAY_ASSERT
#<define>BOOST_CHRONO_USES_ARRAY_ASSERT
- <toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ #<toolset>sun:<define>BOOST_COMMON_TYPE_DONT_USE_TYPEOF
+ #<toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ <toolset>sun:<define>__typeof__=__typeof__
<define>BOOST_SYSTEM_NO_DEPRECATED
#<toolset>gcc-3.4.4:<linkflags>--enable-auto-import
#<toolset>gcc-4.3.4:<linkflags>--enable-auto-import
@@ -66,8 +68,10 @@
#<define>BOOST_COMMON_TYPE_USES_ARRAY_ASSERT
#<define>BOOST_RATIO_USES_ARRAY_ASSERT
#<define>BOOST_CHRONO_USES_ARRAY_ASSERT
- <toolset>sun:<define>BOOST_COMMON_TYPE_DONT_USE_TYPEOF
- <toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ #<toolset>sun:<define>BOOST_COMMON_TYPE_DONT_USE_TYPEOF
+ #<toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ <toolset>sun:<define>__typeof__=__typeof__
+
<define>BOOST_SYSTEM_NO_DEPRECATED
<link>shared:<define>BOOST_CHRONO_DYN_LINK=1
<link>static:<define>BOOST_CHRONO_STATIC_LINK=1
Modified: trunk/libs/chrono/doc/chrono.qbk
==============================================================================
--- trunk/libs/chrono/doc/chrono.qbk (original)
+++ trunk/libs/chrono/doc/chrono.qbk 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -7605,6 +7605,16 @@
[endsect] [/section [*Version 2.0.0] ]
+[section [*Version 1.2.2, April 1, 2012 - 1.50] ]
+
+[*Fixes:]
+
+* [@http://svn.boost.org/trac/boost/ticket/6361 #6361] integer overflow in boost::chrono::process_real_cpu_clock::now() under Windows 32bits.
+* [@http://svn.boost.org/trac/boost/ticket/6628 #6628] compiler warning in process_cpu_clocks.hpp.
+* [@http://svn.boost.org/trac/boost/ticket/6666 #6666] thread_clock.hpp needs pthread.h.
+
+[endsect] [/section [*Version 1.2.2] ]
+
[section [*Version 1.2.1, February 1, 2012 - 1.49] ]
[*Fixes:]
Modified: trunk/libs/chrono/perf/store_now_in_vector.cpp
==============================================================================
--- trunk/libs/chrono/perf/store_now_in_vector.cpp (original)
+++ trunk/libs/chrono/perf/store_now_in_vector.cpp 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -16,7 +16,7 @@
#endif
//static const std::size_t size = 10000000;
-static const std::size_t size = 10000;
+ static const std::size_t size = 2000000;
typedef boost::chrono::simple_stopwatch<boost::chrono::high_resolution_clock> Stopwatch;
typedef boost::chrono::stopwatch_reporter<Stopwatch> Reporter;
@@ -50,6 +50,8 @@
perf<Clock>(vec);
Stopwatch::duration t2 = sw2.elapsed();
std::cout <<" "<< (t2-t1)/size << std::endl;
+ std::cout <<" "<< t2 << std::endl;
+ std::cout <<" "<< t1 << std::endl;
std::size_t cnt=0;
for (int i=size-1; i>0; --i)
{
@@ -134,12 +136,13 @@
std::cout << "process_cpu_clock " ;
test<boost::chrono::process_cpu_clock>();
#endif
-
+ std::cout << "system_clock ";
+ test<boost::chrono::system_clock>();
#if 0
std::cout << "times ";
test2();
std::cout << "clock ";
test3();
#endif
- return 0;
+ return 1;
}
Modified: trunk/libs/chrono/test/Jamfile.v2
==============================================================================
--- trunk/libs/chrono/test/Jamfile.v2 (original)
+++ trunk/libs/chrono/test/Jamfile.v2 2012-04-06 20:19:39 EDT (Fri, 06 Apr 2012)
@@ -15,12 +15,15 @@
: requirements
<target-os>freebsd:<linkflags>"-lrt"
<target-os>linux:<linkflags>"-lrt"
+ <toolset>clang/<target-os>linux:<linkflags>"-lpthread"
<toolset>pgi:<linkflags>"-lrt"
#<threading>single:<define>BOOST_CHRONO_THREAD_DISABLED
<toolset>msvc:<asynch-exceptions>on
<define>BOOST_CHRONO_USES_MPL_ASSERT
<define>BOOST_SYSTEM_NO_DEPRECATED
- <toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ #<toolset>sun:<define>BOOST_COMMON_TYPE_DONT_USE_TYPEOF
+ #<toolset>sun:<define>BOOST_TYPEOF_EMULATION
+ <toolset>sun:<define>__typeof__=__typeof__
<warnings>all
<toolset>gcc:<cxxflags>-Wextra
<toolset>gcc:<cxxflags>-pedantic
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk