[llvm] [LangRef] inline asm: the instructions are treated opaquely (PR #157080)
Jacob Lifshay via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 23 05:33:38 PDT 2025
programmerjake wrote:
analyzing the asm string seems fine to me as long as the output is still correct if the asm string is replaced at runtime with any other asm string -- so that means the compiler can look at it to guess how many instructions it contains and their latency to schedule code around it, but the compiler isn't allowed to e.g. see that it's an empty string and assume it can never have any effect, or see that it writes a `1` to `rax` and assume that `rax` will be `1` afterwards or even that the asm will not have an infinite loop or not terminate the program.
https://github.com/llvm/llvm-project/pull/157080
More information about the llvm-commits
mailing list