Is it possible to build a monotonic clock out of a non-monotonic clock in
I could force it to be monotonic with some static storage and a max=, but would
that be correct?
mclow and I discussed this offline, and max= is not going to work:
18.104.22.168/1: Objects of class steady_clock represent clocks for which values of time_point never decrease as physical time advances and for which values of time_point advance at a steady rate relative to real time.
I'll look into what breaks if steady_clock isn't provided on systems without _POSIX_MONOTONIC_CLOCK, and go from there.
On systems without a monotonic clock, it's probably better to not have steady_clock than to have a non-conforming one.
Since steady_clock is used for timed mutexes and such, something like: http://reviews.llvm.org/D3969 is probably necessary to actually build libc++ without a a monotonic clock. I'll be picking that patch up for upstreaming again here shortly.