Opened 9 years ago

Closed 9 years ago

#9342 closed Bugs (fixed)

Regression on process_cpu_clock::timepoint io on V2

Reported by: viboes Owned by: viboes
Milestone: Boost 1.56.0 Component: chrono
Version: Boost 1.54.0 Severity: Problem
Keywords: Cc:

Description (last modified by viboes)

The following example

#define BOOST_CHRONO_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0
#include <boost/chrono/chrono_io.hpp>

int main() {
  std::cout<< boost::chrono::process_cpu_clock::now() << std::endl; 
}

outputs

{1383629724660000000;0;0} nanoseconds since process start-up

while if BOOST_CHRONO_PROVIDES_DEPRECATED_IO_SINCE_V2_0_0 is not defined, it outputs

1383629672240000000 nanoseconds since process start-up

A process_cpu_clock::duration::rep is a tuple like of 3 clocks real, user and system.

The same problem for input. V1 manages a format {v1,v2;v3} and is able to restore the 3 clocks, but V2 takes only the real clock in account.

Change History (4)

comment:1 by viboes, 9 years ago

Status: newassigned

comment:2 by viboes, 9 years ago

Description: modified (diff)

comment:4 by viboes, 9 years ago

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.