downscale the given weights preserving the ratio. If the maximum value is not already known and not provided via
Declared in <llvm/IR/ProfDataUtils.h>
SmallVector<uint32_t>
downscaleWeights(
ArrayRef<uint64_t> Weights,
std::optional<uint64_t> KnownMaxCount = std::nullopt);
The downscaled 32-bit weights, preserving the original ratio.
| Name | Description |
|---|---|
| KnownMaxCount | , it will be obtained from |
| Weights | The 64-bit weights to downscale. |