[compiler-rt] [llvm] [PGO] Add option to always instrumenting loop entries (PR #116789)

Ellis Hoag via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 25 12:17:32 PST 2024


================
@@ -742,9 +744,10 @@ serializeValueProfDataFrom(ValueProfRecordClosure *Closure,
  */
 #define VARIANT_MASKS_ALL 0xffffffff00000000ULL
 #define GET_VERSION(V) ((V) & ~VARIANT_MASKS_ALL)
-#define VARIANT_MASK_IR_PROF (0x1ULL << 56)
-#define VARIANT_MASK_CSIR_PROF (0x1ULL << 57)
-#define VARIANT_MASK_INSTR_ENTRY (0x1ULL << 58)
+#define VARIANT_MASK_IR_PROF (0x1ULL << 55)
+#define VARIANT_MASK_CSIR_PROF (0x1ULL << 56)
+#define VARIANT_MASK_INSTR_ENTRY (0x1ULL << 57)
----------------
ellishg wrote:

I don't actually remember. I think `VARIANT_MASK_IR_PROF` was actually the first mask and later ones used higher bits. But we cannot go any higher. There might be some reason we started at `55`. At first glance it seems that using bit `54` should be fine.

https://github.com/llvm/llvm-project/pull/116789


More information about the llvm-commits mailing list