• Avi Drissman's avatar
    Revert "Re-land "Switch Mac to use time_exploded_posix.cc."" · ac4c8a25
    Avi Drissman authored
    This reverts commit af2ab97d.
    
    Reason for revert:
    
    This breaks the "ios-simulator" trybot on my CL. See https://chromium-review.googlesource.com/c/chromium/src/+/590273 and failed trybots runs at
    
    https://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/builds/337162
    https://build.chromium.org/p/tryserver.chromium.mac/builders/ios-simulator/builds/337212
    
    which has TimeTest.TimeT/0 failing:
    TimeTest.TimeT:
    ../../base/time/time_unittest.cc:134: Failure
          Expected: tms.tm_hour
          Which is: 14
    To be equal to: exploded.hour
          Which is: 22
    
    
    Original change's description:
    > Re-land "Switch Mac to use time_exploded_posix.cc."
    > 
    > Original review:
    > https://chromium-review.googlesource.com/c/chromium/src/+/754079
    > Reverted here:
    > https://chromium-review.googlesource.com/c/chromium/src/+/760116
    > 
    > Previously, we would use a CoreFoundation-based version of these
    > functions implemented in time_mac.cc because time_t on Mac was
    > capped at year 2038. However, with 64-bit that is no longer the
    > case and we can just use time_exploded_posix.cc.
    > 
    > From UMA sampling profiler data (see bug), we know that the
    > CoreFoundation versions of these functions are slow and currently
    > account for around 80ms cost during startup. After this change
    > is submitted and makes it to Canary, we can see how the POSIX
    > versions of these functions perform - hopefully much faster than
    > the CoreFoundation ones.
    > 
    > Some code in net/ had assumptions around the min and max years
    > that are supported on different platforms by these functions. To
    > make that logic a bit cleaner, this CL introduces two constants
    > in time.h specifying the platform-specific limits - so that
    > downstream code like net can use them instead of baking their
    > own assumptions. Some net error codes are changing as a result
    > of this clean up - which can be seen in the updated net tests.
    > 
    > BUG=781601
    > 
    > Cq-Include-Trybots: master.tryserver.chromium.android:android_cronet_tester;master.tryserver.chromium.mac:ios-simulator-cronet
    > Change-Id: I5d10a06dd5b0073bfd943f58af08f67980227d4a
    > Reviewed-on: https://chromium-review.googlesource.com/760443
    > Reviewed-by: Matt Mueller <mattm@chromium.org>
    > Reviewed-by: Yuri Wiitala <miu@chromium.org>
    > Reviewed-by: Mark Mentovai <mark@chromium.org>
    > Commit-Queue: Alexei Svitkine <asvitkine@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#515370}
    
    TBR=miu@chromium.org,mattm@chromium.org,asvitkine@chromium.org,mmenke@chromium.org,mark@chromium.org
    
    Change-Id: I4a582e11d4fd8490cf22cc37d4d746b4c3731957
    No-Presubmit: true
    No-Tree-Checks: true
    No-Try: true
    Bug: 781601
    Cq-Include-Trybots: master.tryserver.chromium.android:android_cronet_tester;master.tryserver.chromium.mac:ios-simulator-cronet
    Reviewed-on: https://chromium-review.googlesource.com/764868Reviewed-by: default avatarAvi Drissman <avi@chromium.org>
    Commit-Queue: Avi Drissman <avi@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#515727}
    ac4c8a25
x509_certificate.cc 35 KB