Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[libc] Implement clock_gettime for the monotonic clock on the GPU #99067

Merged
merged 1 commit into from
Jul 16, 2024

Commits on Jul 16, 2024

  1. [libc] Implement clock_gettime for the monotonic clock on the GPU

    Summary:
    This patch implements `clock_gettime` using the monotonic clock. This
    allows users to get time elapsed at nanosecond resolution. This is
    primarily to facilitate compiling the `chrono` library from `libc++`.
    For this reason we provide both `CLOCK_MONOTONIC`, which we can implement
    with the GPU's global fixed-frequency clock, and `CLOCK_REALTIME` which
    we cannot. The latter is provided just to make people who use this
    header happy and it will always return failure.
    jhuber6 committed Jul 16, 2024
    Configuration menu
    Copy the full SHA
    4f97696 View commit details
    Browse the repository at this point in the history