You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The *branch hint section* is a **custom section** whose name string is `metadata.code.branch_hint`.
87
87
The branch hints section should appear only once in a module, and only before the code section.
88
88
89
-
The purpose of this section is to aid the compilation of conditional branch instructions, by providing a hint that a branchis very likely (or unlikely) to be taken.
89
+
The purpose of this section is to aid the compilation of conditional branch instructions, by providing a hint that a branch's condition is very likely (or unlikely) to be true.
90
90
91
91
The section contains a vector of *function branch hints* each representing the branch hints for a single function.
92
92
@@ -104,10 +104,10 @@ Each *branch hint* structure consists of
104
104
* A |U32| with value `1`,
105
105
* a |U32| indicating the meaning of the hint:
106
106
107
-
| value | meaning |
108
-
|-------|-------------------|
109
-
| 0 |likely not taken |
110
-
| 1 |likely taken |
107
+
| value | meaning |
108
+
|-------|---------------------------|
109
+
| 0 |condition is likely false|
110
+
| 1 |condition is likely true|
111
111
112
112
Elements of the vector of *branch hint* must appear in increasing byte offset order,
113
113
and a byte offset can appear at most once. A |BRIF| or |IF| instruction must be present
0 commit comments