| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[libc] Add Multithreaded GPU Benchmarks (#98964) This PR runs benchmarks on a 32 threads (A single warp on NVPTX) by default, adding the option for single threaded benchmarks. We can specify that a benchmark should be run on a single thread using the SINGLE_THREADED_BENCHMARK() macro. I chose to use a flag here so that other options could be added in the future. | 2 年前 | |
[libc][gpu] Add exp/log benchmarks and flexible input generation (#155727) This patch adds GPU benchmarks for the exp ( exp, expf, expf16) and log (log, logf, logf16) families of math functions. Adding these benchmarks revealed a key limitation in the existing framework: the input generation mechanism was hardcoded to a single strategy that sampled numbers with a uniform distribution of their unbiased exponents. While this strategy is effective for values spanning multiple orders of magnitude, it is not suitable for linear ranges. The previous framework lacked the flexibility to support this. ### Summary of Changes **1. Framework Refactoring for Flexible Input Sampling:** The GPU benchmark framework was refactored to support multiple, pluggable input sampling strategies. * **Random.h:** A new header was created to house the RandomGenerator and the new distribution classes. * **Distribution Classes:** Two sampling strategies were implemented: * UniformExponent: Formalizes the previous logic of sampling numbers with a uniform distribution of their unbiased exponents. It can now also be configured to produce only positive values, which is essential for functions like log. * UniformLinear: A new strategy that samples numbers from a uniform distribution over a linear interval [min, max). * **MathPerf Update:** The MathPerf class was updated with a generic run_throughput method that is templated on a distribution object. This makes the framework extensible to future sampling strategies. **2. New Benchmarks for exp and log:** Using the newly refactored framework, benchmarks were added for exp, expf, expf16, log, logf, and logf16. The test intervals were carefully chosen to measure the performance of distinct behavioral regions of each function. | 11 个月前 | |
[libc] Add Generic and NVPTX Sin Benchmark (#99795) This PR adds sin benchmarking for a range of values and on a pregenerated random distribution. | 1 年前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 2 年前 | ||
| 11 个月前 | ||
| 1 年前 |