Files
clang-p2996/llvm/lib/Support/BlockFrequency.cpp
Matthias Braun b0c8c45423 Avoid BlockFrequency overflow problems (#66280)
Multiplying raw block frequency with an integer carries a high risk
of overflow.

- Add `BlockFrequency::mul` return an std::optional with the product
  or `nullopt` to indicate an overflow.
- Fix two instances where overflow was likely.
2023-09-14 11:11:27 -07:00

1.4 KiB