[llvm] [AMDGPU] Fix operand definitions for atomic scalar memory instructions. (PR #71799)
    Ivan Kosarev via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Thu Nov  9 05:30:12 PST 2023
    
    
  
================
@@ -909,6 +909,10 @@ class AMDGPUOperand : public MCParsedAsmOperand {
   bool isWaitVDST() const;
   bool isWaitEXP() const;
 
+  auto getPredicate(std::function<bool(const AMDGPUOperand &Op)> P) const {
----------------
kosarev wrote:
I think I'd prefer to have a single generic helper and use that to avoid scattering details of operand definitions over multiple places. Ultimately, the idea is to have an interface to AsmParser that would allow implementing a new kind of operands with a couple lines in a single place in an intuitive manner and not being wrong thinking it does the expected thing.
https://github.com/llvm/llvm-project/pull/71799
    
    
More information about the llvm-commits
mailing list