[llvm] r265585 - [RegisterBankInfo] Get rid of the assert in the constructor of InstructionMapping.

Quentin Colombet via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 6 11:43:46 PDT 2016


Author: qcolombet
Date: Wed Apr  6 13:43:46 2016
New Revision: 265585

URL: http://llvm.org/viewvc/llvm-project?rev=265585&view=rev
Log:
[RegisterBankInfo] Get rid of the assert in the constructor of InstructionMapping.

The default constructor now uses the regular constructor and the assert
is not valid anymore.

Modified:
    llvm/trunk/include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h

Modified: llvm/trunk/include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h?rev=265585&r1=265584&r2=265585&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h (original)
+++ llvm/trunk/include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h Wed Apr  6 13:43:46 2016
@@ -100,8 +100,6 @@ public:
     /// \pre ID != InvalidMappingID
     InstructionMapping(unsigned ID, unsigned Cost, unsigned NumOperands)
         : ID(ID), Cost(Cost), NumOperands(NumOperands) {
-      assert(getID() != InvalidMappingID &&
-             "Use the default constructor for invalid mapping");
       OperandsMapping.reset(new ValueMapping[getNumOperands()]);
     }
 




More information about the llvm-commits mailing list