[libc-commits] [PATCH] D153388: [libc] Add basic utility support for timing functions on the GPU

Joseph Huber via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed Jun 21 07:20:40 PDT 2023


jhuber6 added a comment.

In D153388#4437780 <https://reviews.llvm.org/D153388#4437780>, @JonChesterfield wrote:

> Is that the right basis set? I wonder if we want cycle_count, frequency, width as the controls. It seems like PTX wants to do ns granularity which is useful and GCN needs the loader to write to a global to get the frequency value, and the type wraparound could be anywhere from 20 to 64

It describes what the underlying counters are. We could mention that the fixed frequency is 1E9 on PTX and some runtime value on AMDGCN. Relative timings should be fine in either case. The 20 bits is unfortunate but only affects gfx11xx architectures since we still have `s_memtime` on `gfx10xx`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D153388/new/

https://reviews.llvm.org/D153388



More information about the libc-commits mailing list