Fixes #202374. Preserve LLVM function `!prof` metadata for: - `synthetic_function_entry_count` - `function_entry_count` with import GUID operands The importer represents the entry count, count kind, and trailing import GUID operands in a single `#llvm.function_entry_count` attribute, validates malformed operands before mutating the operation, and exports the metadata through `llvm::Function::setEntryCount`. Tests cover import, export, malformed metadata operands, synthetic counts, synthetic counts with trailing operands, import GUID round-tripping, and raw i64 bit-pattern preservation. Checks: - `git diff --check` - `git clang-format --diff origin/main -- ...` - `llvm-as -disable-output` smoke check Codex was used in making this PR. |
||
|---|---|---|
| .. | ||
| benchmark/python | ||
| cmake/modules | ||
| docs | ||
| examples | ||
| include | ||
| lib | ||
| python | ||
| test | ||
| tools | ||
| unittests | ||
| utils | ||
| .clang-format | ||
| .clang-tidy | ||
| CMakeLists.txt | ||
| LICENSE.TXT | ||
| Maintainers.md | ||
| README.md | ||
Multi-Level Intermediate Representation
See https://mlir.llvm.org/ for more information.