[llvm-branch-commits] [IR] Introduce `llvm.experimental.hot()` (PR #84850)

Nikita Popov via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Tue Mar 12 01:56:44 PDT 2024


================
@@ -27639,6 +27639,54 @@ constant `true`. However it is always correct to replace
 it with any other `i1` value. Any pass can
 freely do it if it can benefit from non-default lowering.
 
+'``llvm.experimental.hot``' Intrinsic
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Syntax:
+"""""""
+
+::
+
+      declare i1 @llvm.experimental.hot()
+
+Overview:
+"""""""""
+
+This intrinsic returns true iff it's known that containing basic block is hot in
+profile.
+
+When used with profile based optimization allows to change program behaviour
+deppending on the code hotness.
----------------
nikic wrote:

```suggestion
depending on the code hotness.
```

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


More information about the llvm-branch-commits mailing list