[llvm] [AMDGPU] Add lit() asm operand modifier for SP3 compatibility. (PR #68839)

Stanislav Mekhanoshin via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 12 01:54:13 PDT 2023


rampitec wrote:

> > abs(neg()) is not. Which also makes sense, as you cannot really do abs(neg()) in a non-constant case
> 
> abs(neg(x)) could be treated as abs(x).

It probably could, but it sounds like an user error, and then asm silently accepting this error. After all asm is not a high level language where it could be justified. I can imagine this sort of constructs created by a pre-processor, but I do not really think an asm writer expects this trap. Asm is not a tool to prevent an user to shot himself in a foot, but creating such traps is not its goal either.

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


More information about the llvm-commits mailing list