[PATCH] D129518: [BOLT] Add function layout class
Fabian Parzefall via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 13 06:37:56 PDT 2022
FPar marked an inline comment as done.
FPar added inline comments.
================
Comment at: bolt/include/bolt/Core/FunctionLayout.h:42
+ /// Named fragment when hot/cold splitting is used.
+ enum NamedFragment : unsigned { NF_HOT = 0, NF_COLD = 1 };
+
----------------
tschuett wrote:
> If you use an enum class, then you can get rid of the prefixes.
This enum is to be used temporarily to pass into APIs that take a fragment number as parameter for parts of BOLT that are only hot/cold aware (so we can perform a more incremental transition from relying on .blocks() to being fully multi-fragment aware). The code using those values will be nicer if they automatically convert to unsigned. Thanks for looking over this!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129518/new/
https://reviews.llvm.org/D129518
More information about the llvm-commits
mailing list