reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

examples/HowToUseJIT/HowToUseJIT.cpp
   88   assert(Add1F->arg_begin() != Add1F->arg_end()); // Make sure there's an arg
examples/HowToUseLLJIT/HowToUseLLJIT.cpp
   45   assert(Add1F->arg_begin() != Add1F->arg_end()); // Make sure there's an arg
examples/Kaleidoscope/BuildingAJIT/Chapter1/toy.cpp
  269     assert(isUnaryOp() || isBinaryOp());
  809   assert(F && "binary operator not found!");
 1162       assert(FP && "Failed to codegen function");
examples/Kaleidoscope/BuildingAJIT/Chapter2/toy.cpp
  269     assert(isUnaryOp() || isBinaryOp());
  809   assert(F && "binary operator not found!");
 1162       assert(FP && "Failed to codegen function");
examples/Kaleidoscope/BuildingAJIT/Chapter3/toy.cpp
  269     assert(isUnaryOp() || isBinaryOp());
  808   assert(F && "binary operator not found!");
 1149       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/BuildingAJIT/Chapter4/KaleidoscopeJIT.h
  161       assert(Sym && "Couldn't find compiled function?");
examples/Kaleidoscope/BuildingAJIT/Chapter4/toy.cpp
  269     assert(isUnaryOp() || isBinaryOp());
  794   assert(F && "binary operator not found!");
 1152       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/BuildingAJIT/Chapter5/KaleidoscopeJIT.h
  174       assert(Sym && "Couldn't find compiled function?");
examples/Kaleidoscope/BuildingAJIT/Chapter5/RemoteJITUtils.h
   34     assert(Dst && "Attempt to read into null.");
   52     assert(Src && "Attempt to append from null.");
examples/Kaleidoscope/BuildingAJIT/Chapter5/toy.cpp
  286     assert(isUnaryOp() || isBinaryOp());
  818   assert(F && "binary operator not found!");
 1176       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/Chapter4/toy.cpp
  611       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/Chapter5/toy.cpp
  885       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/Chapter6/toy.cpp
  252     assert(isUnaryOp() || isBinaryOp());
  707   assert(F && "binary operator not found!");
 1004       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/Chapter7/toy.cpp
  274     assert(isUnaryOp() || isBinaryOp());
  814   assert(F && "binary operator not found!");
 1174       assert(ExprSymbol && "Function not found");
examples/Kaleidoscope/Chapter8/toy.cpp
  275     assert(isUnaryOp() || isBinaryOp());
  813   assert(F && "binary operator not found!");
examples/Kaleidoscope/Chapter9/toy.cpp
  377     assert(isUnaryOp() || isBinaryOp());
  972   assert(F && "binary operator not found!");
examples/ParallelJIT/ParallelJIT.cpp
   66   assert(Add1F->arg_begin() != Add1F->arg_end()); // Make sure there's an arg
  149     assert( result == 0 );
  152     assert( result == 0 );
  159     assert( result == 0 );
  162     assert( result == 0 );
  170     assert( result == 0 );
  174     assert( waitFor == 0 || n <= waitFor );
  185       assert( result == 0 );
  190     assert( result == 0 );
  200     assert( result == 0 );
  214     assert( result == 0 );
  232     assert(result == 0);
gen/lib/Target/AArch64/AArch64GenAsmMatcher.inc
 6463   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 6475       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 6796   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
12394   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
12400       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
27454     assert(Mnemonic == it->getMnemonic());
40873     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/AArch64/AArch64GenAsmWriter.inc
11741   assert(Bits != 0 && "Cannot print this instruction.");
14155   assert(RegNo && RegNo < 629 && "Invalid register number!");
14781     assert(*(AsmStrsNoRegAltName+RegAsmOffsetNoRegAltName[RegNo-1]) &&
14785     assert(*(AsmStrsvlist1+RegAsmOffsetvlist1[RegNo-1]) &&
14789     assert(*(AsmStrsvreg+RegAsmOffsetvreg[RegNo-1]) &&
gen/lib/Target/AArch64/AArch64GenAsmWriter1.inc
12738   assert(Bits != 0 && "Cannot print this instruction.");
14871   assert(RegNo && RegNo < 629 && "Invalid register number!");
15497     assert(*(AsmStrsNoRegAltName+RegAsmOffsetNoRegAltName[RegNo-1]) &&
15501     assert(*(AsmStrsvlist1+RegAsmOffsetvlist1[RegNo-1]) &&
15505     assert(*(AsmStrsvreg+RegAsmOffsetvreg[RegNo-1]) &&
gen/lib/Target/AArch64/AArch64GenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
25814       assert(DecodeComplete);
25847         assert(S == MCDisassembler::Fail);
gen/lib/Target/AArch64/AArch64GenMCCodeEmitter.inc
21325   assert(Inst.getOpcode() < 5384);
gen/lib/Target/AArch64/AArch64GenRegisterBank.inc
  134     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/AArch64/AArch64GenRegisterInfo.inc
 6818   assert(Select < 2);
 6832   assert(Select < 2);
 6846   assert(Select < 2);
 6860   assert(Select < 2);
 6874   assert(Select < 2);
 6888   assert(Select < 2);
 8954   --IdxA; assert(IdxA < 99);
 8955   --IdxB; assert(IdxB < 99);
 9119   --IdxA; assert(IdxA < 99 && "Subregister index out of bounds");
 9133   --IdxA; assert(IdxA < 99 && "Subregister index out of bounds");
20056   assert(RC && "Missing regclass");
20059   assert(Idx < 99 && "Bad subreg");
20183   assert(RegUnit < 115 && "invalid register unit");
20331   assert(RegUnit < 115 && "invalid register unit");
gen/lib/Target/AMDGPU/AMDGPUGenAsmMatcher.inc
 3780   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 3783   assert(OptionalOperandsMask.size() == 27);
 3798       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 4008   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
10314   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
10320       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
23979     assert(Mnemonic == it->getMnemonic());
80425     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/AMDGPU/AMDGPUGenAsmWriter.inc
32459   assert(Bits != 0 && "Cannot print this instruction.");
35780   assert(RegNo && RegNo < 3666 && "Invalid register number!");
39644   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/AMDGPU/AMDGPUGenDAGISel.inc
78716   assert(N->getNumOperands() == 2);
78717   assert(N->getOperand(0).getValueType().getSizeInBits() == 16);
gen/lib/Target/AMDGPU/AMDGPUGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
42078       assert(DecodeComplete);
42111         assert(S == MCDisassembler::Fail);
gen/lib/Target/AMDGPU/AMDGPUGenMCCodeEmitter.inc
50357   assert(Inst.getOpcode() < 15263);
gen/lib/Target/AMDGPU/AMDGPUGenRegisterBank.inc
  233     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/AMDGPU/AMDGPUGenRegisterInfo.inc
25530   --IdxA; assert(IdxA < 192);
25531   --IdxB; assert(IdxB < 192);
25769   --IdxA; assert(IdxA < 192 && "Subregister index out of bounds");
25783   --IdxA; assert(IdxA < 192 && "Subregister index out of bounds");
47914   assert(RC && "Missing regclass");
47917   assert(Idx < 192 && "Bad subreg");
48047   assert(RegUnit < 699 && "invalid register unit");
48692   assert(RegUnit < 699 && "invalid register unit");
gen/lib/Target/AMDGPU/R600GenAsmWriter.inc
  795   assert(Bits != 0 && "Cannot print this instruction.");
 1184   assert(RegNo && RegNo < 1675 && "Invalid register number!");
 2822   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/AMDGPU/R600GenMCCodeEmitter.inc
 2314   assert(Inst.getOpcode() < 514);
gen/lib/Target/AMDGPU/R600GenRegisterInfo.inc
11434   --IdxA; assert(IdxA < 16);
11435   --IdxB; assert(IdxB < 16);
11481   --IdxA; assert(IdxA < 16 && "Subregister index out of bounds");
11495   --IdxA; assert(IdxA < 16 && "Subregister index out of bounds");
12176   assert(RC && "Missing regclass");
12179   assert(Idx < 16 && "Bad subreg");
12232   assert(RegUnit < 1342 && "invalid register unit");
12336   assert(RegUnit < 1342 && "invalid register unit");
gen/lib/Target/ARC/ARCGenAsmWriter.inc
  759   assert(Bits != 0 && "Cannot print this instruction.");
  951   assert(RegNo && RegNo < 34 && "Invalid register number!");
  995   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/ARC/ARCGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
 1549       assert(DecodeComplete);
 1582         assert(S == MCDisassembler::Fail);
gen/lib/Target/ARC/ARCGenRegisterInfo.inc
  715   assert(RegUnit < 33 && "invalid register unit");
  768   assert(RegUnit < 33 && "invalid register unit");
gen/lib/Target/ARM/ARMGenAsmMatcher.inc
 4347   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4359       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 4803   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
15118     assert(Mnemonic == it->getMnemonic());
15281       assert(!OperandNearMiss && "OperandNearMiss was handled earlier");
16359     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/ARM/ARMGenAsmWriter.inc
 9142   assert(Bits != 0 && "Cannot print this instruction.");
11789   assert(RegNo && RegNo < 295 && "Invalid register number!");
12046     assert(*(AsmStrsNoRegAltName+RegAsmOffsetNoRegAltName[RegNo-1]) &&
gen/lib/Target/ARM/ARMGenDAGISel.inc
55064   assert(ARM::dsub_7 == ARM::dsub_0+7 && "Unexpected subreg numbering");
55078   assert(ARM::dsub_7 == ARM::dsub_0+7 && "Unexpected subreg numbering");
55135   assert(ARM::dsub_7 == ARM::dsub_0+7 && "Unexpected subreg numbering");
55149   assert(ARM::ssub_3 == ARM::ssub_0+3 && "Unexpected subreg numbering");
55157   assert(ARM::ssub_3 == ARM::ssub_0+3 && "Unexpected subreg numbering");
55165   assert(ARM::dsub_7 == ARM::dsub_0+7 && "Unexpected subreg numbering");
gen/lib/Target/ARM/ARMGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
21856       assert(DecodeComplete);
21889         assert(S == MCDisassembler::Fail);
gen/lib/Target/ARM/ARMGenRegisterBank.inc
  109     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/ARM/ARMGenRegisterInfo.inc
 5912   assert(Select < 3);
 5930   assert(Select < 3);
 5950   assert(Select < 4);
 5968   assert(Select < 3);
 5986   assert(Select < 3);
 6006   assert(Select < 4);
 6024   assert(Select < 3);
 6044   assert(Select < 4);
 6060   assert(Select < 2);
 6076   assert(Select < 2);
 6092   assert(Select < 2);
 6108   assert(Select < 2);
 6124   assert(Select < 2);
 6140   assert(Select < 2);
 6156   assert(Select < 2);
 6171   assert(Select < 2);
 6187   assert(Select < 2);
 6203   assert(Select < 2);
 6218   assert(Select < 2);
 6236   assert(Select < 3);
 6254   assert(Select < 3);
 6272   assert(Select < 3);
 6290   assert(Select < 3);
 6308   assert(Select < 3);
 6326   assert(Select < 3);
 6344   assert(Select < 3);
 6358   assert(Select < 2);
 6372   assert(Select < 2);
 6386   assert(Select < 2);
 6400   assert(Select < 2);
 6414   assert(Select < 2);
 6428   assert(Select < 2);
 6442   assert(Select < 2);
 6456   assert(Select < 2);
 6470   assert(Select < 2);
 6484   assert(Select < 2);
 6498   assert(Select < 2);
 6512   assert(Select < 2);
 6526   assert(Select < 2);
 6540   assert(Select < 2);
 8450   --IdxA; assert(IdxA < 56);
 8451   --IdxB; assert(IdxB < 56);
 8539   --IdxA; assert(IdxA < 56 && "Subregister index out of bounds");
 8553   --IdxA; assert(IdxA < 56 && "Subregister index out of bounds");
15644   assert(RC && "Missing regclass");
15647   assert(Idx < 56 && "Bad subreg");
15785   assert(RegUnit < 83 && "invalid register unit");
15926   assert(RegUnit < 83 && "invalid register unit");
gen/lib/Target/AVR/AVRGenAsmMatcher.inc
  496   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  508       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
  565   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1009   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1015       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1307     assert(Mnemonic == it->getMnemonic());
 1518     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/AVR/AVRGenAsmWriter.inc
  855   assert(Bits != 0 && "Cannot print this instruction.");
  977   assert(RegNo && RegNo < 53 && "Invalid register number!");
 1041     assert(*(AsmStrsNoRegAltName+RegAsmOffsetNoRegAltName[RegNo-1]) &&
 1045     assert(*(AsmStrsptr+RegAsmOffsetptr[RegNo-1]) &&
gen/lib/Target/AVR/AVRGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
  671       assert(DecodeComplete);
  704         assert(S == MCDisassembler::Fail);
gen/lib/Target/AVR/AVRGenRegisterInfo.inc
 1440   --IdxA; assert(IdxA < 2);
 1441   --IdxB; assert(IdxB < 2);
 1459   --IdxA; assert(IdxA < 2 && "Subregister index out of bounds");
 1473   --IdxA; assert(IdxA < 2 && "Subregister index out of bounds");
 1560   assert(RC && "Missing regclass");
 1563   assert(Idx < 2 && "Bad subreg");
 1597   assert(RegUnit < 35 && "invalid register unit");
 1668   assert(RegUnit < 35 && "invalid register unit");
gen/lib/Target/BPF/BPFGenAsmMatcher.inc
  268   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  280       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
  304   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  697   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  703       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
gen/lib/Target/BPF/BPFGenAsmWriter.inc
  676   assert(Bits != 0 && "Cannot print this instruction.");
 1020   assert(RegNo && RegNo < 25 && "Invalid register number!");
 1054   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/BPF/BPFGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
  608       assert(DecodeComplete);
  641         assert(S == MCDisassembler::Fail);
gen/lib/Target/BPF/BPFGenMCCodeEmitter.inc
  973   assert(Inst.getOpcode() < 309);
gen/lib/Target/BPF/BPFGenRegisterInfo.inc
  533   --IdxA; assert(IdxA < 1);
  534   --IdxB; assert(IdxB < 1);
  550   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  564   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  585   assert(RC && "Missing regclass");
  588   assert(Idx < 1 && "Bad subreg");
  606   assert(RegUnit < 12 && "invalid register unit");
  654   assert(RegUnit < 12 && "invalid register unit");
gen/lib/Target/Hexagon/HexagonGenAsmMatcher.inc
 2545   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2557       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 2608   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 7480   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 7486       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
gen/lib/Target/Hexagon/HexagonGenAsmWriter.inc
 9077   assert(Bits != 0 && "Cannot print this instruction.");
16684   assert(RegNo && RegNo < 197 && "Invalid register number!");
16901   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/Hexagon/HexagonGenDAGISel.inc
72557   assert(isPowerOf2_32(VecSize));
73066   assert(V >= 32);
73081   assert(V >= 1);
73166   assert(isUInt<8>(V));
73175   assert(isUInt<16>(V));
gen/lib/Target/Hexagon/HexagonGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
12295       assert(DecodeComplete);
12328         assert(S == MCDisassembler::Fail);
gen/lib/Target/Hexagon/HexagonGenMCCodeEmitter.inc
14636   assert(Inst.getOpcode() < 2978);
gen/lib/Target/Hexagon/HexagonGenRegisterInfo.inc
 3186   --IdxA; assert(IdxA < 9);
 3187   --IdxB; assert(IdxB < 9);
 3217   --IdxA; assert(IdxA < 9 && "Subregister index out of bounds");
 3231   --IdxA; assert(IdxA < 9 && "Subregister index out of bounds");
 3521   assert(RC && "Missing regclass");
 3524   assert(Idx < 9 && "Bad subreg");
 3565   assert(RegUnit < 127 && "invalid register unit");
 3631   assert(RegUnit < 127 && "invalid register unit");
gen/lib/Target/Lanai/LanaiGenAsmMatcher.inc
  344   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  356       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
  422   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  863   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  869       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1091     assert(Mnemonic == it->getMnemonic());
 1326     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/Lanai/LanaiGenAsmWriter.inc
  640   assert(Bits != 0 && "Cannot print this instruction.");
  842   assert(RegNo && RegNo < 41 && "Invalid register number!");
  891   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/Lanai/LanaiGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
  549       assert(DecodeComplete);
  582         assert(S == MCDisassembler::Fail);
gen/lib/Target/Lanai/LanaiGenRegisterInfo.inc
  753   --IdxA; assert(IdxA < 1);
  754   --IdxB; assert(IdxB < 1);
  770   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  784   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  808   assert(RC && "Missing regclass");
  811   assert(Idx < 1 && "Bad subreg");
  830   assert(RegUnit < 33 && "invalid register unit");
  880   assert(RegUnit < 33 && "invalid register unit");
gen/lib/Target/MSP430/MSP430GenAsmMatcher.inc
  329   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  341       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
  392   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  631   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  637       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1149     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/MSP430/MSP430GenAsmWriter.inc
  600   assert(Bits != 0 && "Cannot print this instruction.");
  732   assert(RegNo && RegNo < 33 && "Invalid register number!");
  759   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/MSP430/MSP430GenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
 1426       assert(DecodeComplete);
 1459         assert(S == MCDisassembler::Fail);
gen/lib/Target/MSP430/MSP430GenRegisterInfo.inc
  466   --IdxA; assert(IdxA < 1);
  467   --IdxB; assert(IdxB < 1);
  483   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  497   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
  518   assert(RC && "Missing regclass");
  521   assert(Idx < 1 && "Bad subreg");
  539   assert(RegUnit < 16 && "invalid register unit");
  587   assert(RegUnit < 16 && "invalid register unit");
gen/lib/Target/Mips/MipsGenAsmMatcher.inc
 1325   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1337       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1562   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4880   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4886       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 8125     assert(Mnemonic == it->getMnemonic());
11698     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/Mips/MipsGenAsmWriter.inc
 6674   assert(Bits != 0 && "Cannot print this instruction.");
 7326   assert(RegNo && RegNo < 442 && "Invalid register number!");
 7471   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/Mips/MipsGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
10406       assert(DecodeComplete);
10439         assert(S == MCDisassembler::Fail);
gen/lib/Target/Mips/MipsGenRegisterBank.inc
   98     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/Mips/MipsGenRegisterInfo.inc
 4773   assert(Select < 2);
 4790   assert(Select < 2);
 6165   --IdxA; assert(IdxA < 11);
 6166   --IdxB; assert(IdxB < 11);
 6198   --IdxA; assert(IdxA < 11 && "Subregister index out of bounds");
 6212   --IdxA; assert(IdxA < 11 && "Subregister index out of bounds");
 7137   assert(RC && "Missing regclass");
 7140   assert(Idx < 11 && "Bad subreg");
 7226   assert(RegUnit < 321 && "invalid register unit");
 7323   assert(RegUnit < 321 && "invalid register unit");
gen/lib/Target/NVPTX/NVPTXGenAsmWriter.inc
12836   assert(Bits != 0 && "Cannot print this instruction.");
27102   assert(RegNo && RegNo < 96 && "Invalid register number!");
27212   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/NVPTX/NVPTXGenRegisterInfo.inc
 1204   assert(RegUnit < 95 && "invalid register unit");
 1288   assert(RegUnit < 95 && "invalid register unit");
gen/lib/Target/PowerPC/PPCGenAsmMatcher.inc
 2081   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2093       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 2480   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4119   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4125       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 7054     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/PowerPC/PPCGenAsmWriter.inc
 6073   assert(Bits != 0 && "Cannot print this instruction.");
 6673   assert(RegNo && RegNo < 344 && "Invalid register number!");
 6906   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/PowerPC/PPCGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
 6656       assert(DecodeComplete);
 6689         assert(S == MCDisassembler::Fail);
gen/lib/Target/PowerPC/PPCGenMCCodeEmitter.inc
 8503   assert(Inst.getOpcode() < 2219);
gen/lib/Target/PowerPC/PPCGenRegisterInfo.inc
 4284   assert(Select < 2);
 4300   assert(Select < 2);
 4316   assert(Select < 2);
 4332   assert(Select < 2);
 4348   assert(Select < 2);
 4364   assert(Select < 2);
 5169   --IdxA; assert(IdxA < 6);
 5170   --IdxB; assert(IdxB < 6);
 5196   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 5210   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 5497   assert(RC && "Missing regclass");
 5500   assert(Idx < 6 && "Bad subreg");
 5550   assert(RegUnit < 171 && "invalid register unit");
 5637   assert(RegUnit < 171 && "invalid register unit");
gen/lib/Target/RISCV/RISCVGenAsmMatcher.inc
  950   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  962       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1040   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1767   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1773       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 2443     assert(Mnemonic == it->getMnemonic());
 2795     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/RISCV/RISCVGenAsmWriter.inc
 1305   assert(Bits != 0 && "Cannot print this instruction.");
 1456   assert(RegNo && RegNo < 97 && "Invalid register number!");
 1588     assert(*(AsmStrsABIRegAltName+RegAsmOffsetABIRegAltName[RegNo-1]) &&
 1592     assert(*(AsmStrsNoRegAltName+RegAsmOffsetNoRegAltName[RegNo-1]) &&
gen/lib/Target/RISCV/RISCVGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
 1832       assert(DecodeComplete);
 1865         assert(S == MCDisassembler::Fail);
gen/lib/Target/RISCV/RISCVGenRegisterBank.inc
   61     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/RISCV/RISCVGenRegisterInfo.inc
 1607   --IdxA; assert(IdxA < 1);
 1608   --IdxB; assert(IdxB < 1);
 1624   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
 1638   --IdxA; assert(IdxA < 1 && "Subregister index out of bounds");
 1689   assert(RC && "Missing regclass");
 1692   assert(Idx < 1 && "Bad subreg");
 1720   assert(RegUnit < 64 && "invalid register unit");
 1783   assert(RegUnit < 64 && "invalid register unit");
gen/lib/Target/Sparc/SparcGenAsmMatcher.inc
 1569   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1581       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1668   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2334   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2340       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 4187     assert(Mnemonic == it->getMnemonic());
 4503     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/Sparc/SparcGenAsmWriter.inc
 1074   assert(Bits != 0 && "Cannot print this instruction.");
 1366   assert(RegNo && RegNo < 236 && "Invalid register number!");
 1559   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/Sparc/SparcGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
 2454       assert(DecodeComplete);
 2487         assert(S == MCDisassembler::Fail);
gen/lib/Target/Sparc/SparcGenMCCodeEmitter.inc
 2456   assert(Inst.getOpcode() < 704);
gen/lib/Target/Sparc/SparcGenRegisterInfo.inc
 2498   --IdxA; assert(IdxA < 6);
 2499   --IdxB; assert(IdxB < 6);
 2523   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 2537   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 2656   assert(RC && "Missing regclass");
 2659   assert(Idx < 6 && "Bad subreg");
 2688   assert(RegUnit < 171 && "invalid register unit");
 2748   assert(RegUnit < 171 && "invalid register unit");
gen/lib/Target/SystemZ/SystemZGenAsmMatcher.inc
 1342   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 1354       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1396   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2328   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 2334       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 5382     assert(Mnemonic == it->getMnemonic());
 9221     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/SystemZ/SystemZGenAsmWriter.inc
11373   assert(Bits != 0 && "Cannot print this instruction.");
12170   assert(RegNo && RegNo < 195 && "Invalid register number!");
12290   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/SystemZ/SystemZGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
10827       assert(DecodeComplete);
10860         assert(S == MCDisassembler::Fail);
gen/lib/Target/SystemZ/SystemZGenMCCodeEmitter.inc
11984   assert(Inst.getOpcode() < 3004);
gen/lib/Target/SystemZ/SystemZGenRegisterInfo.inc
 2584   --IdxA; assert(IdxA < 6);
 2585   --IdxB; assert(IdxB < 6);
 2610   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 2624   --IdxA; assert(IdxA < 6 && "Subregister index out of bounds");
 2815   assert(RC && "Missing regclass");
 2818   assert(Idx < 6 && "Bad subreg");
 2856   assert(RegUnit < 98 && "invalid register unit");
 2914   assert(RegUnit < 98 && "invalid register unit");
gen/lib/Target/WebAssembly/WebAssemblyGenAsmMatcher.inc
  159   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  171       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
  198   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  385   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
  391       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 1151     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/WebAssembly/WebAssemblyGenAsmWriter.inc
 2094   assert(Bits != 0 && "Cannot print this instruction.");
 2300   assert(RegNo && RegNo < 13 && "Invalid register number!");
 2321   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/WebAssembly/WebAssemblyGenRegisterInfo.inc
  478   assert(RegUnit < 12 && "invalid register unit");
  541   assert(RegUnit < 12 && "invalid register unit");
gen/lib/Target/X86/X86GenAsmMatcher.inc
 4940   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 4952       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
 5066   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 7576   assert(Kind < CVT_NUM_SIGNATURES && "Invalid signature!");
 7582       assert(OpIdx < (size_t)(std::end(TiedAsmOperandTable) -
36982     assert(Mnemonic == it->getMnemonic());
gen/lib/Target/X86/X86GenAsmWriter.inc
47417   assert(Bits != 0 && "Cannot print this instruction.");
48554   assert(RegNo && RegNo < 282 && "Invalid register number!");
48838   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/X86/X86GenAsmWriter1.inc
31877   assert(Bits != 0 && "Cannot print this instruction.");
32880   assert(RegNo && RegNo < 282 && "Invalid register number!");
33164   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/X86/X86GenRegisterBank.inc
  152     assert(Index++ == RB->getID() && "Index != ID");
gen/lib/Target/X86/X86GenRegisterInfo.inc
 6262   assert(Select < 2);
 6278   assert(Select < 2);
 8113   --IdxA; assert(IdxA < 10);
 8114   --IdxB; assert(IdxB < 10);
 8145   --IdxA; assert(IdxA < 10 && "Subregister index out of bounds");
 8159   --IdxA; assert(IdxA < 10 && "Subregister index out of bounds");
 9590   assert(RC && "Missing regclass");
 9593   assert(Idx < 10 && "Bad subreg");
 9727   assert(RegUnit < 163 && "invalid register unit");
 9873   assert(RegUnit < 163 && "invalid register unit");
gen/lib/Target/XCore/XCoreGenAsmWriter.inc
  575   assert(Bits != 0 && "Cannot print this instruction.");
  852   assert(RegNo && RegNo < 17 && "Invalid register number!");
  878   assert (*(AsmStrs+RegAsmOffset[RegNo-1]) &&
gen/lib/Target/XCore/XCoreGenDAGISel.inc
 2477   assert(N->getZExtValue() % 4 == 0);
 2494   assert(-value % 4 == 0);
 2510   assert(isMask_32(N->getZExtValue()));
gen/lib/Target/XCore/XCoreGenDisassemblerTables.inc
   36   assert(startBit + numBits <= 64 && "Cannot support >64-bit extractions!");
   37   assert(startBit + numBits <= (sizeof(InsnType) * 8) &&
  898       assert(DecodeComplete);
  931         assert(S == MCDisassembler::Fail);
gen/lib/Target/XCore/XCoreGenRegisterInfo.inc
  478   assert(RegUnit < 16 && "invalid register unit");
  526   assert(RegUnit < 16 && "invalid register unit");
gen/tools/clang/include/clang/AST/AttrImpl.inc
  659   assert(!isAlignmentDependent());
gen/tools/clang/include/clang/AST/Attrs.inc
  992     assert(isalignmentExpr);
  996     assert(!isalignmentExpr);
 6197     assert(SpellingIndex == Pragma_clang_loop && "Unexpected spelling");
 6234     assert(SpellingIndex == Pragma_clang_loop && "Unexpected spelling");
 9067       assert(getCtxSelectorSet() != CtxSetUnknown &&
gen/tools/clang/include/clang/Driver/Options.inc
 3764 assert(ValuesWereAdded && "Couldn't add values to OptTable!");
 3777 assert(ValuesWereAdded && "Couldn't add values to OptTable!");
 3780 assert(ValuesWereAdded && "Couldn't add values to OptTable!");
gen/tools/clang/include/clang/Sema/AttrParsedAttrImpl.inc
 3556     assert(false && "Abstract matcher rule isn't allowed");
gen/tools/lldb/scripts/LLDBWrapPython.cpp
 2383               assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
 2471         assert(!newmemory); /* newmemory handling not yet implemented */
 2663   assert(!(flags & SWIG_BUILTIN_TP_INIT));
include/llvm/ADT/APFloat.h
  703       assert(&S == &PPCDoubleDouble());
  841     assert(&getSemantics() == &RHS.getSemantics() &&
  957     assert(&getSemantics() == &RHS.getSemantics() &&
  966     assert(&getSemantics() == &RHS.getSemantics() &&
  975     assert(&getSemantics() == &RHS.getSemantics() &&
  984     assert(&getSemantics() == &RHS.getSemantics() &&
  993     assert(&getSemantics() == &RHS.getSemantics() &&
 1002     assert(&getSemantics() == &RHS.getSemantics() &&
 1012     assert(&getSemantics() == &Multiplicand.getSemantics() &&
 1014     assert(&getSemantics() == &Addend.getSemantics() &&
 1118     assert(&getSemantics() == &RHS.getSemantics() &&
include/llvm/ADT/APInt.h
  279     assert(BitWidth && "bitwidth too small");
  450     assert(N && "N == 0 ???");
  456     assert(N && "N == 0 ???");
  495     assert(numBits != 0 && "numBits must be non-zero");
  496     assert(numBits <= BitWidth && "numBits out of range");
  753     assert(this != &that && "Self-move not supported");
  792     assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  822     assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  852     assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  905     assert(ShiftAmt <= BitWidth && "Invalid shift amount");
  954     assert(ShiftAmt <= BitWidth && "Invalid shift amount");
  978     assert(ShiftAmt <= BitWidth && "Invalid shift amount");
 1121     assert(bitPosition < getBitWidth() && "Bit position out of bounds!");
 1134     assert(BitWidth == RHS.BitWidth && "Comparison requires equal bit widths");
 1325     assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
 1333     assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
 1407     assert(BitPosition < BitWidth && "BitPosition out of range");
 1422     assert(hiBit <= BitWidth && "hiBit out of range");
 1423     assert(loBit <= BitWidth && "loBit out of range");
 1424     assert(loBit <= hiBit && "loBit greater than hiBit");
 1466     assert(BitPosition < BitWidth && "BitPosition out of range");
 1476     assert(loBits <= BitWidth && "More bits than bitwidth");
 1578     assert(getActiveBits() <= 64 && "Too many bits for uint64_t");
 1590     assert(getMinSignedBits() <= 64 && "Too many bits for int64_t");
include/llvm/ADT/APSInt.h
   94     assert(getMinSignedBits() <= 64 && "Too many bits for int64_t");
  117     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  125     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  133     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  137     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  153     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  157     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  161     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  165     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  169     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  224     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  229     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  234     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  239     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  244     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  249     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  255     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  260     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  265     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  270     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  274     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  278     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  319       assert(!I2.isSigned() && "Expected signed mismatch");
  323       assert(I2.isSigned() && "Expected signed mismatch");
include/llvm/ADT/AllocatorList.h
  231     assert(empty() && "Cannot reset allocator if not empty");
include/llvm/ADT/Any.h
  143   assert(Value && any_isa<T>(*Value) && "Bad any cast!");
  151   assert(Value && any_isa<U>(*Value) && "Bad any cast!");
include/llvm/ADT/ArrayRef.h
  152       assert(!empty());
  158       assert(!empty());
  179       assert(N+M <= size() && "Invalid specifier");
  188       assert(size() >= N && "Dropping more elements than exist");
  194       assert(size() >= N && "Dropping more elements than exist");
  240       assert(Index < Length && "Invalid index!");
  338       assert(!this->empty());
  344       assert(!this->empty());
  351       assert(N + M <= this->size() && "Invalid specifier");
  362       assert(this->size() >= N && "Dropping more elements than exist");
  367       assert(this->size() >= N && "Dropping more elements than exist");
  417       assert(Index < this->size() && "Invalid index!");
include/llvm/ADT/BitVector.h
   36     assert(Current != -1 && "Trying to advance past end.");
   61     assert(&Parent == &Other.Parent &&
   67     assert(&Parent == &Other.Parent &&
  208     assert(Begin <= End && End <= Size);
  237     assert(Begin <= End && End <= Size);
  268     assert(Begin <= End && End <= Size);
  299     assert(Begin <= End && End <= Size);
  404     assert(Bits.data() && "Bits never allocated");
  411     assert(I <= E && "Attempted to set backwards range!");
  412     assert(E <= size() && "Attempted to set out-of-bounds range!");
  450     assert(I <= E && "Attempted to reset backwards range!");
  451     assert(E <= size() && "Attempted to reset out-of-bounds range!");
  491     assert (Idx < Size && "Out-of-bounds Bit access.");
  496     assert (Idx < Size && "Out-of-bounds Bit access.");
  619     assert(N <= Size);
  624     assert(NumWords >= 1);
  668     assert(N <= Size);
  673     assert(NumWords >= 1);
  732     assert(NewCapacity > 0 && "negative capacity?");
  840     assert(Dest.size() == Src.size());
  886     assert(NewCapacity > 0 && "realloc-ing zero space");
include/llvm/ADT/BitmaskEnum.h
   92   assert(U >= 0 && "Negative enum values are not allowed.");
   93   assert(U <= Mask<E>() && "Enum value too large (or largest val too small?)");
include/llvm/ADT/CachedHashString.h
   41     assert(S.size() <= std::numeric_limits<uint32_t>::max());
   58     assert(!isEqual(S, getEmptyKey()) && "Cannot hash the empty key!");
   59     assert(!isEqual(S, getTombstoneKey()) && "Cannot hash the tombstone key!");
   92     assert(isEmptyOrTombstone());
  163     assert(!isEqual(S, getEmptyKey()) && "Cannot hash the empty key!");
  164     assert(!isEqual(S, getTombstoneKey()) && "Cannot hash the tombstone key!");
include/llvm/ADT/DenseMap.h
  138       assert(NumEntries == 0 && "Node count imbalance!");
  347     assert((getNumBuckets() & (getNumBuckets()-1)) == 0 &&
  378         assert(!FoundVal && "Key already in new map?");
  393     assert(&other != this);
  394     assert(getNumBuckets() == other.getNumBuckets());
  559     assert(TheBucket);
  592     assert(!KeyInfoT::isEqual(Val, EmptyKey) &&
  777     assert(Buckets);
 1028           assert(size_t(TmpEnd - TmpBegin) < InlineBuckets &&
 1089     assert(Num < (1U << 31) && "Cannot support more than 1<<31 entries");
 1102     assert(Small);
 1115     assert(!Small);
 1149     assert(Num > InlineBuckets && "Must allocate more buckets than are inline");
 1183     assert(isHandleInSync() && "invalid construction!");
 1203     assert(isHandleInSync() && "invalid iterator access!");
 1209     assert(isHandleInSync() && "invalid iterator access!");
 1216     assert((!Ptr || isHandleInSync()) && "handle not in sync!");
 1217     assert((!RHS.Ptr || RHS.isHandleInSync()) && "handle not in sync!");
 1218     assert(getEpochAddress() == RHS.getEpochAddress() &&
 1223     assert((!Ptr || isHandleInSync()) && "handle not in sync!");
 1224     assert((!RHS.Ptr || RHS.isHandleInSync()) && "handle not in sync!");
 1225     assert(getEpochAddress() == RHS.getEpochAddress() &&
 1231     assert(isHandleInSync() && "invalid iterator access!");
 1242     assert(isHandleInSync() && "invalid iterator access!");
 1248     assert(Ptr <= End);
 1258     assert(Ptr >= End);
include/llvm/ADT/DenseMapInfo.h
  233     assert(Val.data() != getEmptyKey().data() && "Cannot hash the empty key!");
  234     assert(Val.data() != getTombstoneKey().data() &&
  261     assert(Val.data() != getEmptyKey().data() && "Cannot hash the empty key!");
  262     assert(Val.data() != getTombstoneKey().data() &&
include/llvm/ADT/DirectedGraph.h
  108     assert(EL.empty() && "Expected the list of edges to be empty.");
  217     assert(EL.empty() && "Expected the list of edges to be empty.");
  256     assert(findNode(Src) != Nodes.end() && "Src node should be present.");
  257     assert(findNode(Dst) != Nodes.end() && "Dst node should be present.");
  258     assert((E.getTargetNode() == Dst) &&
include/llvm/ADT/EquivalenceClasses.h
   88       assert(isLeader() && "Cannot get the end of a list for a non-leader!");
   93       assert(getNext() == nullptr && "Already has a next pointer!");
  101       assert(RHS.isLeader() && RHS.getNext() == nullptr && "Not a singleton!");
  172     assert(MI != member_end() && "Value is not in the set!");
  181     assert(MI != member_end() && "Value is not in the set!");
  222     assert(L1 != member_end() && L2 != member_end() && "Illegal inputs!");
  269       assert(Node != nullptr && "Dereferencing end()!");
  275       assert(Node != nullptr && "++'d off the end of the list!");
include/llvm/ADT/FoldingSet.h
  460     assert(Inserted == N && "Node already inserted!");
include/llvm/ADT/Hashing.h
  411   assert(buffer_ptr == buffer_end);
include/llvm/ADT/ImmutableList.h
  133     assert(!isEmpty() && "Cannot get the head of an empty list.");
include/llvm/ADT/ImmutableSet.h
  279     assert(isMutable() && "Mutable flag already removed.");
  285     assert(!hasCachedDigest() && "NoCachedDigest flag already removed.");
  334     assert(refCount > 0);
  468       assert(T != L);
  469       assert(T != R);
  498       assert(!isEmpty(L) && "Left tree cannot be empty to have a height >= 2");
  506       assert(!isEmpty(LR) && "LR cannot be empty because it has a height >= 1");
  515       assert(!isEmpty(R) && "Right tree cannot be empty to have a height >= 2");
  523       assert(!isEmpty(RL) && "RL cannot be empty because it has a height >= 1");
  540     assert(!T->isMutable());
  561     assert(!T->isMutable());
  587     assert(!isEmpty(T));
  666     assert(!stack.empty());
  672     assert(!stack.empty());
  683     assert(!stack.empty());
  708     assert(!stack.empty());
  710     assert(Current);
  734     assert(!stack.empty());
  736     assert(Current);
include/llvm/ADT/IndexedMap.h
   46       assert(toIndex_(n) < storage_.size() && "index out of bounds!");
   51       assert(toIndex_(n) < storage_.size() && "index out of bounds!");
include/llvm/ADT/IntEqClasses.h
   76     assert(NumClasses && "operator[] called before compress()");
include/llvm/ADT/IntervalMap.h
  235     assert(i + Count <= M && "Invalid source range");
  236     assert(j + Count <= N && "Invalid dest range");
  248     assert(j <= i && "Use moveRight shift elements right");
  257     assert(i <= j && "Use moveLeft shift elements left");
  258     assert(j + Count <= N && "Invalid range");
  374     assert(CurSize[n] == NewSize[n] && "Insufficient element shuffle");
  508     assert(n <= NodeT::Capacity && "Size too big for node");
  533     assert(pip.getPointer() != RHS.pip.getPointer() && "Inconsistent NodeRefs");
  580     assert(i <= Size && Size <= N && "Bad indices");
  581     assert((i == 0 || Traits::stopLess(stop(i - 1), x)) &&
  595     assert(i < N && "Bad index");
  596     assert((i == 0 || Traits::stopLess(stop(i - 1), x)) &&
  599     assert(i < N && "Unsafe intervals");
  629   assert(i <= Size && Size <= N && "Invalid index");
  630   assert(!Traits::stopLess(b, a) && "Invalid interval");
  633   assert((i == 0 || Traits::stopLess(stop(i - 1), a)));
  634   assert((i == Size || !Traits::stopLess(stop(i), a)));
  635   assert((i == Size || Traits::stopLess(b, start(i))) && "Overlapping insert");
  715     assert(i <= Size && Size <= N && "Bad indices");
  716     assert((i == 0 || Traits::stopLess(stop(i - 1), x)) &&
  729     assert(i < N && "Bad index");
  730     assert((i == 0 || Traits::stopLess(stop(i - 1), x)) &&
  733     assert(i < N && "Unsafe intervals");
  750     assert(Size < N && "branch node overflow");
  751     assert(i <= Size && "Bad insert position");
  988     assert(!branched() && "Cannot acces leaf data in branched root");
  992     assert(!branched() && "Cannot acces leaf data in branched root");
  997     assert(branched() && "Cannot access branch data in non-branched root");
 1001     assert(branched() && "Cannot access branch data in non-branched root");
 1043     assert((uintptr_t(data.buffer) & (alignof(RootLeaf) - 1)) == 0 &&
 1060     assert(!empty() && "Empty IntervalMap has no start");
 1066     assert(!empty() && "Empty IntervalMap has no stop");
 1140     assert(Traits::nonEmpty(a, b));
 1156   assert(branched() && "treeLookup assumes a branched root");
 1313     assert(map && "Invalid iterator");
 1330     assert(valid() && "Cannot access invalid iterator");
 1337     assert(valid() && "Cannot access invalid iterator");
 1344     assert(valid() && "Cannot access invalid iterator");
 1375     assert(map == RHS.map && "Cannot compare iterators from different maps");
 1401     assert(valid() && "Cannot increment end()");
 1683   assert(Traits::nonEmpty(a, this->stop()) && "Cannot move start beyond stop");
 1699   assert(Traits::nonEmpty(this->start(), b) && "Cannot move stop beyond start");
 1737   assert(Level && "Cannot insert next to the root");
 1766     assert(!SplitRoot && "Cannot overflow after splitting the root");
 1856     assert(Size <= Leaf::Capacity && "overflow() didn't make room");
 1873   assert(P.valid() && "Cannot erase end()");
 1917   assert(Level && "Cannot erase root node");
include/llvm/ADT/IntrusiveRefCntPtr.h
   80     assert(RefCount > 0 && "Reference count is already zero.");
   98     assert(NewRefCount >= 0 && "Reference count was already zero.");
include/llvm/ADT/MapVector.h
  182       assert(I.second != Index && "Index was already erased!");
include/llvm/ADT/Optional.h
   73     assert(hasVal);
   77     assert(hasVal);
  173     assert(hasVal);
  177     assert(hasVal);
include/llvm/ADT/PackedVector.h
   38     assert((val >> BitNum) == 0 && "value is too big");
   61     assert((val >> (BitNum-1)) == 0 && "value is too big");
include/llvm/ADT/PointerEmbeddedInt.h
   64     assert((std::is_signed<IntT>::value ? isInt<Bits>(I) : isUInt<Bits>(I)) &&
include/llvm/ADT/PointerIntPair.h
   85     assert(Value == reinterpret_cast<intptr_t>(getPointer()) &&
  178     assert((PtrWord & ~PointerBitMask) == 0 &&
  186     assert((IntWord & ~IntMask) == 0 && "Integer too large for field");
include/llvm/ADT/PointerSumType.h
  102     assert((reinterpret_cast<uintptr_t>(V) & HelperT::TagMask) == 0 &&
  132     assert(is<N>() && "This instance has a different active member.");
  151     assert(is<HelperT::MinTag>() && "The active tag is not zero!");
  160     assert(InitialPtr == get<HelperT::MinTag>() &&
include/llvm/ADT/PointerUnion.h
  195     assert(is<T>() && "Invalid accessor called");
  216     assert(is<First>() && "Val is not the first pointer");
  217     assert(
include/llvm/ADT/PriorityWorklist.h
   85     assert(!empty() && "Cannot call back() on empty PriorityWorklist!");
   92     assert(X != T() && "Cannot insert a null (default constructed) value!");
  101     assert(V[Index] == X && "Value not actually at index in map!");
  146     assert(!empty() && "Cannot remove an element when empty!");
  147     assert(back() != T() && "Cannot have a null element at the back!");
  168     assert(V[I->second] == X && "Value not actually at index in map!");
include/llvm/ADT/SCCIterator.h
  109     assert(!CurrentSCC.empty() || VisitStack.empty());
  123     assert(!CurrentSCC.empty() && "Dereferencing END SCC iterator!");
  136     assert(nodeVisitNumbers.count(Old) && "Old not in scc_iterator?");
  156   assert(!VisitStack.empty());
  182     assert(VisitStack.back().NextChild == GT::child_end(visitingN));
  213     assert(!CurrentSCC.empty() && "Dereferencing END SCC iterator!");
include/llvm/ADT/STLExtras.h
  470     assert(!IsEarlyIncremented && "Cannot dereference twice!");
  479     assert(IsEarlyIncremented && "Cannot increment before dereferencing!");
  488     assert(!IsEarlyIncremented && "Cannot compare after dereferencing!");
 1390     assert(lhs);
 1391     assert(rhs);
 1445     assert(Result.Index != std::numeric_limits<size_t>::max());
include/llvm/ADT/ScopedHashTable.h
  174     assert(!CurScope && TopLevelMap.empty() && "Scope imbalance!");
  217     assert(S && "No scope active!");
  237   assert(HT.CurScope == this && "Scope imbalance!");
  244       assert(HT.TopLevelMap[ThisEntry->getKey()] == ThisEntry &&
  249       assert(KeyEntry == ThisEntry && "Scope imbalance!");
include/llvm/ADT/SetVector.h
  123     assert(!empty() && "Cannot call front() on empty SetVector!");
  129     assert(!empty() && "Cannot call back() on empty SetVector!");
  135     assert(n < vector_.size() && "SetVector access out of range!");
  160       assert(I != vector_.end() && "Corrupted SetVector instances!");
  173     assert(set_.count(V) && "Corrupted SetVector instances!");
  222     assert(!empty() && "Cannot remove an element from an empty SetVector!");
include/llvm/ADT/SmallBitVector.h
   95     assert(!isSmall());
  107     assert(!isSmall() && "Tried to use an unaligned pointer");
  113     assert(isSmall());
  118     assert(isSmall());
  373       assert(Idx <= static_cast<unsigned>(
  385     assert(I <= E && "Attempted to set backwards range!");
  386     assert(E <= size() && "Attempted to set out-of-bounds range!");
  416     assert(I <= E && "Attempted to reset backwards range!");
  417     assert(E <= size() && "Attempted to reset out-of-bounds range!");
  452     assert(Idx < size() && "Out-of-bounds Bit access.");
  457     assert(Idx < size() && "Out-of-bounds Bit access.");
  668     assert(MaskWords <= sizeof(uintptr_t) && "Mask is larger than base!");
include/llvm/ADT/SmallPtrSet.h
   77     assert(SmallSize && (SmallSize & (SmallSize-1)) == 0 &&
  167     assert(*Loc == Ptr && "broken find!");
  248     assert(Bucket <= End);
  255     assert(Bucket >= End);
  284     assert(isHandleInSync() && "invalid iterator access!");
  286       assert(Bucket > End);
  289     assert(Bucket < End);
  294     assert(isHandleInSync() && "invalid iterator access!");
include/llvm/ADT/SmallVector.h
   67     assert(N <= capacity());
  149     assert(idx < size());
  153     assert(idx < size());
  158     assert(!empty());
  162     assert(!empty());
  167     assert(!empty());
  171     assert(!empty());
  438     assert(I >= this->begin() && "Iterator to erase is out of bounds.");
  439     assert(I < this->end() && "Erasing at past-the-end iterator.");
  454     assert(S >= this->begin() && "Range to erase is out of bounds.");
  455     assert(S <= E && "Trying to erase invalid range.");
  456     assert(E <= this->end() && "Trying to erase past the end.");
  473     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  474     assert(I <= this->end() && "Inserting past the end of the vector.");
  503     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  504     assert(I <= this->end() && "Inserting past the end of the vector.");
  535     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  536     assert(I <= this->end() && "Inserting past the end of the vector.");
  590     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  591     assert(I <= this->end() && "Inserting past the end of the vector.");
include/llvm/ADT/SparseBitVector.h
   83     assert(Idx < BITWORDS_PER_ELEMENT);
  154     assert(WordPos <= BITWORDS_PER_ELEMENT
include/llvm/ADT/SparseMultiSet.h
  135     assert(ValIndexOf(Val) < Universe &&
  145     assert(D.isValid() && "Invalid node for head");
  152     assert(N.isValid() && "Invalid node for singleton");
  168     assert(Dense[Idx].isTombstone() && "Non-tombstone free?");
  205     assert(empty() && "Can only resize universe on an empty map");
  236       assert(Idx < SMS->Dense.size() && "Out of range, non-INVALID Idx?");
  257       assert(isKeyed() && SMS->sparseIndex(SMS->Dense[Idx].Data) == SparseIdx &&
  268         assert((isEnd() || SparseIdx == RHS.SparseIdx) &&
  282       assert(isKeyed() && "Decrementing an invalid iterator");
  283       assert((isEnd() || !SMS->isHead(SMS->Dense[Idx])) &&
  295       assert(!isEnd() && isKeyed() && "Incrementing an invalid/end iterator");
  336     assert(NumFree <= Dense.size() && "Out-of-bounds free entries");
  355     assert(Idx < Universe && "Key out of range");
  467     assert(I.isKeyed() && !I.isEnd() && !Dense[I.Idx].isTombstone() &&
  492       assert(N.Next == SMSNode::INVALID && "Singleton has next?");
include/llvm/ADT/SparseSet.h
  158     assert(empty() && "Can only resize universe on an empty map");
  205     assert(Idx < Universe && "Key out of range");
  209       assert(FoundIdx < Universe && "Invalid key in set. Did object mutate?");
  286     assert(unsigned(I - begin()) < size() && "Invalid iterator");
  290       assert(BackIdx < Universe && "Invalid key in set. Did object mutate?");
include/llvm/ADT/StringExtras.h
  163   assert(U1 != -1U && U2 != -1U);
  181   assert(Input.size() % 2 == 0);
include/llvm/ADT/StringMap.h
  189     assert(NewItem && "Unhandled out-of-memory");
  403     assert(NumItems + NumTombstones <= NumBuckets);
  443     assert(NumItems + NumTombstones <= NumBuckets);
include/llvm/ADT/StringRef.h
  155       assert(!empty());
  162       assert(!empty());
  249       assert(Index < Length && "Invalid index!");
  641       assert(size() >= N && "Dropping more elements than exist");
  649       assert(size() >= N && "Dropping more elements than exist");
include/llvm/ADT/StringSet.h
   39       assert(!Key.empty());
include/llvm/ADT/StringSwitch.h
  189     assert(Result && "Fell off the end of a string-switch");
include/llvm/ADT/TinyPtrVector.h
  219     assert(!Val.isNull() && "can't index into an empty vector");
  221       assert(i == 0 && "tinyvector index out of range");
  225     assert(i < Val.template get<VecTy*>()->size() &&
  231     assert(!empty() && "vector empty");
  238     assert(!empty() && "vector empty");
  248       assert(!Val.isNull() && "Can't add a null value");
  283     assert(I >= begin() && "Iterator to erase is out of bounds.");
  284     assert(I < end() && "Erasing at past-the-end iterator.");
  299     assert(S >= begin() && "Range to erase is out of bounds.");
  300     assert(S <= E && "Trying to erase invalid range.");
  301     assert(E <= end() && "Trying to erase past the end.");
  313     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  314     assert(I <= this->end() && "Inserting past the end of the vector.");
  319     assert(!Val.isNull() && "Null value with non-end insert iterator.");
  322       assert(I == begin());
  333     assert(I >= this->begin() && "Insertion iterator is out of bounds.");
  334     assert(I <= this->end() && "Inserting past the end of the vector.");
include/llvm/ADT/Triple.h
  440     assert(isMacOSX() && "Not an OS X triple!");
  447     assert(Major == 10 && "Unexpected major version");
  664     assert(isAndroid() && "Not an Android triple!");
include/llvm/ADT/Twine.h
  170       assert(isNullary() && "Invalid kind!");
  178       assert(isValid() && "Invalid twine!");
  184       assert(isValid() && "Invalid twine!");
  257       assert(isValid() && "Invalid twine!");
  274       assert(isValid() && "Invalid twine!");
  283       assert(isValid() && "Invalid twine!");
  289       assert(isValid() && "Invalid twine!");
  296       assert(isValid() && "Invalid twine!");
  303       assert(isValid() && "Invalid twine!");
  361       assert(isValid() && "Invalid twine!");
  369       assert(isValid() && "Invalid twine!");
  440       assert(isSingleStringRef() &&"This cannot be had as a single stringref!");
include/llvm/ADT/UniqueVector.h
   70     assert(ID-1 < size() && "ID is 0 or out of range!");
include/llvm/ADT/fallible_iterator.h
  128     assert(getErrPtr() && "Cannot increment end iterator");
  144     assert(getErrPtr() && "Cannot decrement end iterator");
  171     assert(LHS.isValid() && RHS.isValid() &&
include/llvm/ADT/ilist.h
  313     assert(!empty() && "pop_front() on empty list!");
  317     assert(!empty() && "pop_back() on empty list!");
include/llvm/ADT/ilist_base.h
   58     assert(&Next != &First &&
include/llvm/ADT/ilist_iterator.h
  139     assert(!NodePtr->isKnownSentinel());
include/llvm/ADT/simple_ilist.h
  197     assert(I != end() && "Cannot remove end of list!");
include/llvm/Analysis/AliasSetTracker.h
  102       assert(isSizeSet() && "Getting an unset size!");
  117       assert(AS && "No AliasSet yet!");
  128       assert(!AS && "Already have an alias set!");
  137         assert(*AS->PtrListEnd == nullptr && "List not terminated right!");
  193     assert(RefCount >= 1 && "Invalid reference count detected!");
  199     assert(i < UnknownInsts.size());
  252       assert(CurNode && "Dereferencing AliasSet.end()!");
  262       assert(CurNode && "Advancing past AliasSet.end()!");
include/llvm/Analysis/BlockFrequencyInfoImpl.h
  251       assert(isHeader(B) && "this is only valid on loop header blocks");
  450     assert(Head.Index < Working.size());
  451     assert(Working[Head.Index].isLoopHeader());
  537     assert(!Freqs.empty());
  568   assert(BB && "Unexpected nullptr");
  576   assert(BB && "Unexpected nullptr");
  874     assert(Node.Index < RPOT.size());
 1069   assert(RPOT.size() - 1 <= BlockNode::getMaxIndex() &&
 1101     assert(Header.isValid());
 1128     assert(Header.isValid());
 1130     assert(HeaderData.isLoopHeader());
 1197       assert(!getBlock(HeaderNode)->getIrrLoopHeaderWeight() &&
 1231   assert(!Working.empty() && "no blocks in function");
 1232   assert(!Working[0].isLoopHeader() && "entry block is a loop header");
 1315     assert(Loop != OuterLoop && "Cannot propagate mass in a packaged loop");
include/llvm/Analysis/BranchProbabilityInfo.h
  155       assert(BPI != nullptr);
include/llvm/Analysis/CFLAliasAnalysisUtils.h
   26     assert(Fn != nullptr);
   27     assert(Result != nullptr);
   37     assert(Result != nullptr);
include/llvm/Analysis/CGSCCPassManager.h
  507         assert(
  585       assert(CallHandles.empty() && "Must start with a clear set of handles.");
  630       assert(!UR.InvalidatedSCCs.count(C) && "Processing an invalid SCC!");
  631       assert(C->begin() != C->end() && "Cannot have an empty SCC!");
  770     assert(RCWorklist.empty() &&
  792       assert(CWorklist.empty() &&
  849           assert(!InvalidSCCSet.count(C) && "Processing an invalid SCC!");
  850           assert(C->begin() != C->end() && "Cannot have an empty SCC!");
  851           assert(&C->getOuterRefSCC() == RC &&
  881           assert(C->begin() != C->end() && "Cannot have an empty SCC!");
include/llvm/Analysis/CallGraph.h
  123     assert(I != FunctionMap.end() && "Function not in callgraph!");
  130     assert(I != FunctionMap.end() && "Function not in callgraph!");
  180     assert(NumReferences == 0 && "Node deleted while references remain");
  202     assert(i < CalledFunctions.size() && "Invalid index");
  226     assert(CalledFunctions.empty() &&
  233     assert(!Call || !Call->getCalledFunction() ||
include/llvm/Analysis/DDG.h
  123     assert(!InstList.empty() && "Instruction List is empty.");
  220     assert(Root && "Root node is not available yet. Graph construction may "
  277     assert(RN && "Failed to allocate memory for DDG root node.");
  283     assert(SN && "Failed to allocate memory for simple DDG node.");
  289     assert(E && "Failed to allocate memory for edge");
  295     assert(E && "Failed to allocate memory for edge");
  301     assert(E && "Failed to allocate memory for edge");
  302     assert(isa<RootDDGNode>(Src) && "Expected root node");
include/llvm/Analysis/DominanceFrontier.h
   63     assert(Roots.size() == 1 && "Should always have entry node!");
   88     assert(find(BB) == end() && "Block already in DominanceFrontier!");
  133     assert(DT.getRoots().size() == 1 &&
include/llvm/Analysis/DominanceFrontierImpl.h
   51   assert(find(BB) != end() && "Block is not in DominanceFrontier!");
   60   assert(I != end() && "BB is not in DominanceFrontier!");
   61   assert(I->second.count(Node) && "Node is not in DominanceFrontier of BB");
   68   assert(I != end() && "BB is not in DominanceFrontier!");
   69   assert(I->second.count(Node) && "Node is not in DominanceFrontier of BB");
  171     assert(currentW && "Missing work object.");
  177     assert(currentBB && "Invalid work object. Missing current Basic Block");
  178     assert(currentNode && "Invalid work object. Missing current Node");
include/llvm/Analysis/InlineCost.h
   81     assert((isVariable() || Reason) &&
   87     assert(Cost > AlwaysInlineCost && "Cost crosses sentinel value");
   88     assert(Cost < NeverInlineCost && "Cost crosses sentinel value");
  110     assert(isVariable() && "Invalid access of InlineCost");
  116     assert(isVariable() && "Invalid access of InlineCost");
  122     assert((Reason || isVariable()) &&
include/llvm/Analysis/IntervalIterator.h
  140     assert(!IntStack.empty() && "Attempting to use interval iterator at end!");
  201     assert(Int && "Null interval == bad!");
  202     assert(Node && "Null Node == bad!");
include/llvm/Analysis/IteratedDominanceFrontier.h
   28     assert(GD);
   51     assert(GD);
include/llvm/Analysis/LazyBlockFrequencyInfo.h
   51       assert(F && BPIPass && LI && "call setAnalysis");
include/llvm/Analysis/LazyBranchProbabilityInfo.h
   65         assert(F && LI && "call setAnalysis");
include/llvm/Analysis/LazyCallGraph.h
  263       assert(EdgeIndexMap.find(&N) != EdgeIndexMap.end() && "No such edge!");
  265       assert(E && "Dead or null edge!");
  351       assert(!G == !F &&
  923       assert(RC && "Cannot increment the end iterator!");
  947       assert(!PostOrderRefSCCs.empty() &&
  953       assert(!PostOrderRefSCCs.empty() &&
 1204     assert(IndexIt != RefSCCIndices.end() && "RefSCC doesn't have an index!");
 1205     assert(PostOrderRefSCCs[IndexIt->second] == &RC &&
 1219   assert(*this && "Queried a null edge!");
 1224   assert(*this && "Queried a null edge!");
 1229   assert(*this && "Queried a null edge!");
 1234   assert(*this && "Queried a null edge!");
include/llvm/Analysis/LazyValueInfo.h
  151     assert(!Info.PImpl && "releaseMemory not called");
include/llvm/Analysis/LoopCacheAnalysis.h
   56     assert(SubNum < getNumSubscripts() && "Invalid subscript number");
   60     assert(!Subscripts.empty() && "Expecting non-empty container");
   64     assert(!Subscripts.empty() && "Expecting non-empty container");
include/llvm/Analysis/LoopInfo.h
   98     assert(!isInvalid() && "Loop not in a valid state!");
  110     assert(!isInvalid() && "Loop not in a valid state!");
  116     assert(!isInvalid() && "Loop not in a valid state!");
  126     assert(!isInvalid() && "Loop not in a valid state!");
  137     assert(!isInvalid() && "Loop not in a valid state!");
  141     assert(!isInvalid() && "Loop not in a valid state!");
  155     assert(!isInvalid() && "Loop not in a valid state!");
  162     assert(!isInvalid() && "Loop not in a valid state!");
  169     assert(!isInvalid() && "Loop not in a valid state!");
  176     assert(!isInvalid() && "Loop not in a valid state!");
  182     assert(!isInvalid() && "Loop not in a valid state!");
  188     assert(!isInvalid() && "Loop not in a valid state!");
  209     assert(!isInvalid() && "Loop not in a valid state!");
  210     assert(contains(BB) && "Exiting block must be part of the loop");
  223     assert(!isInvalid() && "Loop not in a valid state!");
  224     assert(contains(BB) && "block does not belong to the loop");
  234     assert(!isInvalid() && "Loop not in a valid state!");
  315     assert(!isInvalid() && "Loop not in a valid state!");
  376     assert(!isInvalid() && "Loop not in a valid state!");
  377     assert(!NewChild->ParentLoop && "NewChild already has a parent!");
  385     assert(!isInvalid() && "Loop not in a valid state!");
  386     assert(I != SubLoops.end() && "Cannot remove end iterator!");
  388     assert(Child->ParentLoop == this && "Child is not a child of this loop!");
  404     assert(!isInvalid() && "Loop not in a valid state!");
  411     assert(!isInvalid() && "Loop not in a valid state!");
  417     assert(!isInvalid() && "Loop not in a valid state!");
  424     assert(!isInvalid() && "Loop not in a valid state!");
  428       assert(i != Blocks.size() && "Loop does not contain BB!");
  441     assert(!isInvalid() && "Loop not in a valid state!");
  443     assert(I != Blocks.end() && "N is not in this list!");
  950     assert(I != end() && "Cannot remove end iterator!");
  952     assert(!L->getParentLoop() && "Not a top-level loop!");
  972     assert(I != TopLevelLoops.end() && "Old loop not at top level!");
  974     assert(!NewLoop->ParentLoop && !OldLoop->ParentLoop &&
  980     assert(!New->getParentLoop() && "Loop already in subloop!");
 1097     assert(Inst->getFunction() == NewLoc->getFunction() &&
include/llvm/Analysis/LoopInfoImpl.h
   36   assert(!isInvalid() && "Loop not in a valid state!");
   50   assert(!isInvalid() && "Loop not in a valid state!");
   64   assert(!isInvalid() && "Loop not in a valid state!");
   76   assert(!isInvalid() && "Loop not in a valid state!");
  104   assert(!L->isInvalid() && "Loop not in a valid state!");
  125   assert(Latch && "Latch block must exists");
  143   assert(!isInvalid() && "Loop not in a valid state!");
  161   assert(!isInvalid() && "Loop not in a valid state!");
  189   assert(!isInvalid() && "Loop not in a valid state!");
  210   assert(!isInvalid() && "Loop not in a valid state!");
  237   assert(!isInvalid() && "Loop not in a valid state!");
  241     assert(contains(SameHeader) && getHeader() == SameHeader->getHeader() &&
  245   assert(NewBB && "Cannot add a null basic block to the loop!");
  246   assert(!LIB[NewBB] && "BasicBlock already in the loop!");
  267   assert(!isInvalid() && "Loop not in a valid state!");
  268   assert(OldChild->ParentLoop == this && "This loop is already broken!");
  269   assert(!NewChild->ParentLoop && "NewChild already has a parent!");
  271   assert(I != SubLoops.end() && "OldChild not in loop!");
  280   assert(!isInvalid() && "Loop not in a valid state!");
  282   assert(!Blocks.empty() && "Loop header is missing");
  300     assert(std::any_of(GraphTraits<BlockT *>::child_begin(BB),
  305     assert(std::any_of(GraphTraits<Inverse<BlockT *>>::child_begin(BB),
  319       assert(!OutsideLoopPreds.empty() && "Loop is unreachable!");
  327           assert(CB != OutsideLoopPreds[i] &&
  330     assert(BB != &getHeader()->getParent()->front() &&
  343     assert(false && "Unreachable block in loop");
  351       assert(contains(*BI) &&
  357     assert(is_contained(*ParentLoop, this) &&
  367   assert(!isInvalid() && "Loop not in a valid state!");
  593     assert(PreOrderWorklist.empty() &&
  643   assert(H == OtherH &&
  646   assert(L->getLoopDepth() == OtherL->getLoopDepth() &&
  650     assert(ParentL->getHeader() == OtherParentL->getHeader() &&
  659     assert(OtherSubL && "Inner loop is missing in computed loop info!");
  666   assert(compareVectors(BBs, OtherBBs) &&
  671   assert(BlocksSet.size() == OtherBlocksSet.size() &&
  685     assert(!(*I)->getParentLoop() && "Top-level loop has a parent!");
  694     assert(Loops.count(L) && "orphaned loop");
  695     assert(L->contains(BB) && "orphaned block");
  697       assert(!ChildLoop->contains(BB) &&
  718     assert(OtherL && "Top level loop is missing in computed loop info!");
include/llvm/Analysis/LoopIterator.h
  130     assert(isComplete() && "bad loop DFS");
  137     assert(isComplete() && "bad loop DFS");
  154     assert(I != PostNumbers.end() && "block not visited by DFS");
  155     assert(I->second && "block not finished by DFS");
  217     assert(DFS.PostBlocks.empty() && "Need clear DFS result before traversing");
  218     assert(DFS.L->getNumBlocks() && "po_iterator cannot handle an empty graph");
  241     assert(DFS.PostNumbers.count(BB) && "Loop DFS skipped preorder");
include/llvm/Analysis/LoopPass.h
  118     assert(N < PassVector.size() && "Pass number out of range!");
include/llvm/Analysis/MemoryDependenceAnalysis.h
  132     assert(Inst && "Def requires inst");
  136     assert(Inst && "Clobber requires inst");
include/llvm/Analysis/MemoryLocation.h
  127     assert(hasValue() && "Getting value from an unknown LocationSize!");
include/llvm/Analysis/MemorySSA.h
  535     assert(V && "PHI node got a null value!");
  548     assert(this == U.getUser() && "Iterator doesn't point to PHI's Uses?");
  559     assert(BB && "PHI node got a null basic block!");
  584     assert(Idx >= 0 && "Invalid basic block argument!");
  591     assert(I < E && "Cannot remove out of bounds Phi entry.");
  594     assert(E >= 2 && "Cannot only remove incoming values in MemoryPhis with "
  612     assert(getNumOperands() >= 1 &&
  665   assert((isa<MemoryDef>(this) || isa<MemoryPhi>(this)) &&
 1027     assert(MA && "Handed an instruction that MemorySSA doesn't recognize?");
 1103     assert(MP && "Tried to get phi arg block when not iterating over a PHI");
 1108     assert(Access && "Tried to access past the end of our iterator");
 1118     assert(Access && "Hit end of iterator");
 1202     assert(DefIterator != OriginalAccess->defs_end() &&
 1209     assert(DefIterator != OriginalAccess->defs_end() &&
include/llvm/Analysis/OptimizationRemarkEmitter.h
  147     assert(ORE && "pass not run yet");
include/llvm/Analysis/PtrUseVisitor.h
  224     assert(I.getType()->isPointerTy());
include/llvm/Analysis/RegionInfo.h
 1001   assert(!isSubRegion() && "This is not a BasicBlock RegionNode!");
 1009   assert(isSubRegion() && "This is not a subregion RegionNode!");
include/llvm/Analysis/RegionInfoImpl.h
   63   assert(exit && "No exit to replace!");
  157   assert(LI && BB && "LI and BB cannot be null!");
  347   assert(contains(R) && "BB not in current region!");
  360   assert(contains(BB) && "Can get BB node out of this region!");
  376   assert(contains(BB) && "Can get BB node out of this region!");
  394   assert(!SubRegion->parent && "SubRegion already has a parent!");
  395   assert(llvm::find_if(*this,
  407   assert(SubRegion->children.empty() &&
  437   assert(Child->parent == this && "Child is not a child of this region!");
  443   assert(I != children.end() && "Region does not exit. Unable to remove.");
  552   assert(R && "Re must be non-null");
  579   assert(entry && exit && "entry and exit must not be null!");
  622   assert(entry && exit && "entry and exit must not be null!");
  651   assert(entry && exit && "entry and exit must not be null!");
  665   assert(entry && exit && "entry and exit must not be null!");
  687   assert(entry);
  878   assert(A && B && "One of the Regions is NULL");
include/llvm/Analysis/RegionIterator.h
   71     assert(Node.getInt() == ItRgBegin && "Cannot advance region successor!");
   85     assert(succ && "BB not in Region or entered subregion!");
   91     assert(Node.getInt() == ItRgBegin && "Cannot get the region successor!");
  123     assert(isRegionMode() == x.isRegionMode() && "Broken iterator!");
  134     assert(!isExit(BB) && "Iterator out of range!");
  185     assert(!Node->isSubRegion() &&
  187     assert(Node->getParent() && "A BB node must have a parent!");
  198     assert(!Node->isSubRegion() &&
  203     assert(Node->getParent() == x.Node->getParent()
  219     assert(Parent->getExit() != BB && "iterator out of range!");
include/llvm/Analysis/RegionPass.h
  118     assert(N < PassVector.size() && "Pass number out of range!");
include/llvm/Analysis/ScalarEvolution.h
  338     assert((Flags & IncrementNoWrapMask) == Flags && "Invalid flags value!");
  339     assert((OffFlags & IncrementNoWrapMask) == OffFlags &&
  346     assert((Flags & IncrementNoWrapMask) == Flags && "Invalid flags value!");
  347     assert((Mask & IncrementNoWrapMask) == Mask && "Invalid mask value!");
  355     assert((Flags & IncrementNoWrapMask) == Flags && "Invalid flags value!");
  356     assert((OnFlags & IncrementNoWrapMask) == OnFlags &&
 1212       assert(!isa<SCEVUnionPredicate>(P) && "Only add leaf predicates here!");
include/llvm/Analysis/ScalarEvolutionExpander.h
  123         assert(SE->InsertPointGuards.back() == this);
  157       assert(InsertPointGuards.empty());
  241       assert(!CanonicalMode &&
  250       assert(!CanonicalMode &&
  276       assert(IP);
include/llvm/Analysis/ScalarEvolutionExpressions.h
  160       assert(i < NumOperands && "Operand index out of range!");
  381       assert(isMinMaxType(T));
  668       assert(Result.second && "Should insert a new entry");
include/llvm/Analysis/TargetLibraryInfo.h
  132       assert(CustomNames.find(F) != CustomNames.end());
  299     assert(State == TargetLibraryInfoImpl::CustomName);
include/llvm/Analysis/TargetTransformInfoImpl.h
   57       assert(OpTy && "Cast instructions must provide the operand type");
  127     assert(FTy && "FunctionType must be provided to this routine.");
  170     assert(F && "A concrete function must be provided to this routine.");
  700     assert(F && "A concrete function must be provided to this routine.");
  733     assert(PointeeType && Ptr && "can't get GEPCost of nullptr");
  735     assert(Ptr->getType()->getScalarType()->getPointerElementType() ==
  763         assert(ConstIdx && "Unexpected GEP index");
include/llvm/Analysis/Trace.h
   75     assert(B1Idx != -1 && B2Idx != -1 && "Block is not in the trace!");
include/llvm/Analysis/ValueLattice.h
  149     assert(isConstant() && "Cannot get the constant of a non-constant!");
  154     assert(isNotConstant() && "Cannot get the constant of a non-notconstant!");
  159     assert(isConstantRange() &&
  185     assert(V && "Marking constant with NULL");
  193     assert((!isConstant() || getConstant() == V) &&
  195     assert(isUndefined());
  201     assert(V && "Marking constant with NULL");
  209     assert((!isConstant() || getConstant() != V) &&
  211     assert((!isNotConstant() || getNotConstant() == V) &&
  213     assert(isUndefined() || isConstant());
  228     assert(isUndefined());
  267     assert(isConstantRange() && "New ValueLattice type?");
  285     assert(isConstant() && isa<ConstantInt>(getConstant()) &&
include/llvm/Analysis/ValueTracking.h
  281       assert(Delta < Length);
include/llvm/Analysis/VectorUtils.h
  391     assert(Factor > 1 && "Invalid interleave factor");
  487     assert(!getMember(0)->mayWriteToMemory() &&
  489     assert(!isReverse() && "Group should have been invalidated");
  640     assert(!InterleaveGroupMap.count(Instr) &&
include/llvm/BinaryFormat/COFF.h
  495     assert(isOrdinal() && "ILT entry is not an ordinal!");
  507     assert(!isOrdinal() && "ILT entry is not a Hint/Name RVA!");
include/llvm/BinaryFormat/MachO.def
   15 HANDLE_LOAD_COMMAND(LC_SEGMENT, 0x00000001u, segment_command)
   16 HANDLE_LOAD_COMMAND(LC_SYMTAB, 0x00000002u, symtab_command)
   18 HANDLE_LOAD_COMMAND(LC_SYMSEG, 0x00000003u, symseg_command)
   19 HANDLE_LOAD_COMMAND(LC_THREAD, 0x00000004u, thread_command)
   20 HANDLE_LOAD_COMMAND(LC_UNIXTHREAD, 0x00000005u, thread_command)
   22 HANDLE_LOAD_COMMAND(LC_LOADFVMLIB, 0x00000006u, fvmlib_command)
   24 HANDLE_LOAD_COMMAND(LC_IDFVMLIB, 0x00000007u, fvmlib_command)
   26 HANDLE_LOAD_COMMAND(LC_IDENT, 0x00000008u, ident_command)
   28 HANDLE_LOAD_COMMAND(LC_FVMFILE, 0x00000009u, fvmfile_command)
   30 HANDLE_LOAD_COMMAND(LC_PREPAGE, 0x0000000Au, load_command)
   31 HANDLE_LOAD_COMMAND(LC_DYSYMTAB, 0x0000000Bu, dysymtab_command)
   32 HANDLE_LOAD_COMMAND(LC_LOAD_DYLIB, 0x0000000Cu, dylib_command)
   33 HANDLE_LOAD_COMMAND(LC_ID_DYLIB, 0x0000000Du, dylib_command)
   34 HANDLE_LOAD_COMMAND(LC_LOAD_DYLINKER, 0x0000000Eu, dylinker_command)
   35 HANDLE_LOAD_COMMAND(LC_ID_DYLINKER, 0x0000000Fu, dylinker_command)
   37 HANDLE_LOAD_COMMAND(LC_PREBOUND_DYLIB, 0x00000010u, prebound_dylib_command)
   38 HANDLE_LOAD_COMMAND(LC_ROUTINES, 0x00000011u, routines_command)
   39 HANDLE_LOAD_COMMAND(LC_SUB_FRAMEWORK, 0x00000012u, sub_framework_command)
   40 HANDLE_LOAD_COMMAND(LC_SUB_UMBRELLA, 0x00000013u, sub_umbrella_command)
   41 HANDLE_LOAD_COMMAND(LC_SUB_CLIENT, 0x00000014u, sub_client_command)
   42 HANDLE_LOAD_COMMAND(LC_SUB_LIBRARY, 0x00000015u, sub_library_command)
   44 HANDLE_LOAD_COMMAND(LC_TWOLEVEL_HINTS, 0x00000016u, twolevel_hints_command)
   46 HANDLE_LOAD_COMMAND(LC_PREBIND_CKSUM, 0x00000017u, prebind_cksum_command)
   48 HANDLE_LOAD_COMMAND(LC_LOAD_WEAK_DYLIB, 0x80000018u, dylib_command)
   49 HANDLE_LOAD_COMMAND(LC_SEGMENT_64, 0x00000019u, segment_command_64)
   50 HANDLE_LOAD_COMMAND(LC_ROUTINES_64, 0x0000001Au, routines_command_64)
   51 HANDLE_LOAD_COMMAND(LC_UUID, 0x0000001Bu, uuid_command)
   52 HANDLE_LOAD_COMMAND(LC_RPATH, 0x8000001Cu, rpath_command)
   53 HANDLE_LOAD_COMMAND(LC_CODE_SIGNATURE, 0x0000001Du, linkedit_data_command)
   54 HANDLE_LOAD_COMMAND(LC_SEGMENT_SPLIT_INFO, 0x0000001Eu, linkedit_data_command)
   55 HANDLE_LOAD_COMMAND(LC_REEXPORT_DYLIB, 0x8000001Fu, dylib_command)
   56 HANDLE_LOAD_COMMAND(LC_LAZY_LOAD_DYLIB, 0x00000020u, dylib_command)
   57 HANDLE_LOAD_COMMAND(LC_ENCRYPTION_INFO, 0x00000021u, encryption_info_command)
   58 HANDLE_LOAD_COMMAND(LC_DYLD_INFO, 0x00000022u, dyld_info_command)
   59 HANDLE_LOAD_COMMAND(LC_DYLD_INFO_ONLY, 0x80000022u, dyld_info_command)
   60 HANDLE_LOAD_COMMAND(LC_LOAD_UPWARD_DYLIB, 0x80000023u, dylib_command)
   61 HANDLE_LOAD_COMMAND(LC_VERSION_MIN_MACOSX, 0x00000024u, version_min_command)
   62 HANDLE_LOAD_COMMAND(LC_VERSION_MIN_IPHONEOS, 0x00000025u, version_min_command)
   63 HANDLE_LOAD_COMMAND(LC_FUNCTION_STARTS, 0x00000026u, linkedit_data_command)
   64 HANDLE_LOAD_COMMAND(LC_DYLD_ENVIRONMENT, 0x00000027u, dylinker_command)
   65 HANDLE_LOAD_COMMAND(LC_MAIN, 0x80000028u, entry_point_command)
   66 HANDLE_LOAD_COMMAND(LC_DATA_IN_CODE, 0x00000029u, linkedit_data_command)
   67 HANDLE_LOAD_COMMAND(LC_SOURCE_VERSION, 0x0000002Au, source_version_command)
   68 HANDLE_LOAD_COMMAND(LC_DYLIB_CODE_SIGN_DRS, 0x0000002Bu, linkedit_data_command)
   69 HANDLE_LOAD_COMMAND(LC_ENCRYPTION_INFO_64, 0x0000002Cu,
   71 HANDLE_LOAD_COMMAND(LC_LINKER_OPTION, 0x0000002Du, linker_option_command)
   72 HANDLE_LOAD_COMMAND(LC_LINKER_OPTIMIZATION_HINT, 0x0000002Eu, linkedit_data_command)
   73 HANDLE_LOAD_COMMAND(LC_VERSION_MIN_TVOS, 0x0000002Fu, version_min_command)
   74 HANDLE_LOAD_COMMAND(LC_VERSION_MIN_WATCHOS, 0x00000030u, version_min_command)
   75 HANDLE_LOAD_COMMAND(LC_NOTE, 0x00000031u, note_command)
   76 HANDLE_LOAD_COMMAND(LC_BUILD_VERSION, 0x00000032u, build_version_command)
include/llvm/BinaryFormat/MsgPackDocument.h
   79     assert(getKind() == Type::Int);
   84     assert(getKind() == Type::UInt);
   89     assert(getKind() == Type::Boolean);
   94     assert(getKind() == Type::Float);
   99     assert(getKind() == Type::Int);
  104     assert(getKind() == Type::UInt);
  109     assert(getKind() == Type::Boolean);
  114     assert(getKind() == Type::Float);
  119     assert(getKind() == Type::String);
  127       assert(Convert);
  138       assert(Convert);
  200   MapDocNode(DocNode &N) : DocNode(N) { assert(getKind() == Type::Map); }
  220   ArrayDocNode(DocNode &N) : DocNode(N) { assert(getKind() == Type::Array); }
  228     assert(N.getDocument() == getDocument());
include/llvm/Bitstream/BitCodes.h
  116   uint64_t getLiteralValue() const { assert(isLiteral()); return Val; }
  119   Encoding getEncoding() const { assert(isEncoding()); return (Encoding)Enc; }
  121     assert(isEncoding() && hasEncodingData());
  157     assert((V & ~63) == 0 && "Not a Char6 encoded character!");
include/llvm/Bitstream/BitstreamReader.h
  133     assert(canSkipToPos(ByteNo) && "Invalid location");
  159     assert(!(BitNo % 8) && "Expected bit on byte boundary");
  192     assert(NumBits && NumBits <= BitsInWord &&
include/llvm/Bitstream/BitstreamWriter.h
   79     assert((Offset & 3) == 0 && "Not 32-bit aligned");
   88     assert(CurBit == 0 && "Unflushed data remaining");
   89     assert(BlockScope.empty() && CurAbbrevs.empty() && "Block imbalance");
  107     assert((!endian::readAtBitAlignment<uint32_t, little, unaligned>(
  120     assert(NumBits && NumBits <= 32 && "Invalid value size!");
  121     assert((Val & ~(~0U >> (32-NumBits))) == 0 && "High bits set!");
  147     assert(NumBits <= 32 && "Too many bits to emit!");
  160     assert(NumBits <= 32 && "Too many bits to emit!");
  229     assert(!BlockScope.empty() && "Block scope imbalance!");
  259     assert(Op.isLiteral() && "Not a literal");
  262     assert(V == Op.getLiteralValue() &&
  270     assert(!Op.isLiteral() && "Literals should use EmitAbbreviatedLiteral!");
  301     assert(AbbrevNo < CurAbbrevs.size() && "Invalid abbrev #!");
  308       assert(e && "Expected non-empty abbreviation");
  314         assert(Op.getEncoding() != BitCodeAbbrevOp::Array &&
  325         assert(RecordIdx < Vals.size() && "Invalid abbrev/record");
  330         assert(i + 2 == e && "array op not second to last?");
  336           assert(RecordIdx == Vals.size() &&
  360           assert(RecordIdx == Vals.size() &&
  363           assert(Blob.data() == BlobData && "BlobData got moved");
  364           assert(Blob.size() == BlobLen && "BlobLen got changed");
  371         assert(RecordIdx < Vals.size() && "Invalid abbrev/record");
  376     assert(RecordIdx == Vals.size() && "Not all record operands emitted!");
  377     assert(BlobData == nullptr &&
  394       assert(isUInt<8>(B) && "Value too large to emit as byte");
include/llvm/CodeGen/AccelTable.h
  208   assert(Buckets.empty() && "Already finalized!");
  212   assert(Iter->second.Name == Name);
include/llvm/CodeGen/BasicTTIImpl.h
   85     assert(Ty->isVectorTy() && "Can only shuffle vectors");
  102     assert(Ty->isVectorTy() && "Can only shuffle vectors");
  123     assert(Ty && Ty->isVectorTy() && SubTy && SubTy->isVectorTy() &&
  126     assert((Index + NumSubElts) <= (int)Ty->getVectorNumElements() &&
  145     assert(Ty && Ty->isVectorTy() && SubTy && SubTy->isVectorTy() &&
  148     assert((Index + NumSubElts) <= (int)Ty->getVectorNumElements() &&
  561     assert(Ty->isVectorTy() && "Can only scalarize vectors");
  589           assert((VF == 1 || VF == VecTy->getVectorNumElements()) &&
  603     assert(VecTy->isVectorTy());
  631     assert(ISD && "Invalid opcode");
  691     assert(ISD && "Invalid opcode");
  829     assert(ISD && "Invalid opcode");
  833       assert(CondTy && "CondTy must exist");
  875     assert(!Src->isVoidTy() && "Invalid type");
  911     assert(VT && "Expect a vector type for interleaved memory op");
  914     assert(Factor > 1 && NumElts % Factor == 0 && "Invalid interleave factor");
  983       assert(Indices.size() <= Factor &&
  987         assert(Index < Factor && "Invalid index for interleaved memory op");
 1064     assert((RetVF == 1 || VF == 1) && "VF > 1 and RetVF is a vector type");
 1073         assert(VF == 1 || !OpTy->isVectorTy());
 1095       assert(VF == 1 && "Can't vectorize types here.");
 1103       assert(VF == 1 && "Can't vectorize types here.");
 1597     assert(Ty->isVectorTy() && "Expect a vector type");
 1647     assert(Ty->isVectorTy() && "Expect a vector type");
 1656       assert(Ty->isIntOrIntVectorTy() &&
include/llvm/CodeGen/CallingConvLower.h
  150   Register getLocReg() const { assert(isRegLoc()); return Loc; }
  151   unsigned getLocMemOffset() const { assert(isMemLoc()); return Loc; }
  474     assert(InRegsParamRecordIndex < ByValRegs.size() &&
include/llvm/CodeGen/DIE.h
  515     assert(N.Next.getPointer() == &N && "Expected unlinked node");
  516     assert(N.Next.getInt() == true && "Expected unlinked node");
  526     assert(N.Next.getPointer() == &N && "Expected unlinked node");
  527     assert(N.Next.getInt() == true && "Expected unlinked node");
  820     assert(!Child->getParent() && "Child should be orphaned");
  827     assert(!Child->getParent() && "Child should be orphaned");
  873     assert(!this->Section);
include/llvm/CodeGen/DwarfStringPoolEntry.h
   47     assert(getMapEntry()->second.Symbol && "No symbol available!");
   53     assert(isIndexed());
   54     assert(getMapEntry()->getValue().isIndexed());
include/llvm/CodeGen/ExecutionDomainFix.h
   77     assert(domain <
include/llvm/CodeGen/FaultMaps.h
  101     assert(P + sizeof(T) <= E && "out of bounds read!");
  172       assert(Index < getNumFaultingPCs() && "index out of bounds!");
  183       assert(Begin < E && "out of bounds!");
  193     assert(Version == 1 && "only version 1 supported!");
include/llvm/CodeGen/FunctionLoweringInfo.h
  213     assert(R == 0 && "Already initialized this value register!");
  214     assert(VirtReg2Value.empty());
include/llvm/CodeGen/GlobalISel/CallLowering.h
   64       assert((Ty->isVoidTy() == (Regs.empty() || Regs[0] == 0)) &&
  268       assert(SwiftErrorVReg == 0 && "attempt to use unsupported swifterror");
include/llvm/CodeGen/GlobalISel/CombinerInfo.h
   35     assert(((AllowIllegalOps || !LegalizeIllegalOps) || LInfo) &&
include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h
   47       assert(DstOps.size() == 1 && "Invalid dst ops");
   48       assert(SrcOps.size() == 2 && "Invalid src ops");
   58       assert(DstOps.size() == 1 && "Invalid dst ops");
   59       assert(SrcOps.size() == 2 && "Invalid src ops");
include/llvm/CodeGen/GlobalISel/GISelWorkList.h
   66     assert(WorklistMap.empty() && "Expecting empty worklistmap");
   79     assert(Finalized && "GISelWorkList used without finalizing");
   86     assert((Finalized || WorklistMap.empty()) && "Neither finalized nor empty");
  103     assert(Finalized && "GISelWorkList used without finalizing");
  108     assert(I && "Pop back on empty worklist");
include/llvm/CodeGen/GlobalISel/IRTranslator.h
  117       assert(ValToVRegs.find(&V) == ValToVRegs.end() && "Value already exists");
  127       assert(TypeToOffsets.find(V.getType()) == TypeToOffsets.end() &&
  530       assert(irt && "irt is null!");
  566     assert(Regs.size() == 1 &&
include/llvm/CodeGen/GlobalISel/InstructionSelectorImpl.h
   74     assert(CurrentIdx != ~0u && "Invalid MatchTable index");
   91       assert(NewInsnID != 0 && "Refusing to modify MIs[0]");
  113         assert((size_t)NewInsnID == State.MIs.size() &&
  142       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  162       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  190       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  233       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  247       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  248       assert(State.MIs[InsnID]->getOpcode() == TargetOpcode::G_CONSTANT &&
  250       assert(Predicate > GIPFP_I64_Invalid && "Expected a valid predicate");
  271       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  272       assert(State.MIs[InsnID]->getOpcode() == TargetOpcode::G_CONSTANT &&
  274       assert(Predicate > GIPFP_APInt_Invalid && "Expected a valid predicate");
  293       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  294       assert(State.MIs[InsnID]->getOpcode() == TargetOpcode::G_FCONSTANT &&
  296       assert(State.MIs[InsnID]->getOperand(1).isFPImm() && "Expected FPImm operand");
  297       assert(Predicate > GIPFP_APFloat_Invalid && "Expected a valid predicate");
  312       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  313       assert(Predicate > GIPFP_MI_Invalid && "Expected a valid predicate");
  326       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  344       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  362       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  417       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  446       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  482       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  525       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  543       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  554       assert(SizeInBits != 0 && "Pointer size must be known");
  573       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  595       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  616       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  641       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  658       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  673       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  686       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  699       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  711       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  727       assert(State.MIs[InsnID] != nullptr && "Used insn before defined");
  728       assert(State.MIs[OtherInsnID] != nullptr && "Used insn before defined");
  778       assert(OutMIs[NewInsnID] && "Attempted to add to undefined instruction");
  792       assert(OutMIs[NewInsnID] && "Attempted to add to undefined instruction");
  810       assert(OutMIs[NewInsnID] && "Attempted to add to undefined instruction");
  823       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  834       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  846       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  859       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  871       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  882       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  894       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  907       assert(OutMIs[NewInsnID] && "Attempted to add to undefined instruction");
  908       assert(State.MIs[OldInsnID]->getOpcode() == TargetOpcode::G_CONSTANT && "Expected G_CONSTANT");
  926       assert(OutMIs[NewInsnID] && "Attempted to add to undefined instruction");
  927       assert(State.MIs[OldInsnID]->getOpcode() == TargetOpcode::G_FCONSTANT && "Expected G_FCONSTANT");
  943       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  956       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  968       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  980       assert(OutMIs[InsnID] && "Attempted to add to undefined instruction");
  999       assert(State.MIs[InsnID] &&
include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
   50     assert(MI.getOpcode() == TargetOpcode::G_ANYEXT);
   95     assert(MI.getOpcode() == TargetOpcode::G_ZEXT);
  136     assert(MI.getOpcode() == TargetOpcode::G_SEXT);
  162     assert(MI.getOpcode() == TargetOpcode::G_TRUNC);
  190     assert(Opcode == TargetOpcode::G_ANYEXT || Opcode == TargetOpcode::G_ZEXT ||
  251     assert(MI.getOpcode() == TargetOpcode::G_UNMERGE_VALUES);
  377     assert(MI.getOpcode() == TargetOpcode::G_EXTRACT);
  503           assert((TmpDef->getOpcode() == TargetOpcode::COPY ||
include/llvm/CodeGen/GlobalISel/LegalizerInfo.h
  339     assert(TypeIdx <=
  349     assert(ImmIdx <= (MCOI::OPERAND_LAST_GENERIC_IMM -
  366     assert(AliasOf == 0 &&
  469     assert((AliasOf == 0 || AliasOf == Opcode) &&
  471     assert(Rules.empty() && "Aliasing will discard rules");
  804     assert(MinTy.isScalar() && MaxTy.isScalar() && "Expected scalar types");
  899     assert(MinTy.getElementType() == MaxTy.getElementType() &&
  968     assert(!needsLegalizingToDifferentSize(Action));
 1035     assert(v.size() > 0 &&
 1059     assert(v.size() > 0 &&
 1241       assert(SizeAndAction.first > prev_size);
 1273       assert(SmallestLegalizableToSameSizeIdx != -1);
 1274       assert(SmallestNarrowIdx > SmallestLegalizableToSameSizeIdx);
 1277       assert(LargestWidenIdx < LargestLegalizableToSameSizeIdx);
 1286     assert(v.size() >= 1);
 1287     assert(v[0].first == 1);
include/llvm/CodeGen/GlobalISel/MachineIRBuilder.h
  101     assert(Ty == DstType::Ty_Reg && "Not a register");
  248     assert(State.TII && "TargetInstrInfo is not set");
  254     assert(State.MF && "MachineFunction is not set");
  259     assert(State.MF && "MachineFunction is not set");
  279     assert(State.MBB && "MachineBasicBlock is not set");
include/llvm/CodeGen/GlobalISel/RegBankSelect.h
  151         assert(canMaterialize() && "Impossible to materialize this point");
  155       assert(!isSplit() && "Wrong pre-condition");
  170         assert(canMaterialize() && "Impossible to materialize this point");
  174       assert(!isSplit() && "Wrong pre-condition");
  258       assert((!Beginning || MBB.getFirstNonPHI() == MBB.begin()) &&
  262       assert((Beginning || MBB.getFirstTerminator() == MBB.end()) &&
  291       assert(DstOrSplit && DstOrSplit->isPredecessor(&Src) &&
  399       assert(NewKind != Kind && "Already of the right Kind");
  404       assert(NewKind != RepairingKind::Insert &&
include/llvm/CodeGen/GlobalISel/RegisterBankInfo.h
  203       assert(i < getNumOperands() && "Out of bound operand");
  431     assert(ID < getNumRegBanks() && "Accessing an unknown register bank");
include/llvm/CodeGen/LatencyPriorityQueue.h
   69       assert(NodeNum < (*SUnits).size());
   74       assert(NodeNum < NumNodesSolelyBlocking.size());
include/llvm/CodeGen/LexicalScopes.h
   49     assert(D);
   50     assert(D->getSubprogram()->getUnit()->getEmissionKind() !=
   53     assert(D->isResolved() && "Expected resolved node");
   54     assert((!I || I->isResolved()) && "Expected resolved node");
   83     assert(FirstInsn && "MI Range is not open!");
   93     assert(LastInsn && "Last insn missing!");
include/llvm/CodeGen/LiveInterval.h
  171         assert(S < E && "Cannot create empty or backwards segment");
  181         assert((S < E) && "Backwards interval?");
  237       assert(Other.segmentSet == nullptr &&
  247       assert(Other.segmentSet == nullptr &&
  263       assert(I != end());
  271       assert(I != end());
  377       assert(!empty() && "Call to beginIndex() on empty range.");
  384       assert(!empty() && "Call to endIndex() on empty range.");
  620       assert(std::is_sorted(R.begin(), R.end()));
include/llvm/CodeGen/LiveIntervalUnion.h
  186       assert(idx <  Size && "idx out of bounds");
  191       assert(Idx < Size && "Idx out of bounds");
include/llvm/CodeGen/LiveIntervals.h
  132       assert(!hasInterval(Reg) && "Interval already exists!");
  261       assert(unsigned(MBB->getNumber()) == RegMaskBlocks.size() &&
include/llvm/CodeGen/LivePhysRegs.h
   80     assert(TRI && "LivePhysRegs is not initialized.");
   81     assert(Reg <= TRI->getNumRegs() && "Expected a physical register.");
   90     assert(TRI && "LivePhysRegs is not initialized.");
   91     assert(Reg <= TRI->getNumRegs() && "Expected a physical register.");
include/llvm/CodeGen/LiveRangeEdit.h
  151     assert(Parent && "No parent LiveInterval");
include/llvm/CodeGen/LiveRegUnits.h
   66         assert(O->isUse() && "Reg operand not a def and not a use");
include/llvm/CodeGen/LiveStacks.h
   64     assert(Slot >= 0 && "Spill slot indice must be >= 0");
   66     assert(I != S2IMap.end() && "Interval does not exist for stack slot");
   71     assert(Slot >= 0 && "Spill slot indice must be >= 0");
   73     assert(I != S2IMap.end() && "Interval does not exist for stack slot");
   80     assert(Slot >= 0 && "Spill slot indice must be >= 0");
   83     assert(I != S2RCMap.end() &&
include/llvm/CodeGen/LiveVariables.h
  224     assert(Removed && "Register is not used by this instruction!");
  259     assert(Removed && "Register is not defined by this instruction!");
include/llvm/CodeGen/MachineBasicBlock.h
  614     assert((I == end() || I->getParent() == this) &&
  621     assert((I == end() || I->getParent() == this) &&
  623     assert(!MI->isBundledWithPred() && !MI->isBundledWithSucc() &&
  630     assert((I == end() || I->getParent() == this) &&
  632     assert(!MI->isBundledWithPred() && !MI->isBundledWithSucc() &&
  640     assert((I == instr_end() || I->getParent() == this) &&
  642     assert(!MI->isBundledWithPred() && !MI->isBundledWithSucc() &&
  689     assert(!I->isBundled() && "Cannot remove bundled instructions");
  930     assert(I == BB->end() || I->getParent() == BB);
include/llvm/CodeGen/MachineDominators.h
  247     assert(Inserted &&
include/llvm/CodeGen/MachineFrameInfo.h
  406     assert (i >= 0 && (unsigned)i < LocalFrameObjects.size() &&
  444     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  451     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  458     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  465     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  472     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  484     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  492     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  494     assert(!isDeadObjectIndex(ObjectIdx) &&
  500     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  506     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  512     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  518     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  526     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  528     assert(!isDeadObjectIndex(ObjectIdx) &&
  534     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  540     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  542     assert(!isDeadObjectIndex(ObjectIdx) &&
  664     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  674     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  681     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  688     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  694     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  706     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  715     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  723     assert(unsigned(ObjectIdx + NumFixedObjects) < Objects.size() &&
  729     assert(unsigned(ObjectIdx+NumFixedObjects) < Objects.size() &&
  732     assert(isStatepointSpillSlotObjectIndex(ObjectIdx) && "inconsistent");
include/llvm/CodeGen/MachineFunction.h
   86     assert(this == &OldList && "never transfer MBBs between functions");
  390       assert(Arg < (1 << 16) && "Arg out of range");
  407     assert(MI->isCall() &&
  439     assert(TheDelegate == delegate &&
  447     assert(delegate && !TheDelegate &&
  587     assert(N < MBBNumbering.size() && "Illegal block number");
  588     assert(MBBNumbering[N] && "Block was removed from the machine function!");
  715     assert(N < MBBNumbering.size() && "Illegal basic block #");
  918     assert(hasWasmLandingPadIndex(LPad));
  924     assert(hasCallSiteLandingPad(Sym) &&
  941     assert(hasCallSiteBeginLabel(BeginLabel) &&
  986     assert(CallI->isCall());
include/llvm/CodeGen/MachineInstr.h
  432     assert(i < getNumOperands() && "getOperand() out of range!");
  436     assert(i < getNumOperands() && "getOperand() out of range!");
  463     assert(getOperand(OpIdx).getType() == MachineOperand::MO_Immediate &&
  636     assert(MCFlag < 64 &&
 1565     assert(debugLoc.hasTrivialDestructor() && "Expected trivial destructor");
include/llvm/CodeGen/MachineInstrBuilder.h
   90     assert((flags & 0x1) == 0 &&
  116     assert(!(Flags & RegState::Define) &&
  229     assert((MI->isDebugValue() ? static_cast<bool>(MI->getDebugVariable())
  232     assert((MI->isDebugLabel() ? static_cast<bool>(MI->getDebugLabel())
  497   assert(RegOp.isReg() && "Not a register operand");
  527     assert(B != E && "No instructions to bundle");
include/llvm/CodeGen/MachineInstrBundle.h
  138     assert(isValid() && "Cannot advance MIOperands beyond the last operand");
include/llvm/CodeGen/MachineInstrBundleIterator.h
  133     assert((!MI.getNodePtr() || MI.isEnd() || !MI->isBundledWithPred()) &&
  139     assert(!MI.isBundledWithPred() && "It's not legal to initialize "
  146     assert((!MI || !MI->isBundledWithPred()) && "It's not legal to initialize "
include/llvm/CodeGen/MachineModuleInfoImpls.h
   44     assert(Sym && "Key cannot be null");
   49     assert(Sym && "Key cannot be null");
   73     assert(Sym && "Key cannot be null");
   95     assert(Sym && "Key cannot be null");
include/llvm/CodeGen/MachineOperand.h
  222     assert(!isReg() && "Register operands can't have target flags");
  224     assert(SubReg_TargetFlags == F && "Target flags out of range");
  227     assert(!isReg() && "Register operands can't have target flags");
  229     assert((SubReg_TargetFlags & F) && "Target flags out of range");
  354     assert(isReg() && "This is not a register operand!");
  359     assert(isReg() && "Wrong MachineOperand accessor");
  364     assert(isReg() && "Wrong MachineOperand accessor");
  369     assert(isReg() && "Wrong MachineOperand accessor");
  374     assert(isReg() && "Wrong MachineOperand accessor");
  379     assert(isReg() && "Wrong MachineOperand accessor");
  384     assert(isReg() && "Wrong MachineOperand accessor");
  389     assert(isReg() && "Wrong MachineOperand accessor");
  425     assert(isReg() && "Wrong MachineOperand accessor");
  430     assert(isReg() && "Wrong MachineOperand accessor");
  435     assert(isReg() && "Wrong MachineOperand accessor");
  440     assert(isReg() && "Wrong MachineOperand accessor");
  452     assert(isReg() && "Wrong MachineOperand accessor");
  465     assert(isReg() && "Wrong MachineOperand mutator");
  467     assert(SubReg_TargetFlags == subReg && "SubReg out of range");
  489     assert(isReg() && "Wrong MachineOperand mutator");
  494     assert(isReg() && !IsDef && "Wrong MachineOperand mutator");
  495     assert((!Val || !isDebug()) && "Marking a debug operation as kill");
  500     assert(isReg() && IsDef && "Wrong MachineOperand mutator");
  505     assert(isReg() && "Wrong MachineOperand mutator");
  512     assert(isReg() && "Wrong MachineOperand mutator");
  517     assert(isReg() && IsDef && "Wrong MachineOperand mutator");
  522     assert(isReg() && !IsDef && "Wrong MachineOperand mutator");
  531     assert(isImm() && "Wrong MachineOperand accessor");
  536     assert(isCImm() && "Wrong MachineOperand accessor");
  541     assert(isFPImm() && "Wrong MachineOperand accessor");
  546     assert(isMBB() && "Wrong MachineOperand accessor");
  551     assert((isFI() || isCPI() || isTargetIndex() || isJTI()) &&
  557     assert(isGlobal() && "Wrong MachineOperand accessor");
  562     assert(isBlockAddress() && "Wrong MachineOperand accessor");
  567     assert(isMCSymbol() && "Wrong MachineOperand accessor");
  572     assert(isCFIIndex() && "Wrong MachineOperand accessor");
  577     assert(isIntrinsicID() && "Wrong MachineOperand accessor");
  582     assert(isPredicate() && "Wrong MachineOperand accessor");
  587     assert(isShuffleMask() && "Wrong MachineOperand accessor");
  594     assert((isGlobal() || isSymbol() || isMCSymbol() || isCPI() ||
  602     assert(isSymbol() && "Wrong MachineOperand accessor");
  612     assert(PhysReg < (1u << 30) && "Not a physical register");
  624     assert(isRegMask() && "Wrong MachineOperand accessor");
  635     assert(isRegLiveOut() && "Wrong MachineOperand accessor");
  640     assert(isMetadata() && "Wrong MachineOperand accessor");
  649     assert(isImm() && "Wrong MachineOperand mutator");
  654     assert(isCImm() && "Wrong MachineOperand mutator");
  659     assert(isFPImm() && "Wrong MachineOperand mutator");
  664     assert((isGlobal() || isSymbol() || isMCSymbol() || isCPI() ||
  672     assert((isFI() || isCPI() || isTargetIndex() || isJTI()) &&
  678     assert(isMetadata() && "Wrong MachineOperand mutator");
  683     assert(isMBB() && "Wrong MachineOperand mutator");
  692     assert(isRegMask() && "Wrong MachineOperand mutator");
  697     assert(isPredicate() && "Wrong MachineOperand mutator");
  781     assert(!(isDead && !isDef) && "Dead flag on non-def");
  782     assert(!(isKill && isDef) && "Kill flag on def");
  870     assert(Mask && "Missing register mask");
  876     assert(Mask && "Missing live-out register mask");
  944     assert(isReg() && "Can only add reg operand to use lists");
include/llvm/CodeGen/MachineOptimizationRemarkEmitter.h
  219     assert(ORE && "pass not run yet");
include/llvm/CodeGen/MachineOutliner.h
  139     assert(MBB->getParent()->getRegInfo().tracksLiveness() &&
include/llvm/CodeGen/MachinePipeliner.h
  564     assert(it != InstrToCycle.end() && "Instruction hasn't been scheduled.");
include/llvm/CodeGen/MachineRegionInfo.h
  114   assert(!isSubRegion() && "This is not a MachineBasicBlock RegionNode!");
  123   assert(isSubRegion() && "This is not a subregion RegionNode!");
include/llvm/CodeGen/MachineRegisterInfo.h
  124     assert(MO && MO->isReg() && "This is not a register operand!");
  161     assert(TheDelegate == delegate &&
  167     assert(delegate && !TheDelegate &&
  218     assert(VReg.isVirtual() && "Must pass a VReg");
  433     assert((Name.empty() || VRegNames.find(Name) == VRegNames.end()) &&
  632     assert(VRegInfo[Reg.id()].first.is<const TargetRegisterClass *>() &&
  763     assert(Register::isVirtualRegister(VReg));
  772     assert(Register::isVirtualRegister(VReg));
  783     assert (RegAllocHints[VReg].first == 0 &&
  793     assert(VReg.isVirtual());
  803     assert(VReg.isVirtual());
  812     assert(Register::isVirtualRegister(VReg));
  826       assert(MI->isDebugInstr());
  827       assert(MI->getOperand(0).isReg());
  887     assert(reservedRegsFrozen() &&
  988       assert(Op && "Cannot increment end iterator!");
  997             assert(!Op->isDebug() && "Can't have debug defs");
 1027       assert(Op && "Cannot increment end iterator!");
 1052       assert(Op && "Cannot dereference end iterator!");
 1058       assert(Op && "Cannot dereference end iterator!");
 1063       assert(Op && "Cannot dereference end iterator!");
 1094       assert(Op && "Cannot increment end iterator!");
 1103             assert(!Op->isDebug() && "Can't have debug defs");
 1133       assert(Op && "Cannot increment end iterator!");
 1157       assert(Op && "Cannot dereference end iterator!");
 1199     assert(isValid() && "Invalid PSetIterator.");
include/llvm/CodeGen/MachineScheduler.h
  871       assert(Best.Reason != NoCand && "uninitialized Sched candidate");
include/llvm/CodeGen/PBQP/Graph.h
  112         assert(ThisEdgeAdjIdxs[NIdx] == NodeEntry::getInvalidAdjEdgeIdx() &&
  127           assert(NId == NIds[1] && "Edge not connected to NId");
  133         assert(ThisEdgeAdjIdxs[NIdx] != NodeEntry::getInvalidAdjEdgeIdx() &&
  144           assert(NId == NIds[1] && "Edge does not connect NId");
  181       assert(NId < Nodes.size() && "Out of bound NodeId");
  185       assert(NId < Nodes.size() && "Out of bound NodeId");
  206       assert(findEdge(E.getN1Id(), E.getN2Id()) == invalidEdgeId() &&
  357       assert(!Solver && "Solver already set. Call unsetSolver().");
  367       assert(Solver && "Solver not set.");
  410       assert(getNodeCosts(N1Id).getLength() == Costs.getRows() &&
  436       assert(getNodeCosts(N1Id).getLength() == Costs->getRows() &&
include/llvm/CodeGen/PBQP/Math.h
   53     assert(Length != 0 && Data && "Invalid vector");
   61     assert(Length != 0 && Data && "Invalid vector");
   67     assert(Length != 0 && Data && "Invalid vector");
   68     assert(Index < Length && "Vector element access out of bounds.");
   74     assert(Length != 0 && Data && "Invalid vector");
   75     assert(Index < Length && "Vector element access out of bounds.");
   81     assert(Length != 0 && Data && "Invalid vector");
   82     assert(Length == V.Length && "Vector length mismatch.");
   90     assert(Length != 0 && Data && "Invalid vector");
  110   assert((V.getLength() != 0) && "Zero-length vector badness.");
  154     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  162     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  168     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  174     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  175     assert(R < Rows && "Row out of bounds.");
  181     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  182     assert(R < Rows && "Row out of bounds.");
  188     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  197     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  206     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  216     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  217     assert(Rows == M.Rows && Cols == M.Cols &&
  225     assert(Rows != 0 && Cols != 0 && Data && "Invalid matrix");
  248   assert((M.getRows() != 0) && "Zero-row matrix badness.");
include/llvm/CodeGen/PBQP/ReductionRules.h
   37     assert(G.getNodeDegree(NId) == 1 &&
   81     assert(G.getNodeDegree(NId) == 2 &&
  198         assert(hasRegisterOptions(v) && "A conservatively allocatable node "
include/llvm/CodeGen/PBQP/Solution.h
   47       assert(sItr != selections.end() && "No selection for node.");
include/llvm/CodeGen/RegAllocPBQP.h
  215     assert(RS >= this->RS && "A node's reduction state can not be downgraded");
  299     assert(G.getNodeCosts(NId).getLength() > 1 &&
  366       assert(OptimallyReducibleNodes.find(NId) !=
  372       assert(ConservativelyAllocatableNodes.find(NId) !=
  378       assert(NotProvablyAllocatableNodes.find(NId) !=
  426     assert(!G.empty() && "Cannot reduce empty graph.");
include/llvm/CodeGen/Register.h
   51     assert(isStackSlot(Reg) && "Not a stack slot");
   57     assert(FI >= 0 && "Cannot hold a negative frame index.");
   70     assert(!isStackSlot(Reg) && "Not a register! Check isStackSlot() first.");
   77     assert(isVirtualRegister(Reg) && "Not a virtual register");
include/llvm/CodeGen/RegisterClassInfo.h
  113     assert(Register::isPhysicalRegister(PhysReg));
include/llvm/CodeGen/RegisterPressure.h
  110     assert(id < std::numeric_limits<uint16_t>::max() && "PSetID overflow.");
  116     assert(isValid() && "invalid PressureChange");
  212     assert(Idx < Size && "PressureDiff index out of bounds");
  281     assert(Reg < NumRegUnits);
  510     assert(isBottomClosed() && "Uninitialized pressure tracker");
  531     assert(isBottomClosed() && "Uninitialized pressure tracker");
include/llvm/CodeGen/ResourcePriorityQueue.h
   94       assert(NodeNum < (*SUnits).size());
   99       assert(NodeNum < NumNodesSolelyBlocking.size());
include/llvm/CodeGen/ScheduleDAG.h
  111         assert(Reg != 0 &&
  219       assert((getKind() == Data || getKind() == Anti || getKind() == Output) &&
  229       assert((getKind() == Data || getKind() == Anti || getKind() == Output) &&
  231       assert((getKind() != Anti || Reg != 0) &&
  233       assert((getKind() != Output || Reg != 0) &&
  349       assert(!Instr && "Setting SDNode of SUnit with MachineInstr!");
  356       assert(!Instr && "Reading SDNode of SUnit with MachineInstr!");
  367       assert(!Node && "Setting MachineInstr of SUnit with SDNode!");
  374       assert(!Node && "Reading MachineInstr of SUnit with SDNode!");
  521       assert(!HasReadyFilter && "The ready filter must override isReady()");
include/llvm/CodeGen/ScheduleDAGInstrs.h
  389     assert((Addr == nullptr || Addr == &SUnits[0]) &&
include/llvm/CodeGen/ScheduleDFS.h
  172     assert(SU->NodeNum < DFSNodeData.size() &&  "New Node");
include/llvm/CodeGen/ScoreboardHazardRecognizer.h
   61       assert(Depth && !(Depth & (Depth - 1)) &&
include/llvm/CodeGen/SelectionDAG.h
  299       assert(DAG.UpdateListeners == this &&
  484     assert((!N.getNode() || N.getValueType() == MVT::Other) &&
  770       assert((VT.getVectorElementType() == Op.getValueType() ||
  786       assert((VT.getVectorElementType() == Op.getValueType() ||
  979     assert(LHS.getValueType().isVector() == RHS.getValueType().isVector() &&
  981     assert(LHS.getValueType().isVector() == VT.isVector() &&
  983     assert(Cond != ISD::SETCC_INVALID &&
  992     assert(LHS.getValueType() == RHS.getValueType() &&
  994     assert(VT.isVector() == LHS.getValueType().isVector() &&
include/llvm/CodeGen/SelectionDAGNodes.h
  732     assert(isMachineOpcode() && "Not a MachineInstr opcode!");
  803       assert(Op && "Cannot increment end iterator!");
  814       assert(Op && "Cannot dereference end iterator!");
  824       assert(Op && "Cannot dereference end iterator!");
  952     assert(Num < NumOperands && "Invalid child # of SDNode!");
 1015     assert(ResNo < NumValues && "Illegal result number!");
 1109     assert(debugLoc.hasTrivialDestructor() && "Expected trivial destructor");
 1110     assert(NumValues == VTs.NumVTs &&
 1137     assert(Order >= 0 && "bad IROrder");
 1153   assert((!Node || !ResNo || ResNo < Node->getNumValues()) &&
 1155   assert(ResNo < -2U && "Cannot use result numbers reserved for DenseMaps.");
 1440     assert(((Opc != ISD::ATOMIC_LOAD && Opc != ISD::ATOMIC_STORE) ||
 1458     assert(isCompareAndSwap() && "Must be cmpxchg operation");
 1533     assert(Idx < getValueType(0).getVectorNumElements() && "Idx out of range!");
 1540     assert(isSplat() && "Cannot get splat index for non-splat!");
 1784     assert(hasOffset() && "offset is unknown");
 1788     assert(hasOffset() && "offset is unknown");
 1836     assert(Offset >= 0 && "Offset is too large");
 1845     assert(Offset >= 0 && "Offset is too large");
 1856     assert(!isMachineConstantPoolEntry() && "Wrong constantpool type");
 1861     assert(isMachineConstantPoolEntry() && "Wrong constantpool type");
 2113     assert(LabelSDNode::classof(this) && "not a label opcode");
 2206     assert(getAddressingMode() == AM && "Value truncated");
 2240     assert(readMem() && "Load MachineMemOperand is not a load!");
 2241     assert(!writeMem() && "Load MachineMemOperand is a store!");
 2268     assert(!readMem() && "Store MachineMemOperand is a load!");
 2269     assert(writeMem() && "Store MachineMemOperand is not a store!");
 2389     assert(getIndexType() == IndexType && "Value truncated");
 2548     assert(Node == Other.Node &&
include/llvm/CodeGen/SlotIndexes.h
  116       assert(isValid() && "Attempt to compare reserved index.");
  145       assert(lie.getPointer() != nullptr &&
  374       assert(indexList.front().getIndex() == 0 && "First index is not 0?");
  397       assert(!BundleNonDebug.isDebugInstr() &&
  400       assert(itr != mi2iMap.end() && "Instruction not found in maps.");
  427       assert(MBB && "MI must be inserted in a basic block");
  444       assert(MBB && "MI must be inserted in a basic block");
  527       assert(J != MBBIndexEnd() && J->first <= index &&
  539       assert(!MI.isInsideBundle() &&
  541       assert(mi2iMap.find(&MI) == mi2iMap.end() && "Instr already indexed.");
  544       assert(!MI.isDebugInstr() && "Cannot number debug instructions.");
  546       assert(MI.getParent() != nullptr && "Instr must be added to function.");
  597       assert(miEntry->getInstr() == &MI &&
  627       assert(prevMBB != mbb->getParent()->end() &&
  632       assert(unsigned(mbb->getNumber()) == MBBRanges.size() &&
include/llvm/CodeGen/StackMaps.h
   86     assert(Pos < MetaEnd && "Meta operand index out of range.");
include/llvm/CodeGen/TargetCallingConv.h
  134       assert(getByValAlign() == A.value() && "bitfield overflow");
  143       assert(getOrigAlign() == A.value() && "bitfield overflow");
  186       assert(OrigArgIndex != NoArgIndex && "Implicit machine-level argument");
include/llvm/CodeGen/TargetInstrInfo.h
  189     assert(isFrameInstr(I) && "Not a frame instruction");
  190     assert(I.getOperand(0).getImm() >= 0);
  199       assert(I.getOperand(1).getImm() >= 0 &&
  879     assert(MI.getDesc().isSelect() && "MI must be a select instruction");
 1624     assert((MIa.mayLoad() || MIa.mayStore()) &&
 1626     assert((MIb.mayLoad() || MIb.mayStore()) &&
include/llvm/CodeGen/TargetLowering.h
  700     assert(RC && "This value type is not natively supported!");
  741     assert(!VT.isSimple() ||
  796     assert(!VT.isVector());
 1100     assert(ExtType < ISD::LAST_LOADEXT_TYPE && ValI < MVT::LAST_VALUETYPE &&
 1125     assert(ValI < MVT::LAST_VALUETYPE && MemI < MVT::LAST_VALUETYPE &&
 1149     assert(IdxMode < ISD::LAST_INDEXED_MODE && VT.isValid() &&
 1167     assert(IdxMode < ISD::LAST_INDEXED_MODE && VT.isValid() &&
 1185     assert((unsigned)CC < array_lengthof(CondCodeActions) &&
 1192     assert(Action != Promote && "Can't promote condition code!");
 1211     assert(getOperationAction(Op, VT) == Promote &&
 1220     assert((VT.isInteger() || VT.isFloatingPoint()) &&
 1226       assert(NVT.isInteger() == VT.isInteger() && NVT != MVT::isVoid &&
 1289     assert((unsigned)VT.SimpleTy < array_lengthof(RegisterTypeForVT));
 1296       assert((unsigned)VT.getSimpleVT().SimpleTy <
 1324       assert((unsigned)VT.getSimpleVT().SimpleTy <
 1393     assert(unsigned(NT >> 3) < array_lengthof(TargetDAGCombineArray));
 2020     assert((unsigned)VT.SimpleTy < array_lengthof(RegClassForVT));
 2038     assert(Op < array_lengthof(OpActions[0]) && "Table isn't big enough!");
 2046     assert(ExtType < ISD::LAST_LOADEXT_TYPE && ValVT.isValid() &&
 2048     assert((unsigned)Action < 0x10 && "too many bits for bitfield array");
 2058     assert(ValVT.isValid() && MemVT.isValid() && "Table isn't big enough!");
 2069     assert(VT.isValid() && IdxMode < ISD::LAST_INDEXED_MODE &&
 2083     assert(VT.isValid() && IdxMode < ISD::LAST_INDEXED_MODE &&
 2094     assert(VT.isValid() && (unsigned)CC < array_lengthof(CondCodeActions) &&
 2096     assert((unsigned)Action < 0x10 && "too many bits for bitfield array");
 2124     assert(unsigned(NT >> 3) < array_lengthof(TargetDAGCombineArray));
 2390       assert(isa<SExtInst>(Ext) && "Unexpected ext type!");
 2500     assert(SrcVT.isFloatingPoint() && DestVT.isFloatingPoint() &&
 2509     assert(DestVT.isFloatingPoint() && SrcVT.isFloatingPoint() &&
 2521     assert(VT.isFloatingPoint());
 2528     assert(VT.isFloatingPoint());
 3764     assert(SI.isAtomic() && "violated precondition");
 3773     assert(LI.isAtomic() && "violated precondition");
include/llvm/CodeGen/TargetPassConfig.h
   68     assert(!IsInstance && "Not a Pass ID");
   73     assert(IsInstance && "Not a Pass Instance");
include/llvm/CodeGen/TargetRegisterInfo.h
  339     assert(SubIdx && SubIdx < getNumSubRegIndices() &&
  349     assert(SubIdx < getNumSubRegIndices() && "This is not a subregister index");
  553     assert(Idx == 0 && "Target has no sub-registers");
  672     assert(i < getNumRegClasses() && "Register Class ID out of range");
 1031     assert(isValid() && "Cannot move iterator past end.");
 1098     assert(NumBits < 32 && "Undefined behavior spotted!");
 1124     assert(isValid() && "Cannot move iterator past end.");
include/llvm/CodeGen/ValueTypes.h
   78       assert(!IsScalable && "We don't support extended scalable types yet");
   88       assert (!EC.Scalable && "We don't support extended scalable types yet");
   97         assert (!isScalableVector() &&
  106       assert(VecTy.SimpleTy != MVT::INVALID_SIMPLE_VALUE_TYPE &&
  253       assert(isSimple() && "Expected a SimpleValueType!");
  265       assert(isVector() && "Invalid vector type!");
  273       assert(isVector() && "Invalid vector type!");
  281       assert((isVector()) && "Invalid vector type!");
  285       assert(!isScalableVector() &&
  317       assert(isInteger() && !isVector() && "Invalid integer type!");
  328       assert(isInteger() && !isVector() && "Invalid integer type!");
  353       assert(!(EltCnt.Min & 1) && "Splitting vector, but not in half!");
include/llvm/CodeGen/VirtRegMap.h
   85       assert(MF && "getMachineFunction called before runOnMachineFunction");
  103       assert(virtReg.isVirtual());
  114       assert(virtReg.isVirtual());
  115       assert(Virt2PhysMap[virtReg.id()] != NO_PHYS_REG &&
  167       assert(virtReg.isVirtual());
include/llvm/DebugInfo/CodeView/CodeViewRecordIO.h
  250       assert(CurrentOffset >= BeginOffset);
include/llvm/DebugInfo/CodeView/GlobalTypeTableBuilder.h
   88         assert(Result.first->second.getIndex() ==
include/llvm/DebugInfo/CodeView/SymbolDeserializer.h
   64     assert(!Mapping && "Already in a symbol mapping!");
   69     assert(Mapping && "Not in a symbol mapping!");
include/llvm/DebugInfo/CodeView/TypeDeserializer.h
   68     assert(!Mapping && "Already in a type mapping!");
   78     assert(Mapping && "Not in a type mapping!");
  156     assert(Mapping.Reader.getOffset() == EndOffset);
include/llvm/DebugInfo/CodeView/TypeHashing.h
   82     assert(H.size() == 8);
include/llvm/DebugInfo/CodeView/TypeIndex.h
  118     assert(!isSimple());
  127     assert(isSimple());
  132     assert(isSimple());
  205     assert(Index >= N);
  252     assert(A.getIndex() >= N);
  259     assert(A >= B);
include/llvm/DebugInfo/CodeView/TypeRecord.h
  586     assert(GuidStr.size() == 16 && "guid isn't 16 bytes");
include/llvm/DebugInfo/DIContext.h
   88     assert(Index < Frames.size());
   93     assert(Index < Frames.size());
include/llvm/DebugInfo/DWARF/DWARFAbbreviationDeclaration.h
   32       assert(isImplicitConst());
   36       assert(!isImplicitConst());
   74       assert(isImplicitConst());
  101     assert(idx < AttributeSpecs.size());
  110     assert(idx < AttributeSpecs.size());
include/llvm/DebugInfo/DWARF/DWARFAcceleratorTable.h
  536       assert(CurrentName <= CurrentIndex->getNameCount());
include/llvm/DebugInfo/DWARF/DWARFAddressRange.h
   38     assert(valid() && RHS.valid());
include/llvm/DebugInfo/DWARF/DWARFDebugRangeList.h
   53       assert(AddressSize == 4 || AddressSize == 8);
include/llvm/DebugInfo/DWARF/DWARFDie.h
   59     assert(isValid() && "must check validity prior to calling");
   67     assert(isValid() && "must check validity prior to calling");
   79     assert(isValid() && "must check validity prior to calling");
  412     assert(!AtEnd && "Incrementing rend");
  427     assert(!Die.isNULL() && "Decrementing rbegin");
  432     assert(Die.isValid());
include/llvm/DebugInfo/DWARF/DWARFExpression.h
  132     assert(AddressSize == 8 || AddressSize == 4 || AddressSize == 2);
include/llvm/DebugInfo/DWARF/DWARFListTable.h
  210   assert(*OffsetPtr == End &&
include/llvm/DebugInfo/DWARF/DWARFUnit.h
   89     assert((!DWOId || *DWOId == Id) && "setting DWOId to a different value");
  241     assert(Die >= First && Die < First + DieArray.size());
  336     assert(StringOffsetsTableContribution);
  341     assert(StringOffsetsTableContribution);
  460     assert(Index < DieArray.size());
  476     assert(!DieArray.empty());
include/llvm/DebugInfo/GSYM/LineTable.h
  162     assert(i < Lines.size());
  166     assert(i < Lines.size());
include/llvm/DebugInfo/GSYM/Range.h
   90     assert(i < Ranges.size());
include/llvm/DebugInfo/MSF/MSFCommon.h
   55     assert(SB->FreeBlockMapBlock == 1 || SB->FreeBlockMapBlock == 2);
  134   assert(FpmNumber == 1 || FpmNumber == 2);
include/llvm/DebugInfo/PDB/Native/HashTable.h
   72     assert(Map->Present.test(Index));
  246     assert(FirstUnused);
  260     assert(Iter != end());
  280       assert(isPresent(Entry.index()));
  281       assert(Traits.storageKeyToLookupKey(Buckets[Entry.index()].first) == K);
  288     assert(!isPresent(Entry.index()));
  289     assert(Entry.isEnd());
  297     assert((find_as(K, Traits)) != end());
  309     assert(capacity() != UINT32_MAX && "Can't grow Hash table!");
  326     assert(capacity() == NewCapacity);
  327     assert(size() == S);
include/llvm/Demangle/ItaniumDemangle.h
  619       assert(FirstChar == SecondChar);
  635     assert(isString());
  641     assert(isNode());
 2196   assert(0 && "unknown mangling node kind");
 2300     assert(Last != First && "Popping empty vector!");
 2305     assert(Index <= size() && "dropBack() can't expand!");
 2315     assert(Last != First && "Calling back() on empty vector!");
 2319     assert(Index < size() && "Invalid access!");
 2358       assert(Parser->TemplateParams.size() >= OldNumTemplateParamLists);
 2419     assert(FromPosition <= Names.size());
 3408   assert(SoFar != nullptr);
 5366     assert(ForwardRef->getKind() == Node::KForwardTemplateReference);
include/llvm/Demangle/MicrosoftDemangle.h
   50       assert(Head->Buf);
   59     assert(Head && Head->Buf);
   74     assert(Head && Head->Buf);
   93     assert(Head && Head->Buf);
include/llvm/Demangle/StringView.h
   75     assert(!empty());
   80     assert(!empty());
   85     assert(!empty());
include/llvm/ExecutionEngine/JITLink/JITLink.h
   79     assert(isRelocation() && "Not a relocation edge");
  109     assert(!(IsDefined && IsAbsolute) &&
  146     assert(isPowerOf2_64(Alignment) && "Alignment must be power of 2");
  147     assert(AlignmentOffset < Alignment &&
  149     assert(AlignmentOffset <= MaxAlignmentOffset &&
  160     assert(isPowerOf2_64(Alignment) && "Alignment must be power of 2");
  161     assert(AlignmentOffset < Alignment &&
  163     assert(AlignmentOffset <= MaxAlignmentOffset &&
  196     assert(Data && "Section does not contain content");
  298     assert(SymStorage && "Storage cannot be null");
  299     assert(!Name.empty() && "Common symbol name cannot be empty");
  300     assert(Base.isDefined() &&
  302     assert(static_cast<Block &>(Base).getSize() == Size &&
  311     assert(SymStorage && "Storage cannot be null");
  312     assert(!Base.isDefined() &&
  314     assert(!Name.empty() && "External symbol name cannot be empty");
  324     assert(SymStorage && "Storage cannot be null");
  325     assert(!Base.isDefined() &&
  336     assert(SymStorage && "Storage cannot be null");
  347     assert(SymStorage && "Storage cannot be null");
  348     assert(!Name.empty() && "Name cannot be empty");
  371     assert((!Name.empty() || getScope() == Scope::Local) &&
  379     assert(Base && "Attempt to access null symbol");
  386     assert(Base && "Attempting to access null symbol");
  401     assert(Base && "Attempt to access null symbol");
  407     assert(Base && "Attempt to access null symbol");
  413     assert(Base && "Cannot get underlying addressable for null symbol");
  419     assert(Base && "Cannot get underlying addressable for null symbol");
  425     assert(Base && "Cannot get block for null symbol");
  426     assert(Base->isDefined() && "Not a defined symbol");
  432     assert(Base && "Cannot get block for null symbol");
  433     assert(Base->isDefined() && "Not a defined symbol");
  461     assert((L == Linkage::Strong || (Base->isDefined() && !Name.empty())) &&
  471     assert((S == Scope::Default || Base->isDefined() || Base->isAbsolute()) &&
  478     assert(!A.isDefined() && "Attempting to make external with defined block");
  556     assert(!Symbols.count(&Sym) && "Symbol is already in this section");
  561     assert(Symbols.count(&Sym) && "symbol is not in this section");
  589     assert((!Last || First) && "First can not be null if end is non-null");
  593     assert((First || !Last) && "Last can not be null if start is non-null");
  597     assert((First || !Last) && "Last can not be null if start is non-null");
  678       assert(SymI != SecI->symbols().end() && "Dereferencing end?");
  840       assert(AbsoluteSymbols.count(&Sym) &&
  844       assert(Sym.isDefined() && "Sym is not a defined symbol");
  854     assert(!Sym.isDefined() && !Sym.isAbsolute() &&
  856     assert(ExternalSymbols.count(&Sym) && "Symbol is not in the externals set");
  865     assert(!Sym.isDefined() && Sym.isAbsolute() &&
  867     assert(AbsoluteSymbols.count(&Sym) &&
  877     assert(Sym.isDefined() && "Sym is not a defined symbol");
include/llvm/ExecutionEngine/JITLink/JITLinkMemoryManager.h
   40       assert(isPowerOf2_32(Alignment) && "Alignment must be power of 2");
include/llvm/ExecutionEngine/JITSymbol.h
   47   assert(IntPtr == Addr && "JITTargetAddress value out of range for uintptr_t");
  296     assert(!Flags.hasError() && "getAddress called on error value");
  301         assert(CachedAddr && "Symbol could not be materialized.");
include/llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h
  307     assert(!LogicalDylibs.count(K) && "VModuleKey K already in use");
  327     assert(I != LogicalDylibs.end() && "VModuleKey K not valid here");
  353     assert(LogicalDylibs.count(K) && "VModuleKey K is not valid here");
  507       assert(NewA && "Alias not cloned?");
include/llvm/ExecutionEngine/Orc/Core.h
  681       assert(static_cast<uint8_t>(State) < (1 << 6) &&
  960   assert(MU && "Can not define with a null MU");
  976   assert(MU && "Can not define with a null MU");
include/llvm/ExecutionEngine/Orc/IndirectionUtils.h
   95     assert(!AvailableTrampolines.empty() && "Failed to grow trampoline pool");
  144     assert(this->AvailableTrampolines.empty() && "Growing prematurely?");
  325     assert(StubAddr && "Missing stub address");
  341     assert(PtrAddr && "Missing pointer address");
  352     assert(I != StubIndexes.end() && "No stub pointer for symbol");
include/llvm/ExecutionEngine/Orc/LazyEmittingLayer.h
  168       assert(!MangledSymbols && "Mangled symbols map already exists?");
  206     assert(!ModuleMap.count(K) && "VModuleKey K already in use");
  248     assert(ModuleMap.count(K) && "VModuleKey K not valid here");
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h
  292         assert(!Allocs.empty() && "No sections in allocated segment");
  386       assert(I != StubIndexes.end() && "No stub pointer for symbol");
  432       assert(RemoteIndirectStubsInfos[K.first].StubBase != 0 &&
  439       assert(RemoteIndirectStubsInfos[K.first].PtrBase != 0 &&
  462       assert(!AvailableTrampolines.empty() && "Failed to grow trampoline pool");
  561     assert(!CallbackManager && "CallbackManager already obtained");
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.h
  156     assert(NextId + 1 != ~0ULL && "All ids allocated");
include/llvm/ExecutionEngine/Orc/OrcRemoteTargetServer.h
  129       assert(Allocs.find(MB.base()) == Allocs.end() && "Duplicate alloc");
  153     assert(AddrOrErr && "Compile request failed");
include/llvm/ExecutionEngine/Orc/RPCSerialization.h
  342     assert(!Name.empty() &&
  360       assert(KeyName != nullptr && "No keyname pointer");
  365         assert(EIB.dynamicClassID() == ErrorInfoT::classID() &&
  403     assert(DI != Deserializers.end() && "No deserializer for error type");
  597     assert(V.empty() &&
  630     assert(S.empty() && "Expected default-constructed set to deserialize into");
  673     assert(M.empty() && "Expected default-constructed map to deserialize into");
include/llvm/ExecutionEngine/Orc/RPCUtils.h
 1037       assert(!PendingResponses.count(SeqNo) &&
 1137     assert(IdItr != LocalFunctionIds.end() &&
 1140     assert(HandlerItr != Handlers.end() &&
 1208     assert(PRHandler &&
include/llvm/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.h
  233       assert(PFC && "mapSectionAddress called on finalized LinkedObject");
  284       assert(PFC && "mapSectionAddress called on finalized LinkedObject");
  285       assert(PFC->RTDyld && "mapSectionAddress called on raw LinkedObject");
  396     assert(!LinkedObjects.count(K) && "VModuleKey already in use");
  416     assert(LinkedObjects.count(K) && "VModuleKey not associated with object");
  445     assert(LinkedObjects.count(K) && "VModuleKey not associated with object");
  453     assert(LinkedObjects.count(K) && "VModuleKey not associated with object");
  461     assert(LinkedObjects.count(K) && "VModuleKey not associated with object");
include/llvm/ExecutionEngine/Orc/RemoteObjectLayer.h
  199       assert(!InUseSymbols.count(Id) && "Symbol id already in use");
  338       assert(!Resolvers.count(Handle) && "Handle already in use?");
  472     assert(!BaseLayerHandles.count(Id) && "Id already in use?");
include/llvm/ExecutionEngine/Orc/Speculation.h
  186     assert(!IRNames.empty() && "No IRNames received to Intern?");
include/llvm/ExecutionEngine/Orc/SymbolStringPool.h
  146   assert(Pool.empty() && "Dangling references at pool destruction time");
include/llvm/ExecutionEngine/Orc/ThreadSafeModule.h
   55     assert(S->Ctx != nullptr &&
   68     assert(S && "Can not lock an empty ThreadSafeContext");
  124       assert(TSCtx.getContext() &&
  135     assert(M && "Can not call on null module");
include/llvm/ExecutionEngine/RuntimeDyld.h
  246     assert(!Dyld && "setProcessAllSections must be called before loadObject.");
include/llvm/ExecutionEngine/RuntimeDyldChecker.h
   91       assert(Size && "setContent/setZeroFill must be called first");
   97       assert(!ContentPtr && !Size && "Content/zero-fill already set");
  104       assert(!ContentPtr && !this->Size && "Content/zero-fill already set");
  110       assert(!isZeroFill() && "Can't get content for a zero-fill section");
  116       assert(isZeroFill() && "Can't get zero-fill length for content section");
  122       assert(!this->TargetAddress && "TargetAddress already set");
include/llvm/FuzzMutate/OpDescriptor.h
  196     assert(!Cur.empty() && "No first source yet");
  200     assert(!Cur.empty() && "No first source yet");
  209     assert(!Cur.empty() && "No first source yet");
  213     assert(!Cur.empty() && "No first source yet");
include/llvm/FuzzMutate/Random.h
   45     assert(!isEmpty() && "Nothing selected");
include/llvm/IR/Argument.h
   48     assert(Parent && "can't get number of unparented arg");
include/llvm/IR/Attributes.h
  758     assert((unsigned)A < Attribute::EndAttrKinds && "Attribute out of range!");
include/llvm/IR/BasicBlock.h
  317       assert(PN && "Cannot increment the end iterator!");
  439     assert((int)(signed char)getSubclassDataFromValue() >= 0 &&
include/llvm/IR/CFG.h
   74     assert(!It.atEnd() && "pred_iterator out of range!");
   80     assert(!It.atEnd() && "pred_iterator out of range!");
  212     assert(Inst == RHS.Inst && "Cannot compare iterators of different blocks!");
  218     assert(index_is_valid(NewIdx) && "Iterator index out of bound");
include/llvm/IR/CallSite.h
   63   CallSiteBase(CallTy *CI) : I(CI, 1) { assert(CI); }
   64   CallSiteBase(InvokeTy *II) : I(II, 0) { assert(II); }
   65   CallSiteBase(CallBrTy *CBI) : I(CBI, 2) { assert(CBI); }
  105     assert(getInstruction() && "Not a call, invoke or callbr instruction!");
  131     assert(getInstruction() && "Not a call, callbr, or invoke instruction!");
  132     assert(cast<PointerType>(V->getType())->getElementType() ==
  164     assert(getInstruction() == U->getUser());
  175     assert(getInstruction() == U->getUser());
  194     assert(arg_begin() + ArgNo < arg_end() && "Argument # out of range!");
  199     assert(getInstruction() && "Not a call, invoke or callbr instruction!");
  200     assert(arg_begin() + ArgNo < arg_end() && "Argument # out of range!");
  213     assert(getInstruction() && "Not a call, invoke or callbr instruction!");
  214     assert(isArgOperand(U) && "Argument # out of range!");
  237     assert(getInstruction() && "Not a call, invoke or callbr instruction!");
  238     assert(isDataOperand(U) && "Data operand # out of range!");
  254     assert(getInstruction() && "Not a call or invoke instruction!");
  258     assert(getInstruction() && "Not a call or invoke instruction!");
  804     assert(!CI.ParameterEncoding.empty() &&
  852     assert(isCallbackCall());
  853     assert(CI.ParameterEncoding.size() && CI.ParameterEncoding[0] > 0);
  861     assert(CalleeArgIdx >= 0 &&
include/llvm/IR/Constants.h
  656     assert(isString() && "Not a string");
  663     assert(isCString() && "Isn't a C string");
include/llvm/IR/DataLayout.h
  269     assert(StackNaturalAlign && "StackNaturalAlign must be defined");
  608     assert(Idx < NumElements && "Invalid element idx!");
  625   assert(Ty->isSized() && "Cannot getTypeInfo() on a type that is unsized!");
include/llvm/IR/DebugInfoMetadata.h
  126     assert(Tag < 1u << 16);
  611     assert(isDistinct() && "Only distinct nodes can mutate");
  844     assert(getTag() == dwarf::DW_TAG_ptr_to_member_type);
  853     assert(getTag() == dwarf::DW_TAG_inheritance);
  861     assert(getTag() == dwarf::DW_TAG_member && isBitField());
  868     assert(getTag() == dwarf::DW_TAG_member && isStaticMember());
  874     assert(getTag() == dwarf::DW_TAG_member && !isStaticMember());
  909     assert(isDistinct() && "Only distinct nodes can mutate");
  910     assert(getRawIdentifier() && "Only ODR-uniqued nodes should mutate");
 1038       assert(is_contained(Elements->operands(), Op) &&
 1162     assert(Storage != Uniqued);
 1869     assert(Column < (1u << 16) && "Expected 16-bit column");
 2329     assert(I < Elements.size() && "Index out of range");
 2760     assert(Arg < (1 << 16) && "DILocalVariable: Arg out of range");
 3104     assert(MIType < 1u << 16);
 3229       assert(is_contained(Elements->operands(), Op) &&
include/llvm/IR/DerivedTypes.h
  180     assert((FnTy == nullptr) == (Callee == nullptr));
  273     assert(elt1 && "Cannot create a struct type with no elements with this");
  292     assert(elt1 && "Cannot create a struct type with no elements with this");
  329     assert(elt1 && "Cannot create a struct type with no elements with this");
  352     assert(N < NumContainedTys && "Element number out of range!");
  470     assert(EltBits && "Element size must be of a non-zero size");
  478     assert(VTy->isIntOrIntVectorTy() && "VTy expected to be a vector of ints.");
  501       assert((EltBits & 1) == 0 &&
  523     assert ((EltCnt.Min & 1) == 0 &&
  532     assert((VTy->getNumElements() * 2ull) <= UINT_MAX &&
  544     assert(MinimumEltCnt <= UINT_MAX && "Too many elements in vector");
  616   assert(
  626   assert(
include/llvm/IR/Function.h
  218     assert(!(ID & ~CallingConv::MaxID) && "Unsupported calling convention");
  719     assert (i < NumArgs && "getArg() out of range!");
include/llvm/IR/GetElementPtrTypeIterator.h
  120       assert(isBoundedSequential());
include/llvm/IR/GlobalObject.h
   94     assert(getGlobalObjectSubClassData() == Val && "representation error");
include/llvm/IR/GlobalValue.h
  168     assert(V < (1 << GlobalValueSubClassDataBits) && "It will not fit");
  243     assert((!hasLocalLinkage() || V == DefaultVisibility) &&
  255     assert(Val == NotThreadLocal || getValueID() != Value::FunctionVal);
include/llvm/IR/GlobalVariable.h
   79     assert(ptr != nullptr && "must not be nullptr");
  137     assert(hasInitializer() && "GV doesn't have initializer!");
  141     assert(hasInitializer() && "GV doesn't have initializer!");
include/llvm/IR/IRBuilder.h
  142     assert(InsertPt != BB->end() && "Can't read debug loc from end()");
  259     assert(BB && "Must have a basic block to set any function attributes!");
 1110     assert(RoundingStr.hasValue() && "Garbage strict rounding mode!");
 1126     assert(ExceptStr.hasValue() && "Garbage strict exception behavior!");
 1302     assert(!Ops.empty());
 1328     assert(!Ops.empty());
 1562       assert(Ops.size() == 2 && "Invalid number of operands!");
 1567       assert(Ops.size() == 1 && "Invalid number of operands!");
 1905     assert(V->getType()->isIntOrIntVectorTy() &&
 1920     assert(V->getType()->isIntOrIntVectorTy() &&
 2418     assert(LHS->getType() == RHS->getType() &&
 2433     assert(isa<PointerType>(Ptr->getType()) &&
 2444     assert(FnLaunderInvariantGroup->getReturnType() == Int8PtrTy &&
 2460     assert(isa<PointerType>(Ptr->getType()) &&
 2472     assert(FnStripInvariantGroup->getReturnType() == Int8PtrTy &&
 2487     assert(NumElts > 0 && "Cannot splat to an empty vector!");
 2526     assert(isa<PointerType>(Base->getType()) &&
 2555     assert(isa<PointerType>(Base->getType()) &&
 2574     assert(isa<PointerType>(Base->getType()) &&
 2643     assert(isa<PointerType>(PtrValue->getType()) &&
 2645     assert(Alignment != 0 && "Invalid Alignment");
 2670     assert(isa<PointerType>(PtrValue->getType()) &&
include/llvm/IR/InlineAsm.h
  270     assert(((NumOps << 3) & ~0xffff) == 0 && "Too many inline asm operands!");
  271     assert(Kind >= Kind_RegUse && Kind <= Kind_Mem && "Invalid Kind");
  290     assert(MatchedOperandNo <= 0x7fff && "Too big matched operand");
  291     assert((InputFlag & ~0xffff) == 0 && "High bits already contain data");
  303     assert(!isImmKind(InputFlag) && "Immediates cannot have a register class");
  304     assert(!isMemKind(InputFlag) && "Memory operand cannot have a register class");
  305     assert(RC <= 0x7fff && "Too large register class ID");
  306     assert((InputFlag & ~0xffff) == 0 && "High bits already contain data");
  313     assert(isMemKind(InputFlag) && "InputFlag is not a memory constraint!");
  314     assert(Constraint <= 0x7fff && "Too large a memory constraint ID");
  315     assert(Constraint <= Constraints_Max && "Unknown constraint ID");
  316     assert((InputFlag & ~0xffff) == 0 && "High bits already contain data");
  321     assert(isMemKind(InputFlag));
  330     assert(isMemKind(Flag));
include/llvm/IR/InstVisitor.h
  287     assert(CS);
include/llvm/IR/InstrTypes.h
 1189     assert(this == U->getUser() &&
 1206     assert(isDataOperand(U) && "Data operand # out of range!");
 1247     assert(i < getNumArgOperands() && "Out of bounds!");
 1252     assert(i < getNumArgOperands() && "Out of bounds!");
 1258     assert(i < getNumArgOperands() && "Out of bounds!");
 1262     assert(i < getNumArgOperands() && "Out of bounds!");
 1267     assert(this == U->getUser() &&
 1341     assert(FTy == cast<FunctionType>(
 1345     assert(getType() == FTy->getReturnType());
 1355     assert(!(ID & ~CallingConv::MaxID) && "Unsupported calling convention");
 1379     assert(Kind != Attribute::NoBuiltin &&
 1403     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1411     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1433     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1441     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1480     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1486     assert(ArgNo < getNumArgOperands() && "Out of bounds");
 1505     assert(i < (getNumArgOperands() + getNumTotalBundleOperands() + 1) &&
 1520     assert(hasOperandBundles() && i >= (getBundleOperandsStartIndex() + 1) &&
 1748     assert(hasOperandBundles() && "Don't call otherwise!");
 1754     assert(hasOperandBundles() && "Don't call otherwise!");
 1766     assert(this == U->getUser() &&
 1783     assert(Begin <= End && "Should be!");
 1789     assert(Index < getNumOperandBundles() && "Index out of bounds!");
 1820     assert(countOperandBundlesOfType(Name) < 2 && "Precondition violated!");
 1836     assert(countOperandBundlesOfType(ID) < 2 && "Precondition violated!");
 2171     assert(ParentPad);
include/llvm/IR/Instruction.h
  765     assert((D & HasMetadataBit) == 0 && "Out of range value put into field");
include/llvm/IR/Instructions.h
  596     assert(Ordering != AtomicOrdering::NotAtomic &&
  609     assert(Ordering != AtomicOrdering::NotAtomic &&
  803     assert(Ordering != AtomicOrdering::NotAtomic &&
  874   assert(Ty && "Invalid GetElementPtrInst indices for type!");
  916       assert(
  932       assert(
  984     assert(ResultElementType ==
 1123   assert(ResultElementType ==
 1137   assert(ResultElementType ==
 1154     assert(isIntPredicate() &&
 1156     assert(getOperand(0)->getType() == getOperand(1)->getType() &&
 1159     assert((getOperand(0)->getType()->isIntOrIntVectorTy() ||
 1296     assert(isFPPredicate() && "Invalid FCmp predicate value");
 1297     assert(getOperand(0)->getType() == getOperand(1)->getType() &&
 1300     assert(getOperand(0)->getType()->isFPOrFPVectorTy() &&
 1733     assert(!areInvalidOperands(C, S1, S2) && "Invalid operands for select");
 2070     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2091     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2128     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2152     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2172     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2222     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2244     assert(Mask->getType()->isVectorTy() && "Shuffle needs vector constant.");
 2264       assert(Idx >= 0 && Idx < (int)InVecNumElts * 2 &&
 2648     assert(V && "PHI node got a null value!");
 2649     assert(getType() == V->getType() &&
 2672     assert(this == U.getUser() && "Iterator doesn't point to PHI's Uses?");
 2684     assert(BB && "PHI node got a null basic block!");
 2690     assert(New && Old && "PHI node got a null basic block!");
 2719     assert(Idx >= 0 && "Invalid basic block argument to remove!");
 2735     assert(Idx >= 0 && "Invalid basic block argument!");
 2741     assert(BB && "PHI node got a null basic block!");
 2749     assert(Found && "Invalid basic block argument to set!");
 3057     assert(isConditional() && "Cannot get condition of an uncond branch!");
 3062     assert(isConditional() && "Cannot set condition of unconditional branch!");
 3069     assert(i < getNumSuccessors() && "Successor # out of range for Branch!");
 3074     assert(idx < getNumSuccessors() && "Successor # out of range for Branch!");
 3186       assert((unsigned)Index < SI->getNumCases() &&
 3193       assert(((unsigned)Index < SI->getNumCases() ||
 3204       assert(((unsigned)Index == DefaultPseudoIndex ||
 3211       assert(SI == RHS.SI && "Incompatible operators.");
 3228       assert((unsigned)Index < SI->getNumCases() &&
 3261       assert(SuccessorIndex < SI->getNumSuccessors() &&
 3276       assert(Case.Index + N >= 0 &&
 3285       assert(Case.Index - N >= 0 &&
 3292       assert(Case.SI == RHS.Case.SI && "Incompatible operators.");
 3446     assert(idx < getNumSuccessors() &&"Successor idx out of range for switch!");
 3450     assert(idx < getNumSuccessors() && "Successor # out of range for switch!");
 3858     assert(i < 2 && "Successor # out of range for invoke!");
 3863     assert(i < 2 && "Successor # out of range for invoke!");
 4066     assert(i < getNumIndirectDests() && "Out of bounds!");
 4072     assert(i < getNumIndirectDests() && "Out of bounds!");
 4099     assert(i < getNumSuccessors() + 1 &&
 4105     assert(i < getNumIndirectDests() + 1 &&
 4289     assert(UnwindDest);
 4290     assert(hasUnwindDest());
 4366     assert(Idx < getNumSuccessors() &&
 4371     assert(Idx < getNumSuccessors() &&
 4468     assert(CatchSwitch);
 4501     assert(CatchPad);
 4502     assert(BB);
 4508     assert(CatchPad);
 4509     assert(BB);
 4519     assert(CatchPad);
 4525     assert(NewSucc);
 4546     assert(Idx < getNumSuccessors() && "Successor # out of range for catchret!");
 4551     assert(Idx < getNumSuccessors() && "Successor # out of range for catchret!");
 4586     assert(CleanupPad);
 4596     assert(CleanupPad);
 4615     assert(CleanupPad);
 4625     assert(NewDest);
 4626     assert(hasUnwindDest());
 4640     assert(Idx == 0);
 4645     assert(Idx == 0);
 5285   assert((isa<LoadInst>(I) || isa<StoreInst>(I)) &&
 5295   assert((isa<LoadInst>(I) || isa<StoreInst>(I)) &&
include/llvm/IR/IntrinsicInst.h
  409       assert(getRawDest()->getType() == Ptr->getType() &&
  422       assert(getLength()->getType() == L->getType() &&
  458       assert(getRawSource()->getType() == Ptr->getType() &&
  514       assert(V->getType() == Type::getInt8Ty(getContext()) &&
include/llvm/IR/Intrinsics.h
  126       assert(Kind == Argument || Kind == ExtendArgument ||
  135       assert(Kind == Argument || Kind == ExtendArgument ||
  146       assert(Kind == VecOfAnyPtrsToElt);
  150       assert(Kind == VecOfAnyPtrsToElt);
include/llvm/IR/LegacyPassManagers.h
  389     assert ( 0 && "Invalid use of getPassManagerType");
  512     assert ( N < PassVector.size() && "Pass number out of range!");
include/llvm/IR/Metadata.h
  293     assert(UseMap.empty() && "Cannot destroy in-use replaceable metadata");
  352     assert(V && "Expected valid value");
  431     assert(!isa<Constant>(Local) && "Expected local value");
  531   assert(MD && "Null pointer sent into hasa");
  747     assert(static_cast<void *>(this) == &MD && "Expected same address");
  777     assert(getReplaceableUses() && "Expected non-null replaceable uses");
  819     assert(ReplaceableUses && "Expected non-null replaceable uses");
  820     assert(&ReplaceableUses->getContext() == &getContext() &&
  830     assert(hasReplaceableUses() && "Expected to own replaceable uses");
  949     assert(isTemporary() && "Expected temporary node");
 1069     assert(I < NumOperands && "Out of range");
 1313     assert(!Use && "Use is still being tracked despite being untracked!");
include/llvm/IR/ModuleSummaryIndex.h
  179     assert(haveGVs());
  194     assert(isValidAccessSpecifier());
  198     assert(isValidAccessSpecifier());
  202     assert(isValidAccessSpecifier());
  212     assert(getAccessSpecifier() == 0);
  216     assert(getAccessSpecifier() == 0);
  238   assert(A.getRef() && B.getRef() &&
  244   assert(A.getRef() && B.getRef() &&
  250   assert(A.getRef() && B.getRef() &&
  271     assert(isSpecialKey(L) || isSpecialKey(R) || (L.haveGVs() == R.haveGVs()));
  358     assert((K != AliasKind || Refs.empty()) &&
  451     assert(!!AliaseeSummary == (AliaseeValueInfo &&
  458     assert(AliaseeSummary && "Unexpected missing aliasee summary");
  467     assert(AliaseeValueInfo && "Unexpected missing aliasee");
  471     assert(AliaseeValueInfo && "Unexpected missing aliasee");
  784     assert(!VTableFuncs);
 1014     assert(F != nullptr && "Expected FunctionSummary node");
 1113     assert(!HaveGVs);
 1121     assert(HaveGVs);
 1201     assert(GV.hasName() && "Can't get GlobalValueSummary for GV with no name");
 1229     assert(It != ModulePathStringTable.end() && "Module not registered");
 1262     assert(It != ModulePathStringTable.end() && "Module not registered");
 1432   assert(isa<GlobalVarSummary>(S->getBaseObject()));
include/llvm/IR/PassManager.h
  699       assert(RI != Results.end() &&
  714       assert(Inserted && "Should not have already inserted this ID, likely "
  736     assert(AnalysisResults.empty() == AnalysisResultLists.empty() &&
  778     assert(AnalysisPasses.count(PassT::ID()) &&
  797     assert(AnalysisPasses.count(PassT::ID()) &&
  895       assert(Inserted && "Should never have already inserted this ID, likely "
  925     assert(PI != AnalysisPasses.end() &&
  933     assert(PI != AnalysisPasses.end() &&
  968       assert(RI != AnalysisResults.end() && "we just inserted it!");
include/llvm/IR/PatternMatch.h
  234         assert(NumElts != 0 && "Constant vector with no elements?");
  293         assert(NumElts != 0 && "Constant vector with no elements?");
include/llvm/IR/Statepoint.h
  108     assert(*this && "check validity first!");
  128     assert(isInt<32>(NumPatchBytes) && "should fit in 32 bits!");
  171     assert(CallArgsBeginPos <= (int)getCall()->arg_size());
  176     assert((getCall()->arg_end() - I) >= 0);
  204     assert((getCall()->arg_end() - I) >= 0);
  209     assert((getCall()->arg_end() - I) >= 0);
  227     assert((getCall()->arg_end() - I) >= 0);
  232     assert((getCall()->arg_end() - I) >= 0);
  274     assert(getNumCallArgs() >= 0 &&
  342       assert(isStatepoint(Token));
  350     assert(InvokeBB && "safepoints should have unique landingpads");
  351     assert(InvokeBB->getTerminator() &&
  353     assert(isStatepoint(InvokeBB->getTerminator()));
include/llvm/IR/TrackingMDRef.h
   94     assert(MD == X.MD && "Expected values to match");
include/llvm/IR/Type.h
  100     assert(getSubclassData() == val && "Subclass data too large for field");
  337     assert(i < NumContainedTys && "Index out of range!");
  362     assert(isSequentialType(getTypeID()) && "Not a sequential type!");
  369     assert(getTypeID() == ArrayTyID);
  377     assert(getTypeID() == VectorTyID);
  382     assert(getTypeID() == PointerTyID);
include/llvm/IR/User.h
   75     assert(NumOps < (1u << NumUserOperandsBits) && "Too many operands");
   79     assert((!HasHungOffUses || !getOperandList()) &&
  156     assert(HasHungOffUses &&
  170     assert(i < NumUserOperands && "getOperand() out of range!");
  175     assert(i < NumUserOperands && "setOperand() out of range!");
  176     assert((!isa<Constant>((const Value*)this) ||
  183     assert(i < NumUserOperands && "getOperandUse() out of range!");
  187     assert(i < NumUserOperands && "getOperandUse() out of range!");
  208     assert(NumOps <= 1 && "GlobalVariable can only have 0 or 1 operands");
  216     assert(HasHungOffUses && "Must have hung off uses to use this method");
  217     assert(NumOps < (1u << NumUserOperandsBits) && "Too many operands");
include/llvm/IR/Value.h
  141       assert(U && "Cannot increment end iterator!");
  153       assert(U && "Cannot dereference end iterator!");
  303     assert(New && "Value::replaceUsesWithIf(<null>) is invalid!");
  304     assert(New->getType() == getType() &&
  789       assert(NumSlots <= MaxSlots && "Use list bigger than 2^32");
  797   assert(Next && "Expected one more Use");
  798   assert(!Next->Next && "Expected only one Use");
include/llvm/IR/ValueHandle.h
  332     assert(InnerHandle.pointsToAliveValue() &&
  339     assert(isa<ValueTy>(InnerHandle) &&
  465     assert(!Poisoned && "Tried to delete an already poisoned handle!");
  472     assert(!Poisoned && "Tried to RAUW an already poisoned handle!");
  484     assert(!Poisoned && "Accessed a poisoned value handle!");
include/llvm/IR/ValueMap.h
  272     assert(isa<KeySansPointerT>(new_key) &&
include/llvm/MC/MCAsmMacro.h
   91     assert(Kind == String && "This token isn't a string!");
  116     assert(Kind == Integer && "This token isn't an integer!");
  121     assert((Kind == Integer || Kind == BigNum) &&
include/llvm/MC/MCAssembler.h
  328     assert((Size == 0 || !(Size & (Size - 1))) &&
include/llvm/MC/MCCodeView.h
   79     assert(column <= UINT16_MAX);
  131     assert(isInlinedCallSite());
include/llvm/MC/MCContext.h
  564       assert(I != MCDwarfLineTablesCUMap.end());
include/llvm/MC/MCDwarf.h
  126     assert(column <= UINT16_MAX);
  132     assert(flags <= UINT8_MAX);
  138     assert(isa <= UINT8_MAX);
  469     assert(Op != OpRegister);
  474     assert(Op == OpRegister);
  581     assert(Operation == OpDefCfa || Operation == OpOffset ||
  589     assert(Operation == OpRegister);
  594     assert(Operation == OpDefCfa || Operation == OpOffset ||
  601     assert(Operation == OpEscape);
include/llvm/MC/MCFixup.h
   95     assert(Kind < MaxTargetFixupKind && "Kind out of range!");
  158       assert(!IsPCRel && "Invalid pc-relative fixup size!");
include/llvm/MC/MCFragment.h
  391     assert(isPowerOf2_64(PolicyMask) &&
  396     assert(isInstructionInitialized() && "Fragment has no instruction!");
  400     assert(isInstructionInitialized() && "Fragment has no instruction!");
  403     assert(InstInfo.InstFragment != nullptr &&
include/llvm/MC/MCInst.h
   65     assert(isReg() && "This is not a register operand!");
   71     assert(isReg() && "This is not a register operand!");
   76     assert(isImm() && "This is not an immediate");
   81     assert(isImm() && "This is not an immediate");
   86     assert(isFPImm() && "This is not an FP immediate");
   91     assert(isFPImm() && "This is not an FP immediate");
   96     assert(isExpr() && "This is not an expression");
  101     assert(isExpr() && "This is not an expression");
  106     assert(isInst() && "This is not a sub-instruction");
  111     assert(isInst() && "This is not a sub-instruction");
include/llvm/MC/MCInstrDesc.h
  107     assert(isGenericType() && "non-generic types don't have an index");
  117     assert(isGenericImm() && "non-generic immediates don't have an index");
include/llvm/MC/MCInstrInfo.h
   45     assert(Opcode < NumOpcodes && "Invalid opcode!");
   51     assert(Opcode < NumOpcodes && "Invalid opcode!");
include/llvm/MC/MCLinkerOptimizationHint.h
  119     assert(isValidMCLOHType(Kind) && "Invalid LOH directive type!");
include/llvm/MC/MCParser/MCAsmLexer.h
   74     assert(!CurTok.empty());
  111     assert(ReadCount == 1);
include/llvm/MC/MCParser/MCAsmParser.h
   68     assert(isKind(IK_Invalid) && "should be initialized only once");
   73     assert(isKind(IK_Invalid) && "should be initialized only once");
   78     assert(isKind(IK_Invalid) && "should be initialized only once");
include/llvm/MC/MCParser/MCTargetAsmParser.h
  259     assert(Kind == NearMissFeature);
  265     assert(Kind == NearMissPredicate);
  270     assert(Kind == NearMissOperand || Kind == NearMissTooFewOperands);
  275     assert(Kind == NearMissOperand || Kind == NearMissTooFewOperands);
  280     assert(Kind == NearMissOperand);
  286     assert(Kind == NearMissOperand);
  463     assert(Op1.isReg() && Op2.isReg() && "Operands not all regs");
include/llvm/MC/MCRegister.h
   53     assert(!isStackSlot(Reg) && "Not a register! Check isStackSlot() first.");
include/llvm/MC/MCRegisterInfo.h
   59     assert(i < getNumRegs() && "Register number out of range!");
  204       assert(isValid() && "Cannot move off the end of the list.");
  330     assert(RegNo < NumRegs &&
  427     assert(i < getNumRegClasses() && "Register Class ID out of range");
  437     assert(RegNo < NumRegs &&
  567     assert(Reg && "Null register has no regunits");
  636     assert(RegUnit < MCRI->getNumRegUnits() && "Invalid register unit");
  653     assert(isValid() && "Cannot move off the end of the list.");
  690     assert(SI.isValid() && "Cannot dereference an invalid iterator.");
  713     assert(isValid() && "Cannot move off the end of the list.");
include/llvm/MC/MCSchedule.h
  323     assert(hasExtraProcessorInfo() &&
  340     assert(hasInstrSchedModel() && "No scheduling machine model");
  342     assert(ProcResourceIdx < NumProcResourceKinds && "bad proc resource idx");
  347     assert(hasInstrSchedModel() && "No scheduling machine model");
  349     assert(SchedClassIdx < NumSchedClasses && "bad scheduling class idx");
include/llvm/MC/MCSection.h
  115     assert(!Begin);
include/llvm/MC/MCSectionCOFF.h
   60     assert((Characteristics & 0x00F00000) == 0 &&
include/llvm/MC/MCSectionWasm.h
   83     assert(isWasmData());
   87     assert(isWasmData());
include/llvm/MC/MCSectionXCOFF.h
   47     assert((ST == XCOFF::XTY_SD || ST == XCOFF::XTY_CM) &&
include/llvm/MC/MCStreamer.h
  417     assert(Section && "Cannot switch to a null section!");
include/llvm/MC/MCSubtargetInfo.h
  171     assert(DefIdx < SC->NumWriteLatencyEntries &&
include/llvm/MC/MCSymbol.h
  183       assert(F != AbsolutePseudoFragment);
  191     assert(FragmentAndHasName.getInt() && "Name is required");
  269     assert(isInSection() && "Invalid accessor!");
  275     assert(!isVariable() && "Cannot set fragment of variable");
  303     assert(isVariable() && "Invalid accessor!");
  325     assert((SymbolContents == SymContentsUnset ||
  331     assert((SymbolContents == SymContentsUnset ||
  340     assert(isCommon() && "Not a 'common' symbol!");
  350     assert(getOffset() == 0);
  354     assert((!Align || isPowerOf2_32(Align)) &&
  357     assert(Log2Align < (1U << NumCommonAlignmentBits) &&
  364     assert(isCommon() && "Not a 'common' symbol!");
  375     assert(isCommon() || getOffset() == 0);
  423     assert(Value < (1U << NumFlagsBits) && "Out of range flags");
  429     assert(Value < (1U << NumFlagsBits) && "Out of range flags");
include/llvm/MC/MCSymbolMachO.h
  106     assert(Value == (Value & SF_DescFlagsMask) &&
  120         assert((1U << Log2Size) == Align && "Invalid 'common' alignment!");
include/llvm/MC/MCSymbolWasm.h
   96     assert(GlobalType.hasValue());
  102     assert(EventType.hasValue());
include/llvm/MC/MCSymbolXCOFF.h
   27     assert((!StorageClass.hasValue() || StorageClass.getValue() == SC) &&
   33     assert(StorageClass.hasValue() &&
   39     assert((!ContainingCsect || ContainingCsect == C) &&
   46     assert(ContainingCsect &&
include/llvm/MC/SubtargetFeature.h
  209     assert(!Feature.empty() && "Empty string");
  223     assert(!Feature.empty() && "Empty string");
include/llvm/MCA/HardwareUnits/LSUnit.h
   82     assert(!isExecuted() && "Should have been removed!");
  104     assert(!isReady() && "Unexpected group-start event!");
  115     assert(!isReady() && "Inconsistent state found!");
  121     assert(!isExecuting() && "Invalid internal state!");
  143     assert(isReady() && !isExecuted() && "Invalid internal state!");
  156     assert(!getNumSuccessors() && "Cannot add instructions to this group!");
  279     assert(isValidGroupID(Index) && "Group doesn't exist!");
  284     assert(isValidGroupID(Index) && "Group doesn't exist!");
include/llvm/MCA/HardwareUnits/ResourceManager.h
  241     assert(isSubResourceReady(ID));
  246     assert(!isSubResourceReady(ID));
  274     assert(AvailableSlots <= static_cast<unsigned>(BufferSize));
  285     assert(AvailableSlots <= static_cast<unsigned>(BufferSize));
  394     assert(ResourceID < ProcResID2Mask.size() &&
include/llvm/MCA/HardwareUnits/Scheduler.h
  270     assert(find(WaitSet, IR) == WaitSet.end() && "Already in the wait set!");
  271     assert(find(ReadySet, IR) == ReadySet.end() && "Already in the ready set!");
  272     assert(find(IssuedSet, IR) == IssuedSet.end() && "Already executing!");
include/llvm/MCA/Instruction.h
  207     assert(Users.empty() && "Write is in an inconsistent state.");
  321     assert(End >= Cycles);
  540     assert(isExecuted() && "Instruction is in an invalid state!");
  615     assert(isValid() && "Invalid null WriteState found!");
include/llvm/MCA/SourceMgr.h
   45     assert(hasNext() && "Already at end of sequence!");
include/llvm/MCA/Stages/Stage.h
   58     assert(!NextInSequence && "This stage already has a NextInSequence!");
   71     assert(checkNextStage(IR) && "Next stage is not ready!");
include/llvm/MCA/Support.h
   59     assert(Denominator && "Invalid denominator (must be non-zero).");
  100   assert(Mask && "Processor Resource Mask cannot be zero!");
include/llvm/Object/Archive.h
  105       assert(!Parent || !other.Parent || Parent == other.Parent);
include/llvm/Object/COFF.h
  195     assert(isOrdinal() && "ILT entry is not an ordinal!");
  200     assert(!isOrdinal() && "ILT entry is not a Hint/Name RVA!");
  313     assert(isSet() && "COFFSymbolRef points to nothing!");
  318     assert(isSet() && "COFFSymbolRef points to nothing!");
  323     assert(isSet() && "COFFSymbolRef points to nothing!");
  334     assert(isSet() && "COFFSymbolRef points to nothing!");
  339     assert(isSet() && "COFFSymbolRef points to nothing!");
  344     assert(isSet() && "COFFSymbolRef points to nothing!");
  882     assert(!is64());
  887     assert(is64());
include/llvm/Object/ELF.h
  218     assert(Phdr.p_type == ELF::PT_NOTE && "Phdr is not of type PT_NOTE");
  237     assert(Shdr.sh_type == ELF::SHT_NOTE && "Shdr is not of type SHT_NOTE");
  322   assert(Sym->st_shndx == ELF::SHN_XINDEX);
  628   assert(Section.sh_type == ELF::SHT_SYMTAB_SHNDX);
include/llvm/Object/ELFObjectFile.h
  101     assert(isa<ELFObjectFileBase>(SectionRef::getObject()));
  124     assert(isa<ELFObjectFileBase>(B->getObject()));
  139     assert(isa<ELFObjectFileBase>(SymbolRef::getObject()));
  191     assert(isa<ELFObjectFileBase>(RelocationRef::getObject()));
  321     assert(SymTable->sh_type == ELF::SHT_SYMTAB ||
  927   assert(getRelSection(Rel)->sh_type == ELF::SHT_REL);
  937   assert(getRelSection(Rela)->sh_type == ELF::SHT_RELA);
include/llvm/Object/ELFTypes.h
  212     assert(v < 4 && "Invalid value for visibility");
  366     assert(!isMips64EL);
  370     assert(!IsMips64EL);
  669     assert(Start && "ELF note iterator starting at NULL");
  675     assert(Nhdr && "incremented ELF note end iterator");
  692     assert(Nhdr && "dereferenced ELF note end iterator");
  735     assert(kind == ELF::ODK_REGINFO);
include/llvm/Object/IRSymtab.h
  210     assert(isCommon());
  215     assert(isCommon());
  222     assert(isWeak() && isIndirect());
include/llvm/Object/Minidump.h
  112       assert(Storage.size() % Stride == 0);
  120       assert(Storage.size() >= sizeof(minidump::MemoryInfo));
include/llvm/Object/ObjectFile.h
  176     assert(isa<ObjectFile>(BasicSymbolRef::getObject()));
  293     assert(getSymbolFlags(Symb) & SymbolRef::SF_Common);
  424   assert(OwningObject == Other.OwningObject);
include/llvm/Object/StackMapParser.h
  131       assert(getKind() == LocationKind::Constant && "Not a small constant.");
  137       assert(getKind() == LocationKind::ConstantIndex &&
  144       assert((getKind() == LocationKind::Direct ||
  308     assert(StackMapSection[0] == 3 &&
include/llvm/Object/XCOFFObjectFile.h
  285     assert(!is64Bit() && "Symbol table handling not supported yet.");
include/llvm/ObjectYAML/CodeViewYAMLTypeHashing.h
   34     assert(S.size() == 8 && "Invalid hash size!");
   37     assert(S.size() == 8 && "Invalid hash size!");
include/llvm/Option/OptTable.h
   78     assert(id > 0 && id - 1 < getNumOptions() && "Invalid Option ID.");
include/llvm/Option/Option.h
   88     assert(Info && "Must have a valid info!");
   93     assert(Info && "Must have a valid info!");
   99     assert(Info && "Must have a valid info!");
  104     assert(Info && "Must have a valid info!");
  105     assert(Owner && "Must have a valid owner!");
  110     assert(Info && "Must have a valid info!");
  111     assert(Owner && "Must have a valid owner!");
  118     assert(Info && "Must have a valid info!");
  119     assert((!Info->AliasArgs || Info->AliasArgs[0] != 0) &&
include/llvm/PassAnalysisSupport.h
  202   assert(Resolver && "Pass not resident in a PassManager object!");
  221   assert(Resolver && "Pass has not been inserted into a PassManager object!");
  227   assert(PI && "getAnalysis for unregistered pass!");
  228   assert(Resolver&&"Pass has not been inserted into a PassManager object!");
  233   assert(ResultPass &&
  249   assert(Resolver &&"Pass has not been inserted into a PassManager object!");
  256   assert(PI && "getAnalysis for unregistered pass!");
  257   assert(Resolver && "Pass has not been inserted into a PassManager object!");
  262   assert(ResultPass && "Unable to find requested analysis info");
include/llvm/PassInfo.h
   97     assert((!isAnalysisGroup() || NormalCtor) &&
   99     assert(NormalCtor &&
include/llvm/Passes/PassBuilder.h
   47     assert(this->CSAction == NoCSAction ||
   51     assert(this->CSAction != CSIRInstr || !this->CSProfileGenFile.empty());
   55     assert(this->CSAction != CSIRUse || this->Action == IRUse);
   58     assert(this->Action != NoAction || this->CSAction != NoCSAction ||
include/llvm/ProfileData/Coverage/CoverageMapping.h
   69     assert(Err != coveragemap_error::success && "Not an error");
  356     assert(Current != Records.end() && "incremented past end");
  455     assert(hasName() && "Instantiations don't have a shared name");
include/llvm/ProfileData/GCOV.h
  337     assert(&Edge->Dst == this); // up to caller to ensure edge is valid
  342     assert(&Edge->Src == this); // up to caller to ensure edge is valid
include/llvm/ProfileData/InstrProf.h
  304     assert(Err != instrprof_error::success && "Not an error");
  322       assert(Err == instrprof_error::success && "Multiple errors encountered");
  357     assert(FirstError == instrprof_error::success &&
include/llvm/ProfileData/InstrProfReader.h
  174     assert(Symtab.get());
  228     assert(Symtab.get());
  267       assert(atEnd());
  485       assert(CS_Summary && "No context sensitive profile summary");
  488       assert(Summary && "No profile summary");
  515       assert(CS_Summary && "No context sensitive summary");
  518       assert(Summary && "No profile summary");
include/llvm/ProfileData/SampleProf.h
  520       assert(false && "internal error: unknown suffix elision policy");
  535     assert(GUIDToFuncNameMap && "GUIDToFuncNameMap needs to be popluated first");
include/llvm/ProfileData/SampleProfReader.h
  249     assert(Remappings && "Remappings cannot be nullptr");
include/llvm/Support/ARMWinEH.h
  117     assert(Flag() == RuntimeFunctionFlag::RFF_Unpacked &&
  123     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  129     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  135     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  138     assert(((UnwindData & 0x00006000) || L()) && "L must be set to 1");
  142     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  148     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  154     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  160     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  166     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  169     assert(((~UnwindData & 0x00200000) || L()) &&
  171     assert(((~UnwindData & 0x00200000) || (Reg() < 7) || R()) &&
  176     assert((Flag() == RuntimeFunctionFlag::RFF_Packed ||
  381     assert(!isAArch64 && "Fragments are only supported on ARMv7 WinEH");
  404     assert(E() == 0 && "epilogue scopes are only present when the E bit is 0");
  418     assert(X() && "Exception Handler RVA is only valid if the X bit is set");
  423     assert(X() && "Exception Handler RVA is only valid if the X bit is set");
include/llvm/Support/Alignment.h
   78     assert(Value > 0 && "Value must not be 0");
   79     assert(llvm::isPowerOf2_64(Value) && "Alignment is not a power of 2");
   81     assert(ShiftValue < 64 && "Broken invariant");
  135     assert((Value == 0 || llvm::isPowerOf2_64(Value)) &&
  153   ALIGN_CHECK_ISSET(Lhs);
  186   assert(static_cast<uintptr_t>(ArithAddr + Alignment.value() - 1) >=
  209   ALIGN_CHECK_ISSET(A);
  253   ALIGN_CHECK_ISPOSITIVE(Rhs);
  257   ALIGN_CHECK_ISPOSITIVE(Rhs);
  261   ALIGN_CHECK_ISPOSITIVE(Rhs);
  265   ALIGN_CHECK_ISPOSITIVE(Rhs);
  269   ALIGN_CHECK_ISPOSITIVE(Rhs);
  273   ALIGN_CHECK_ISPOSITIVE(Rhs);
  285   ALIGN_CHECK_ISSET(Lhs);
  286   ALIGN_CHECK_ISPOSITIVE(Rhs);
  290   ALIGN_CHECK_ISSET(Lhs);
  291   ALIGN_CHECK_ISPOSITIVE(Rhs);
  295   ALIGN_CHECK_ISSET(Lhs);
  296   ALIGN_CHECK_ISPOSITIVE(Rhs);
  300   ALIGN_CHECK_ISSET(Lhs);
  301   ALIGN_CHECK_ISPOSITIVE(Rhs);
  327   ALIGN_CHECK_ISSET(Rhs);
  331   ALIGN_CHECK_ISSET(Rhs);
  335   ALIGN_CHECK_ISSET(Rhs);
  339   ALIGN_CHECK_ISSET(Rhs);
  343   ALIGN_CHECK_ISSET(Rhs);
  347   ALIGN_CHECK_ISSET(Rhs);
  353   ALIGN_CHECK_ISSET(Lhs);
  357   ALIGN_CHECK_ISSET(Lhs);
  361   ALIGN_CHECK_ISSET(Lhs);
  365   ALIGN_CHECK_ISSET(Lhs);
  369   ALIGN_CHECK_ISSET(Lhs);
  373   ALIGN_CHECK_ISSET(Lhs);
  378   assert(llvm::isPowerOf2_64(Divisor) &&
  380   assert(Lhs != 1 && "Can't halve byte alignment");
  385   assert(llvm::isPowerOf2_64(Divisor) &&
include/llvm/Support/Allocator.h
  220     assert(Adjustment + Size >= Size && "Adjustment + Size must not overflow");
  251       assert(AlignedAddr + Size <= (uintptr_t)NewSlab + PaddedSize);
  261     assert(AlignedAddr + SizeToAllocate <= (uintptr_t)End &&
  272     assert(Alignment > 0 && "0-byte alignnment is not allowed. Use 1 instead.");
  324     assert(Out && "Wrong allocator used");
  341     assert(Out % alignof(T) == 0 && "Wrong alignment information");
  469       assert(Begin == (char *)alignAddr(Begin, Align::Of<T>()));
include/llvm/Support/ArrayRecycler.h
   57     assert(Ptr && "Cannot recycle NULL pointer");
   98     assert(Bucket.empty() && "Non-empty ArrayRecycler deleted!");
include/llvm/Support/Automaton.h
  213     assert(Transcriber &&
  245     assert(Transcriber && Transcribe &&
include/llvm/Support/BinaryItemStream.h
   80       assert(Len > 0 && "no empty items");
   94     assert(Idx < Items.size() && "binary search for offset failed");
include/llvm/Support/BinaryStreamArray.h
  117     assert(Begin >= Skew);
  179       assert(Array == R.Array);
  197     assert(Array && !HasError);
  266     assert(Stream.getLength() % sizeof(T) == 0);
  280     assert(Index < size());
  284       assert(false && "Unexpected failure reading from stream");
  289     assert(isAddrAligned(Align::Of<T>(), Data.data()));
  337     assert(Array == R.Array);
  347     assert(std::ptrdiff_t(Index) >= N);
  353     assert(Array == R.Array);
  354     assert(Index >= R.Index);
include/llvm/Support/BinaryStreamReader.h
  201     assert(isAddrAligned(Align::Of<T>(), Bytes.data()) &&
include/llvm/Support/BinaryStreamRef.h
  100     assert(N <= getLength());
  106     assert(N <= getLength());
include/llvm/Support/BranchProbability.h
   92     assert(N != UnknownN && RHS.N != UnknownN &&
  100     assert(N != UnknownN && RHS.N != UnknownN &&
  108     assert(N != UnknownN && RHS.N != UnknownN &&
  115     assert(N != UnknownN &&
  122     assert(N != UnknownN && RHS.N != UnknownN &&
  129     assert(N != UnknownN &&
  131     assert(RHS > 0 && "The divider cannot be zero.");
  176     assert(N != UnknownN && RHS.N != UnknownN &&
  182     assert(N != UnknownN && RHS.N != UnknownN &&
  188     assert(N != UnknownN && RHS.N != UnknownN &&
  194     assert(N != UnknownN && RHS.N != UnknownN &&
include/llvm/Support/CFGUpdate.h
   87     assert(std::abs(NumInsertions) <= 1 && "Unbalanced operations!");
include/llvm/Support/Casting.h
   84     assert(Val && "isa<> used on a null pointer");
   91     assert(Val && "isa<> used on a null pointer");
  105     assert(Val && "isa<> used on a null pointer");
  250   assert(isa<X>(Val) && "cast<Ty>() argument of incompatible type!");
  257   assert(isa<X>(Val) && "cast<Ty>() argument of incompatible type!");
  264   assert(isa<X>(Val) && "cast<Ty>() argument of incompatible type!");
  272   assert(isa<X>(Val.get()) && "cast<Ty>() argument of incompatible type!");
  289   assert(isa<X>(Val) && "cast_or_null<Ty>() argument of incompatible type!");
  300   assert(isa<X>(Val) && "cast_or_null<Ty>() argument of incompatible type!");
  308   assert(isa<X>(Val) && "cast_or_null<Ty>() argument of incompatible type!");
include/llvm/Support/Chrono.h
  149     assert(0 && "Unrecognised duration format");
  163       assert(!unit.empty());
include/llvm/Support/CommandLine.h
  530     assert(Valid && "invalid option value");
  813     assert(findOption(Name) == Values.size() && "Option already exists!");
  823     assert(N != Values.size() && "Option not found!");
 1209     assert((MF != Grouping || O.ArgStr.size() == 1) &&
 1239     assert(Location && "cl::location(...) not specified for a command "
 1442     assert(Location != 0 && "cl::location(...) not specified for a command "
 1584     assert(optnum < this->size() && "Invalid option index");
include/llvm/Support/DebugCounter.h
  109     assert(Result != Us.Counters.end() && "Asking about a non-set counter");
include/llvm/Support/Endian.h
  120   assert(startBit < 8);
  155   assert(startBit < 8);
include/llvm/Support/Error.h
  385     assert(!Payload1->isA<ErrorList>() && !Payload2->isA<ErrorList>() &&
  462     assert(Err && "Cannot create Expected<T> from Error success value.");
  626     assert(!HasError && "Cannot get value when an error exists!");
  636     assert(HasError && "Cannot get error when a value exists!");
  641     assert(HasError && "Cannot get error when a value exists!");
  795     assert(appliesTo(*E) && "Applying incorrect handler");
  809     assert(appliesTo(*E) && "Applying incorrect handler");
  825     assert(appliesTo(*E) && "Applying incorrect handler");
  841     assert(appliesTo(*E) && "Applying incorrect handler");
 1228     assert(Err && !FileName.empty() && "Trying to log after takeError().");
 1245     assert(E && "Cannot create FileError from Error success value.");
 1246     assert(!F.isTriviallyEmpty() &&
include/llvm/Support/ErrorOr.h
  243     assert(!HasError && "Cannot get value when an error exists!");
  248     assert(!HasError && "Cannot get value when an error exists!");
  253     assert(HasError && "Cannot get error when a value exists!");
include/llvm/Support/FileSystem.h
 1408     assert(State && "Cannot pop an end iterator!");
 1409     assert(State->Level > 0 && "Cannot pop an iterator with level < 1");
include/llvm/Support/Format.h
   55     assert(BufferSize && "Invalid buffer size!");
  188   assert(Width <= 18 && "hex width must be <= 18");
  201   assert(Width <= 16 && "hex width must be <= 16");
include/llvm/Support/FormatProviders.h
   68       assert(false && "Invalid precision specifier");
   71       assert(Prec < 100 && "Precision out of range");
  147     assert(Style.empty() && "Invalid integral format style!");
  205       assert(false && "Style is not a valid integer");
  368       assert(false && "Invalid range style");
  377         assert(false && "Missing range option end delimeter!");
  384     assert(false && "Invalid range style!");
  391     assert(Style.empty() && "Unexpected text in range option string!");
include/llvm/Support/GenericDomTree.h
  118     assert(IDom && "No immediate dominator?");
  122     assert(I != IDom->Children.end() &&
  149     assert(IDom);
  159         assert(C->IDom);
  383     assert(!this->isPostDominator() &&
  439     assert(this->Roots.size() == 1 && "Should always have entry node!");
  446     assert(A && B && "Pointers are not valid");
  447     assert(A->getParent() == B->getParent() &&
  534     assert(From);
  535     assert(To);
  536     assert(From->getParent() == Parent);
  537     assert(To->getParent() == Parent);
  552     assert(From);
  553     assert(To);
  554     assert(From->getParent() == Parent);
  555     assert(To->getParent() == Parent);
  569     assert(getNode(BB) == nullptr && "Block already in dominator tree!");
  571     assert(IDomNode && "Not immediate dominator specified for block!");
  583     assert(getNode(BB) == nullptr && "Block already in dominator tree!");
  584     assert(!this->isPostDominator() &&
  592       assert(Roots.size() == 1);
  608     assert(N && NewIDom && "Cannot change null node pointers!");
  622     assert(Node && "Removing node that isn't in dominator tree.");
  623     assert(Node->getChildren().empty() && "Node is not a leaf node.");
  631       assert(I != IDom->Children.end() &&
  694     assert((!Parent || ThisRoot) && "Empty constructed DomTree");
  775     assert(std::distance(GraphT::child_begin(NewBB),
  784     assert(!PredBlocks.empty() && "No predblocks?");
  829     assert(A != B);
  830     assert(isReachableFromEntry(B));
  831     assert(isReachableFromEntry(A));
include/llvm/Support/GenericDomTreeConstruction.h
  149           assert(llvm::find(Res, Child) != Res.end()
  157           assert(llvm::find(Res, Child) == Res.end() &&
  183     assert(IDom || DT.DomTreeNodes[nullptr]);
  221     assert(V);
  280     assert(Stack.empty());
  357     assert(IsPostDom && "Only postdominators have a virtual root");
  358     assert(NumToNode.size() == 1 && "SNCAInfo must be freshly constructed");
  371     assert(N && "N must be a valid node");
  376     assert(DT.Parent && "Parent not set");
  384     assert(DT.Parent && "Parent pointer is not set");
  488     assert((Total + 1 == Num) && "Everything should have been visited");
  512     assert(IsPostDom && "This function is for postdominators only");
  552       assert(DT.Roots.size() == 1 && "Dominators should have a singe root");
  623       assert(TN);
  651     assert((From || IsPostDom) &&
  653     assert(To && "Cannot be a nullptr");
  685     assert(IsPostDom && "This function is only for postdominators");
  716     assert(IsPostDom && "This function is only for postdominators");
  753     assert(NCDBlock || DT.isPostDominator());
  755     assert(NCD);
  787       assert(TN->getBlock() && II.Visited.count(TN) && "Preconditions!");
  801           assert(SuccTN &&
  860       assert(TN->getLevel() == TN->getIDom()->getLevel() + 1 &&
  898     assert(!DT.getNode(Root) && "Root must not be reachable");
  920     assert(From && To && "Cannot disconnect nullptrs");
  933     assert(!IsSuccessor(To, From) && "Deleted edge still exists in the CFG!");
  982     assert(ToIDom || DT.isPostDominator());
  984     assert(ToIDomTN);
 1041     assert(ToTN);
 1042     assert(ToTN->getBlock());
 1063       assert(TN);
 1083       assert(NCDBlock || DT.isPostDominator());
 1085       assert(NCD);
 1117     assert(PrevIDom);
 1137     assert(TN);
 1138     assert(TN->getNumChildren() == 0 && "Not a tree leaf");
 1141     assert(IDom);
 1144     assert(ChIt != IDom->Children.end());
 1224     assert(!BUI.Updates.empty() && "No updates to apply!");
 1238     assert(FS.back().getPointer() == CurrentUpdate.getTo() &&
 1244     assert(FP.back().getPointer() == CurrentUpdate.getFrom() &&
 1420         assert(FirstCh);
include/llvm/Support/JSON.h
  310       assert(false && "Invalid UTF-8 in value used as JSON");
  322       assert(false && "Invalid UTF-8 in value used as JSON");
  495       assert(false && "Invalid UTF-8 in value used as JSON");
  502       assert(false && "Invalid UTF-8 in value used as JSON");
  657     assert(*this && "Must check this is an object before calling map()");
  666     assert(*this && "Must check this is an object before calling map()");
  760     assert(Stack.size() == 1 && "Unmatched begin()/end()");
  761     assert(Stack.back().Ctx == Singleton);
  762     assert(Stack.back().HasValue && "Did not write top-level value");
include/llvm/Support/KnownBits.h
   40     assert(Zero.getBitWidth() == One.getBitWidth() &&
   50     assert(!hasConflict() && "KnownBits conflict!");
   57     assert(isConstant() && "Can only get value when all bits are known");
   72     assert(!hasConflict() && "KnownBits conflict!");
   78     assert(!hasConflict() && "KnownBits conflict!");
include/llvm/Support/LowLevelTypeImpl.h
   43     assert(SizeInBits > 0 && "invalid scalar size");
   50     assert(SizeInBits > 0 && "invalid pointer size");
   58     assert(NumElements > 1 && "invalid number of vector elements");
   59     assert(ScalarSizeInBits > 0 && "invalid vector element size");
   66     assert(NumElements > 1 && "invalid number of vector elements");
   67     assert(!ScalarTy.isVector() && "invalid vector element type");
  100     assert(IsVector && "cannot get number of elements on scalar/aggregate");
  134     assert(!getScalarType().isPointer() &&
  141     assert(RawData != 0 && "Invalid Type");
  156     assert(RawData != 0 && "Invalid Type");
  157     assert(IsPointer && "cannot get address space of non-pointer type");
  166     assert(isVector() && "cannot get element type of scalar/aggregate");
  236     assert(Val <= Mask && "Value too large for field");
  257       assert(NumElements > 1 && "invalid number of vector elements");
include/llvm/Support/MachineValueType.h
  398       assert(!(EltCnt.Min & 1) && "Splitting vector, but not in half!");
 1093         assert((int)VT <= MVT::MAX_ALLOWED_VALUETYPE &&
include/llvm/Support/MathExtras.h
  251   assert(N <= Bits && "Invalid bit index");
  403   assert(N > 0 && N <= 64 && "integer width out of range");
  414   assert(N > 0 && N <= 64 && "integer width out of range");
  421   assert(N > 0 && N <= 64 && "integer width out of range");
  718   assert(Align != 0u && "Align can't be 0.");
  738   assert(Align != 0u && "Align can't be 0.");
  754   assert(B > 0 && "Bit width can't be 0.");
  755   assert(B <= 32 && "Bit width out of range.");
  770   assert(B > 0 && "Bit width can't be 0.");
  771   assert(B <= 64 && "Bit width out of range.");
include/llvm/Support/Mutex.h
   54           assert(acquired && "Lock not acquired before release!");
include/llvm/Support/OnDiskHashTable.h
  179       assert(B.Off && "Cannot write a bucket at offset 0. Please add padding.");
  183       assert(B.Length != 0 && "Bucket has a head but zero length?");
  201         assert(offset_type(DataStart - KeyStart) == Len.first &&
  203         assert(offset_type(End - DataStart) == Len.second &&
  295     assert((reinterpret_cast<uintptr_t>(Buckets) & 0x3) == 0 &&
  304     assert((reinterpret_cast<uintptr_t>(Buckets) & 0x3) == 0 &&
  419     assert(Buckets > Base);
  478       assert(NumItemsInBucketLeft);
  480       assert(NumEntriesLeft);
  605     assert(Buckets > Base);
include/llvm/Support/RWMutex.h
  130     assert(readers > 0 && "Reader lock not acquired before release!");
  143     assert(writers == 0 && "Writer lock already acquired!");
  156     assert(writers == 1 && "Writer lock not acquired before release!");
include/llvm/Support/Recycler.h
   61     assert(!FreeList && "Non-empty recycler deleted!");
include/llvm/Support/SMLoc.h
   55     assert(Start.isValid() == End.isValid() &&
include/llvm/Support/SMTAPI.h
   43     assert(isBitvectorSort() && "Not a bitvector sort!");
   45     assert(Size && "Size is zero!");
   52     assert(isFloatSort() && "Not a floating-point sort!");
   54     assert(Size && "Size is zero!");
include/llvm/Support/ScaledNumber.h
  203   assert(LocalFloor >= 1);
  308   assert(ShiftL < getWidth<DigitsT>() && "can't shift more than width");
  322   assert(LScale == RScale && "scales should match");
  338   assert(LScale < INT16_MAX && "scale too large");
  339   assert(RScale < INT16_MAX && "scale too large");
  701     assert(Shift >= ScaledNumbers::MinScale && "Shift should be close to 0");
  702     assert(Shift <= ScaledNumbers::MaxScale - 64 &&
  789     assert(size_t(Scale) < sizeof(IntT) * 8);
  793     assert(size_t(-Scale) < sizeof(IntT) * 8);
  836   assert(Shift != INT32_MIN);
  866   assert(Shift != INT32_MIN);
include/llvm/Support/SourceMgr.h
  128     assert(isValidBufferID(i));
  133     assert(isValidBufferID(i));
  142     assert(getNumBuffers());
  147     assert(isValidBufferID(i));
  238     assert(Loc.isValid());
  244     assert(R.isValid());
include/llvm/Support/StringPool.h
  116       assert(*this && "Attempt to dereference empty PooledStringPtr!");
  121       assert(*this && "Attempt to dereference empty PooledStringPtr!");
  126       assert(*this && "Attempt to dereference empty PooledStringPtr!");
include/llvm/Support/TargetRegistry.h
  482       assert(T.isOSWindows() && "only Windows COFF is supported");
  620       assert(Current && "Cannot increment end iterator!");
  631       assert(Current && "Cannot dereference end iterator!");
include/llvm/Support/TaskQueue.h
   74     assert(Tasks.empty());
include/llvm/Support/Timer.h
   95     assert(!RHS.TG && "Can only copy uninitialized timers");
   98     assert(!TG && !T.TG && "Can only assign uninit timers");
include/llvm/Support/TrailingObjects.h
  377       assert(p && "FixedSizeStorageOwner owns null?");
include/llvm/Support/TypeName.h
   33   assert(!Name.empty() && "Unable to find the template parameter!");
   36   assert(Name.endswith("]") && "Name doesn't end in the substitution key!");
include/llvm/Support/TypeSize.h
   89     assert(LHS.IsScalable == RHS.IsScalable &&
  125     assert(!IsScalable && "Request for a fixed size on a scalable object");
  194   assert(Align != 0u && "Align must be non-zero");
include/llvm/Support/UnicodeCharRanges.h
   58     assert(rangesAreValid());
include/llvm/Support/VirtualFileSystem.h
  164     assert(Impl.get() != nullptr && "requires non-null implementation");
  174     assert(Impl && "attempting to increment past end");
  235     assert(!State->Stack.empty() &&
include/llvm/Support/YAMLParser.h
  330     assert(Base && Base->CurrentEntry && "Attempted to access end iterator!");
  335     assert(Base && Base->CurrentEntry &&
  341     assert(Base && Base->CurrentEntry && "Attempted to access end iterator!");
  354       assert((Base->CurrentEntry == Other.Base->CurrentEntry)
  366     assert(Base && "Attempted to advance iterator past end!");
  381   assert(C.IsAtBeginning && "You may only iterate over a collection once!");
  390   assert((C.IsAtBeginning || C.IsAtEnd) && "Cannot skip mid parse!");
  595     assert(Doc && "incrementing iterator past the end.");
include/llvm/Support/YAMLTraits.h
  621   assert(State == FoundExponent && "Should have found exponent at this point.");
  905     assert(DefaultValue.hasValue() == false &&
 1062       assert(Err.empty() && "invalid struct trying to be written as yaml");
 1859     assert(PolymorphicTraits<T>::getKind(Val) != NodeKind::Scalar && "plain scalar documents are not supported");
include/llvm/Support/raw_ostream.h
  372       assert(Size + Offset <= Pos && "We don't support extending the stream");
include/llvm/TableGen/Record.h
  503     assert(Bit < 1 && "Bit index out of range!");
  558     assert(Bit < NumBits && "Bit index out of range!");
  687     assert(i < NumValues && "List element index out of range!");
  776     assert(Operands.size() == 1 &&
  784     assert(i == 0 && "Invalid operand id for unary operator");
  831     assert(Operands.size() == 2 &&
  886     assert(Operands.size() == 3 &&
  954     assert(Num < NumConds && "Condition number out of range!");
  959     assert(Num < NumConds && "Val number out of range!");
 1111     assert(T->getType() &&
 1135     assert(B < 1 && "Bit index out of range!");
 1150     assert(T->getType() && isa<ListRecTy>(T->getType()) &&
 1240     assert(i < NumArgs && "Argument index out of range!");
 1344     assert(Num < NumArgs && "Arg number out of range!");
 1349     assert(Num < NumArgNames && "Arg number out of range!");
 1541     assert(!isTemplateArg(Name) && "Template arg already defined!");
 1546     assert(getValue(RV.getNameInit()) == nullptr && "Value already added!");
 1583     assert(!TheInit && "changing type of record after it has been referenced");
 1584     assert(!isSubClassOf(R) && "Already subclassing record!");
 1728     assert(Ins && "Class already exists");
 1735     assert(Ins && "Record already exists");
 1741     assert(!getDef(Name));
 1742     assert(Ins && "Global already exists");
 1813       assert (i < Parts.size() && "Invalid idx!");
 1824     assert (LHSNumParts && RHSNumParts && "Expected at least one part!");
 1834       assert (LHSPart.first == false && RHSPart.first == false &&
 1843       assert (LHSPart.first == true && RHSPart.first == true &&
 1851       assert(!LHSFailed && "Unable to convert LHS to integer.");
 1853       assert(!RHSFailed && "Unable to convert RHS to integer.");
include/llvm/TableGen/StringToOffsetTable.h
   64       assert(i + 1 < AggregateString.size() && "Incomplete escape sequence!");
   66         assert(isdigit(AggregateString[i + 2]) &&
   84     assert(AggregateString.find(')') == std::string::npos &&
include/llvm/Transforms/IPO/Attributor.h
  240     assert(IRP.getAssociatedFunction());
  258     assert(KindOrArgNo != IRP_INVALID &&
  273     assert(KindOrArgNo != IRP_INVALID &&
  363     assert(KindOrArgNo != IRP_INVALID &&
  367     assert(isa<CallBase>(AnchorVal) && "Expected a call base!");
  402       assert(((isa<Argument>(getAnchorValue()) &&
  411     assert(KindOrArgNo < 0 &&
  790     assert(!KindToAbstractAttributeMap.count(&AAType::ID) &&
  823     assert(F.hasLocalLinkage() &&
  957     assert((QueryingAA || !TrackDependence) &&
include/llvm/Transforms/IPO/WholeProgramDevirt.h
   56     assert(Pos % 8 == 0);
   60       assert(!DataUsed.second[I]);
   68     assert(Pos % 8 == 0);
   72       assert(!DataUsed.second[Size - I - 1]);
   82     assert(!(*DataUsed.second & (1 << Pos % 8)));
  170     assert(Pos >= 8 * minBeforeBytes());
  176     assert(Pos >= 8 * minAfterBytes());
  184     assert(Pos >= 8 * minBeforeBytes());
  193     assert(Pos >= 8 * minAfterBytes());
  229     assert(!(ExportSummary && ImportSummary));
include/llvm/Transforms/InstCombine/InstCombineWorklist.h
   56     assert(Worklist.empty() && "Worklist must be empty to add initial group");
   98     assert(WorklistMap.empty() && "Worklist empty, but map not?");
include/llvm/Transforms/Instrumentation.h
  200   assert(Scaled <= std::numeric_limits<uint32_t>::max() && "overflow 32-bits");
include/llvm/Transforms/Scalar/GVNExpression.h
  168     assert(Operands && "Operands not allocated");
  169     assert(N < NumOperands && "Operand out of range");
  174     assert(Operands && "Operands not allocated before setting");
  175     assert(N < NumOperands && "Operand out of range");
  196     assert(NumOperands < MaxOperands && "Tried to add too many operands");
  197     assert(Operands && "Operandss not allocated before pushing");
  203     assert(!Operands && "Operands already allocated");
  445     assert(NumIntOperands < MaxIntOperands &&
  447     assert(IntOperands && "Operands not allocated before pushing");
  452     assert(!IntOperands && "Operands already allocated");
include/llvm/Transforms/Scalar/LoopPassManager.h
  122     assert(PreOrderLoops.empty() && "Must start with an empty preorder walk.");
  123     assert(PreOrderWorklist.empty() &&
  168     assert((&L == CurrentL || CurrentL->contains(&L)) &&
  188       assert(NewL->getParentLoop() == CurrentL && "All of the new loops must "
  209       assert(NewL->getParentLoop() == ParentL &&
  348       assert(L->isRecursivelyLCSSAForm(LAR.DT, LI) &&
include/llvm/Transforms/Utils/BasicBlockUtils.h
  207     assert(i != TI->getNumSuccessors() && "Edge doesn't exist!");
include/llvm/Transforms/Utils/Evaluator.h
   68     assert(R && "Reference to an uncomputed value!");
include/llvm/Transforms/Utils/SizeOpts.h
   38   assert(F);
   57   assert(BB);
lib/Analysis/AliasAnalysis.cpp
  714   assert(I1.getParent() == I2.getParent() &&
lib/Analysis/AliasSetTracker.cpp
   53   assert(!AS.Forward && "Alias set is already forwarding!");
   54   assert(!Forward && "This set is a forwarding set!!");
  107     assert(*AS.PtrListEnd == nullptr && "End of list is not null?");
  126     assert(AliasSets.empty() && "Tracker not empty");
  131   assert(RefCount == 0 && "Cannot remove non-dead alias set from tracker!");
  138   assert(!Entry.hasAliasSet() && "Entry already in set!");
  152         assert(Result != NoAlias && "Cannot be part of must set!");
  162   assert(*PtrListEnd == nullptr && "End of list is not null?");
  165   assert(*PtrListEnd == nullptr && "End of list is not null?");
  205     assert(UnknownInsts.empty() && "Illegal must alias set!");
  210     assert(SomePtr && "Empty must-alias set??");
  242   assert(Inst->mayReadOrWriteMemory() &&
  275     assert(!Addr->user_empty() &&
  368       assert(Entry.getAliasSet(*this) == AliasAnyAS &&
  521   assert(&AA == &AST.AA &&
  545   assert(MSSA && L && "MSSA and L must be available");
  591   assert(I->second->hasAliasSet() && "Dead entry?");
  605   assert(!AliasAnyAS && (TotalMayAliasSetSize > SaturationThreshold) &&
  718   assert(AST && "ASTCallbackVH called with a null AliasSetTracker!");
lib/Analysis/AssumptionCache.cpp
  171   assert(!Scanned && "Tried to scan the function twice!");
  172   assert(AssumeHandles.empty() && "Already have assumes when scanning!");
  190   assert(match(CI, m_Intrinsic<Intrinsic::assume>()) &&
  201   assert(CI->getParent() &&
  203   assert(&F == CI->getParent()->getParent() &&
  214     assert(&F == cast<Instruction>(VH)->getParent()->getParent() &&
  216     assert(match(cast<CallInst>(VH), m_Intrinsic<Intrinsic::assume>()) &&
  218     assert(AssumptionSet.insert(VH).second &&
  260   assert(IP.second && "Scanning function already in the map?");
lib/Analysis/BasicAliasAnalysis.cpp
  281   assert(V->getType()->isIntegerTy() && "Not an integer value");
  297     assert(Scale == 0 && "Constant values don't have a scale");
  436   assert(PointerSize <= Offset.getBitWidth() && "Invalid PointerSize!");
  655   assert(Visited.empty() && "Visited must be cleared after use!");
  842   assert(notDifferentParent(LocA.Ptr, LocB.Ptr) &&
  872   assert(notDifferentParent(Call, Loc.Ptr) &&
 1088   assert(GEP1->getPointerOperand()->stripPointerCastsAndInvariantGroups() ==
 1131   assert(GEP1->getNumIndices() > 1 && "Not enough GEP indices to examine");
 1327   assert(DecompGEP1.Base == UnderlyingV1 && DecompGEP2.Base == UnderlyingV2 &&
 1374       assert(BaseAlias == NoAlias || BaseAlias == MayAlias);
 1420       assert(R == NoAlias || R == MayAlias);
 1611         assert((CacheIt != AAQI.AliasCache.end()) &&
 1631         assert(!Pair.second && "Entry must have existed");
 1847       assert(!ItInsPair.second && "Entry must have existed");
 1864       assert(!Pair.second && "Entry must have existed");
 1880       assert(!Pair.second && "Entry must have existed");
 1892       assert(!Pair.second && "Entry must have existed");
 1901   assert(!Pair.second && "Entry must have existed");
lib/Analysis/BlockFrequencyInfo.cpp
  222   assert(BFI && "Expected analysis to be available");
  227   assert(BFI && "Expected analysis to be available");
  234   assert(BFI && "Expected analysis to be available");
lib/Analysis/BlockFrequencyInfoImpl.cpp
   54   assert(N < 16);
  113   assert(Weight && "invalid weight");
  114   assert(Weight <= RemWeight);
  125   assert(Amount && "invalid weight of 0");
  130   assert(!(DidOverflow && IsOverflow) && "unexpected repeated overflow");
  141   assert(OtherW.TargetNode.isValid());
  146   assert(W.Type == OtherW.Type);
  147   assert(W.TargetNode == OtherW.TargetNode);
  148   assert(OtherW.Amount && "Expected non-zero weight");
  207   assert(Shift >= 0);
  208   assert(Shift < 64);
  244     assert(Total == std::accumulate(Weights.begin(), Weights.end(), UINT64_C(0),
  260     assert(W.TargetNode.isValid());
  262     assert(W.Amount <= UINT32_MAX);
  267   assert(Total <= UINT32_MAX);
  332       assert((!OuterLoop || !OuterLoop->isIrreducible()) &&
  343     assert(OuterLoop && OuterLoop->isIrreducible() && !isLoopHeader(Resolved) &&
  444     assert(OuterLoop && "backedge or exit outside of loop");
  454     assert(W.Type == Weight::Exit);
  600   assert(Node.isValid() && "Expected valid node");
  601   assert(Node.Index < Freqs.size() && "Expected legal index");
  708   assert(Headers.size() >= 2 &&
  777   assert((OuterLoop == nullptr) == (Insert == Loops.begin()));
  806   assert(Loop.isIrreducible() && "this only makes sense on irreducible loops");
  836     assert(W.Type == Weight::Local && "all weights should be local");
  847     assert(W.Type == Weight::Local && "all weights should be local");
lib/Analysis/BranchProbabilityInfo.cpp
  175   assert(!PostDominatedByColdCall.count(BB));
  213   assert(TI->getNumSuccessors() > 1 && "expected more than one successor!");
  214   assert(!isa<InvokeInst>(TI) &&
  256   assert(TI->getNumSuccessors() > 1 && "expected more than one successor!");
  265   assert(TI->getNumSuccessors() < UINT32_MAX && "Too many successors");
  285     assert(Weight->getValue().getActiveBits() <= 32 &&
  294   assert(Weights.size() == TI->getNumSuccessors() && "Checked above");
  308   assert(WeightSum <= UINT32_MAX &&
  359   assert(TI->getNumSuccessors() > 1 && "expected more than one successor!");
  360   assert(!isa<InvokeInst>(TI) &&
  415   assert(CI->getOperand(1)->getType()->isPointerTy());
  444   assert(getSCCNum(BB, SccI) == SccNum);
  840   assert(LastF && "Cannot print prior to running over a function");
  954   assert(PostDominatedByUnreachable.empty());
  955   assert(PostDominatedByColdCall.empty());
lib/Analysis/CFG.cpp
   79     assert(i != e && "Didn't find edge?");
   90   assert(SuccNum < TI->getNumSuccessors() && "Illegal edge specification!");
   96   assert(TI->isTerminator() && "Must be a terminator to have successors!");
   99   assert(find(predecessors(Dest), TI->getParent()) != pred_end(Dest) &&
  105   assert(I != E && "No preds, but we have an edge to the block?");
  208   assert(A->getParent() == B->getParent() &&
  222   assert(A->getParent()->getParent() == B->getParent()->getParent() &&
lib/Analysis/CFLAndersAliasAnalysis.cpp
  172     assert(From != To);
  212     assert(LHS.DerefLevel > 0 && RHS.DerefLevel > 0);
  511   assert(V != nullptr);
  522   assert(LHS && RHS);
  611     assert(ValueInfo.getNumLevels() > 0);
  643   assert(NodeInfo != nullptr);
  814   assert(InsertPair.second &&
  833     assert(Iter != Cache.end());
  834     assert(Iter->second.hasValue());
  867     assert(!parentFunctionOfValue(ValB) || parentFunctionOfValue(ValB) == Fn);
  870   assert(Fn != nullptr);
lib/Analysis/CFLGraph.h
   86       assert(Level < Levels.size());
   90       assert(Level < Levels.size());
  113     assert(N.Val != nullptr);
  122     assert(Info != nullptr);
  128     assert(FromInfo != nullptr);
  130     assert(ToInfo != nullptr);
  145     assert(Info != nullptr);
  205       assert(Val != nullptr && Val->getType()->isPointerTy());
  220       assert(From != nullptr && To != nullptr);
  232       assert(From != nullptr && To != nullptr);
  377       assert(Fns.size() > 0);
  387         assert(Fn->arg_size() <= Call.arg_size());
  394         assert(Summary != nullptr);
lib/Analysis/CFLSteensAliasAnalysis.cpp
  164     assert(RetVal != nullptr);
  165     assert(RetVal->getType()->isPointerTy());
  196     assert(ValueInfo.getNumLevels() > 0);
  229   assert(InsertPair.second &&
  251     assert(Iter != Cache.end());
  252     assert(Iter->second.hasValue());
  287     assert((!MaybeFnB || MaybeFnB == MaybeFnA) &&
  293   assert(Fn != nullptr);
  295   assert(MaybeInfo.hasValue());
lib/Analysis/CGSCCPassManager.cpp
   96     assert(C->begin() != C->end() && "Cannot have an empty SCC!");
  229   assert(FAMProxy && "The CGSCC pass manager requires that the FAM module "
  383   assert(C != &*NewSCCRange.begin() &&
  386   assert(G.lookupSCC(N) == C && "Failed to update current SCC!");
  410     assert(C != &NewC && "No need to re-visit the current SCC!");
  411     assert(OldC != &NewC && "Already handled the original SCC!");
  461           assert(E && "No function transformations should introduce *new* "
  466           assert(Inserted && "We should never visit a function twice.");
  483     assert(E && "No function transformations should introduce *new* ref "
  488     assert(Inserted && "We should never visit a function twice.");
  556     assert(G.lookupSCC(N) == C && "Changed the SCC when splitting RefSCCs!");
  558     assert(G.lookupRefSCC(N) == RC && "Failed to update current RefSCC!");
  563     assert(NewRefSCCs.front() == RC &&
  567       assert(NewRC != RC && "Should not encounter the current RefSCC further "
  585       assert(RC->isAncestorOf(TargetRC) &&
  614       assert(RC->isAncestorOf(TargetRC) &&
  633             assert(MergedC != &TargetC && "Cannot merge away the target SCC!");
  655       assert(G.lookupSCC(N) == C && "Failed to update current SCC!");
  697   assert(!UR.InvalidatedSCCs.count(C) && "Invalidated the current SCC!");
  698   assert(!UR.InvalidatedRefSCCs.count(RC) && "Invalidated the current RefSCC!");
  699   assert(&C->getOuterRefSCC() == RC && "Current SCC not in current RefSCC!");
lib/Analysis/CallGraph.cpp
  121   assert(CGN->empty() && "Cannot remove function from call "
  135   assert(FunctionMap.count(From) && "No CallGraphNode for function!");
  136   assert(!FunctionMap.count(To) &&
  152   assert((!F || F->getParent() == &M) && "Function not in current module!");
  188     assert(I != CalledFunctions.end() && "Cannot find callsite to remove!");
  215     assert(I != CalledFunctions.end() && "Cannot find callee to remove!");
  232     assert(I != CalledFunctions.end() && "Cannot find callsite to remove!");
lib/Analysis/CallGraphSCCPass.cpp
   95     assert(N < PassVector.size() && "Pass number out of range!");
  166   assert(PM->getPassManagerType() == PMT_FunctionPassManager &&
  247         assert(!CheckingMode &&
  270       assert(!Calls.count(I->first) &&
  318           assert(!CheckingMode &&
  343         assert(!CheckingMode &&
  378     assert(Calls.empty() && "Dangling pointers found in call sites map");
  516       assert(PM->getPassManagerType() == PMT_FunctionPassManager &&
  531       assert(PM->getPassManagerType() == PMT_FunctionPassManager &&
  548   assert(Old != New && "Should not replace node with self");
  550     assert(i != Nodes.size() && "Node not in SCC");
  574   assert(!PMS.empty() && "Unable to handle Call Graph Pass");
  581     assert(!PMS.empty() && "Unable to create Call Graph Pass Manager");
lib/Analysis/CaptureTracking.cpp
  177   assert(!isa<GlobalValue>(V) &&
  206   assert(!isa<GlobalValue>(V) &&
  229   assert(V->getType()->isPointerTy() && "Capture is for pointers only!");
lib/Analysis/CodeMetrics.cpp
   54     assert(Visited.count(V) &&
  104     assert(I->getParent()->getParent() == F &&
lib/Analysis/ConstantFolding.cpp
   96   assert(CastInst::castIsValid(Instruction::BitCast, C, DestTy) &&
  380   assert(ByteOffset <= DL.getTypeAllocSize(C->getType()) &&
  477       assert(BytesWritten <= EltSize && "Not indexing into this element?");
  803   assert(Ptr->getType()->isPointerTy() && "Not a pointer type");
  851           assert((!CE || CE->getType() == IntPtrTy) &&
  999   assert(C->getType()->getPointerElementType() == Ty &&
 1112   assert(isa<ConstantVector>(C));
 1291   assert(Instruction::isUnaryOp(Opcode));
 1299   assert(Instruction::isBinaryOp(Opcode));
 1309   assert(Instruction::isCast(Opcode));
 1628   assert(ResultWidth <= 64 &&
 1690   assert(Operands.size() == 1 && "Wrong number of operands.");
 1981       assert(status == APFloat::opOK && !lost &&
 2029   assert(Operands.size() == 2 && "Wrong number of operands.");
 2205       assert(C1 && "Must be constant int");
 2282   assert(Operands.size() == 3 && "Wrong number of operands.");
 2318           assert(Scale < Width && "Illegal scale.");
lib/Analysis/DDG.cpp
   30   assert(IList.empty() && "Expected the IList to be empty on entry.");
   81   assert(InstList.empty() && "Expected empty list.");
   87   assert(((getKind() == NodeKind::SingleInstruction && InstList.size() == 1) ||
   94   assert(((getKind() == NodeKind::SingleInstruction && InstList.size() == 1) ||
  171   assert(!Root && "Root node is already added. No more nodes can be added.");
lib/Analysis/DependenceAnalysis.cpp
  264   assert(0 < Level && Level <= Levels && "Level out of range");
  271   assert(0 < Level && Level <= Levels && "Level out of range");
  280   assert(0 < Level && Level <= Levels && "Level out of range");
  288   assert(0 < Level && Level <= Levels && "Level out of range");
  296   assert(0 < Level && Level <= Levels && "Level out of range");
  303   assert(0 < Level && Level <= Levels && "Level out of range");
  314   assert(Kind == Point && "Kind should be Point");
  322   assert(Kind == Point && "Kind should be Point");
  330   assert((Kind == Line || Kind == Distance) &&
  339   assert((Kind == Line || Kind == Distance) &&
  348   assert((Kind == Line || Kind == Distance) &&
  357   assert(Kind == Distance && "Kind should be Distance");
  364   assert((Kind == Distance || Kind == Line || Kind == Point) &&
  435   assert(!Y->isPoint() && "Y must not be a Point");
  473   assert(!(X->isPoint() && Y->isPoint()) &&
  559   assert(!(X->isLine() && Y->isPoint()) && "This case should never occur");
  819       assert(SrcTy == DstTy && "This function only unify integer types and "
  835   assert(widestWidthSeen > 0);
  844       assert(SrcTy == DstTy && "This function only unify integer types and "
 1158   assert(0 < Level && Level <= CommonLevels && "level out of range");
 1291   assert(0 < Level && Level <= CommonLevels && "Level out of range");
 1315     assert(ConstCoeff &&
 1319   assert(SE->isKnownPositive(ConstCoeff) && "ConstCoeff should be positive");
 1504   assert(0 < Level && Level <= CommonLevels && "Level out of range");
 1716   assert(0 < Level && Level <= MaxLevels && "Level out of range");
 1825   assert(0 < Level && Level <= SrcLevels && "Level out of range");
 2166     assert(CurLoop == DstAddRec->getLoop() &&
 2383         assert(!Constant && "Surprised to find multiple constants");
 3135     assert(Charlie.srem(Beta) == 0 && "C should be evenly divisible by B");
 3150     assert(Charlie.srem(Alpha) == 0 && "C should be evenly divisible by A");
 3164     assert(Charlie.srem(Alpha) == 0 && "C should be evenly divisible by A");
 3266   assert(isLoadOrStore(Src) && "instruction is not load or store");
 3267   assert(isLoadOrStore(Dst) && "instruction is not load or store");
 3421   assert(isLoadOrStore(Src) && "instruction is not load or store");
 3422   assert(isLoadOrStore(Dst) && "instruction is not load or store");
 3834   assert(Dep.isSplitable(SplitLevel) &&
 3838   assert(Src->mayReadFromMemory() || Src->mayWriteToMemory());
 3839   assert(Dst->mayReadFromMemory() || Dst->mayWriteToMemory());
 3840   assert(isLoadOrStore(Src));
 3841   assert(isLoadOrStore(Dst));
 3844   assert(underlyingObjectsAlias(AA, F->getParent()->getDataLayout(),
 3932         assert(SplitIter != nullptr);
lib/Analysis/DependenceGraphBuilder.cpp
   40   assert(IMap.empty() && "Expected empty instruction map at start");
lib/Analysis/DivergenceAnalysis.cpp
  101   assert(isa<Instruction>(DivVal) || isa<Argument>(DivVal));
  102   assert(!isAlwaysUniform(DivVal) && "cannot be a divergent");
  114     assert(BranchTerm->isConditional());
  191   assert(DivLoop && "loopHeader is not actually part of a loop");
  212     assert(!DivLoop->contains(UserBlock) &&
  317     assert(BranchLoop);
  355     assert(BranchLoop);
lib/Analysis/DomTreeUpdater.cpp
   67     assert(I < E && "Iterator range invalid; there should be DomTree updates.");
   88     assert(I < E &&
  109     assert(BB->getInstList().size() == 1 &&
  216   assert(DelBB && "Invalid push_back of nullptr DelBB.");
  217   assert(pred_empty(DelBB) && "DelBB has one or more predecessors.");
  304   assert(DT && "Invalid acquisition of a null DomTree");
  311   assert(PDT && "Invalid acquisition of a null PostDomTree");
  320   assert(isUpdateValid({DominatorTree::Insert, From, To}) &&
  366   assert(isUpdateValid({DominatorTree::Delete, From, To}) &&
  424   assert(B <= E && "Iterator out of range.");
  490     assert(PendUpdates.begin() <= I && I <= PendUpdates.end() &&
  500     assert(PendUpdates.begin() <= I && I <= PendUpdates.end() &&
lib/Analysis/GlobalsModRef.cpp
  473     assert(!SCC.empty() && "SCC with no functions?");
  491     assert(!SCC.empty() && "SCC with no functions?");
  956     assert(H.GAR == &Arg);
lib/Analysis/IVDescriptors.cpp
  463   assert((isa<ICmpInst>(I) || isa<FCmpInst>(I) || isa<SelectInst>(I)) &&
  780   assert(IK != IK_NoInduction && "Not an induction");
  784   assert(StartValue && "StartValue is null");
  785   assert((IK != IK_PtrInduction || StartValue->getType()->isPointerTy()) &&
  787   assert((IK != IK_IntInduction || StartValue->getType()->isIntegerTy()) &&
  791   assert((!getConstIntStepValue() || !getConstIntStepValue()->isZero()) &&
  794   assert((IK != IK_PtrInduction || getConstIntStepValue()) &&
  796   assert((IK == IK_FpInduction || Step->getType()->isIntegerTy()) &&
  799   assert((IK != IK_FpInduction || Step->getType()->isFloatingPointTy()) &&
  801   assert((IK != IK_FpInduction ||
  832   assert(Phi->getType()->isFloatingPointTy() && "Unexpected Phi type");
  846     assert(TheLoop->contains(Phi->getIncomingBlock(1)) &&
  917   assert(CastInsts.empty() && "CastInsts is expected to be empty.");
  919   assert(PSE.getSCEV(PN) == AR && "Unexpected phi node SCEV expression");
 1077   assert(PhiTy->isPointerTy() && "The PHI must be a pointer");
lib/Analysis/IndirectCallPromotionAnalysis.cpp
   80     assert(Count <= RemainingCount);
lib/Analysis/InlineCost.cpp
  248     assert(UpperBound > 0 && UpperBound <= INT_MAX && "invalid upper bound");
  390   assert(IntPtrWidth == Offset.getBitWidth());
 1676     assert(V->getType()->isPointerTy() && "Unexpected operand type!");
 1741   assert(NumInstructions == 0);
 1742   assert(NumVectorInstructions == 0);
 1750   assert(Threshold >= 0);
 1751   assert(SingleBBBonus >= 0);
 1752   assert(VectorBonus >= 0);
 1790     assert(CAI != Call.arg_end());
lib/Analysis/InstructionPrecedenceTracking.cpp
   47     assert(FirstSpecialInsts.find(BB) != FirstSpecialInsts.end() && "Must be!");
   85       assert(It->second == &Insn &&
   90   assert(It->second == nullptr &&
  142     assert(cast<LoadInst>(Insn)->isVolatile() &&
  147     assert(cast<StoreInst>(Insn)->isVolatile() &&
lib/Analysis/InstructionSimplify.cpp
  233   assert(Instruction::isAssociative(Opcode) && "Not an associative operation!");
  340     assert(isa<SelectInst>(RHS) && "No select instruction operand!");
  413   assert(isa<SelectInst>(LHS) && "Not comparing with a select instruction!");
  497     assert(isa<PHINode>(RHS) && "No PHI instruction operand!");
  537   assert(isa<PHINode>(LHS) && "Not comparing with a phi instruction!");
  657   assert(V->getType()->isPtrOrPtrVectorTy());
 2729         assert(B == D);
 3185   assert(CmpInst::isIntPredicate(Pred) && "Not an integer compare!");
 3195   assert(!isa<UndefValue>(LHS) && "Unexpected icmp undef,%X");
 3480   assert(CmpInst::isFPPredicate(Pred) && "Not an FP compare!");
 3505   assert((FCmpInst::isOrdered(Pred) || FCmpInst::isUnordered(Pred)) &&
 3558       assert(!C->isNaN() && "Unexpected NaN constant!");
 4378   assert(MaskNumElts == Indices.size() &&
 5486   assert(I != SimpleV && "replaceAndRecursivelySimplify(X,X) is not valid!");
 5487   assert(SimpleV && "Must provide a simplified value.");
lib/Analysis/IntervalPartition.cpp
   73   assert(I != intervals_end(&F) && "No intervals in function!?!?!");
   95   assert(IP.getRootInterval() && "Cannot operate on empty IntervalPartitions!");
   99   assert(I != intervals_end(IP) && "No intervals in interval partition!?!?!");
lib/Analysis/LazyCallGraph.cpp
   73   assert(!Edges && "Must not have already populated the edges for this node!");
  136   assert(F != &NewF && "Must not replace a function with itself!");
  233   assert(OuterRefSCC && "Can't have a null RefSCC!");
  234   assert(!Nodes.empty() && "Can't have an empty SCC!");
  237     assert(N && "Can't have a null node!");
  238     assert(OuterRefSCC->G->lookupSCC(*N) == this &&
  240     assert(N->DFSNumber == -1 &&
  242     assert(N->LowLink == -1 &&
  245       assert(E.getNode().isPopulated() && "Can't have an unpopulated node!");
  307   assert(G && "Can't have a null graph!");
  308   assert(!SCCs.empty() && "Can't have an empty SCC!");
  313     assert(C && "Can't have a null SCC!");
  315     assert(&C->getOuterRefSCC() == this &&
  318     assert(Inserted && "Found a duplicate SCC!");
  320     assert(IndexIt != SCCIndices.end() &&
  328     assert(C && "Can't have a null SCC in the indices!");
  329     assert(SCCSet.count(C) && "Found an index for an SCC not in the RefSCC!");
  330     assert(SCCs[i] == C && "Index doesn't point to SCC!");
  342           assert(SCCIndices.find(&TargetSCC)->second <= i &&
  466   assert(SourceIdx < TargetIdx && "Cannot have equal indices here!");
  485     assert(SourceI > (SCCs.begin() + SourceIdx) &&
  487     assert(*std::prev(SourceI) == &TargetSCC &&
  495   assert(SCCs[TargetIdx] == &TargetSCC &&
  498   assert(SCCs[SourceIdx] == &SourceSCC &&
  517     assert(SCCs[TargetIdx] == &TargetSCC &&
  532   assert(!(*SourceN)[TargetN].isCall() && "Must start with a ref edge!");
  654     assert(C != &TargetSCC &&
  680   assert((*SourceN)[TargetN].isCall() && "Must start with a call edge!");
  689   assert(G->lookupRefSCC(SourceN) == this &&
  691   assert(G->lookupRefSCC(TargetN) == this &&
  693   assert(G->lookupSCC(SourceN) != G->lookupSCC(TargetN) &&
  702   assert((*SourceN)[TargetN].isCall() && "Must start with a call edge!");
  711   assert(G->lookupRefSCC(SourceN) == this &&
  713   assert(G->lookupRefSCC(TargetN) == this &&
  717   assert(G->lookupSCC(SourceN) == &TargetSCC && "Source and Target must be in "
  763     assert(DFSStack.empty() &&
  765     assert(PendingSCCStack.empty() &&
  770       assert(RootN->DFSNumber == -1 &&
  791           assert(!G->SCCMap.count(&ChildN) &&
  829         assert(ChildN.LowLink > 0 && "Must have a positive low-link number!");
  889   assert(!(*SourceN)[TargetN].isCall() && "Must start with a ref edge!");
  891   assert(G->lookupRefSCC(SourceN) == this && "Source must be in this RefSCC.");
  892   assert(G->lookupRefSCC(TargetN) != this &&
  911   assert((*SourceN)[TargetN].isCall() && "Must start with a call edge!");
  913   assert(G->lookupRefSCC(SourceN) == this && "Source must be in this RefSCC.");
  914   assert(G->lookupRefSCC(TargetN) != this &&
  933   assert(G->lookupRefSCC(SourceN) == this && "Source must be in this RefSCC.");
  934   assert(G->lookupRefSCC(TargetN) == this && "Target must be in this RefSCC.");
  949   assert(G->lookupRefSCC(SourceN) == this && "Source must be in this RefSCC.");
  951   assert(G->lookupRefSCC(TargetN) != this &&
  966   assert(G->lookupRefSCC(TargetN) == this && "Target must be in this RefSCC.");
  968   assert(&SourceC != this && "Source must not be in this RefSCC.");
  985   assert(SourceIdx < TargetIdx &&
 1058     assert(RC != this && "We're merging into the target RefSCC, so it "
 1109   assert(G->lookupRefSCC(SourceN) == this &&
 1111   assert(G->lookupRefSCC(TargetN) != this &&
 1124   assert(Removed && "Target not in the edge set for this caller?");
 1148     assert(!(*SourceN)[*TargetN].isCall() &&
 1153     assert(Removed && "Target not in the edge set for this caller?");
 1195     assert(DFSStack.empty() &&
 1197     assert(PendingRefSCCStack.empty() &&
 1203       assert(RootN->DFSNumber == -1 &&
 1218       assert(N->DFSNumber != 0 && "We should always assign a DFS number "
 1245         assert(ChildN.LowLink != 0 &&
 1259         assert(!DFSStack.empty() &&
 1302     assert(DFSStack.empty() && "Didn't flush the entire DFS stack!");
 1303     assert(PendingRefSCCStack.empty() && "Didn't flush all pending nodes!");
 1306   assert(PostOrderNumber > 1 &&
 1336       assert(N.LowLink == SCCNumber &&
 1370   assert(G->lookupRefSCC(SourceN) == this && "Source must be in this RefSCC.");
 1452   assert(G->lookupRefSCC(N) == this &&
 1455   assert(G->NodeMap.find(&NewF) == G->NodeMap.end() &&
 1464   assert(&OldF != &NewF && "Cannot replace a function with itself!");
 1465   assert(OldF.use_empty() &&
 1477   assert(SCCMap.empty() &&
 1484   assert(SCCMap.empty() &&
 1489   assert(Removed && "Target not in the edge set for this caller?");
 1495   assert(F.use_empty() &&
 1500   assert(!isLibFunction(F) &&
 1524   assert(CI != SCCMap.end() &&
 1533   assert(C.size() == 1 && "Dead functions must be in a singular SCC");
 1534   assert(RC.size() == 1 && "Dead functions must be in a singular RefSCC");
 1582     assert(DFSStack.empty() &&
 1584     assert(PendingSCCStack.empty() &&
 1589       assert(RootN->DFSNumber == -1 &&
 1626         assert(ChildN.LowLink > 0 && "Must have a positive low-link number!");
 1667   assert(RC.SCCs.empty() && "Already built SCCs!");
 1668   assert(RC.SCCIndices.empty() && "Already mapped SCC indices!");
 1671     assert(N->LowLink >= (*Nodes.begin())->LowLink &&
 1705   assert(RefSCCIndices.empty() && "Already mapped RefSCC indices!");
 1733         assert(Inserted && "Cannot already have this RefSCC in the index map!");
lib/Analysis/LazyValueInfo.cpp
  193           assert(It != ValueCache.end() && "Val was just added to the map!");
  484         assert(!DisabledDT && "Both DT and DisabledDT are not nullptr!");
  493         assert(!DT && "Both DT and DisabledDT are not nullptr!");
  539     assert(BlockValueSet.count(e) && "Stack value should be in BlockValueSet!");
  543       assert(BlockValueStack.back() == e && "Nothing should have been pushed!");
  544       assert(TheCache.hasCachedValueInfo(e.second, e.first) &&
  555       assert(BlockValueStack.back() != e && "Stack should have been pushed!");
  703   assert(Val->getType()->isPointerTy());
  723     assert(isa<Argument>(Val) && "Unknown live-in to the entry block");
  775   assert(!Result.isOverdefined());
  812   assert(!Result.isOverdefined() && "Possible PHI in entry block?");
  960         assert(A->getType() == B->getType());
 1085   assert(BO->getOperand(0)->getType()->isSized() &&
 1326   assert(Cond && "precondition");
 1351   assert(isOperationFoldable(Usr) && "Precondition");
 1355     assert(CI->getOperand(0) == Op && "Operand 0 isn't Op");
 1364     assert((Op0Match || Op1Match) &&
 1389       assert(BI->getSuccessor(!isTrueDest) == BBTo &&
 1408         assert(Result.isOverdefined() && "Result isn't overdefined");
 1464     assert((Condition == Val || ValUsesConditionAndMayBeFoldable) &&
 1556   assert(BlockValueStack.empty() && BlockValueSet.empty());
 1596     assert(WasFastQuery && "More work to do after problem solved?");
 1617     assert(DL && "getCache() called with a null DataLayout");
 1716   assert(V->getType()->isIntegerTy());
 1727   assert(!(Result.isConstant() && isa<ConstantInt>(Result.getConstant())) &&
 1766   assert(!(Result.isConstant() && isa<ConstantInt>(Result.getConstant())) &&
lib/Analysis/LegacyDivergenceAnalysis.cpp
  242   assert(PDT.properlyDominates(End, Start) &&
lib/Analysis/Lint.cpp
  741   assert(!F.isDeclaration() && "Cannot lint external functions");
lib/Analysis/Loads.cpp
   44     assert(APAlign.isPowerOf2() && "must be a power of 2!");
   77       assert(Ty->isSized() && "must be sized");
  239   assert(SE.isLoopInvariant(StartS, L) && "implied by addrec definition");
lib/Analysis/LoopAccessAnalysis.cpp
  204     assert(AR && "Invalid addrec expression");
  251   assert(Checks.empty() && "Checks is not empty");
  875           assert(((IsReadOnlyPtr && UseDeferred) || IsWrite ||
  994   assert(Ty->isPointerTy() && "Unexpected non-ptr");
 1103   assert(llvm::all_of(
 1412   assert(Stride > 1 && "The stride must be greater than 1");
 1413   assert(TypeByteSize > 0 && "The type size in byte must be non-zero");
 1414   assert(Distance > 0 && "The distance must be non-zero");
 1445   assert (AIdx < BIdx && "Must pass arguments in program order");
 1544   assert(Val.isStrictlyPositive() && "Expect a positive value");
 1675             assert(*I1 != *I2);
 2080   assert(TheLoop->contains(BB) && "Unknown block used");
 2089   assert(!Report && "Multiple reports generated");
 2226     assert((AS0 == B.End->getType()->getPointerAddressSpace()) &&
lib/Analysis/LoopCacheAnalysis.cpp
   56   assert(!Loops.empty() && "Expecting a non-empy loop vector");
   62     assert(Loops.size() == 1 && "Expecting a single loop");
   80   assert(AR->getLoop() && "AR should have a loop");
  131   assert((isa<StoreInst>(StoreOrLoadInst) || isa<LoadInst>(StoreOrLoadInst)) &&
  143   assert(IsValid && "Expecting a valid reference");
  200   assert(IsValid && "Expecting a valid reference");
  256   assert(IsValid && "Expecting a valid reference");
  308   assert(Subscripts.empty() && "Subscripts should be empty");
  309   assert(Sizes.empty() && "Sizes should be empty");
  310   assert(!IsValid && "Should be called once from the constructor");
  363   assert(Addr != nullptr && "Expecting either a load or a store instruction");
  364   assert(SE.isSCEVable(Addr->getType()) && "Addr should be SCEVable");
  400   assert(isa<SCEVAddRecExpr>(LastSubscript) &&
  419   assert(AR->getLoop() && "AR should have a loop");
  458   assert(!Loops.empty() && "Expecting a non-empty loop vector.");
  498     assert((std::find_if(LoopCosts.begin(), LoopCosts.end(),
  512   assert(RefGroups.empty() && "Reference groups should be empty");
  516   assert(InnerMostLoop != nullptr && "Expecting a valid innermost loop");
  606   assert(!RG.empty() && "Reference group should have at least one member.");
lib/Analysis/LoopInfo.cpp
  127   assert(PI != pred_end(H) && "Loop must have at least one backedge!");
  142   assert(Incoming && Backedge && "expected non-null incoming and backedges");
  230   assert(Latch && "Expecting valid latch");
  233   assert(BI && BI->isConditional() && "Expecting conditional latch branch");
  236   assert(LatchCmpInst &&
  295   assert(Header && "Expected a valid loop header");
  368   assert(Preheader && Latch &&
  389   assert(GuardBB->getTerminator() && "Expecting valid guard terminator");
  514   assert((!LoopID || LoopID->getNumOperands() > 0) &&
  516   assert((!LoopID || LoopID->getOperand(0) == LoopID) &&
  549       assert(isValidAsAccessGroup(AccGroup) &&
  568             assert(isValidAsAccessGroup(AG) && "Item must be an access group");
  574             assert(isValidAsAccessGroup(AccGroup) &&
  706         assert((NL != &Unloop && (!NL || NL->contains(&Unloop))) &&
  712         assert((FoundIB || Unloop.contains(L)) && "uninitialized successor");
  720     assert(NIters < Unloop.getNumBlocks() && "runaway iterative algorithm");
  732         assert(NL != &Unloop && (!NL || NL->contains(&Unloop)) &&
  757       assert(OldParent && "new loop is not an ancestor of the original");
  769     assert(SubloopParents.count(Subloop) && "DFS failed to visit subloop");
  794       assert(Subloop && "subloop is not an ancestor of the original loop");
  802     assert(!Subloop && "subloop blocks must have a successor");
  813       assert((FoundIB || !DFS.hasPostorder(*I)) && "should have seen IB");
  822       assert(L->getParentLoop() == &Unloop && "cannot skip into nested loops");
  858   assert(!Unloop->isInvalid() && "Loop has already been erased!");
  880       assert(I != end() && "Couldn't find loop");
  908     assert(I != ParentLoop->end() && "Couldn't find loop");
  982   assert(LoopID->getNumOperands() > 0 && "requires at least one operand");
  983   assert(LoopID->getOperand(0) == LoopID && "invalid loop id");
lib/Analysis/LoopPass.cpp
  144   assert((&L == CurrentLoop || CurrentLoop->contains(&L)) &&
  149   assert(LQ.back() == CurrentLoop && "Loop queue back isn't the current loop!");
  366     assert (!PMS.empty() && "Unable to create Loop Pass Manager");
lib/Analysis/LoopUnrollAnalyzer.cpp
  136   assert(CV && "Constant expected.");
lib/Analysis/MemDepPrinter.cpp
   68       assert(dep.isUnknown() && "unexpected dependence type");
  118       assert( (isa<LoadInst>(Inst) || isa<StoreInst>(Inst) ||
lib/Analysis/MemoryBuiltins.cpp
  358   assert(isMallocLikeFn(CI, TLI) && "getMallocType and not malloc call");
  402   assert(isMallocLikeFn(CI, TLI) && "getMallocArraySize and not malloc call");
  506   assert(ObjectSize->getIntrinsicID() == Intrinsic::objectsize &&
  921   assert(I.isArrayAllocation());
lib/Analysis/MemoryDependenceAnalysis.cpp
  103   assert(InstIt != ReverseMap.end() && "Reverse map out of sync?");
  105   assert(Found && "Invalid reverse map!");
  350   assert(InvariantGroupDependency.isUnknown() &&
  381     assert(Other && "Must call it with not null instruction");
  391     assert(Ptr && !isa<GlobalValue>(Ptr) &&
  779   assert(std::is_sorted(Cache.begin(), Cache.begin() + Count) &&
  786   assert(getDependency(QueryCall).isNonLocal() &&
  919   assert(FromBB);
  921   assert(Loc.Ptr->getType()->isPointerTy() &&
 1004     assert(ExistingResult->getResult().getInst()->getParent() == BB &&
 1036   assert(Inst && "Didn't depend on anything?");
 1258       assert(Visited.count(BB) && "Should check 'visited' before adding to WL");
 1461       assert((GotWorklistLimit || I.getResult().isNonLocal() ||
 1471     assert((foundBlock || GotWorklistLimit) && "Current block not in cache?");
 1515     assert(Target->getParent() == PInfo[i].getBB());
 1591     assert(!ReverseDepIt->second.empty() && !RemInst->isTerminator() &&
 1595       assert(InstDependingOnRemInst != RemInst &&
 1601       assert(NewDirtyVal.getInst() &&
 1622       assert(I != RemInst && "Already removed NonLocalDep info for RemInst");
 1659       assert(P.getPointer() != RemInst &&
 1696   assert(!NonLocalDeps.count(RemInst) && "RemInst got reinserted?");
 1707     assert(DepKV.first != D && "Inst occurs in data structures");
 1708     assert(DepKV.second.getInst() != D && "Inst occurs in data structures");
 1712     assert(DepKV.first.getPointer() != D && "Inst occurs in NLPD map key");
 1714       assert(Entry.getResult().getInst() != D && "Inst occurs as NLPD value");
 1718     assert(DepKV.first != D && "Inst occurs in data structures");
 1721       assert(Entry.getResult().getInst() != D &&
 1726     assert(DepKV.first != D && "Inst occurs in data structures");
 1728       assert(Inst != D && "Inst occurs in data structures");
 1732     assert(DepKV.first != D && "Inst occurs in data structures");
 1734       assert(Inst != D && "Inst occurs in data structures");
 1738     assert(DepKV.first != D && "Inst occurs in rev NLPD map");
 1741       assert(P != ValueIsLoadPair(D, false) && P != ValueIsLoadPair(D, true) &&
lib/Analysis/MemoryLocation.cpp
  144       assert((ArgIdx == 0 || ArgIdx == 1) &&
  154       assert(ArgIdx == 1 && "Invalid argument index");
  166       assert(ArgIdx == 2 && "Invalid argument index");
  174       assert(ArgIdx == 0 && "Invalid argument index");
  182       assert(ArgIdx == 0 && "Invalid argument index");
  198     assert((ArgIdx == 0 || ArgIdx == 1) &&
lib/Analysis/MemorySSA.cpp
  153     assert(IsCall);
  158     assert(!IsCall);
  265   assert(DefInst && "Defining instruction not actually an instruction");
  526     assert(From->getNumOperands() && "Phi with no operands?");
  556     assert(!isa<MemoryUse>(Desc.Last) && "Uses don't exist in my world");
  557     assert(UpwardWalkLimit && "Need a valid walk limit");
  590     assert(isa<MemoryPhi>(Desc.Last) &&
  626     assert(!PausedSearches.empty() && "No searches to continue?");
  657         assert(isa<MemoryDef>(Query->OriginalAccess));
  665         assert(Res.Result != StopWhere && Res.Result != SkipStopWhere);
  688       assert(!MSSA.isLiveOnEntryDef(Res.Result) && "liveOnEntry is a clobber");
  746     assert(!Paths.empty() && NP >= &Paths.front() && NP <= &Paths.back() &&
  766     assert(Paths.empty() && VisitedPhis.empty() &&
  783       assert(!Paths.empty() && "Need a path to move");
  795       assert(!MSSA.isLiveOnEntryDef(Current) &&
  801       assert(all_of(TerminatedPaths, [&](const TerminatedPath &P) {
  816         assert(Iter != def_path_iterator());
  819         assert(CurNode.Last == Current);
  876         assert(DefChainEnd && "Failed to find dominating phi/liveOnEntry");
  897       assert(all_of(NewPaused,
  914     assert(all_of(R.OtherClobbers, [&](const TerminatedPath &P) {
 1104       assert(ReplacementDone && "Incomplete phi during partial rename");
 1140   assert(Root && "Trying to rename accesses in an unreachable block");
 1188   assert(!DT->isReachableFromEntry(BB) &&
 1337     assert(
 1404     assert(LocInfo.LowerBound < VersionStack.size() &&
 1406     assert(LocInfo.LastKill < VersionStack.size() &&
 1431           assert(UpperBound != 0);
 1678     assert(Point == Beginning &&
 1684     assert(Inserted && "Cannot move a Phi to a block that already has one");
 1692   assert(!getMemoryAccess(BB) && "MemoryPhi already exists for this BB");
 1704   assert(!isa<PHINode>(I) && "Cannot create a defined access for a PHI");
 1707     assert(NewAccess != nullptr && "Tried to create a memory access for a "
 1758     assert(Def == DefCheck && (Def || Use == UseCheck) && "Invalid template");
 1808   assert(MA->use_empty() &&
 1945       assert(ThisNumberIter != BlockNumbering.end() &&
 1949       assert(ThisNumber > LastNumber &&
 1955   assert(ValidBlocks.empty() &&
 1980       assert((!MA || (AL && (isa<MemoryUse>(MA) || DL))) &&
 1995     assert(AL->size() == ActualAccesses.size() &&
 1998     assert((DL || ActualDefs.size() == 0) &&
 2000     assert((!DL || DL->size() == ActualDefs.size()) &&
 2006       assert(&*ALI == *AAI && "Not the same accesses in the same order");
 2015         assert(&*DLI == *ADI && "Not the same defs in the same order");
 2033         assert(dominates(MP, U) && "Memory PHI does not dominate it's uses");
 2041         assert(dominates(MD, U) && "Memory Def does not dominate it's uses");
 2053     assert(isLiveOnEntryDef(Use) &&
 2056     assert(is_contained(Def->users(), Use) &&
 2099   assert(AL != nullptr && "Asking to renumber an empty block");
 2112   assert((DominatorBlock == Dominatee->getBlock()) &&
 2133   assert(DominatorNum != 0 && "Block was not numbered properly");
 2135   assert(DominateeNum != 0 && "Block was not numbered properly");
 2439     assert(isa<MemoryDef>(Q.OriginalAccess));
lib/Analysis/MemorySSAUpdater.cpp
  102         assert(Phi->operands().empty() && "Expected empty Phi");
  208   assert(Phi && "Can only remove concrete Phi.");
  263     assert((!Defs || (++Defs->begin() == Defs->end())) &&
  294   assert(i != -1 && "Should have found the basic block in the phi");
  491         assert(!isa<MemoryPhi>(FirstDef) &&
  495         assert(MSSA->dominates(NewDef, FirstDef) &&
  554       assert(DefMUDI && "Found MemoryUseOrDef with no Instruction.");
  559           assert(InsnDefining && "Defining instruction cannot be nullptr.");
  566           assert(DefIt != MSSA->getBlockDefs(DefMUD->getBlock())->begin() &&
  578   assert(InsnDefining && "Defining instruction cannot be nullptr.");
  660     assert(Phi && NewPhi && "Invalid Phi nodes.");
  684           assert(IncI && "Found MemoryUseOrDef with no Instruction.");
  688             assert(IncMUD &&
  708     assert(!MSSA->getWritableBlockAccesses(NewBlock) &&
  855         assert(Count == 1 && Pred && "Single predecessor expected.");
  935       assert(pred_size(BB) == AddedBlockSet.size() && "Duplicate edges added.");
  944       assert(AddedBlockSet.size() == 1 &&
  971     assert(!PrevBlockSet.empty() &&
  983       assert(DefPn != nullptr && "Unable to find last definition.");
 1034     assert(DT.getNode(BB)->getIDom() && "BB does not have valid idom");
 1036     assert(PrevIDom && "Previous IDom should exists");
 1038     assert(NewIDom && "BB should have a new valid idom");
 1039     assert(DT.dominates(NewIDom, PrevIDom) &&
 1072       assert(IDFPhi && "Phi must exist");
 1111                 assert(IDom && "Block must have a valid IDom.");
 1173   assert(Start->getParent() == To && "Incorrect Start instruction");
 1204   assert(MSSA->getBlockAccesses(To) == nullptr &&
 1214   assert(From->getUniquePredecessor() == To &&
 1239   assert(!MSSA->getWritableBlockAccesses(New) &&
 1245     assert(pred_size(New) == Preds.size() &&
 1249     assert(!Preds.empty() && "Must be moving at least one predecessor to the "
 1256       assert(PredsSet.size() == Preds.size() &&
 1274   assert(!MSSA->isLiveOnEntryDef(MA) &&
 1286     assert((NewDefTarget || MP->use_empty()) &&
 1344     assert(TI && "Basic block expected to have a terminator instruction");
 1424   assert(I->getParent() == InsertPt->getBlock() &&
 1434   assert(I->getParent() == InsertPt->getBlock() &&
lib/Analysis/ModuleSummaryAnalysis.cpp
  249   assert(F.hasName());
  329         assert(!CalledFunction && "Expected null called function in callsite for alias");
  342         assert(CalledFunction->hasName());
  504     assert(STy);
  543     assert(P.VTableOffset >= PrevOffset);
  622   assert(AliaseeVI && "Alias expects aliasee summary to be available");
  623   assert(AliaseeVI.getSummaryList().size() == 1 &&
  642   assert(PSI);
  689           assert(GV->isDeclaration() && "Def in module asm already has definition");
  769     assert(Summary && "Missing summary for global value");
  787     assert(GlobalList.second.SummaryList.size() == 1 &&
lib/Analysis/MustExecute.cpp
   50   assert(CurLoop != nullptr && "CurLoop can't be null");
   58   assert(Header == *CurLoop->getBlocks().begin() &&
   77   assert(CurLoop != nullptr && "CurLoop can't be null");
  121   assert(CurLoop->contains(CondExitBlock) && "meaning of exit block");
  150   assert(ExitBlock == BI->getSuccessor(1) && "implied by above");
  160   assert(Predecessors.empty() && "Garbage in predecessors set?");
  161   assert(CurLoop->contains(BB) && "Should only be called for loop blocks!");
  171     assert(CurLoop->contains(Pred) && "Should only reach loop blocks!");
  190   assert(CurLoop->contains(BB) && "Should only be called for loop blocks!");
  274   assert(CurLoop->contains(BB) && "Should only be called for loop blocks!");
  295   assert(CurLoop->contains(BB) && "Should only be called for loop blocks!");
  477   assert(PP->isTerminator() && "Expected a terminator!");
  510   assert(CurInst && "Cannot advance an end iterator!");
lib/Analysis/OrderedBasicBlock.cpp
   37   assert(!(LastInstFound == BB->end() && NextInstPos != 0) &&
   39   assert(A->getParent() == BB && "Instruction supposed to be in the block!");
   40   assert(B->getParent() == BB && "Instruction supposed to be in the block!");
   56   assert(II != IE && "Instruction not found?");
   57   assert((Inst == A || Inst == B) && "Should find A or B");
   67   assert(A->getParent() == B->getParent() &&
   69   assert(A->getParent() == BB && "Instructions must be in the tracked block!");
lib/Analysis/OrderedInstructions.cpp
   18   assert(InstA->getParent() == InstB->getParent() &&
lib/Analysis/PHITransAddr.cpp
  134   assert(!isa<PHINode>(I) && "Error, removing something that isn't an input");
  315   assert(DT || !MustDominate);
  316   assert(Verify() && "Invalid PHITransAddr!");
  322   assert(Verify() && "Invalid PHITransAddr!");
lib/Analysis/PhiValues.cpp
   52   assert(DepthMap.lookup(Phi) == 0);
   53   assert(NextDepthNumber != UINT_MAX);
   64       assert(DepthMap.lookup(PhiPhiOp) != 0);
  117     assert(Stack.empty());
  119   assert(DepthMap.lookup(PN) != 0);
lib/Analysis/PostDominators.cpp
   54     assert(DT.verify(PostDominatorTree::VerificationLevel::Full));
   56     assert(DT.verify(PostDominatorTree::VerificationLevel::Basic));
lib/Analysis/ProfileSummaryInfo.cpp
  108   assert((isa<CallInst>(Inst) || isa<InvokeInst>(Inst)) &&
  253   assert(ColdCountThreshold <= HotCountThreshold &&
lib/Analysis/RegionPass.cpp
  253     assert (!PMS.empty() && "Unable to create Region Pass Manager");
lib/Analysis/RegionPrinter.cpp
  231   assert(RI && "Argument must be non-null");
  241   assert(F && "Argument must be non-null");
  242   assert(!F->isDeclaration() && "Function must have an implementation");
lib/Analysis/ScalarEvolution.cpp
  448   assert(Op->getType()->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
  455   assert(Op->getType()->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
  462   assert(Op->getType()->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
  705       assert(LHead != RHead && "Two loops share the same header?");
  709         assert(DT.dominates(RHead, LHead) &&
  888     assert(Numerator && Denominator && "Uninitialized SCEV");
 1256   assert(getTypeSizeInBits(Op->getType()) > getTypeSizeInBits(Ty) &&
 1258   assert(isSCEVable(Ty) &&
 1639   assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
 1641   assert(isSCEVable(Ty) &&
 1945   assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
 1947   assert(isSCEVable(Ty) &&
 2199   assert(getTypeSizeInBits(Op->getType()) < getTypeSizeInBits(Ty) &&
 2201   assert(isSCEVable(Ty) &&
 2347   assert(CanAnalyze && "don't call from other places!");
 2409   assert(!(Flags & ~(SCEV::FlagNUW | SCEV::FlagNSW)) &&
 2411   assert(!Ops.empty() && "Cannot get empty add!");
 2416     assert(getEffectiveSCEVType(Ops[i]->getType()) == ETy &&
 2429     assert(Idx < Ops.size());
 2744       assert(DT.dominates(
 2910   assert(Flags == maskFlags(Flags, SCEV::FlagNUW | SCEV::FlagNSW) &&
 2912   assert(!Ops.empty() && "Cannot get empty mul!");
 2917     assert(getEffectiveSCEVType(Ops[i]->getType()) == ETy &&
 3160   assert(getEffectiveSCEVType(LHS->getType()) ==
 3189   assert(getEffectiveSCEVType(LHS->getType()) ==
 3416     assert(getEffectiveSCEVType(Operands[i]->getType()) == ETy &&
 3419     assert(isLoopInvariant(Operands[i], L) &&
 3551   assert(!Ops.empty() && "Cannot get empty (u|s)(min|max)!");
 3556     assert(getEffectiveSCEVType(Ops[i]->getType()) == ETy &&
 3575     assert(Idx < Ops.size());
 3661   assert(!Ops.empty() && "Reduced smax down to nothing!");
 3747     assert(cast<SCEVUnknown>(S)->getValue() == V &&
 3774   assert(isSCEVable(Ty) && "Type is not SCEVable!");
 3784   assert(isSCEVable(Ty) && "Type is not SCEVable!");
 3790   assert(Ty->isPointerTy() && "Unexpected non-pointer non-integer type!");
 3850       assert(ValueExprMap.count(VE.first));
 3900   assert(isSCEVable(V->getType()) && "Value is not SCEVable!");
 3932   assert(isSCEVable(V->getType()) && "Value is not SCEVable!");
 4046   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4058   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4070   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4072   assert(getTypeSizeInBits(SrcTy) <= getTypeSizeInBits(Ty) &&
 4082   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4084   assert(getTypeSizeInBits(SrcTy) <= getTypeSizeInBits(Ty) &&
 4094   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4096   assert(getTypeSizeInBits(SrcTy) <= getTypeSizeInBits(Ty) &&
 4106   assert(SrcTy->isIntOrPtrTy() && Ty->isIntOrPtrTy() &&
 4108   assert(getTypeSizeInBits(SrcTy) >= getTypeSizeInBits(Ty) &&
 4136   assert(!Ops.empty() && "At least one operand must be!");
 4331         assert(BI->getSuccessor(0) != BI->getSuccessor(1) &&
 4692   assert(L && "Expecting an integer loop header phi");
 4835     assert(isLoopInvariant(Expr, L) && "Expr is expected to be invariant");
 4911     assert(isa<SCEVAddRecExpr>(Rewrite.first) && "Expected an AddRec");
 4912     assert(!(Rewrite.second).empty() && "Expected to find Predicates");
 4963   assert(L && L->getHeader() == PN->getParent());
 4964   assert(BEValueV && StartValueV);
 5031   assert(ValueExprMap.find_as(PN) == ValueExprMap.end() &&
 5248   assert(RightEdge.isSingleEdge() && "Follows from LeftEdge.isSingleEdge()");
 5292     assert(IDom && "At least the entry block should dominate PN");
 5520   assert(InsertPair.second && "Should insert a new key");
 5718       assert(SignHint == ScalarEvolution::HINT_RANGE_SIGNED &&
 5743         assert(Erased && "Failed to erase Phi properly?");
 5822   assert(!isa<SCEVCouldNotCompute>(MaxBECount) &&
 5868       assert(SE.getTypeSizeInBits(S->getType()) == BitWidth &&
 6088         assert(BI->isConditional() && "Only possibility!");
 6127     assert(InsertPair.second && "We just checked!");
 6536   assert(ExitingBlock && "Must pass a non-null exiting block!");
 6537   assert(L->isLoopExiting(ExitingBlock) &&
 6573   assert(ExitingBlock && "Must pass a non-null exiting block!");
 6574   assert(L->isLoopExiting(ExitingBlock) &&
 6685     assert(isLoopInvariant(BEExact, L) &&
 6909     assert(BECount != SE->getCouldNotCompute() && "Bad exit SCEV!");
 6910     assert(SE->DT.dominates(ENT.ExitingBlock, Latch) &&
 6919     assert((Preds || ENT.hasAlwaysTruePredicate()) &&
 6957   assert((isa<SCEVCouldNotCompute>(getMax()) || isa<SCEVConstant>(getMax())) &&
 6985   assert((isa<SCEVCouldNotCompute>(MaxNotTaken) ||
 6994   assert((isa<SCEVCouldNotCompute>(ExactNotTaken) ||
 6997   assert((isa<SCEVCouldNotCompute>(MaxNotTaken) ||
 7009   assert((isa<SCEVCouldNotCompute>(MaxNotTaken) ||
 7017   assert((isa<SCEVCouldNotCompute>(MaxNotTaken) ||
 7048   assert((isa<SCEVCouldNotCompute>(MaxCount) || isa<SCEVConstant>(MaxCount)) &&
 7080     assert((AllowPredicates || EL.Predicates.empty()) &&
 7132   assert(L->contains(ExitingBlock) && "Exit count for non-loop block?");
 7142     assert(BI->isConditional() && "If unconditional, it can't be in loop!");
 7144     assert(ExitIfTrue == L->contains(BI->getSuccessor(1)) &&
 7161     assert(Exit && "Exiting block must have at least one exit");
 7185   assert(this->L == L && this->ExitIfTrue == ExitIfTrue &&
 7199   assert(this->L == L && this->ExitIfTrue == ExitIfTrue &&
 7204   assert(InsertResult.second && "Expected successful insertion!");
 7459   assert(!L->contains(ExitingBlock) && "Not an exiting block!");
 7465   assert(L->contains(Switch->getDefaultDest()) &&
 7483   assert(isa<SCEVConstant>(Val) &&
 7696   assert(Result->getType()->isIntegerTy(1) &&
 7889   assert(PN->getParent() == Header && "Can't evaluate PHI not in loop header!");
 7905   assert(BEs.getActiveBits() < CHAR_BIT * sizeof(unsigned) &&
 7969   assert(PN->getParent() == Header && "Can't evaluate PHI not in loop header!");
 7972   assert(Latch && "Should follow from NumIncomingValues == 2!");
 8396   assert(BW == SE.getTypeSizeInBits(B->getType()));
 8397   assert(A != 0 && "A must be non-zero.");
 8443   assert(AddRec->getNumOperands() == 3 && "This is not a quadratic chrec!");
 8459   assert(!N.isNullValue() && "This is not a quadratic addrec");
 8576   assert(AddRec->getOperand(0)->isZero() &&
 8582   assert(Range.contains(APInt(SE.getTypeSizeInBits(AddRec->getType()), 0)) &&
 8989         assert(!RA.isMinValue() && "Should have been caught earlier!");
 8995         assert(!RA.isMaxValue() && "Should have been caught earlier!");
 9001         assert(!RA.isMinSignedValue() && "Should have been caught earlier!");
 9007         assert(!RA.isMaxSignedValue() && "Should have been caught earlier!");
 9119   assert(PostInc != getCouldNotCompute() && "Unexpected could not compute");
 9137       assert((DT.dominates(L1->getHeader(), L2->getHeader()) ||
 9153   assert (SplitLHS.second != getCouldNotCompute() && "Unexpected CNC");
 9159   assert (SplitRHS.second != getCouldNotCompute() && "Unexpected CNC");
 9207   assert(Result == ResultSwapped && "should be able to analyze both!");
 9209     assert(Increasing == !IncreasingSwapped &&
 9460     assert(!verifyFunction(*L->getHeader()->getParent(), &dbgs()) &&
 9525     assert(DTN && "should reach the loop header before reaching the root!");
 9550       assert(DT.dominates(DominatingEdge, Latch) && "should be!");
 9570     assert(!verifyFunction(*L->getHeader()->getParent(), &dbgs()) &&
 9574   assert(isAvailableAtLoopEntry(LHS, L) &&
 9576   assert(isAvailableAtLoopEntry(RHS, L) &&
 9994     assert(Pred == CmpInst::ICMP_SLT && "Checked above!");
10013       assert(Erased && "Failed to erase LPhi!");
10018       assert(Erased && "Failed to erase RPhi!");
10057   assert(LPhi && "LPhi should definitely be a SCEVUnknown Phi!");
10088     assert(Predecessor && "Loop with AddRec with no predecessor?");
10093     assert(Latch && "Loop with AddRec with no latch?");
10213   assert(getTypeSizeInBits(LHS->getType()) ==
10216   assert(getTypeSizeInBits(FoundLHS->getType()) ==
10482   assert(isKnownPositive(Stride) && "Positive stride expected!");
10544   assert(!isKnownNonPositive(Stride) &&
10852     assert(Range.contains(
10869   assert(getNumOperands() > 1 && "AddRec with zero step?");
10886   assert(!Last->isZero() && "Recurrency with zero step?");
11357   assert(SE && "SCEVCallbackVH called with a null ScalarEvolution!");
11365   assert(SE && "SCEVCallbackVH called with a null ScalarEvolution!");
11470   assert(PendingLoopPredicates.empty() && "isImpliedCond garbage");
11471   assert(PendingPhiRanges.empty() && "getRangeRef garbage");
11472   assert(PendingMerges.empty() && "isImpliedViaMerge garbage");
11473   assert(!WalkingBEDominatingConds && "isLoopBackedgeGuardedByCond garbage!");
11474   assert(!ProvingSplitPredicate && "ProvingSplitPredicate garbage!");
11685     assert(!L->contains(AR->getLoop()) && "Containing loop's header does not"
12067   assert(LHS->getType() == RHS->getType() &&
12247   assert(LHS->getType() == RHS->getType() && "LHS and RHS types don't match");
12248   assert(LHS != RHS && "LHS and RHS are the same SCEV");
12370   assert(Key && "Only SCEVUnionPredicate doesn't have an "
lib/Analysis/ScalarEvolutionExpander.cpp
   80   assert(SE.DT.dominates(Ret, &*BIP));
  100     assert(!IP->isEHPad() && "unexpected eh pad!");
  111   assert((Op == Instruction::BitCast ||
  115   assert(SE.getTypeSizeInBits(V->getType()) == SE.getTypeSizeInBits(Ty) &&
  511     assert(!isa<Instruction>(V) ||
  795     assert(Exponent > 0 && "Trying to calculate a zeroth exponent of operand?");
  814     assert(Result && "Nothing was expanded?");
  837         assert(!Ty->isVectorTy() && "vector types are not SCEVable");
 1165   assert((!IVIncInsertLoop||IVIncInsertPos) && "Uninitialized insert position");
 1263   assert(L->getLoopPreheader() &&
 1270   assert(!isa<Instruction>(StartV) ||
 1372         assert(!PostLoopOffset && "Start not-null but PostLoopOffset set?");
 1404     assert(LatchBlock && "PostInc mode requires a unique loop latch!");
 1458     assert(S->isAffine() && "Can't linearly scale non-affine recurrences.");
 1545         assert(StartV->getType() == PTy && "Pointer type mismatch for GEP!");
 1597     assert(Ty == SE.getEffectiveSCEVType(CanonicalIV->getType()) &&
 1771     assert(SE.getTypeSizeInBits(Ty) == SE.getTypeSizeInBits(SH->getType()) &&
 1927   assert(Ty->isIntegerTy() && "Can only insert integer induction variables!");
 2214   assert(IP);
 2240   assert(AR->isAffine() && "Cannot generate RT check for "
 2247   assert(ExitCount != SE.getCouldNotCompute() && "Invalid loop count");
lib/Analysis/ScalarEvolutionNormalization.cpp
   68     assert(Kind == Normalize && "Only two possibilities!");
lib/Analysis/StackSafetyAnalysis.cpp
  241   assert(!Offset.isEmptySet());
  258   assert(!AccessRange.isEmptySet());
  291       assert(V == UI.get());
  343         assert(isa<Function>(Callee) || isa<GlobalAlias>(Callee));
  368   assert(!F.isDeclaration() &&
  463     assert(!CS.Offset.isEmptySet() &&
  535   assert(WorkList.empty());
  562   assert(Count == SSI.size() && "Unexpected functions in the result");
lib/Analysis/StratifiedSets.h
  102     assert(inbounds(Index));
  185       assert(!isRemapped());
  190       assert(!isRemapped());
  195       assert(!isRemapped());
  200       assert(!isRemapped());
  205       assert(!isRemapped());
  215       assert(!isRemapped());
  216       assert(hasBelow());
  221       assert(!isRemapped());
  222       assert(hasAbove());
  227       assert(!isRemapped());
  232       assert(!isRemapped());
  240       assert(!isRemapped());
  245       assert(isRemapped());
  251       assert(isRemapped());
  283         assert(Iter != Remaps.end());
  290         assert(Iter != Remaps.end());
  299       assert(Iter != Remaps.end());
  370     assert(has(Main));
  380     assert(has(Main));
  386     assert(has(Main));
  442     assert(inbounds(Idx1) && inbounds(Idx2));
  443     assert(&linksAt(Idx1) != &linksAt(Idx2) &&
  463     assert(inbounds(Idx1) && inbounds(Idx2));
  512     assert(inbounds(LowerIndex) && inbounds(UpperIndex));
lib/Analysis/SyncDependenceAnalysis.cpp
  222     assert(JoinBlocks);
  252     assert(ItBeginRPO != ItEndRPO);
  270       assert(DefBlock);
  312       assert(ParentLoop);
  317       assert(HeaderDefBlock && "no definition at header of carrying loop");
  321         assert((ItExitDef != DefMap.end()) &&
  353   assert(ItInserted.second);
  376   assert(ItInserted.second);
lib/Analysis/TargetLibraryInfo.cpp
   71   assert(std::is_sorted(StandardNames.begin(), StandardNames.end(),
lib/Analysis/TargetTransformInfo.cpp
  151   assert(Cost >= 0 && "TTI should not produce negative costs!");
  158   assert(Cost >= 0 && "TTI should not produce negative costs!");
  166   assert(Cost >= 0 && "TTI should not produce negative costs!");
  192   assert(Cost >= 0 && "TTI should not produce negative costs!");
  205   assert(Cost >= 0 && "TTI should not produce negative costs!");
  346   assert(Cost >= 0 && "TTI should not produce negative costs!");
  439   assert(Cost >= 0 && "TTI should not produce negative costs!");
  447   assert(Cost >= 0 && "TTI should not produce negative costs!");
  453   assert(Cost >= 0 && "TTI should not produce negative costs!");
  460   assert(Cost >= 0 && "TTI should not produce negative costs!");
  467   assert(Cost >= 0 && "TTI should not produce negative costs!");
  591   assert(Cost >= 0 && "TTI should not produce negative costs!");
  598   assert(Cost >= 0 && "TTI should not produce negative costs!");
  604   assert ((I == nullptr || I->getOpcode() == Opcode) &&
  607   assert(Cost >= 0 && "TTI should not produce negative costs!");
  615   assert(Cost >= 0 && "TTI should not produce negative costs!");
  621   assert(Cost >= 0 && "TTI should not produce negative costs!");
  627   assert ((I == nullptr || I->getOpcode() == Opcode) &&
  630   assert(Cost >= 0 && "TTI should not produce negative costs!");
  637   assert(Cost >= 0 && "TTI should not produce negative costs!");
  645   assert ((I == nullptr || I->getOpcode() == Opcode) &&
  648   assert(Cost >= 0 && "TTI should not produce negative costs!");
  657   assert(Cost >= 0 && "TTI should not produce negative costs!");
  666   assert(Cost >= 0 && "TTI should not produce negative costs!");
  678   assert(Cost >= 0 && "TTI should not produce negative costs!");
  687   assert(Cost >= 0 && "TTI should not produce negative costs!");
  694   assert(Cost >= 0 && "TTI should not produce negative costs!");
  701   assert(Cost >= 0 && "TTI should not produce negative costs!");
  713   assert(Cost >= 0 && "TTI should not produce negative costs!");
  719   assert(Cost >= 0 && "TTI should not produce negative costs!");
  726   assert(Cost >= 0 && "TTI should not produce negative costs!");
  735   assert(Cost >= 0 && "TTI should not produce negative costs!");
  882     assert(Kind != RK_None && "expected binary or min/max reduction only.");
  929   assert(I->getType()->isVectorTy() && "Expecting a vector type");
lib/Analysis/TypeBasedAliasAnalysis.cpp
  339         assert(Idx >= FirstFieldOpNo + NumOpsPerField &&
  614       assert(!NewFormat && "Did not see access type in access path!");
  674   assert(isStructPathTBAA(A) && "Access A is not struct-path aware!");
  675   assert(isStructPathTBAA(B) && "Access B is not struct-path aware!");
lib/Analysis/TypeMetadataUtils.cpp
   77   assert(CI->getCalledFunction()->getIntrinsicID() == Intrinsic::type_test);
  102   assert(CI->getCalledFunction()->getIntrinsicID() ==
lib/Analysis/VFABIDemangling.cpp
  388   assert(NGlobalPreds < 2 && "Cannot have more than one global predicate.");
  390     assert(Parameters.back().ParamKind == VFParamKind::GlobalPredicate &&
lib/Analysis/ValueTracking.cpp
  135     assert(NumExcluded <= Excluded.size());
  193   assert(LHS->getType() == RHS->getType() &&
  195   assert(LHS->getType()->isIntOrIntVectorTy() &&
  354   assert(!Known.hasConflict() && !Known2.hasConflict());
  442   assert(NumRanges >= 1);
  594     assert(I->getParent()->getParent() == Q.CxtI->getParent()->getParent() &&
  603     assert(I->getCalledFunction()->getIntrinsicID() == Intrinsic::assume &&
  609       assert(BitWidth == 1 && "assume operand is not i1?");
  615       assert(BitWidth == 1 && "assume operand is not i1?");
 1141     assert(SrcBitWidth && "SrcBitWidth can't be zero");
 1254         assert((Known.Zero & Known.One) == 0 && "Bits known to be one AND zero?");
 1636   assert(V && "No Value?");
 1637   assert(Depth <= MaxDepth && "Limit Search Depth");
 1640   assert((V->getType()->isIntOrIntVectorTy(BitWidth) ||
 1647   assert(ExpectedWidth == BitWidth && "V and Known should have same BitWidth");
 1704   assert(!isa<ConstantData>(V) && "Unhandled constant data!");
 1735   assert((Known.Zero & Known.One) == 0 && "Bits known to be one AND zero?");
 1744   assert(Depth <= MaxDepth && "Limit Search Depth");
 1852   assert(GEP->getType()->isPointerTy() && "We only support plain pointer GEP");
 1905   assert(V->getType()->isPointerTy() && "V must be pointer type");
 1906   assert(!isa<ConstantData>(V) && "Did not expect ConstantPointerNull");
 1937       assert(WorkList.empty() && "Should be!");
 1958           assert(BI->isConditional() && "uses a comparison!");
 1981   assert(NumRanges >= 1);
 2306   assert(isa<Operator>(Select) &&
 2363   assert(Result > 0 && "At least one sign bit needs to be present!");
 2375   assert(Depth <= MaxDepth && "Limit Search Depth");
 2619         assert(M < NumElts * 2 && "Invalid shuffle mask constant");
 2640       assert(Tmp <= V->getType()->getScalarSizeInBits() &&
 2669   assert(V && "No Value?");
 2670   assert(Depth <= MaxDepth && "Limit Search Depth");
 2671   assert(V->getType()->isIntegerTy() && "Not integer or pointer type!");
 3100   assert(V->getType()->isFPOrFPVectorTy() && "Querying for NaN on non-FP type");
 3236       assert(CI->getBitWidth() > 8 && "8 bits should be handled above!");
 3353   assert(InsertBefore && "Must have someplace to insert!");
 3376   assert((V->getType()->isStructTy() || V->getType()->isArrayTy()) &&
 3378   assert(ExtractValueInst::getIndexedType(V->getType(), idx_range) &&
 3443     assert(Idxs.size() == size
 3477   assert(V);
 3666   assert(Call &&
 3758     assert(V->getType()->isPointerTy() && "Unexpected operand type!");
 3829     assert(V->getType()->isIntegerTy() && "Unexpected operand type!");
 4182       assert(EVI->getNumIndices() == 1 && "Obvious from CI's type");
 4187         assert(EVI->getIndices()[0] == 1 && "Obvious from CI's type");
 4191             assert(B->isConditional() && "How else is it using an i1?");
 4578   assert(CmpInst::isIntPredicate(Pred) && "Expected integer comparison");
 4741   assert(X && Y && "Invalid operand");
 5137   assert(!LHS->getType()->isVectorTy() && "TODO: extend to handle vectors!");
 5320   assert((LHS->getOpcode() == Instruction::And ||
 5324   assert(Depth <= MaxDepth && "Hit recursion limit");
 5357   assert(OpTy->isIntOrIntVectorTy(1) && "Expected integer type only!");
 5367   assert(OpTy->isIntegerTy(1) && "implied by above");
 5389   assert(Cond->getType()->isIntOrIntVectorTy(1) && "Condition must be bool");
 5410   assert((TrueBB == ContextBB || FalseBB == ContextBB) &&
 5529         assert(Upper != Lower && "Upper part of range has wrapped!");
 5688   assert(V->getType()->isIntOrIntVectorTy() && "Expected integer instruction");
lib/Analysis/VectorUtils.cpp
  262   assert(V->getType()->isVectorTy() && "Not looking at a vector?");
  333   assert(Depth <= MaxDepth && "Limit Search Depth");
  514     assert(isValidAsAccessGroup(AccGroups) && "Node must be an access group");
  521     assert(isValidAsAccessGroup(Item) && "List item must be an access group");
  572     assert(isValidAsAccessGroup(MD1) && "Node must be an access group");
  578       assert(isValidAsAccessGroup(Item) && "List item must be an access group");
  645   assert(!Group.isReverse() && "Reversed group not supported.");
  706   assert(VecTy1 && VecTy2 &&
  712   assert(NumElts1 >= NumElts2 && "Unexpect the first vector has less elements");
  727   assert(NumVecs > 1 && "Should be at least two vectors");
  735       assert((V0->getType() == V1->getType() || i == NumVecs - 2) &&
lib/AsmParser/LLLexer.cpp
   79       assert(Buffer != End);
   99     assert(Buffer != End);
lib/AsmParser/LLParser.cpp
  228     assert(MD && "UpgradeInstWithTBAATag should have a TBAA tag");
  355   assert(Lex.getKind() == lltok::kw_module);
  370   assert(Lex.getKind() == lltok::kw_target);
  395   assert(Lex.getKind() == lltok::kw_source_filename);
  410   assert(Lex.getKind() == lltok::kw_deplibs);
  482   assert(Lex.getKind() == lltok::kw_declare);
  505   assert(Lex.getKind() == lltok::kw_define);
  590   assert(Lex.getKind() == lltok::GlobalVar);
  615   assert(Lex.getKind() == lltok::ComdatVar);
  700   assert(Lex.getKind() == lltok::MetadataVar);
  733   assert(Lex.getKind() == lltok::exclaim);
  760     assert(NumberedMetadata[MetadataID] == Init && "Tracking VH didn't work");
  809   assert(Lex.getKind() == lltok::SummaryID);
 1005   assert(GA->getName() == Name && "Should not be a name conflict!");
 1158   assert(Lex.getKind() == lltok::kw_attributes);
 2021   assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata attachment");
 2098   assert((AttrKind == lltok::kw_dereferenceable ||
 2564   assert(Lex.getKind() == lltok::lparen);
 2645   assert(Lex.getKind() == lltok::lparen);
 2745   assert(Lex.getKind() == lltok::lbrace);
 3405       assert(Opc == Instruction::ICmp && "Unexpected opcode for CmpInst!");
 3640       assert(Opc == Instruction::InsertElement && "Unknown opcode");
 3914     assert(isMDSignedField() && "Wrong field type");
 3918     assert(isMDField() && "Wrong field type");
 3930     assert(isMDSignedField() && "Wrong field type");
 3934     assert(isMDUnsignedField() && "Wrong field type");
 3954   assert(Result.Val <= Result.Max && "Expected value in range");
 3979   assert(Tag <= Result.Max && "Expected valid DWARF tag");
 3999   assert(Macinfo <= Result.Max && "Expected valid DWARF macinfo type");
 4019   assert(Virtuality <= Result.Max && "Expected valid DWARF virtuality code");
 4037   assert(Lang <= Result.Max && "Expected valid DWARF language");
 4055   assert(CC <= Result.Max && "Expected valid DWARF calling convention");
 4073   assert(*Kind <= Result.Max && "Expected valid emission kind");
 4092   assert(((unsigned)*Kind) <= Result.Max && "Expected valid nameTable kind");
 4111   assert(Encoding <= Result.Max && "Expected valid DWARF language");
 4211   assert(Result.Val >= Result.Min && "Expected value in range");
 4212   assert(Result.Val <= Result.Max && "Expected value in range");
 4351   assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
 4375   assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
 4940   assert(Lex.getKind() == lltok::MetadataVar && "Expected metadata type name");
 5106   assert(Lex.getKind() == lltok::exclaim && "Expected '!' here");
 5263     assert(isa<Constant>(V) && "Expected a constant value");
 5484   assert(Fn->getAddressSpace() == AddrSpace && "Created function in wrong AS");
 5557     assert((BBID.Kind == ValID::t_LocalID || BBID.Kind == ValID::t_LocalName) &&
 6527     assert(Opc == Instruction::ICmp && "Unknown opcode for CmpInst!");
 7361   assert(Indexes.empty() && "Expected empty order vector");
 7408   assert(Lex.getKind() == lltok::kw_uselistorder_bb);
 7455   assert(Lex.getKind() == lltok::kw_module);
 7491   assert(Lex.getKind() == lltok::kw_typeid);
 7512       assert(!*TIDRef.first &&
 7551   assert(Lex.getKind() == lltok::kw_typeidCompatibleVTable);
 7601       assert(TI[P.first].VTableVI == EmptyVI &&
 7619       assert(!*TIDRef.first &&
 7689       assert(Val <= 0xff);
 7904   assert(!(ReadOnly && WriteOnly));
 7920     assert(Name.empty());
 7923     assert(!Name.empty());
 7926       assert(GV);
 7929       assert(
 7942       assert(VIRef.first->getRef() == FwdVIRef &&
 7953       assert(!AliaseeRef.first->hasAliasee() &&
 7955       assert(Summary && "Aliasee must be a definition");
 7981   assert(Lex.getKind() == lltok::kw_gv);
 8062   assert(Lex.getKind() == lltok::kw_function);
 8132   assert(Lex.getKind() == lltok::kw_variable);
 8187   assert(Lex.getKind() == lltok::kw_alias);
 8223     assert(Summary && "Aliasee must be a definition");
 8249   assert(Lex.getKind() == lltok::kw_funcFlags);
 8305   assert(Lex.getKind() == lltok::kw_calls);
 8354       assert(Calls[P.first].first.getRef() == FwdVIRef &&
 8399   assert(Lex.getKind() == lltok::kw_vTableFuncs);
 8441       assert(VTableFuncs[P.first].FuncVI == EmptyVI &&
 8459   assert(Lex.getKind() == lltok::kw_refs);
 8502       assert(Refs[P.first].getRef() == FwdVIRef &&
 8522   assert(Lex.getKind() == lltok::kw_typeIdInfo);
 8570   assert(Lex.getKind() == lltok::kw_typeTests);
 8597       assert(TypeTests[P.first] == 0 &&
 8616   assert(Lex.getKind() == Kind);
 8638       assert(VFuncIdList[P.first].GUID == 0 &&
 8655   assert(Lex.getKind() == Kind);
 8677       assert(ConstVCallList[P.first].VFunc.GUID == 0 &&
 8712   assert(Lex.getKind() == lltok::kw_vFuncId);
 8748   assert(Lex.getKind() == lltok::kw_flags);
 8764       assert(HasLinkage && "Linkage not optional in summary entry");
 8806   assert(Lex.getKind() == lltok::kw_varFlags);
 8852   assert(I != ModuleIdMap.end());
 8869     assert(NumberedValueInfos[GVId].getRef() != FwdVIRef);
lib/AsmParser/LLParser.h
   74       assert(!RHS.ConstantStructElts);
   80       assert((Kind == t_LocalName || Kind == t_GlobalName ||
lib/BinaryFormat/Dwarf.cpp
  491   assert(Arch != llvm::Triple::ArchType::UnknownArch);
lib/BinaryFormat/MsgPackDocument.cpp
   42   assert(!Key.isEmpty());
lib/BinaryFormat/MsgPackDocumentYAML.cpp
  100   assert((Tag == "!str" || Tag == "") && "unsupported tag");
lib/BinaryFormat/MsgPackWriter.cpp
  113     assert(Size <= UINT32_MAX && "String object too long to be encoded");
  122   assert(!Compatible && "Attempt to write Bin format in compatible mode");
  133     assert(Size <= UINT32_MAX && "Binary object too long to be encoded");
  200       assert(Size <= UINT32_MAX && "Ext size too large to be encoded");
lib/Bitcode/Reader/BitcodeAnalyzer.cpp
  917             assert(!(Val >> 32) && "Unexpected high bits set");
  937           assert(i + 2 == e && "Array op not second to last");
lib/Bitcode/Reader/BitcodeReader.cpp
  875     assert(F && "Expected valid function");
  891   assert(BasicBlockFwdRefs.empty() && "Function missing from queue");
 1339   assert((!Alignment || isPowerOf2_32(Alignment)) &&
 1640           assert(Record[i] == 0 && "Kind string not null terminated");
 1647             assert(Record[i] == 0 && "Value string not null terminated");
 1652           assert((Record[i] == 5 || Record[i] == 6) &&
 1916     assert(ResultTy && "Didn't read a type?");
 2047   assert(MaybeEntry.get().Kind == BitstreamEntry::SubBlock);
 2048   assert(MaybeEntry.get().ID == bitc::VALUE_SYMTAB_BLOCK_ID);
 2822     assert(V->getType() == flattenPointerTypes(CurFullTy) &&
 2875         assert(ID < FunctionBBs.size() && "Basic block not found");
 2949   assert(
 3014   assert(SeenValueSymbolTable);
 3157   assert(NewGV->getType() == flattenPointerTypes(FullTy) &&
 3223   assert(Func->getFunctionType() == flattenPointerTypes(FullFTy) &&
 3304   assert(Func->getType() == flattenPointerTypes(FullTy) &&
 3362   assert(NewGA->getValueType() == flattenPointerTypes(FullTy) &&
 3395   assert(NewGA->getType() == flattenPointerTypes(FullTy) &&
 3454           assert(VSTOffset == 0 || FunctionsWithBodies.empty());
 3461           assert(VSTOffset > 0);
 3478         assert(DeferredMetadataInfo.empty() && "Unexpected deferred metadata");
 3710     assert(I.getType() == flattenPointerTypes(FullFTy->getParamType(ArgNo)) &&
 3765         assert(DeferredMetadataInfo.empty() &&
 3808         assert(!BBRefs.empty() && "Unexpected empty array");
 3809         assert(!BBRefs.front() && "Invalid reference to entry block");
 4668         assert(isa<FPMathOperator>(I) && "Unexpected phi type");
 4685         assert(BitCode == bitc::FUNC_CODE_INST_LANDINGPAD_OLD);
 4718         assert((CT != LandingPadInst::Catch ||
 4721         assert((CT != LandingPadInst::Filter ||
 5145         assert(
 5155       assert(I->getType() == flattenPointerTypes(FullTy) &&
 5200     assert(VSTOffset == 0 || !F->hasName());
 5228   assert(DFII != DeferredFunctionInfo.end() && "Deferred function not found!");
 5366   assert(VGI.first);
 5403   assert(Offset > 0 && "Expected non-zero VST offset");
 5449       assert(!SourceFileName.empty());
 5451       assert(VLI != ValueIdToLinkageMap.end() &&
 5463       assert(!SourceFileName.empty());
 5465       assert(VLI != ValueIdToLinkageMap.end() &&
 5524         assert(((SeenValueSymbolTable && VSTOffset > 0) ||
 5535         assert(!SeenValueSymbolTable &&
 5585             assert(!(Val >> 32) && "Unexpected high bits set");
 5734   assert(ROCnt + WOCnt <= Refs.size());
 5820       assert(Flags <= 0x1f && "Unexpected bits in flag");
 5891       assert(Record.size() >= RefListStartIndex + NumRefs &&
 6036       assert(Record.size() >= RefListStartIndex + NumRefs &&
 6123       assert(PendingTypeTests.empty());
 6129       assert(PendingTypeTestAssumeVCalls.empty());
 6135       assert(PendingTypeCheckedLoadVCalls.empty());
 6234         assert(!(Val >> 32) && "Unexpected high bits set");
 6558       assert(Flags <= 0x1f && "Unexpected bits in flag");
lib/Bitcode/Reader/MetadataLoader.cpp
  153     assert(i < MetadataPtrs.size());
  164     assert(N <= size() && "Invalid shrinkTo request!");
  165     assert(ForwardReference.empty() && "Unexpected forward refs");
  166     assert(UnresolvedNodes.empty() && "Unexpected unresolved node");
  185     assert(hasFwdRefs());
  298     assert(!N->isTemporary() && "Unexpected forward reference");
  308   assert(CT.getRawIdentifier() == &UUID && "Mismatched UUID");
  369     assert(empty() && "PlaceholderQueue hasn't been flushed before being destroyed");
  403     assert(MD && "Flushing placeholder on unassigned MD");
  406       assert(MDN->isResolved() &&
  754         assert(Entry.Kind == BitstreamEntry::Record &&
  760           assert(MaybeCode.get() == bitc::METADATA_INDEX &&
  788           assert(Code == bitc::METADATA_NAME);
  804           assert(MaybeNextBitCode.get() == bitc::METADATA_NAMED_NODE);
  817           assert(MD && "Invalid metadata: expect fwd ref to MDNode");
  986   assert(ID < (MDStringRef.size()) + GlobalMetadataBitPosIndex.size());
  987   assert(ID >= MDStringRef.size() && "Unexpected lazy-loading of MDString");
 1180         assert(isa<ConstantAsMetadata>(MD) &&
 1963   assert(Record.size() % 2 == 0);
 2055           assert(!MD->isTemporary() && "should load MDs before attachments");
lib/Bitcode/Reader/ValueList.cpp
   77   assert(FullTypes[Idx] == nullptr || FullTypes[Idx] == FullTy);
  196           assert(It != ResolveConstants.end() && It->first == *I);
  212         assert(isa<ConstantExpr>(UserC) && "Must be a ConstantExpr.");
lib/Bitcode/Reader/ValueList.h
   60     assert(ResolveConstants.empty() && "Constants not resolved?");
   75     assert(ResolveConstants.empty() && "Constants not resolved?");
   81     assert(i < ValuePtrs.size());
   93     assert(N <= size() && "Invalid shrinkTo request!");
lib/Bitcode/Writer/BitcodeWriter.cpp
  228     assert(VMI != GUIDToValueIdMap.end() &&
  471           assert(ModuleToSummariesForIndex->size() == 1);
  771         assert(Attr.isTypeAttribute());
 1435     assert(!(MD && isa<LocalAsMetadata>(MD)) &&
 1642   assert(N->isDistinct() && "Expected distinct compile units");
 2018       assert(N->isResolved() && "Expected forward references to be resolved");
 2381         assert(0 && "Unknown FP type!");
 2437           assert(CE->getNumOperands() == 2 && "Unknown constant expr!");
 2448         assert(CE->getNumOperands() == 1 && "Unknown constant expr!");
 2615       assert(isa<BinaryOperator>(I) && "Unknown instruction!");
 2917     assert(Log2_32(Value::MaximumAlignment) + 1 < 1 << 5 &&
 2919     assert(AlignRecord < 1 << 5 && "alignment greater than 1 << 64");
 3051   assert((VSTOffset & 31) == 0 && "VST block not 32-bit aligned");
 3076     assert((BitcodeIndex & 31) == 0 && "function block not 32-bit aligned");
 3134   assert(Order.Shuffle.size() >= 2 && "Shuffle too small");
 3147   assert(VE.shouldPreserveUseListOrder() &&
 3687     assert(V.isDeclaration());
 3844       assert(F.isDeclaration());
 3988     assert(S);
 3994     assert(ValueId);
 4117     assert(AliasValueId);
 4122     assert(AliaseeValueId);
 4329   assert(Buffer.size() >= BWH_HeaderSize &&
 4363 BitcodeWriter::~BitcodeWriter() { assert(WroteStrtab); }
 4379   assert(!WroteStrtab && !WroteSymtab);
 4411   assert(!WroteStrtab);
 4433   assert(!WroteStrtab);
 4439   assert(M.isMaterialized());
 4644   assert(!WroteStrtab);
 4650   assert(M.isMaterialized());
lib/Bitcode/Writer/ValueEnumerator.cpp
  234   assert(List.size() == Stack.back().Shuffle.size() && "Wrong size");
  242   assert(IDPair.first && "Unmapped value");
  443   assert(I != InstructionMap.end() && "Instruction is not mapped!");
  449   assert(ComdatID && "Comdat not found!");
  462   assert(I != ValueMap.end() && "Value not in slotcalculator!");
  661   assert(
  693   assert(F && "Expected a function");
  698     assert(Index.F == F && "Expected the same function");
  726   assert(MetadataMap.size() == MDs.size() &&
  805   assert(!V->getType()->isVoidTy() && "Can't insert void values!");
  806   assert(!isa<MetadataAsValue>(V) && "EnumerateValue doesn't handle Metadata!");
  895   assert(!isa<MetadataAsValue>(V) && "Unexpected metadata operand");
  999     assert(ValueMap.count(FnLocalMDVector[i]->getValue()) &&
lib/Bitcode/Writer/ValueEnumerator.h
   85       assert(ID && "Expected non-zero ID");
   86       assert(ID <= MDs.size() && "Expected valid ID");
  155     assert(ID != 0 && "Metadata not in slotcalculator!");
  169     assert(I != TypeMap.end() && "Type not in ValueEnumerator!");
  179     assert(I != AttributeListMap.end() && "Attribute not in ValueEnumerator!");
  187     assert(I != AttributeGroupMap.end() && "Attribute not in ValueEnumerator!");
lib/Bitstream/Reader/BitstreamReader.cpp
   69   assert(!Op.isLiteral() && "Not to be used with literals!");
   77     assert((unsigned)Op.getEncodingData() <= Cursor.MaxChunkSize);
   80     assert((unsigned)Op.getEncodingData() <= Cursor.MaxChunkSize);
   93   assert(!Op.isLiteral() && "Not to be used with literals!");
  101     assert((unsigned)Op.getEncodingData() <= Cursor.MaxChunkSize);
  107     assert((unsigned)Op.getEncodingData() <= Cursor.MaxChunkSize);
  179       assert(i+2 == e && "array op not second to last?");
  188         assert((unsigned)EltEnc.getEncodingData() <= MaxChunkSize);
  194         assert((unsigned)EltEnc.getEncodingData() <= MaxChunkSize);
  210     assert(Op.getEncoding() == BitCodeAbbrevOp::Blob);
  259   assert(Abbv->getNumOperandInfos() != 0 && "no record code in abbreviation?");
  335     assert(Op.getEncoding() == BitCodeAbbrevOp::Blob);
lib/CodeGen/AggressiveAntiDepBreaker.cpp
   95   assert(GroupNodes[0] == 0 && "GroupNode 0 not parent!");
   96   assert(GroupNodeIndices[0] == 0 && "Reg 0 not in Group 0!");
  153   assert(!State);
  198   assert(Count < InsertPosIndex && "Instruction index out of expected range!");
  564   assert(!Regs.empty() && "Empty register group!");
  585       assert(BV.empty());
  793     assert(CriticalPathSU && "Failed to find SUnit critical path");
  859         assert(AntiDepReg != 0 && "Anti-dependence on reg0?");
  879           assert(AntiDepOp && "Can't find index for defined register operand");
  945         assert(AntiDepReg != 0);
  998             assert(((KillIndices[CurrReg] == ~0u) !=
lib/CodeGen/AllocationOrder.cpp
   51     assert(is_contained(Order, Hints[I]) &&
lib/CodeGen/Analysis.cpp
   53     assert(!Indices && "Unexpected out of bound");
   63       assert(*Indices < NumElts && "Unexpected out of bound");
  164     assert(Var->hasInitializer() &&
  171   assert((GV || isa<ConstantPointerNull>(V)) &&
  499     assert(!Path.empty() && "found a leaf but didn't set the path?");
  712       assert(P.first->second == EHScope && "MBB is part of two scopes!");
lib/CodeGen/AntiDepBreaker.h
   60     assert(MI.isDebugValue() && "MI is not DBG_VALUE!");
lib/CodeGen/AsmPrinter/ARMException.cpp
   43   assert(MoveType != AsmPrinter::CFI_M_EH &&
lib/CodeGen/AsmPrinter/AccelTable.cpp
  367   assert(CompUnitCount > 0 && "Index must have at least one CU.");
  391   assert(AugmentationStringSize % 4 == 0);
  459     assert(Abbrev.first != 0);
  478   assert(AbbrevIt != Abbreviations.end() &&
  491       assert(AttrEnc.Form == dwarf::DW_FORM_ref4);
  562     assert(CU.index() == CU.value()->getUniqueID());
lib/CodeGen/AsmPrinter/AsmPrinter.cpp
  176   assert(GVAlign && "GVAlign must be set");
  192   assert(!DD && Handlers.empty() && "Debug/EH info didn't get finalized");
  226   assert(MF && "getSubtargetInfo requires a valid MachineFunction!");
  235   assert(DD && "Dwarf debug file is not defined.");
  236   assert(OutStreamer->hasRawTextSupport() && "Expected assembly output mode.");
  289   assert(MI && "AsmPrinter didn't require GCModuleInfo?");
  451   assert(!(IsEmuTLSVar && GV->hasCommonLinkage()) &&
  810     assert(Op.isReg() && "KILL instruction must have only register operands");
  882       assert(MI->getOperand(0).isFI() && "Unknown operand type");
 1310     assert(GIS.hasLocalLinkage() && "Invalid alias or ifunc linkage");
 1365     assert(!Filename->empty() && "The filename can't be empty.");
 1516   assert(MI && "AsmPrinter didn't require GCModuleInfo?");
 1579       assert(LU->hasInitializer() &&
 1581       assert(isa<ArrayType>(LU->getValueType()) &&
 1659     assert(TM.getTargetTriple().isOSAIX() && "Function descriptor is only"
 1661     assert(CurrentFnDescSym && "The function descriptor symbol needs to be"
 1865   assert(MBB && MBB->getNumber() >= 0 && "Invalid basic block");
 1918   assert(Value && "Unknown entry kind!");
 1941   assert(GV->hasInitializer() && "Not a special LLVM global!");
 2056       assert(N->getNumOperands() == 1 &&
 2078     assert(N->getNumOperands() == 1 &&
 2330   assert(!Data.empty() && "Empty aggregates should be CAZ node");
 2343     assert(Size % 8 == 0);
 2355     assert(CA->getNumOperands() != 0 && "Should be a CAZ");
 2409   assert(EmittedSize <= Size && "Size cannot be less than EmittedSize!");
 2469   assert(SizeSoFar == Layout->getSizeInBytes() &&
 2474   assert(ET && "Unknown float type");
 2570     assert(Size && Size * 8 >= ExtraBitsSize &&
 2875   assert(Header && "No header for loop");
 2906   assert(MF != nullptr && "Machine function must be valid");
 2963     assert(MLI != nullptr && "MachineLoopInfo should has been computed");
 3079   assert(MI && "AsmPrinter didn't require GCModuleInfo?");
 3116   assert(Padding >= 0 && "Instrumentation map entry > 4 * Word Size");
 3130     assert(Associated != nullptr);
lib/CodeGen/AsmPrinter/AsmPrinterDwarf.cpp
  173     assert(S.Symbol && "No symbol available");
  264     assert(V.getForm() && "Too many attributes for DIE (check abbreviation)");
lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
   47   assert(DiagInfo && "Diagnostic context not passed down?");
  113   assert(!Str.empty() && "Can't emit empty inline asm block");
  126   assert(MCAI && "No MCAsmInfo");
  469   assert(MI->isInlineAsm() && "printInlineAsm only works on inline asms");
  475     assert(NumDefs != MI->getNumOperands()-2 && "No asm string?");
  477   assert(MI->getOperand(NumDefs).isSymbol() && "No asm string?");
  604   assert(MO.isGlobal() && "caller should check MO.isGlobal");
lib/CodeGen/AsmPrinter/CodeViewDebug.cpp
  260     assert(Success && ".cv_file directive failed");
  360   assert(!isa<DIType>(Scope) && "shouldn't make a namespace scope for a type");
  375   assert(SP);
  442   assert(!SP->getDeclaration() && "should use declaration as key");
  467   assert(InsertResult.second && "DINode was already assigned a type index");
  561   assert(Asm != nullptr);
  696     assert(GHR.Hash.size() == 8);
  864     assert(TypeIndices.count({SP, nullptr}));
  886   assert(TypeIndices.count({Site.Inlinee, nullptr}));
  912     assert(I != FI.InlineSites.end() &&
  987   assert(Fn);
  994   assert(SP);
 1079       assert(I != FI.InlineSites.end() &&
 1096         assert(Str.data()[Str.size()] == '\0' && "non-nullterminated MDString");
 1135   assert(DR.DataOffset == Offset && "truncation");
 1152     assert(VI.Var->isValidLocationForIntrinsic(VI.Loc) &&
 1219     assert(DVInst->isDebugValue() && "Invalid History entry");
 1334   assert(Insertion.second && "function already has info");
 1571     assert(Element->getTag() == dwarf::DW_TAG_subrange_type);
 1574     assert(Subrange->getLowerBound() == 0 &&
 1769   assert(Ty->getTag() == dwarf::DW_TAG_ptr_to_member_type);
 1778   assert(Ty->getSizeInBits() / 8 <= 0xff && "pointer size too big");
 2116   assert(CurFn == nullptr);
 2138   assert((DDTy->getOffsetInBits() % 8) == 0 && "Unnamed bitfield member!");
 2341       assert(I->getOffsetInBits() % 8 == 0 &&
 2415     assert(!Methods.empty() && "Empty methods map entry");
 2478   assert(PtrTy->getTag() == dwarf::DW_TAG_pointer_type &&
 2678       assert(DefRange.DataOffset == 0 && "unexpected offset into register");
 2812   assert(Range.first && Range.second);
 2816   assert(Block.Begin && "missing label for scope begin");
 2817   assert(Block.End && "missing label for scope end");
 2832   assert(FnDebugInfo.count(&GV));
 2833   assert(CurFn == FnDebugInfo[&GV].get());
 2970     assert(shouldEmitUdt(T));
 3103     assert(DIE->isConstant() &&
lib/CodeGen/AsmPrinter/DIE.cpp
  199   assert(Unit && "DIE must be owned by a DIEUnit to get its absolute offset");
  297     assert(Abbrev.hasChildren() && "Children flag not set");
  321   assert((UnitTag == dwarf::DW_TAG_compile_unit ||
  514   assert(Offset < (1ULL << (ULEB128PadSize * 7)) && "Offset wont fit");
lib/CodeGen/AsmPrinter/DIEHash.cpp
   92   assert(Cur->getTag() == dwarf::DW_TAG_compile_unit ||
  176   assert(Tag != dwarf::DW_TAG_friend && "No current LLVM clients emit friend "
lib/CodeGen/AsmPrinter/DbgEntityHistoryCalculator.cpp
   42   assert(MI.isDebugValue());
   43   assert(MI.getNumOperands() == 4);
   58   assert(MI.isDebugValue() && "not a DBG_VALUE");
   87   assert(isDbgValue() && "Setting end index for non-debug value");
   88   assert(!isClosed() && "End index has already been set");
   93   assert(MI.isDebugLabel() && "not a DBG_LABEL");
  115   assert(RegNo != 0U && I != RegVars.end());
  118   assert(VarPos != VarSet.end());
  128   assert(RegNo != 0U);
  130   assert(!is_contained(VarSet, Var));
  146     assert(Entry.isDbgValue() && "Not a DBG_VALUE in LiveEntries");
  173       assert(Entry.isDbgValue() && "Not a DBG_VALUE in LiveEntries");
  243         assert(MI.getNumOperands() > 1 && "Invalid DBG_VALUE instruction!");
  248         assert(RawVar->isValidLocationForIntrinsic(MI.getDebugLoc()) &&
  254         assert(MI.getNumOperands() == 1 && "Invalid DBG_LABEL instruction!");
  256         assert(RawLabel->isValidLocationForIntrinsic(MI.getDebugLoc()) &&
  326           assert(Ent.isDbgValue() && !Ent.isClosed());
lib/CodeGen/AsmPrinter/DebugHandlerBase.cpp
  107       assert(R.first && "InsnRange does not have first instruction!");
  108       assert(R.second && "InsnRange does not have second instruction!");
  118   assert(Label && "Didn't insert label before instruction");
  136   assert(AfterInsn && "Expected label after instruction");
  144   assert(Ty);
  178   assert(SP->getUnit());
  205   assert(DbgValues.empty() && "DbgValues map wasn't cleaned!");
  206   assert(DbgLabels.empty() && "DbgLabels map wasn't cleaned!");
  283   assert(CurMI == nullptr);
  309   assert(CurMI != nullptr);
lib/CodeGen/AsmPrinter/DebugLocEntry.h
   57     assert(cast<DIExpression>(Expr)->isValid());
  130     assert((Values.size() == 1 || all_of(Values, [](DbgValueLoc V) {
lib/CodeGen/AsmPrinter/DebugLocStream.cpp
   36   assert(Lists.back().EntryOffset <= Entries.size() &&
lib/CodeGen/AsmPrinter/DebugLocStream.h
  129     assert(&Lists.front() <= &L && &L <= &Lists.back() &&
  134     assert(&Entries.front() <= &E && &E <= &Entries.back() &&
lib/CodeGen/AsmPrinter/DwarfCFIException.cpp
  147   assert(P && "Expected personality function");
lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
  119   assert(GV);
  135     assert(SDMDecl->isStaticMember() && "Expected static member decl");
  136     assert(GV->isDefinition());
  241           assert((PointerSize == 4 || PointerSize == 8) &&
  368   assert(Begin && "Begin label should not be null!");
  369   assert(End && "End label should not be null!");
  370   assert(Begin->isDefined() && "Invalid starting label");
  371   assert(End->isDefined() && "Invalid end label");
  421   assert((Scope->getInlinedAt() || !isa<DISubprogram>(DS)) &&
  458     assert(ScopeDIE && "Scope DIE should not be null.");
  524   assert(Scope->getScopeNode());
  530   assert(OriginDIE && "Unable to find original DIE for an inlined subprogram.");
  759       assert(false && "dependency cycle in local variables");
  777   assert(Children.empty());
  815     assert(!Scope->getInlinedAt());
  816     assert(!Scope->isAbstractScope());
  955     assert(CalleeDIE && "Could not create DIE for call site entry origin");
  967     assert(PCAddr && "Missing PC information for a call");
  970     assert(PCOffset && "Missing return PC information for a call");
 1019   assert(EntityDie);
 1036     assert(D || includeMinimalInlineScopes());
 1077   assert(Scope && Scope->isAbstractScope());
lib/CodeGen/AsmPrinter/DwarfCompileUnit.h
  166     assert(Scope && "Invalid Scope encoding!");
  292     assert(getSection());
lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  191   assert(Idx < (1ULL << (ULEB128PadSize * 7)) && "Idx wont fit");
  202   assert(!IsBuffering && "Already buffering?");
  234   assert(MI->getNumOperands() == 4);
  240     assert((!Op1.isImm() || (Op1.getImm() == 0)) && "unexpected offset");
  255   assert(FrameIndexExprs.empty() && "Already initialized?");
  256   assert(!ValueLoc.get() && "Already initialized?");
  258   assert(getVariable() == DbgValue->getDebugVariable() && "Wrong variable");
  259   assert(getInlinedAt() == DbgValue->getDebugLoc()->getInlinedAt() &&
  272   assert(llvm::all_of(FrameIndexExprs,
  287   assert(DebugLocListIndex == ~0U && !ValueLoc.get() && "not an MMI entry");
  288   assert(V.DebugLocListIndex == ~0U && !V.ValueLoc.get() && "not an MMI entry");
  289   assert(V.getVariable() == getVariable() && "conflicting variable");
  290   assert(V.getInlinedAt() == getInlinedAt() && "conflicting inlined-at location");
  292   assert(!FrameIndexExprs.empty() && "Expected an MMI entry");
  293   assert(!V.FrameIndexExprs.empty() && "Expected an MMI entry");
  312   assert((FrameIndexExprs.size() == 1 ||
  515   assert(Scope && Scope->getScopeNode());
  516   assert(Scope->isAbstractScope());
  517   assert(!Scope->getInlinedAt());
  562     assert(InsertedReg && "Single register used to forward two arguments?");
  704   assert(TII && "TargetInstrInfo not found: cannot label tail calls");
  758       assert((IsTail || PCOffset || PCAddr) &&
  942   assert(MMI->hasDebugInfo() == (NumDebugCUs > 0) &&
 1033     assert(Die);
 1038     assert(Unit);
 1045     assert(SP->getUnit()->getEmissionKind() != DICompileUnit::NoDebug);
 1168   assert(CurFn == nullptr);
 1169   assert(CurMI == nullptr);
 1270     assert(VI.Var->isValidLocationForIntrinsic(VI.Loc) &&
 1301   assert(DbgValue->getDebugLoc() && "DBG_VALUE without a debug location");
 1407     assert(StartLabel &&
 1420     assert(EndLabel && "Forgot label after instruction ending a range!");
 1539     assert(MInsn->isDebugValue() && "History must begin with debug value");
 1635   assert(CurMI);
 1783   assert(LScopes.empty() || SP == LScopes.getCurrentFunctionScope()->getScopeNode());
 1818   assert(CurFn == MF &&
 1825   assert(!FnScope || SP == FnScope->getScopeNode());
 1845     assert(InfoHolder.getScopeVariables().empty());
 1871       assert(LScopes.getAbstractScopesList().size() == NumAbstractScopes
 2153     assert(Op.getCode() != dwarf::DW_OP_const_type &&
 2163             assert(Offset < (1ULL << (ULEB128PadSize * 7)) && "Offset wont fit");
 2179     assert(Offset == Op.getEndOffset());
 2222   assert(!Values.empty() &&
 2224   assert(Begin != End && "unexpected location list entry with empty range");
 2231     assert(llvm::all_of(Values, [](DbgValueLoc P) {
 2234     assert(std::is_sorted(Values.begin(), Values.end()) &&
 2241     assert(Values.size() == 1 && "only fragments may have >1 value");
 2373       assert(!Base);
 2381       assert(Begin && "Range without a begin symbol?");
 2382       assert(End && "Range without an end symbol?");
 2519         assert(Cur.CU);
 2553         assert(Prev.CU);
 2671   assert(useRangesSection());
 2672   assert(llvm::none_of(CUMap, [](const decltype(CUMap)::value_type &Pair) {
 2690   assert(useSplitDwarf());
 2700   assert(getDwarfVersion() >= 5);
 2701   assert(useRangesSection());
 2702   assert(llvm::none_of(CUMap, [](const decltype(CUMap)::value_type &Pair) {
 2740   assert(F.getMacinfoType() == dwarf::DW_MACINFO_start_file);
 2812   assert(useSplitDwarf() && "No split dwarf debug info?");
 2820   assert(useSplitDwarf() && "No split dwarf?");
 2825   assert(useSplitDwarf() && "No split dwarf?");
 2832   assert(useSplitDwarf() && "No split dwarf?");
 2844   assert(useSplitDwarf() && "No split dwarf?");
 2966   assert(TypeUnitsUnderConstruction.empty() || !DD->AddrPool.hasBeenUsed());
lib/CodeGen/AsmPrinter/DwarfDebug.h
  141     assert(FrameIndexExprs.empty() && "Already initialized?");
  142     assert(!ValueLoc.get() && "Already initialized?");
  144     assert((!E || E->isValid()) && "Expected valid expression");
  145     assert(FI != std::numeric_limits<int>::max() && "Expected valid index");
  152     assert(FrameIndexExprs.empty() && "Already initialized?");
  153     assert(!ValueLoc && "Already initialized?");
  154     assert(!Value.getExpression()->isFragment() && "Fragments not supported.");
  171     assert(ValueLoc.get() && FrameIndexExprs.size() <= 1);
  211     assert(ValueLoc.get() && "Expected DBG_VALUE, not MMI variable");
  212     assert((FrameIndexExprs.empty() ||
  265     assert(Reg && "Parameter register cannot be undef");
lib/CodeGen/AsmPrinter/DwarfExpression.cpp
   43  assert(DwarfReg >= 0 && "invalid negative dwarf register number");
   44  assert((isUnknownLocation() || isRegisterLocation()) &&
   56   assert(DwarfReg >= 0 && "invalid negative dwarf register number");
   57   assert(!isRegisterLocation() && "location description already locked down");
  188   assert(isImplicitLocation() || isUnknownLocation());
  195   assert(isImplicitLocation() || isUnknownLocation());
  201   assert(isImplicitLocation() || isUnknownLocation());
  277   assert(DwarfRegs.size() == 1);
  281   assert(Reg.Size == 0 && "subregister has same size as superregister");
  323   assert(Op && Op->getOp() == dwarf::DW_OP_LLVM_entry_value);
  324   assert(!isMemoryLocation() &&
  326   assert(!IsEmittingEntryValue && "Already emitting entry value?");
  327   assert(Op->getArg(0) == 1 &&
  336   assert(IsEmittingEntryValue && "Entry value not open?");
  393       assert(OffsetInBits >= FragmentOffset && "fragment offset not added?");
  417       assert(!isRegisterLocation());
  438       assert(!isRegisterLocation());
  440       assert(!isParameterValue() && "Parameter entry values should not be "
  450       assert(!isRegisterLocation());
  493       assert(!isRegisterLocation());
  497       assert(!isRegisterLocation());
  528   assert(SubRegisterSizeInBits && "no subregister was registered");
  536   assert(DwarfRegs.size() == 0 && "dwarf registers not emitted");
  551   assert(FragmentOffset >= OffsetInBits &&
lib/CodeGen/AsmPrinter/DwarfExpression.h
   42       assert(Start == End);
  170     assert(SizeInBits < 65536 && OffsetInBits < 65536);
  292     assert(isUnknownLocation());
lib/CodeGen/AsmPrinter/DwarfStringPool.cpp
   36     assert(NumBytes > Entry.Offset && "Unexpected overflow");
   98     assert(ShouldCreateSymbols == static_cast<bool>(Entry->getValue().Symbol) &&
lib/CodeGen/AsmPrinter/DwarfUnit.cpp
   74   assert(!IsBuffering && "Already buffering?");
  236   assert(Form != dwarf::DW_FORM_implicit_const &&
  312   assert(File);
  426   assert(V);
  432   assert(G);
  438   assert(SP);
  444   assert(L);
  450   assert(Ty);
  456   assert(Ty);
  486     assert(T == dwarf::DW_TAG_typedef || T == dwarf::DW_TAG_const_type ||
  489     assert(DTy->getBaseType() && "Expected valid base type");
  495   assert((Encoding == dwarf::DW_ATE_unsigned ||
  511   assert(MO.isFPImm() && "Invalid machine operand!");
  544   assert(MO.isImm() && "Invalid machine operand!");
  698   assert(ContextDIE);
  727   assert(Ty && "Trying to add a type that doesn't exist?");
  829       assert(i == N-1 && "Unspecified parameter must be the last argument");
 1069       assert(isa<MDString>(Val));
 1161     assert(DeclDie && "This DIE should've already been constructed when the "
 1181   assert(((LinkageName.empty() || DeclLinkageName.empty()) ||
 1355   assert(CTy && CTy->isVector() && "Composite type is not a vector");
 1360   assert(BaseTy && "Unknown vector element type.");
 1365   assert(Elements.size() == 1 &&
 1374   assert(ActualSize >= (NumVecElements * ElementSize) && "Invalid vector size");
 1564   assert(dwarf::isType(ContextDIE->getTag()) &&
 1709   assert(DD->getDwarfVersion() >= 5 &&
lib/CodeGen/AsmPrinter/EHStreamer.cpp
  118         assert(Actions.size());
  124           assert(PrevAction != (unsigned)-1 && "PrevAction is invalid!");
  134         assert(-1 - TypeID < (int)FilterOffsets.size() && "Unknown filter id!");
  169   assert(MI->isCall() && "This should be a call instruction!");
  210       assert(!PadMap.count(BeginLabel) && "Duplicate landing pad labels!");
  264       assert(BeginLabel == LandingPad->BeginLabels[P.RangeIndex] &&
  278       assert(BeginLabel && LastLabel && "Invalid landing pad!");
lib/CodeGen/AsmPrinter/WasmException.cpp
   55   assert(LSDALabel && ".GCC_exception_table has not been emitted!");
lib/CodeGen/AsmPrinter/WinException.cpp
  174   assert(MBB->isEHFuncletEntry());
  344     assert(UnusedReg ==
  353   assert(FuncInfo.EHRegNodeEndOffset != INT_MAX);
  405     assert(Begin != End);
  415     assert(BaseState == O.BaseState);
  513     assert(CurrentEndLabel != nullptr);
  626   assert(BeginLabel && EndLabel);
  653     assert(UME.ToState < State && "states should decrease");
  791       assert(0 <= TBME.TryLow && "bad trymap interval");
  792       assert(TBME.TryLow <= TBME.TryHigh && "bad trymap interval");
  793       assert(TBME.TryHigh < TBME.CatchHigh && "bad trymap interval");
  794       assert(TBME.CatchHigh < int(FuncInfo.CxxUnwindMap.size()) &&
  840           assert(Offset != 0 && "Illegal offset for catch object!");
  913       assert(FuncInfo.FuncletBaseStateMap.count(FuncletPad) != 0);
  917     assert(StartLabel && "need local function start label");
 1041   assert(!FuncInfo.SEHUnwindMap.empty());
 1110   assert(NumStates > 0 && "Don't need exception table!");
 1119     assert(FuncInfo.ClrEHUnwindMap[State].HandlerParentState < State &&
 1177     assert(HandlerStack.empty());
 1184         assert(CurrentState != NullState &&
 1216     assert(HandlerStack.empty());
 1299       assert(Clause.EnclosingState > MinClauseMap[Clause.State]);
 1313     assert(Entry.HandlerType != ClrHandlerType::Filter && "NYI: filters");
lib/CodeGen/AtomicExpandPass.cpp
  160   assert(Align != 0 && "An atomic LoadInst always has an explicit alignment");
  169   assert(Align != 0 && "An atomic StoreInst always has an explicit alignment");
  223     assert((LI || SI || RMWI || CASI) && "Unknown atomic instruction");
  288         assert(LI->getType()->isIntegerTy() && "invariant broken");
  298         assert(SI->getValueOperand()->getType()->isIntegerTy() &&
  329       assert(!CASI->getCompareOperand()->getType()->isFloatingPointTy() &&
  335         assert(CASI->getCompareOperand()->getType()->isIntegerTy() &&
  365   assert(BitWidth == VT.getSizeInBits() && "must be a power of two");
  652   assert(ValueSize < WordSize);
  744   assert(ExpansionKind == TargetLoweringBase::AtomicExpansionKind::CmpXChg);
  779   assert((Op == AtomicRMWInst::Or || Op == AtomicRMWInst::Xor ||
 1287     assert(EV->getNumIndices() == 1 && EV->getIndices()[0] <= 1 &&
 1397   assert(Success && NewLoaded);
 1419     assert(ValueSize >= MinCASSize &&
 1477   assert(expanded && "expandAtomicOpToLibcall shouldn't fail tor Load");
 1491   assert(expanded && "expandAtomicOpToLibcall shouldn't fail tor Store");
 1507   assert(expanded && "expandAtomicOpToLibcall shouldn't fail tor CAS");
 1613   assert(Libcalls.size() == 6);
 1629   assert(Ordering != AtomicOrdering::NotAtomic && "expect atomic MO");
 1634     assert(Ordering2 != AtomicOrdering::NotAtomic && "expect atomic MO");
lib/CodeGen/BranchFolding.cpp
  154   assert(MBB->pred_empty() && "MBB must be dead!");
  436       assert(P.LaneMask == LaneBitmask::getAll() &&
  648     assert(EHScope1 != EHScopeMembership.end());
  650     assert(EHScope2 != EHScopeMembership.end());
  856     assert(MBBI != MBBIE && "Reached BB end within common tail length!");
  867     assert(MBBICommon != MBBIECommon &&
  869     assert(MBBICommon->isIdenticalTo(*MBBI) && "Expected matching MIIs!");
  898       assert(SameTails[i].getTailStartPos() == MBB->begin() &&
  912       assert(Pos != SameTails[i].getBlock()->end() &&
  916         assert(Pos != SameTails[i].getBlock()->end() &&
  919       assert(MI.isIdenticalTo(*Pos) && "Expected matching MIIs!");
 1305   assert(I != MBB->end() && "empty block!");
 1315   assert(MBB1 && MBB2 && "Unknown MachineBasicBlock");
 1376   assert(IsEmptyBlock(&MBB) && "Expected an empty block (except debug info).");
 1402     assert(MBBEHScope != EHScopeMembership.end());
 1404     assert(FallThroughEHScope != EHScopeMembership.end());
 1498       assert(PrevBB.succ_empty());
 1677               assert(PriorCond.empty() && !PriorFBB &&
 1681               assert(!PriorFBB && "Machine CFG out of date!");
lib/CodeGen/BranchRelaxation.cpp
  131     assert(isAligned(MBB.getAlignment(), BlockInfo[Num].Offset));
  132     assert(!Num || BlockInfo[PrevNum].postOffset(MBB) <= BlockInfo[Num].Offset);
  133     assert(BlockInfo[Num].Size == computeBlockSize(MBB));
  188     assert(I != MBB->end() && "Didn't find MI in its own basic block?");
  340   assert(!Fail && "branches to be relaxed must be analyzable");
  447   assert(!TII->isBranchOffsetInRange(MI.getOpcode(), DestOffset - SrcOffset));
lib/CodeGen/BreakFalseDeps.cpp
  110   assert(MO.isUndef() && "Expected undef machine operand");
  178   assert(!MI->isDebugInstr() && "Won't process debug values");
lib/CodeGen/CalcSpillWeights.cpp
  100     assert(MI && "Dead valno in interval");
  124         assert(VNI && "Copy from non-existing value");
  128         assert(MI && "Dead valno in interval");
  174     assert(localMBB == LIS.getMBBFromIndex(*start) &&
lib/CodeGen/CallingConvLower.cpp
  225   assert(NumLocs < Locs.size() && "CC assignment failed to add location");
lib/CodeGen/CodeGenPrepare.cpp
  830       assert(SinglePred == BB &&
  950     assert(ToReplace->getBasePtrIndex() == RelocatedBase->getBasePtrIndex() &&
  975     assert(RelocatedBase->getNextNode() &&
 1113       assert(InsertPt != UserBB->end());
 1201     assert(isa<Constant>(Arg1) && "Unexpected input for usubo");
 1213   assert(InsertPt != nullptr && "Parent block did not contain cmp or binop");
 1387       assert(InsertPt != UserBB->end());
 1434   assert(!InsertedInsts.count(AndI) &&
 1567       assert(InsertPt != TruncUserBB->end());
 1580       assert(TruncInsertPt != TruncUserBB->end());
 1668       assert(InsertPt != UserBB->end());
 2173       assert(BaseReg == nullptr);
 2191       assert(ScaledReg == nullptr);
 2814     (void)Success; assert(Success && "Couldn't select *anything*?");
 2954   assert(CurrentIndex < Set->NodeList.size() &&
 2960   assert(CurrentIndex < Set->NodeList.size() &&
 3035     assert(To && Get(To) == To && "Replacement PHI node is already replaced.");
 3211     assert(CommonType && "At least one non-null value must be!");
 3385       assert(Map.find(Current) != Map.end() && "No node to fill!!!");
 3392         assert(Map.find(TrueValue) != Map.end() && "No True Value!");
 3395         assert(Map.find(FalseValue) != Map.end() && "No False Value!");
 3403           assert(Map.find(PV) != Map.end() && "No predecessor Value!");
 3420     assert((isa<PHINode>(Original) || isa<SelectInst>(Original)) &&
 3823   assert((isa<SExtInst>(Ext) || isa<ZExtInst>(Ext)) &&
 4275     assert(PromotedOperand &&
 4614     (void)Success; assert(Success && "Couldn't select *anything*?");
 4867           assert(cast<IntegerType>(IntPtrTy)->getBitWidth() <
 5059   assert(!Val->use_empty() && "Input must have at least one use");
 5151     assert(PromotedVal &&
 5481     assert(LI && ExtFedByLoad && "Expect a valid load and extension");
 5636       assert(InsertPt != UserBB->end());
 5889     assert(DefSI->getCondition() == SI->getCondition() &&
 5894   assert(V && "Failed to get select true/false value");
 5899   assert(Shift->isShift() && "Expected a shift");
 6046     assert(TrueBlock == nullptr &&
 6148       assert(InsertPt != UserBB->end());
 6321     assert(isa<ExtractElementInst>(Transition) &&
 6330     assert(isa<ExtractElementInst>(Transition) &&
 6468     assert(Transition && "Do not know how to promote null");
 6517     assert(canCombine(ToBeCombined) && "Unsupported instruction to combine");
 6554   assert(ToBePromoted->getType() == Transition->getType() &&
 6915   assert(find_if(GEPIOp->users(), [&](User *Usr) {
lib/CodeGen/CriticalAntiDepBreaker.cpp
  117   assert(Count < InsertPosIndex && "Instruction index out of expected range!");
  256   assert(!MI.isKill() && "Attempting to scan a kill instruction");
  412     assert(((KillIndices[AntiDepReg] == ~0u) != (DefIndices[AntiDepReg] == ~0u))
  414     assert(((KillIndices[NewReg] == ~0u) != (DefIndices[NewReg] == ~0u))
  460   assert(Max && "Failed to find bottom of the critical path");
  561           assert(AntiDepReg != 0 && "Anti-dependence on reg0?");
  631     assert((AntiDepReg == 0 || RC != nullptr) &&
  673         assert(((KillIndices[NewReg] == ~0u) !=
  680         assert(((KillIndices[AntiDepReg] == ~0u) !=
lib/CodeGen/DFAPacketizer.cpp
   67   assert((InsnClass.size() <= DFA_MAX_RESTERMS) &&
   93     assert((i++ < DFA_MAX_RESTERMS) && "Exceeded maximum number of DFA inputs");
  135   assert(!NfaPaths.empty() && "Invalid bundle!");
  233   assert(VLIWScheduler && "VLIW Scheduler is not initialized!");
  274     assert(SUI && "Missing SUnit Info!");
  290         assert(SUJ && "Missing SUnit Info!");
lib/CodeGen/DetectDeadLanes.cpp
  156   assert(lowersToCopies(MI));
  233   assert(lowersToCopies(MI) &&
  241     assert(OpNum % 2 == 1);
  261     assert(OpNum == 1);
  265     assert(OpNum == 1);
  327       assert(OpNum == 1 && "INSERT_SUBREG must have two operands");
  335     assert(OpNum == 1 && "EXTRACT_SUBREG must have one register operand only");
  346   assert(Def.getSubReg() == 0 &&
  390         assert(Register::isVirtualRegister(MOReg));
  412   assert(Def.getSubReg() == 0 &&
  429       assert(UseMI.getDesc().getNumDefs() == 1);
lib/CodeGen/EarlyIfConversion.cpp
  518     assert(Register::isVirtualRegister(PI.TReg) && "Bad PHI");
  519     assert(Register::isVirtualRegister(PI.FReg) && "Bad PHI");
  560   assert(Tail->pred_size() == 2 && "Cannot replace PHIs");
  562   assert(FirstTerm != Head->end() && "No terminators");
  582   assert(FirstTerm != Head->end() && "No terminators");
  625   assert(Head && Tail && TBB && FBB && "Call canConvertIf first.");
  675   assert(Head->succ_empty() && "Additional head successors?");
  757     assert(Node != HeadNode && "Cannot erase the head node");
  759       assert(Node->getBlock() == IfConv.Tail && "Unexpected children");
lib/CodeGen/ExecutionDomainFix.cpp
   20   assert(Reg < AliasMap.size() && "Invalid register");
   30   assert(dv->Refs == 0 && "Reference count wasn't cleared");
   31   assert(!dv->Next && "Chained DomainValue shouldn't have been recycled");
   37     assert(DV->Refs && "Bad DomainValue");
   71   assert(unsigned(rx) < NumRegs && "Invalid index");
   72   assert(!LiveRegs.empty() && "Must enter basic block first.");
   82   assert(unsigned(rx) < NumRegs && "Invalid index");
   83   assert(!LiveRegs.empty() && "Must enter basic block first.");
   92   assert(unsigned(rx) < NumRegs && "Invalid index");
   93   assert(!LiveRegs.empty() && "Must enter basic block first.");
  103       assert(LiveRegs[rx] && "Not live after collapse?");
  113   assert(dv->hasDomain(domain) && "Cannot collapse");
  128   assert(!A->isCollapsed() && "Cannot merge into collapsed");
  129   assert(!B->isCollapsed() && "Cannot merge from collapsed");
  145     assert(!LiveRegs.empty() && "no space allocated for live registers");
  170     assert(unsigned(pred->getNumber()) < MBBOutRegsInfos.size() &&
  210   assert(!LiveRegs.empty() && "Must enter basic block first.");
  212   assert(MBBNumber < MBBOutRegsInfos.size() &&
  236   assert(!MI->isDebugInstr() && "Won't process debug values");
  331     assert(!LiveRegs.empty() && "no space allocated for live registers");
  355       assert(dv->AvailableDomains && "Domain should have been filtered");
  368       assert(!LiveRegs.empty() && "no space allocated for live registers");
  420   assert(NumRegs == RC->getNumRegs() && "Bad regclass");
lib/CodeGen/ExpandMemCmp.cpp
  166   assert(NumNonOverlappingLoads && "there must be at least one load");
  188   assert(Size > 0 && Size < MaxLoadSize && "broken invariant");
  209   assert(Size > 0 && "zero blocks");
  215   assert(!LoadSizes.empty() && "cannot load Size bytes");
  222   assert(LoadSequence.size() <= Options.MaxNumLoads && "broken invariant");
  237   assert(LoadSequence.size() <= Options.MaxNumLoads && "broken invariant");
  316   assert(LoadIndex < getNumLoads() &&
  397     assert(Diff && "Failed to find comparison diff");
  446   assert(CurLoadEntry.LoadSize <= MaxLoadSize && "Unexpected load type");
  559   assert(LoadIndex == getNumLoads() && "some entries were not consumed");
lib/CodeGen/ExpandPostRAPseudos.cpp
   77   assert((MI->getOperand(0).isReg() && MI->getOperand(0).isDef()) &&
   84   assert(!MI->getOperand(2).getSubReg() && "SubIdx on physreg?");
   87   assert(SubIdx != 0 && "Invalid index for insert_subreg");
   90   assert(Register::isPhysicalRegister(DstReg) &&
   92   assert(Register::isPhysicalRegister(InsReg) &&
lib/CodeGen/FuncletLayout.cpp
   54     assert(FuncletX != FuncletMembership.end());
   55     assert(FuncletY != FuncletMembership.end());
lib/CodeGen/GCMetadata.cpp
   67   assert(!F.isDeclaration() && "Can only get GCFunctionInfo for a definition!");
   68   assert(F.hasGC());
  141   assert(GMI && "Printer didn't require GCModuleInfo?!");
lib/CodeGen/GCRootLowering.cpp
  107   assert(MI && "LowerIntrinsics didn't require GCModuleInfo!?");
  291   assert(TFI && "TargetRegisterInfo not available!");
lib/CodeGen/GlobalISel/CSEInfo.cpp
   97   assert(Removed && "Invalidation called on invalid UMI");
  119   assert(UMI);
  129   assert(InstrMapping.count(UMI->MI) == 0 &&
  135   assert(shouldCSE(MI->getOpcode()) && "Trying to CSE an unsupported Node");
  141   assert(MI);
  177   assert(shouldCSE(MI->getOpcode()) && "Invalid instruction for CSE");
  217   assert(CSEOpt.get() && "CSEConfig not set");
  348     assert(!MO.isImplicit() && "Unhandled case");
lib/CodeGen/GlobalISel/CSEMIRBuilder.cpp
   24   assert(A->getParent() == B->getParent() &&
   37   assert(CSEInfo && "Can't get here without setting CSEInfo");
  107   assert(canPerformCSEForOpc(MIB->getOpcode()) &&
  127   assert(checkCopyToDefsPossible(DstOps) &&
  158     assert(SrcOps.size() == 2 && "Invalid sources");
  159     assert(DstOps.size() == 1 && "Invalid dsts");
  166     assert(DstOps.size() == 1 && "Invalid dst ops");
  167     assert(SrcOps.size() == 2 && "Invalid src ops");
lib/CodeGen/GlobalISel/CallLowering.cpp
  128   assert(SrcRegs.size() > 1 && "Nothing to pack");
  138   assert(LLTs.size() == SrcRegs.size() && "Regs / types mismatch");
  154   assert(DstRegs.size() > 1 && "Nothing to unpack");
  161   assert(LLTs.size() == DstRegs.size() && "Regs / types mismatch");
  261         assert(Unmerge->getNumOperands() == NumParts + 1);
  286     assert(j < ArgLocs.size() && "Skipped too many arg locs");
  289     assert(VA.getValNo() == i && "Location doesn't correspond to current arg");
  309           assert((j + (NumArgRegs - 1)) < ArgLocs.size() &&
  343         assert((j + (Args[i].Regs.size() - 1)) < ArgLocs.size() &&
lib/CodeGen/GlobalISel/CombinerHelper.cpp
   57   assert(FromRegOp.getParent() && "Expected an operand in an MI");
  104   assert(MI.getOpcode() == TargetOpcode::G_CONCAT_VECTORS &&
  118     assert(Def && "Operand not defined");
  138       assert(MRI.getType(Undef->getOperand(0).getReg()) ==
  187   assert(MI.getOpcode() == TargetOpcode::G_SHUFFLE_VECTOR &&
  372   assert(LoadValue.isReg() && "Result wasn't a register?");
  417   assert(Preferred.Ty != LoadValueTy && "Extending to same type?");
  534   assert(DefMI.getParent() == UseMI.getParent());
  562   assert(Opcode == TargetOpcode::G_LOAD || Opcode == TargetOpcode::G_SEXTLOAD ||
  629   assert(Opcode == TargetOpcode::G_LOAD || Opcode == TargetOpcode::G_SEXTLOAD ||
  758   assert(std::next(BrIt) == MBB->end() && "expected G_BR to be a terminator");
  839     assert(Ty.getSizeInBits() > 0 && "Could not find valid type");
  855       assert(NewTySize > 0 && "Could not find appropriate type");
  915   assert(ExtType == Ty && "Vector memset value type not supported yet");
  927   assert(KnownLen != 0 && "Have a zero length memset length!");
  993       assert(I == MemOps.size() - 1 && I != 0);
 1041   assert(KnownLen != 0 && "Have a zero length memcpy length!");
 1149   assert(KnownLen != 0 && "Have a zero length memmove length!");
 1250   assert(MI.getOpcode() == TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS);
 1252   assert((ID == Intrinsic::memcpy || ID == Intrinsic::memmove ||
 1270     assert(MMOIt != MI.memoperands_end() && "Expected a second MMO on MI");
lib/CodeGen/GlobalISel/GISelKnownBits.cpp
  355     assert(SrcBitWidth && "SrcBitWidth can't be zero");
  365   assert(!Known.hasConflict() && "Bits known to be one AND zero?");
lib/CodeGen/GlobalISel/IRTranslator.cpp
  133     assert(getCurrentInst() && "Inserted instruction without a current MI");
  143     assert((CurrInst->getDebugLoc() == MI.getDebugLoc() ||
  162   assert(!VMap.contains(Val) && "Value already allocated in VMap");
  185   assert(Val.getType()->isSized() &&
  207     assert(SplitTys.size() == 1 && "unexpectedly split LLT");
  278   assert(MBB && "BasicBlock was not encountered before");
  283   assert(NewPred && "new predecessor must be a real MachineBasicBlock");
  354     assert(CI && "Instruction should be CmpInst");
  444     assert(Succ && "Could not find successor mbb in mapping");
  489   assert(!Clusters.empty());
  510   assert(JT.Reg != -1U && "Should lower JT Header first!");
  593     assert(CB.PredInfo.Pred == CmpInst::ICMP_SLE &&
  877     assert(Regs.size() == 1 && "swifterror should be single pointer");
  919     assert(Vals.size() == 1 && "swifterror should be single pointer");
 1319     assert(DI.getVariable() && "Missing variable");
 1327     assert(DI.getVariable()->isValidLocationForIntrinsic(
 1346     assert(DI.getLabel() && "Missing label");
 1348     assert(DI.getLabel()->isValidLocationForIntrinsic(
 1375     assert(DI.getVariable()->isValidLocationForIntrinsic(
 1554       assert(SwiftInVReg == 0 && "Expected only one swift error argument");
 1576     assert(!HasTailCall && "Can't tail call return twice from block?");
 1610   assert(ID != Intrinsic::not_intrinsic && "unknown intrinsic");
 1637         assert(CI->getBitWidth() <= 64 &&
 1761   assert(Tys.size() == 2 && "Only two-valued landingpads are supported");
 1840   assert(MF->getFrameInfo().hasVarSizedObjects());
 2252   assert(PendingPHIs.empty() && "stale PHIs");
 2305       assert(VRegs.size() == 1 && "Too many vregs for Swift error");
 2379   assert(EntryBB->succ_size() == 1 &&
 2383   assert(NewEntryBB.pred_size() == 1 &&
 2400   assert(&MF->front() == &NewEntryBB &&
lib/CodeGen/GlobalISel/InstructionSelect.cpp
   78   assert(ISel && "Cannot work without InstructionSelector");
lib/CodeGen/GlobalISel/Legalizer.cpp
  217     assert(RetryList.empty() && "Expected no instructions in RetryList");
  221       assert(isPreISelGenericOpcode(MI.getOpcode()) && "Expecting generic opcode");
  260       assert(isPreISelGenericOpcode(MI.getOpcode()) && "Expecting generic opcode");
lib/CodeGen/GlobalISel/LegalizerHelper.cpp
   42   assert(!LeftoverTy.isValid() && "this is an out argument");
   48   assert(Size > NarrowSize);
  134   assert(!LeftoverTy.isValid() && "this is an out argument");
  177     assert(OrigTy.getElementType() == TargetTy.getElementType());
  184     assert(OrigTy.getElementType() == TargetTy);
  188   assert(!OrigTy.isVector() && !TargetTy.isVector());
  201     assert(LeftoverRegs.empty());
  243     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  255     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  267     assert((Size == 32 || Size == 64) && "Unsupported size");
  270     assert((Size == 32 || Size == 64) && "Unsupported size");
  273     assert(Size == 32 && "Unsupported size");
  276     assert((Size == 32 || Size == 64) && "Unsupported size");
  279     assert((Size == 32 || Size == 64) && "Unsupported size");
  282     assert((Size == 32 || Size == 64) && "Unsupported size");
  285     assert((Size == 32 || Size == 64) && "Unsupported size");
  288     assert((Size == 32 || Size == 64) && "Unsupported size");
  291     assert((Size == 32 || Size == 64) && "Unsupported size");
  298     assert((Size == 32 || Size == 64) && "Unsupported size");
  301     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  305     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  309     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  313     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  317     assert((Size == 32 || Size == 64 || Size == 128) && "Unsupported size");
  321     assert((Size == 32 || Size == 64) && "Unsupported size");
  324     assert((Size == 32 || Size == 64) && "Unsupported size");
  394   assert(MI.getOpcode() == TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS);
  445     assert(Info.IsTailCall && "Lowered tail call when it wasn't a tail call?");
  448     assert(MI.getNextNode() && MI.getNextNode()->isReturn() &&
 1048         assert(PartialExtensionReg &&
 1183       assert(MRI.getType(SrcReg) == LLT::scalar(PartSize));
 1556       assert(TypeIdx == 1);
 1587       assert(TypeIdx == 1);
 1704     assert(!LosesInfo && "extend should always be lossless");
 1752     assert(TypeIdx == 1 && "unable to legalize pointer of GEP");
 1759     assert(TypeIdx == 0 && "Expecting only Idx 0");
 1852     assert(TypeIdx == 0);
 2260     assert(MI.getOperand(2).isImm() && "Expected immediate");
 2476       assert(NewInsts.size() == PartRegs.size() + LeftoverRegs.size());
 2631   assert(TypeIdx == 0 || CondTy.isVector());
 2801   assert(TypeIdx == 0 && "not a vector type index");
 3243   assert(TypeIdx == 0 && "Expecting only Idx 0");
 3577   assert(DstRegs.size() == (unsigned)NumParts && "not all parts covered");
 3593   assert(MI.getNumOperands() == 3 && TypeIdx == 0);
 3797   assert(MRI.getType(Src) == S64 && MRI.getType(Dst) == S32);
 4121     assert(Mask.size() == 1 && "Expected a single mask element");
lib/CodeGen/GlobalISel/LegalizerInfo.cpp
  193       assert(mutationIsSane(Rule, Query, Mutation) &&
  195       assert(hasNoSimpleLoops(Rule, Query, Mutation) && "Simple loop detected");
  285   assert(TablesInitialized == false);
  351           assert(BitsizeAndAction.first % ElementSize == 0);
  380   assert(TablesInitialized && "backend forgot to call computeTables");
  385   assert(Aspect.Type.isVector());
  393   assert(TypeIdx < MI.getNumOperands() && "Unexpected TypeIdx");
  403   assert(Opcode >= FirstOp && Opcode <= LastOp && "Unsupported opcode");
  413     assert(RulesForOpcode[OpcodeIdx].getAlias() == 0 && "Cannot chain aliases");
  428   assert(!Result.isAliasedByAnother() && "Modifying this opcode will modify aliases");
  436   assert(!llvm::empty(Opcodes) && Opcodes.begin() + 1 != Opcodes.end() &&
  449   assert(OpcodeTo != OpcodeFrom && "Cannot alias to self");
  450   assert(OpcodeTo >= FirstOp && OpcodeTo <= LastOp && "Unsupported opcode");
  564   assert(Size >= 1);
  570   assert(It != Vec.begin() && "Does Vec not start with size 1?");
  620   assert(Aspect.Type.isScalar() || Aspect.Type.isPointer());
  649   assert(Aspect.Type.isVector());
lib/CodeGen/GlobalISel/Localizer.cpp
  122     assert(MI.getDesc().getNumDefs() == 1 &&
  200     assert(II != MBB.end() && "Didn't find the user in the MBB");
lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
   39   assert(&getMF() == MBB.getParent() &&
   44   assert(MI.getParent() && "Instruction is not part of a basic block");
   53   assert(MBB.getParent() == &getMF() &&
   92   assert(isa<DILocalVariable>(Variable) && "not a variable");
   93   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
   94   assert(
  105   assert(isa<DILocalVariable>(Variable) && "not a variable");
  106   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
  107   assert(
  122   assert(isa<DILocalVariable>(Variable) && "not a variable");
  123   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
  124   assert(
  141   assert(isa<DILocalVariable>(Variable) && "not a variable");
  142   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
  143   assert(
  163   assert(isa<DILabel>(Label) && "not a label");
  164   assert(cast<DILabel>(Label)->isValidLocationForIntrinsic(State.DL) &&
  174   assert(Res.getLLTTy(*getMRI()).isPointer() && "expected ptr dst type");
  184   assert(Res.getLLTTy(*getMRI()).isPointer() && "invalid operand type");
  193   assert(Res.getLLTTy(*getMRI()).isPointer() && "invalid operand type");
  194   assert(Res.getLLTTy(*getMRI()).getAddressSpace() ==
  212   assert((Res.isScalar() || Res.isVector()) && "invalid operand type");
  213   assert((Res == Op0 && Res == Op1) && "type mismatch");
  218   assert((Res.isScalar() || Res.isVector()) && "invalid operand type");
  219   assert((Res == Op0) && "type mismatch");
  225   assert(Res.getLLTTy(*getMRI()).isPointer() &&
  227   assert(Op1.getLLTTy(*getMRI()).isScalar() && "invalid offset type");
  235   assert(Res == 0 && "Res is a result argument");
  236   assert(ValueTy.isScalar()  && "invalid offset type");
  251   assert(Res.getLLTTy(*getMRI()).isPointer() &&
  266   assert(getMRI()->getType(Tgt).isPointer() && "invalid branch destination");
  273   assert(getMRI()->getType(TablePtr).isPointer() &&
  290   assert(EltTy.getScalarSizeInBits() == Val.getBitWidth() &&
  319   assert(APFloat::getSizeInBits(Val.getValueAPF().getSemantics())
  323   assert(!Ty.isPointer() && "invalid operand type");
  363   assert(getMRI()->getType(Tst).isScalar() && "invalid operand type");
  378   assert(Res.getLLTTy(*getMRI()).isValid() && "invalid operand type");
  379   assert(Addr.getLLTTy(*getMRI()).isPointer() && "invalid operand type");
  391   assert(Val.getLLTTy(*getMRI()).isValid() && "invalid operand type");
  392   assert(Addr.getLLTTy(*getMRI()).isPointer() && "invalid operand type");
  454   assert((TargetOpcode::G_ANYEXT == ExtOpc || TargetOpcode::G_ZEXT == ExtOpc ||
  457   assert(Res.getLLTTy(*getMRI()).isScalar() ||
  459   assert(Res.getLLTTy(*getMRI()).isScalar() ==
  470     assert(Res.getLLTTy(*getMRI()) == Op.getLLTTy(*getMRI()));
  503     assert(!SrcTy.isPointer() && !DstTy.isPointer() && "n G_ADDRCAST yet");
  517   assert(SrcTy.isValid() && "invalid operand type");
  518   assert(DstTy.isValid() && "invalid operand type");
  519   assert(Index + DstTy.getSizeInBits() <= SrcTy.getSizeInBits() &&
  524     assert(Index == 0 && "insertion past the end of a register");
  538   assert(Ops.size() == Indices.size() && "incompatible args");
  539   assert(!Ops.empty() && "invalid trivial sequence");
  540   assert(std::is_sorted(Indices.begin(), Indices.end()) &&
  543   assert(getMRI()->getType(Res).isValid() && "invalid operand type");
  545     assert(getMRI()->getType(Op).isValid() && "invalid operand type");
  586   assert(TmpVec.size() > 1);
  596   assert(TmpVec.size() > 1);
  615   assert(TmpVec.size() > 1);
  655   assert(Index + getMRI()->getType(Op).getSizeInBits() <=
  752   assert(OldValResTy.isScalar() && "invalid operand type");
  753   assert(SuccessResTy.isScalar() && "invalid operand type");
  754   assert(AddrTy.isPointer() && "invalid operand type");
  755   assert(CmpValTy.isValid() && "invalid operand type");
  756   assert(NewValTy.isValid() && "invalid operand type");
  757   assert(OldValResTy == CmpValTy && "type mismatch");
  758   assert(OldValResTy == NewValTy && "type mismatch");
  779   assert(OldValResTy.isScalar() && "invalid operand type");
  780   assert(AddrTy.isPointer() && "invalid operand type");
  781   assert(CmpValTy.isValid() && "invalid operand type");
  782   assert(NewValTy.isValid() && "invalid operand type");
  783   assert(OldValResTy == CmpValTy && "type mismatch");
  784   assert(OldValResTy == NewValTy && "type mismatch");
  804   assert(OldValResTy.isScalar() && "invalid operand type");
  805   assert(AddrTy.isPointer() && "invalid operand type");
  806   assert(ValTy.isValid() && "invalid operand type");
  807   assert(OldValResTy == ValTy && "type mismatch");
  808   assert(MMO.isAtomic() && "not atomic mem operand");
  912   assert(getMRI()->getType(Res).isPointer() && "invalid res type");
  922     assert(SrcTy.isVector() && "mismatched cast between vector and non-vector");
  923     assert(SrcTy.getNumElements() == DstTy.getNumElements() &&
  926     assert(DstTy.isScalar() && SrcTy.isScalar() && "invalid extend/trunc");
  929     assert(DstTy.getSizeInBits() > SrcTy.getSizeInBits() &&
  932     assert(DstTy.getSizeInBits() < SrcTy.getSizeInBits() &&
  940   assert((ResTy.isScalar() || ResTy.isVector() || ResTy.isPointer()) &&
  942   assert((ResTy == Op0Ty && ResTy == Op1Ty) && "type mismatch");
  944     assert(TstTy.isScalar() && "type mismatch");
  946     assert((TstTy.isScalar() ||
  961     assert(DstOps.size() == 1 && "Invalid select");
  962     assert(SrcOps.size() == 3 && "Invalid select");
  983     assert(DstOps.size() == 1 && "Invalid Dst");
  984     assert(SrcOps.size() == 2 && "Invalid Srcs");
  993     assert(DstOps.size() == 1 && "Invalid Dst");
  994     assert(SrcOps.size() == 2 && "Invalid Srcs");
 1003     assert(DstOps.size() == 1 && "Invalid Dst");
 1004     assert(SrcOps.size() == 1 && "Invalid Srcs");
 1010     assert(DstOps.size() == 1 && "Invalid Dst");
 1011     assert(SrcOps.size() == 1 && "Invalid Srcs");
 1017     assert(DstOps.size() == 1 && "Invalid Dst");
 1023     assert(DstOps.size() == 1 && "Invalid Dst Operands");
 1024     assert(SrcOps.size() == 3 && "Invalid Src Operands");
 1027     assert(SrcOps[0].getSrcOpKind() == SrcOp::SrcType::Ty_Predicate &&
 1029     assert([&]() -> bool {
 1034     assert(SrcOps[1].getLLTTy(*getMRI()) == SrcOps[2].getLLTTy(*getMRI()) &&
 1036     assert([&]() -> bool {
 1048     assert(!DstOps.empty() && "Invalid trivial sequence");
 1049     assert(SrcOps.size() == 1 && "Invalid src for Unmerge");
 1050     assert(std::all_of(DstOps.begin(), DstOps.end(),
 1056     assert(DstOps.size() * DstOps[0].getLLTTy(*getMRI()).getSizeInBits() ==
 1062     assert(!SrcOps.empty() && "invalid trivial sequence");
 1063     assert(DstOps.size() == 1 && "Invalid Dst");
 1064     assert(std::all_of(SrcOps.begin(), SrcOps.end(),
 1070     assert(SrcOps.size() * SrcOps[0].getLLTTy(*getMRI()).getSizeInBits() ==
 1083     assert(DstOps.size() == 1 && "Invalid Dst size");
 1084     assert(SrcOps.size() == 2 && "Invalid Src size");
 1085     assert(SrcOps[0].getLLTTy(*getMRI()).isVector() && "Invalid operand type");
 1086     assert((DstOps[0].getLLTTy(*getMRI()).isScalar() ||
 1089     assert(SrcOps[1].getLLTTy(*getMRI()).isScalar() && "Invalid operand type");
 1090     assert(SrcOps[0].getLLTTy(*getMRI()).getElementType() ==
 1096     assert(DstOps.size() == 1 && "Invalid dst size");
 1097     assert(SrcOps.size() == 3 && "Invalid src size");
 1098     assert(DstOps[0].getLLTTy(*getMRI()).isVector() &&
 1100     assert(DstOps[0].getLLTTy(*getMRI()).getElementType() ==
 1103     assert(SrcOps[2].getLLTTy(*getMRI()).isScalar() && "Invalid index");
 1104     assert(DstOps[0].getLLTTy(*getMRI()).getNumElements() ==
 1110     assert((!SrcOps.empty() || SrcOps.size() < 2) &&
 1112     assert(DstOps.size() == 1 && "Invalid DstOps");
 1113     assert(DstOps[0].getLLTTy(*getMRI()).isVector() &&
 1115     assert(std::all_of(SrcOps.begin(), SrcOps.end(),
 1121     assert(SrcOps.size() * SrcOps[0].getLLTTy(*getMRI()).getSizeInBits() ==
 1127     assert((!SrcOps.empty() || SrcOps.size() < 2) &&
 1129     assert(DstOps.size() == 1 && "Invalid DstOps");
 1130     assert(DstOps[0].getLLTTy(*getMRI()).isVector() &&
 1132     assert(std::all_of(SrcOps.begin(), SrcOps.end(),
 1144     assert(DstOps.size() == 1 && "Invalid DstOps");
 1145     assert((!SrcOps.empty() || SrcOps.size() < 2) &&
 1147     assert(std::all_of(SrcOps.begin(), SrcOps.end(),
 1154     assert(SrcOps.size() * SrcOps[0].getLLTTy(*getMRI()).getSizeInBits() ==
 1160     assert(DstOps.size() == 2 && "Invalid no of dst operands");
 1161     assert(SrcOps.size() == 3 && "Invalid no of src operands");
 1162     assert(DstOps[0].getLLTTy(*getMRI()).isScalar() && "Invalid operand");
 1163     assert((DstOps[0].getLLTTy(*getMRI()) == SrcOps[0].getLLTTy(*getMRI())) &&
 1166     assert(DstOps[1].getLLTTy(*getMRI()).isScalar() && "Invalid operand");
 1167     assert(DstOps[1].getLLTTy(*getMRI()) == SrcOps[2].getLLTTy(*getMRI()) &&
lib/CodeGen/GlobalISel/RegBankSelect.cpp
   83   assert(RBI && "Cannot work without RegisterBankInfo");
  128              assert(DesiredRegBrank && "The mapping must be valid");
  138   assert(ValMapping.NumBreakDowns == (unsigned)size(NewVRegs) &&
  142   assert(!NewVRegs.empty() && "We should not have to repair");
  156     assert((RepairPt.getNumInsertPoints() == 1 ||
  171     assert(ValMapping.partsAllUniform() && "irregular breakdowns not supported");
  180           assert(
  239   assert(MO.isReg() && "We should only repair register operand");
  240   assert(ValMapping.NumBreakDowns && "Nothing to map??");
  246   assert(CurRegBank || MO.isDef());
  291   assert(!PossibleMappings.empty() &&
  318     assert(BestMapping && "No suitable mapping for instruction");
  326   assert(RepairPt.hasSplit() && "We should not have to adjust for split");
  329   assert((MI.isPHI() || MI.isTerminator()) && "Why do we split?");
  331   assert(&MI.getOperand(RepairPt.getOpIdx()) == &MO &&
  338   assert((!MI.isPHI() || !MO.isDef()) && "Need split for phi def?");
  343       assert(&MI != &(*MI.getParent()->getFirstTerminator()) &&
  365   assert(MI.isTerminator() && MO.isDef() &&
  413     assert(&MI == &(*MI.getParent()->getFirstTerminator()) &&
  416     assert((!Next || Next->isUnconditionalBranch()) &&
  422       assert(!Next->readsRegister(Reg) && "Need to split between terminators");
  431       assert(false && "Repairing cost may not be accurate");
  445   assert((MBFI || !BestCost) && "Costs comparison require MBFI");
  453   assert(!Saturated && "Possible mapping saturated the cost");
  514     assert(MBFI && MBPI && "Cost computation requires MBFI and MBPI");
  539     assert(((RepairCost < RepairCost * PercentageForBias) &&
  544       assert(InsertPt->canMaterialize() && "We should not have made it here");
  552         assert(CostForInsertPt + Bias > CostForInsertPt &&
  591     assert(RepairPt.getKind() != RepairingPlacement::None &&
  601       assert(ValMapping.NumBreakDowns == 1 &&
  642   assert(BestMapping->verify(MI) && "Invalid instruction mapping");
  729   assert(MO.isReg() && "Trying to repair a non-reg operand");
  789         assert(!It->modifiesRegister(MO.getReg(), &TRI) &&
  807       assert(It->modifiesRegister(MO.getReg(), &TRI) &&
  843   assert((!Before || !Instr.isPHI()) &&
  845   assert((!Before || !Instr.getNextNode() || !Instr.getNextNode()->isPHI()) &&
  903   assert(Src.isSuccessor(DstOrSplit) && DstOrSplit->isPredecessor(&Src) &&
  906   assert(NewBB && "Invalid call to materialize");
  932   assert(Src.succ_size() > 1 && DstOrSplit->pred_size() > 1 &&
lib/CodeGen/GlobalISel/RegisterBank.cpp
   32   assert(isValid() && "Invalid register bank");
   52       assert(getSize() >= TRI.getRegSizeInBits(SubRC) &&
   54       assert(covers(SubRC) && "Not all subclasses are covered");
   61   assert(isValid() && "RB hasn't been initialized yet");
   75   assert((OtherRB.getID() != getID() || &OtherRB == this) &&
   99   assert(ContainedRegClasses.size() == TRI->getNumRegClasses() &&
lib/CodeGen/GlobalISel/RegisterBankInfo.cpp
   63     assert(RegBanks[Idx] != nullptr && "Invalid RegisterBank");
   64     assert(RegBanks[Idx]->isValid() && "RegisterBank should be valid");
   73     assert(Idx == RegBank.getID() &&
   76     assert(RegBank.verify(TRI) && "RegBank is invalid");
   88   assert(Reg && "NoRegister does not have a register bank");
  100   assert(Register::isPhysicalRegister(Reg) && "Reg must be a physreg");
  121   assert(RegBank.covers(*RC) &&
  253   assert(CompleteMapping && "Setting an uncomplete mapping");
  379   assert(((IsInvalid && ID == InvalidMappingID && Cost == 0 &&
  422     assert(Mapping->verify(MI) && "Mapping is invalid");
  450     assert(OpdMapper.getInstrMapping().getOperandMapping(OpIdx).NumBreakDowns !=
  453     assert(OpdMapper.getInstrMapping().getOperandMapping(OpIdx).NumBreakDowns ==
  477       assert(OrigTy.getSizeInBits() <= NewTy.getSizeInBits() &&
  497     assert(RC && "Expecting Register class");
  514   assert(RegBank && "Register bank not set");
  515   assert(Length && "Empty mapping");
  516   assert((StartIdx <= getHighBitIdx()) && "Overflow, switch to APInt?");
  518   assert(RegBank->getSize() >= Length && "Register bank too small for Mask");
  544   assert(NumBreakDowns && "Value mapped nowhere?!");
  549     assert(PartMap.verify() && "Partial mapping is invalid");
  555   assert(OrigValueBitWidth >= MeaningfulBitWidth &&
  565     assert((ValueMask & PartMapMask) == PartMapMask &&
  568   assert(ValueMask.isAllOnesValue() && "Value is not fully mapped");
  595   assert(NumOperands == (isCopyLike(MI) ? 1 : MI.getNumOperands()) &&
  597   assert(MI.getParent() && MI.getMF() &&
  606       assert(!getOperandMapping(Idx).isValid() &&
  613     assert(getOperandMapping(Idx).isValid() &&
  619     assert(MOMapping.verify(RBI->getSizeInBits(
  652   assert(InstrMapping.verify(MI) && "Invalid mapping for MI");
  657   assert(OpIdx < getInstrMapping().getNumOperands() && "Out-of-bound access");
  685   assert((NewVRegs.size() == StartIdx + NumVal ||
  693   assert(OpIdx < getInstrMapping().getNumOperands() && "Out-of-bound access");
  699     assert(PartMap != ValMapping.end() && "Out-of-bound access");
  700     assert(NewVReg == 0 && "Register has already been created");
  715   assert(OpIdx < getInstrMapping().getNumOperands() && "Out-of-bound access");
  716   assert(getInstrMapping().getOperandMapping(OpIdx).NumBreakDowns >
  721   assert(NewVRegs[OpToNewVRegIdx[OpIdx] + PartialMapIdx] == 0 &&
  730   assert(OpIdx < getInstrMapping().getNumOperands() && "Out-of-bound access");
  744     assert((VReg || ForDebug) && "Some registers are uninitialized");
lib/CodeGen/GlobalISel/Utils.cpp
   48   assert(Register::isVirtualRegister(Reg) && "PhysReg not implemented");
   61       assert(RegMO.isDef() && "Must be a definition");
   77   assert(Register::isVirtualRegister(Reg) && "PhysReg not implemented");
   92     assert((!isTargetSpecificOpcode(II.getOpcode()) || RegMO.isUse()) &&
  115   assert(!isPreISelGenericOpcode(I.getOpcode()) &&
  129     assert(MO.isReg() && "Unsupported non-reg operand");
  211   assert((!ValAndVReg || ValAndVReg->VReg == VReg) &&
  238       assert(Val.getBitWidth() == BitWidth &&
lib/CodeGen/GlobalMerge.cpp
  439   assert(Globals.size() > 1);
  624     assert(PT && "Global variable is not a pointer!");
lib/CodeGen/HardwareLoops.cpp
  240   assert(
  380     assert((isa<BranchInst>(BeginBB->getTerminator()) &&
lib/CodeGen/IfConversion.cpp
  845       assert(!E2->isBranch() && "Branch mis-match, one block is empty.");
  849       assert(!E1->isBranch() && "Branch mis-match, one block is empty.");
  854       assert(E1->isIdenticalTo(*E2) &&
 1890     assert(DI1 != MBB1.begin());
 1923     assert(DI2 != MBB2.begin());
 2049     assert((TailBB || !TrueBBI.IsBrAnalyzable) && "Unexpected!");
 2239   assert(!FromMBB.hasAddressTaken() &&
lib/CodeGen/ImplicitNullChecks.cpp
  106       assert((!PotentialDependence || CanReorder) &&
  238   assert(!llvm::any_of(MI->operands(), IsRegMask) &&
  248   assert(llvm::all_of(Block, canHandle) && "Check this first!");
  249   assert(!is_contained(Block, MI) && "Block must be exclusive of MI!");
  271   assert(canHandle(A) && canHandle(B) && "Precondition!");
  342     assert(MMO1->getValue() && "MMO1 should have a Value!");
  411   assert(canHandle(DependenceMI) && "Should never have reached here!");
  442     assert(!(DependenceMO.isDef() &&
  522   assert(MBP.ConditionDef->getParent() ==  &MBB && "Should be in basic block");
  622   assert(NumDefs <= 1 && "other cases unhandled!");
  627     assert(NumDefs == 1 && "expected exactly one def!");
  648         assert(MO.isDef() && "Expected def or use");
  671     assert(BranchesRemoved > 0 && "expected at least one branch!");
lib/CodeGen/IndirectBrExpandPass.cpp
  130     assert(std::find_if(std::next(BlockAddressUseIt), BB.use_end(),
lib/CodeGen/InlineSpiller.cpp
  376   assert(VNI && VNI->def == Idx.getRegSlot() && "Not defined by copy");
  390   assert(StackInt && "No stack slot assigned yet.");
  407     assert(DefMI && "Defining instruction disappeared");
  426   assert(VNI && "Missing value");
  429   assert(StackInt && "No stack slot assigned yet.");
  462            assert(DstVNI && "Missing defined value");
  463            assert(DstVNI->def == Idx.getRegSlot() && "Wrong copy def slot");
  513     assert(isRegToSpill(SnipLI.reg) && "Unexpected register in copy");
  515     assert(SnipVNI && "Snippet undefined before copy");
  656       assert(!MI.isDebugInstr() && "Did not expect to find a use in debug "
  702     assert(LIS.hasInterval(Reg) &&
  813     assert(MI == OpPair.first && "Instruction conflict during operand folding");
  859     assert(MO->isDead() && "Cannot fold physreg def");
  874   assert(!MIS.empty() && "Unexpected empty span of instructions!");
  925   assert(Def.getNumOperands() == 1 &&
  982     assert(!MI->isDebugInstr() && "Did not expect to find a use in debug "
 1075   assert(StackInt->getNumValNums() == 1 && "Bad stack interval values");
 1097       assert(SnippetCopies.count(&MI) && "Remaining use wasn't a snippet copy");
 1112   assert(!Register::isStackSlot(edit.getReg()) &&
 1123   assert(edit.getParent().isSpillable() &&
 1125   assert(DeadDefs.empty() && "Previous spill didn't remove dead defs");
 1183   assert(OrigLI.getVNInfoAt(Idx) == &OrigVNI && "Unexpected VNI");
 1302   assert(Orders.size() == WorkSet.size() &&
lib/CodeGen/InterferenceCache.cpp
  108   assert(!hasRefs() && "Cannot reset cache entry with references");
lib/CodeGen/InterferenceCache.h
  104       assert(!hasRefs() && "Cannot clear cache entry with references");
lib/CodeGen/InterleavedAccessPass.cpp
  386           assert(Extract->getOperand(0) == Shuffle->getOperand(0) &&
lib/CodeGen/InterleavedLoadCombinePass.cpp
  788     assert(ArgTy && "ShuffleVector Operand is not a VectorType");
  837       assert((i < 2 * (signed)ArgTy->getNumElements()) &&
 1102   assert(!LIs.empty() && "No load instructions given.");
 1110   assert(FLI != BB->end());
 1189   assert(!LIs.empty() && "There are no LoadInst to combine");
lib/CodeGen/IntrinsicLowering.cpp
   63   assert(V->getType()->isIntOrIntVectorTy() && "Can't bswap a non-integer type!");
  158   assert(V->getType()->isIntegerTy() && "Can't ctpop a non-integer type!");
  239   assert(Callee && "Cannot lower an indirect call!");
  483   assert(CI->use_empty() &&
lib/CodeGen/LLVMTargetMachine.cpp
   57   assert(TmpAsmInfo && "MCAsmInfo not initialized. "
  235   assert(TargetPassConfig::willCompleteCodeGenPipeline() &&
lib/CodeGen/LatencyPriorityQueue.cpp
  135   assert(!Queue.empty() && "Queue is empty!");
  137   assert(I != Queue.end() && "Queue doesn't contain the SU being removed!");
lib/CodeGen/LexicalScopes.cpp
  160   assert(Scope && "Invalid Scope encoding!");
  177     assert(cast<DISubprogram>(Scope)->describes(&MF->getFunction()));
  178     assert(!CurrentFnLexicalScope);
  189   assert(Scope && "Invalid Scope encoding!");
  212   assert(Scope && "Invalid Scope encoding!");
  234   assert(Scope && "Unable to calculate scope dominance graph!");
  264     assert(S && "Lost LexicalScope for a machine instruction!");
  281   assert(MF && "Method called on a uninitialized LexicalScopes object!");
  302   assert(MF && "Unexpected uninitialized LexicalScopes object!");
lib/CodeGen/LiveDebugValues.cpp
   85   assert(MI.isDebugValue() && "expected a DBG_VALUE");
   86   assert(MI.getNumOperands() == 4 && "malformed DBG_VALUE");
  227       assert(MI.isDebugValue() && "not a DBG_VALUE");
  228       assert(MI.getNumOperands() == 4 && "malformed DBG_VALUE");
  242       assert((Kind != ImmediateKind || !MI.isDebugEntryValue()) &&
  261       assert(VL.Kind == RegisterKind);
  271       assert(VL.Kind == RegisterKind);
  442       assert(Vars.empty() == VarLocs.empty() && "open ranges are inconsistent");
  654   assert(MI.hasOneMemOperand() &&
  658   assert(PVal->kind() == PseudoSourceValue::FixedStack &&
  678   assert(Var->isValidLocationForIntrinsic(DebugLoc) &&
  697     assert(MI.getOperand(0).isReg() && MI.getOperand(0).getReg() == 0 &&
  761     assert(NewReg &&
  787     assert(NewReg &&
 1107       assert(ASeenFragmentsOverlaps != OverlappingFragments.end() &&
 1197   assert((NumVisited || MBB.pred_empty()) &&
 1401     assert(Pending.empty() && "Pending should be empty");
lib/CodeGen/LiveDebugVariables.cpp
  105     assert(locNo() == LocNo && "location truncation");
  460     assert((!ModifiedMF || EmitDone) &&
  586   assert(Register::isVirtualRegister(VirtReg) && "Only map VirtRegs");
  587   assert(UserVarMap.find(UV->getId()) != UserVarMap.end() &&
  642   assert(!MI.getOperand(1).isImm() && "DBG_VALUE with indirect flag before "
  798     assert(DstVNI && DstVNI->def == Idx.getRegSlot() && "Bad copy value");
  823       assert(CopyMI && CopyMI->isCopy() && "Bad copy value");
 1066           assert(LocMapI.valid() && "Unexpected coalescing");
 1304   assert(cast<DILocalVariable>(Variable)
 1316   assert((!Spilled || MO.isFI()) && "a spilled location must be a frame index");
lib/CodeGen/LiveInterval.cpp
   89     assert(!Def.isDead() && "Cannot define a value at the dead slot");
   90     assert((!ForVNI || ForVNI->def == Def) &&
  101       assert((!ForVNI || ForVNI == S->valno) && "Value number mismatch");
  102       assert(S->valno->def == S->start && "Inconsistent existing value def");
  114     assert(SlotIndex::isEarlierInstr(Def, S->start) && "Already live at def");
  159     assert(I != segments().end() && "Not a valid segment!");
  166       assert(MergeTo->valno == ValNo && "Cannot merge with differing values!");
  187     assert(I != segments().end() && "Not a valid segment!");
  199       assert(MergeTo->valno == ValNo && "Cannot merge with differing values!");
  235         assert(B->end <= Start &&
  257         assert(I->start >= End &&
  406   assert(!empty() && "empty range");
  412   assert((StartPos->start <= i->start || StartPos == other.begin()) &&
  421       assert(StartPos < other.end() && i < end());
  447   assert(!empty() && "empty range");
  463     assert(J->end >= I->start);
  489   assert(Start < End && "Invalid range");
  538     assert(!VNI->isUnused() && "Unused valno used by live segment");
  560   assert(segments.empty() || segments.back().end <= S.start);
  587   assert(I != end() && "Segment is not in range!");
  588   assert(I->containsInterval(Start, End)
  669       assert(nextValNo && "Huh?");
  750   assert(V1 != V2 && "Identical value#'s are always equivalent!");
  805   assert(segmentSet != nullptr && "segment set must have been created");
  806   assert(
  901     assert(MI && "Cannot find the definition of a value");
  971   assert(Register::isVirtualRegister(reg));
  973   assert((VRegMask & LaneMask).any());
  979     assert(SubReg != 0 && "Undef should only be set on subreg defs");
 1007       assert(S.valno == getValNumInfo(S.valno->id) && "Bad VNInfo");
 1062     assert(I->start.isValid());
 1063     assert(I->end.isValid());
 1064     assert(I->start < I->end);
 1065     assert(I->valno != nullptr);
 1066     assert(I->valno->id < valnos.size());
 1067     assert(I->valno == valnos[I->valno->id]);
 1069       assert(I->end <= std::next(I)->start);
 1071         assert(I->valno != std::next(I)->valno);
 1085     assert((Mask & SR.LaneMask).none());
 1089     assert((Mask & ~MaxMask).none());
 1091     assert(!SR.empty());
 1095     assert(covers(SR));
 1138   assert(LR && "Can't have null LR in dirty updater.");
 1161   assert(A.start <= B.start && "Unordered live segments.");
 1166   assert(A.valno == B.valno && "Cannot overlap different values");
 1171   assert(LR && "Cannot add to a null destination");
 1185     assert(Spills.empty() && "Leftover spilled segments");
 1206   assert(ReadI == E || ReadI->end > Seg.start);
 1210     assert(ReadI->valno == Seg.valno && "Cannot overlap different values");
 1273   assert(NumMoved == size_t(Spills.end() - SpillSrc));
 1283   assert(LR && "Cannot add to a null destination");
 1328       assert(MBB && "Phi-def has no defining MBB");
 1400           assert(MainRangeVNI != nullptr
lib/CodeGen/LiveIntervalUnion.cpp
   67     assert(SegPos.value() == &VirtReg && "Inconsistent LiveInterval");
  142     assert(LRI != LREnd && "Reached end of LR");
  163     assert(LRI->end <= LiveUnionI.start() && "Expected non-overlap");
lib/CodeGen/LiveIntervals.cpp
  195   assert(LRCalc && "LRCalc not initialized.");
  196   assert(LI.empty() && "Should only compute empty intervals.");
  238       assert(!MBB.empty() && "empty return block?");
  264   assert(LRCalc && "LRCalc not initialized.");
  287   assert(IsReserved == MRI->isReservedRegUnit(Unit) &&
  374         assert(SR.LaneMask == M && "Expecting lane masks to match exactly");
  394       assert(ExtVNI == VNI && "Unexpected existing value number");
  422         assert(OldVNI == VNI && "Wrong value out of predecessor");
  429         assert(LaneMask.any() &&
  433         assert(LiveRangeCalc::isJointlyDominated(Pred, Undefs, *Indexes) &&
  444   assert(Register::isVirtualRegister(li->reg) &&
  508     assert(I != LI.end() && "Missing segment for VNI");
  531       assert(MI && "No instruction defining live value");
  544   assert(Register::isVirtualRegister(Reg) &&
  597     assert(Segment != nullptr && "Missing segment for VNI");
  615   assert(LRCalc && "LRCalc not initialized.");
  788             assert(MO.isDef());
  912     assert(*SlotI >= LiveI->start);
 1105     assert(OldIdxOut != E && SlotIndex::isSameInstr(OldIdx, OldIdxOut->start) &&
 1108     assert(OldIdxVNI->def == OldIdxOut->start && "Inconsistent def");
 1141         assert(INext != E && "Must have following segment");
 1187           assert(DefVNI != AfterNewIdx->valno);
 1197       assert(AfterNewIdx->valno != OldIdxVNI && "Multiple defs of value?");
 1205       assert(AfterNewIdx != OldIdxOut && "Inconsistent iterators");
 1255     assert(OldIdxOut != E && SlotIndex::isSameInstr(OldIdx, OldIdxOut->start) &&
 1258     assert(OldIdxVNI->def == OldIdxOut->start && "Inconsistent def");
 1265       assert(NewIdxOut->valno != OldIdxVNI &&
 1287           assert(NewIdxIn == LR.find(NewIdx.getBaseIndex()));
 1388     assert(RI != LIS.RegMaskSlots.end() && *RI == OldIdx.getRegSlot() &&
 1391     assert((RI == LIS.RegMaskSlots.begin() ||
 1394     assert((std::next(RI) == LIS.RegMaskSlots.end() ||
 1422     assert(Before < OldIdx && "Expected upwards move");
 1459   assert((!MI.isBundled() || MI.getOpcode() == TargetOpcode::BUNDLE) &&
 1464   assert(getMBBStartIdx(MI.getParent()) <= OldIndex &&
 1639     assert(VNI->def.getBaseIndex() == Pos.getBaseIndex());
 1670   assert(LRCalc && "LRCalc not initialized.");
lib/CodeGen/LivePhysRegs.cpp
   99         assert(O->isUse());
  162     assert(Mask.any() && "Invalid livein mask");
  258   assert(MBB.livein_empty() && "Expected empty live-in list");
  298       assert(Register::isPhysicalRegister(Reg));
  315       assert(Register::isPhysicalRegister(Reg));
lib/CodeGen/LiveRangeCalc.cpp
   75   assert(MRI && Indexes && "call reset() first");
  134   assert(MainRange.segments.empty() && MainRange.valnos.empty() &&
  148   assert(MRI && Indexes && "call reset() first");
  192       assert(!MO.isDef() && "Cannot handle PHI def of partial register.");
  222     assert(I.Value && "No live-in value found");
  232       assert(Seen.test(MBB->getNumber()));
  243   assert(Use.isValid() && "Invalid SlotIndex");
  244   assert(Indexes && "Missing SlotIndexes");
  245   assert(DomTree && "Missing dominator tree");
  248   assert(UseMBB && "No MBB at Use");
  270   assert(Indexes && "Missing SlotIndexes");
  271   assert(DomTree && "Missing dominator tree");
  435     assert(TheVNI != nullptr && TheVNI != &UndefVNI);
  483   assert(Indexes && "Missing SlotIndexes");
  484   assert(DomTree && "Missing dominator tree");
  550         assert(Alloc && "Need VNInfo allocator to create PHI-defs");
lib/CodeGen/LiveRangeEdit.cpp
   73   assert(DefMI && "Missing instruction");
  142   assert(ScannedRemattable && "Call anyRematerializable first");
  150   assert(RM.OrigMI && "No defining instruction for remattable value");
  170   assert(RM.OrigMI && "Invalid remat");
  262   assert(MI->allDefsAreDead() && "Def isn't really dead");
lib/CodeGen/LiveRangeUtils.h
   34       assert((SplitLRs[eq-1]->empty() || SplitLRs[eq-1]->expiredAt(I->start)) &&
lib/CodeGen/LiveRegMatrix.cpp
  106   assert(!VRM->hasPhys(VirtReg.reg) && "Duplicate VirtReg assignment");
lib/CodeGen/LiveStacks.cpp
   58   assert(Slot >= 0 && "Spill slot indice must be >= 0");
lib/CodeGen/LiveVariables.cpp
   86   assert(Register::isVirtualRegister(RegIdx) &&
  114   assert(MBB != &MF->front() && "Can't find reaching def for virtreg");
  133   assert(MRI->getVRegDef(reg) && "Register use before def!");
  149     assert(VRInfo.Kills[i]->getParent() != MBB && "entry should be at end!");
  379           assert(!MO->isDead());
  502   assert(!MI.isDebugInstr());
  530       assert(MO.isDef());
  568     assert(Register::isPhysicalRegister(LI.PhysReg) &&
  669     assert(Visited.count(&*i) != 0 && "unreachable basic block found");
  697         assert(removed && "kill not in register's VarInfo?");
lib/CodeGen/LocalStackSlotAllocation.cpp
  209     assert(!MFI.isObjectPreAllocated(StackProtectorFI) &&
  351     assert(MFI.isObjectPreAllocated(FrameIdx) &&
  373     assert(idx < MI.getNumOperands() && "Cannot find FI operand");
  434     assert(BaseReg != 0 && "Unable to allocate virtual base register!");
lib/CodeGen/LoopTraversal.cpp
   17   assert(MBBNumber < MBBInfos.size() && "Unexpected basic block number.");
   36     assert(MBBNumber < MBBInfos.size() && "Unexpected basic block number.");
   48         assert(SuccNumber < MBBInfos.size() &&
lib/CodeGen/LowLevelType.cpp
   33     assert(SizeInBits != 0 && "invalid zero-sized type");
lib/CodeGen/LowerEmuTLS.cpp
  142     assert(EmuTlsTmplVar && "Failed to create emualted TLS initializer");
lib/CodeGen/MIRParser/MILexer.cpp
   56     assert(C.Ptr >= Ptr && C.Ptr <= End);
  118   assert(Value.front() == '"' && Value.back() == '"');
  146   assert(C.peek() == '"');
  436   assert(C.peek() == '$');
lib/CodeGen/MIRParser/MIParser.cpp
  112   assert(TRI && "Expected target register info");
  119     assert(WasInserted && "Expected registers to be unique case-insensitively");
  137   assert(TII && "Expected target instruction info");
  156   assert(TRI && "Expected target register info");
  159   assert(RegMasks.size() == RegMaskNames.size());
  194   assert(TII && "Expected target instruction info");
  214   assert(TII && "Expected target instruction info");
  236   assert(TII && "Expected target instruction info");
  258   assert(TII && "Expected target instruction info");
  335   assert(RegName != "" && "Expected named reg.");
  360       assert(Operand.isReg() && Operand.isUse() &&
  538   assert(Loc >= Source.data() && Loc <= (Source.data() + Source.size()));
  586   assert(Token.is(MIToken::MachineBasicBlockLabel));
  696   assert(Token.is(MIToken::kw_liveins));
  729   assert(Token.is(MIToken::kw_successors));
  762   assert(Token.is(MIToken::MachineBasicBlockLabel));
  808       assert(IsInBundle);
  832     assert(Token.isNewlineOrEOF() && "MI is not fully parsed");
  863   assert(Token.is(MIToken::MachineBasicBlockLabel));
  879     assert(Token.is(MIToken::MachineBasicBlockLabel) || Token.is(MIToken::Eof));
 1076   assert(MO.isImplicit());
 1082   assert(Register::isPhysicalRegister(Reg) && "expected phys reg");
 1115   assert(TRI && "Expected target register info");
 1182   assert(Token.is(MIToken::NamedRegister) && "Needs NamedRegister token");
 1190   assert(Token.is(MIToken::NamedVirtualRegister) && "Expected NamedVReg token");
 1201   assert(Token.is(MIToken::VirtualRegister) && "Needs VirtualRegister token");
 1331   assert(Token.is(MIToken::dot));
 1479   assert(Token.is(MIToken::IntegerLiteral));
 1594   assert(Token.is(MIToken::Identifier));
 1653   assert(Token.is(MIToken::MachineBasicBlock) ||
 1681   assert(Token.is(MIToken::StackObject));
 1710   assert(Token.is(MIToken::FixedStackObject));
 1769   assert(Token.is(MIToken::ConstantPoolItem));
 1784   assert(Token.is(MIToken::JumpTableIndex));
 1797   assert(Token.is(MIToken::ExternalSymbol));
 1807   assert(Token.is(MIToken::MCSymbol));
 1817   assert(Token.is(MIToken::SubRegisterIndex));
 1828   assert(Token.is(MIToken::exclaim));
 1846   assert(Token.is(MIToken::md_diexpr));
 1892   assert(Token.is(MIToken::md_dilocation));
 2024   assert(TRI && "Expected target register info");
 2174   assert(Token.is(MIToken::kw_blockaddress));
 2205   assert(Token.is(MIToken::kw_intrinsic));
 2234   assert(Token.is(MIToken::kw_intpred) || Token.is(MIToken::kw_floatpred));
 2292   assert(Token.is(MIToken::kw_shufflemask));
 2335   assert(Token.is(MIToken::kw_target_index));
 2354   assert(Token.stringValue() == "CustomRegMask" && "Expected a custom RegMask");
 2381   assert(Token.is(MIToken::kw_liveout));
 2562   assert(Token.is(MIToken::kw_align));
 2577   assert(Token.is(MIToken::kw_addrspace));
 2651   assert(Token.is(MIToken::HexLiteral));
 2653   assert(S[0] == '0' && tolower(S[1]) == 'x');
 2942   assert((Token.is(MIToken::kw_pre_instr_symbol) ||
lib/CodeGen/MIRParser/MIRParser.cpp
  189   assert(Error.getKind() == SourceMgr::DK_Error && "Expected an error");
  415     assert(ConstantPool && "Constant pool must be created");
  497   assert(RegInfo.tracksLiveness());
  870   assert(SourceRange.isValid() && "Invalid source range");
  886   assert(SourceRange.isValid());
lib/CodeGen/MIRPrinter.cpp
  246   assert(RegMask && "Can't print an empty register mask");
  418       assert(StackObjectInfo != StackObjectOperandMapping.end() &&
  435     assert(StackObjectInfo != StackObjectOperandMapping.end() &&
  438     assert(!StackObject.IsFixed && "Expected a locally mapped stack object");
  454     assert(StackObjectInfo != StackObjectOperandMapping.end() &&
  606   assert(MBB.getNumber() >= 0 && "Invalid MBB number");
  710   assert(TRI && "Expected target register info");
  712   assert(TII && "Expected target instruction info");
  714     assert(MI.getNumOperands() == 1 && "Expected 1 operand in CFI instruction");
  811   assert(ObjectInfo != StackObjectOperandMapping.end() &&
lib/CodeGen/MIRVRegNamerUtils.cpp
   31     assert(Type != RSE_Reg && "Expected a non-Register Type.");
   40     assert(this->isReg() && "Expected a virtual or physical Register.");
  100     assert(TReg.isReg() && "Expected vreg or physreg.");
lib/CodeGen/MachineBasicBlock.cpp
   64     assert(getNumber() >= 0 && "cannot get label for unreachable MBB");
  111   assert(!N->getParent() && "machine instruction already in a basic block");
  124   assert(N->getParent() && "machine instruction not in a basic block");
  140   assert(Parent->getParent() == FromList.Parent->getParent() &&
  147   assert(Parent != FromList.Parent && "Two lists have the same parent?");
  156   assert(!MI->getParent() && "MI is still in a block!");
  164   assert((I == E || !I->isInsideBundle()) &&
  179   assert((I == E || !I->isInsideBundle()) &&
  194   assert((I == E || !I->isInsideBundle()) &&
  494   assert(getParent() && "MBB must be inserted in function");
  495   assert(PhysReg.isPhysical() && "Expected physreg");
  496   assert(RC && "Register class is required");
  497   assert((isEHPad() || this == &getParent()->front()) &&
  543   assert(!B && "UpdateTerminators requires analyzable predecessors!");
  557         assert(!TBB && "Found more than one non-landing-pad successor!");
  597     assert(!FallthroughBB && "Found more than one fallthrough successor.");
  649   assert((uint64_t)std::abs(Sum - BranchProbability::getDenominator()) <=
  678   assert(OldI != succ_end() && "Old is not a successor of this block!");
  679   assert(llvm::find(successors(), New) == succ_end() &&
  701   assert(I != Successors.end() && "Not a current successor!");
  736   assert(OldI != E && "Old is not a successor of this block");
  770   assert(I != Predecessors.end() && "Pred is not a predecessor of this block!");
 1039           assert(VNI &&
 1059         assert(VNI && "LiveInterval should have VNInfo where it is live.");
 1094           assert(DestLoop->getHeader() == Succ &&
 1169   assert(!MI->isBundledWithPred() && !MI->isBundledWithSucc() &&
 1182   assert(getParent() && "Not embedded in a function!");
 1189   assert(getParent() && "Not embedded in a function!");
 1197   assert(Old != New && "Cannot replace self with self!");
 1263     assert(DestA && DestB && IsCond &&
 1353   assert(!Prob.isUnknown());
 1363   assert(Probs.size() == Successors.size() && "Async probability list!");
 1365   assert(index < Probs.size() && "Not a current successor!");
 1372   assert(Probs.size() == Successors.size() && "Async probability list!");
 1374   assert(index < Probs.size() && "Not a current successor!");
 1498   assert(getParent()->getProperties().hasProperty(
lib/CodeGen/MachineBlockFrequencyInfo.cpp
  245   assert(MBFI && "Expected analysis to be available");
lib/CodeGen/MachineBlockPlacement.cpp
  238     assert(BB && "Cannot create a chain with a null basic block");
  271     assert(BB && "Can't merge a null block.");
  272     assert(!Blocks.empty() && "Can't merge into an empty chain.");
  276       assert(!BlockToChain[BB] &&
  283     assert(BB == *Chain->begin() && "Passed BB is not head of Chain.");
  284     assert(Chain->begin() != Chain->end());
  290       assert(BlockToChain[ChainBB] == Chain && "Incoming blocks not in chain.");
  530     assert(F);
 1153       assert(getKey()->isSuccessor(dst) &&
 1224       assert(InsertResult.second && "Block seen twice.");
 1247       assert(InsertResult.second && "Block seen twice.");
 1601     assert(MBB->isEHPad() == IsEHPad &&
 1608     assert(SuccChain.UnscheduledPredecessors == 0 &&
 1677   assert(
 1681     assert(BlockToChain[ChainBB] == &Chain &&
 1705   assert(HeadBB && "BB must not be null.\n");
 1706   assert(BlockToChain[HeadBB] == &Chain && "BlockToChainMap mis-match.\n");
 1713     assert(BB && "null block found at end of chain in loop.");
 1714     assert(BlockToChain[BB] == &Chain && "BlockToChainMap mis-match in loop.");
 1715     assert(*std::prev(Chain.end()) == BB && "BB Not found at end of chain.");
 2262     assert(std::next(ExitIt) != LoopChain.end() &&
 2470   assert(BlockWorkList.empty() &&
 2472   assert(EHPadWorkList.empty() &&
 2506   assert(LoopChain.UnscheduledPredecessors == 0 &&
 2550     assert(!BadLoop && "Detected problems with the placement of this loop.");
 2578       assert(NextFI != FE && "Can't fallthrough past the last block.");
 2596   assert(BlockWorkList.empty() &&
 2598   assert(EHPadWorkList.empty() &&
 2631     assert(!BadFunc && "Detected problems with the block placement.");
 2662       assert((!TII->analyzeBranch(*PrevBB, TBB, FBB, Cond) ||
 2842     assert(Removed && "Block must have been removed to be duplicated into its "
 2996   assert(BlockToChain.empty() &&
 2998   assert(ComputedEdges.empty() &&
lib/CodeGen/MachineCSE.cpp
  362       assert(CrossMBB && "Reaching end-of-MBB without finding MI?");
  505   assert(SI != ScopeMap.end());
  616       assert(Register::isVirtualRegister(OldReg) &&
  647         assert(Def != nullptr && "CSEd register has no unique definition?");
  807     assert(
  825         assert(MI->getOperand(0).isDef() &&
  874   assert(DT->dominates(CandidateBB, MBB) && "CandidateBB should dominate MBB");
  875   assert(DT->dominates(CandidateBB, MBB1) &&
lib/CodeGen/MachineCombiner.cpp
  161   assert(TSchedModel.hasInstrSchedModelOrItineraries() &&
  181         assert(II->second < InstrDepth.size() && "Bad Index");
  183         assert(DefInstr &&
  218   assert(TSchedModel.hasInstrSchedModelOrItineraries() &&
  278   assert(!InsInstrs.empty() && "Only support sequences that insert instrs.");
  306   assert(TSchedModel.hasInstrSchedModelOrItineraries() &&
  482     assert(CurrentLatencyDiff <= PrevLatencyDiff &&
lib/CodeGen/MachineCopyPropagation.cpp
  120     assert(MI->isCopy() && "Tracking non-copy?");
  268     assert(Def == PreviousDef);
  302   assert(Copy.isCopy());
  304   assert(CopyDef == Src || CopyDef == Def);
  474       assert(!Register::isVirtualRegister(Def) &&
  567       assert(!Register::isVirtualRegister(Reg) &&
  587         assert(!MRI->isReserved(Reg));
  622       assert(!MRI->isReserved(MaybeDead->getOperand(0).getReg()));
  625       assert(MaybeDead->isCopy());
lib/CodeGen/MachineDominators.cpp
  121         assert(PredBB->pred_size() == 1 && "A basic block resulting from a "
lib/CodeGen/MachineFrameInfo.cpp
   33     assert(Alignment <= StackAlignment &&
   54   assert(Size != 0 && "Cannot allocate zero size stack objects!");
   59   assert(Index >= 0 && "Bad frame index!");
   84   assert(Size != 0 && "Cannot allocate zero size fixed stack objects!");
  193   assert(FrameSetupOpcode != ~0u && FrameDestroyOpcode != ~0u &&
lib/CodeGen/MachineFunction.cpp
  199   assert(Target.isCompatibleDataLayout(getDataLayout()) &&
  305         assert(MBBNumbering[MBBI->getNumber()] == &*MBBI &&
  321   assert(BlockNo <= MBBNumbering.size() && "Mismatch!");
  371   assert((!MI->isCall(MachineInstr::IgnoreBundle) ||
  395   assert(MBB->getParent() == this && "MBB parent mismatch!");
  595     assert((VRegRC == RC || (VRegRC->contains(PReg) &&
  611   assert(JumpTableInfo && "No jump tables");
  612   assert(JTI < JumpTableInfo->getJumpTables().size() && "Invalid JTI!");
  693     assert(isa<CleanupPadInst>(FirstI) && "Invalid landingpad!");
  828   assert(New->isCall() && "Call site info refers only to call instructions!");
  848   assert(New->isCall() && "Call site info refers only to call instructions!");
  906   assert(!DestBBs.empty() && "Cannot create an empty jump table!");
  915   assert(Old != New && "Not making a change?");
  927   assert(Old != New && "Not making a change?");
 1062   assert(Alignment && "Alignment must be specified!");
 1082   assert(Alignment && "Alignment must be specified!");
lib/CodeGen/MachineInstr.cpp
  119   assert(debugLoc.hasTrivialDestructor() && "Expected trivial destructor");
  136   assert(debugLoc.hasTrivialDestructor() && "Expected trivial destructor");
  178   assert(MBB && "Use MachineInstrBuilder to add operands to dangling instrs");
  180   assert(MF && "Use MachineInstrBuilder to add operands to dangling instrs");
  200   assert(MCID && "Cannot add operands before providing an instr descriptor");
  223       assert(!Operands[OpNo].isTied() && "Cannot move tied operands");
  233   assert((isImpReg || Op.isRegMask() || MCID->isVariadic() ||
  296   assert(OpNo < getNumOperands() && "Invalid operand number");
  303       assert(!Operands[i].isTied() && "Cannot move tied operands");
  387   assert(&MF == MI.getMF() &&
  438   assert(&MF == MIs[0]->getMF() &&
  443     assert(&MF == MI.getMF() &&
  512   assert(&MF == MI.getMF() &&
  569   assert(!isBundledWithPred() && "Must be called on bundle header");
  596     assert(Other.isBundle() && "Expected that both instructions are bundles.");
  660   assert(getParent() && "Not embedded in a basic block!");
  665   assert(getParent() && "Not embedded in a basic block!");
  670   assert(getParent() && "Not embedded in a basic block!");
  675   assert(getParent() && "Not embedded in a basic block!");
  678   assert(MF && "Not embedded in a function!");
  695   assert(getParent() && "Not embedded in a basic block!");
  733   assert(!isBundledWithPred() && "MI is already bundled with its predecessor");
  737   assert(!Pred->isBundledWithSucc() && "Inconsistent bundle flags");
  742   assert(!isBundledWithSucc() && "MI is already bundled with its successor");
  746   assert(!Succ->isBundledWithPred() && "Inconsistent bundle flags");
  751   assert(isBundledWithPred() && "MI isn't bundled with its predecessor");
  755   assert(Pred->isBundledWithSucc() && "Inconsistent bundle flags");
  760   assert(isBundledWithSucc() && "MI isn't bundled with its successor");
  764   assert(Succ->isBundledWithPred() && "Inconsistent bundle flags");
  778   assert(isInlineAsm() && "getInlineAsmDialect() only works for inline asms!");
  785   assert(isInlineAsm() && "Expected an inline asm instruction");
  786   assert(OpIdx < getNumOperands() && "OpIdx out of range");
  812   assert(isDebugLabel() && "not a DBG_LABEL");
  817   assert(isDebugValue() && "not a DBG_VALUE");
  822   assert(isDebugValue() && "not a DBG_VALUE");
  834   assert(getParent() && "Can't have an MBB reference here!");
  835   assert(getMF() && "Can't have an MF reference here!");
  890   assert(CurRC && "Invalid initial register class");
  904   assert(MO.isReg() &&
  906   assert(CurRC && "Invalid initial register class");
 1053   assert(DefMO.isDef() && "DefIdx must be a def operand");
 1054   assert(UseMO.isUse() && "UseIdx must be a use operand");
 1055   assert(!DefMO.isTied() && "Def is already tied to another use");
 1056   assert(!UseMO.isTied() && "Use is already tied to another def");
 1064     assert(isInlineAsm() && "DefIdx out of range");
 1077   assert(MO.isTied() && "Operand isn't tied");
 1105     assert(FlagMO.isImm() && "Invalid tied operand on inline asm");
 1266   assert((OffsetA >= 0) && "Negative MachineMemOperand offset");
 1267   assert((OffsetB >= 0) && "Negative MachineMemOperand offset");
 1358   assert(getNumOperands() >= 3 &&
 1483     assert(getNumOperands() == 1 && "Expected 1 operand in CFI instruction");
 2017   assert(isa<DILocalVariable>(Variable) && "not a variable");
 2018   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
 2019   assert(cast<DILocalVariable>(Variable)->isValidLocationForIntrinsic(DL) &&
 2033   assert(isa<DILocalVariable>(Variable) && "not a variable");
 2034   assert(cast<DIExpression>(Expr)->isValid() && "not an expression");
 2035   assert(cast<DILocalVariable>(Variable)->isValidLocationForIntrinsic(DL) &&
 2073   assert(MI.getOperand(0).isReg() && "can't spill non-register");
 2074   assert(MI.getDebugVariable()->isValidLocationForIntrinsic(MI.getDebugLoc()) &&
 2079     assert(MI.getOperand(1).getImm() == 0 && "DBG_VALUE with nonzero offset");
lib/CodeGen/MachineInstrBundle.cpp
  127   assert(FirstMI != LastMI && "Empty bundle?");
  264     assert(!MII->isInsideBundle() &&
  319   assert(Register::isPhysicalRegister(Reg) &&
lib/CodeGen/MachineLICM.cpp
  429     assert(Register::isPhysicalRegister(Reg) &&
  684     assert(Node && "Null dominator tree node?");
  890   assert(MI.mayLoad() && "Expected MI that loads!");
  966   assert(Register::isVirtualRegister(CopyDstReg) &&
 1041     assert(MRI->getVRegDef(Reg) &&
 1313   assert(Success &&
 1316   assert(NewMIs.size() == 2 &&
 1379       assert((!MO.isReg() || MO.getReg() == 0 ||
lib/CodeGen/MachineLoopUtils.cpp
   85     assert(OrigPhi.isPHI());
  123     assert(CanAnalyzeBr && "Must be able to analyze the loop branch!");
lib/CodeGen/MachineModuleInfo.cpp
   87     assert(DeletedAddrLabelsNeedingEmission.empty() &&
  103   assert(BB->hasAddressTaken() &&
  109     assert(BB->getParent() == Entry.Fn && "Parent changed");
  143   assert(!Entry.Symbols.empty() && "Didn't have a symbol, why a callback?");
  146   assert((BB->getParent() == nullptr || BB->getParent() == Entry.Fn) &&
  165   assert(!OldEntry.Symbols.empty() && "Didn't have a symbol, why a callback?");
lib/CodeGen/MachineOperand.cpp
   76   assert(Reg.isVirtual());
   85   assert(Reg.isPhysical());
   99   assert(isReg() && "Wrong MachineOperand accessor");
  100   assert((!Val || !isDebug()) && "Marking a debug operation as def");
  103   assert(!IsDeadOrKill && "Changing def/use with dead/kill set not supported");
  116   assert(isReg() && "Wrong MachineOperand accessor");
  117   assert(Register::isPhysicalRegister(getReg()) &&
  129   assert(isUse() && "Reg is not def or use");
  134   assert(isReg() && "Wrong MachineOperand accessor");
  135   assert(Register::isPhysicalRegister(getReg()) &&
  154   assert((!isReg() || !isTied()) && "Cannot change a tied operand into an imm");
  163   assert((!isReg() || !isTied()) && "Cannot change a tied operand into an imm");
  173   assert((!isReg() || !isTied()) &&
  186   assert((!isReg() || !isTied()) &&
  198   assert((!isReg() || !isTied()) &&
  208   assert((!isReg() || !isTied()) &&
  219   assert((!isReg() || !isTied()) &&
  246   assert(!(isDead && !isDef) && "Dead flag on non-def");
  247   assert(!(isKill && isDef) && "Kill flag on def");
  405   assert(TII && "expected instruction info");
  543   assert(TII && "expected instruction info");
 1024   assert((PtrInfo.V.isNull() || PtrInfo.V.is<const PseudoSourceValue *>() ||
 1027   assert(getBaseAlignment() == a && a != 0 && "Alignment is not a power of 2!");
 1028   assert((isLoad() || isStore()) && "Not a load/store!");
 1031   assert(getSyncScopeID() == SSID && "Value truncated");
 1033   assert(getOrdering() == Ordering && "Value truncated");
 1035   assert(getFailureOrdering() == FailureOrdering && "Value truncated");
 1051   assert(MMO->getFlags() == getFlags() && "Flags mismatch!");
 1052   assert(MMO->getSize() == getSize() && "Size mismatch!");
 1093   assert((isLoad() || isStore()) &&
 1117     assert(PVal && "Expected a pseudo source value");
lib/CodeGen/MachineOutliner.cpp
  180     assert(*EndIdx != EmptyIdx && "EndIdx is undefined!");
  278     assert(StartIdx <= LeafEndIdx && "String can't start after it ends!");
  298     assert(StartIdx <= EndIdx && "String can't start after it ends!");
  299     assert(!(!Parent && StartIdx != EmptyIdx) &&
  325       assert(ChildPair.second && "Node had a null child!");
  360       assert(Active.Idx <= EndIdx && "Start index can't be after end index!");
  488     assert(Root && "Root node can't be nullptr!");
  681     assert(LegalInstrNumber != DenseMapInfo<unsigned>::getEmptyKey() &&
  683     assert(LegalInstrNumber != DenseMapInfo<unsigned>::getTombstoneKey() &&
  714     assert(LegalInstrNumber < IllegalInstrNumber &&
  717     assert(IllegalInstrNumber != DenseMapInfo<unsigned>::getEmptyKey() &&
  720     assert(IllegalInstrNumber != DenseMapInfo<unsigned>::getTombstoneKey() &&
  815     assert(DenseMapInfo<unsigned>::getEmptyKey() == (unsigned)-1 &&
  817     assert(DenseMapInfo<unsigned>::getTombstoneKey() == (unsigned)-2 &&
lib/CodeGen/MachinePipeliner.cpp
  279   assert(LoopID->getNumOperands() > 0 && "requires atleast one operand");
  280   assert(LoopID->getOperand(0) == LoopID && "invalid loop");
  294       assert(MD->getNumOperands() == 2 &&
  298       assert(II_setByPragma >= 1 && "Pipeline initiation interval must be positive.");
  354     assert(DefOp.getSubReg() == 0);
  383   assert(L.getBlocks().size() == 1 && "SMS works on single blocks only.");
  551     assert(NewInstrChanges.empty() &&
  583   assert(Phi.isPHI() && "Expecting a Phi.");
  593   assert(InitVal != 0 && LoopVal != 0 && "Unexpected Phi structure.");
  700               assert(TII->areMemAccessesTriviallyDisjoint(LdMI, MI) &&
 1069       assert(NewResource->canReserveResources(*MI) && "Reserve error.");
 1242     assert(SI != BU.end() && "Invalid B set.");
 2220   assert(SI != nullptr && DI != nullptr && "Expecting SUnit with an MI.");
 2310         assert(ProcItinResources.canReserveResources(*(*I)->getInstr()) &&
 2591   assert(Phi.isPHI() && "Expecting a Phi.");
 2648     assert(StageDef != -1 && "Instruction should have been scheduled.");
 2896   assert(SM.getNumProcResourceKinds() < 64 &&
lib/CodeGen/MachinePostDominators.cpp
   52   assert(!Blocks.empty());
lib/CodeGen/MachineRegisterInfo.cpp
   59   assert(RC && RC->isAllocatable() && "Invalid RC for virtual register");
  160   assert(RegClass && "Cannot create register without RegClass!");
  161   assert(RegClass->isAllocatable() &&
  251   assert(Valid && "Invalid use list");
  266   assert(!MO->isOnRegUseList() && "Already on list");
  281   assert(MO->getReg() == Head->getReg() && "Different regs on the same list!");
  285   assert(Last && "Inconsistent use list");
  286   assert(MO->getReg() == Last->getReg() && "Different regs on the same list!");
  305   assert(MO->isOnRegUseList() && "Operand not on use list");
  308   assert(Head && "List already empty");
  336   assert(Src != Dst && NumOps && "Noop moveOperands");
  355       assert(Head && "List empty, but operand is chained");
  356       assert(Prev && "Operand was not on use-def list");
  381   assert(FromReg != ToReg && "Cannot replace a reg with itself");
  403   assert((I.atEnd() || std::next(I) == def_instr_end()) &&
  501   assert(Register::isVirtualRegister(Reg));
  515   assert(ReservedRegs.size() == getTargetRegisterInfo()->getNumRegs() &&
  520   assert(Register::isPhysicalRegister(PhysReg));
  616   assert(Reg && (Reg < TRI->getNumRegs()) &&
lib/CodeGen/MachineScheduler.cpp
  279   assert(I != Beg && "reached the top of the region, cannot decrement");
  775     assert(!SU->isScheduled && "Node already scheduled");
  781       assert(SU->isTopReady() && "node still has unscheduled dependencies");
  787       assert(SU->isBottomReady() && "node still has unscheduled dependencies");
  807   assert(CurrentTop == CurrentBottom && "Nonempty unscheduled zone.");
  829     assert(!SU.isBoundaryNode() && "Boundary node should not be in SUnits");
  986   assert((!ShouldTrackLaneMasks || ShouldTrackPressure) &&
 1041   assert((BotRPTracker.getPos() == RegionEnd ||
 1124       assert(P.LaneMask.any());
 1141       assert(VNI && "No live value at use.");
 1223     assert(!SU->isScheduled && "Node already scheduled");
 1243   assert(CurrentTop == CurrentBottom && "Nonempty unscheduled zone.");
 1380     assert(TopRPTracker.getPos() == RegionBegin && "bad initial Top tracker");
 1391     assert(SU->isTopReady() && "node still has unscheduled dependencies");
 1413       assert(TopRPTracker.getPos() == CurrentTop && "out of sync");
 1420     assert(SU->isBottomReady() && "node still has unscheduled dependencies");
 1450       assert(BotRPTracker.getPos() == CurrentBottom && "out of sync");
 1753     assert(std::prev(GlobalSegment)->start < LocalLI->beginIndex() &&
 1814   assert(DAG->hasVRegLiveness() && "Expect VRegs with LiveIntervals");
 1883   assert(!ExecutedResCounts[0] && "nonzero count for bad resource");
 1967   assert(NumberOfInstances > 0 &&
 2089   assert(SU->getInstr() && "Scheduled SUnit must have instr");
 2115     assert(MinReadyCycle < std::numeric_limits<unsigned>::max() &&
 2173   assert(Rem->RemainingCounts[PIdx] >= Count && "resource double counted");
 2214   assert(
 2224     assert(ReadyCycle <= CurrCycle && "Broken PendingQueue");
 2246     assert(Rem->RemIssueCount >= DecRemIssue && "MOps double counted");
 2378     assert(Pending.isInQueue(SU) && "bad ready count");
 2715   assert(dag->hasVRegLiveness() &&
 2779   assert((!ForceTopDown || !ForceBottomUp) &&
 3157     assert(BotCand.Reason != NoCand && "failed to find the first candidate");
 3165       assert(TCand.SU == BotCand.SU &&
 3177     assert(TopCand.Reason != NoCand && "failed to find the first candidate");
 3185       assert(TCand.SU == TopCand.SU &&
 3192   assert(BotCand.isValid());
 3193   assert(TopCand.isValid());
 3210     assert(Top.Available.empty() && Top.Pending.empty() &&
 3222         assert(TopCand.Reason != NoCand && "failed to find a candidate");
 3233         assert(BotCand.Reason != NoCand && "failed to find a candidate");
 3417     assert(Top.Available.empty() && Top.Pending.empty() && "ReadyQ garbage");
 3432       assert(TopCand.Reason != NoCand && "failed to find a candidate");
 3508     assert(dag->hasVRegLiveness() && "ILPScheduler needs vreg liveness");
 3551     assert(!IsTopNode && "SchedDFSResult needs bottom-up");
 3659   assert((TopDown || !ForceTopDown) &&
lib/CodeGen/MachineSink.cpp
  243   assert(Register::isVirtualRegister(Reg) && "Only makes sense for vregs");
  408   assert(MI.isDebugValue() && "Expected DBG_VALUE for processing");
  543   assert (SuccToSinkTo && "Invalid SinkTo Candidate BB");
  629   assert (MBB && "Invalid MachineBasicBlock!");
  985   assert(MI.isCopy());
  986   assert(MI.getOperand(1).isReg());
 1004       assert(User.getOperand(0).isReg() &&
 1292     assert((!UsedOpsInCopy.empty() && !DefedRegsInCopy.empty()) &&
 1303     assert((SuccBB->pred_size() == 1 && *SuccBB->pred_begin() == &CurBB) &&
lib/CodeGen/MachineTraceMetrics.cpp
   98   assert(MBB && "No basic block");
  128       assert(PI->ProcResourceIdx < PRKinds && "Bad processor resource kind");
  145   assert(BlockInfo[MBBNum].hasResources() &&
  148   assert((MBBNum+1) * PRKinds <= ProcResourceCycles.size());
  193   assert(PredTBI->hasValidDepth() && "Trace above has not been computed yet");
  228   assert(SuccTBI->hasValidHeight() && "Trace below has not been computed yet");
  266   assert((MBBNum+1) * PRKinds <= ProcResourceDepths.size());
  279   assert((MBBNum+1) * PRKinds <= ProcResourceHeights.size());
  384   assert(strategy < TS_NumStrategies && "Invalid trace strategy enum");
  409   assert(BlockInfo.size() == MF->getNumBlockIDs() && "Outdated BlockInfo size");
  546         assert((!TBI.Succ || Pred->isSuccessor(TBI.Succ)) && "CFG changed");
  571         assert((!TBI.Pred || Succ->isPredecessor(TBI.Pred)) && "CFG changed");
  587   assert(BlockInfo.size() == MTM.MF->getNumBlockIDs() &&
  593       assert(MBB->isPredecessor(TBI.Pred) && "CFG doesn't match trace");
  594       assert(BlockInfo[TBI.Pred->getNumber()].hasValidDepth() &&
  597       assert(!(Loop && MBB == Loop->getHeader()) && "Trace contains backedge");
  601       assert(MBB->isSuccessor(TBI.Succ) && "CFG doesn't match trace");
  602       assert(BlockInfo[TBI.Succ->getNumber()].hasValidHeight() &&
  606       assert(!(Loop && Loop == SuccLoop && TBI.Succ == Loop->getHeader()) &&
  637     assert(Register::isVirtualRegister(VirtReg));
  639     assert(!DefI.atEnd() && "Register has no defs");
  642     assert((++DefI).atEnd() && "Register has multiple defs");
  687   assert(UseMI.isPHI() && UseMI.getNumOperands() % 2 && "Bad PHI");
  764   assert(TBI.HasValidInstrDepths && "Missing depth info");
  765   assert(TBI.HasValidInstrHeights && "Missing height info");
  799     assert(DepTBI.HasValidInstrDepths && "Inconsistent dependency");
  844     assert(TBI.hasValidDepth() && "Incomplete trace");
  980   assert(!Trace.empty() && "Trace should contain at least one block");
  982   assert(Register::isVirtualRegister(Reg));
 1006     assert(TBI.hasValidHeight() && "Incomplete trace");
 1174   assert(getBlockNum() == unsigned(MI.getParent()->getNumber()) &&
 1185   assert(Deps.size() == 1 && "PHI doesn't have MBB as a predecessor");
lib/CodeGen/MachineVerifier.cpp
  345     assert(!Last.isValid() || I->first > Last);
  475   assert(MF);
  490   assert(MBB);
  501   assert(MI);
  511   assert(MO);
 1092       assert(MI->getOpcode() == TargetOpcode::G_ADDRSPACE_CAST);
 1130     assert(MCID.getNumOperands() == 2 && "Expected 2 operands G_*{EXT,TRUNC}");
 1558       assert(SrcSize && "Expecting size here");
 1559       assert(DstSize && "Expecting size here");
 1899     assert(VNI && "NULL valno is not allowed");
 1921       assert(Register::isVirtualRegister(VRegOrUnit) &&
 2313   assert(LiveVars && "Don't call verifyLiveVariables without LiveVars");
 2339   assert(LiveInts && "Don't call verifyLiveIntervals without LiveInts");
 2354     assert(Reg == LI.reg && "Invalid reg to interval mapping");
 2462   assert(VNI && "Live segment has no valno");
 2620     assert(LiveInts->isLiveInToMBB(LR, &*MFI));
 2682   assert(Register::isVirtualRegister(Reg));
 2770       assert(Reachable.count(StackPred) &&
lib/CodeGen/ModuloSchedule.cpp
   37   assert(Phi.isPHI() && "Expecting a Phi.");
   47   assert(InitVal != 0 && LoopVal != 0 && "Unexpected Phi structure.");
  110   assert(LoopInfo && "Must be able to analyze loop!");
  258   assert(!checkBranch && "generateEpilog must be able to analyze the branch");
  265   assert(LoopExitI != KernelBB->succ_end() && "Expecting a successor");
  630       assert(StageScheduled != -1 && "Expecting scheduled instruction.");
  853   assert(PrologBBs.size() == EpilogBBs.size() && "Prolog/Epilog mismatch");
 1158     assert(OrigInstr != InstrMap.end() && "Instruction not scheduled.");
 1223       assert(MI.isPHI());
 1305   assert(FirstMI && "Failed to find first MI in schedule");
 1363     assert(ConsumerStage != -1 &&
 1365     assert(ConsumerStage >= ProducerStage);
 1382     assert(LoopProducer);
 1399     assert(LoopProducerCycle <= ConsumerCycle);
 1400     assert(LoopProducerStage == ConsumerStage + 1);
 1410     assert(ConsumerStage >= LoopProducerStage);
 1634   assert(Prologs.size() == Epilogs.size());
 1703   assert(CanAnalyzeBr && "Must be able to analyze the loop branch!");
 1747       assert(UseMI.isPHI());
 1764   assert(Info);
 1840   assert(LIS && "Requires LiveIntervals!");
 1876     assert(OI->getOpcode() == NI->getOpcode() && "Opcodes don't match?!");
lib/CodeGen/OptimizePHIs.cpp
   99   assert(MI->isPHI() && "IsSingleValuePHICycle expects a PHI instruction");
  143   assert(MI->isPHI() && "IsDeadPHICycle expects a PHI instruction");
  145   assert(Register::isVirtualRegister(DstReg) &&
lib/CodeGen/PHIElimination.cpp
  251   assert(MPhi->getOperand(0).getSubReg() == 0 && "Can't handle sub-reg PHIs");
  345     assert(DestLI.begin() != DestLI.end() &&
  352       assert(OrigDestVNI && "PHI destination should be live at block entry.");
  362       assert(DestVNI && "PHI destination should be live at its definition.");
  380     assert(Register::isVirtualRegister(SrcReg) &&
  468       assert(KillInst->readsRegister(SrcReg) && "Cannot find kill instruction");
  528           assert(KillInst->readsRegister(SrcReg) &&
  643   assert((LV || LIS) &&
  653   assert((LV || LIS) &&
lib/CodeGen/ParallelCG.cpp
   42   assert(BCOSs.empty() || BCOSs.size() == OSs.size());
lib/CodeGen/PatchableFunction.cpp
   63   assert(PatchType == "prologue-short-redirect" && "Only possibility today!");
   69     assert(FirstActualI != FirstMBB.end());
lib/CodeGen/PeepholeOptimizer.cpp
  312       assert(Idx < getNumSources() && "Reg pair source out of index");
  323       assert(Idx < getNumSources() && "Reg source out of index");
  328       assert(Idx < getNumSources() && "SubReg source out of index");
  694         assert(CurSrcRes == Res && "ValueTrackerResult found must match");
  758   assert(!SrcRegs.empty() && "No sources to create a PHI instruction?");
  763   assert(SrcRegs[0].SubReg == 0 && "should not have subreg operand");
  831     assert(MI.isCopy() && "Expected copy instruction");
  906     assert(MI.isInsertSubreg() && "Invalid instruction");
  959     assert(MI.isExtractSubreg() && "Invalid instruction");
 1018     assert(MI.isRegSequence() && "Invalid instruction");
 1168   assert(isCoalescableCopy(MI) && "Invalid argument");
 1169   assert(MI.getDesc().getNumDefs() == 1 &&
 1224   assert(!Register::isPhysicalRegister(Def.Reg) &&
 1270   assert(isUncoalescableCopy(MI) && "Invalid argument");
 1367     assert(II != ImmDefMIs.end() && "couldn't find immediate definition");
 1393   assert(MI.isCopy() && "expected a COPY machine instruction");
 1440   assert(MI.isCopy() && "expected a COPY machine instruction");
 1568     assert(isVirtualRegisterOperand(MO) && "Invalid PHI instruction");
 1808   assert(Def->isCopy() && "Invalid definition");
 1813   assert(Def->getNumOperands() - Def->getNumImplicitOperands() == 2 &&
 1815   assert(!Def->hasImplicitDef() && "Only implicit uses are allowed");
 1829   assert(Def->isBitcast() && "Invalid definition");
 1853     assert(!MO.isDef() && "We should have skipped all the definitions by now");
 1879   assert((Def->isRegSequence() || Def->isRegSequenceLike()) &&
 1923   assert((Def->isInsertSubreg() || Def->isInsertSubregLike()) &&
 1976   assert((Def->isExtractSubreg() ||
 2005   assert(Def->isSubregToReg() && "Invalid definition");
 2026   assert(Def->isPHI() && "Invalid definition");
 2037     assert(MO.isReg() && "Invalid PHI instruction");
 2049   assert(Def && "This method needs a valid definition");
 2051   assert(((Def->getOperand(DefIdx).isDef() &&
lib/CodeGen/PostRASchedulerList.cpp
  219   assert((AntiDepMode == TargetSubtargetInfo::ANTIDEP_NONE ||
  356     assert(Count == 0 && "Instruction count mismatch!");
  357     assert((MBB.begin() == Current || CurrentCount != 0) &&
  503   assert(CurCycle >= SU->getDepth() &&
  665   assert(Sequence.size() - Noops == ScheduledNodes &&
lib/CodeGen/PreISelIntrinsicLowering.cpp
   80     assert(CI->getCalledFunction() && "Cannot lower an indirect call!");
lib/CodeGen/ProcessImplicitDefs.cpp
  142   assert(MRI->isSSA() && "ProcessImplicitDefs only works on SSA form.");
  143   assert(WorkList.empty() && "Inconsistent worklist state");
lib/CodeGen/PrologEpilogInserter.cpp
  329   assert(!MFI.isMaxCallFrameSizeComputed() ||
  360     assert(MFI.getRestorePoint() && "Both restore and save must be set");
  580         assert(I != RestoreBlock.begin() &&
  595   assert(MF.getProperties().hasProperty(
  798   assert(LocalAreaOffset >= 0
 1155       assert(Reachable.count(StackPred) &&
 1176   assert(MF.getSubtarget().getRegisterInfo() &&
 1206         assert(i == 0 && "Frame indices can only appear as the first "
 1250         assert((!MI.isDebugValue() || i == 0) &&
lib/CodeGen/ReachingDefAnalysis.cpp
   27   assert(MBBNumber < MBBReachingDefs.size() &&
   56     assert(unsigned(pred->getNumber()) < MBBOutRegsInfos.size() &&
   79   assert(!LiveRegs.empty() && "Must enter basic block first.");
   81   assert(MBBNumber < MBBOutRegsInfos.size() &&
   96   assert(!MI->isDebugInstr() && "Won't process debug instructions");
   99   assert(MBBNumber < MBBReachingDefs.size() &&
  174   assert(InstIds.count(MI) && "Unexpected machine instuction.");
  178   assert(MBBNumber < MBBReachingDefs.size() &&
  193   assert(InstIds.count(MI) && "Unexpected machine instuction.");
lib/CodeGen/RegAllocBase.cpp
   90     assert(!VRM->hasPhys(VirtReg->reg) && "Register already assigned");
  145       assert(LIS->hasInterval(Reg));
  148       assert(!VRM->hasPhys(SplitVirtReg->reg) && "Register already assigned");
  150         assert(SplitVirtReg->empty() && "Non-empty but used interval");
  157       assert(Register::isVirtualRegister(SplitVirtReg->reg) &&
lib/CodeGen/RegAllocBasic.cpp
  223   assert(!Intfs.empty() && "expected interference");
  287     assert(!Matrix->checkInterference(VirtReg, *PhysRegI) &&
lib/CodeGen/RegAllocFast.cpp
  331     assert(NewDV->getParent() == MBB && "dangling parent pointer");
  389   assert(PhysRegState[LR.PhysReg] == LR.VirtReg &&
  397   assert(Register::isVirtualRegister(VirtReg) &&
  408   assert(Register::isVirtualRegister(VirtReg) &&
  411   assert(LRI != LiveVirtRegs.end() && LRI->PhysReg &&
  418   assert(PhysRegState[LR.PhysReg] == LR.VirtReg && "Broken RegState mapping");
  459   assert(Register::isPhysicalRegister(PhysReg) && "Bad usePhysReg operand");
  493       assert((TRI->isSuperRegister(PhysReg, Alias) ||
  576     assert(LRI != LiveVirtRegs.end() && LRI->PhysReg &&
  597       assert(LRI != LiveVirtRegs.end() && LRI->PhysReg &&
  614   assert(LR.PhysReg == 0 && "Already assigned a physreg");
  615   assert(PhysReg != 0 && "Trying to assign no register");
  630     assert(Register::isVirtualRegister(Reg));
  664   assert(Register::isVirtualRegister(VirtReg) &&
  752   assert(MO.isUndef() && "expected undef use");
  754   assert(Register::isVirtualRegister(VirtReg) && "Expected virtreg");
  763     assert(!AllocationOrder.empty() && "Allocation order must not be empty");
  779   assert(Register::isVirtualRegister(VirtReg) && "Not a virtual register");
  799   assert(LRI->PhysReg && "Register not assigned");
  812   assert(Register::isVirtualRegister(VirtReg) && "Not a virtual register");
  845   assert(LRI->PhysReg && "Register not assigned");
  990       assert(LRI != LiveVirtRegs.end() && LRI->PhysReg &&
  994       assert(LRI->PhysReg == Reg && "Bad inverse map");
 1005     assert(Register::isVirtualRegister(i->VirtReg) && "Bad map key");
 1006     assert(Register::isPhysicalRegister(i->PhysReg) && "Bad map value");
 1007     assert(PhysRegState[i->PhysReg] == i->VirtReg && "Bad inverse map");
 1130       assert(MO.isUndef() && "Should only have undef virtreg uses left");
 1250   assert(LiveVirtRegs.empty() && "Mapping not cleared from last block?");
lib/CodeGen/RegAllocGreedy.cpp
  688   assert(Register::isVirtualRegister(Reg) &&
  902       assert(Register::isVirtualRegister(Intf->reg) &&
 1083     assert((ExtraRegInfo[Intf->reg].Cascade < Cascade ||
 1271       assert(T < GroupSize && "Array overflow");
 1280     assert(B < GroupSize && "Array overflow");
 1684   assert(NumGlobalIntvs && "No global intervals configured");
 1998     assert(!Cand.PhysReg && "Compact region has no physreg");
 2021   assert(&SA->getParent() == &VirtReg && "Live range wasn't analyzed");
 2068   assert(SuperRC && "Invalid register class");
 2153   assert(SA->getUseBlocks().size() == 1 && "Not a local interval");
 2270       assert(!SlotIndex::isEarlierInstr(RMS[ri], Uses[i]));
 2440     assert(!ProgressRequired && "Didn't make progress when it was required.");
 2610   assert((getStage(VirtReg) >= RS_Done || !VirtReg.isSpillable()) &&
 2629   assert(!FixedRegisters.count(VirtReg.reg));
 2667       assert(VRM->hasPhys(ItVirtReg) &&
 2755       assert(LI->empty() && "Only empty live-range do not require a register");
 2938     assert(VRM->hasPhys(Reg) && "We have unallocated variable!!");
 3024     assert(Register::isVirtualRegister(LI->reg) &&
 3084   assert((NewVRegs.empty() || Depth) && "Cannot append to existing NewVRegs");
lib/CodeGen/RegAllocPBQP.cpp
  245     assert(NRegs != MRegs && "AllowedRegs can not be disjoint with itself");
  336       assert(!LI.empty() && "PBQP graph contains node for empty interval");
  509     assert(CostMat.getRows() == Allowed1.size() + 1 && "Size mismatch.");
  510     assert(CostMat.getCols() == Allowed2.size() + 1 && "Size mismatch.");
  695     assert(!LI.empty() && "Empty spill range.");
  728       assert(PReg != 0 && "Invalid preg selected.");
  764       assert(PReg &&
  891     assert(Costs.getLength() != 0 && "Empty vector in graph.");
  899     assert(N1Id != N2Id && "PBQP graphs should not have self-edges.");
  901     assert(M.getRows() != 0 && "No rows in matrix.");
  902     assert(M.getCols() != 0 && "No cols in matrix.");
lib/CodeGen/RegUsageInfoPropagate.cpp
   65     assert(RegMask.size() ==
lib/CodeGen/RegisterClassInfo.cpp
   55   assert(TRI && "no register info set");
   91   assert(RC && "no register class given");
  130   assert(RCI.NumRegs <= NumRegs && "Allocation order larger than regclass");
lib/CodeGen/RegisterCoalescer.cpp
  477   assert(Register::isVirtualRegister(Src) && "Src must be virtual");
  478   assert(!(Register::isPhysicalRegister(Dst) && DstSub) &&
  513     assert(!DstIdx && !SrcIdx && "Inconsistent CoalescerPair state.");
  557   assert(!CP.isPartial() && "This doesn't work for partial copies.");
  558   assert(!CP.isPhys() && "This doesn't work for physreg copies.");
  740   assert(!CP.isPhys());
  771   assert(BValNo != nullptr && BValNo->def == CopyIdx);
  775   assert(AValNo && !AValNo->isUnused() && "COPY source not live");
  786   assert(DefIdx != -1);
  875     assert(US != IntA.end() && "Use must be live");
  899     assert(DVNI->def == DefIdx);
  906       assert(SubBValNo->def == CopyIdx);
  946             assert(BSubValNo != nullptr);
 1027   assert(!CP.isPhys());
 1046   assert(AValNo && !AValNo->isUnused() && "COPY source not live");
 1161     assert(BValNo && "All sublanes should be live");
 1191   assert(!Register::isPhysicalRegister(Reg) &&
 1272       assert(Register::isVirtualRegister(DstReg) &&
 1294       assert(SrcIdx == 0 && CP.isFlipped()
 1318       assert(MO.isImplicit() && "No explicit operands after implicit operands.");
 1338       assert(MO.isImplicit() && MO.isDead() &&
 1352       assert(NewRC && "subreg chosen for remat incompatible with instruction");
 1431     assert(Register::isPhysicalRegister(DstReg) &&
 1549   assert(Seg != nullptr && "No segment for defining instruction");
 1579       assert(SVNI != nullptr && SlotIndex::isSameInstr(SVNI->def, RegIndex));
 1808       assert(ReadVNI && "No value before copy and no <undef> flag.");
 1809       assert(ReadVNI != DefVNI && "Cannot read and define the same value.");
 1981   assert(CP.isPhys() && "Must be a physreg copy");
 1982   assert(MRI->isReserved(DstReg) && "Not a reserved register");
 1986   assert(RHS.containsOneValue() && "Invalid join with reserved register");
 2411     assert(MI && "No defining instruction");
 2484   assert(!V.isAnalyzed() && "Value has already been analyzed!");
 2500     assert(DefMI != nullptr);
 2529         assert((TrackSubRegLiveness || V.RedefVNI) &&
 2558     assert(SlotIndex::isSameInstr(VNI->def, OtherVNI->def) && "Broken LRQ");
 2593   assert(!SlotIndex::isSameInstr(VNI->def, V.OtherVNI->def) && "Broken LRQ");
 2691     assert(VNI->def.isEarlyClobber() &&
 2725     assert(Assignments[ValNo] != -1 && "Bad recursion?");
 2732     assert(V.OtherVNI && "OtherVNI not assigned, can't merge.");
 2733     assert(Other.Vals[V.OtherVNI->id].isAnalyzed() && "Missing recursion");
 2744     assert(V.OtherVNI && "OtherVNI not assigned, can't prune");
 2792   assert(OtherI != Other.LR.end() && "No conflict?");
 2842     assert(V.Resolution != CR_Impossible && "Unresolvable conflict");
 2851     assert(V.OtherVNI && "Inconsistent conflict resolution.");
 2864     assert(!TaintExtent.empty() && "There should be at least one conflict.");
 2874     assert(!SlotIndex::isSameInstr(VNI->def, TaintExtent.front().first) &&
 2878     assert(LastMI && "Range must end at a proper instruction");
 2881       assert(MI != MBB->end() && "Bad LastMI");
 2891         assert(LastMI && "Range must end at a proper instruction");
 3088   assert(&static_cast<LiveRange&>(LI) == &LR);
 3140         assert(I != LR.end());
 3153         assert(static_cast<LiveRange*>(LI) == &LR);
 3190       assert(MI && "No instruction to erase");
 3337       assert(Mask.any());
 3513   assert(Copy.isCopyLike());
 3522   assert(Copy.isCopyLike());
 3637   assert(WorkList.empty() && LocalWorkList.empty() && "Old data still around.");
 3736             assert((S.LaneMask & ~MaxMask).none());
lib/CodeGen/RegisterPressure.cpp
   53   assert((PrevMask & ~NewMask).none() && "Must not remove bits");
   74     assert(CurrSetPressure[*PSetI] >= Weight && "register pressure underflow");
  280     assert(lis && "IntervalPressure requires LiveIntervals");
  325   assert(P.LiveInRegs.empty() && "inconsistent max pressure result");
  337   assert(P.LiveOutRegs.empty() && "inconsistent max pressure result");
  345     assert(LiveRegs.size() == 0 && "no region boundary");
  361   assert(isBottomClosed() && "need bottom-up tracking to intialize.");
  384   assert(Pair.LaneMask.any());
  410   assert(Pair.LaneMask.any());
  507       assert(MO.isDef());
  539       assert(MO.isDef());
  661   assert(!PDiff.begin()->isValid() && "stale PDiff");
  715   assert(Pair.LaneMask.any());
  765   assert(!CurrPos->isDebugInstr());
  804     assert(Use.LaneMask.any());
  823             assert(I->LaneMask.none());
  852   assert(CurrPos != MBB->begin());
  877     assert(CurrPos == MBB->begin());
  896   assert(!TrackUntiedDefs && "unsupported mode");
  897   assert(CurrPos != MBB->end());
 1042   assert(!MI->isDebugInstr() && "Expect a nondebug instruction.");
 1051   assert(RegOpers.DeadDefs.size() == 0);
 1109   assert(Delta.CriticalMax.getUnitInc() >= 0 &&
 1180     assert((PDiffI->getUnitInc() >= 0) == (PNew >= POld)
 1245   assert(RequireIntervals);
 1255   assert(RequireIntervals);
 1266   assert(RequireIntervals);
 1283   assert(!MI->isDebugInstr() && "Expect a nondebug instruction.");
 1355   assert(Delta.CriticalMax.getUnitInc() >= 0 &&
lib/CodeGen/RegisterScavenging.cpp
   63   assert((NumRegUnits == 0 || NumRegUnits == TRI->getNumRegUnits()) &&
  110   assert(Tracking && "Must be tracking to determine kills and defs");
  113   assert(!MI.isDebugInstr() && "Debug values have no kills or defs");
  147       assert(MO.isDef());
  157   assert(Tracking && "Cannot unprocess because we're not tracking");
  181     assert(MBBI != MBB->end() && "Already past the end of the basic block!");
  184   assert(MBBI != MBB->end() && "Already at the end of the basic block!");
  243       assert(MO.isDef());
  261   assert(Tracking && "Must be tracking to determine kills and defs");
  311   assert(Survivor > 0 && "No candidates for scavenging");
  314   assert(StartMI != ME && "MI already at terminator");
  362   assert(RestorePointMI != StartMI &&
  454     assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
  594   assert(Reg != 0 && "No register left to scavenge!");
  635     assert(MBB == CommonMBB && "All defs+uses must be in the same basic block");
  639         assert((!RealDef || RealDef == &MI) &&
  645   assert(RealDef != nullptr && "Must have at least 1 Def");
  659   assert(FirstDef != MRI.def_end() &&
  727       assert(!MO.isInternalRead() && "Cannot assign inside bundles");
  728       assert((!MO.isUndef() || MO.isDef()) && "Cannot handle undef uses");
  742     assert(!MO.isInternalRead() && "Cannot assign inside bundles");
  743     assert((!MO.isUndef() || MO.isDef()) && "Cannot handle undef uses");
  744     assert(!MO.readsReg() && "Vreg use in first instruction not allowed");
lib/CodeGen/SafeStack.cpp
  292       assert(V == UI.get());
  430   assert(StaticTop && "The stack top isn't set.");
  541     assert(isPowerOf2_32(FrameAlignment));
  664     assert(isPowerOf2_32(Align));
  701         assert(II->use_empty());
  738   assert(F.hasFnAttribute(Attribute::SafeStack) &&
  740   assert(!F.isDeclaration() && "Can't run SafeStack on a function declaration");
  789   assert(BasePointer->getType() == StackPtrTy);
lib/CodeGen/SafeStackColoring.cpp
   43   assert(IT != AllocaNumbering.end());
  232         assert(!Started.test(AllocaNo) || Start[AllocaNo] == BBStart);
  239         assert(!Ended.test(AllocaNo));
lib/CodeGen/SafeStackColoring.h
  132     assert(NumInst >= 0);
lib/CodeGen/SafeStackLayout.cpp
   67   assert(Obj.Alignment <= MaxAlignment);
   74     assert(End >= R.Start);
lib/CodeGen/ScalarizeMaskedMemIntrin.cpp
  519   assert(isa<VectorType>(Src->getType()) &&
  521   assert(isa<VectorType>(Ptrs->getType()) &&
lib/CodeGen/ScheduleDAG.cpp
  139     assert(NumPreds < std::numeric_limits<unsigned>::max() &&
  141     assert(N->NumSuccs < std::numeric_limits<unsigned>::max() &&
  151       assert(NumPredsLeft < std::numeric_limits<unsigned>::max() &&
  161       assert(N->NumSuccsLeft < std::numeric_limits<unsigned>::max() &&
  185   assert(Succ != N->Succs.end() && "Mismatching preds / succs lists!");
  190     assert(NumPreds > 0 && "NumPreds will underflow!");
  191     assert(N->NumSuccs > 0 && "NumSuccs will underflow!");
  199       assert(NumPredsLeft > 0 && "NumPredsLeft will underflow!");
  207       assert(N->NumSuccsLeft > 0 && "NumSuccsLeft will underflow!");
  433   assert(!AnyNotSched);
  488       assert(SU.Succs.empty() && "SUnit should have no successors");
  516       assert(Node2Index[SU.NodeNum] > Node2Index[PD.getSUnit()->NodeNum] &&
  558     assert(!HasLoop && "Inserted edge creates a loop!");
  674   assert(Found && "Error in SUnit Graph!");
lib/CodeGen/ScheduleDAGInstrs.cpp
  160           assert(isIdentifiedObject(V));
  190   assert(bb == BB && "startBlock should set BB");
  231   assert(MO.isDef() && "expect physreg def");
  423     assert(deadDefHasNoUse(MO) && "Dead defs should have no uses");
  632       assert(NumNodes >= Itr->second.size());
  678   assert(BarrierChain != nullptr);
  689   assert(BarrierChain != nullptr);
  776   assert(Defs.empty() && Uses.empty() &&
  781   assert(CurrentVRegDefs.empty() && "nobody else should use CurrentVRegDefs");
  782   assert(CurrentVRegUses.empty() && "nobody else should use CurrentVRegUses");
  809     assert(SU && "No SUnit mapped to this MI");
  823       assert(&*RPTracker->getPos() == &MI && "RPTracker in sync");
  827     assert(
 1059   assert(N <= NodeNums.size());
 1319     assert(SubtreeClasses.getNumClasses() == RootSet.size()
 1355     assert(PredDep.getKind() == SDep::Data && "Subtrees are for data edges");
lib/CodeGen/ScoreboardHazardRecognizer.cpp
  139         assert((StageCycle - Stalls) < (int)RequiredScoreboard.getDepth() &&
  178   assert(MCID && "The scheduler must filter non-machineinstrs");
  193       assert(((cycle + i) < RequiredScoreboard.getDepth()) &&
lib/CodeGen/SelectionDAG/DAGCombiner.cpp
  207         assert(GoodWorklistEntry &&
  238       assert(N->getOpcode() != ISD::DELETED_NODE &&
  692       assert(LHSTy.isInteger() && "Shift amount is not an integer type!");
  971   assert(TLI.isCommutativeBinOp(Opc) && "Operation not commutative.");
  991   assert(N->getNumValues() == NumTo && "Broken CombineTo call!");
  997     assert((!To[i].getNode() ||
 1189     assert(PVT != VT && "Don't know what type to promote to!");
 1254     assert(PVT != VT && "Don't know what type to promote to!");
 1303     assert(PVT != VT && "Don't know what type to promote to!");
 1334     assert(PVT != VT && "Don't know what type to promote to!");
 1458     assert(N->getOpcode() != ISD::DELETED_NODE &&
 1467       assert(N->getValueType(0) == RV.getValueType() &&
 1627     assert(N->getOpcode() != ISD::DELETED_NODE &&
 1810       assert((OrigOpNumber != Ops.size()) &&
 1835     assert((OpWorkCount[CurOpNumber] > 0) &&
 1917   assert(TLI.isBinOp(BO->getOpcode()) && BO->getNumValues() == 1 &&
 1995   assert((N->getOpcode() == ISD::ADD || N->getOpcode() == ISD::SUB) &&
 2036   assert((N->getOpcode() == ISD::ADD || N->getOpcode() == ISD::SUB) &&
 2118       assert(Sub && "Constant folding failed");
 2127       assert(Add && "Constant folding failed");
 2947     assert(NewC && "Constant folding failed");
 2958       assert(NewC && "Constant folding failed");
 2969     assert(NewC && "Constant folding failed");
 2979     assert(NewC && "Constant folding failed");
 3338     assert((!N0IsConst ||
 3341     assert((!N1IsConst ||
 3426       assert(ShAmt < VT.getScalarSizeInBits() &&
 3564           assert(UserOpc == Opcode);
 4254   assert((LogicOpcode == ISD::AND || LogicOpcode == ISD::OR ||
 4256   assert(HandOpcode == N1.getOpcode() && "Bad input!");
 4370     assert(X.getValueType() == Y.getValueType() &&
 4419   assert(N0.getValueType() == N1.getValueType() &&
 4421   assert(LL.getValueType() == LR.getValueType() &&
 4637           assert(MaskBits <= Size);
 4757     assert(isa<StoreSDNode>(LDST) && "It is not a Load nor a Store SDNode");
 4853       assert(HasValue && "Node to be masked has no data result?");
 4917       assert(NewLoad &&
 4933   assert(N->getOpcode() == ISD::AND);
 4985   assert(And->getOpcode() == ISD::AND && "Expected an 'and' op");
 5712         assert((!ZeroN00 || !ZeroN01) && "Both inputs zero!");
 5713         assert((!ZeroN10 || !ZeroN11) && "Both inputs zero!");
 5741           assert((M0 >= 0 || M1 >= 0) && "Undef index!");
 5892   assert(OppShift && ExtractFrom && "Empty SDValue");
 5893   assert(
 6151     assert(LHS.getValueType() == RHS.getValueType());
 6333   assert(Op.getValueType().isScalarInteger() && "can't handle other types");
 6338   assert(Index < ByteWidth && "invalid index requested");
 6437   assert((BigEndian != LittleEndian) && "It should be either big endian or"
 6570   assert(FirstOffset != INT64_MAX && "First byte offset must be set");
 6571   assert(FirstStore && "First store must be set");
 6600     assert(CombinedValue.getValueType().getSizeInBits() > VT.getSizeInBits() &&
 6649   assert(N->getOpcode() == ISD::OR &&
 6667     assert(P.isMemory() && "Must be a memory byte provider");
 6669     assert(LoadBitWidth % 8 == 0 &&
 6693     assert(L->hasNUsesOfValue(1, 0) && L->isSimple() &&
 6696     assert(L->getOffset().isUndef() && "Unindexed load must have undef offset");
 6725   assert(!Loads.empty() && "All the bytes of the value must be loaded from "
 6727   assert(Base && "Base address of the accessed memory location must be set");
 6728   assert(FirstOffset != INT64_MAX && "First byte offset must be set");
 6736   assert(FirstByteProvider && "must be set");
 6788   assert(N->getOpcode() == ISD::XOR);
 6840     assert(TLI.hasAndNot(X) && "Only mask is a variable? Unreachable.");
 7076   assert(C1Node && "Expected a shift with constant operand");
 7130   assert(isConstOrConstSplat(N->getOperand(1)) && "Expected constant operand");
 7193   assert(isa<ConstantSDNode>(NewRHS) && "Folding was not successful!");
 7201   assert(N->getOpcode() == ISD::TRUNCATE);
 7202   assert(N->getOperand(0).getOpcode() == ISD::AND);
 8184   assert(isConstantOrConstantVector(C1) && isConstantOrConstantVector(C2) &&
 8519   assert(LHS.getOpcode() == ISD::CONCAT_VECTORS &&
 8556   assert(TopHalf && BottomHalf &&
 8893   assert((Opcode == ISD::SIGN_EXTEND || Opcode == ISD::ZERO_EXTEND ||
 9060   assert((N->getOpcode() == ISD::SIGN_EXTEND ||
 9111   assert(!DstVT.isScalableVector() && "Unexpected scalable vector type");
 9157   assert(N->getOpcode() == ISD::ZERO_EXTEND);
 9238   assert((CastOpcode == ISD::SIGN_EXTEND || CastOpcode == ISD::ZERO_EXTEND ||
 9381   assert((N->getOpcode() == ISD::SIGN_EXTEND ||
 9662   assert(Op0.getValueType() == Op1.getValueType());
 9680   assert((Extend->getOpcode() == ISD::ZERO_EXTEND ||
10124     assert(BigA_AssertVT.bitsLE(N0.getValueType()) &&
10144     assert(BigA_AssertVT.bitsLE(N0.getValueType()) &&
10597     assert(NVT.getSizeInBits() == VecTy.getSizeInBits() && "Invalid Size");
10676       assert((BuildVecNumElts % TruncVecNumElts) == 0 &&
10748       assert(V.getNode() && "The single defined operand is empty!");
10860   assert(N->getOpcode() == ISD::BUILD_PAIR);
11042       assert(VT.getSizeInBits() == 128);
11050         assert(N0.getOpcode() == ISD::FABS);
11068     assert(N0.getOpcode() == ISD::FABS);
11257   assert(SrcEltVT.isInteger() && DstEltVT.isInteger());
11834   assert(N->getOpcode() == ISD::FMUL && "Expected FMUL Operation");
13675     assert(OtherUses[i]->getOperand(!OffsetIdx).getNode() ==
13856   assert(AM != ISD::UNINDEXED);
13863   assert((Inc.getOpcode() != ISD::TargetConstant ||
13909   assert(Val.getValueType() == LDMemType &&
14061       assert(N->getValueType(2) == MVT::Other && "Malformed indexed loads?");
14108         assert(NewLoad.getNode() == N);
14274     assert(Origin && "No original load to compare against.");
14276     assert(Inst && "This slice is not bound to an instruction");
14277     assert(Inst->getValueSizeInBits(0) <= BitWidth &&
14289     assert(!(SliceSize & 0x7) && "Size is not a multiple of a byte.");
14296     assert(DAG && "Missing context");
14358     assert(DAG && "Missing context.");
14360     assert(!(Shift & 0x7) && "Shifts not aligned on Bytes are not supported.");
14363     assert(!(Origin->getValueSizeInBits(0) & 0x7) &&
14368     assert(TySizeInBytes > Offset &&
14382     assert(Inst && Origin && "Unable to replace a non-existing slice.");
14387     assert(Offset >= 0 && "Offset too big to fit in int64_t!");
14423     assert(DAG && "Missing context");
14485   assert(First.Origin == Second.Origin && First.Origin &&
14488   assert((UsedBits & Second.getUsedBits()) == 0 &&
14508     assert(LHS.Origin == RHS.Origin && "Different bases not implemented.");
14547     assert(GlobalLSCost.Loads > 0 && "We save more loads than we created!");
14688     assert(SliceInst->getOpcode() == ISD::LOAD &&
15101   assert(Chains.size() > 0 && "Chain should have generated a chain");
15195     assert(IsConstantSrc && "Merged vector elements should use vector store");
16163         assert(NewStore.getNode() == N);
16527       assert(NewMask[InsIndex] <
16659   assert(Ops.size() == NumElts && "Unexpected vector size");
16676   assert(OriginalLoad->isSimple());
16820       assert(InOp.getValueType().isInteger() && ScalarVT.isInteger());
16866       assert(X.getValueType().isScalarInteger() && ScalarVT.isScalarInteger() &&
16877         assert(XBitWidth % VecEltBitWidth == 0 &&
16914         assert(InOp.getValueType().isInteger() && ScalarVT.isInteger());
17122   assert(ElemRatio > 1 && "Invalid element size ratio");
17132     assert((Cast.getOpcode() == ISD::ANY_EXTEND ||
17143     assert(Index < Ops.size() && "Invalid index");
17149   assert(VecVT.getSizeInBits() == VT.getSizeInBits() &&
17191       assert(NumConcats >= 2 && "Concat needs at least two inputs!");
17273   assert(InVT1 == VecIn2.getValueType() && "Unexpected second input type.");
17283   assert(BV->getOpcode() == ISD::BUILD_VECTOR && "Expected build vector");
17660       assert(!V.isUndef() && "Splat of undef should have been handled earlier");
17857     assert(In.getValueType().isVector() && "Must concat vectors");
17933       assert(FoundMinVT && "Concat vector type mismatch");
17945           assert(SVT == OpVT.getScalarType() && "Concat vector type mismatch");
17955     assert(VT.getVectorNumElements() == Opnds.size() &&
18097   assert(ExtractIndex % VT.getVectorNumElements() == 0 &&
18282     assert((Idx % NumElems) == 0 &&
18462     assert(0 <= OpIdx && "Unknown concat_vectors op");
18698   assert(ShufMask.size() == SplatMask.size() && "Mask length mismatch");
18791   assert(Mask[ShufOp0Index] >= 0 && Mask[ShufOp0Index] < (int)Mask.size() &&
18832     assert(Mask[i] >= 0 && Mask[i] < e && "Unexpected shuffle mask value");
18851   assert(N0.getValueType() == VT && "Vector shuffle must be normalized in DAG");
18930       assert(V->getNumOperands() == NumElts &&
19072     assert(N1->getOperand(0).getValueType() == VT &&
19102     assert(OtherSV->getOperand(0).getValueType() == VT &&
19446   assert(N->getOpcode() == ISD::AND && "Unexpected opcode!");
19581   assert(N->getValueType(0).isVector() &&
19682   assert(N0.getOpcode() ==ISD::SETCC && "First argument must be a SetCC node!");
20374   assert(Iterations > 0);
lib/CodeGen/SelectionDAG/FastISel.cpp
  131   assert(LocalValueMap.empty() &&
  160     assert(VI != LocalValueMap.end() && "Missed an argument?");
  282     assert(I != OrderMap.Orders.end() &&
  301     assert(UsedByPHI && "must be users if not used by a phi");
  546   assert(I.isValid() && E.isValid() && std::distance(I, E) > 0 &&
  793   assert(I->getCalledFunction()->getReturnType()->isVoidTy() &&
  809   assert(isa<ConstantInt>(I->getOperand(PatchPointOpers::IDPos)) &&
  814   assert(isa<ConstantInt>(I->getOperand(PatchPointOpers::NBytesPos)) &&
  878     assert(!V->getType()->isEmptyTy() && "Empty type passed to intrinsic.");
  916   assert(isa<ConstantInt>(I->getOperand(PatchPointOpers::NArgPos)) &&
  925   assert(I->getNumArgOperands() >= NumMetaOpers + NumArgs &&
  935   assert(CLI.Call && "No call instruction specified.");
  941     assert(CLI.NumResultRegs == 0 && "Unexpected result register.");
  948   assert(isa<ConstantInt>(I->getOperand(PatchPointOpers::IDPos)) &&
  953   assert(isa<ConstantInt>(I->getOperand(PatchPointOpers::NBytesPos)) &&
 1120     assert(!V->getType()->isEmptyTy() && "Empty type passed to intrinsic.");
 1234   assert(CLI.Call && "No call instruction specified.");
 1347     assert(DI->getVariable() && "Missing variable");
 1388       assert(DI->getVariable()->isValidLocationForIntrinsic(DbgLoc) &&
 1409     assert(DI->getVariable()->isValidLocationForIntrinsic(DbgLoc) &&
 1449     assert(DI->getLabel() && "Missing label");
 2230   assert(Register::isVirtualRegister(Op0) &&
 2317   assert(LI->hasOneUse() &&
lib/CodeGen/SelectionDAG/FunctionLoweringInfo.cpp
  245         assert(&*BB.begin() == PadInst &&
  250         assert(&*BB.begin() == PadInst && "WinEHPrepare failed to demote PHIs");
  279       assert(PHIReg && "PHI node does not have an assigned virtual register!");
  418   assert(ValueVTs.size() == 1 &&
  446     assert(ValueMap.count(V) && "V should have been placed in ValueMap when its"
  461   assert(DestLOI.Known.Zero.getBitWidth() == BitWidth &&
  481     assert(ValueMap.count(V) && "V should have been placed in ValueMap when "
  525   assert(VReg && "null vreg in exception pointer table!");
lib/CodeGen/SelectionDAG/InstrEmitter.cpp
   96     assert(isNew && "Node emitted out of order - early");
  163     assert(TRI->isTypeLegalForClass(*UseRC, VT) &&
  186   assert(isNew && "Node emitted out of order - early");
  194   assert(Node->getMachineOpcode() != TargetOpcode::IMPLICIT_DEF &&
  222       assert(Register::isPhysicalRegister(VRBase));
  246       assert(RC && "Isn't a register operand!");
  259       assert(isNew && "Node emitted out of order - early");
  282   assert(I != VRBaseMap.end() && "Node emitted out of order - late");
  297   assert(Op.getValueType() != MVT::Other &&
  321         assert(OpRC && "Constraints cannot be fulfilled for allocation");
  327         assert(ConstrainedRC->isAllocatable() &&
  441     assert(Op.getValueType() != MVT::Other &&
  466   assert(RC && "No legal register class for VT supports that SubIdx");
  572     assert(SRC && "No register class supports VT and SubIdx for INSERT_SUBREG");
  600   assert(isNew && "Node emitted out of order - early");
  623   assert(isNew && "Node emitted out of order - early");
  643   assert((NumOps & 1) == 1 &&
  671   assert(isNew && "Node emitted out of order - early");
  682   assert(cast<DILocalVariable>(Var)->isValidLocationForIntrinsic(DL) &&
  768   assert(cast<DILabel>(Label)->isValidLocationForIntrinsic(DL) &&
  835     assert(NumMIOperands >= II.getNumOperands() &&
  838     assert(NumMIOperands >= II.getNumOperands() &&
  892   assert((!HasOptPRefs || !HasPhysRegOuts) &&
 1140         assert(MO && "No def operand for clobbered register?");
lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
  210     assert(Old->getNumValues() == New->getNumValues() &&
  266   assert(NumEltsGrowth && "Cannot promote to vector type with fewer elts!");
  281   assert(NewMask.size() == NumDestElts && "Non-integer NumEltsGrowth?");
  282   assert(TLI.isShuffleMaskLegal(NewMask, NVT) && "Shuffle not legal?");
  302     assert((VT == MVT::f64 || VT == MVT::f32) && "Invalid type expansion");
  526       assert(NVT.getSizeInBits() == VT.getSizeInBits() &&
  558     assert(!StVT.isVector() && "Unsupported truncstore!");
  560     assert(LogStWidth < 32);
  562     assert(RoundWidth < StWidth);
  564     assert(ExtraWidth < RoundWidth);
  565     assert(!(RoundWidth % 8) && !(ExtraWidth % 8) &&
  637       assert(!StVT.isVector() &&
  699       assert(NVT.getSizeInBits() == VT.getSizeInBits() &&
  709       assert(RVal.getNode() != Node && "Load must be completely replaced");
  772     assert(!SrcVT.isVector() && "Unsupported extload!");
  774     assert(LogSrcWidth < 32);
  776     assert(RoundWidth < SrcWidth);
  778     assert(ExtraWidth < RoundWidth);
  779     assert(!(RoundWidth % 8) && !(ExtraWidth % 8) &&
  919       assert(!SrcVT.isVector() &&
  926       assert(ExtType != ISD::EXTLOAD &&
  951     assert(Value.getNode() != Node && "Load must be completely replaced");
  973     assert(TLI.getTypeAction(*DAG.getContext(), Node->getValueType(i)) ==
  978     assert((TLI.getTypeAction(*DAG.getContext(), Op.getValueType()) ==
 1359   assert(Op.getValueType().isVector() && "Non-vector insert subvector!");
 1402   assert(TypeByteSize > 0 && "Vector element type too small for stack store!");
 1467     assert(FloatVT.isByteSized() && "Unsupported floating point type!");
 1582   assert(SPReg && "Target cannot require DYNAMIC_STACKALLOC expansion and"
 1673         assert(TLI.isCondCodeLegal(ISD::SETOEQ, OpVT)
 1677         assert(TLI.isCondCodeLegal(ISD::SETUNE, OpVT)
 1770     assert(SrcSize == SlotSize && "Invalid store");
 1779   assert(SlotSize < DestSize && "Unknown extension!");
 1872     assert(IntermedVals.size() <= 2 && IntermedVals.size() > 0 &&
 1956         assert(Node->getOperand(i).isUndef());
 2402   assert(!isSigned && "Legalize cannot Expand SINT_TO_FP for i64 yet");
 2470     assert(NewInTy.isInteger() && "Ran out of possibilities!");
 2511     assert(NewOutTy.isInteger() && "Ran out of possibilities!");
 2809       assert(VT.isFloatingPoint() && "Unknown value type!");
 2977         assert(NewVT.bitsEq(VT));
 2988         assert(factor > 0);
 3186     assert(TLI.isOperationLegalOrCustom(ISD::ADD, VT) &&
 3258     assert(TLI.isTypeLegal(HalfType));
 3563       assert(!TLI.isOperationExpand(ISD::SELECT, VT) &&
 3602       assert(Legalized && "Can't legalize SELECT_CC with legal condition!");
 3634     assert(Legalized && "Can't legalize BR_CC with legal condition!");
 3636     assert(!NeedInvert && "Don't know how to invert BR_CC!");
 3663     assert(VT.isVector() && "Unable to legalize non-vector shift");
 3664     assert(TLI.isTypeLegal(VT.getScalarType())&& "Element type must be legal");
 3794     assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected atomic op or value type!");
 4042     assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unable to expand fp_to_fp16");
 4117   assert(TLI.isTypeLegal(MidVT) && "unexpected");
 4199       assert(OVT.isInteger()
 4235       assert(OVT.isInteger() && "Cannot promote logic operation");
 4417     assert(NVT.isVector() && OVT.getSizeInBits() == NVT.getSizeInBits() &&
 4419     assert(NewEltVT.bitsLT(EltVT) && "not handled");
 4450     assert(NVT.isVector() && OVT.getSizeInBits() == NVT.getSizeInBits() &&
 4452     assert(NewEltVT.bitsLT(EltVT) && "not handled");
 4496     assert(NVT.isVector() && OVT.getSizeInBits() == NVT.getSizeInBits() &&
 4498     assert(NewEltVT.bitsLT(EltVT) && "not handled");
 4561     assert(NVT.getSizeInBits() == OVT.getSizeInBits() &&
 4563     assert(AM->getMemoryVT().getSizeInBits() == NVT.getSizeInBits() &&
lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp
  110     assert(R.getNode() != N);
  527   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_EXTEND!");
  549   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_EXTEND!");
  563   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_ROUND!");
  588   assert(N->getOperand(1).getValueType() == MVT::i32 &&
  807   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported XINT_TO_FP!");
  863   assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
  886   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_EXTEND libcall");
  898   assert(N->getOpcode() == ISD::FP_ROUND || N->getOpcode() == ISD::FP_TO_FP16);
  905   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_ROUND libcall");
  958   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_TO_XINT!");
 1006     assert(NewLHS.getValueType() == N->getValueType(0) &&
 1018   assert(ISD::isUNINDEXEDStore(N) && "Indexed store during type legalization!");
 1019   assert(OpNo == 1 && "Can only soften the stored value!");
 1182   assert(NVT.getSizeInBits() == 64 &&
 1196   assert(N->getValueType(0) == MVT::ppcf128 &&
 1517   assert(ISD::isUNINDEXEDLoad(N) && "Indexed load during type legalization!");
 1524   assert(NVT.isByteSized() && "Expanded type not byte sized!");
 1525   assert(LD->getMemoryVT().bitsLE(NVT) && "Float type not round?");
 1544   assert(N->getValueType(0) == MVT::ppcf128 && "Unsupported XINT_TO_FP!");
 1572     assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported XINT_TO_FP!");
 1669   assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
 1686   assert(NewLHS.getValueType() == MVT::ppcf128 && "Unsupported setcc type!");
 1727   assert(N->getOperand(1).getValueType() == MVT::ppcf128 &&
 1738   assert(N->getOperand(0).getValueType() == MVT::ppcf128 &&
 1752   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_TO_SINT!");
 1762   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported FP_TO_UINT!");
 1793     assert(NewLHS.getValueType() == N->getValueType(0) &&
 1807   assert(ISD::isUNINDEXEDStore(N) && "Indexed store during type legalization!");
 1808   assert(OpNo == 1 && "Can only expand the stored value so far");
 1816   assert(NVT.isByteSized() && "Expanded type not byte sized!");
 1817   assert(ST->getMemoryVT().bitsLE(NVT) && "Float type not round?");
 1951   assert (OpNo == 1 && "Only Operand 1 must need promotion here");
lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
  250     assert(N->getOpcode() == ISD::ATOMIC_CMP_SWAP_WITH_SUCCESS);
  425   assert(isa<ConstantSDNode>(Result) && "Didn't constant fold ext?");
  553     assert(Res.getValueType().bitsLE(NVT) && "Extension doesn't make sense!");
  565       assert(N->getOpcode() == ISD::ANY_EXTEND && "Unknown integer extension!");
  575   assert(ISD::isUNINDEXEDLoad(N) && "Indexed load during type legalization!");
  606   assert(NVT == ExtPassThru.getValueType() &&
  630   assert(NumOps <= 3 && "Too many operands");
  838   assert(SVT.isVector() == N->getOperand(0).getValueType().isVector() &&
  924     assert(InVT.isVector() && "Cannot split scalar types");
  926     assert(NumElts == NVT.getVectorNumElements() &&
  928     assert(isPowerOf2_32(NumElts) &&
 1234   assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
 1309   assert(OpNo == 2 && "Don't know how to promote this operand!");
 1323   assert(OpNo == 1 && "only know how to promote condition");
 1338   assert(Lo.getValueType() == N->getValueType(0) && "Operand over promoted?");
 1353   assert(!((NumElts & 1) && (!TLI.isTypeLegal(VecVT))) &&
 1359   assert(N->getOperand(0).getValueSizeInBits() >=
 1377     assert(N->getOperand(1).getValueSizeInBits() >=
 1386   assert(OpNo == 2 && "Different operand and result vector types?");
 1410   assert(OpNo == 0 && "Only know how to promote the condition!");
 1427   assert(OpNo == 0 && "Don't know how to promote this operand!");
 1439   assert(OpNo == 0 && "Don't know how to promote this operand!");
 1468   assert(ISD::isUNINDEXEDStore(N) && "Indexed store during type legalization!");
 1495     assert(OpNo == 1 && "Unexpected operand for promotion");
 1507   assert(OpNo == 2 && "Only know how to promote the mask!");
 1574   assert(OpNo == 2 && "Don't know how to promote this operand!");
 1599   assert(OpNo > 1 && "Don't know how to promote this operand!");
 1817   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected atomic op or value type!");
 1886   assert(N->getOpcode() == ISD::SRA && "Unknown shift!");
 1920   assert(isPowerOf2_32(NVTBits) &&
 2006   assert(isPowerOf2_32(NVTBits) &&
 2388     assert(getTypeAction(Op.getValueType()) ==
 2392     assert(Res.getValueType() == N->getValueType(0) &&
 2564   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected fp-to-sint conversion!");
 2581   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected fp-to-uint conversion!");
 2601   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected llround input type!");
 2629   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unexpected llrint input type!");
 2650   assert(ISD::isUNINDEXEDLoad(N) && "Indexed load during type legalization!");
 2662   assert(NVT.isByteSized() && "Expanded type not byte sized!");
 2684       assert(ExtType == ISD::EXTLOAD && "Unknown extload!");
 2917   assert(Scale <= VTSize && "Scale can't be larger than the value type size.");
 2934   assert((VTSize == NVTSize * 2) && "Expected the new value type to be half "
 3028     assert(OverflowBits <= VTSize && OverflowBits > NVTSize &&
 3146   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported SDIV!");
 3175     assert(N->getOpcode() == ISD::SRA && "Unknown shift!");
 3199     assert(ShiftTy.getScalarSizeInBits() >=
 3235     assert(N->getOpcode() == ISD::SRA && "Unknown shift!");
 3275     assert(getTypeAction(Op.getValueType()) ==
 3279     assert(Res.getValueType() == N->getValueType(0) &&
 3337   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported SREM!");
 3427   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported XMULO!");
 3495   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported UDIV!");
 3522   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported UREM!");
 3540     assert(getTypeAction(Op.getValueType()) ==
 3544     assert(Res.getValueType() == N->getValueType(0) &&
 3635   assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
 3833     assert(NewLHS.getValueType() == N->getValueType(0) &&
 3883   assert(LC != RTLIB::UNKNOWN_LIBCALL &&
 3894   assert(ISD::isUNINDEXEDStore(N) && "Indexed store during type legalization!");
 3895   assert(OpNo == 1 && "Can only expand the stored value so far");
 3907   assert(NVT.isByteSized() && "Expanded type not byte sized!");
 4050   assert(LC != RTLIB::UNKNOWN_LIBCALL &&
 4072   assert(NOutVT.isVector() && "This type must be promoted to a vector type");
 4122   assert(NOutVT.isVector() && "This type must be promoted to a vector type");
 4150   assert(!N->getOperand(0).getValueType().isVector() &&
 4155   assert(NOutVT.isVector() && "This type must be promoted to a vector type");
 4168   assert(!SplatVal.getValueType().isVector() && "Input must be a scalar");
 4172   assert(NOutVT.isVector() && "Type must be promoted to a vector type");
 4185   assert(NOutVT.isVector() && "This type must be promoted to a vector type");
 4192   assert(NumElem * NumOperands == NumOutElem &&
 4202     assert(NumElem == Op.getValueType().getVectorNumElements() &&
 4219   assert(NVT.isVector() && "This type must be promoted to a vector type");
 4254   assert(NOutVT.isVector() && "This type must be promoted to a vector type");
lib/CodeGen/SelectionDAG/LegalizeTypes.cpp
   95             assert(UI->getNodeId() == NewNode &&
  108         assert(NewVal.getNode()->getNodeId() != NewNode &&
  182       assert(UI->getNodeId() == NewNode && "NewNode used by non-NewNode!");
  222     assert(N->getNodeId() == ReadyToProcess &&
  342       assert(N->getNodeId() == ReadyToProcess && "Node ID recalculated?");
  354       assert(N->getNumValues() == M->getNumValues() &&
  359       assert(N->getNodeId() == NewNode && "Unexpected node state!");
  375     assert(N->getNodeId() == ReadyToProcess && "Node ID recalculated?");
  403       assert(NodeId == Unanalyzed && "Unknown node ID!");
  561     assert(Id != I->second && "Id is mapped to itself.");
  586       assert(N->getNodeId() != DAGTypeLegalizer::ReadyToProcess &&
  591       assert(E && "Node not replaced?");
  610       assert(N->getNodeId() != DAGTypeLegalizer::ReadyToProcess &&
  623   assert(From.getNode() != To.getNode() && "Potential legalization loop!");
  658         assert(M->getNodeId() != NewNode && "Analysis resulted in NewNode!");
  659         assert(N->getNumValues() == M->getNumValues() &&
  686   assert(Result.getValueType() ==
  692   assert((OpIdEntry == 0) && "Node is already promoted!");
  700   assert(Result.getValueType() ==
  706   assert((OpIdEntry == 0) && "Node is already converted to integer!");
  711   assert(Result.getValueType() ==
  717   assert((OpIdEntry == 0) && "Node is already promoted!");
  725   assert(Result.getValueSizeInBits() >= Op.getScalarValueSizeInBits() &&
  730   assert((OpIdEntry == 0) && "Node is already scalarized!");
  737   assert((Entry.first != 0) && "Operand isn't expanded");
  744   assert(Lo.getValueType() ==
  766   assert((Entry.first == 0) && "Node already expanded");
  774   assert((Entry.first != 0) && "Operand isn't expanded");
  781   assert(Lo.getValueType() ==
  790   assert((Entry.first == 0) && "Node already expanded");
  800   assert(Lo.getNode() && "Operand isn't split");
  806   assert(Lo.getValueType().getVectorElementType() ==
  818   assert((Entry.first == 0) && "Node already split");
  824   assert(Result.getValueType() ==
  830   assert((OpIdEntry == 0) && "Node already widened!");
  848   assert(Op.getValueType().isVector() && "Only applies to vectors!");
  904   assert(Results.size() == N->getNumValues() &&
  928   assert(Results.size() == N->getNumValues() &&
 1057   assert(LoVT.getSizeInBits() + HiVT.getSizeInBits() ==
lib/CodeGen/SelectionDAG/LegalizeTypes.h
  137     assert(V.getNode() && "Getting TableId on SDValue()");
  143       assert(I->second && "All Ids should be nonzero");
  150     assert(NextValueId != 0 &&
  157     assert(Id && "TableId should be non-zero");
  252     assert(PromotedOp.getNode() && "Operand wasn't promoted?");
  477       assert(isSimpleLegalType(Op.getValueType()) &&
  482     assert(SoftenedOp.getNode() && "Unconverted op in SoftenedFloats?");
  620     assert(PromotedOp.getNode() && "Operand wasn't promoted?");
  661     assert(ScalarizedOp.getNode() && "Operand wasn't scalarized?");
  787     assert(WidenedOp.getNode() && "Operand wasn't widened?");
lib/CodeGen/SelectionDAG/LegalizeTypesGeneric.cpp
   86       assert(!(InVT.getVectorNumElements() & 1) && "Unsupported BITCAST");
  153   assert(NOutVT.isByteSized() && "Expanded type not byte sized!");
  199   assert(Part.getValueType() == N->getValueType(0) &&
  221     assert(OldEltVT.bitsLT(OldVT) && "Result type smaller then element type!");
  247   assert(ISD::isNormalLoad(N) && "This routine only for normal loads!");
  258   assert(NVT.isByteSized() && "Expanded type not byte sized!");
  315   assert(Op.getValueType().isInteger());
  376   assert(OldVT == VecVT.getVectorElementType() &&
  416   assert(OldEVT == VecVT.getVectorElementType() &&
  445   assert(VT.getVectorElementType() == N->getOperand(0).getValueType() &&
  457   assert(ISD::isNormalStore(N) && "This routine only for normal stores!");
  458   assert(OpNo == 1 && "Can only expand the stored value so far");
  469   assert(NVT.isByteSized() && "Expanded type not byte sized!");
lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
  211   assert(LegalizedNodes.count(OldRoot) && "Root didn't get legalized?");
  258           assert(Lowered->getNumValues() == Op->getNumValues() &&
  540   assert(Op.getNode()->getNumValues() == 1 &&
  574   assert(NVT.getVectorNumElements() == VT.getVectorNumElements() &&
  599   assert(NVT.getVectorNumElements() == VT.getVectorNumElements() &&
  649     assert(WideVT.isRound() &&
  652     assert(WideVT.bitsGE(SrcEltVT) &&
  701       assert(BitOffset < WideBits && "Unexpected offset!");
  898   assert(VT.isVector() && !Mask.getValueType().isVector()
  975     assert((VT.getSizeInBits() % SrcVT.getScalarSizeInBits()) == 0 &&
 1035     assert((VT.getSizeInBits() % SrcVT.getScalarSizeInBits()) == 0 &&
 1218   assert((BW == 64 || BW == 32) &&
lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
  359   assert(N->isUnindexed() && "Indexed vector load?");
  488         assert(VecBool == TargetLowering::UndefinedBooleanContent ||
  495         assert(VecBool == TargetLowering::UndefinedBooleanContent ||
  543   assert(N->getValueType(0).isVector() &&
  660   assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
  678   assert(N->getValueType(0).getVectorNumElements() == 1 &&
  691   assert(N->getValueType(0).getVectorNumElements() == 1 &&
  740   assert(N->getValueType(0).isVector() &&
  743   assert(N->getValueType(0) == MVT::v1i1 && "Expected v1i1 type");
  769   assert(N->isUnindexed() && "Indexed store of one-element vector?");
  770   assert(OpNo == 1 && "Do not know how to scalarize this operand!");
  798   assert(OpNo == 1 && "Wrong operand for scalarization!");
 1129   assert(!(N->getNumOperands() & 1) && "Unsupported CONCAT_VECTORS");
 1280   assert((2 * OutNumElements) <= InNumElements &&
 1537   assert(ISD::isUNINDEXEDLoad(LD) && "Indexed load during type legalization!");
 1705   assert(N->getValueType(0).isVector() &&
 2063     assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 2 &&
 2066     assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
 2076   assert(OpNo == 0 && "Illegal operand must be mask");
 2083   assert(Mask.getValueType().isVector() && "VSELECT without a vector mask?");
 2087   assert(Lo.getValueType() == Hi.getValueType() &&
 2092   assert(LoOpVT == HiOpVT && "Asymmetric vector split?");
 2114   assert(VecVT.isVector() && "Can only split reduce vector operand");
 2210     assert(IdxVal + SubVT.getVectorNumElements() <= LoElts &&
 2480   assert(N->isUnindexed() && "Indexed store of vector?");
 2481   assert(OpNo == 1 && "Can only split the stored value");
 2573   assert(!(NumElements & 1) && "Splitting vector, but not in half!");
 2581   assert(LoOutVT == HiOutVT && "Unequal split?");
 2627   assert(N->getValueType(0).isVector() &&
 3129       assert(Oper.getValueType() == N->getValueType(0) && 
 3585   assert(WidenNumElts >= NumElts && "Shrinking vector instead of widening!");
 3846   assert(isSETCCorConvertedSETCC(InMask) && "Unexpected mask argument.");
 3869   assert(Mask->getValueType(0).getScalarSizeInBits() ==
 3888   assert((Mask->getValueType(0) == ToMaskVT) &&
 4037   assert(InOp1.getValueType() == WidenVT && InOp2.getValueType() == WidenVT);
 4081   assert(N->getValueType(0).isVector() &&
 4089   assert(InVT.isVector() && "can not widen non-vector type");
 4114   assert(InOp1.getValueType() == WidenInVT &&
 4201     assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 2 &&
 4204     assert(Res.getValueType() == N->getValueType(0) && N->getNumValues() == 1 &&
 4216   assert(getTypeAction(InOp.getValueType()) ==
 4220   assert(VT.getVectorNumElements() <
 4235         assert(FixedVT.getVectorNumElements() >= VT.getVectorNumElements() &&
 4237         assert(FixedVT.getVectorNumElements() != InVT.getVectorNumElements() &&
 4286   assert(getTypeAction(InOp.getValueType()) ==
 4410     assert(getTypeAction(InOp.getValueType()) ==
 4455   assert((OpNo == 1 || OpNo == 3) &&
 4485   assert(Mask.getValueType().getVectorNumElements() ==
 4494   assert(OpNo == 4 && "Can widen only the index of mgather");
 4644   assert(VT.isVector() && !VT.isPow2VectorType() && isTypeLegal(VT));
 4770   assert(LdVT.isVector() && WidenVT.isVector());
 4771   assert(LdVT.getVectorElementType() == WidenVT.getVectorElementType());
 4802     assert(WidenWidth % NewVTWidth == 0);
 4921   assert(LdVT.isVector() && WidenVT.isVector());
 4978   assert(StVT.getVectorElementType() == ValEltVT);
 5045   assert(StVT.isVector() && ValOp.getValueType().isVector());
 5046   assert(StVT.bitsLT(ValOp.getValueType()));
 5080   assert(InVT.getVectorElementType() == NVT.getVectorElementType() &&
lib/CodeGen/SelectionDAG/ResourcePriorityQueue.cpp
   52   assert(ResourcesModel && "Unimplemented CreateTargetScheduleState.");
  619   assert(!Queue.empty() && "Queue is empty!");
lib/CodeGen/SelectionDAG/SDNodeDbgValue.h
   80     assert((Kind == VREG || Kind == FRAMEIX) &&
   99   SDNode *getSDNode() const { assert (kind==SDNODE); return u.s.Node; }
  102   unsigned getResNo() const { assert (kind==SDNODE); return u.s.ResNo; }
  105   const Value *getConst() const { assert (kind==CONST); return u.Const; }
  108   unsigned getFrameIx() const { assert (kind==FRAMEIX); return u.FrameIx; }
  111   unsigned getVReg() const { assert (kind==VREG); return u.VReg; }
lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp
  185   assert(CurCycle >= SU->getHeight() && "Node scheduled below its height!");
  195         assert(NumLiveRegs > 0 && "NumLiveRegs is already zero!");
  196         assert(LiveRegDefs[Succ.getReg()] == SU &&
  239     assert(NewNodes.size() == 2 && "Expected a load folding node!");
  251     assert(N->getNodeId() == -1 && "Node already inserted!");
  433     assert(MCID.ImplicitDefs && "Physical reg def must be in implicit def list!");
  533     assert(RootSU->Succs.empty() && "Graph root shouldn't have successors!");
  569         assert(LRegs.size() == 1 && "Can't handle this yet!");
  683         assert(OpN->getNodeId() != 0 && "Glue operand not ready?");
  699       assert(Degree > 0 && "Predecessor over-released!");
lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp
  368   assert(Interferences.empty() && LRegsMap.empty() && "stale Interferences");
  508       assert(Best);
  518         assert(NestLevel != 0);
  564       assert((!RegDef || RegDef == SU || RegDef == Pred.getSUnit()) &&
  585         assert(N && "Must find call sequence start");
  601     assert(PendingQueue.empty() && "pending instrs not allowed in this mode");
  703     assert(SU->getNode()->isMachineOpcode() &&
  773       assert(NumLiveRegs > 0 && "NumLiveRegs is already zero!");
  788         assert(NumLiveRegs > 0 && "NumLiveRegs is already zero!");
  828   assert(PredSU->NumSuccsLeft < std::numeric_limits<unsigned>::max() &&
  842       assert(NumLiveRegs > 0 && "NumLiveRegs is already zero!");
  843       assert(LiveRegDefs[Pred.getReg()] == Pred.getSUnit() &&
  860       assert(SeqEnd && "Call sequence start/end must be known");
  861       assert(!LiveRegDefs[CallResource]);
  862       assert(!LiveRegGens[CallResource]);
  876         assert(NumLiveRegs > 0 && "NumLiveRegs is already zero!");
  877         assert(LiveRegDefs[CallResource]);
  878         assert(LiveRegGens[CallResource]);
  961   assert(!SU->isSucc(OldSU) && "Something is wrong!");
  992   assert(NewNodes.size() == 2 && "Expected a load folding node!");
 1284     assert(MCID.ImplicitDefs && "Physical reg def must be in implicit def list!");
 1481         assert(CurSU->isPending && "Interferences are pending");
 1553     assert(LRegs.size() == 1 && "Can't handle this yet!");
 1591   assert(CurSU && "Unable to resolve live physical register dependencies!");
 1604     assert(RootSU->Succs.empty() && "Graph root shouldn't have successors!");
 1626       assert(MinAvailableCycle < std::numeric_limits<unsigned>::max() &&
 1803     assert(!U->NodeQueueId && "Node in the queue already");
 1809     assert(!Queue.empty() && "Queue is empty!");
 1810     assert(SU->NodeQueueId != 0 && "Not in queue!");
 1968           assert(It.SU != PredSU && "Trying to push an element twice?");
 1988       assert(PredSethiUllman > 0 && "We should have evaluated this pred!");
 2003   assert(SUNumbers[SU->NodeNum] > 0 && "SethiUllman should never be zero!");
 2031   assert(SU->NodeNum < SethiUllmanNumbers.size());
 2433       assert(PredSU->getNode()->getOpcode() == ISD::CopyFromReg &&
 2620   assert(left->NodeQueueId && right->NodeQueueId &&
 2879   assert(ImpDefs && "Caller should check hasPhysRegDefs");
 2989     assert(PredSU);
 3031       assert(!Edge.isAssignedRegDep());
lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
   75   assert((Addr == nullptr || Addr == &SUnits[0]) &&
  187   assert((N->getValueType(N->getNumValues() - 1) == MVT::Glue &&
  371       assert(N->getNodeId() == -1 && "Node already inserted!");
  388           assert(N->getNodeId() == -1 && "Node already inserted!");
  411     assert(N->getNodeId() == -1 && "Node already inserted!");
  476         assert(OpSU && "Node has no SUnit!");
  480         assert(OpVT != MVT::Glue && "Glued nodes should be in same sunit!");
  487         assert((PhysReg == 0 || !isChain) &&
  601   assert(SU->NumRegDefsLeft == 0 && "expect a new node");
  603     assert(SU->NumRegDefsLeft < USHRT_MAX && "overflow is ok but unexpected");
  725   assert(Sequence.size() - Noops == ScheduledNodes &&
  795       assert(VRI != VRBaseMap.end() && "Node emitted out of order - late");
  810       assert(I->getReg() && "Unknown physical register!");
  814       assert(isNew && "Node emitted out of order - early");
  954       assert(MI);
  982       assert((*DI)->getOrder() >= LastOrder &&
lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.h
  151         assert(IsValid() && "bad iterator");
lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
  124   assert(!D.isWeak() && "unexpected artificial DAG edge");
  141     assert(!I->isAssignedRegDep() &&
  156   assert(CurCycle >= SU->getDepth() && "Node scheduled above its depth!");
  197         assert(PendingQueue[i]->getDepth() > CurCycle && "Negative latency?");
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
  120   assert(VT.isFloatingPoint() && "Can only convert between FP types");
  752   assert(N->getIterator() != AllNodes.begin() &&
  754   assert(N->use_empty() && "Cannot delete a node that is not dead!");
  797     assert(N->getNumValues() == 1 && "Too many results!");
  798     assert(!VT.isVector() && (VT.isInteger() || VT.isFloatingPoint()) &&
  800     assert(N->getNumOperands() == 2 && "Wrong number of operands!");
  801     assert(N->getOperand(0).getValueType() == N->getOperand(1).getValueType() &&
  803     assert(N->getOperand(0).getValueType().isInteger() == VT.isInteger() &&
  805     assert(VT.getSizeInBits() == 2 * N->getOperand(0).getValueSizeInBits() &&
  810     assert(N->getNumValues() == 1 && "Too many results!");
  811     assert(N->getValueType(0).isVector() && "Wrong return type!");
  812     assert(N->getNumOperands() == N->getValueType(0).getVectorNumElements() &&
  816       assert((I->getValueType() == EltVT ||
  820       assert(I->getValueType() == N->getOperand(0).getValueType() &&
  852     assert(CondCodeNodes[cast<CondCodeSDNode>(N)->get()] &&
  883     assert(N->getOpcode() != ISD::DELETED_NODE && "DELETED_NODE in CSEMap!");
  884     assert(N->getOpcode() != ISD::EntryToken && "EntryToken in CSEMap!");
 1020   assert(!UpdateListeners && "Dangling registered DAGUpdateListeners");
 1027   assert(&*AllNodes.begin() == &EntryNode);
 1132   assert(!VT.isVector() &&
 1186   assert((EltVT.getSizeInBits() >= 64 ||
 1199   assert(VT.isInteger() && "Cannot create FP integer constant!");
 1232     assert(ViaVecVT.getSizeInBits() == VT.getSizeInBits());
 1261   assert(Elt->getBitWidth() == EltVT.getSizeInBits() &&
 1308   assert(VT.isFloatingPoint() && "Cannot create integer FP constant!");
 1359   assert((TargetFlags == 0 || isTargetGA) &&
 1406   assert((TargetFlags == 0 || isTarget) &&
 1427   assert((TargetFlags == 0 || isTarget) &&
 1455   assert((TargetFlags == 0 || isTarget) &&
 1571   assert(VT.getVectorNumElements() == Mask.size() &&
 1573   assert(VT == N1.getValueType() && VT == N2.getValueType() &&
 1583   assert(llvm::all_of(Mask,
 1826   assert((!V || V->getType()->isPointerTy()) &&
 1990     assert(!OpVT.isInteger() && "Illegal setcc for integer!");
 2147     assert(CV && "Const value should be ConstSDNode.");
 2248   assert(VT.isVector() && "Vector type expected");
 2251   assert(NumElts == DemandedElts.getBitWidth() && "Vector size mismatch");
 2327   assert(VT.isVector() && "Vector type expected");
 2456   assert((!Op.getValueType().isVector() ||
 2477         assert(SrcOp.getValueSizeInBits() > BitWidth &&
 2497     assert(NumElts == SVN->getMask().size() && "Unexpected vector size");
 2637       assert(N0.getValueType().isVector() && "Expected bitcast from vector");
 2660       assert(Op.getValueType().isVector() && "Expected bitcast to vector");
 3067     assert(Op.getResNo() == 0 && "We only compute knownbits for the sum here.");
 3109         assert((Known.Zero & Known.One) == 0&&"Bits known to be one AND zero?");
 3326   assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 3413   assert((VT.isInteger() || VT.isFloatingPoint()) && "Invalid VT!");
 3451         assert(SrcOp.getValueSizeInBits() > VTBits &&
 3465     assert(NumElts == SVN->getMask().size() && "Unexpected vector size");
 3489     assert(Tmp <= VTBits && "Failed to determine minimum sign bits");
 3510       assert(VT.isVector() && "Expected bitcast to vector");
 3793     assert(Tmp <= VTBits && "Failed to determine minimum sign bits");
 3849     assert(Tmp <= VTBits && "Failed to determine minimum sign bits");
 3873       assert(Tmp <= VTBits && "Failed to determine minimum sign bits");
 3882     assert(Tmp <= VTBits && "Failed to determine minimum sign bits");
 4098   assert(Op.getValueType().isFloatingPoint() &&
 4109   assert(!Op.getValueType().isFloatingPoint() &&
 4146   assert(A.getValueType() == B.getValueType() &&
 4155   assert(NumOps != 0 && "Can't build an empty vector!");
 4156   assert(VT.getVectorNumElements() == (unsigned)NumOps &&
 4188   assert(!Ops.empty() && "Can't concatenate an empty list of vectors!");
 4189   assert(llvm::all_of(Ops,
 4194   assert((Ops.size() * Ops[0].getValueType().getVectorNumElements()) ==
 4221     assert((!IdentitySrc || IdentitySrc == Op.getOperand(0)) &&
 4226     assert(IdentitySrc && "Failed to set source vector of extracts");
 4473     assert(VT.isFloatingPoint() &&
 4476     assert((!VT.isVector() ||
 4480     assert(Operand.getValueType().bitsLT(VT) &&
 4497     assert(VT.isInteger() && Operand.getValueType().isInteger() &&
 4499     assert(VT.isVector() == Operand.getValueType().isVector() &&
 4503     assert((!VT.isVector() ||
 4507     assert(Operand.getValueType().bitsLT(VT) &&
 4516     assert(VT.isInteger() && Operand.getValueType().isInteger() &&
 4518     assert(VT.isVector() == Operand.getValueType().isVector() &&
 4522     assert((!VT.isVector() ||
 4526     assert(Operand.getValueType().bitsLT(VT) &&
 4535     assert(VT.isInteger() && Operand.getValueType().isInteger() &&
 4537     assert(VT.isVector() == Operand.getValueType().isVector() &&
 4541     assert((!VT.isVector() ||
 4545     assert(Operand.getValueType().bitsLT(VT) &&
 4565     assert(VT.isInteger() && Operand.getValueType().isInteger() &&
 4567     assert(VT.isVector() == Operand.getValueType().isVector() &&
 4571     assert((!VT.isVector() ||
 4575     assert(Operand.getValueType().bitsGT(VT) &&
 4595     assert(VT.isVector() && "This DAG node is restricted to vector types.");
 4596     assert(Operand.getValueType().bitsLE(VT) &&
 4598     assert(VT.getVectorNumElements() <
 4603     assert(VT.isInteger() && VT == Operand.getValueType() &&
 4609     assert(VT.isInteger() && VT == Operand.getValueType() &&
 4611     assert((VT.getScalarSizeInBits() % 16 == 0) &&
 4617     assert(VT.isInteger() && VT == Operand.getValueType() &&
 4624     assert(VT.getSizeInBits() == Operand.getValueSizeInBits() &&
 4633     assert(VT.isVector() && !Operand.getValueType().isVector() &&
 4777     assert(Ops.size() == 2 && "Div/rem should have 2 operands");
 4809       assert((!Folded || !VT.isVector()) &&
 4834   assert((!BV1 || !BV2 || BV1->getNumOperands() == BV2->getNumOperands()) &&
 4871   assert(VT.getVectorNumElements() == Outputs.size() &&
 5057     assert(VT == MVT::Other && N1.getValueType() == MVT::Other &&
 5078     assert(VT.isInteger() && "This operator does not apply to FP types!");
 5079     assert(N1.getValueType() == N2.getValueType() &&
 5092     assert(VT.isInteger() && "This operator does not apply to FP types!");
 5093     assert(N1.getValueType() == N2.getValueType() &&
 5115     assert(VT.isInteger() && "This operator does not apply to FP types!");
 5116     assert(N1.getValueType() == N2.getValueType() &&
 5124     assert(VT.isFloatingPoint() && "This operator only applies to FP types!");
 5125     assert(N1.getValueType() == N2.getValueType() &&
 5131     assert(N1.getValueType() == VT &&
 5144     assert(VT == N1.getValueType() &&
 5146     assert(VT.isInteger() && N2.getValueType().isInteger() &&
 5148     assert((!VT.isVector() || VT == N2.getValueType()) &&
 5154     assert(N2.getValueSizeInBits() >= Log2_32_Ceil(N1.getValueSizeInBits()) &&
 5166     assert(VT.isFloatingPoint() &&
 5176     assert(VT == N1.getValueType() && "Not an inreg extend!");
 5177     assert(VT.isInteger() && EVT.isInteger() &&
 5179     assert(!EVT.isVector() &&
 5182     assert(EVT.bitsLE(VT.getScalarType()) && "Not extending!");
 5188     assert(VT == N1.getValueType() && "Not an inreg extend!");
 5189     assert(VT.isInteger() && EVT.isInteger() &&
 5191     assert(EVT.isVector() == VT.isVector() &&
 5194     assert((!EVT.isVector() ||
 5197     assert(EVT.bitsLE(VT) && "Not extending!");
 5229     assert(VT.getSizeInBits() >= N1.getValueType().getScalarSizeInBits() &&
 5299     assert(N2C && (unsigned)N2C->getZExtValue() < 2 && "Bad EXTRACT_ELEMENT!");
 5300     assert(!N1.getValueType().isVector() && !VT.isVector() &&
 5321       assert(VT.isVector() && N1.getValueType().isVector() &&
 5323       assert(VT.getVectorElementType() ==
 5326       assert(VT.getSimpleVT() <= N1.getSimpleValueType() &&
 5330         assert((VT.getVectorNumElements() + N2C->getZExtValue()
 5451     assert(VT.isFloatingPoint() && "This operator only applies to FP types!");
 5452     assert(N1.getValueType() == VT && N2.getValueType() == VT &&
 5480     assert(VT.isInteger() && "SETCC result type must be an integer!");
 5481     assert(N1.getValueType() == N2.getValueType() &&
 5483     assert(VT.isVector() == N1.getValueType().isVector() &&
 5485     assert((!VT.isVector() ||
 5529       assert(VT.isVector() && N1.getValueType().isVector() &&
 5532       assert(VT == N1.getValueType() &&
 5534       assert(N2.getSimpleValueType() <= N1.getSimpleValueType() &&
 5537         assert((N2.getValueType().getVectorNumElements() +
 5629   assert(!Value.isUndef());
 5633     assert(C->getAPIntValue().getBitWidth() == 8);
 5644   assert(Value.getValueType() == MVT::i8 && "memset with non-byte fill value?");
 5689   assert(!VT.isVector() && "Can't handle vector type here!");
 5748   assert(OutLoadChains.size() && "Missing loads in memcpy inlining");
 5749   assert(OutStoreChains.size() && "Missing stores in memcpy inlining");
 5846       assert(i == NumMemOps-1 && i != 0);
 5884       assert(NVT.bitsGE(VT));
 6122       assert(i == NumMemOps-1 && i != 0);
 6136     assert(Value.getValueType() == VT && "Value with wrong type.");
 6164   assert(Align && "The SDAG layer expects explicit alignment and reserves 0");
 6194     assert(ConstantSize && "AlwaysInline requires a constant size!");
 6280   assert(Align && "The SDAG layer expects explicit alignment and reserves 0");
 6383   assert(Align && "The SDAG layer expects explicit alignment and reserves 0");
 6506   assert(Opcode == ISD::ATOMIC_CMP_SWAP ||
 6508   assert(Cmp.getValueType() == Swp.getValueType() && "Invalid Atomic Op Types");
 6517   assert((Opcode == ISD::ATOMIC_LOAD_ADD ||
 6545   assert(Opcode == ISD::ATOMIC_LOAD && "Invalid Atomic Op");
 6585   assert((Opcode == ISD::INTRINSIC_VOID ||
 6700   assert(Chain.getValueType() == MVT::Other &&
 6706   assert((MMOFlags & MachineMemOperand::MOStore) == 0);
 6725     assert(VT == MemVT && "Non-extending load from different memory type!");
 6728     assert(MemVT.getScalarType().bitsLT(VT.getScalarType()) &&
 6730     assert(VT.isInteger() == MemVT.isInteger() &&
 6732     assert(VT.isVector() == MemVT.isVector() &&
 6734     assert((!VT.isVector() ||
 6740   assert((Indexed || Offset.isUndef()) && "Unindexed load with an offset!");
 6807   assert(LD->getOffset().isUndef() && "Load is already a indexed load!");
 6823   assert(Chain.getValueType() == MVT::Other && "Invalid chain type");
 6828   assert((MMOFlags & MachineMemOperand::MOLoad) == 0);
 6841   assert(Chain.getValueType() == MVT::Other &&
 6874   assert(Chain.getValueType() == MVT::Other &&
 6880   assert((MMOFlags & MachineMemOperand::MOLoad) == 0);
 6896   assert(Chain.getValueType() == MVT::Other &&
 6901   assert(SVT.getScalarType().bitsLT(VT.getScalarType()) &&
 6903   assert(VT.isInteger() == SVT.isInteger() &&
 6905   assert(VT.isVector() == SVT.isVector() &&
 6907   assert((!VT.isVector() ||
 6940   assert(ST->getOffset().isUndef() && "Store is already a indexed store!");
 6996   assert(Chain.getValueType() == MVT::Other &&
 7026   assert(Ops.size() == 6 && "Incompatible number of operands");
 7044   assert(N->getPassThru().getValueType() == N->getValueType(0) &&
 7046   assert(N->getMask().getValueType().getVectorNumElements() ==
 7049   assert(N->getIndex().getValueType().getVectorNumElements() >=
 7052   assert(isa<ConstantSDNode>(N->getScale()) &&
 7067   assert(Ops.size() == 6 && "Incompatible number of operands");
 7084   assert(N->getMask().getValueType().getVectorNumElements() ==
 7087   assert(N->getIndex().getValueType().getVectorNumElements() >=
 7090   assert(isa<ConstantSDNode>(N->getScale()) &&
 7225     assert(NumOps == 5 && "SELECT_CC takes 5 operands!");
 7226     assert(Ops[0].getValueType() == Ops[1].getValueType() &&
 7228     assert(Ops[2].getValueType() == Ops[3].getValueType() &&
 7230     assert(Ops[2].getValueType() == VT &&
 7234     assert(NumOps == 5 && "BR_CC takes 5 operands!");
 7235     assert(Ops[2].getValueType() == Ops[3].getValueType() &&
 7449   assert(N->getNumOperands() == 1 && "Update with wrong number of operands");
 7474   assert(N->getNumOperands() == 2 && "Update with wrong number of operands");
 7525   assert(N->getNumOperands() == NumOps &&
 7788   assert(Node->getNumValues() == 2 && "Unexpected number of results!");
 7982   assert(cast<DILocalVariable>(Var)->isValidLocationForIntrinsic(DL) &&
 7993   assert(cast<DILocalVariable>(Var)->isValidLocationForIntrinsic(DL) &&
 8004   assert(cast<DILocalVariable>(Var)->isValidLocationForIntrinsic(DL) &&
 8015   assert(cast<DILocalVariable>(Var)->isValidLocationForIntrinsic(DL) &&
 8026   assert(FromNode && ToNode && "Can't modify dbg values");
 8125   assert(cast<DILabel>(Label)->isValidLocationForIntrinsic(DL) &&
 8162   assert(From->getNumValues() == 1 && FromN.getResNo() == 0 &&
 8164   assert(From != To.getNode() && "Cannot replace uses of with self");
 8214     assert((!From->hasAnyUseOfValue(i) ||
 8226       assert((i < To->getNumValues()) && "Invalid To location");
 8451     assert(DivergenceMap[&N] == N.isDivergent() &&
 8545       assert(SortedPos != AllNodes.end() && "Overran node list");
 8564       assert(Degree != 0 && "Invalid node degree");
 8571         assert(SortedPos != AllNodes.end() && "Overran node list");
 8591   assert(SortedPos == AllNodes.end() &&
 8593   assert(AllNodes.front().getOpcode() == ISD::EntryToken &&
 8595   assert(AllNodes.front().getNodeId() == 0 &&
 8597   assert(AllNodes.front().getNumOperands() == 0 &&
 8599   assert(AllNodes.back().getNodeId() == (int)DAGSize-1 &&
 8601   assert(AllNodes.back().use_empty() &&
 8603   assert(DAGSize == allnodes_size() && "Node count mismatch!");
 8611     assert(DbgInfo->getSDDbgValues(SD).empty() || SD->getHasDebugValue());
 8623   assert(isa<MemSDNode>(NewMemOp.getNode()) && "Expected a memop node");
 8642   assert(isa<ExternalSymbolSDNode>(Op) && "Node should be an ExternalSymbol");
 8732       assert(CVT.bitsGE(NSVT) && "Illegal build vector element extension");
 8756       assert(CVT.bitsGE(NSVT) && "Illegal build vector element extension");
 8845   assert(memvt.getStoreSize() <= MMO->getSize() && "Size mismatch!");
 8879     assert(VT.getSimpleVT() < MVT::LAST_VALUETYPE &&
 8889   assert(Value < getNumValues() && "Bad value!");
 8907   assert(Value < getNumValues() && "Bad value!");
 9111   assert(N->getNumValues() == 1 &&
 9182   assert((Opcode == ISD::UADDO || Opcode == ISD::SADDO ||
 9312   assert(LoVT.getVectorNumElements() + HiVT.getVectorNumElements() <=
 9366   assert(VT.isVector() && "Expected a vector type");
 9381   assert(NumOps > 0 && "isConstantSplat has 0-size build vector");
 9432   assert(getNumOperands() == DemandedElts.getBitWidth() &&
 9453     assert(getOperand(FirstDemandedIdx).isUndef() &&
 9563   assert(!Node->OperandList && "Node already has operands");
 9564   assert(SDNode::getMaxNumOperands() >= Vals.size() &&
 9632     assert(N && "Checking nonexistent SDNode");
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
  209   assert(NumParts > 0 && "No parts to assemble!");
  266       assert(ValueVT == EVT(MVT::ppcf128) && PartVT == MVT::f64 &&
  276       assert(ValueVT.isFloatingPoint() && PartVT.isInteger() &&
  361   assert(ValueVT.isVector() && "Not a vector value");
  362   assert(NumParts > 0 && "No parts to assemble!");
  385     assert(NumRegs == NumParts && "Part count doesn't match vector breakdown!");
  387     assert(RegisterVT == PartVT && "Part type doesn't match vector breakdown!");
  388     assert(RegisterVT.getSizeInBits() ==
  403       assert(NumParts % NumIntermediates == 0 &&
  435       assert(PartEVT.getVectorNumElements() > ValueVT.getVectorNumElements() &&
  446     assert(PartEVT.getVectorNumElements() == ValueVT.getVectorNumElements() &&
  512   assert(DAG.getTargetLoweringInfo().isTypeLegal(PartVT) &&
  518   assert(!ValueVT.isVector() && "Vector case handled elsewhere");
  521     assert(NumParts == 1 && "No-op copy with multiple parts!");
  529       assert(NumParts == 1 && "Do not know what to promote to!");
  538       assert((PartVT.isInteger() || PartVT == MVT::x86mmx) &&
  548     assert(NumParts == 1 && PartEVT != ValueVT);
  552     assert((PartVT.isInteger() || PartVT == MVT::x86mmx) &&
  563   assert(NumParts * PartBits == ValueVT.getSizeInBits() &&
  580     assert(PartVT.isInteger() && ValueVT.isInteger() &&
  663   assert(ValueVT.isVector() && "Not a vector");
  689         assert(PartVT.getSizeInBits() > ValueVT.getSizeInBits() &&
  698     assert(Val.getValueType() == PartVT && "Unexpected vector part value type");
  718   assert(NumRegs == NumParts && "Part count doesn't match vector breakdown!");
  720   assert(RegisterVT == PartVT && "Part type doesn't match vector breakdown!");
  760     assert(NumIntermediates != 0 && "division by zero");
  761     assert(NumParts % NumIntermediates == 0 &&
  872       assert(FromVT != MVT::Other);
  969     assert(Regs.size() == RegVTs.size() && Regs.size() == ValueVTs.size() &&
  975       assert(
  987       assert(Reg < Regs.size() && "Mismatch in # registers expected");
 1062       assert(PendingExports[i].getNode()->getNumOperands() > 1);
 1168     assert(DI && "Ill-formed DanglingDebugInfo");
 1174     assert(Variable->isValidLocationForIntrinsic(dl) &&
 1223   assert(isa<DbgValueInst>(DDI.getDI()));
 1467       assert(N1.getNode() && "visit didn't populate the NodeMap!");
 1504       assert((isa<ConstantAggregateZero>(C) || isa<UndefValue>(C)) &&
 1539       assert(isa<ConstantAggregateZero>(C) && "Unknown vector constant!");
 1623   assert(SuccessorColor && "No parent funclet for catchret!");
 1625   assert(SuccessorColorMBB && "No MBB for SuccessorColor!");
 1697     assert(UnwindDests.size() <= 1 &&
 1900     assert(SwiftError.getFunctionArg() && "Need a swift error argument");
 1921   assert(Chain.getNode() && Chain.getValueType() == MVT::Other &&
 1938     assert(!V->use_empty() && "Unused value assigned virtual registers!");
 2156     assert(Opc == Instruction::And && "Unknown merge op!");
 2275       assert(SL->SwitchCases[0].ThisBB == BrMBB && "Unexpected lowering!");
 2354     assert(CB.CC == ISD::SETLE && "Can handle only LE ranges now");
 2405   assert(JT.Reg != -1U && "Should lower JT Header first!");
 2534     assert(FnTy->getNumParams() == 1 && "Invalid function signature");
 2749   assert(!I.hasOperandBundlesOtherThan({LLVMContext::OB_deopt,
 2830   assert(!I.hasOperandBundlesOtherThan(
 2834   assert(isa<InlineAsm>(I.getCalledValue()) &&
 2860   assert(FuncInfo.MBB->isEHPad() &&
 2881   assert(ValueVTs.size() == 2 && "Only two-valued landingpads are supported");
 3562   assert(!VT.isScalableVector() && "Unsupported scalable vector shuffle");
 3996   assert(FuncInfo.MF->getFrameInfo().hasVarSizedObjects());
 4081       assert(PendingLoads.empty() && "PendingLoads must be serialized first");
 4127   assert(DAG.getTargetLoweringInfo().supportSwiftError() &&
 4135   assert(ValueVTs.size() == 1 && Offsets[0] == 0 &&
 4150   assert(DAG.getTargetLoweringInfo().supportSwiftError() &&
 4153   assert(!I.isVolatile() &&
 4162   assert(
 4173   assert(ValueVTs.size() == 1 && Offsets[0] == 0 &&
 4337   assert(Ptr->getType()->isVectorTy() && "Uexpected pointer type");
 4804       assert(CI->getBitWidth() <= 64 &&
 5541         assert(!IsDbgDeclare && "DbgDeclare operand is not in memory?");
 5574   assert(Variable->isValidLocationForIntrinsic(DL) &&
 5631   assert(FunctionName && "FunctionName must not be nullptr");
 5811     assert(Variable && "Missing variable");
 5888     assert(Label && "Missing label");
 5897     assert(DI.getVariable() && "Missing variable");
 5948     assert(CI && "Non-constant call site value in eh.sjlj.callsite!");
 5949     assert(MMI.getCurrentCallSite() == 0 && "Overlapping call sites!");
 6466     assert(DAG.getMachineFunction().getFunction().hasGC() &&
 6468     assert(GFI && "implied by previous");
 6650       assert(FuncInfo.StaticAllocaMap.count(Slot) &&
 7016   assert(Result.getNode()->getNumValues() == 2);
 7056   assert((CLI.IsTailCall || Result.second.getNode()) &&
 7058   assert((Result.second.getNode() || !Result.first.getNode()) &&
 7084       assert(CLI.CS);
 7397   assert(MC.getNode() != nullptr &&
 7703   assert(!I.hasOperandBundlesOtherThan({LLVMContext::OB_deopt,
 7972         assert(I != RC->end() && "AssignedReg should be member of RC");
 7976     assert(I != RC->end() && "Ran out of registers to allocate!");
 7993     assert((InlineAsm::isRegDefKind(OpFlag) ||
 8089       assert(!CS.getType()->isVoidTy() && "Bad inline asm!");
 8094         assert(ResNo == 0 && "Asm only has one result!");
 8158       assert((OpInfo.isMultipleAlternative ||
 8209         assert(ConstraintID != InlineAsm::Constraint_Unknown &&
 8291         assert(InlineAsm::isMemKind(OpFlag) && "Unknown matching constraint!");
 8292         assert(InlineAsm::getNumOperandRegisters(OpFlag) == 1 &&
 8339         assert(OpInfo.isIndirect && "Operand must be indirect to be a mem!");
 8340         assert(InOperandVal.getValueType() ==
 8346         assert(ConstraintID != InlineAsm::Constraint_Unknown &&
 8359       assert((OpInfo.ConstraintType == TargetLowering::C_RegisterClass ||
 8424     assert(CurResultType != ResultTypes.end() && "Unexpected value");
 8425     assert((*CurResultType)->isSized() && "Unexpected unsized type");
 8448     assert(ResultVT == V.getValueType() && "Asm result value mismatch!");
 8475         assert(false && "Unexpected unknown constraint");
 8481         assert(Ptr && "Expected value CallOperandVal for indirect asm operand");
 8487         assert(!CS.getType()->isVoidTy() && "Bad inline asm!");
 8499     assert(CurResultType == ResultTypes.end() &&
 8501     assert(ResultValues.size() == ResultTypes.size() &&
 8633     assert(!V->getType()->isEmptyTy() && "Empty type passed to intrinsic.");
 8690   assert(CI.getType()->isVoidTy() && "Stackmap cannot return a value.");
 8780   assert(CS.arg_size() >= NumMetaOpers + NumArgs &&
 8799   assert(CallEnd->getOpcode() == ISD::CALLSEQ_END &&
 8862     assert(ValueVTs.size() == 1 && "Expected only one return value type.");
 9212         assert((CLI.RetTy == Args[i].Ty ||
 9265   assert(CLI.Chain.getNode() && CLI.Chain.getValueType() == MVT::Other &&
 9267   assert((!CLI.IsTailCall || InVals.empty()) &&
 9269   assert((CLI.IsTailCall || InVals.size() == CLI.Ins.size()) &&
 9283     assert(InVals[i].getNode() && "LowerCall emitted a null value!");
 9284     assert(EVT(CLI.Ins[i].VT) == InVals[i].getValueType() &&
 9297     assert(PVTs.size() == 1 && "Pointers should fit in one register");
 9371   assert((Op.getOpcode() != ISD::CopyFromReg ||
 9374   assert(!Register::isPhysicalRegister(Reg) && "Is a physreg");
 9528   assert(ArgCopyIter != ArgCopyElisionCandidates.end());
 9733   assert(NewRoot.getNode() && NewRoot.getValueType() == MVT::Other &&
 9735   assert(InVals.size() == Ins.size() &&
 9739       assert(InVals[i].getNode() &&
 9741       assert(EVT(Ins[i].VT) == InVals[i].getValueType() &&
 9903   assert(i == InVals.size() && "Argument register count mismatch!");
 9974           assert(isa<AllocaInst>(PHIOp) &&
10294   assert(W.FirstCluster->Low->getValue().slt(W.LastCluster->Low->getValue()) &&
10297   assert(W.LastCluster - W.FirstCluster + 1 >= 2 && "Too small to split!");
10345         assert(NumRight < NumLeft);
10361   assert(LastLeft + 1 == FirstRight);
10362   assert(LastLeft >= W.FirstCluster);
10363   assert(FirstRight <= W.LastCluster);
10368   assert(PivotCluster > W.FirstCluster);
10369   assert(PivotCluster <= W.LastCluster);
10523     assert(PeeledSwitchMBB == SwitchMBB);
10553   assert(!Clusters.empty());
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
  302       assert(!shouldEmitStackProtector() && "Stack Protector Descriptor is "
  515     assert(!N.getNode() && "Already set a value for this node!");
  521     assert(!N.getNode() && "Already set a value for this node!");
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
  270     assert(TLI->getSchedulingPreference() == Sched::ILP &&
  299   assert(!MI.hasPostISelHook() &&
  417   assert((!EnableFastISelAbort || TM.Options.EnableFastISel) &&
  591       assert(!hasFI && "There's no handling of frame pointer updating here yet "
  600         assert(MI->getOperand(1).getImm() == 0 &&
  602       assert(cast<DILocalVariable>(Variable)->isValidLocationForIntrinsic(DL) &&
 1149             assert(Op->getNodeId() != -1 &&
 1219     assert(IntrFound && "wasm.landingpad.index intrinsic not found!");
 1243         assert(EHPhysReg && "target lacks exception pointer register");
 1302       assert(DI->getVariable() && "Missing variable");
 1303       assert(DI->getDebugLoc() && "Missing location");
 1349   assert(*RPOT.begin() == &Fn.getEntryBlock());
 1649   assert(OPI2 != MI.operands_end()
 1708     assert(PHI->isPHI() &&
 1835       assert(PHI->isPHI() &&
 1888       assert(PHI->isPHI() &&
 1940             assert(pn != FuncInfo->PHINodesToUpdate.size() &&
 2052       assert(InlineAsm::getNumOperandRegisters(Flags) == 1 &&
 2266   assert(Val >= 128 && "Not a VBR");
 2290     assert(InputChain.getNode() &&
 2301       assert(ChainNode->getOpcode() != ISD::DELETED_NODE &&
 2312       assert(ChainVal.getValueType() == MVT::Other && "Not a chain?");
 2467   assert(RecNo < RecordedNodes.size() && "Invalid CheckSame");
 2801   assert(!NodeToMatch->isMachineOpcode() && "Node already selected!");
 2873     assert(MatcherIndex < TableSize && "Invalid index");
 3000       assert(!NodeStack.empty() && "Node stack imbalance!");
 3038       assert(RecNo < RecordedNodes.size() && "Invalid CheckComplexPat");
 3177       assert(NodeStack.size() != 1 && "No parent node");
 3234       assert(RecNo < RecordedNodes.size() && "Invalid EmitConvertToTarget");
 3255       assert(!InputChain.getNode() &&
 3257       assert(ChainNodesMatched.empty() &&
 3262       assert(RecNo < RecordedNodes.size() && "Invalid EmitMergeInputChains");
 3282       assert(!InputChain.getNode() &&
 3291       assert(NumChains != 0 && "Can't TF zero chains");
 3293       assert(ChainNodesMatched.empty() &&
 3299         assert(RecNo < RecordedNodes.size() && "Invalid EmitMergeInputChains");
 3327       assert(RecNo < RecordedNodes.size() && "Invalid EmitCopyToReg");
 3346       assert(RecNo < RecordedNodes.size() && "Invalid EmitNodeXForm");
 3409         assert(RecNo < RecordedNodes.size() && "Invalid EmitNode");
 3418         assert(NodeToMatch->getNumOperands() >= FirstOpToCopy &&
 3453         assert(NodeToMatch->getOpcode() != ISD::DELETED_NODE &&
 3459           assert((!E || !is_contained(Chain, N)) &&
 3533         assert(ResSlot < RecordedNodes.size() && "Invalid CompleteMatch");
 3536         assert(i < NodeToMatch->getNumValues() &&
 3540         assert((NodeToMatch->getValueType(i) == Res.getValueType() ||
 3562       assert(NodeToMatch->use_empty() &&
 3623   assert(N->getOpcode() == ISD::OR && "Unexpected opcode");
 3632     assert(isPowerOf2_32(A) && "Unexpected alignment");
lib/CodeGen/SelectionDAG/StatepointLowering.cpp
   74   assert(PendingGCRelocateCalls.empty() &&
   88   assert(PendingGCRelocateCalls.empty() &&
   99   assert((SpillSize * 8) == ValueType.getSizeInBits() && "Size not in bytes?");
  106   assert(NextSlotToAllocate <= NumSlots && "Broken invariant");
  108   assert(AllocatedStackSlots.size() ==
  131   assert(AllocatedStackSlots.size() ==
  247   assert(SlotIt != StatepointSlots.end() &&
  300   assert(Bases.size() >= NewBases.size());
  301   assert(Ptrs.size() >= NewPtrs.size());
  302   assert(Relocs.size() >= NewRelocs.size());
  306   assert(Ptrs.size() == Bases.size());
  307   assert(Ptrs.size() == Relocs.size());
  346   assert(CallEnd->getOpcode() == ISD::CALLSEQ_END && "expected!");
  387     assert((MFI.getObjectSize(Index) * 8) == Incoming.getValueSizeInBits() &&
  407   assert(Loc.getNode());
  435     assert(Incoming.getValueType() == Builder.getFrameIndexTy() &&
  493         assert(Opt.getValue() &&
  500         assert(Opt.getValue() &&
  504     assert(SI.Bases.size() == SI.Ptrs.size() && "Pointer without base!");
  506     assert(SI.Bases.empty() && "No gc specified, so cannot relocate pointers!");
  507     assert(SI.Ptrs.empty() && "No gc specified, so cannot relocate pointers!");
  589       assert(Incoming.getValueType() == Builder.getFrameIndexTy() &&
  658   assert(SI.Bases.size() == SI.Ptrs.size() &&
  759   assert(((Flags & ~(uint64_t)StatepointFlags::MaskAll) == 0) &&
  834   assert(ISP.getCall()->getCallingConv() != CallingConv::AnyReg &&
  844   assert(GFI->getStrategy().useStatepoints() &&
  983     assert(CopyFromReg.getNode());
 1001     assert(*IsManaged && "Non gc managed pointer relocated!");
 1009   assert(SlotIt != SpillMap.end() && "Relocating not lowered gc value");
 1043   assert(SpillLoad.getNode());
lib/CodeGen/SelectionDAG/StatepointLowering.h
   60     assert(!Locations.count(Val) &&
   82     assert(I != PendingGCRelocateCalls.end() &&
   95     assert(Offset >= 0 && Offset < (int)AllocatedStackSlots.size() &&
   97     assert(!AllocatedStackSlots.test(Offset) && "already reserved!");
   98     assert(NextSlotToAllocate <= (unsigned)Offset && "consistency!");
  103     assert(Offset >= 0 && Offset < (int)AllocatedStackSlots.size() &&
lib/CodeGen/SelectionDAG/TargetLowering.cpp
  203     assert(VT.isInteger());
  209     assert(LVT.isInteger());
  280   assert((VT == MVT::f32 || VT == MVT::f64 || VT == MVT::f128 || VT == MVT::ppcf128)
  513   assert(Op.getNumOperands() == 2 &&
  515   assert(Op.getNode()->getNumValues() == 1 &&
  546       assert(DemandedSize <= SmallVTBits && "Narrowed below demanded bits?");
  758   assert(Op.getScalarValueSizeInBits() == BitWidth &&
  762   assert((!Op.getValueType().isVector() ||
  965       assert(0 <= M && M < (int)(2 * NumElts) && "Shuffle index out of range");
 1043     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1047     assert(!Known2.hasConflict() && "Bits known to be one AND zero?");
 1092     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1096     assert(!Known2.hasConflict() && "Bits known to be one AND zero?");
 1138     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1142     assert(!Known2.hasConflict() && "Bits known to be one AND zero?");
 1216     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1217     assert(!Known2.hasConflict() && "Bits known to be one AND zero?");
 1234     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1235     assert(!Known2.hasConflict() && "Bits known to be one AND zero?");
 1421       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1464       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1578     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1648     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1649     assert(Known.getBitWidth() == InBits && "Src width has changed?");
 1686     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1687     assert(Known.getBitWidth() == InBits && "Src width has changed?");
 1721     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1722     assert(Known.getBitWidth() == InBits && "Src width has changed?");
 1783     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1794     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 2041   assert(DAG.getTargetLoweringInfo().isBinOp(BO.getOpcode()) && VT.isVector() &&
 2046   assert(UndefOp0.getBitWidth() == NumElts &&
 2090   assert(VT.isVector() && "Expected vector op");
 2091   assert(VT.getVectorNumElements() == NumElts &&
 2383       assert(0 <= M && M < (int)(2 * NumElts) && "Shuffle index out of range");
 2565   assert((KnownUndef & KnownZero) == 0 && "Elements flagged as undef AND zero");
 2582   assert((Op.getOpcode() >= ISD::BUILTIN_OP_END ||
 2603   assert(isa<FrameIndexSDNode>(Op) && "expected FrameIndex");
 2617   assert((Op.getOpcode() >= ISD::BUILTIN_OP_END ||
 2629   assert((Op.getOpcode() >= ISD::BUILTIN_OP_END ||
 2641   assert((Op.getOpcode() >= ISD::BUILTIN_OP_END ||
 2654   assert(
 2689   assert((Op.getOpcode() >= ISD::BUILTIN_OP_END ||
 2913   assert(KeptBits > 0 && KeptBits < XVT.getSizeInBits() && "unreachable");
 2922   assert(MaskedBits > 0 && MaskedBits < XVT.getSizeInBits() && "unreachable");
 2938   assert(isConstOrConstSplat(N1C) &&
 2941   assert((Cond == ISD::SETEQ || Cond == ISD::SETNE) &&
 3012   assert((BOpcode == ISD::ADD || BOpcode == ISD::SUB || BOpcode == ISD::XOR) &&
 3014   assert((Cond == ISD::SETEQ || Cond == ISD::SETNE) && "Unexpected condcode");
 3415             assert(N0.getOpcode() == ISD::AND &&
 3698     assert(!CFP->getValueAPF().isNaN() && "Unexpected NaN value");
 3758     assert(!N0.getValueType().isInteger() &&
 4121   assert(*(Constraint.end() - 1) == '}' && "Not a brace enclosed constraint?");
 4162   assert(!ConstraintCode.empty() && "No known constraint!");
 4169   assert(!ConstraintCode.empty() && "No known constraint!");
 4213       assert(!CS.getType()->isVoidTy() &&
 4219         assert(ResNo == 0 && "Asm only has one result!");
 4476   assert(OpInfo.Codes.size() > 1 && "Doesn't have multiple constraint options");
 4492       assert(OpInfo.Codes[i].size() == 1 &&
 4527   assert(!OpInfo.Codes.empty() && "Must have at least one constraint");
 4777       assert(magics.a == 0 && "Should use cheap fixup now");
 4784       assert(magics.s < Divisor.getBitWidth() &&
 4932   assert((Cond == ISD::SETEQ || Cond == ISD::SETNE) &&
 4969     assert((!D.isOneValue() || (K == 0)) && "For divisor '1' we won't rotate.");
 4984     assert(!P.isNullValue() && "No multiplicative inverse!"); // unreachable
 4985     assert((D0 * P).isOneValue() && "Multiplicative inverse sanity check.");
 4990     assert(APInt::getAllOnesValue(ShSVT.getSizeInBits()).ugt(K) &&
 4998       assert(Q.isAllOnesValue() &&
 5081     assert(Built.size() <= 7 && "Max size prediction failed.");
 5105   assert((Cond == ISD::SETEQ || Cond == ISD::SETNE) &&
 5152     assert((!D.isOneValue() || (K == 0)) && "For divisor '1' we won't rotate.");
 5171     assert(!P.isNullValue() && "No multiplicative inverse!"); // unreachable
 5172     assert((D0 * P).isOneValue() && "Multiplicative inverse sanity check.");
 5187     assert(APInt::getAllOnesValue(SVT.getSizeInBits()).ugt(A) &&
 5189     assert(APInt::getAllOnesValue(ShSVT.getSizeInBits()).ugt(K) &&
 5294   assert(VT.isVector() && "Can/should only get here for vectors.");
 5466   assert(Depth <= SelectionDAG::MaxRecursionDepth &&
 5490     assert((DAG.getTarget().Options.NoSignedZerosFPMath ||
 5539     assert((DAG.getTarget().Options.NoSignedZerosFPMath ||
 5592   assert(Opcode == ISD::MUL || Opcode == ISD::UMUL_LOHI ||
 5613   assert((LL.getNode() && LH.getNode() && RL.getNode() && RH.getNode()) ||
 5778     assert(Result.size() == 2);
 5865   assert(isPowerOf2_32(EltSizeInBits) && EltSizeInBits > 1 &&
 6166   assert(VT.isInteger() && "CTPOP not implemented for this type.");
 6362   assert(SrcEltVT.isByteSized());
 6438   assert(Stride && "Zero stride!");
 6462   assert(LD->getAddressingMode() == ISD::UNINDEXED &&
 6560   assert(LoadedVT.isInteger() && !LoadedVT.isVector() &&
 6617   assert(ST->getAddressingMode() == ISD::UNINDEXED &&
 6709   assert(StoreMemVT.isInteger() && !StoreMemVT.isVector() &&
 6749   assert(DataVT.getVectorNumElements() == MaskVT.getVectorNumElements() &&
 6804   assert(EltSize * 8 == EltVT.getSizeInBits() &&
 6834   assert(EmuTlsVar && "Cannot find EmuTlsVar ");
 6852   assert((GA->getOffset() == 0) &&
 6859   assert((Op->getOpcode() == ISD::SETCC) && "Input has to be a SETCC node.");
 6889   assert(VT == RHS.getValueType() && "Expected operands to be the same type");
 6890   assert(VT.isInteger() && "Expected operands to be integers");
 6964   assert((Node->getOpcode() == ISD::SMULFIX ||
 7013   assert(((Signed && Scale < VTSize) || (!Signed && Scale <= VTSize)) &&
 7016   assert(LHS.getValueType() == RHS.getValueType() &&
 7241     assert(LC != RTLIB::UNKNOWN_LIBCALL && "Cannot expand this operation!");
 7281     assert(Ret.getOpcode() == ISD::MERGE_VALUES &&
 7310   assert(RType.getSizeInBits() == Overflow.getValueSizeInBits() &&
lib/CodeGen/ShadowStackGCLowering.cpp
  232   assert(Roots.empty() && "Not cleaned up?");
  265   assert(isa<GetElementPtrInst>(Val) && "Unexpected folded constant");
  277   assert(isa<GetElementPtrInst>(Val) && "Unexpected folded constant");
lib/CodeGen/ShrinkWrap.cpp
  284       assert(Register::isPhysicalRegister(PhysReg) && "Unallocated register?!");
  533     assert(!Save && !Restore && "We miss a shrink-wrap opportunity?!");
lib/CodeGen/SjLjEHPrepare.cpp
  233   assert(AfterAllocaInsPt != F.front().end());
lib/CodeGen/SlotIndexes.cpp
   55   assert(indexList.empty() && "Index list non-empty at initial numbering?");
   56   assert(idx2MBBMap.empty() &&
   58   assert(MBBRanges.empty() &&
   60   assert(mi2iMap.empty() &&
  105   assert(!MI.isBundledWithPred() &&
  113   assert(MIEntry.getInstr() == &MI && "Instruction indexes broken.");
  126   assert(MIEntry.getInstr() == &MI && "Instruction indexes broken.");
  133     assert(!MI.isBundledWithPred() && "Should have first bundle isntruction");
  201     assert(ListI->getIndex() >= startIdx.getIndex() &&
lib/CodeGen/SpillPlacement.cpp
  201   assert(!nodes && "Leaking node array");
  371   assert(ActiveNodes && "Call prepare() first");
lib/CodeGen/SplitKit.cpp
  166   assert(UseSlots.empty() && "Call clear first");
  201     assert(fixed && "Couldn't fix broken live interval");
  246       assert(BI.FirstInstr >= Start);
  250       assert(BI.LastInstr < Stop);
  257         assert(LVI->start == LVI->valno->def && "Dangling Segment start");
  258         assert(LVI->start == BI.FirstInstr && "First instr should be a def");
  289         assert(LVI->start == LVI->valno->def && "Dangling Segment start");
  312   assert(getNumLiveBlocks() == countLiveBlocks(CurLI) && "Bad block count");
  343   assert(!Orig.empty() && "Splitting empty interval?");
  437     assert(DefMI != nullptr);
  460   assert(ParentVNI && "Mapping  NULL value");
  461   assert(Idx.isValid() && "Invalid SlotIndex");
  462   assert(Edit->getParent().getVNInfoAt(Idx) == ParentVNI && "Bad Parent VNI");
  561   assert(RC == MRI.getRegClass(ToReg) && "Should have same reg class");
  686   assert(Idx != 0 && "Cannot select the complement interval");
  687   assert(Idx < Edit->size() && "Can only select previously opened interval");
  693   assert(OpenIdx && "openIntv not called before enterIntvBefore");
  703   assert(MI && "enterIntvBefore called with invalid index");
  710   assert(OpenIdx && "openIntv not called before enterIntvAfter");
  720   assert(MI && "enterIntvAfter called with invalid index");
  728   assert(OpenIdx && "openIntv not called before enterIntvAtEnd");
  752   assert(OpenIdx && "openIntv not called before useIntv");
  759   assert(OpenIdx && "openIntv not called before leaveIntvAfter");
  771   assert(MI && "No instruction at index");
  790   assert(OpenIdx && "openIntv not called before leaveIntvBefore");
  803   assert(MI && "No instruction at index");
  809   assert(OpenIdx && "openIntv not called before leaveIntvAtTop");
  828   assert(OpenIdx && "openIntv not called before overlapIntv");
  830   assert(ParentVNI == Edit->getParent().getVNInfoBefore(End) &&
  832   assert(LIS.getMBBFromIndex(Start) == LIS.getMBBFromIndex(End) &&
  856     assert(MI && "No instruction for back-copy");
  895   assert(MDT.dominates(DefMBB, MBB) && "MBB must be dominated by the def.");
 1023     assert(ParentVNI && "Parent not live at complement def");
 1181         assert(VNI && "Missing def for complex mapped value");
 1193       assert(Start <= BlockStart && "Expected live-in block");
 1199           assert(ParentVNI->isPHIDef() && "Non-phi defined at block start?");
 1201           assert(VNI && "Missing def for complex mapped parent PHI");
 1373     assert(LI.hasSubRanges());
 1418       assert(MI && "Missing instruction for dead def");
 1463       assert(PredVNI && "Value available in PhiVNI predecessor");
 1549   assert(!LRMap || LRMap->size() == Edit->size());
 1610   assert((IntvIn || IntvOut) && "Use splitSingleBlock for isolated blocks");
 1612   assert((!LeaveBefore || LeaveBefore < Stop) && "Interference after block");
 1613   assert((!IntvIn || !LeaveBefore || LeaveBefore > Start) && "Impossible intf");
 1614   assert((!EnterAfter || EnterAfter >= Start) && "Interference before block");
 1627     assert((!LeaveBefore || Idx <= LeaveBefore) && "Interference");
 1641     assert((!EnterAfter || Idx >= EnterAfter) && "Interference");
 1659   assert((!IntvOut || !EnterAfter || EnterAfter < LSP) && "Impossible intf");
 1679     assert((!LeaveBefore || Idx <= LeaveBefore) && "Interference");
 1680     assert((!EnterAfter || Idx >= EnterAfter) && "Interference");
 1690   assert(LeaveBefore <= EnterAfter && "Missed case");
 1695   assert((!EnterAfter || Idx >= EnterAfter) && "Interference");
 1700   assert((!LeaveBefore || Idx <= LeaveBefore) && "Interference");
 1714   assert(IntvIn && "Must have register in");
 1715   assert(BI.LiveIn && "Must be live-in");
 1716   assert((!LeaveBefore || LeaveBefore > Start) && "Bad interference");
 1748       assert((!LeaveBefore || Idx <= LeaveBefore) && "Interference");
 1755       assert((!LeaveBefore || Idx <= LeaveBefore) && "Interference");
 1778     assert((!LeaveBefore || From <= LeaveBefore) && "Interference");
 1793   assert((!LeaveBefore || From <= LeaveBefore) && "Interference");
 1809   assert(IntvOut && "Must have register out");
 1810   assert(BI.LiveOut && "Must be live-out");
 1811   assert((!EnterAfter || EnterAfter < LSP) && "Bad interference");
 1835     assert((!EnterAfter || Idx >= EnterAfter) && "Interference");
 1851   assert((!EnterAfter || Idx >= EnterAfter) && "Interference");
lib/CodeGen/StackColoring.cpp
  541   assert(BI != BlockLiveness.end() && "Block not found");
  568   assert((MI.getOpcode() == TargetOpcode::LIFETIME_START ||
  727           assert(slots.size() == 1 && "unexpected: MI ends multiple slots");
  770       assert(BI != BlockLiveness.end() && "Block not found");
  912     assert(To && From && "Invalid allocation object");
 1012           assert(Interval->find(Index) != Interval->end() &&
 1253         assert(!First->empty() && !Second->empty() && "Found an empty range");
 1274           assert(MFI->getObjectSize(FirstSlot) >=
lib/CodeGen/StackMaps.cpp
   50   assert(getVarIdx() <= MI->getNumOperands() &&
   64   assert(getMetaIdx() == CheckStartIdx &&
   82   assert(ScratchIdx != e && "No scratch register available");
   97   assert(RegNum >= 0 && "Invalid Dwarf register number.");
  114       assert((Size % 8) == 0 && "Need pointer size in bytes.");
  124       assert(Size > 0 && "Need a valid size for indirect memory locations.");
  133       assert(MOI->isImm() && "Expected constant operand.");
  151     assert(Register::isPhysicalRegister(MOI->getReg()) &&
  154     assert(!MOI->getSubReg() && "Physical subreg still around.");
  257   assert(Mask && "No register mask specified");
  309     assert(PatchPointOpers(&MI).hasDef() && "Stackmap has no return value.");
  331       assert((uint64_t)Loc.Offset != DenseMapInfo<uint64_t>::getEmptyKey() &&
  364   assert(MI.getOpcode() == TargetOpcode::STACKMAP && "expected stackmap");
  373   assert(MI.getOpcode() == TargetOpcode::PATCHPOINT && "expected patchpoint");
  387       assert(Locations[i].Type == Location::Register &&
  394   assert(MI.getOpcode() == TargetOpcode::STATEPOINT && "expected statepoint");
  551   assert((!CSInfos.empty() || ConstPool.empty()) &&
  553   assert((!CSInfos.empty() || FnInfos.empty()) &&
lib/CodeGen/StackProtector.cpp
  432       assert(SPCall && "Call to llvm.stackprotector is missing");
lib/CodeGen/StackSlotColoring.cpp
  296     assert(NextColors[StackID] != -1 && "No more spill slots?");
  302   assert(MFI->getStackID(Color) == MFI->getStackID(FI));
  335     assert(NewSS >= 0 && "Stack coloring failed?");
  410     assert(MFI->getStackID(OldFI) == MFI->getStackID(NewFI));
lib/CodeGen/SwiftErrorValueTracking.cpp
   99       assert(!HaveSeenSwiftErrorArg &&
  167       assert(!(UpwardsUse && !DownwardDef) &&
  196           assert(UUseIt != VRegUpwardsUse.end());
  214         assert(!VRegs.empty() &&
  228         assert(UpwardsUse);
  229         assert(!VRegs.empty() &&
  275         assert(!SwiftErrorAddr && "Cannot have multiple swifterror arguments");
  277         assert(SwiftErrorAddr->isSwiftError() &&
lib/CodeGen/SwitchLoweringUtils.cpp
   22   assert(Last >= First);
   25   assert(LowCase.getBitWidth() == HighCase.getBitWidth());
   36   assert(Last >= First);
   37   assert(TotalCases[Last] >= TotalCases[First]);
   48   assert(!Clusters.empty());
   50     assert(C.Kind == CC_Range);
   52     assert(Clusters[i - 1].High->getValue().slt(Clusters[i].Low->getValue()));
   55   assert(TLI && "TLI not set!");
   79   assert(NumCases < UINT64_MAX / 100);
   80   assert(Range >= NumCases);
  138       assert(NumCases < UINT64_MAX / 100);
  139       assert(Range >= NumCases);
  169     assert(Last >= First);
  170     assert(DstIndex <= First);
  190   assert(First <= Last);
  202     assert(Clusters[I].Kind == CC_Range);
  210       assert(PreviousHigh.slt(Low));
  267   assert(!Clusters.empty());
  268   assert(Clusters[0].Kind == CC_Range || Clusters[0].Kind == CC_JumpTable);
  270     assert(C.Kind == CC_Range || C.Kind == CC_JumpTable);
  272     assert(Clusters[i-1].High->getValue().slt(Clusters[i].Low->getValue()));
  343     assert(First <= Last);
  344     assert(DstIndex <= First);
  363   assert(First <= Last);
  370     assert(Clusters[I].Kind == CC_Range);
  378   assert(Low.slt(High));
  387   assert(TLI->rangeFitsInWord(Low, High, *DL) &&
  427     assert(Hi >= Lo && Hi < 64 && "Invalid bit case!");
  462     assert(CC.Low == CC.High && "Input clusters must be single-case");
lib/CodeGen/TailDuplicator.cpp
   89   assert(MBPI != nullptr && "Machine Branch Probability Info required");
  345   assert(SrcOpIdx && "Unable to find matching PHI source?");
  478       assert(Idx != 0);
  642       assert(Idx != 0);
  761       assert(PredBB->succ_size() <= 1);
  817     assert(TailBB != PredBB &&
  863     assert(PredBB->succ_empty() &&
  913         assert(!MI->isBundle() && "Not expecting bundles before regalloc!");
  924     assert(PrevBB->succ_empty());
  995   assert(MBB->pred_empty() && "MBB must be dead!");
lib/CodeGen/TargetFrameLoweringImpl.cpp
   34   assert(MF.getFunction().hasFnAttribute(Attribute::NoReturn) &&
lib/CodeGen/TargetInstrInfo.cpp
  167   assert(findCommutedOpIndices(MI, CommutableOpIdx1, CommutableOpIdx2) &&
  170   assert(MI.getOperand(Idx1).isReg() && MI.getOperand(Idx2).isReg() &&
  247     assert(MI.isCommutable() &&
  288   assert(!MI.isBundle() &&
  324   assert(!MI.isBundle() &&
  400   assert(TRI->getSpillSize(*RC) >= (Offset + Size) && "bad subregister range");
  426   assert(!Orig.isNotDuplicable() && "Instruction cannot be duplicated");
  435   assert(MI.isCopy() && "MI must be a COPY instruction");
  438   assert(FoldIdx<2 && "FoldIdx refers no nonexistent operand");
  449   assert(Register::isVirtualRegister(FoldReg) && "Cannot fold physregs");
  541   assert(MBB && "foldMemoryOperand needs an inserted instruction");
  567   assert(MemSize && "Did not expect a zero-sized stack slot");
  586     assert((!(Flags & MachineMemOperand::MOStore) ||
  589     assert((!(Flags & MachineMemOperand::MOLoad) ||
  592     assert(MFI.getObjectOffset(FI) != -1);
  623   assert(LoadMI.canFoldAsLoad() && "LoadMI isn't foldable!");
  626     assert(MI.getOperand(OpIdx).isUse() && "Folding load into def!");
  877   assert(Prev && "Unknown pattern for machine combiner");
 1169   assert((MI.isRegSequence() ||
 1177   assert(DefIdx == 0 && "REG_SEQUENCE only has one def");
 1184     assert(MOSubIdx.isImm() &&
 1196   assert((MI.isExtractSubreg() ||
 1204   assert(DefIdx == 0 && "EXTRACT_SUBREG only has one def");
 1209   assert(MOSubIdx.isImm() &&
 1221   assert((MI.isInsertSubreg() ||
 1229   assert(DefIdx == 0 && "INSERT_SUBREG only has one def");
 1235   assert(MOSubIdx.isImm() &&
lib/CodeGen/TargetLoweringBase.cpp
   92   assert(TT.isOSDarwin() && "should be called with darwin triple");
  799   assert(LHSTy.isInteger() && "Shift amount is not an integer type!");
  807   assert(isTypeLegal(VT));
  830     assert((unsigned)SVT.SimpleTy < array_lengthof(TransformToType));
  834     assert((LA == TypeLegal || LA == TypeSoftenFloat ||
  850     assert(VT.isInteger() && "Float types must be simple");
  855       assert(NVT != VT && "Unable to round integer VT");
 1057       assert(MI->getOpcode() == TargetOpcode::STATEPOINT && "sanity");
 1075     assert(MIB->mayLoad() && "Folded a stackmap use to a non-load!");
 1078     assert(MFI.getObjectOffset(FI) != -1);
 1102   assert(MI.getOpcode() == TargetOpcode::PATCHABLE_EVENT_CALL &&
 1117   assert(MI.getOpcode() == TargetOpcode::PATCHABLE_TYPED_EVENT_CALL &&
 1179     assert(LargestIntReg != MVT::i1 && "No integer registers defined!");
 1378   assert(!VT.isVector() && "No default SetCC type for vectors!");
 1841     assert(VT.getScalarType() == MVT::f32 &&
 1954     assert(Override != "none" &&
lib/CodeGen/TargetLoweringObjectFileImpl.cpp
  551     assert(!Kind.isMergeableCString() && "unknown string width");
  552     assert(!Kind.isMergeableConst() && "unknown data width");
  606   assert(Section->getAssociatedSymbol() == AssociatedSymbol &&
  626   assert(Kind.isReadOnlyWithRel() && "Unknown section kind");
  708   assert(Section->getAssociatedSymbol() == AssociatedSymbol);
  750   assert(Kind.isReadOnlyWithRel() && "Unknown section kind");
 1259   assert(C && "expected GV to have a Comdat!");
 1604   assert(Width >= Size && "hex string is too large!");
 1837   assert(!TM.getFunctionSections() && !TM.getDataSections() &&
lib/CodeGen/TargetPassConfig.cpp
  298     assert(InsertedPassID.isValid() && "Illegal Pass ID!");
  302     assert(NP && "Pass ID not registered");
  434   assert(((!InsertedPassID.isInstance() &&
  489   assert(!Initialized && "PassConfig is immutable");
  519   assert(!Initialized && "PassConfig is immutable");
  688   assert(MCAI && "No MCAsmInfo");
  881       assert(IPI && "failed to get \"machineinstr-printer\" PassInfo!");
lib/CodeGen/TargetRegisterInfo.cpp
  136     assert(Roots.isValid() && "Unit has no roots.");
  162       assert((RegInfo.def_empty(Reg) || RegInfo.getType(Reg).isValid()) &&
  191   assert(Register::isPhysicalRegister(reg) &&
  203   assert(BestRC && "Couldn't find the register class");
  211   assert(RC->isAllocatable() && "invalid for nonallocatable sets");
  266   assert(A && B && "Missing register class");
  267   assert(Idx && "Bad sub-register index");
  282   assert(RCA && SubA && RCB && SubB && "Invalid arguments");
  435     assert(Register::isPhysicalRegister(PhysReg) &&
  490   assert(RC && "Unable to deduce the register class");
  506       assert(MI->isSubregToReg() && "Bad opcode for lookThruCopyLike");
lib/CodeGen/TargetSchedule.cpp
   59   assert((LCM >= A && LCM >= B) && "LCM overflow");
  144     assert(++NIter < 6 && "Variants are nested deeper than the magic number");
  261   assert(hasInstrSchedModel() && "Only call this function with a SchedModel");
lib/CodeGen/TwoAddressInstructionPass.cpp
  253     assert(LI.end() != LI.begin() &&
  319   assert(KillMO && "Didn't find kill");
  445     assert(I != LI.end() && "Reg must be live-in to use.");
  695   assert(NewMI == MI &&
  736   assert(MBB->getIterator() == MFI &&
  795       assert(SrcRegMap[NewReg] == Reg && "Can't map to two src registers!");
  808         assert(DstRegMap[FromReg] == ToReg &&"Can't map to two dst registers!");
  813       assert(DstRegMap[DstReg] == ToReg && "Can't map to two dst registers!");
  843       assert(SrcRegMap[DstReg] == SrcReg &&
  873     assert(LI.end() != LI.begin() &&
  982         assert((MOReg != Reg || &OtherMI == KillMI) &&
 1035     assert(Dist > DefDist && "Visited def already?");
 1063     assert(LI.end() != LI.begin() &&
 1280   assert(Register::isVirtualRegister(regB) &&
 1372         assert(NewMIs.size() == 2 &&
 1392         assert(!TransformResult &&
 1406                       assert(NewMIs[1]->killsRegister(MO.getReg()) &&
 1415                     assert(NewMIs[0]->registerDefIsDead(MO.getReg()) &&
 1480     assert(SrcReg && SrcMO.isUse() && "two address instruction invalid");
 1538     assert(Register::isVirtualRegister(RegB) &&
 1546       assert(i == DstIdx ||
 1560         assert(TRI->getMatchingSuperRegClass(RC, MRI->getRegClass(RegA),
 1566         assert(TRI->getMatchingSuperReg(RegA, SubRegB, MRI->getRegClass(RegB))
 1592     assert(MO.isReg() && MO.getReg() == RegB && MO.isUse() &&
 1645       assert(I != LI.end() && "RegB must be live-in to use.");
 1767         assert(mi->getOperand(0).getSubReg() == 0 && "Unexpected subreg idx");
lib/CodeGen/UnreachableBlockElim.cpp
  179         assert(Output.getSubReg() == 0 && "Cannot have output subregister");
lib/CodeGen/ValueTypes.cpp
   30   assert(VT.isExtended() && "Type is not extended!");
   38   assert(ResultVT.isExtended() && "Type is not extended!");
   43   assert(isExtended() && "Type is not extended!");
   48   assert(isExtended() && "Type is not extended!");
   53   assert(isExtended() && "Type is not extended!");
   58   assert(isExtended() && "Type is not extended!");
   95   assert(isExtended() && "Type is not extended!");
  100   assert(isExtended() && "Type is not extended!");
  105   assert(isExtended() && "Type is not extended!");
  267     assert(isExtended() && "Type is not extended!");
lib/CodeGen/VirtRegMap.cpp
   84   assert(virtReg.isVirtual() && Register::isPhysicalRegister(physReg));
   85   assert(Virt2PhysMap[virtReg.id()] == NO_PHYS_REG &&
   88   assert(!getRegInfo().isReserved(physReg) &&
  120   assert(virtReg.isVirtual());
  121   assert(Virt2StackSlotMap[virtReg.id()] == NO_STACK_SLOT &&
  128   assert(virtReg.isVirtual());
  129   assert(Virt2StackSlotMap[virtReg.id()] == NO_STACK_SLOT &&
  131   assert((SS >= 0 ||
  268   assert(!LI.empty());
  269   assert(LI.hasSubRanges());
  323     assert(PhysReg != VirtRegMap::NO_PHYS_REG && "Unmapped virtual register.");
  361   assert(LI.liveAt(BaseIndex) &&
  364   assert(SubRegIdx != 0 && LI.hasSubRanges());
  519         assert(PhysReg != VirtRegMap::NO_PHYS_REG &&
  521         assert(!MRI->isReserved(PhysReg) && "Reserved register assignment");
  549               assert(MO.isDef());
  564           assert(PhysReg.isValid() && "Invalid SubReg for physical register");
lib/CodeGen/WasmEHPrepare.cpp
  219   assert(F.hasPersonalityFn() && "Personality function not found");
  276   assert(BB->isEHPad() && "BB is not an EHPad!");
  294     assert(!GetSelectorCI &&
  307       assert(GetSelectorCI->use_empty() &&
  345   assert(GetSelectorCI && "wasm.get.ehselector() call does not exist");
lib/CodeGen/WinEHPrepare.cpp
  145   assert(TBME.TryLow <= TBME.TryHigh);
  182     assert(BBColors.size() == 1 && "multi-color BB not removed by preparation");
  188     assert(FuncletPad || FuncletEntryBB == &Fn->getEntryBlock());
  210       assert(FuncInfo.EHPadStateMap.count(PadInst) && "EH Pad has no state!");
  228   assert(!TI->isEHPad() && "unexpected EHPad!");
  239   assert(BB->isEHPad() && "not a funclet!");
  242     assert(FuncInfo.EHPadStateMap.count(CatchSwitch) == 0 &&
  341   assert(BB->isEHPad() && "no a funclet!");
  344     assert(FuncInfo.EHPadStateMap.count(CatchSwitch) == 0 &&
  349     assert(CatchSwitch->getNumHandlers() == 1 &&
  357     assert((Filter || FilterOrNull->isNullValue()) &&
  572       assert(CatchSwitch->getNumHandlers());
  775       assert(NewColors.empty() && "A new block should only have one color!");
  833           assert(!IncomingColors.empty() && "Block not colored!");
  834           assert((IncomingColors.size() == 1 ||
  906         assert(!ColorsForUserBB.empty());
 1024     assert(NumColors == 1 && "Expected monochromatic BB!");
 1029     assert((DisableDemotion || !(BB.isEHPad() && isa<PHINode>(BB.begin()))) &&
 1242   assert(InvokeStateMap.count(II) &&
lib/DebugInfo/CodeView/AppendingTypeTableBuilder.cpp
   91   assert(!Fragments.empty());
lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
   27   assert(!Limits.empty() && "Not in a record!");
   61   assert(!Limits.empty() && "Not in a record!");
   74   assert(Min.hasValue() && "Every field must have a maximum length!");
   86   assert(!isWriting() && "Cannot skip padding while writing!");
  276   assert(Value < 0 && "Encoded integer is not signed!");
  325   assert(Value < 0 && "Encoded integer is not signed!");
lib/DebugInfo/CodeView/ContinuationRecordBuilder.cpp
   52   assert(!Kind.hasValue());
   58   assert(SegmentWriter.getOffset() == 0);
   59   assert(SegmentWriter.getLength() == 0);
   79   assert(Kind.hasValue());
   96   assert(getCurrentSegmentLength() % 4 == 0);
  114     assert(getCurrentSegmentLength() == MemberLength + sizeof(RecordPrefix));
  117   assert(getCurrentSegmentLength() % 4 == 0);
  118   assert(getCurrentSegmentLength() <= MaxSegmentLength);
  128   assert(Offset > SegmentBegin);
  129   assert(Offset - SegmentBegin <= MaxSegmentLength);
  140   assert(SegmentLength % 4 == 0);
  141   assert(SegmentLength <= MaxRecordLength);
  146   assert(SegmentWriter.bytesRemaining() == 0);
  151   assert(OffEnd - OffBegin <= USHRT_MAX);
  165     assert(CR->Kind == TypeLeafKind::LF_INDEX);
  166     assert(CR->IndexRef == 0xB0C0B0C0);
lib/DebugInfo/CodeView/DebugChecksumsSubsection.cpp
   84   assert(SerializedSize % 4 == 0);
  113   assert(Iter != OffsetMap.end());
lib/DebugInfo/CodeView/DebugInlineeLinesSubsection.cpp
   53   assert(Reader.bytesRemaining() == 0);
   79   assert(Size % 4 == 0);
lib/DebugInfo/CodeView/DebugLinesSubsection.cpp
   94   assert(B.Lines.size() == B.Columns.size());
  115     assert(B.Lines.size() == B.Columns.size() || B.Columns.empty());
lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp
   78     assert(Writer.getOffset() <= End);
   82   assert((End - Begin) == StringSize);
   99   assert(Iter != StringToId.end());
  105   assert(Iter != IdToString.end());
lib/DebugInfo/CodeView/DebugSubsectionRecord.cpp
   72   assert(Writer.getOffset() % alignOf(Container) == 0 &&
lib/DebugInfo/CodeView/Formatters.cpp
   29   assert(Item.size() == 16 && "Expected 16-byte GUID");
lib/DebugInfo/CodeView/GlobalTypeTableBuilder.cpp
   92                           assert(Data.size() == Record.size());
  102   assert(!Fragments.empty());
lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp
   29   assert(!static_cast<bool>(EC));
   85   assert(contains(Index));
   91   assert(!Index.isSimple());
   95   assert(contains(Index));
  109   assert(contains(Index));
  158   assert(!Index.isSimple());
  166   assert(NewCapacity > capacity());
  171   assert(!TI.isSimple());
  180   assert(Next != PartialOffsets.begin());
  226   assert(!TI.isSimple());
  227   assert(PartialOffsets.empty());
  267   assert(RI != Types.end());
lib/DebugInfo/CodeView/MergingTypeTableBuilder.cpp
   92   assert(Record.size() < UINT32_MAX && "Record too big");
   93   assert(Record.size() % 4 == 0 && "Record is not aligned to 4 bytes!");
  119   assert(!Fragments.empty());
lib/DebugInfo/CodeView/RecordName.cpp
   80     assert(Indices[I] < CurrentTypeIndex);
lib/DebugInfo/CodeView/StringsAndChecksums.cpp
   34   assert(SR.kind() == DebugSubsectionKind::StringTable);
   35   assert(!Strings && "Found a string table even though we already have one!");
   73   assert(FCR.kind() == DebugSubsectionKind::FileChecksums);
lib/DebugInfo/CodeView/SymbolRecordHelpers.cpp
   24   assert(symbolOpensScope(Sym.kind()));
   48     assert(false && "Unknown record type");
   55   assert(symbolOpensScope(Sym.kind()));
   79     assert(false && "Unknown record type");
   88   assert(symbolOpensScope(Opener.kind()));
lib/DebugInfo/CodeView/SymbolRecordMapping.cpp
  488   assert(unsigned(EncodedReg) < 4);
lib/DebugInfo/CodeView/SymbolSerializer.cpp
   27   assert(!CurrentSymbol.hasValue() && "Already in a symbol mapping!");
   42   assert(CurrentSymbol.hasValue() && "Not in a symbol mapping!");
lib/DebugInfo/CodeView/TypeIndex.cpp
   71   assert(TI.isNoneType() || TI.isSimple());
lib/DebugInfo/CodeView/TypeIndexDiscovery.cpp
   44   assert(N <= LF_UQUADWORD);
lib/DebugInfo/CodeView/TypeRecordHelpers.cpp
   48   assert(CVT.kind() == LF_MODIFIER);
lib/DebugInfo/CodeView/TypeRecordMapping.cpp
  188   assert(!TypeKind.hasValue() && "Already in a type mapping!");
  189   assert(!MemberKind.hasValue() && "Already in a member mapping!");
  220   assert(TypeKind.hasValue() && "Not in a type mapping!");
  221   assert(!MemberKind.hasValue() && "Still in a member mapping!");
  230   assert(TypeKind.hasValue() && "Not in a type mapping!");
  231   assert(!MemberKind.hasValue() && "Already in a member mapping!");
  256   assert(TypeKind.hasValue() && "Not in a type mapping!");
  257   assert(MemberKind.hasValue() && "Not in a member mapping!");
  396   assert((CVR.kind() == TypeLeafKind::LF_STRUCTURE) ||
lib/DebugInfo/CodeView/TypeStreamMerger.cpp
   24   assert(!Idx.isSimple() && "simple type indices have no slots");
  118     assert(TypeLookup.empty());
  122     assert(hasIdStream());
  222     assert(IndexMap.size() == slotForIndex(CurIndex) &&
  226     assert(slotForIndex(CurIndex) < IndexMap.size());
  344     assert(NumBadIndices <= BadIndicesRemaining &&
  395   assert((IsSecondPass || IndexMap.size() == slotForIndex(CurIndex)) &&
lib/DebugInfo/CodeView/TypeTableCollection.cpp
   30   assert(contains(Prev));
   38   assert(Index.toArrayIndex() < Records.size());
lib/DebugInfo/DWARF/DWARFAcceleratorTable.cpp
  278   assert(HdrData && "Dereferencing end iterator?");
  279   assert(HdrData->Atoms.size() == Values.size());
  316   assert(NumData > 0 && "attempted to increment iterator past the end");
  533   assert(Abbr->Attributes.size() == Values.size());
  567   assert(Abbr->Attributes.size() == Values.size());
  581   assert(CU < Hdr.CompUnitCount);
  587   assert(TU < Hdr.LocalTypeUnitCount);
  593   assert(TU < Hdr.ForeignTypeUnitCount);
  627   assert(0 < Index && Index <= Hdr.NameCount);
  640   assert(Bucket < Hdr.BucketCount);
  646   assert(0 < Index && Index <= Hdr.NameCount);
  843   assert(CurrentIndex && "Incrementing an end() iterator?");
lib/DebugInfo/DWARF/DWARFDebugArangeSet.cpp
   82     assert(sizeof(arangeDescriptor.Address) >= HeaderData.AddrSize);
lib/DebugInfo/DWARF/DWARFDebugAranges.cpp
  104       assert(CUPos != ValidCUs.end());
  109   assert(ValidCUs.empty());
lib/DebugInfo/DWARF/DWARFDebugFrame.cpp
  220   assert(OperandIdx < 2);
  267     assert(Instr.Expression && "missing DWARFExpression object");
lib/DebugInfo/DWARF/DWARFDebugLine.cpp
   70   assert(DwarfVersion != 0 &&
   80   assert(DwarfVersion != 0 &&
  352     assert((DebugLineData.getAddressSize() == 0 ||
  558     assert(Prologue.getAddressSize() == 0 ||
  824           assert(Opcode - 1U < Prologue.StandardOpcodeLengths.size());
  914   assert(Seq.SectionIndex == Address.SectionIndex);
  924   assert(FirstRow->Address.Address <= Row.Address.Address &&
  929   assert(Seq.SectionIndex == RowPos->Address.SectionIndex);
 1012     assert(FirstRowIndex != UnknownRowIndex);
 1013     assert(LastRowIndex != UnknownRowIndex);
 1134   assert(DebugLineData.isValidOffset(Offset) &&
 1148   assert(DebugLineData.isValidOffset(Offset) &&
lib/DebugInfo/DWARF/DWARFDebugLoc.cpp
  236     assert(!EncodingString.empty() && "Unknown loclist entry encoding");
lib/DebugInfo/DWARF/DWARFDebugRnglists.cpp
   25   assert(*OffsetPtr < End &&
  193     assert(!EncodingString.empty() && "Unknown range entry encoding");
lib/DebugInfo/DWARF/DWARFDie.cpp
   44     assert(Shift < 64 && "undefined behavior");
  667   assert(AbbrDecl && "Must have abbreviation declaration");
  689     assert(U && "Die must have valid DWARF unit");
  694     assert(Index == NumAttrs && "Indexes should be [0, NumAttrs) only");
lib/DebugInfo/DWARF/DWARFExpression.cpp
  163         assert(AddressSize == 2);
  173         assert(getRefAddrSize(AddressSize, Version) == 2);
  246   assert(!Name.empty() && "DW_OP has no name!");
lib/DebugInfo/DWARF/DWARFGdbIndex.cpp
   79     assert(CuVector != ConstantPoolVectors.end() && "Invalid symbol table");
lib/DebugInfo/DWARF/DWARFListTable.cpp
   42   assert(FullLength == length());
lib/DebugInfo/DWARF/DWARFUnit.cpp
  284   assert(*offset_ptr - Offset <= 255 && "unexpected header size");
  331   assert(!DieArray.empty());
  430     assert(AddrOffsetSectionBase == 0);
  431     assert(RangeSectionBase == 0);
  650   assert(InlinedChain.empty());
  673   assert(Kind == DW_SECT_TYPES);
  756     assert(DieArray[I].getDepth() > Depth && "Not processing children?");
lib/DebugInfo/DWARF/DWARFVerifier.cpp
  544     assert(RefVal);
  568     assert(RefVal);
  585     assert(SecOffset); // DW_FORM_strp is a section offset.
  679       assert(LineTable == nullptr);
  730       assert(HasFullPath && "Invalid index?");
lib/DebugInfo/GSYM/FileWriter.cpp
   23   assert(Length < sizeof(Bytes));
   30   assert(Length < sizeof(Bytes));
lib/DebugInfo/GSYM/GsymCreator.cpp
  118   assert(!Files.empty());
  119   assert(Files[0].Dir == 0);
  120   assert(Files[0].Base == 0);
lib/DebugInfo/GSYM/GsymReader.cpp
  206   assert(Hdr);
  250   assert(*AddressIndex < AddrInfoOffsets.size());
lib/DebugInfo/GSYM/LineTable.cpp
  157     assert(MinLineDelta <= MaxLineDelta);
  189   assert(MinLineDelta <= MaxLineDelta);
lib/DebugInfo/GSYM/Range.cpp
   71   assert(Start >= BaseAddr);
lib/DebugInfo/MSF/MSFBuilder.cpp
  134     assert(Block != -1 && "We ran out of Blocks!");
  243     assert(ExpectedNumBlocks == D.second.size() &&
  335   assert(FpmWriter.bytesRemaining() == 0);
lib/DebugInfo/MSF/MappedBlockStream.cpp
   62   assert(StreamIndex < Layout.StreamMap.size() && "Invalid stream index");
  298       assert(Intersection.first <= Intersection.second);
  330   assert(StreamIndex < Layout.StreamMap.size() && "Invalid stream index");
lib/DebugInfo/PDB/Native/DbiModuleDescriptorBuilder.cpp
   80   assert(BulkSymbols.size() % alignOf(CodeViewContainer::Pdb) == 0 &&
   92     assert(Builder && "Empty C13 Fragment Builder!");
  162     assert(SymbolWriter.getOffset() % alignOf(CodeViewContainer::Pdb) == 0 &&
  166       assert(Builder && "Empty C13 Fragment Builder!");
  182   assert(Subsection);
lib/DebugInfo/PDB/Native/DbiModuleList.cpp
   49   assert(Modules == R.Modules);
   50   assert(Modi == R.Modi);
   51   assert(!isEnd());
   52   assert(!R.isEnd());
   59   assert(isCompatible(R));
   72   assert(isCompatible(R));
   73   assert(!(*this < R));
   79   assert(!R.isEnd());
   91   assert(Thisi >= R.Filei);
   97   assert(!isEnd());
  100   assert(Filei <= Modules->getSourceFileCount(Modi));
  109   assert(!isUniversalEnd());
  111   assert(N <= Filei);
  136   assert(Modules);
  137   assert(Modi <= Modules->getModuleCount());
  138   assert(Filei <= Modules->getSourceFileCount(Modi));
  227     assert(DescriptorIter != Descriptors.end());
  235   assert(DescriptorIter == Descriptors.end());
  236   assert(NextFileIndex == NumSourceFiles);
  254   assert(Modi < getModuleCount());
  257   assert(Iter != Descriptors.end());
lib/DebugInfo/PDB/Native/DbiStream.cpp
  226     assert(SectionContribVersion == DbiSecContribVer60);
  230     assert(SectionContribVersion == DbiSecContribV2);
lib/DebugInfo/PDB/Native/DbiStreamBuilder.cpp
   90   assert(Type != DbgHeaderType::NewFPO &&
  441     assert(Stream->StreamNumber != kInvalidStreamIndex);
lib/DebugInfo/PDB/Native/GSIStreamBuilder.cpp
  258     assert(Sym.kind() == SymbolKind::S_PUB32);
  272     assert(Idx >= 0 && size_t(Idx) < Records.size());
lib/DebugInfo/PDB/Native/GlobalsStream.cpp
   72   assert(EndRecordIndex <= GlobalsTable.HashRecords.size());
lib/DebugInfo/PDB/Native/InfoStreamBuilder.cpp
   80   assert(Writer.bytesRemaining() == 0);
lib/DebugInfo/PDB/Native/InjectedSourceStream.cpp
   63   assert(Reader.bytesRemaining() == 0);
lib/DebugInfo/PDB/Native/ModuleDebugStream.cpp
  117   assert(Iter != SymbolArray.end());
lib/DebugInfo/PDB/Native/NamedStreamMap.cpp
   92   assert(NamesBuffer.size() > Offset);
lib/DebugInfo/PDB/Native/NativeSymbolEnumerator.cpp
   81     assert(Record.Value.isSignedIntN(BT.getLength() * 8));
   97     assert(Record.Value.isIntN(BT.getLength() * 8));
  112     assert(Record.Value.isIntN(BT.getLength() * 8));
  117     assert(false && "Invalid enumeration type");
lib/DebugInfo/PDB/Native/NativeTypeEnum.cpp
   72     assert(FieldList.kind() == LF_FIELDLIST);
lib/DebugInfo/PDB/Native/NativeTypePointer.cpp
   22   assert(TI.isSimple());
   23   assert(TI.getSimpleMode() != SimpleTypeMode::Direct);
   73   assert(Record);
   95     assert(false && "invalid simple type mode!");
lib/DebugInfo/PDB/Native/PDBFile.cpp
  181   assert(ContainerLayout.SB);
  228   assert(Reader.bytesRemaining() == 0);
  377     assert(Reader.bytesRemaining() == 0);
  466   assert(*ExpectedNSI < getNumStreams());
  479   assert(*ExpectedNSI < getNumStreams());
lib/DebugInfo/PDB/Native/PDBFileBuilder.cpp
   97   assert(NamedStreamData.count(*ExpectedIndex) == 0);
  227   assert(!InjectedSourceTable.empty());
  242   assert(Writer.bytesRemaining() == 0);
  258     assert(SourceWriter.bytesRemaining() == IS.Content->getBufferSize());
  265   assert(!Filename.empty());
  323   assert(!InfoStreamBlocks.empty());
lib/DebugInfo/PDB/Native/PDBStringTable.cpp
   38   assert(Reader.bytesRemaining() == 0);
   53   assert(Reader.bytesRemaining() == 0);
   80   assert(Reader.bytesRemaining() == 0);
  105   assert(Reader.bytesRemaining() == 0);
lib/DebugInfo/PDB/Native/PDBStringTableBuilder.cpp
  128   assert(Entry != StringsToBuckets.end());
  161   assert(Writer.bytesRemaining() == 0);
  169   assert(Writer.bytesRemaining() == 0);
  197   assert(Writer.bytesRemaining() == 0);
  204   assert(Writer.bytesRemaining() == 0);
lib/DebugInfo/PDB/Native/SymbolCache.cpp
  136     assert(false && "Invalid LF_MODIFIER record");
  151     assert(TypeIndexToSymbolId.count(Index) == 0);
  171       assert(!isUdtForwardRef(Types.getType(*EFD)));
  175       assert(TypeIndexToSymbolId.count(Index) == 0);
  224     assert(TypeIndexToSymbolId.count(Index) == 0);
  232   assert(SymbolId < Cache.size());
  277     assert(GlobalOffsetToSymbolId.count(Offset) == 0);
lib/DebugInfo/PDB/Native/TpiHashing.cpp
   99     assert(false && "Type is not a tag record!");
lib/DebugInfo/PDB/Native/TpiStream.cpp
  222   assert(!Index.isSimple());
lib/DebugInfo/PDB/Native/TpiStreamBuilder.cpp
  104   assert((TypeRecords.size() == TypeHashes.size() || TypeHashes.empty()) &&
  156     assert(!Rec.empty()); // An empty record will not write anything, but it
lib/DebugInfo/PDB/PDBContext.cpp
   54   assert(LineInfo);
lib/DebugInfo/PDB/UDTLayout.cpp
  216   assert(VTables.size() <= 1);
lib/DebugInfo/Symbolize/SymbolizableObjectFile.cpp
   48   assert(DICtx);
lib/DebugInfo/Symbolize/Symbolize.cpp
  353   assert(Obj != nullptr);
  419   assert(InsertResult.second);
lib/Demangle/ItaniumDemangle.cpp
  355     assert(Parser.ForwardTemplateRefs.empty());
  529   assert(RootNode != nullptr && "must call partialDemangle()");
  534   assert(RootNode != nullptr && "must call partialDemangle()");
  574   assert(RootNode != nullptr && "must call partialDemangle()");
  580   assert(RootNode != nullptr && "must call partialDemangle()");
lib/Demangle/MicrosoftDemangle.cpp
  485   assert(MangledName.startsWith('?'));
  755   assert(MangledName.startsWith("??@"));
  787   assert(MangledName.startsWith('.'));
  953   assert(startsWithDigit(MangledName));
  984   assert(MangledName.startsWith("?$"));
 1029   assert(isRebasedHexDigit(C));
 1034   assert(!MangledName.empty());
 1106   assert(Digit <= 15);
 1111   assert (C != 0);
 1131   assert(Pos >= 0);
 1210   assert(NumBytes > 0);
 1244   assert(CharBytes == 1 || CharBytes == 2 || CharBytes == 4);
 1355     assert(StringByteSize % CharBytes == 0);
 1414   assert(MangledName.startsWith("?A"));
 1432   assert(startsWithLocalScopePattern(MangledName));
 1439   assert(!IsNegative);
 1444   assert(!Error);
 1472   assert(Identifier);
 1477   assert(QN);
 1510   assert(QN);
 1588     assert(!Error);
 1720   assert(MangledName.front() >= '0' && MangledName.front() <= '4');
 1802       assert(MangledName.startsWith("$$A6"));
 1908   assert(MangledName.startsWith('?'));
 2001     assert(false);
 2033   assert(Pointer->Affinity == PointerAffinity::Pointer);
 2047     assert(IsMember || Error);
 2071   assert(MangledName.front() == 'Y');
 2152     assert(CharsConsumed != 0);
 2298   assert(!Error);
 2302   assert(MangledName.startsWith('@')); // The above loop exits only on '@'.
lib/Demangle/MicrosoftDemangleNodes.cpp
  513     assert(false);
  549   assert(N->kind() == NodeKind::IntegerLiteral);
lib/ExecutionEngine/ExecutionEngine.cpp
   79   assert(M && "Module is null?");
  192   assert(GV->hasName() && "Global must have name.");
  214   assert(!Name.empty() && "Empty GlobalMapping symbol name!");
  218   assert((!CurVal || !Addr) && "GlobalMapping already established!");
  224     assert((!V.empty() || !Name.empty()) &&
  270     assert((!V.empty() || !Name.empty()) &&
  458       assert(!isTargetNullPtr(this, GVTOP(GVArgs[1])) &&
  738       assert(PtrWidth <= 64 && "Bad pointer width");
  748       assert(GV.IntVal.getBitWidth() <= 64 && "Bad pointer width");
  758           assert(DestTy->isFloatingPointTy() && "invalid bitcast");
  765           assert(DestTy->isIntegerTy(32) && "Invalid bitcast");
  769           assert(DestTy->isIntegerTy(64) && "Invalid bitcast");
  773           assert(DestTy->isPointerTy() && "Invalid bitcast");
 1264         assert(Ptr && "Canonical global wasn't codegen'd!");
lib/ExecutionEngine/ExecutionEngineBindings.cpp
  347   assert(Functions.AllocateCodeSection &&
  349   assert(Functions.AllocateDataSection &&
  351   assert(Functions.FinalizeMemory &&
  353   assert(Functions.Destroy &&
  379   assert((result || !errMsgCString) &&
lib/ExecutionEngine/GDBRegistrationListener.cpp
  163   assert(ObjectBufferMap.find(K) == ObjectBufferMap.end() &&
  210       assert(__jit_debug_descriptor.first_entry == JITCodeEntry);
lib/ExecutionEngine/Interpreter/Execution.cpp
  590     assert(Src1.AggregateVal.size() == Src2.AggregateVal.size());
  621     assert(Src1.AggregateVal.size() == Src2.AggregateVal.size());
  652       assert(Src1.AggregateVal.size() == Src2.AggregateVal.size());
  743     assert(Src1.AggregateVal.size() == Src2.AggregateVal.size());
  847       assert(Src1.AggregateVal.size() == Src2.AggregateVal.size());
  848       assert(Src2.AggregateVal.size() == Src3.AggregateVal.size());
  996     assert(i != -1 && "PHINode doesn't contain entry for predecessor??");
 1037   assert(Result.PointerVal && "Null pointer returned by malloc!");
 1049   assert(Ptr->getType()->isPointerTy() &&
 1072         assert(BitWidth == 64 && "Invalid index type for getelementptr");
 1198     assert(src1Size == Src2.AggregateVal.size());
 1225     assert(src1Size == Src2.AggregateVal.size());
 1252     assert(src1Size == Src2.AggregateVal.size());
 1336     assert(SrcVal->getType()->getScalarType()->isDoubleTy() &&
 1346     assert(SrcVal->getType()->isDoubleTy() && DstTy->isFloatTy() &&
 1359     assert(SrcVal->getType()->getScalarType()->isFloatTy() &&
 1368     assert(SrcVal->getType()->isFloatTy() && DstTy->isDoubleTy() &&
 1390       assert(SrcVecTy->isFloatingPointTy() && "Invalid FPToUI instruction");
 1402     assert(SrcTy->isFloatingPointTy() && "Invalid FPToUI instruction");
 1428       assert(SrcVecTy->isFloatingPointTy() && "Invalid FPToSI instruction");
 1440     assert(SrcTy->isFloatingPointTy() && "Invalid FPToSI instruction");
 1462       assert(DstVecTy->isFloatingPointTy() && "Invalid UIToFP instruction");
 1473     assert(DstTy->isFloatingPointTy() && "Invalid UIToFP instruction");
 1494       assert(DstVecTy->isFloatingPointTy() && "Invalid SIToFP instruction");
 1505     assert(DstTy->isFloatingPointTy() && "Invalid SIToFP instruction");
 1521   assert(SrcVal->getType()->isPointerTy() && "Invalid PtrToInt instruction");
 1530   assert(DstTy->isPointerTy() && "Invalid PtrToInt instruction");
 1675       assert(SrcTy->isPointerTy() && "Invalid BitCast");
 2124   assert((ECStack.empty() || !ECStack.back().Caller.getInstruction() ||
 2145   assert((ArgVals.size() == F->arg_size() ||
lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
  312   assert(Args.size() == 1);
  431   assert(args.size() < 10 && "Only handle up to 10 args to sscanf right now!");
  445   assert(args.size() < 10 && "Only handle up to 10 args to scanf right now!");
  461   assert(Args.size() >= 2);
lib/ExecutionEngine/Interpreter/Interpreter.cpp
   82   assert (F && "Function *F was null at entry to run()");
lib/ExecutionEngine/JITLink/BasicGOTAndStubsBuilder.h
   40     assert(Target.hasName() && "GOT edge cannot point to anonymous target");
   51     assert(GOTEntryI != GOTEntries.end() && "Could not get GOT entry symbol");
   56     assert(Target.hasName() &&
   65     assert(StubI != Stubs.end() && "Count not get stub symbol");
lib/ExecutionEngine/JITLink/EHFrameSupport.cpp
  269   assert(!CIEInfos.count(CIESymbol.getAddress()) &&
lib/ExecutionEngine/JITLink/JITLinkGeneric.cpp
   32   assert(G && "Graph should have been created by buildGraph above");
  261     assert(Sym->getAddress() == 0 &&
  263     assert(Sym->getName() != StringRef() && Sym->getName() != "" &&
  272     assert(Sym->getAddress() == 0 && "Symbol already resolved");
  273     assert(!Sym->isDefined() && "Symbol being resolved is already defined");
  274     assert(Result.count(Sym->getName()) && "Missing resolution for symbol");
  284   assert(llvm::all_of(G->external_symbols(),
  290   assert(Err && "Should not be bailing out on success value");
  291   assert(Alloc && "can not call deallocateAndBailOut before allocation");
  296   assert(G && "Graph is not set yet");
lib/ExecutionEngine/JITLink/JITLinkGeneric.h
   37     assert(this->Ctx && "Ctx can not be null");
lib/ExecutionEngine/JITLink/JITLinkMemoryManager.cpp
   29       assert(SegBlocks.count(Seg) && "No allocation for segment");
   34       assert(SegBlocks.count(Seg) && "No allocation for segment");
   51       assert((SlabSize % sys::Process::getPageSizeEstimate()) == 0 &&
lib/ExecutionEngine/JITLink/MachOLinkGraphBuilder.cpp
   55   assert(!CustomSectionParserFunctions.count(SectionName) &&
  181                assert(LHS && RHS && "Null section?");
  291   assert(!AddrToCanonicalSymbol.count(Sym.getAddress()) &&
lib/ExecutionEngine/JITLink/MachOLinkGraphBuilder.h
  110       assert((!Name || !Name->empty()) && "Name must be none or non-empty");
  170     assert(I != IndexToSection.end() && "No section recorded at index");
  231     assert((!CanonicalSymEntry || CanonicalSymEntry->getSize() == 0) &&
lib/ExecutionEngine/JITLink/MachO_arm64.cpp
  129     assert(((SubtractorKind == Delta32 && SubRI.r_length == 2) ||
  132     assert(SubRI.r_extern && "SUBTRACTOR reloc symbol should be extern");
  133     assert(!SubRI.r_pcrel && "SUBTRACTOR reloc should not be PCRel");
  370           assert(TargetSymbol && "No target symbol from parsePairRelocation?");
  438     assert(E.getKind() == Branch26 && "Not a Branch32 edge?");
  439     assert(E.getAddend() == 0 && "Branch32 edge has non-zero addend?");
  549       assert((FixupAddress & 0x3) == 0 && "Branch-inst is not 32-bit aligned");
  561       assert((RawInstr & 0x7fffffff) == 0x14000000 &&
  582       assert(E.getAddend() == 0 && "PAGE21/GOTPAGE21 with non-zero addend");
  592       assert((RawInstr & 0xffffffe0) == 0x90000000 &&
  601       assert(E.getAddend() == 0 && "PAGEOFF12 with non-zero addend");
  616       assert(E.getAddend() == 0 && "GOTPAGEOF12 with non-zero addend");
  619       assert((RawInstr & 0xfffffc00) == 0xf9400000 &&
  623       assert((TargetOffset & 0x7) == 0 && "GOT entry is not 8-byte aligned");
  630       assert((FixupAddress & 0x3) == 0 && "LDR is not 32-bit aligned");
  631       assert(E.getAddend() == 0 && "LDRLiteral19 with non-zero addend");
  633       assert(RawInstr == 0x58000010 && "RawInstr isn't a 64-bit LDR literal");
lib/ExecutionEngine/JITLink/MachO_x86_64.cpp
  131     assert(((SubtractorKind == Delta32 && SubRI.r_length == 2) ||
  134     assert(SubRI.r_extern && "SUBTRACTOR reloc symbol should be extern");
  135     assert(!SubRI.r_pcrel && "SUBTRACTOR reloc should not be PCRel");
  339           assert(TargetSymbol && "No target symbol from parsePairRelocation?");
  380     assert((E.getKind() == PCRel32GOT || E.getKind() == PCRel32GOTLoad) &&
  401     assert(E.getKind() == Branch32 && "Not a Branch32 edge?");
  402     assert(E.getAddend() == 0 && "Branch32 edge has non-zero addend?");
lib/ExecutionEngine/MCJIT/MCJIT.cpp
  144   assert(M && "Can not emit a null module");
  191   assert(OwnedModules.ownsModule(M) &&
  203   assert(M->getDataLayout() == getDataLayout() && "DataLayout Mismatch");
  208     assert(ObjectToLoad && "Compilation did not produce an object.");
  271   assert(OwnedModules.ownsModule(M) && "MCJIT::finalizeModule: Unknown module.");
  508   assert(F && "Function *F was null at entry to run()");
  512   assert(FPtr && "Pointer to fn's code was null after getPointerToFunction");
  516   assert((FTy->getNumParams() == ArgValues.size() ||
  519   assert(FTy->getNumParams() == ArgValues.size() &&
lib/ExecutionEngine/MCJIT/MCJIT.h
  128       assert(AddedModules.count(M) &&
  143       assert(LoadedModules.count(M) &&
lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp
   36       assert(A.hasName() && "Anonymous alias?");
   37       assert(Aliasee->hasName() && "Anonymous aliasee");
  126   assert(TSM && "Null module");
  178       assert(!NewSearchOrder.empty() &&
  213   assert(!Partition.empty() && "Unexpected empty partition");
  250     assert(Defs.count(Name) && "No definition for symbol");
lib/ExecutionEngine/Orc/Core.cpp
  211     assert(JDs.front().first && "JITDylibList entries must not be null");
  215       assert(KV.first && "JITDylibList entries must not be null");
  254   assert(!this->Symbols->empty() && "Can not fail to resolve an empty set");
  267   assert(!this->Symbols.empty() && "Can not fail to resolve an empty set");
  280   assert(!this->Symbols.empty() && "Can not fail to resolve an empty set");
  295   assert(RequiredState >= SymbolState::Resolved &&
  308   assert(I != ResolvedSymbols.end() &&
  310   assert(I->second.getAddress() == 0 && "Redundantly resolving symbol Name");
  316   assert(OutstandingSymbolsCount == 0 &&
  327   assert(QueryRegistrations.empty() && ResolvedSymbols.empty() &&
  338   assert(Added && "Duplicate dependence notification?");
  344   assert(QRI != QueryRegistrations.end() &&
  346   assert(QRI->second.count(Name) && "No dependency on Name in JD");
  363   assert(!this->SymbolFlags.empty() && "Materializing nothing?");
  367   assert(SymbolFlags.empty() &&
  383     assert(I != SymbolFlags.end() &&
  385     assert((KV.second.getFlags() & ~WeakFlags) == (I->second & ~WeakFlags) &&
  458     assert(I != SymbolFlags.end() &&
  472   assert(SymbolFlags.count(Name) &&
  501   assert(Symbols.count(Name) && "Symbol is not part of this MU");
  539     assert(I != Aliases.end() && "Symbol not found in aliases map?");
  598     assert(!QuerySymbols.empty() && "Alias cycle detected!");
  620       assert(Deps.size() == 1 && Deps.count(&SrcJD) &&
  639           assert(Result->count(KV.second.Aliasee) &&
  668   assert(Aliases.count(Name) &&
  698     assert(Flags->count(Name) && "Missing entry in flags map");
  742     assert(I != DefGenerators.end() && "Generator not found");
  776   assert(MU != nullptr && "Can not replace with a null MaterializationUnit");
  784           assert(SymI != Symbols.end() && "Replacing unknown symbol");
  785           assert(SymI->second.isInMaterializationPhase() &&
  787           assert(!SymI->second.hasMaterializerAttached() &&
  789           assert(UnmaterializedInfos.count(KV.first) == 0 &&
  808           assert(SymI->second.getState() == SymbolState::Materializing &&
  810           assert(!SymI->second.hasMaterializerAttached() &&
  812           assert(UnmaterializedInfos.count(KV.first) == 0 &&
  832       assert(Symbols.count(KV.first) && "JITDylib does not cover this symbol?");
  833       assert(Symbols.find(KV.first)->second.isInMaterializationPhase() &&
  850   assert(Symbols.count(Name) && "Name not in symbol table");
  851   assert(Symbols[Name].isInMaterializationPhase() &&
  859   assert(Symbols[Name].getState() != SymbolState::Emitted &&
  867     assert(KV.first && "Null JITDylib in dependency?");
  879       assert(OtherSymI != OtherJITDylib.Symbols.end() &&
  895       assert(OtherJITDylib.MaterializingInfos.count(OtherSymbol) &&
  933       assert(!KV.second.getFlags().hasError() &&
  938       assert(SymI != Symbols.end() && "Symbol not found");
  939       assert(!SymI->second.hasMaterializerAttached() &&
  941       assert(SymI->second.getState() == SymbolState::Materializing &&
  943       assert(SymI->second.getAddress() == 0 &&
  951         assert(Flags == (SymI->second.getFlags() &
  987   assert((SymbolsInErrorState.empty() || CompletedQueries.empty()) &&
  999     assert(Q->isComplete() && "Q not completed");
 1018       assert(SymI != Symbols.end() && "No symbol table entry for Name");
 1039       assert(SymEntry.getState() == SymbolState::Resolved &&
 1044       assert(MII != MaterializingInfos.end() &&
 1056           assert(DependantMII != DependantJD.MaterializingInfos.end() &&
 1062           assert(DependantMI.UnemittedDependencies.count(this) &&
 1065           assert(DependantMI.UnemittedDependencies[this].count(Name) &&
 1077           assert(DependantSymI != DependantJD.Symbols.end() &&
 1086             assert(DependantMI.Dependants.empty() &&
 1120   assert((SymbolsInErrorState.empty() || CompletedQueries.empty()) &&
 1132     assert(Q->isComplete() && "Q is not complete");
 1151       assert(Worklist.back().first && "Failed JITDylib can not be null");
 1158       assert(JD.Symbols.count(Name) && "No symbol table entry for Name");
 1180           assert(DependantJD.Symbols.count(DependantName) &&
 1186           assert(DependantJD.MaterializingInfos.count(DependantName) &&
 1191           assert(UnemittedDepI != DependantMI.UnemittedDependencies.end() &&
 1193           assert(UnemittedDepI->second.count(Name) &&
 1203             assert(DependantMI.Dependants.empty() &&
 1217           assert(UnemittedDepMII != UnemittedDepJD.MaterializingInfos.end() &&
 1219           assert(UnemittedDepMII->second.Dependants.count(&JD) &&
 1221           assert(UnemittedDepMII->second.Dependants[&JD].count(Name) &&
 1237       assert(MI.Dependants.empty() &&
 1239       assert(MI.UnemittedDependencies.empty() &&
 1242       assert(!MI.hasQueriesPending() &&
 1373         assert(Unresolved2->empty() &&
 1391       assert(!Flags.count(Name) && "Symbol already present in Flags map");
 1403   assert(Q && "Query can not be null");
 1433       assert(NewDefs->empty() &&
 1480       assert(SymI->second.getAddress() == 0 &&
 1483       assert(UMII != UnmaterializedInfos.end() &&
 1486       assert(MU != nullptr && "Materializer should not be null");
 1502     assert(SymI->second.isInMaterializationPhase() &&
 1519   assert(Q && "Query can not be null");
 1537       assert(!QueryComplete && "query complete but unresolved symbols remain?");
 1545         assert(NewDefs->empty() &&
 1555   assert((MUs.empty() || !QueryComplete) &&
 1604       assert(SymI->second.getAddress() == 0 &&
 1607       assert(UMII != UnmaterializedInfos.end() &&
 1610       assert(MU != nullptr && "Materializer should not be null");
 1616         assert(SymK != Symbols.end() && "Missing symbol table entry");
 1627     assert(SymI->second.isInMaterializationPhase() &&
 1665         assert(I != UnmaterializedInfos.end() &&
 1709   assert(I != PendingQueries.end() &&
 1747           assert(I->second.getState() == SymbolState::NeverSearched &&
 1769     assert(UMII != UnmaterializedInfos.end() &&
 1788     assert(MaterializingInfos.count(QuerySymbol) &&
 1842   assert(!getJITDylibByName(Name) && "JITDylib with that name already exists");
 1853   assert(!!Err && "Error should be in failure state");
 1960         assert(KV.first && "JITDylibList entries must not be null");
 1961         assert(!CollectedMUsMap.count(KV.first) &&
 2086     assert(ResultMap->size() == 1 && "Unexpected number of results");
 2087     assert(ResultMap->count(Name) && "Missing result for symbol");
 2131       assert(JITDylibAndMU.second && "JITDylib, but no MU?");
lib/ExecutionEngine/Orc/ExecutionUtils.cpp
   29   assert(InitList == Other.InitList && "Incomparable iterators.");
   50   assert(CS && "Unrecognized type in llvm.global_ctors/llvm.global_dtors");
   99     assert(CtorDtor.Func && CtorDtor.Func->hasName() &&
  127       assert(Added && "Ctor/Dtor names clashed");
  136         assert(CtorDtorMap->count(Name) && "No entry for Name");
lib/ExecutionEngine/Orc/IRCompileLayer.cpp
   25   assert(TSM && "Module must not be null");
lib/ExecutionEngine/Orc/IRTransformLayer.cpp
   22   assert(TSM && "Module must not be null");
lib/ExecutionEngine/Orc/IndirectionUtils.cpp
  238   assert(F.isDeclaration() && "Can't turn a definition into a stub.");
  239   assert(F.getParent() && "Function isn't in a module.");
  307   assert(!OrigF.isDeclaration() && "Nothing to move");
  311     assert(VMap[&OrigF] == NewF && "Incorrect function mapping in VMap.");
  312   assert(NewF && "Function mapping missing from VMap.");
  313   assert(NewF->getParent() != OrigF.getParent() &&
  339   assert(OrigGV.hasInitializer() && "Nothing to move");
  343     assert(VMap[&OrigGV] == NewGV &&
  345   assert(NewGV->getParent() != OrigGV.getParent() &&
  355   assert(OrigA.getAliasee() && "Original alias doesn't have an aliasee?");
lib/ExecutionEngine/Orc/LLJIT.cpp
   42   assert(TSM && "Can not add null module");
   52   assert(Obj && "Can not add null object");
  177   assert(TSM && "Can not add null module");
lib/ExecutionEngine/Orc/Layer.cpp
   30   assert(this->TSM && "Module must not be null");
   66   assert(I != SymbolToDefinition.end() &&
   68   assert(!I->second->isDeclaration() &&
lib/ExecutionEngine/Orc/LazyReexports.cpp
  147     assert(I != CallableAliases.end() && "Symbol not found in alias map?");
  193   assert(CallableAliases.count(Name) &&
  202     assert(KV.second.AliasFlags.isCallable() &&
lib/ExecutionEngine/Orc/NullResolver.cpp
   23   assert(Symbols.empty() && "Null resolver: Symbols must be empty");
lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp
  103           assert(!ExtraSymbolsToClaim.count(InternedName) &&
  121           assert(!ExtraSymbolsToClaim.count(InternedName) &&
  216           assert(TargetSym.isDefined() &&
  256             assert(TargetSym.isDefined() &&
  331   assert(O && "Object must not be null");
  380   assert(Alloc && "No allocation for key K");
  418   assert(!InProcessLinks.count(&MR) && "Link for MR already being tracked?");
  436   assert(EHFrameRange.Addr &&
  454   assert(EHFrameRange.Addr && "Tracked eh-frame range must not be null");
  476     assert(EHFrameRange.Addr && "Untracked eh-frame range must not be null");
lib/ExecutionEngine/Orc/ObjectTransformLayer.cpp
   22   assert(O && "Module must not be null");
lib/ExecutionEngine/Orc/OrcCBindingsStack.h
  218               assert(ResolverI != Resolvers.end() &&
  388     assert(KeyLayers.count(K) && "looking up symbol in unknown module");
  476           assert(ResolverI != Resolvers.end() && "No resolver for module K");
  481           assert(!Resolvers.count(K) && "Resolver already present");
lib/ExecutionEngine/Orc/OrcMCJITReplacement.cpp
   28   assert(F && "Function *F was null at entry to run()");
   31   assert(FPtr && "Pointer to fn's code was null after getPointerToFunction");
   35   assert((FTy->getNumParams() == ArgValues.size() ||
   38   assert(FTy->getNumParams() == ArgValues.size() &&
lib/ExecutionEngine/Orc/OrcMCJITReplacement.h
  264       assert(M->getDataLayout() == getDataLayout() && "DataLayout Mismatch");
lib/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.cpp
   82   assert(O && "Object must not be null");
lib/ExecutionEngine/Orc/SpeculateAnalyses.cpp
   54   assert(BB != nullptr && "Traversing Null BB to find calls?");
  107   assert(IBBs.size() == BBFreqs.size() && "BB Count Mismatch");
  121   assert(!Calles.empty() && "Running Analysis on Function with no calls?");
  144   assert(RearrangedBBSet.size() == BBList.size() &&
lib/ExecutionEngine/Orc/Speculation.cpp
   29   assert(SrcJD && "Tracking on Null Source .impl dylib");
   34     assert(It.second && "ImplSymbols are already tracked for this Symbol?");
   41   assert(Ptr && " Null Address Received in orc_speculate_for ");
   64   assert(TSM && "Speculation Layer received Null Module ?");
   65   assert(TSM.getContext().getContext() != nullptr &&
  109           assert(SpeculateDecisionBlock == &Fn.getEntryBlock() &&
  130           assert(Mutator.GetInsertBlock()->getParent() == &Fn &&
  139   assert(!TSM.withModuleDo([](const Module &M) { return verifyModule(M); }) &&
lib/ExecutionEngine/Orc/ThreadSafeModule.cpp
   21   assert(TSM && "Can not clone null module");
lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
  477   assert(isa<MachOObjectFile>(Obj));
  495   assert(isa<MachOObjectFile>(Obj));
 1089         assert(RRI != ExternalSymbolMap.end() && "No result for symbol");
 1175       assert(NewResolverResults->size() == NewSymbols.size() &&
 1179         assert(!ResolvedSymbols.count(RRKV.first) && "Redundant resolution?");
 1226     assert(!Name.empty() && "Symbol has no name?");
 1227     assert(!SharedThis->GlobalSymbolTable.count(Name) &&
 1342   assert(Dyld && "No RuntimeDyld instance attached");
 1385   assert(Dyld && "No Dyld instance attached");
 1390   assert(Dyld && "No Dyld instance attached");
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldChecker.cpp
  147     assert(R.hasError() && "Not an error result.");
  481     assert(Expr.startswith("(") && "Not a parenthesized expression");
  500     assert(Expr.startswith("*") && "Not a load expression");
  591     assert(RemainingExpr.startswith("[") && "Not a slice expr.");
  764   assert(PtrSizedAddr == SrcAddr && "Linker memory pointer out-of-range.");
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
  188   assert(Obj.isELF() && "Not an ELF object file.");
  286     assert((Type == ELF::R_X86_64_32 && (Value <= UINT32_MAX)) ||
  299     assert(isInt<8>(RealOffset));
  307     assert(isInt<32>(RealOffset));
  331     assert(GOTBase != 0 && "missing GOT");
  389     assert(static_cast<int64_t>(Result) >= INT16_MIN && Result < UINT16_MAX);
  395     assert(static_cast<int64_t>(Result) >= INT32_MIN && Result < UINT32_MAX);
  404     assert(static_cast<int64_t>(Result) >= INT32_MIN &&
  419     assert(isInt<28>(BranchImm));
  441     assert(isInt<33>(Result) && "overflow check failed for relocation");
  537     assert((support::ulittle32_t::ref{TargetPtr} & 0xFFFFFF) == 0xFFFFFE);
  665       assert(TSI != Obj.section_end() && "TSI should refer to a valid section");
  772     assert(((Value + Addend) & 3) == 0);
  836     assert(int16_t(Delta / 2) * 2 == Delta && "R_390_PC16DBL overflow");
  843     assert(int32_t(Delta / 2) * 2 == Delta && "R_390_PC32DBL overflow");
  849     assert(int16_t(Delta) == Delta && "R_390_PC16 overflow");
  855     assert(int32_t(Delta) == Delta && "R_390_PC32 overflow");
  898     assert(Value <= UINT32_MAX);
 1886           assert (i != SectionMap.end());
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
   91     assert(OffsetBytes <= AllocationSize && "Offset out of bounds!");
  102     assert(OffsetBytes <= AllocationSize && "Offset out of bounds!");
  110     assert(StubOffset <= AllocationSize && "Not enough space allocated!");
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
   75   assert(TargetSI != Obj.section_end() && "Can't find section for symbol");
  184   assert(!Obj.is64Bit() &&
  195   assert((PTSectionSize % PTEntrySize) == 0 &&
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFI386.h
  146       assert(Result <= UINT32_MAX && "relocation overflow");
  161       assert(Result <= UINT32_MAX && "relocation overflow");
  176       assert(static_cast<int64_t>(Result) <= INT32_MAX &&
  178       assert(static_cast<int64_t>(Result) >= INT32_MIN &&
  190       assert(static_cast<uint32_t>(RE.SectionID) <= UINT16_MAX &&
  199       assert(static_cast<uint64_t>(RE.Addend) <= UINT32_MAX &&
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFThumb.h
  191       assert(Result <= UINT32_MAX && "relocation overflow");
  205       assert(Result <= UINT32_MAX && "relocation overflow");
  217       assert(static_cast<uint32_t>(RE.SectionID) <= UINT16_MAX &&
  226       assert(static_cast<uint64_t>(RE.Addend) <= UINT32_MAX &&
  237       assert(Result <= UINT32_MAX && "relocation overflow");
  266       assert(static_cast<int64_t>(RE.Addend) <= INT32_MAX &&
  268       assert(static_cast<int64_t>(RE.Addend) >= INT32_MIN &&
  281       assert(static_cast<int64_t>(RE.Addend) <= INT32_MAX &&
  283       assert(static_cast<int64_t>(RE.Addend) >= INT32_MIN &&
  296       assert(static_cast<int64_t>(RE.Addend) <= INT32_MAX &&
  298       assert(static_cast<int64_t>(RE.Addend) >= INT32_MIN &&
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFX86_64.h
   52     assert(Result <= UINT32_MAX && "Relocation overflow");
  104       assert(((int64_t)Result <= INT32_MAX) && "Relocation overflow");
  105       assert(((int64_t)Result >= INT32_MIN) && "Relocation underflow");
  131       assert(static_cast<int64_t>(RE.Addend) <= INT32_MAX && "Relocation overflow");
  132       assert(static_cast<int64_t>(RE.Addend) >= INT32_MIN && "Relocation underflow");
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldELFMips.cpp
  162       assert(GOTEntry == Value &&
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOAArch64.h
   70       assert(NumBytes == 4 && "Invalid relocation size.");
   71       assert((((uintptr_t)LocalAddress & 0x3) == 0) &&
   90       assert(((*p & 0xFC000000) == 0x14000000 ||
  105       assert((*p & 0x9F000000) == 0x90000000 && "Expected adrp instruction.");
  119       assert((*p & 0x3B000000) == 0x39000000 &&
  127       assert((((*p & 0x3B000000) == 0x39000000) ||
  163       assert((NumBytes == 4 || NumBytes == 8) && "Invalid relocation size.");
  170       assert(NumBytes == 4 && "Invalid relocation size.");
  171       assert((((uintptr_t)LocalAddress & 0x3) == 0) &&
  190       assert(((*p & 0xFC000000) == 0x14000000 ||
  195       assert((Addend & 0x3) == 0 && "Branch target is not aligned");
  196       assert(isInt<28>(Addend) && "Branch target is out of range.");
  206       assert((*p & 0x9F000000) == 0x90000000 && "Expected adrp instruction.");
  209       assert((Addend & 0xFFF) == 0 && "ADRP target is not page aligned.");
  210       assert(isInt<33>(Addend) && "Invalid page reloc value.");
  222       assert((*p & 0x3B000000) == 0x39000000 &&
  231       assert((((*p & 0x3B000000) == 0x39000000) ||
  246             assert(((Addend & 0xF) == 0) &&
  251           assert(((Addend & 0x1) == 0) && "16-bit LDR/STR not 2-byte aligned.");
  254           assert(((Addend & 0x3) == 0) && "32-bit LDR/STR not 4-byte aligned.");
  257           assert(((Addend & 0x7) == 0) && "64-bit LDR/STR not 8-byte aligned.");
  263       assert(isUInt<12>(Addend) && "Addend cannot be encoded.");
  292       assert(!Obj.getPlainRelocationExternal(RelInfo));
  293       assert(!Obj.getAnyRelocationPCRel(RelInfo));
  294       assert(Obj.getAnyRelocationLength(RelInfo) == 2);
  321     assert((ExplicitAddend == 0 || RE.Addend == 0) && "Relocation has "\
  367       assert(!RE.IsPCRel && "PCRel and ARM64_RELOC_UNSIGNED not supported");
  378       assert(((RE.Size == 2 && RE.IsPCRel) || (RE.Size == 3 && !RE.IsPCRel)) &&
  390       assert(RE.IsPCRel && "not PCRel and ARM64_RELOC_BRANCH26 not supported");
  399       assert(RE.IsPCRel && "not PCRel and ARM64_RELOC_PAGE21 not supported");
  409       assert(!RE.IsPCRel && "PCRel and ARM64_RELOC_PAGEOFF21 not supported");
  420       assert((Value == SectionABase || Value == SectionBBase) &&
  444     assert((RE.RelType == MachO::ARM64_RELOC_POINTER_TO_GOT &&
  462       assert(((StubAddress % getStubAlignment()) == 0) &&
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOARM.h
  222       assert((HighInsn & 0xf800) == 0xf000 &&
  227       assert((LowInsn & 0xf800) == 0xf800 &&
  262       assert((Value == SectionABase || Value == SectionBBase) &&
  317       assert(Section.getStubOffset() % 4 == 0 && "Misaligned stub");
  380     assert(SAI != MachO.section_end() && "Can't find section for address A");
  394     assert(SBI != MachO.section_end() && "Can't find section for address B");
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOI386.h
  117       assert((Value == SectionABase || Value == SectionBBase) &&
  169     assert(SAI != Obj.section_end() && "Can't find section for address A");
  183     assert(SBI != Obj.section_end() && "Can't find section for address B");
lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldMachOX86_64.h
   47     assert(!Obj.isRelocationScattered(RelInfo) &&
  114       assert((Value == SectionABase || Value == SectionBBase) &&
  132     assert(RE.IsPCRel);
  133     assert(RE.Size == 2);
lib/ExecutionEngine/SectionMemoryManager.cpp
   47   assert(!(Alignment & (Alignment - 1)) && "Alignment must be a power of two.");
  187   assert(((uintptr_t)Trimmed.base() % PageSize) == 0);
  188   assert((Trimmed.allocatedSize() % PageSize) == 0);
  189   assert(M.base() <= Trimmed.base() &&
lib/ExecutionEngine/TargetSelect.cpp
  101   assert(Target && "Could not allocate target machine!");
lib/FuzzMutate/IRMutator.cpp
  173   assert(!Inst.isTerminator() && "Deleting terminators invalidates CFG");
lib/FuzzMutate/Operations.cpp
  183   assert(T->isAggregateType() && "Not a struct or array");
lib/FuzzMutate/RandomIRBuilder.cpp
   54       assert(IP != BB.end() && "guaranteed by the findPointer");
   66   assert(!RS.isEmpty() && "Failed to generate sources");
lib/IR/AbstractCallSite.cpp
  102   assert(CallbackEncMD->getNumOperands() >= 2 && "Incomplete !callback metadata");
  109     assert(OpAsCM->getType()->isIntegerTy(64) &&
  113     assert(-1 <= Idx && Idx <= NumCallOperands &&
  125   assert(VarArgFlagAsCM->getType()->isIntegerTy(1) &&
lib/IR/AsmWriter.cpp
  239   assert(List.size() == Stack.back().Shuffle.size() && "Wrong size");
  247   assert(IDPair.first && "Unmapped value");
  400   assert(!Name.empty() && "Cannot get empty name!");
  515     assert(P.second < NumberedTypes.size() && "Didn't get a dense numbering?");
  516     assert(!NumberedTypes[P.second] && "Didn't get a unique numbering?");
  860   assert(F && "No function incorporated");
 1021   assert(TheIndex);
 1116   assert(!isa<Constant>(V) && "Can't get a constant or global slot with this!");
 1163   assert(V && "Can't insert a null Value into SlotTracker!");
 1164   assert(!V->getType()->isVoidTy() && "Doesn't need a slot!");
 1165   assert(!V->hasName() && "Doesn't need a slot!");
 1181   assert(!V->getType()->isVoidTy() && !V->hasName() && "Doesn't need a slot!");
 1193   assert(N && "Can't insert a null Value into SlotTracker!");
 1211   assert(AS.hasAttributes() && "Doesn't need a slot!");
 1323         assert(((StrVal[0] >= '0' && StrVal[0] <= '9') ||
 1708     assert(!StringF.empty() && "Expected valid flag");
 1732     assert(!StringF.empty() && "Expected valid flag");
 2144       assert(!OpStr.empty() && "Expected valid opcode");
 2236     assert(TypePrinter && "Constants require TypePrinting!");
 2342   assert(TypePrinter && "TypePrinter required for metadata values");
 2343   assert((FromValue || !isa<LocalAsMetadata>(V)) &&
 2513   assert(SuccessOrdering != AtomicOrdering::NotAtomic &&
 2649   assert(UseListOrders.empty() && "All use-lists should have been consumed");
 2671   assert(TheIndex);
 3002         assert(Slot != -1);
 3044     assert(Slot != -1);
 3560     assert(Slot != -1 && "expect argument in function here");
 4161   assert(Order.Shuffle.size() >= 2 && "Shuffle too small");
lib/IR/AttributeImpl.h
  137     assert((Kind == Attribute::Alignment || Kind == Attribute::StackAlignment ||
lib/IR/Attributes.cpp
   61   assert((!NumElemsArg.hasValue() ||
  146   assert(A <= 0x40000000 && "Alignment too large.");
  151   assert(A <= 0x100 && "Alignment too large.");
  157   assert(Bytes && "Bytes must be non-zero.");
  163   assert(Bytes && "Bytes must be non-zero.");
  174   assert(!(ElemSizeArg == 0 && NumElemsArg && *NumElemsArg == 0) &&
  201   assert((isEnumAttribute() || isIntAttribute() || isTypeAttribute()) &&
  208   assert(isIntAttribute() &&
  215   assert(isStringAttribute() &&
  222   assert(isStringAttribute() &&
  229   assert(isTypeAttribute() &&
  245   assert(hasAttribute(Attribute::Alignment) &&
  251   assert(hasAttribute(Attribute::StackAlignment) &&
  257   assert(hasAttribute(Attribute::Dereferenceable) &&
  264   assert(hasAttribute(Attribute::DereferenceableOrNull) &&
  271   assert(hasAttribute(Attribute::AllocSize) &&
  520   assert(isEnumAttribute() || isIntAttribute() || isTypeAttribute());
  525   assert(isIntAttribute());
  530   assert(isStringAttribute());
  535   assert(isStringAttribute());
  540   assert(isTypeAttribute());
  557       assert(getKindAsEnum() != AI.getKindAsEnum() &&
  576   assert(isStringAttribute());
  782       assert(B.getAlignment() && "Alignment must be set");
  786       assert(B.getStackAlignment() && "StackAlignment must be set");
  906   assert(!Sets.empty() && "pointless AttributeListImpl");
  947   assert(!AttrSets.empty() && "pointless AttributeListImpl");
  978   assert(std::is_sorted(Attrs.begin(), Attrs.end(),
  983   assert(llvm::none_of(Attrs,
 1014   assert(std::is_sorted(Attrs.begin(), Attrs.end(),
 1020   assert(llvm::none_of(Attrs,
 1168   assert((!OldAlign || !NewAlign || OldAlign == NewAlign) &&
 1187   assert(std::is_sorted(ArgNos.begin(), ArgNos.end()));
 1210   assert(Index < AttrSets.size());
 1223   assert(Index < AttrSets.size());
 1447   assert((unsigned)Val < Attribute::EndAttrKinds && "Attribute out of range!");
 1448   assert(Val != Attribute::Alignment && Val != Attribute::StackAlignment &&
 1485   assert((unsigned)Val < Attribute::EndAttrKinds && "Attribute out of range!");
 1524   assert(*Align <= 0x40000000 && "Alignment too large.");
 1536   assert(*Align <= 0x100 && "Alignment too large.");
 1567   assert(RawArgs && "Invalid allocsize arguments -- given allocsize(0, 0)");
 1667       assert(Attr.isStringAttribute() && "Invalid attribute kind!");
lib/IR/AutoUpgrade.cpp
  491   assert(F && "Illegal to upgrade a non-existent Function.");
  827   assert(F != NewFn && "Intrinsic function upgraded to the same function");
  992   assert((IsVALIGN || NumElts % 16 == 0) && "Illegal NumElts for PALIGNR!");
  993   assert((!IsVALIGN || NumElts <= 16) && "NumElts too large for VALIGN!");
  994   assert(isPowerOf2_32(NumElts) && "NumElts not a power of 2!");
 1652   assert(F && "Intrinsic call is not direct?");
 1658     assert(Name.startswith("llvm.") && "Intrinsic doesn't start with 'llvm.'");
 2090         assert(NumDstElts == 2 && "Unexpected vector size");
 3486     assert(
 3545     assert(CI->getNumArgOperands() == 1 &&
 3572     assert(CI->getNumArgOperands() == 4);
 3714   assert(NewCall && "Should have either set this variable or returned through "
 3726   assert(F && "Illegal attempt to upgrade a non-existent intrinsic.");
 4090   assert(OldTag.startswith(OldPrefix) && "Expected old prefix");
lib/IR/BasicBlock.cpp
   47     assert(!InsertBefore &&
   54   assert(NewParent && "Expected a parent");
   55   assert(!Parent && "Already has a parent");
   71     assert(!use_empty() && "There should be at least one blockaddress!");
   82   assert(getParent() == nullptr && "BasicBlock still linked into the program!");
  310   assert((hasNUsesOrMore(16)||// Reduce cost of this assertion for complex CFGs.
  331   assert(max_idx != 0 && "PHI Node in block with 0 predecessors!?!?!");
  397   assert(Term->getNumSuccessors() > 0);
  415   assert(getTerminator() && "Can't use splitBasicBlock on degenerate BB!");
  416   assert(I != InstList.end() &&
lib/IR/ConstantFold.cpp
   81   assert(Op && Op->isCast() && "Can't fold cast of cast without a cast!");
   82   assert(DstTy && DstTy->isFirstClassType() && "Invalid cast destination type");
   83   assert(CastInst::isCast(opc) && "Invalid cast opcode");
  141       assert(DestPTy->getBitWidth() == SrcTy->getBitWidth() &&
  214   assert(C->getType()->isIntegerTy() &&
  218   assert(ByteSize && "Must be accessing some piece");
  219   assert(ByteStart+ByteSize <= CSize && "Extracting invalid piece from input");
  220   assert(ByteSize != CSize && "Should not extract everything");
  334       assert((SrcBitSize&7) && "Shouldn't get byte sized case here");
  942   assert(Instruction::isUnaryOp(Opcode) && "Non-unary instruction detected");
  957   assert(!HasScalarUndef && "Unexpected UndefValue");
  959   assert(!isa<ConstantInt>(C) && "Unexpected Integer UnaryOp");
  989   assert(Instruction::isBinaryOp(Opcode) && "Non-binary instruction detected");
 1097   assert(!HasScalarUndef && "Unexpected UndefValue");
 1198           assert(CI2->isOne());
 1233         assert(!CI2->isZero() && "Div by zero handled above");
 1236         assert(!CI2->isZero() && "Div by zero handled above");
 1241         assert(!CI2->isZero() && "Div by zero handled above");
 1244         assert(!CI2->isZero() && "Div by zero handled above");
 1447   assert(V1->getType() == V2->getType() &&
 1537   assert(V1->getType() == V2->getType() &&
 1588       assert(isa<ConstantPointerNull>(V2) && "Canonicalization guarantee!");
 1619       assert((isa<ConstantPointerNull>(V2) || isa<GlobalValue>(V2)) &&
 1700             assert(CE1->getNumOperands() == 2 &&
 2195       assert(Ty && "Invalid indices for GEP!");
lib/IR/ConstantRange.cpp
   51   assert(Lower.getBitWidth() == Upper.getBitWidth() &&
   53   assert((Lower != Upper || (Lower.isMaxValue() || Lower.isMinValue())) &&
   59   assert(!Known.hasConflict() && "Expected valid KnownBits");
  145   assert(makeAllowedICmpRegion(Pred, C) == makeSatisfyingICmpRegion(Pred, C));
  177   assert((!Success || ConstantRange::makeExactICmpRegion(Pred, RHS) == *this) &&
  230   assert(Instruction::isBinaryOp(BinOp) && "Binary operators only!");
  232   assert((NoWrapKind == OBO::NoSignedWrap ||
  330   assert(getBitWidth() == Other.getBitWidth());
  340   assert(MaxSize && "MaxSize can't be 0.");
  416   assert(Val.getBitWidth() == getBitWidth() && "Wrong bit width");
  449   assert(getBitWidth() == CR.getBitWidth() &&
  555   assert(getBitWidth() == CR.getBitWidth() &&
  610     assert(CR.Lower.ule(Upper) && CR.Upper.ult(Lower) &&
  673   assert(SrcTySize < DstTySize && "Not a value extension");
  690   assert(SrcTySize < DstTySize && "Not a value extension");
  705   assert(getBitWidth() > DstTySize && "Not a value truncation");
  778   assert(Instruction::isBinaryOp(BinOp) && "Binary operators only!");
  822   assert(Instruction::isBinaryOp(BinOp) && "Binary operators only!");
 1496   assert(NumRanges >= 1 && "Must have at least one range!");
 1497   assert(Ranges.getNumOperands() % 2 == 0 && "Must be a sequence of pairs");
lib/IR/Constants.cpp
  376   assert(isa<IntegerType>(Elt->getType()) && "Index must be an integer");
  415     assert(isa<Constant>(V) && "References remain to Constant being destroyed");
  419     assert((use_empty() || user_back() != V) && "Constant not removed!");
  428   assert(C->getType()->isFirstClassType() && "Cannot evaluate aggregate vals!");
  606   assert(V.getBitWidth() == Ty->getBitWidth() && "Invalid constant for type");
  624   assert(Ty->isIntOrIntVectorTy(1) && "Type not i1 or vector of i1.");
  632   assert(Ty->isIntOrIntVectorTy(1) && "Type not i1 or vector of i1.");
  649   assert(Slot->getType() == IntegerType::get(Context, V.getBitWidth()));
  677   assert(C->getType() == Ty->getScalarType() &&
  712   assert(Ty->isPPC_FP128Ty() && "Unknown FP format");
  734   assert(C->getType() == Ty->getScalarType() &&
  829       assert(&V.getSemantics() == &APFloat::PPCDoubleDouble() &&
  851   assert(&V.getSemantics() == TypeToFloatSemantics(Ty) &&
  942   assert(!V.empty() && "Cannot get empty int sequence.");
  955   assert(!V.empty() && "Cannot get empty FP sequence.");
 1004     assert(V[I]->getType() == T->getTypeAtIndex(I) &&
 1010   assert(V.size() == T->getNumElements() &&
 1026     assert(V[i]->getType() == Ty->getElementType() &&
 1063   assert(!V.empty() &&
 1070   assert((T->isOpaque() || V.size() == T->getNumElements()) &&
 1076   assert((ST->isOpaque() || ST->getNumElements() == V.size()) &&
 1105   assert(V.size() == T->getNumElements() &&
 1118   assert(!V.empty() && "Vectors can't be empty");
 1225   assert(Op->getType() == getOperand(OpNo)->getType() &&
 1239   assert(Ops.size() == getNumOperands() && "Operand count mismatch!");
 1278     assert(SrcTy || (Ops[0]->getType() == getOperand(0)->getType()));
 1288     assert(getNumOperands() == 2 && "Must be binary operator?");
 1364   assert((Ty->isStructTy() || Ty->isArrayTy() || Ty->isVectorTy()) &&
 1400   assert(this->getType()->isVectorTy() && "Only valid for vectors!");
 1423   assert(this->getSplatValue() && "Doesn't contain a unique integer!");
 1425   assert(C && isa<ConstantInt>(C) && "Not a vector of numbers!");
 1461   assert(BB->getParent() && "Block must have a parent");
 1471   assert(BA->getFunction() == F && "Basic block moved between functions");
 1488   assert(F && "Block must have a parent");
 1491   assert(BA && "Refcount and block address map disagree!");
 1511     assert(From == NewBB && "From does not match any operand");
 1545   assert(Ty->isFirstClassType() && "Cannot cast to an aggregate type!");
 1564   assert(Instruction::isCast(opc) && "opcode out of range");
 1565   assert(C && Ty && "Null arguments to getCast");
 1566   assert(CastInst::castIsValid(opc, C, Ty) && "Invalid constantexpr cast!");
 1619   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 1620   assert((Ty->isIntOrIntVectorTy() || Ty->isPtrOrPtrVectorTy()) &&
 1635   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 1636   assert(Ty->isPtrOrPtrVectorTy() && "Invalid cast");
 1645   assert(C->getType()->isIntOrIntVectorTy() &&
 1657   assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
 1673   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1674   assert(C->getType()->isIntOrIntVectorTy() && "Trunc operand must be integer");
 1675   assert(Ty->isIntOrIntVectorTy() && "Trunc produces only integral");
 1676   assert(C->getType()->getScalarSizeInBits() > Ty->getScalarSizeInBits()&&
 1687   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1688   assert(C->getType()->isIntOrIntVectorTy() && "SExt operand must be integral");
 1689   assert(Ty->isIntOrIntVectorTy() && "SExt produces only integer");
 1690   assert(C->getType()->getScalarSizeInBits() < Ty->getScalarSizeInBits()&&
 1701   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1702   assert(C->getType()->isIntOrIntVectorTy() && "ZEXt operand must be integral");
 1703   assert(Ty->isIntOrIntVectorTy() && "ZExt produces only integer");
 1704   assert(C->getType()->getScalarSizeInBits() < Ty->getScalarSizeInBits()&&
 1715   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1716   assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
 1727   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1728   assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
 1739   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1740   assert(C->getType()->isIntOrIntVectorTy() && Ty->isFPOrFPVectorTy() &&
 1750   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1751   assert(C->getType()->isIntOrIntVectorTy() && Ty->isFPOrFPVectorTy() &&
 1761   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1762   assert(C->getType()->isFPOrFPVectorTy() && Ty->isIntOrIntVectorTy() &&
 1772   assert((fromVec == toVec) && "Cannot convert from scalar to/from vector");
 1773   assert(C->getType()->isFPOrFPVectorTy() && Ty->isIntOrIntVectorTy() &&
 1780   assert(C->getType()->isPtrOrPtrVectorTy() &&
 1782   assert(DstTy->isIntOrIntVectorTy() &&
 1784   assert(isa<VectorType>(C->getType()) == isa<VectorType>(DstTy));
 1786     assert(C->getType()->getVectorNumElements()==DstTy->getVectorNumElements()&&
 1793   assert(C->getType()->isIntOrIntVectorTy() &&
 1795   assert(DstTy->isPtrOrPtrVectorTy() &&
 1797   assert(isa<VectorType>(C->getType()) == isa<VectorType>(DstTy));
 1799     assert(C->getType()->getVectorNumElements()==DstTy->getVectorNumElements()&&
 1806   assert(CastInst::castIsValid(Instruction::BitCast, C, DstTy) &&
 1818   assert(CastInst::castIsValid(Instruction::AddrSpaceCast, C, DstTy) &&
 1840   assert(Instruction::isUnaryOp(Opcode) &&
 1846     assert(C->getType()->isFPOrFPVectorTy() &&
 1871   assert(Instruction::isBinaryOp(Opcode) &&
 1873   assert(C1->getType() == C2->getType() &&
 1885     assert(C1->getType()->isIntOrIntVectorTy() &&
 1893     assert(C1->getType()->isFPOrFPVectorTy() &&
 1900     assert(C1->getType()->isIntOrIntVectorTy() &&
 1906     assert(C1->getType()->isIntOrIntVectorTy() &&
 1970   assert(C1->getType() == C2->getType() && "Op types should be identical!");
 1992   assert(!SelectInst::areInvalidOperands(C, V1, V2)&&"Invalid select operands");
 2014     assert(Ty ==
 2023   assert(DestTy && "GEP indices invalid!");
 2045     assert((!Idxs[i]->getType()->isVectorTy() ||
 2067   assert(LHS->getType() == RHS->getType());
 2068   assert(CmpInst::isIntPredicate((CmpInst::Predicate)pred) &&
 2092   assert(LHS->getType() == RHS->getType());
 2093   assert(CmpInst::isFPPredicate((CmpInst::Predicate)pred) &&
 2117   assert(Val->getType()->isVectorTy() &&
 2119   assert(Idx->getType()->isIntegerTy() &&
 2139   assert(Val->getType()->isVectorTy() &&
 2141   assert(Elt->getType() == Val->getType()->getVectorElementType() &&
 2143   assert(Idx->getType()->isIntegerTy() &&
 2162   assert(ShuffleVectorInst::isValidOperands(V1, V2, Mask) &&
 2186   assert(Agg->getType()->isFirstClassType() &&
 2189   assert(ExtractValueInst::getIndexedType(Agg->getType(),
 2209   assert(Agg->getType()->isFirstClassType() &&
 2214   assert(ReqTy && "extractvalue indices invalid!");
 2216   assert(Agg->getType()->isFirstClassType() &&
 2232   assert(C->getType()->isIntOrIntVectorTy() &&
 2239   assert(C->getType()->isFPOrFPVectorTy() &&
 2245   assert(C->getType()->isIntOrIntVectorTy() &&
 2340   assert(Instruction::isBinaryOp(Opcode) && "Only binops allowed");
 2469   assert(Elt < getNumElements() && "Invalid Elt");
 2487   assert(isElementTypeCompatible(Ty->getSequentialElementType()));
 2514   assert(isa<VectorType>(Ty));
 2526   assert(Slot != CDSConstants.end() && "CDS not found in uniquing table");
 2534     assert((*Entry) == this && "Hash mismatch in ConstantDataSequential");
 2541       assert(Node && "Didn't find entry in its uniquing hash table!");
 2651   assert(isElementTypeCompatible(V->getType()) &&
 2666     assert(CI->getType()->isIntegerTy(64) && "Unsupported ConstantData type");
 2693   assert(isa<IntegerType>(getElementType()) &&
 2713   assert(isa<IntegerType>(getElementType()) &&
 2762   assert(getElementType()->isFloatTy() &&
 2768   assert(getElementType()->isDoubleTy() &&
 2847   assert(Replacement != this && "I didn't contain From!");
 2857   assert(isa<Constant>(To) && "Cannot make Constant refer to non-constant!");
 2898   assert(isa<Constant>(To) && "Cannot make Constant refer to non-constant!");
 2934   assert(isa<Constant>(To) && "Cannot make Constant refer to non-constant!");
 2960   assert(isa<Constant>(ToV) && "Cannot make Constant refer to non-constant!");
 2975   assert(NumUpdated && "I didn't contain From!");
 3033     assert(getNumOperands() == 2 && "Must be binary operator?");
lib/IR/ConstantsContext.h
  382     assert(Storage.empty() && "Expected empty storage");
  456     assert(PointerType::getUnqual(FTy) == Ty);
  493     assert(Storage.empty() && "Expected empty storage");
  640     assert(Result->getType() == Ty && "Type specified is not correct!");
  660     assert(Result && "Unexpected nullptr");
  668     assert(I != Map.end() && "Constant not found in constant table!");
  669     assert(*I == CP && "Didn't find correct element?");
  689       assert(OperandNo < CP->getNumOperands() && "Invalid index");
  690       assert(CP->getOperand(OperandNo) != To && "I didn't contain From!");
lib/IR/Core.cpp
  865   assert(I && "Expected instruction");
  876   assert((isa<MDNode>(MD) || isa<ConstantAsMetadata>(MD)) &&
  987       assert(Index == 0 && "Function-local metadata can only have one operand");
 1082       assert(!isa<LocalAsMetadata>(MD) && "Unexpected function-local metadata "
 1086       assert(Count == 1 &&
 1235     assert(0 && "Expected Instruction, GlobalVariable or Function");
 1259     assert(0 && "Expected Instruction, GlobalVariable or Function");
 1282     assert(0 && "Expected Instruction, GlobalVariable or Function");
 2319   assert(ID < llvm::Intrinsic::num_intrinsics && "Intrinsic ID out of range");
 2641   assert(CurBB && "current insertion point is invalid!");
lib/IR/DIBuilder.cpp
   44   assert(AllowUnresolvedNodes && "Cannot handle unresolved nodes");
   70     assert(!AllowUnresolvedNodes &&
  144   assert(((Lang <= dwarf::DW_LANG_Fortran08 && Lang >= dwarf::DW_LANG_C89) ||
  148   assert(!CUNode && "Can only make one compile unit per DIBuilder instance");
  167     assert(File && "Source location has line number but no file");
  222   assert(!Name.empty() && "Unable to create macro without name");
  223   assert((MacroType == dwarf::DW_MACINFO_undef ||
  246   assert(!Name.empty() && "Unable to create enumerator without name");
  251   assert(!Name.empty() && "Unable to create type without name");
  262   assert(!Name.empty() && "Unable to create type without name");
  300   assert(RTy && "Unable to create reference type");
  315   assert(Ty && "Invalid type!");
  316   assert(FriendTy && "Invalid friend type!");
  325   assert(Ty && "Unable to create inheritance");
  407   assert((!Context || isa<DICompileUnit>(Context)) && "Expected compile unit");
  415   assert((!Context || isa<DICompileUnit>(Context)) && "Expected compile unit");
  448   assert((!Context || isa<DIScope>(Context)) &&
  564   assert(T && "Expected non-null type");
  565   assert((isa<DIType>(T) || (isa<DISubprogram>(T) &&
  634     assert(CT->getIdentifier().empty() &&
  689     assert(Fn && "Missing subprogram for local variable");
  708   assert(ArgNo && "Expected non-zero argument number for parameter");
  728     assert(Fn && "Missing subprogram for label");
  791   assert(getNonCompileUnitScope(Context) &&
  910   assert(V && "no value passed to dbg intrinsic");
  922   assert(VarInfo && "empty or invalid DILocalVariable* passed to dbg.declare");
  923   assert(DL && "Expected debug loc");
  924   assert(DL->getScope()->getSubprogram() ==
  943   assert(V && "no value passed to dbg.value");
  944   assert(VarInfo && "empty or invalid DILocalVariable* passed to dbg.value");
  945   assert(DL && "Expected debug loc");
  946   assert(DL->getScope()->getSubprogram() ==
  965   assert(LabelInfo && "empty or invalid DILabel* passed to dbg.label");
  966   assert(DL && "Expected debug loc");
  967   assert(DL->getScope()->getSubprogram() ==
lib/IR/DataLayout.cpp
   47   assert(!ST->isOpaque() && "Cannot get layout of opaque structs");
   83   assert(SI != &MemberOffsets[0] && "Offset not in structure type!");
   85   assert(*SI <= Offset && "upper_bound didn't work");
   86   assert((SI == &MemberOffsets[0] || *(SI-1) <= Offset) &&
  104   assert(abi_align <= pref_align && "Preferred alignment worse than ABI!");
  128   assert(ABIAlign <= PrefAlign && "Preferred alignment worse than ABI!");
  199   assert(!Str.empty() && "parse error, string can't be empty here");
  491   assert(Log2(abi_align) < 16 && Log2(pref_align) < 16 && "Alignment too big");
  640     assert(I->AddressSpace == 0);
  649     assert(I->AddressSpace == 0);
  658     assert(I->AddressSpace == 0);
  672   assert(Ty->isPtrOrPtrVectorTy() &&
  682     assert(I->AddressSpace == 0);
  688   assert(Ty->isPtrOrPtrVectorTy() &&
  705   assert(Ty->isSized() && "Cannot getTypeInfo() on a type that is unsized!");
  775   assert(Ty->isPtrOrPtrVectorTy() &&
  797   assert(Ty->isPtrOrPtrVectorTy() &&
  816       assert(Idx->getType()->isIntegerTy(32) && "Illegal struct idx");
lib/IR/DebugInfo.cpp
  282   assert(!N->operands().empty() && "Missing self reference?");
lib/IR/DebugInfoMetadata.cpp
   30   assert((MDs.size() == 1 || MDs.size() == 2) &&
   34   assert(Column < (1u << 16) && "Expected 16-bit column");
   63     assert(ShouldCreate && "Expected non-uniqued nodes to always be created");
  231   assert((isa<DIFile>(this) || isa<DICompileUnit>(this)) &&
  247   assert((isa<DILexicalBlockBase>(this) || isa<DIFile>(this) ||
  272     assert(ShouldCreate && "Expected non-uniqued nodes to always be created");
  276   assert(isCanonical(Header) && "Expected canonical MDString");
  335   assert(isCanonical(Name) && "Expected canonical MDString");
  346   assert(isCanonical(Name) && "Expected canonical MDString");
  373   assert(isCanonical(Name) && "Expected canonical MDString");
  391   assert(isCanonical(Name) && "Expected canonical MDString");
  412   assert(!Identifier.getString().empty() && "Expected valid identifier");
  423   assert(CT->getRawIdentifier() == &Identifier && "Wrong ODR identifier?");
  433   assert((std::end(Ops) - std::begin(Ops)) == (int)CT->getNumOperands() &&
  447   assert(!Identifier.getString().empty() && "Expected valid identifier");
  461   assert(!Identifier.getString().empty() && "Expected valid identifier");
  484   assert(CSKind <= DIFile::CSK_Last && "Invalid checksum kind");
  503   assert(isCanonical(Filename) && "Expected canonical MDString");
  504   assert(isCanonical(Directory) && "Expected canonical MDString");
  505   assert((!CS || isCanonical(CS->Value)) && "Expected canonical MDString");
  506   assert((!Source || isCanonical(*Source)) && "Expected canonical MDString");
  522   assert(Storage != Uniqued && "Cannot unique DICompileUnit");
  523   assert(isCanonical(Producer) && "Expected canonical MDString");
  524   assert(isCanonical(Flags) && "Expected canonical MDString");
  525   assert(isCanonical(SplitDebugFilename) && "Expected canonical MDString");
  634   assert(isCanonical(Name) && "Expected canonical MDString");
  635   assert(isCanonical(LinkageName) && "Expected canonical MDString");
  659   assert(F && "Invalid function");
  675   assert(Scope && "Expected scope");
  686   assert(Scope && "Expected scope");
  695   assert(isCanonical(Name) && "Expected canonical MDString");
  706   assert(isCanonical(Name) && "Expected canonical MDString");
  717   assert(isCanonical(Name) && "Expected canonical MDString");
  729   assert(isCanonical(Name) && "Expected canonical MDString");
  738   assert(isCanonical(Name) && "Expected canonical MDString");
  751   assert(isCanonical(Name) && "Expected canonical MDString");
  752   assert(isCanonical(LinkageName) && "Expected canonical MDString");
  777   assert(Arg <= UINT16_MAX && "Expected argument number to fit in 16-bits");
  779   assert(Scope && "Expected scope");
  780   assert(isCanonical(Name) && "Expected canonical MDString");
  815   assert(Scope && "Expected scope");
  816   assert(isCanonical(Name) && "Expected canonical MDString");
 1052   assert(Expr && "Can't prepend ops to this expression");
 1083   assert(Expr && !Ops.empty() && "Can't append ops to this expression");
 1105   assert(Expr && !Ops.empty() && "Can't append ops to this expression");
 1106   assert(none_of(Ops,
 1157         assert((OffsetInBits + SizeInBits <= FragmentSizeInBits) &&
 1166   assert(Expr && "Unknown DIExpression");
 1198   assert(isCanonical(Name) && "Expected canonical MDString");
 1199   assert(isCanonical(GetterName) && "Expected canonical MDString");
 1200   assert(isCanonical(SetterName) && "Expected canonical MDString");
 1212   assert(isCanonical(Name) && "Expected canonical MDString");
 1222   assert(isCanonical(Name) && "Expected canonical MDString");
lib/IR/DebugLoc.cpp
   26   assert(get() && "Expected valid DebugLoc");
   31   assert(get() && "Expected valid DebugLoc");
   36   assert(get() && "Expected valid DebugLoc");
   41   assert(get() && "Expected valid DebugLoc");
lib/IR/DiagnosticInfo.cpp
  249   assert(!Func->empty() && "Function does not have a body");
lib/IR/Dominators.cpp
   51   assert(NumEdgesToEnd == 1);
  345   assert(DT.verify());
  370     assert(DT.verify(DominatorTree::VerificationLevel::Full));
  372     assert(DT.verify(DominatorTree::VerificationLevel::Basic));
lib/IR/Function.cpp
  112   assert(getType()->isPointerTy() && "Only pointers have alignments");
  117   assert(getType()->isPointerTy() && "Only pointers have byval types");
  122   assert(getType()->isPointerTy() &&
  128   assert(getType()->isPointerTy() &&
  248   assert(FunctionType::isValidReturnType(getReturnType()) &&
  289       assert(!ArgTy->isVoidTy() && "Cannot have void typed arguments!");
  298   assert(!hasLazyArguments());
  315   assert(isDeclaration() && "Expected no references to current arguments");
  319     assert(llvm::all_of(makeArgArray(Arguments, NumArgs),
  331   assert(arg_size() == Src.arg_size());
  347   assert(!hasLazyArguments());
  479   assert(hasGC() && "Function has no collector");
  531   assert(Name.startswith("llvm."));
  561   assert(Name.size() >= MatchSize && "Expected either exact or prefix match");
  641   assert(id < num_intrinsics && "Invalid intrinsic ID!");
  642   assert(!isOverloaded(id) &&
  648   assert(id < num_intrinsics && "Invalid intrinsic ID!");
  992     assert(ITy->getBitWidth() % 2 == 0);
  999     assert(VTy && "Expected an argument of Vector Type");
 1034     assert(VTy && "Expected an argument of Vector Type");
 1181       assert(D.getArgumentNumber() == ArgTys.size() && !IsDeferredCheck &&
 1282         assert(D.getOverloadArgNumber() == ArgTys.size() &&
 1414   assert(NewDecl->getFunctionType() == FTy && "Shouldn't change the signature");
 1466   assert(hasPersonalityFn() && getNumOperands());
 1476   assert(hasPrefixData() && getNumOperands());
 1486   assert(hasPrologueData() && getNumOperands());
 1522   assert(Bit < 16 && "SubclassData contains only 16 bits");
 1531   assert(Count.hasValue());
 1534   assert(!PrevCount.hasValue() || PrevCount.getType() == Count.getType());
 1589     assert(cast<MDString>(MD->getOperand(0))
lib/IR/Globals.cpp
  121   assert((!Align || Align <= MaximumAlignment) &&
  126   assert(MaybeAlign(getAlignment()) == Align &&
  211   assert(hasSection());
  241   assert(isa<GlobalIndirectSymbol>(this));
  345   assert(!Ty->isFunctionTy() && PointerType::isValidElementType(Ty) &&
  349     assert(InitVal->getType() == Ty &&
  365   assert(!Ty->isFunctionTy() && PointerType::isValidElementType(Ty) &&
  369     assert(InitVal->getType() == Ty &&
  398     assert(InitVal->getType() == getValueType() &&
  523   assert((!Aliasee || Aliasee->getType() == getType()) &&
lib/IR/IRBuilder.cpp
   57   assert(BB && BB->getParent() && "No current function!");
  130   assert(Align >= ElementSize &&
  161   assert((DstAlign == 0 || isPowerOf2_32(DstAlign)) && "Must be 0 or a power of 2");
  162   assert((SrcAlign == 0 || isPowerOf2_32(SrcAlign)) && "Must be 0 or a power of 2");
  200   assert(DstAlign >= ElementSize &&
  202   assert(SrcAlign >= ElementSize &&
  241   assert((DstAlign == 0 || isPowerOf2_32(DstAlign)) && "Must be 0 or a power of 2");
  242   assert((SrcAlign == 0 || isPowerOf2_32(SrcAlign)) && "Must be 0 or a power of 2");
  276   assert(DstAlign >= ElementSize &&
  278   assert(SrcAlign >= ElementSize &&
  401   assert(isa<PointerType>(Ptr->getType()) &&
  407     assert(Size->getType() == getInt64Ty() &&
  417   assert(isa<PointerType>(Ptr->getType()) &&
  423     assert(Size->getType() == getInt64Ty() &&
  434   assert(isa<PointerType>(Ptr->getType()) &&
  440     assert(Size->getType() == getInt64Ty() &&
  453   assert(Cond->getType() == getInt1Ty() &&
  475   assert(DataTy->isVectorTy() && "Ptr should point to a vector");
  476   assert(Mask && "Mask should not be all-ones (null)");
  495   assert(DataTy->isVectorTy() && "Ptr should point to a vector");
  496   assert(Mask && "Mask should not be all-ones (null)");
  561   assert(NumElts == DataTy->getVectorNumElements() &&
  608   assert(isa<FunctionType>(FuncPtrType->getElementType()) &&
  659   assert(isa<FunctionType>(FuncPtrType->getElementType()) &&
lib/IR/InlineAsm.cpp
   38   assert(Verify(getFunctionType(), constraints) &&
  165         assert(scInfo.MatchingInput >= 0);
  173         assert(ConstraintsSoFar[N].MatchingInput >= 0);
  188       assert(isdigit(C) && "Expected a digit!");
  190       assert(N > 0 && "Found a zero letter constraint!");
lib/IR/Instruction.cpp
   30     assert(BB && "Instruction to insert before is not in a basic block!");
   40   assert(InsertAtEnd && "Basic block to append to may not be NULL!");
   45   assert(!Parent && "Instruction still linked in the program!");
   96   assert(I == BB.end() || I->getParent() == &BB);
  150   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  155   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  160   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  165   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  170   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  175   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  180   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  185   assert(isa<FPMathOperator>(this) && "setting fast-math flag on invalid op");
  190   assert(isa<FPMathOperator>(this) && "copying fast-math flag on invalid op");
  195   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  200   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  205   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  210   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  215   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  220   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  225   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  230   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  235   assert(isa<FPMathOperator>(this) && "getting fast-math flag on invalid op");
  381   assert(I1->getOpcode() == I2->getOpcode() &&
  569   assert(isAtomic());
  581   assert(isAtomic());
  748   assert(isa<CallBase>(this) &&
lib/IR/Instructions.cpp
  250   assert(OpNo < ReservedSpace && "Growing didn't work!");
  262   assert(getOpcode() == Instruction::CallBr && "Unexpected opcode!");
  334   assert(ArgNo < getNumArgOperands() && "Param index out of bounds!");
  367     assert(BI != Bundles.end() && "Incorrect allocation?");
  376   assert(BI == Bundles.end() && "Incorrect allocation?");
  388   assert(getNumOperands() == Args.size() + CountBundleInputs(Bundles) + 1 &&
  393   assert((Args.size() == FTy->getNumParams() ||
  398     assert((i >= FTy->getNumParams() ||
  407   assert(It + 1 == op_end() && "Should add up!");
  414   assert(getNumOperands() == 1 && "NumOperands not set up?");
  417   assert(FTy->getNumParams() == 0 && "Calling a function with bad signature");
  517   assert(val && "IsConstantOne does not work with nullptr val");
  528   assert(((!InsertBefore && InsertAtEnd) || (InsertBefore && !InsertAtEnd)) &&
  565   assert(AllocSize->getType() == IntPtrTy && "malloc arg is wrong size");
  599   assert(!MCall->getType()->isVoidTy() && "Malloc has void return type");
  656   assert(((!InsertBefore && InsertAtEnd) || (InsertBefore && !InsertAtEnd)) &&
  658   assert(Source->getType()->isPointerTy() &&
  701   assert(FreeCall && "CreateFree did not create a CallInst");
  708   assert(FreeCall && "CreateFree did not create a CallInst");
  722   assert((int)getNumOperands() ==
  730   assert(((Args.size() == FTy->getNumParams()) ||
  735     assert((i >= FTy->getNumParams() ||
  744   assert(It + 3 == op_end() && "Should add up!");
  790   assert((int)getNumOperands() ==
  801   assert(((Args.size() == FTy->getNumParams()) ||
  806     assert((i >= FTy->getNumParams() ||
  815   assert(It + 2 + IndirectDests.size() == op_end() && "Should add up!");
  821   assert(getNumIndirectDests() > i && "IndirectDest # out of range for callbr");
 1028   assert(ParentPad && NumReservedValues);
 1045   assert(NumOperands >= 1);
 1055   assert(OpNo < ReservedSpace && "Growing didn't work!");
 1076   assert(getNumOperands() == 1 + Args.size() && "NumOperands not set up?");
 1127     assert(getCondition()->getType()->isIntegerTy(1) &&
 1135   assert(IfTrue && "Branch destination may not be null!");
 1155   assert(IfTrue && "Branch destination may not be null!");
 1177     assert(BI.getNumOperands() == 3 && "BR can have 1 or 3 operands!");
 1185   assert(isConditional() &&
 1202     assert(!isa<BasicBlock>(Amt) &&
 1204     assert(Amt->getType()->isIntegerTy() &&
 1234   assert(!Ty->isVoidTy() && "Cannot allocate void!");
 1245   assert(!Ty->isVoidTy() && "Cannot allocate void!");
 1250   assert((!Align || *Align <= MaximumAlignment) &&
 1255     assert(getAlignment() == Align->value() &&
 1258     assert(getAlignment() == 0 && "Alignment representation error!");
 1284   assert(getOperand(0)->getType()->isPointerTy() &&
 1286   assert(!(isAtomic() && getAlignment() == 0) &&
 1320   assert(Ty == cast<PointerType>(Ptr->getType())->getElementType());
 1332   assert(Ty == cast<PointerType>(Ptr->getType())->getElementType());
 1341   assert((!Align || *Align <= MaximumAlignment) &&
 1346     assert(getAlignment() == Align->value() &&
 1349     assert(getAlignment() == 0 && "Alignment representation error!");
 1357   assert(getOperand(0) && getOperand(1) && "Both operands must be non-null!");
 1358   assert(getOperand(1)->getType()->isPointerTy() &&
 1360   assert(getOperand(0)->getType() ==
 1363   assert(!(isAtomic() && getAlignment() == 0) &&
 1420   assert((!Align || *Align <= MaximumAlignment) &&
 1425     assert(getAlignment() == Align->value() &&
 1428     assert(getAlignment() == 0 && "Alignment representation error!");
 1446   assert(getOperand(0) && getOperand(1) && getOperand(2) &&
 1448   assert(getOperand(0)->getType()->isPointerTy() &&
 1450   assert(getOperand(1)->getType() ==
 1453   assert(getOperand(2)->getType() ==
 1456   assert(SuccessOrdering != AtomicOrdering::NotAtomic &&
 1458   assert(FailureOrdering != AtomicOrdering::NotAtomic &&
 1460   assert(!isStrongerThan(FailureOrdering, SuccessOrdering) &&
 1463   assert(FailureOrdering != AtomicOrdering::Release &&
 1505   assert(getOperand(0) && getOperand(1) &&
 1507   assert(getOperand(0)->getType()->isPointerTy() &&
 1509   assert(getOperand(1)->getType() ==
 1512   assert(Ordering != AtomicOrdering::NotAtomic &&
 1599   assert(getNumOperands() == 1 + IdxList.size() &&
 1711   assert(isValidOperands(Val, Index) &&
 1725   assert(isValidOperands(Val, Index) &&
 1749   assert(isValidOperands(Vec, Elt, Index) &&
 1763   assert(isValidOperands(Vec, Elt, Index) &&
 1798   assert(isValidOperands(V1, V2, Mask) &&
 1815   assert(isValidOperands(V1, V2, Mask) &&
 1835     assert(MaskElt >= 0 && MaskElt < 2 * NumOpElts && "Out-of-range mask");
 1891   assert(i < Mask->getType()->getVectorNumElements() && "Index out of range");
 1917   assert(!Mask.empty() && "Shuffle mask must contain elements");
 1923     assert(Mask[i] >= 0 && Mask[i] < (NumOpElts * 2) &&
 1930   assert((UsesLHS ^ UsesRHS) && "Should have selected from exactly 1 source");
 2109   assert(getNumOperands() == 2 && "NumOperands not initialized?");
 2115   assert(!Idxs.empty() && "InsertValueInst must have at least one index");
 2117   assert(ExtractValueInst::getIndexedType(Agg->getType(), Idxs) ==
 2140   assert(getNumOperands() == 1 && "NumOperands not initialized?");
 2144   assert(!Idxs.empty() && "ExtractValueInst must have at least one index");
 2229     assert(getType() == LHS->getType() &&
 2231     assert(getType()->isFPOrFPVectorTy() &&
 2273   assert(LHS->getType() == RHS->getType() &&
 2279     assert(getType() == LHS->getType() &&
 2281     assert(getType()->isIntOrIntVectorTy() &&
 2286     assert(getType() == LHS->getType() &&
 2288     assert(getType()->isFPOrFPVectorTy() &&
 2294     assert(getType() == LHS->getType() &&
 2296     assert(getType()->isIntOrIntVectorTy() &&
 2300     assert(getType() == LHS->getType() &&
 2302     assert(getType()->isFPOrFPVectorTy() &&
 2307     assert(getType() == LHS->getType() &&
 2309     assert(getType()->isIntOrIntVectorTy() &&
 2313     assert(getType() == LHS->getType() &&
 2315     assert(getType()->isFPOrFPVectorTy() &&
 2321     assert(getType() == LHS->getType() &&
 2323     assert(getType()->isIntOrIntVectorTy() &&
 2328     assert(getType() == LHS->getType() &&
 2330     assert(getType()->isIntOrIntVectorTy() &&
 2341   assert(S1->getType() == S2->getType() &&
 2695       assert(
 2715       assert(
 2727       assert(
 2749   assert(castIsValid(op, S, Ty) && "Invalid cast!");
 2771   assert(castIsValid(op, S, Ty) && "Invalid cast!");
 2842   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 2843   assert((Ty->isIntOrIntVectorTy() || Ty->isPtrOrPtrVectorTy()) &&
 2845   assert(Ty->isVectorTy() == S->getType()->isVectorTy() && "Invalid cast");
 2846   assert((!Ty->isVectorTy() ||
 2860   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 2861   assert((Ty->isIntOrIntVectorTy() || Ty->isPtrOrPtrVectorTy()) &&
 2863   assert(Ty->isVectorTy() == S->getType()->isVectorTy() && "Invalid cast");
 2864   assert((!Ty->isVectorTy() ||
 2878   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 2879   assert(Ty->isPtrOrPtrVectorTy() && "Invalid cast");
 2891   assert(S->getType()->isPtrOrPtrVectorTy() && "Invalid cast");
 2892   assert(Ty->isPtrOrPtrVectorTy() && "Invalid cast");
 2914   assert(C->getType()->isIntOrIntVectorTy() && Ty->isIntOrIntVectorTy() &&
 2928   assert(C->getType()->isIntOrIntVectorTy() && Ty->isIntOrIntVectorTy() &&
 2942   assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
 2955   assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
 3089   assert(SrcTy->isFirstClassType() && DestTy->isFirstClassType() &&
 3128       assert(DestBits == SrcBits &&
 3132       assert(SrcTy->isPointerTy() &&
 3151       assert(DestBits == SrcBits &&
 3157     assert(DestBits == SrcBits &&
 3171       assert(DestBits == SrcBits && "Casting vector of wrong width to X86_MMX");
 3305   assert(castIsValid(getOpcode(), S, Ty) && "Illegal Trunc");
 3311   assert(castIsValid(getOpcode(), S, Ty) && "Illegal Trunc");
 3317   assert(castIsValid(getOpcode(), S, Ty) && "Illegal ZExt");
 3323   assert(castIsValid(getOpcode(), S, Ty) && "Illegal ZExt");
 3328   assert(castIsValid(getOpcode(), S, Ty) && "Illegal SExt");
 3334   assert(castIsValid(getOpcode(), S, Ty) && "Illegal SExt");
 3340   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPTrunc");
 3346   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPTrunc");
 3352   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPExt");
 3358   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPExt");
 3364   assert(castIsValid(getOpcode(), S, Ty) && "Illegal UIToFP");
 3370   assert(castIsValid(getOpcode(), S, Ty) && "Illegal UIToFP");
 3376   assert(castIsValid(getOpcode(), S, Ty) && "Illegal SIToFP");
 3382   assert(castIsValid(getOpcode(), S, Ty) && "Illegal SIToFP");
 3388   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPToUI");
 3394   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPToUI");
 3400   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPToSI");
 3406   assert(castIsValid(getOpcode(), S, Ty) && "Illegal FPToSI");
 3412   assert(castIsValid(getOpcode(), S, Ty) && "Illegal PtrToInt");
 3418   assert(castIsValid(getOpcode(), S, Ty) && "Illegal PtrToInt");
 3424   assert(castIsValid(getOpcode(), S, Ty) && "Illegal IntToPtr");
 3430   assert(castIsValid(getOpcode(), S, Ty) && "Illegal IntToPtr");
 3436   assert(castIsValid(getOpcode(), S, Ty) && "Illegal BitCast");
 3442   assert(castIsValid(getOpcode(), S, Ty) && "Illegal BitCast");
 3448   assert(castIsValid(getOpcode(), S, Ty) && "Illegal AddrSpaceCast");
 3454   assert(castIsValid(getOpcode(), S, Ty) && "Illegal AddrSpaceCast");
 3697   assert(CmpInst::isUnsigned(pred) && "Call only with signed predicates!");
 3797   assert(Value && Default && NumReserved);
 3849   assert(OpNo+1 < ReservedSpace && "Growing didn't work!");
 3861   assert(2 + idx*2 < getNumOperands() && "Case index out of range!!!");
 3901   assert(Changed && "called only if metadata has changed");
 3906   assert(SI.getNumSuccessors() == Weights->size() &&
 3940     assert(SI.getNumSuccessors() == Weights->size() &&
 3966     assert(SI.getNumSuccessors() == Weights->size() &&
 4020   assert(Address && Address->getType()->isPointerTy() &&
 4073   assert(OpNo < ReservedSpace && "Growing didn't work!");
 4081   assert(idx < getNumOperands()-1 && "Successor index out of range!");
lib/IR/IntrinsicInst.cpp
   49   assert(!cast<MDNode>(MD)->getNumOperands() && "Expected an empty MDNode");
   61   assert(Name.startswith("llvm."));
lib/IR/LLVMContext.cpp
   46     assert(ID == MDKind.first && "metadata kind id drifted");
   51   assert(DeoptEntry->second == LLVMContext::OB_deopt &&
   56   assert(FuncletEntry->second == LLVMContext::OB_funclet &&
   61   assert(GCTransitionEntry->second == LLVMContext::OB_gc_transition &&
   66   assert(CFGuardTargetEntry->second == LLVMContext::OB_cfguardtarget &&
   72   assert(SingleThreadSSID == SyncScope::SingleThread &&
   78   assert(SystemSSID == SyncScope::System &&
  181   assert (I && "Invalid instruction");
lib/IR/LLVMContextImpl.cpp
   54   assert(InstructionMetadata.empty() &&
  188     assert(Hash == RawHash &&
  212   assert(I != BundleTagCache.end() && "Unknown tag!");
  218   assert(NewSSID < std::numeric_limits<SyncScope::ID>::max() &&
lib/IR/LLVMContextImpl.h
  224     assert((RawOps.empty() || Ops.empty()) && "Two sets of operands?");
lib/IR/LegacyPassManager.cpp
  362     assert(N < PassVector.size() && "Pass number out of range!");
  433     assert(N < PassManagers.size() && "Pass number out of range!");
  514     assert(N < PassVector.size() && "Pass number out of range!");
  579     assert(N < PassManagers.size() && "Pass number out of range!");
  621       assert(AnalysisPass && "Expected analysis pass to exist.");
  623       assert(AR && "Expected analysis resolver to exist.");
  691     assert(Node && "cached analysis usage must be non null");
  753         assert(PI && "Expected required passes to be initialized");
  830     assert(PI == PassRegistry::getPassRegistry()->getPassInfo(AID) &&
  849   assert(PassInf && "Expected all immutable passes to be initialized");
  881       assert(PI && "Expected all immutable passes to be initialized");
  922   assert(!AvailableAnalysis.empty());
 1095     assert(PUsed->getResolver() && "Analysis Resolver is not set");
 1180     assert(AR && "Analysis Resolver is not set");
 1304   assert(PassDebugging >= Details);
 1561     assert(AR && "Analysis Resolver is not set");
 1796   assert(P->getPotentialPassManagerType() == PMT_ModulePassManager &&
 1798   assert((P->getPotentialPassManagerType() <
 1837   assert(FPP && "Unable to find on the fly pass");
 1911   assert(PM && "Unable to push. Pass Manager expected");
 1912   assert(PM->getDepth()==0 && "Pass Manager depth set too early");
 1915     assert(PM->getPassManagerType() > this->top()->getPassManagerType()
 1919     assert(TPM && "Unable to find top level manager");
 1924     assert((PM->getPassManagerType() == PMT_ModulePassManager
 1956   assert(!PMS.empty() && "Unable to find appropriate Pass Manager");
 1978     assert(!PMS.empty() && "Unable to create Function Pass Manager");
 2033     assert(!PMS.empty() && "Unable to create BasicBlock Pass Manager");
lib/IR/MDBuilder.cpp
   31   assert(Accuracy > 0.0 && "Invalid fpmath accuracy!");
   43   assert(Weights.size() >= 1 && "Need at least one branch weights!");
   85   assert(Lo.getBitWidth() == Hi.getBitWidth() && "Mismatched bitwidths!");
  145     assert(NewCBCalleeIdx != OldCBCalleeIdx &&
lib/IR/Mangler.cpp
   37   assert(!Name.empty() && "getNameWithPrefix requires non-empty name");
lib/IR/Metadata.cpp
  154   assert(Ref && "Expected live reference");
  155   assert((Owner || *static_cast<Metadata **>(Ref) == &MD) &&
  162     assert(!PH->Use && "Placeholders can only be used once");
  163     assert(!Owner && "Unexpected callback to owner");
  171   assert(Ref && "Expected live reference");
  179   assert(Ref && "Expected live reference");
  180   assert(New && "Expected live reference");
  181   assert(Ref != New && "Expected change");
  186   assert(!isa<DistinctMDOperandPlaceholder>(MD) &&
  188   assert(!isReplaceable(MD) &&
  202   assert(WasInserted && "Expected to add a reference");
  205   assert(NextIndex != 0 && "Unexpected overflow");
  211   assert(WasErased && "Expected to drop a reference");
  217   assert(I != UseMap.end() && "Expected to move a reference");
  222   assert(WasInserted && "Expected to add a reference");
  226   assert((OwnerAndIndex.first || *static_cast<Metadata **>(Ref) == &MD) &&
  228   assert((OwnerAndIndex.first || *static_cast<Metadata **>(New) == &MD) &&
  277   assert(UseMap.empty() && "Expected all uses to be replaced");
  332   assert(V && "Expected value");
  349   assert(V && "Unexpected null Value");
  354     assert((isa<Constant>(V) || isa<Argument>(V) || isa<Instruction>(V)) &&
  356     assert(!V->IsUsedByMD && "Expected this to be the only metadata use");
  368   assert(V && "Unexpected null Value");
  373   assert(V && "Expected valid value");
  382   assert(MD && "Expected valid metadata");
  383   assert(MD->getValue() == V && "Expected valid mapping");
  392   assert(From && "Expected valid value");
  393   assert(To && "Expected valid value");
  394   assert(From != To && "Expected changed value");
  395   assert(From->getType() == To->getType() && "Unexpected type change");
  401     assert(!From->IsUsedByMD && "Expected From not to be used by metadata");
  406   assert(From->IsUsedByMD && "Expected From to be used by metadata");
  409   assert(MD && "Expected valid metadata");
  410   assert(MD->getValue() == From && "Expected valid mapping");
  443   assert(!To->IsUsedByMD && "Expected this to be the only metadata use");
  464   assert(Entry && "Expected to find string map entry");
  539   assert(NumUnresolved == 0 && "Expected unresolved ops to be uncounted");
  540   assert(isUniqued() && "Expected this to be uniqued");
  545   assert(isTemporary() && "Expected this to be temporary");
  546   assert(!isResolved() && "Expected this to be unresolved");
  557     assert(isResolved() && "Expected this to be resolved");
  560   assert(isUniqued() && "Expected this to be uniqued");
  564   assert(isTemporary() && "Expected this to be temporary");
  565   assert(!isResolved() && "Expected this to be unresolved");
  571   assert(isDistinct() && "Expected this to be distinct");
  572   assert(isResolved() && "Expected this to be resolved");
  576   assert(isUniqued() && "Expected this to be uniqued");
  577   assert(!isResolved() && "Expected this to be unresolved");
  582   assert(isResolved() && "Expected this to be resolved");
  586   assert(!NumUnresolved && "Unexpected unresolved operand");
  594   assert(isUniqued() && "Expected this to be uniqued");
  595   assert(NumUnresolved != 0 && "Expected unresolved operands");
  607   assert(!isResolved() && "Expected this to be unresolved");
  611   assert(isUniqued() && "Expected this to be uniqued");
  617   assert(isResolved() && "Expected this to become resolved");
  633     assert(!N->isTemporary() &&
  700   assert(Op < getNumOperands() && "Expected valid operand");
  782   assert(!hasSelfReference(this) && "Cannot uniquify a self-referencing node");
  823     assert(ShouldCreate && "Expected non-uniqued nodes to always be created");
  831   assert(N->isTemporary() && "Expected temporary node");
  837   assert(!Context.hasReplaceableUses() && "Unexpected replaceable uses");
  838   assert(!NumUnresolved && "Unexpected unresolved nodes");
  840   assert(isResolved() && "Expected this to be resolved");
  871   assert(I < NumOperands);
 1081   assert(i < getNumOperands() && "Invalid Operand number!");
 1089   assert(I < getNumOperands() && "Invalid operand number");
 1235     assert(!Info.empty() == hasMetadataHashEntry() &&
 1244   assert((hasMetadataHashEntry() ==
 1275   assert(!Info.empty() && "bit out of sync with hash table");
 1292   assert(hasMetadataHashEntry() &&
 1296   assert(!Info.empty() && "Shouldn't have called this");
 1303   assert(hasMetadataHashEntry() &&
 1307   assert(!Info.empty() && "Shouldn't have called this");
 1313   assert(
 1337   assert((getOpcode() == Instruction::Br ||
 1373   assert(hasMetadataHashEntry() && "Caller should check");
 1512     assert(Val <= 2 && "unknown vcall visibility!");
lib/IR/Module.cpp
  211   assert(GV && "The CreateGlobalCallback is expected to create a global");
  355   assert(Node->getNumOperands() == 3 &&
  357   assert(mdconst::hasa<ConstantInt>(Node->getOperand(0)) &&
  388   assert(!Materializer &&
lib/IR/ModuleSummaryIndex.cpp
   87   assert(VI && "GlobalValue not found in index");
   88   assert((!PerModuleIndex || VI.getSummaryList().size() == 1) &&
  117     assert(VI.getAccessSpecifier() == 0 || isa<FunctionSummary>(S));
  401     assert(static_cast<size_t>(TypeOrHotness) <
lib/IR/Operator.cpp
   36   assert(Offset.getBitWidth() ==
lib/IR/OptBisect.cpp
   43   assert(BisectEnabled);
   50   assert(BisectEnabled);
lib/IR/Pass.cpp
  121   assert(!Resolver && "Resolver is already set");
lib/IR/PassRegistry.cpp
   61   assert(Inserted && "Pass registered multiple times!");
   90   assert(Registeree.isAnalysisGroup() &&
   95     assert(ImplementationInfo &&
  105       assert(InterfaceInfo->getNormalCtor() == nullptr &&
  107       assert(
lib/IR/PassTimingInfo.cpp
  180   assert(Pair.second && "should always create a new timer");
  223   assert(TimerStack.size() > 0 && "empty stack in popTimer");
  225   assert(MyTimer && "timer should be present");
lib/IR/RemarkStreamer.cpp
  121   assert(EnableRemarksSection == cl::BOU_UNSET);
lib/IR/SafepointIRVerifier.cpp
   84     assert(!isDeadBlock(InBB) && "block must be live");
   95     assert(Listed && "basic block is not found among incoming blocks");
  105     assert(cast<Instruction>(U->getUser())->isTerminator() &&
  107     assert(cast_or_null<BasicBlock>(U->get()) &&
  109     assert(!isDeadBlock(cast<Instruction>(U->getUser())->getParent()) &&
  137       assert(TI && "blocks must be well formed");
  628     assert(OldInCount >= BBS->AvailableIn.size() && "invariant!");
  639       assert(OldOutCount > BBS->AvailableOut.size() && "invariant!");
  648   assert(&BBS->Contribution == &Contribution &&
  705     assert(!(ValidUnrelocatedPointerDef && PoisonedPointerDef) &&
  738   assert(DTN && "Unreachable blocks are ignored");
  742     assert(BBS && "immediate dominator cannot be dead for a live block");
lib/IR/SymbolTableListTraitsImpl.h
   64   assert(!V->getParent() && "Value already in a container!!");
lib/IR/Type.cpp
  141   assert(isFloatingPointTy() && "Not a floating point type!");
  147   assert(getTypeID() == PPC_FP128TyID && "unknown fp type");
  245   assert(NumBits >= MIN_INT_BITS && "bitwidth too small");
  246   assert(NumBits <= MAX_INT_BITS && "bitwidth too large");
  285   assert(isValidReturnType(Result) && "invalid return type for function");
  291     assert(isValidArgumentType(Params[i]) &&
  374   assert(isOpaque() && "Struct body already set!");
  469   assert(!Elements.empty() &&
  475   assert(!Elements.empty() &&
  505   assert(!isLiteral() && "Literal structs never have names");
  540     assert(indexValid(Idx) && "Invalid structure index!");
  549     assert(indexValid(Idx) && "Invalid structure index!");
  588   assert(isValidElementType(ElementType) && "Invalid type for array element!");
  615   assert(EC.Min > 0 && "#Elements of a VectorType must be greater than 0");
  616   assert(isValidElementType(ElementType) && "Element type of a VectorType must "
  638   assert(EltTy && "Can't get a pointer to <null> type!");
  639   assert(isValidElementType(EltTy) && "Invalid type for pointer element!");
lib/IR/User.cpp
   23   assert((!isa<Constant>(this) || isa<GlobalValue>(this)) &&
   40   assert(HasHungOffUses && "alloc must have hung off uses");
   59   assert(HasHungOffUses && "realloc must have hung off uses");
   65   assert(NewNumUses > OldNumUses && "realloc must grow num uses");
   98   assert(HasDescriptor && "Don't call otherwise!");
   99   assert(!HasHungOffUses && "Invariant!");
  102   assert(DI->SizeInBytes != 0 && "Should not have had a descriptor otherwise!");
  114   assert(Us < (1u << NumUserOperandsBits) && "Too many operands");
  120   assert(DescBytesToAllocate % sizeof(void *) == 0 &&
  170     assert(!Obj->HasDescriptor && "not supported!");
lib/IR/Value.cpp
   48   assert(Ty && "Value defined with a null type: Error!");
   62     assert((VTy->isFirstClassType() || VTy->isVoidTy() || VTy->isStructTy()) &&
   66     assert((VTy->isFirstClassType() || VTy->isVoidTy()) &&
   91   assert(use_empty() && "Uses remain when a value is destroyed!");
  180     assert(isa<Constant>(V) && "Unknown value type!");
  191   assert(I != Ctx.pImpl->ValueNames.end() &&
  200   assert(HasName == Ctx.pImpl->ValueNames.count(this) &&
  234   assert(NameRef.find_first_of(0) == StringRef::npos &&
  246   assert(!getType()->isVoidTy() && "Cannot assign a name to void values!");
  326   assert(!Failure && "V has a name, so it should have a ST!"); (void)Failure;
  359   assert(M->isMaterialized());
  399   assert(New && "Value::replaceAllUsesWith(<null>) is invalid!");
  400   assert(!contains(New, this) &&
  402   assert(New->getType() == getType() &&
  440   assert(New && "Value::replaceUsesOutsideBlock(<null>, BB) is invalid!");
  441   assert(!contains(New, this) &&
  443   assert(New->getType() == getType() &&
  445   assert(BB && "Basic block that may contain a use of 'New' must be defined\n");
  522     assert(V->getType()->isPointerTy() && "Unexpected operand type!");
  556   assert(BitWidth == DL.getIndexTypeSizeInBits(getType()) &&
  598     assert(V->getType()->isPtrOrPtrVectorTy() && "Unexpected operand type!");
  610   assert(getType()->isPointerTy() && "must be pointer");
  675   assert(getType()->isPointerTy() && "must be pointer");
  779   assert(List && "Handle list is null?");
  787     assert(getValPtr() == Next->getValPtr() && "Added to wrong list?");
  792   assert(List && "Must insert after existing node");
  802   assert(getValPtr() && "Null pointer doesn't have a use list!");
  810     assert(Entry && "Value doesn't have any handles?");
  824   assert(!Entry && "Value really did already have handles?");
  838     assert(I->second && I->first == I->second->getValPtr() &&
  845   assert(getValPtr() && getValPtr()->HasValueHandle &&
  850   assert(*PrevPtr == this && "List invariant broken");
  854     assert(Next->getPrevPtr() == &Next && "List invariant broken");
  871   assert(V->HasValueHandle && "Should only be called if ValueHandles present");
  877   assert(Entry && "Value bit set but no entries exist");
  891     assert(Entry->Next == &Iterator && "Loop invariant broken.");
  924   assert(Old->HasValueHandle &&"Should only be called if ValueHandles present");
  925   assert(Old != New && "Changing value into itself!");
  926   assert(Old->getType() == New->getType() &&
  934   assert(Entry && "Value bit set but no entries exist");
  943     assert(Entry->Next == &Iterator && "Loop invariant broken.");
lib/IR/ValueSymbolTable.cpp
   39   assert(vmap.empty() && "Values remain in symbol table!");
   73   assert(V->hasName() && "Can't insert nameless Value into symbol table");
lib/IR/Verifier.cpp
  324     assert(F.getParent() == &M &&
  847   assert(ActualF && "Unimplemented function local metadata case!");
 1194     assert(N.getValue().data()[0] != ' ' && "Macro value has a space prefix");
 1939   assert(Call.getCalledFunction() &&
 1951   assert(isInt<32>(NumPatchBytes) && "NumPatchBytesV is an i32!");
 2232   assert(F.hasMetadata() != MDs.empty() && "Bit out-of-sync");
 3322   assert(Range && Range == I.getMetadata(LLVMContext::MD_range) &&
 3587   assert(I.isEHPad());
 3874         assert(CurrentPad == &FPI);
 4753   assert(!isa<DILocalScope>(LocalScope) && "Unknown type of local scope");
 5219   assert(InsertResult.second && "We just checked!");
 5366   assert(InsertResult.second && "Just checked!");
 5379   assert(BaseNode->getNumOperands() >= 2 && "Invalid base node!");
lib/LTO/LTO.cpp
  463   assert(Mods.size() == 1 && "Expect only one bitcode module");
  498     assert(ResI != ResE);
  511       assert(!GlobalRes.Prevailing &&
  550     assert(ResI != Res.end());
  565   assert(ResI == Res.end());
  570   assert(!CalledGetMaxTasks);
  583   assert(ResI == Res.end());
  711     assert(ResI != ResE);
  714     assert(MsymI != MsymE);
  774   assert(MsymI == MsymE);
  815     assert(ResI != ResE);
 1123     assert(ModuleToDefinedGVSummaries.count(ModulePath));
lib/LTO/LTOBackend.cpp
  525     assert(Mod.getContext().isODRUniquingDebugTypes() &&
  528     assert(I != ModuleMap.end());
lib/LTO/LTOCodeGenerator.cpp
  158   assert(&Mod->getModule().getContext() == &Context &&
  171   assert(&Mod->getModule().getContext() == &Context &&
  476   assert(ScopeRestrictionsDone &&
  671   assert(DiagHandler && "Invalid diagnostic handler");
lib/LTO/LTOModule.cpp
  464   assert(NameRef.data()[NameRef.size()] == '\0');
  609     assert(isa<GlobalAlias>(GV));
lib/LTO/ThinLTOCodeGenerator.cpp
  146     assert(ModuleMap.find(M->getName()) == ModuleMap.end() &&
  897   assert(ProducedBinaries.empty() && "The generator should not be reused");
lib/LineEditor/LineEditor.cpp
   37   assert(!Comps.empty());
  209   assert(Data->Hist);
  212   assert(Data->EL);
lib/Linker/IRMover.cpp
   81   assert(SpeculativeTypes.empty());
   82   assert(SpeculativeDstOpaqueTypes.empty());
  200     assert(DstSTy->isOpaque());
  254       assert(!(Pair.first != Ty && Pair.second == Ty) &&
  559     assert(ConflictGV->getName() != Name && "forceRenaming didn't work");
  983   assert(!DGV || SGV->hasAppendingLinkage() == DGV->hasAppendingLinkage());
 1057   assert(Dst.isDeclaration() && !Src.isDeclaration());
 1121     assert(CU && "Expected valid compile unit");
 1157       assert(Scope && "Invalid Scope encoding!");
 1439     assert(!GV->isDeclaration());
 1506   assert(!Ty->isOpaque());
 1511   assert(!Ty->isOpaque());
 1515   assert(Removed);
 1519   assert(Ty->isOpaque());
lib/Linker/LinkModules.cpp
  302     assert(!Dest.hasExternalWeakLinkage());
  303     assert(!Dest.hasAvailableExternallyLinkage());
  315     assert(Src.hasExternalLinkage());
  320   assert(!Src.hasExternalWeakLinkage());
  321   assert(!Dest.hasExternalWeakLinkage());
  322   assert(Dest.hasExternalLinkage() && Src.hasExternalLinkage() &&
lib/MC/ELFObjectWriter.cpp
  461   assert(StringTableIndex < ELF::SHN_LORESERVE);
  674     assert(Local || !Symbol.isTemporary());
  682         assert(!Local);
  703         assert(static_cast<const MCSymbolELF &>(Symbol).getType() ==
  713       assert(MSD.SectionIndex && "Invalid section index!");
  778     assert(MSD.Symbol->getBinding() != ELF::STB_LOCAL);
  786     assert(SymtabShndxSectionIndex == 0);
  789   assert(SymtabShndxSectionIndex != 0);
  885   assert((MAI->compressDebugSections() == DebugCompressionType::Z ||
 1026     assert(sh_link && ".symtab not found");
 1172     assert(SignatureSymbol);
 1284     assert(Pos != StringRef::npos);
 1375   assert(Sym && "Expected a symbol");
 1464     assert(!SymB.isAbsolute() && "Should have been folded");
 1472     assert(!IsPCRel && "should have been folded");
 1539     assert(!InSet);
lib/MC/MCAsmBackend.cpp
  104   assert((size_t)Kind <= array_lengthof(Builtins) && "Unknown fixup kind");
lib/MC/MCAsmStreamer.cpp
   77     assert(InstPrinter);
  373   assert(Comments.back() == '\n' &&
  388   assert(Bytes > 0 && Bytes <= 8 && "Invalid size!");
  430     assert(false && "Unexpected Assembly Comment");
  445   assert(Section && "Cannot switch to a null section!");
  477   assert(NbArgs != -1 && ((size_t)NbArgs) == Args.size() && "Malformed LOH!");
  478   assert(str != "" && "Invalid LOH name");
  504   assert(!Options.empty() && "At least one option is required!");
  770   assert(MAI->getLCOMMDirectiveAlignmentType() == LCOMM::Log2Alignment &&
  772   assert(isPowerOf2_32(ByteAlignment) && "Alignment must be a power of 2.");
  784   assert(MAI->hasDotTypeDotSizeDirective());
  821       assert(isPowerOf2_32(ByteAlign) && "alignment must be a power of 2");
  838   assert(Section->getVariant() == MCSection::SV_MachO &&
  862   assert(Symbol && "Symbol shouldn't be NULL!");
  865   assert(Section->getVariant() == MCSection::SV_MachO &&
  916   assert(getCurrentSectionOnly() &&
  954     assert(EJ > 0);
  973   assert(Size <= 8 && "Invalid size");
  974   assert(getCurrentSectionOnly() &&
 1009       assert(Shift < static_cast<uint64_t>(
 1019   assert(Directive && "Invalid size for machine code value!");
 1052   assert(MAI->getDTPRel64Directive() != nullptr);
 1059   assert(MAI->getDTPRel32Directive() != nullptr);
 1066   assert(MAI->getTPRel64Directive() != nullptr);
 1073   assert(MAI->getTPRel32Directive() != nullptr);
 1080   assert(MAI->getGPRel64Directive() != nullptr);
 1087   assert(MAI->getGPRel32Directive() != nullptr);
 1202   assert(MAI->hasSingleParameterDotFile());
 1244   assert(CUID == 0 && "multiple CUs not supported by MCAsmStreamer");
 1275   assert(CUID == 0);
 1499   assert(MAI->hasIdentDirective() && ".ident directive not supported");
 1865       assert(Index < Code.size() * 8 && "Invalid offset in fixup!");
 1911           assert(Bit == 0 && "Encoder wrote into fixed up bit!");
 1931   assert(getCurrentSectionOnly() &&
 2017     assert(Tables.size() == 1 && "asm output only supports one line table");
lib/MC/MCAssembler.cpp
  227   assert(getBackendPtr() && "Expected assembler backend");
  266   assert((ShouldAlignPC ? IsPCRel : true) &&
  289   assert(getBackendPtr() && "Requires assembler backend");
  392   assert(!isFragmentValid(F) && "Attempt to recompute a valid fragment!");
  395   assert((!Prev || isFragmentValid(Prev)) &&
  435     assert(isa<MCEncodedFragment>(F) &&
  465   assert(getBackendPtr() && "Expected assembler backend");
  469     assert(isBundlingEnabled() &&
  471     assert(EF.hasInstructions() &&
  518     assert(AF.getValueSize() && "Invalid virtual align in concrete fragment!");
  662   assert(OS.tell() - Start == FragmentSize &&
  668   assert(getBackendPtr() && "Expected assembler backend");
  672     assert(Layout.getSectionFileSize(Sec) == 0 && "Invalid size for section!");
  698         assert((cast<MCAlignFragment>(F).getValueSize() == 0 ||
  703         assert((cast<MCFillFragment>(F).getValue() == 0) &&
  718   assert(OS.tell() - Start == Layout.getSectionAddressSize(Sec));
  759   assert(getBackendPtr() && "Expected assembler backend");
  825         assert(!FragWithFixups->hasInstructions() || STI != nullptr);
  830         assert(!FragWithFixups->hasInstructions() || STI != nullptr);
  875   assert(getBackendPtr() && "Expected assembler backend");
  890   assert(getBackendPtr() && "Expected assembler backend");
  906   assert(getEmitterPtr() &&
  940   assert(getBackendPtr() && "Expected assembler backend");
  978   assert(Abs && "We created a line delta with an invalid expression");
 1019   assert(Abs && "We created call frame with an invalid expression");
 1072       assert(!getRelaxAll() &&
 1123   assert(getBackendPtr() && "Expected assembler backend");
lib/MC/MCCodePadder.cpp
   28   assert(Policy && "Policy must be valid");
   34   assert(OS != nullptr && "OS must be valid");
   35   assert(this->OS == nullptr && "Still handling another basic block");
   41   assert((!InsertionPoint ||
   69   assert(this->OS != nullptr && "Not handling a basic block");
   77   assert(CurrHandledInstFragment == nullptr && "Can't start handling an "
   82   assert((!InsertionPoint ||
  178   assert(InsertionResult.second &&
  202   assert(InsertionResult.second &&
  216   assert(isPowerOf2_64(MaxWindowSize) &&
  219   assert(isPowerOf2_64(SectionAlignment) &&
  245             assert(PolicyWeight >= 0.0 && "A penalty weight must be positive");
  269   assert(Fragment != nullptr && "Fragment cannot be null");
  367   assert(FullWindowWeight >= FullWindowFirstPartWeight &&
lib/MC/MCCodeView.cpp
   50   assert(FileNumber > 0);
  166   assert(I != StringTable.end());
  454   assert(Success && "failed to evaluate label difference as absolute");
  456   assert(Result >= 0 && "negative label difference requested");
  457   assert(Result < UINT_MAX && "label difference greater than 2GB");
  591   assert(HaveOpenRange);
  684     assert((NumGaps == 0 || Bias <= MaxDefRange) &&
  689       assert(I < GapAndRangeSizes.size());
lib/MC/MCContext.cpp
  133   assert(!NameRef.empty() && "Normal symbols cannot be unnamed!");
  206     assert(IsTemporary && "Cannot rename non-temporary symbols");
  638   assert(!FileName.empty());
lib/MC/MCDisassembler/Disassembler.cpp
  287     assert(OutStringSize != 0 && "Output buffer cannot be zero size");
lib/MC/MCDisassembler/MCExternalSymbolizer.cpp
  194   assert(Ctx && "No MCContext given for symbolic disassembly");
lib/MC/MCDwarf.cpp
  286   assert(array_lengthof(StandardOpcodeLengths) >=
  296   assert(!isa<MCSymbolRefExpr>(Expr));
  342     assert(!MCDwarfFiles[i].Name.empty());
  355   assert(!DwarfFile.Name.empty());
  439   assert((!RootFile.Name.empty() || MCDwarfFiles.size() >= 1) &&
  567   assert(!FileName.empty());
  737     assert(Temp <= 255 && "Buggy special opcode encoding.");
  906     assert(StartSymbol && "StartSymbol must not be NULL");
  907     assert(EndSymbol && "EndSymbol must not be NULL");
  994     assert(TextSection != Sections.end() && "No text section found");
  998     assert(StartSymbol && "StartSymbol must not be NULL");
  999     assert(EndSymbol && "EndSymbol must not be NULL");
 1022   assert(MCDwarfFiles.empty() || MCDwarfFiles.size() >= 2);
 1111     assert(StartSymbol && "StartSymbol must not be NULL");
 1112     assert(EndSymbol && "EndSymbol must not be NULL");
 1183   assert((RangesSectionSymbol != nullptr) || !UseRangesSection);
 1619     assert(RAReg <= 255 &&
 1941     assert(isUInt<32>(AddrDelta));
lib/MC/MCELFStreamer.cpp
  607   assert(AlignPow2 <= 30 && "Invalid bundle alignment");
  652     assert(!BundleGroups.empty() && "There are no bundle groups");
lib/MC/MCExpr.cpp
  182   assert(Symbol);
  628   assert((!Layout || Asm) &&
lib/MC/MCFragment.cpp
   47   assert(LastValid->getParent() == Sec);
   71     assert(I != Sec->end() && "Layout bookkeeping error");
   79   assert(F->Offset != ~UINT64_C(0) && "Address not set!");
  194   assert(BundleSize > 0 &&
lib/MC/MCInst.cpp
   48   assert(isExpr() &&
lib/MC/MCMachOStreamer.cpp
  158     assert(!CreatedADWARFSection && "Creating regular section after DWARF");
  224   assert(!Regions.empty() && "Mismatched .end_data_region!");
  226   assert(!Data.End && "Mismatched .end_data_region!");
  408   assert(Symbol->isUndefined() && "Cannot define a symbol twice!");
  486       assert(Symbol.getOffset() == 0 &&
lib/MC/MCObjectStreamer.cpp
   86   assert(Hi && Lo);
  138   assert(getCurrentSectionOnly() && "No current section!");
  290   assert(Section && "Cannot switch to a null section!");
  671   assert(getCurrentSectionOnly() && "need a section");
  701   assert(getCurrentSectionOnly() && "need a section");
lib/MC/MCParser/AsmLexer.cpp
   97   assert((*CurPtr == 'p' || *CurPtr == 'P' || *CurPtr == '.') &&
lib/MC/MCParser/AsmParser.cpp
  745   assert((HadError || ActiveMacros.empty()) &&
  912     assert(InsertResult && ".text section should not have debug info yet");
  940   assert(!hasPendingError() && "unexpected error from parseStatement");
 1372   assert((StrLoc.getPointer() != nullptr) &&
 1688   assert(!hasPendingError() && "parseStatement started with pending error");
 1831         assert(!RewrittenLabel.empty() &&
 2305   assert(getTok().is(AsmToken::Integer) &&
 2309   assert(getTok().is(AsmToken::String) &&
 2721         assert(M && "expected macro to be defined");
 3056       assert(Size <= 8 && "Invalid size");
 3341   assert(Section && "must have section to emit alignment");
 4757     assert(Size <= 8 && "Invalid size");
 5679   assert(getLexer().is(AsmToken::EndOfStatement));
 5804     assert(!hasPendingError() && "unexpected error from parseStatement");
 5901     assert(Loc >= AsmStart && "Expected Loc to be at or after Start!");
 5919       assert(AR.IntelExp.isValid() && "cannot write invalid intel expression");
 5969       assert(Val < 10 && "Expected alignment less then 2^10.");
lib/MC/MCParser/COFFAsmParser.cpp
  277   assert(Attr != MCSA_Invalid && "unexpected symbol attribute directive!");
lib/MC/MCParser/DarwinAsmParser.cpp
 1043   assert(getLexer().is(AsmToken::Comma) && "comma expected");
 1076   assert(isSDKVersionToken(getLexer().getTok()) && "expected sdk_version");
lib/MC/MCParser/ELFAsmParser.cpp
  177   assert(Attr != MCSA_Invalid && "unexpected symbol attribute directive!");
lib/MC/MCParser/MCAsmParser.cpp
   28   assert(!TargetParser && "Target parser is already initialized!");
lib/MC/MCParser/WasmAsmParser.cpp
  228     assert(Attr != MCSA_Invalid && "unexpected symbol attribute directive!");
lib/MC/MCRegisterInfo.cpp
   33   assert(Idx && Idx < getNumSubRegIndices() &&
   46   assert(SubReg && SubReg < getNumRegs() && "This is not a register");
   57   assert(Idx && Idx < getNumSubRegIndices() &&
   63   assert(Idx && Idx < getNumSubRegIndices() &&
lib/MC/MCSectionCOFF.cpp
   32   assert(Selection != 0 && "invalid COMDAT selection type");
   96         assert(false && "unsupported COFF selection type");
lib/MC/MCSectionELF.cpp
  164     assert(Flags & ELF::SHF_MERGE);
  175     assert(AssociatedSymbol);
lib/MC/MCSectionMachO.cpp
   88   assert(Segment.size() <= 16 && Section.size() <= 16 &&
  116   assert(SectionType <= MachO::LAST_KNOWN_SECTION_TYPE &&
  159   assert(SectionAttrs == 0 && "Unknown section attributes!");
lib/MC/MCSectionXCOFF.cpp
   62     assert((getMappingClass() == XCOFF::XMC_RW ||
   66     assert(getCSectType() == XCOFF::XTY_CM &&
lib/MC/MCStreamer.cpp
  132   assert(1 <= Size && Size <= 8 && "Invalid size");
  133   assert((isUIntN(8 * Size, Value) || isIntN(8 * Size, Value)) &&
  168   assert((!IsSectionRelative || Size == 4) &&
  392   assert(Fragment);
  406   assert(!Symbol->isVariable() && "Cannot emit a variable symbol!");
  407   assert(getCurrentSectionOnly() && "Cannot emit before setting section!");
  408   assert(!Symbol->getFragment() && "Unexpected fragment on symbol data!");
  409   assert(Symbol->isUndefined() && "Cannot define a symbol twice!");
  419   assert(EH || Debug);
 1102   assert(Section && "Cannot switch to a null section!");
 1108     assert(!Section->hasEnded() && "Section already ended");
 1141     assert(Major && "A non-zero major version is expected");
lib/MC/MCSubtargetInfo.cpp
   60   assert(SubtargetFeatures::hasFlag(Feature) &&
  158   assert(std::is_sorted(std::begin(ProcDesc), std::end(ProcDesc)) &&
  160   assert(std::is_sorted(std::begin(ProcFeatures), std::end(ProcFeatures)) &&
  291   assert(std::is_sorted(ProcDesc.begin(), ProcDesc.end()) &&
  304   assert(CPUEntry->SchedModel && "Missing processor SchedModel value");
lib/MC/MCSymbol.cpp
   49   assert(!IsUsed && "Cannot set a variable that has already been used.");
   50   assert(Value && "Invalid variable value!");
   51   assert((SymbolContents == SymContentsUnset ||
lib/MC/MCSymbolELF.cpp
  150   assert(Visibility == ELF::STV_DEFAULT || Visibility == ELF::STV_INTERNAL ||
  163   assert((Other & 0x1f) == 0);
  165   assert(Other <= 0x7);
lib/MC/MCWasmStreamer.cpp
   81   assert(Attribute != MCSA_IndirectSymbol && "indirect symbols not supported");
lib/MC/MCWin64EH.cpp
  189     assert(frameInst.Operation == Win64EH::UOP_SetFPReg);
  389     assert(inst.Register >= 19 && "Saved reg must be >= 19");
  397     assert(inst.Register >= 19 && "Saved reg must be >= 19");
  405     assert(inst.Register >= 19 && "Saved registers must be >= 19");
  413     assert(inst.Register >= 19 && "Saved registers must be >= 19");
  421     assert(inst.Register >= 8 && "Saved dreg must be >= 8");
  429     assert(inst.Register >= 8 && "Saved dreg must be >= 8");
  437     assert(inst.Register >= 8 && "Saved dregs must be >= 8");
  445     assert(inst.Register >= 8 && "Saved dregs must be >= 8");
  469     assert(InstrsIter != info->EpilogMap.end() &&
  559       assert(EpilogInfo.find(MatchingEpilog) != EpilogInfo.end() &&
  634   assert(BytesMod >= 0);
lib/MC/MCXCOFFStreamer.cpp
   56   assert(F && "Expected a valid section with a fragment set.");
lib/MC/MachObjectWriter.cpp
  160   assert(W.OS.tell() - Start == (is64Bit() ? sizeof(MachO::mach_header_64)
  165   assert(Size >= Str.size());
  211   assert(W.OS.tell() - Start == SegmentLoadCommandSize);
  224     assert(Layout.getSectionFileSize(&Sec) == 0 && "Invalid file size!");
  245   assert(isPowerOf2_32(Section.getAlignment()) && "Invalid alignment!");
  255   assert(W.OS.tell() - Start ==
  275   assert(W.OS.tell() - Start == sizeof(MachO::symtab_command));
  312   assert(W.OS.tell() - Start == sizeof(MachO::dysymtab_command));
  418   assert(W.OS.tell() - Start == sizeof(MachO::linkedit_data_command));
  451   assert(W.OS.tell() - Start == Size);
  551   assert(Index <= 256 && "Too many sections!");
  587       assert(MSD.SectionIndex && "Invalid section index!");
  610       assert(MSD.SectionIndex && "Invalid section index!");
  633       assert(isInt<24>(Index));
  867       assert(!V.empty() && "empty version");
  870       assert(Update < 256 && "unencodable update target version");
  871       assert(Minor < 256 && "unencodable minor target version");
  872       assert(V.getMajor() < 65536 && "unencodable major target version");
 1005     assert(W.OS.tell() - Start == LOHSize);
lib/MC/StringTableBuilder.cpp
   55   assert(isFinalized());
   65   assert(isFinalized());
  123   assert(K != DWARF);
  181   assert(isFinalized());
  183   assert(I != StringIndexMap.end() && "String is not in table!");
  189     assert(S.size() > COFF::NameSize && "Short string in COFF string table!");
  191   assert(!isFinalized());
lib/MC/WasmObjectWriter.cpp
  191   assert(SizeLen == 5);
  201   assert(SizeLen == 5);
  431   assert(!(Asm.getBackend().getFixupKindInfo(Fixup.getKind()).Flags &
  539     assert(GOTIndices.count(RelEntry.Symbol) > 0 && "symbol not found in GOT index space");
  549     assert(Sym->isFunction());
  559     assert(WasmIndices.count(RelEntry.Symbol) > 0 && "symbol not found in wasm index space");
 1034   assert(Symbol.isFunction());
 1035   assert(TypeIndices.count(&Symbol));
 1040   assert(Symbol.isEvent());
 1041   assert(TypeIndices.count(&Symbol));
 1046   assert(Symbol.isFunction());
 1066   assert(Symbol.isEvent());
 1167         assert(WasmIndices.count(&WS) == 0);
 1179         assert(WasmIndices.count(&WS) == 0);
 1192         assert(WasmIndices.count(&WS) == 0);
 1211       assert(GOTIndices.count(&WS) == 0);
 1252       assert(Sec.getKind().isMetadata());
 1383         assert(WasmIndices.count(&WS) == 0);
 1388         assert(WasmIndices.count(&WS) > 0);
 1394       assert(WS.isSection());
 1406     assert(S.isDefined());
 1415       assert(WasmIndices.count(ResolvedSym) > 0);
 1417       assert(WasmIndices.count(&WS) == 0);
 1421       assert(DataLocations.count(ResolvedSym) > 0);
 1463       assert(WasmIndices.count(&WS) > 0);
 1466       assert(DataLocations.count(&WS) > 0);
 1481       assert(Rel.Symbol->isFunction());
 1550       assert(Fixup.getKind() ==
lib/MC/WinCOFFObjectWriter.cpp
  427   assert(Value > Max7DecimalOffset && Value <= MaxBase64Offset &&
  455     assert(Buffer.size() <= COFF::NameSize && Buffer.size() >= 2);
  621     assert(W.OS.tell() == Sec.Header.PointerToRawData &&
  629     assert(AuxSyms.size() == 1 && AuxSyms[0].AuxType == ATSectionDefinition);
  636     assert(Sec.Header.PointerToRelocations == 0 &&
  641   assert(W.OS.tell() == Sec.Header.PointerToRelocations &&
  701   assert(Target.getSymA() && "Relocation must reference a symbol!");
  720   assert(SectionMap.find(MCSec) != SectionMap.end() &&
  756     assert(
  762     assert(
  932         assert(Relocation.Symb->getIndex() != -1);
  937     assert(Sec->Symbol->Aux.size() == 1 &&
  940     assert(Aux.AuxType == ATSectionDefinition &&
  995       assert(Symbol->getIndex() != -1);
  996       assert(Symbol->Aux.size() == 1 && "Symbol must contain one aux symbol!");
  997       assert(Symbol->Aux[0].AuxType == ATWeakExternal &&
 1011     assert(AssocMCSym);
 1024     assert(SectionMap.count(AssocMCSec));
 1046       assert(SectionMap.find(TargetSection) != SectionMap.end() &&
 1076   assert(W.OS.tell() == Header.PointerToSymbolTable &&
lib/MC/XCOFFObjectWriter.cpp
  211     assert(!needsAuxiliaryHeader() &&
  247     assert(XCOFF::XTY_SD == MCSec->getCSectType() &&
  256     assert(XCOFF::XTY_CM == MCSec->getCSectType() &&
  277     assert(WrapperMap.find(MCSec) == WrapperMap.end() &&
  302     assert(WrapperMap.find(ContainingCsect) != WrapperMap.end() &&
  332     assert(CurrentAddressLocation == Section->Address &&
  398   assert(SymbolOffset <= UINT32_MAX - CSectionRef.Address &&
  533           assert(Csect.Syms.size() == 1 && "Csect should only contain 1 symbol "
  634   assert(isPowerOf2_32(Align) && "Alignment must be a power of 2.");
lib/MCA/HardwareUnits/LSUnit.cpp
   72   assert((Desc.MayLoad || Desc.MayStore) && "Not a memory operation!");
  113   assert(Desc.MayLoad && "Expected a load!");
  165   assert(It != Groups.end() && "Instruction not dispatched to the LS unit");
  175   assert((IsALoad || IsAStore) && "Expected a memory operation!");
lib/MCA/HardwareUnits/RegisterFile.cpp
   50     assert(RF.NumPhysRegs && "Invalid PRF with zero physical registers!");
  151   assert(RegID && "Adding an invalid register definition?");
  190         assert(!IsEliminated && "Unexpected partial update!");
  252   assert(RegID != 0 && "Invalidating an already invalid register?");
  253   assert(WS.getCyclesLeft() != UNKNOWN_CYCLES &&
  255   assert(WS.getCyclesLeft() <= 0 && "Invalid cycles left for this write!");
  359   assert(RegID && RegID < RegisterMappings.size());
lib/MCA/HardwareUnits/ResourceManager.cpp
  161   assert(Index < Resources.size() && "Invalid processor resource index!");
  162   assert(S && "Unexpected null strategy in input!");
  179   assert(Index < Resources.size() && "Invalid resource use!");
  181   assert(RS.isReady() && "No available units to select!");
  258     assert(RS.isBufferAvailable() == ResourceStateEvent::RS_BUFFER_AVAILABLE);
  307     assert(CS.begin() == 0 && "Invalid {Start, End} cycles!");
  315       assert((countPopulation(R.first) > 1) && "Expected a group!");
  317       assert(R.second.isReserved());
  346   assert(Resource.isAResourceGroup() && !Resource.isReserved() &&
lib/MCA/HardwareUnits/RetireControlUnit.cpp
   36   assert(NumROBEntries && "Invalid reorder buffer size!");
   44   assert((AvailableEntries >= Entries) && "Reorder Buffer unavailable!");
   59   assert(Inst && "Invalid RUToken in the RCU queue.");
   86   assert(Queue.size() > TokenID);
   87   assert(Queue[TokenID].IR.getInstruction() && "Instruction was not dispatched!");
   88   assert(Queue[TokenID].Executed == false && "Instruction already executed!");
lib/MCA/HardwareUnits/Scheduler.cpp
  322   assert(IS.isReady() && (!IS.isMemOp() || LSU.isReady(IR)) &&
lib/MCA/InstrBuilder.cpp
  117       assert(countPopulation(A.first) > 1 && "Expected a group!");
  337   assert(CurrentDef == NumExplicitDefs &&
  358     assert(Write.RegisterID != 0 && "Expected a valid phys register!");
  510   assert(STI.getSchedModel().hasInstrSchedModel() &&
  699     assert(RegID && "Expected a valid register ID!");
lib/MCA/Instruction.cpp
   31   assert(DependentWrites);
   32   assert(CyclesLeft == UNKNOWN_CYCLES);
   54   assert(CyclesLeft == UNKNOWN_CYCLES);
   90   assert(!PartialWrite && "PartialWrite already set!");
  159   assert(Stage == IS_INVALID);
  169   assert(Stage == IS_READY);
  184   assert(Stage == IS_READY && "Invalid internal state!");
  190   assert(isPending() && "Unexpected instruction stage found!");
  204   assert(isDispatched() && "Unexpected instruction stage found!");
  242   assert(isExecuting() && "Instruction not in-flight?");
  243   assert(CyclesLeft && "Instruction already executed?");
lib/MCA/Pipeline.cpp
   38   assert(!Stages.empty() && "Unexpected empty pipeline found!");
   76   assert(S && "Invalid null stage in input!");
lib/MCA/Stages/DispatchStage.cpp
   79   assert(!CarryOver && "Cannot dispatch another instruction!");
   84     assert(AvailableEntries == DispatchWidth);
   89     assert(AvailableEntries >= NumMicroOps);
   99     assert(IS.getDefs().size() == 1 && "Expected a single input!");
  100     assert(IS.getUses().size() == 1 && "Expected a single output!");
  149   assert(CarriedOver && "Invalid dispatched instruction");
  176   assert(canDispatch(IR) && "Cannot dispatch another instruction!");
lib/MCA/Stages/EntryStage.cpp
   32   assert(!CurrentInstruction && "There is already an instruction to process!");
   43   assert(CurrentInstruction && "There is no instruction to process!");
lib/MCA/Stages/ExecuteStage.cpp
  163   assert(Inst.isEliminated() && "Instruction was not eliminated!");
  164   assert(Inst.isReady() && "Instruction in an inconsistent state!");
  169   assert(!Desc.MayLoad && !Desc.MayStore && "Cannot eliminate a memory op!");
  187   assert(isAvailable(IR) && "Scheduler is not available!");
  258       assert(Resource.second.getDenominator() == 1 && "Invalid cycles!");
lib/MCA/Support.cpp
   43   assert(Masks.size() == SM.getNumProcResourceKinds() &&
lib/Object/Archive.cpp
  120   assert(end <= sizeof(ArMemHdr->Name) && end > 0);
  340   assert(Err && "Err can't be nullptr if Start is not a nullptr");
  420   assert(isThin.get());
lib/Object/ArchiveWriter.cpp
   83   assert(FD != sys::fs::kInvalidFile);
  120   assert(SizeSoFar <= Size && "Data doesn't fit in Size");
  555   assert((!Thin || !isBSDLike(Kind)) && "Only the gnu format has a thin mode");
lib/Object/COFFObjectFile.cpp
   70   assert(Str.size() <= 6 && "String too long, possible overflow.");
  106   assert(!checkOffset(Data, uintptr_t(Addr), sizeof(*Addr)));
  111   assert((Offset - getPointerToSymbolTable()) % sizeof(coff_symbol_type) == 0 &&
  127   assert(Offset % sizeof(coff_section) == 0 &&
  334   assert((Offset % sizeof(coff_section)) == 0);
  452   assert(Rva <= UINT32_MAX);
  947   assert(PE32Header || PE32PlusHeader);
 1037     assert((Offset - getPointerToSymbolTable()) % SymbolSize == 0 &&
 1047   assert(Offset % getSymbolTableEntrySize() == 0 &&
 1050   assert(Index < getNumberOfSymbols());
 1695   assert(Table != nullptr);
 1706   assert(Entry != nullptr);
 1717   assert(Entry != nullptr);
 1723   assert(Entry.Offset.isSubDir());
 1729   assert(!Entry.Offset.isSubDir());
lib/Object/IRSymtab.cpp
  310   assert(!IRMods.empty());
lib/Object/MachOObjectFile.cpp
  109   assert(Offset <= O.getData().size());
 1669   assert(LoadCommands.size() == LoadCommandCount);
 2116   assert((getHeader().filetype == MachO::MH_OBJECT ||
 3055   assert(!Stack.empty() && "ExportEntry::moveNext() with empty node stack");
 3425   assert(Opcodes.data() == Other.Opcodes.data() && "compare iterators of different files");
 3988   assert(Opcodes.data() == Other.Opcodes.data() && "compare iterators of different files");
 4155   assert(Sec.d.a < Sections.size() && "Should have detected this earlier");
 4163   assert(Sec.d.a < Sections.size() && "Should have detected this earlier");
 4249   assert(DRI.d.a < Sections.size() && "Should have detected this earlier");
 4254   assert(DRI.d.a < Sections.size() && "Should have detected this earlier");
 4440   assert(is64Bit());
lib/Object/ModuleSymbolTable.cpp
   58     assert(FirstMod->getTargetTriple() == M->getTargetTriple());
   80   assert(T && T->hasMCAsmParser());
lib/Object/RelocationResolver.cpp
  568     assert(Obj.getBytesInAddress() == 4 &&
lib/Object/WasmObjectFile.cpp
 1106   assert(isDefinedFunctionIndex(Index));
 1112   assert(isDefinedFunctionIndex(Index));
 1117   assert(isDefinedGlobalIndex(Index));
 1122   assert(isDefinedEventIndex(Index));
 1167     assert(Ctx.Ptr == FunctionEnd);
 1314     assert(Segment.Offset.Opcode == wasm::WASM_OPCODE_I32_CONST);
 1540   assert(Ref.d.a < Sections.size());
 1556   assert(Ref.d.a < Sections.size());
 1558   assert(Ref.d.b < Sec.Relocations.size());
lib/Object/WindowsResource.cpp
  723   assert(Src.size() <= COFF::NameSize &&
lib/Object/XCOFFObjectFile.cpp
   79   assert(!is64Bit() && "32-bit interface called on 64-bit object file.");
   88   assert(is64Bit() && "64-bit interface called on a 32-bit object file.");
   96   assert(!is64Bit() && "Symbol table support not implemented for 64-bit.");
   97   assert(Ref.p != 0 && "Symbol table pointer can not be nullptr!");
  106   assert(!is64Bit() && "32-bit interface called on 64-bit object file.");
  111   assert(is64Bit() && "64-bit interface called on a 32-bit object file.");
  117   assert(!is64Bit() && "32-bit interface called on 64-bit object file.");
  123   assert(is64Bit() && "64-bit interface called on a 32-bit object file.");
  185   assert(!is64Bit() && "Symbol table support not implemented for 64-bit.");
  334   assert(!is64Bit() && "64-bit support not implemented yet.");
  341   assert(!is64Bit() && "64-bit support not implemented yet.");
  417   assert(!is64Bit() && "Symbol table support not implemented for 64-bit.");
  539   assert(Type == Binary::ID_XCOFF32 || Type == Binary::ID_XCOFF64);
  543   assert(is64Bit() && "64-bit interface called for non 64-bit file.");
  550   assert(!is64Bit() && "32-bit interface called for non 32-bit file.");
  708   assert(!OwningObjectPtr->is64Bit() &&
  710   assert(hasCsectAuxEnt() && "No Csect Auxiliary Entry is found.");
lib/ObjectYAML/COFFEmitter.cpp
  235         assert(CP.StringsAndChecksums.hasStrings() &&
  473   assert(OS.tell() == CP.SectionTableStart);
  489   assert(OS.tell() == CP.SectionTableStart + CP.SectionTableSize);
  504     assert(S.Header.PointerToRawData >= OS.tell());
  507     assert(S.Header.SizeOfRawData >= S.SectionData.binary_size());
lib/ObjectYAML/CodeViewYAMLDebugSections.cpp
  404   assert(SC.hasStrings());
  415   assert(SC.hasStrings() && SC.hasChecksums());
  446   assert(SC.hasChecksums());
  477   assert(SC.hasStrings());
  511   assert(SC.hasStrings());
  698   assert(S.empty());
  757     assert(CVS != nullptr);
  908   assert(Magic == COFF::DEBUG_SECTION_MAGIC && "Invalid .debug$S section!");
lib/ObjectYAML/CodeViewYAMLTypeHashing.cpp
   49   assert(DebugH.size() >= 8);
   50   assert((DebugH.size() - 8) % 8 == 0);
   63   assert(Reader.bytesRemaining() == 0);
   82     assert((Hash.size() == 8) && "Invalid hash size!");
   85   assert(Writer.bytesRemaining() == 0);
lib/ObjectYAML/CodeViewYAMLTypes.cpp
  784   assert(Magic == COFF::DEBUG_SECTION_MAGIC &&
  804     assert(T.length() % 4 == 0 && "Improper type record alignment!");
  815   assert(Writer.bytesRemaining() == 0 && "Didn't write all type record bytes!");
lib/ObjectYAML/DWARFEmitter.cpp
   55     assert(false && "Invalid integer write size.");
lib/ObjectYAML/ELFEmitter.cpp
   85     assert(false && "Expected section not found in index");
  307   assert(LocSec.empty() || LocSym.empty());
  394     assert(Sec && "It can't be null unless it is an implicit section. But all "
  591     assert(Symbols.empty());
  736   assert((Section.Type == llvm::ELF::SHT_REL ||
  791   assert(Section.Type == llvm::ELF::SHT_GROUP &&
  965   assert(Section.Type == llvm::ELF::SHT_MIPS_ABIFLAGS &&
  994   assert(Section.Type == llvm::ELF::SHT_DYNAMIC &&
lib/ObjectYAML/ELFYAML.cpp
  281   assert(Object && "The IO context is not initialized");
  438   assert(Object && "The IO context is not initialized");
  617   assert(Object && "The IO context is not initialized");
  668   assert(Object && "The IO context is not initialized");
  871     assert(Original && "This constructor is only used for outputting YAML and "
 1000   assert(!IO.outputting() ||
 1333   assert(IO.getContext() && "The IO context is not initialized");
 1340   assert(IO.getContext() && "The IO context is not initialized");
 1347   assert(IO.getContext() && "The IO context is not initialized");
 1356   assert(IO.getContext() && "The IO context is not initialized");
 1367   assert(IO.getContext() && "The IO context is not initialized");
 1376   assert(IO.getContext() && "The IO context is not initialized");
 1387   assert(Object && "The IO context is not initialized");
 1407   assert(!IO.getContext() && "The IO context is initialized already");
 1419   assert(IO.getContext() && "The IO context is not initialized");
lib/ObjectYAML/MachOEmitter.cpp
  274         assert((OS.tell() - fileStart <= Sec.offset ||
  497   assert(FatFile.FatArchs.size() == FatFile.Slices.size());
lib/ObjectYAML/MinidumpEmitter.cpp
   95   assert(OK && "Invalid UTF8 in Str?");
  111   assert(OS.tell() == BeginOffset + NextOffset &&
  199       assert(Raw.Content.binary_size() <= Raw.Size);
lib/ObjectYAML/WasmEmitter.cpp
  184       assert(Info.Index == SymbolIndex++);
lib/Option/ArgList.cpp
  222   assert(Index0 + 1 == Index1 && "Unexpected non-consecutive indices!");
lib/Option/OptTable.cpp
   81   assert(((A.Kind == Option::JoinedClass) ^ (B.Kind == Option::JoinedClass)) &&
  106       assert(!TheInputOptionID && "Cannot have multiple input options!");
  109       assert(!TheUnknownOptionID && "Cannot have multiple unknown options!");
  116   assert(FirstSearchableIndex != 0 && "No searchable options?");
  123     assert((Kind != Option::InputClass && Kind != Option::UnknownClass &&
  165   assert((unsigned) (id - 1) < getNumOptions() && "Invalid ID.");
  252   assert(!Option.empty());
  418     assert(Index > Prev && "Parser failed to consume argument.");
  422       assert(Index >= End && "Unexpected parser error.");
  423       assert(Index - Prev - 1 && "No missing arguments!");
lib/Option/Option.cpp
   30   assert((!Info || !getAlias().isValid() || !getAlias().getAlias().isValid()) &&
   34     assert(getAlias().isValid() && "Only alias options can have alias args.");
   35     assert(getKind() == FlagClass && "Only Flag aliases can have alias args.");
   36     assert(getAlias().getKind() != FlagClass &&
lib/Passes/PassBuilder.cpp
  390   assert(Level != O0 && "Must request optimizations!");
  553   assert(Level != O0 && "Not expecting O0 here!");
  592     assert(!ProfileFile.empty() && "Profile use expecting a profile file!");
  623     assert(!ProfileFile.empty() && "Profile use expecting a profile file!");
 1024   assert(Level != O0 && "Must request optimizations for the default pipeline!");
 1051   assert(Level != O0 && "Must request optimizations for the default pipeline!");
 1131   assert(Level != O0 && "Must request optimizations for the default pipeline!");
 1436     assert(false &&
 1442     assert(false && "invalid format for parametrized pass name");
 1446   assert((Result || Result.template errorIsA<StringError>()) &&
 1777     assert(Sep == ')' && "Bogus separator!");
 1802   assert(PipelineStack.back() == &ResultPipeline &&
 1867     assert(Matches.size() == 3 && "Must capture two matched strings!");
 1899       assert(Matches[1] == "lto" && "Not one of the matched options!");
lib/Passes/StandardInstrumentations.cpp
  115     assert(M && "module should be valid for printing");
  122     assert(F && "function should be valid for printing");
  129     assert(C && "scc should be valid for printing");
  137     assert(L && "Loop should be valid for printing");
  147   assert(ModuleDescStack.empty() && "ModuleDescStack is not empty at exit");
  151   assert(StoreModuleDesc);
  161   assert(!ModuleDescStack.empty() && "empty ModuleDescStack");
  163   assert(std::get<2>(ModuleDesc).equals(PassID) && "malformed ModuleDescStack");
lib/ProfileData/Coverage/CoverageMapping.cpp
  233   assert(!Record.MappingRegions.empty() && "Function has no regions");
  358     assert(I != E && "function does not cover the given file");
  426       assert((!Loc || CompletedRegion->endLoc() <= *Loc) &&
  591         assert(false && "Coverage segments not unique or sorted");
lib/ProfileData/Coverage/CoverageMappingReader.cpp
  306       assert(!FileIDExpansionRegionMapping[R.ExpandedFileID]);
  483     assert((CovMapVersion)CovHeader->getVersion<Endian>() == Version);
lib/ProfileData/Coverage/CoverageMappingWriter.cpp
   33     assert(NameSet.insert(Name).second && "Duplicate filename");
  117   assert(ID <=
  129   assert(all_of(MappingRegions,
  168       assert(I->FileID == (CurrentFileID + 1));
  186       assert(Count.isZero());
  187       assert(I->ExpandedFileID <=
  200       assert(Count.isZero());
  206     assert(I->LineStart >= PrevLineStart);
  209     assert(I->LineEnd >= I->LineStart);
  215   assert(CurrentFileID == (VirtualFileMapping.size() - 1));
lib/ProfileData/GCOV.cpp
   56   assert(GCNOInitialized && "readGCDA() can only be called after readGCNO()");
  389   assert(DstEdgeNo < DstEdges.size()); // up to caller to ensure EdgeNo is valid
lib/ProfileData/InstrProf.cpp
  380   assert(!NameStrs.empty() && "No name data to emit");
  386   assert(StringRef(UncompressedNameStrings)
  537   assert(ThisNumValueSites == Other.getNumValueSites(ValueKind));
  554   assert(FuncLevelOverlap.Test.CountSum >= 1.0f);
 1104     assert(F.getLinkage() == GlobalValue::AvailableExternallyLinkage);
 1128   assert(RangeLast >= RangeStart);
lib/ProfileData/ProfileSummaryBuilder.cpp
   73     assert(Cutoff <= 999999);
   80     assert(DesiredCount <= TotalCount);
   88     assert(CurrSum >= DesiredCount);
lib/ProfileData/SampleProf.cpp
  178   assert(DIL);
lib/ProfileData/SampleProfReader.cpp
  539     assert(Data == End && "More data is read than expected");
  555     assert(FuncProfileAddr < End && "out of LBRProfile section");
  804   assert(HeaderSize + TotalSecsSize == getFileSize() &&
 1224   assert(Remappings && "should be initialized while creating remapper");
lib/Remarks/BitstreamRemarkSerializer.cpp
  248     assert(StrTab != None && *StrTab != nullptr);
  250     assert(Filename != None);
  254     assert(RemarkVersion != None);
  258     assert(RemarkVersion != None);
  260     assert(StrTab != None && *StrTab != nullptr);
  331   assert(Mode == SerializerMode::Separate &&
  361   assert(DidSetUp &&
  370   assert(Helper.ContainerType !=
lib/Remarks/YAMLRemarkParser.cpp
   26   assert(Ctx && "Expected non-null Ctx in diagnostic handler.");
   28   assert(Message.empty() && "Expected an empty string.");
lib/Remarks/YAMLRemarkSerializer.cpp
   40     assert(io.outputting() && "input not yet implemented");
   61       assert(Serializer->StrTab.hasValue() &&
   78     assert(io.outputting() && "input not yet implemented");
   86       assert(Serializer->StrTab.hasValue() &&
  128     assert(io.outputting() && "input not yet implemented");
  137     assert(io.outputting() && "input not yet implemented");
  141       assert(Serializer->StrTab.hasValue() &&
  202   assert(StrTab);
  238   assert(!FilenameBuf.empty() && "The filename can't be empty.");
lib/Support/APFloat.cpp
  245     assert(p != end && "Exponent has no digits");
  249   assert(absExponent < 10U && "Invalid character in exponent");
  255     assert(value < 10U && "Invalid character in exponent");
  266   assert(p == end && "Invalid exponent in exponent");
  284   assert(p != end && "Exponent has no digits");
  289     assert(p != end && "Exponent has no digits");
  298     assert(value < 10U && "Invalid character in exponent");
  337     assert(end - begin != 1 && "Significand has no digits");
  379       assert(dot == end && "String contains multiple dots");
  389     assert((*p == 'e' || *p == 'E') && "Invalid character in significand");
  390     assert(p != begin && "Significand has no digits");
  391     assert((dot == end || p - begin != 1) && "Significand has no digits");
  442   assert(p != end && "Invalid trailing hexadecimal fraction!");
  515   assert(HUerr1 < 2 || HUerr2 < 2 || (HUerr1 + HUerr2 < 8));
  532   assert(bits != 0);
  580   assert(power <= maxExponent);
  648   assert(count != 0 && count <= APFloatBase::integerPartWidth / 4);
  707   assert(semantics == rhs.semantics);
  717   assert(isFiniteNonZero() || category == fcNaN);
  718   assert(rhs.partCount() >= partCount());
  824   assert(NumHighBits <= integerPartWidth && "Can not have more high bits to "
  846   assert(NumHighBits <= integerPartWidth && "Can not have more high bits to "
  946   assert(carry == 0);
  956   assert(semantics == rhs.semantics);
  957   assert(exponent == rhs.exponent);
  970   assert(semantics == rhs.semantics);
  971   assert(exponent == rhs.exponent);
  990   assert(semantics == rhs.semantics);
 1038       assert(extendedPrecision > omsb);
 1056     assert(status == opOK);
 1063     assert(lost_fraction == lfExactlyZero &&
 1117   assert(semantics == rhs.semantics);
 1161     assert(APInt::tcCompare(dividend, divisor, partsCount) >= 0);
 1203   assert((ExponentType) (exponent + bits) >= exponent);
 1212   assert(bits < semantics->precision);
 1220     assert(!APInt::tcIsZero(significandParts(), partsCount));
 1228   assert(semantics == rhs.semantics);
 1229   assert(isFiniteNonZero());
 1230   assert(rhs.isFiniteNonZero());
 1278   assert(isFiniteNonZero() || category == fcZero);
 1281   assert(lost_fraction != lfExactlyZero);
 1338       assert(lost_fraction == lfExactlyZero);
 1405   assert(omsb < semantics->precision);
 1521     assert(!carry);
 1535     assert(!carry);
 1682     assert(category != fcZero || lost_fraction == lfExactlyZero);
 1767   assert(fs==opOK);   // should always work
 1770   assert(fs==opOK || fs==opInexact);   // should not overflow or underflow
 1773   assert(fs==opOK || fs==opInexact);   // likewise
 1795     assert(fs==opOK);
 1892   assert(semantics == rhs.semantics);
 2086   assert(dstPartsCount <= parts.size() && "Integer too big");
 2198     assert(dstPartsCount <= parts.size() && "Integer too big");
 2330       assert(dot == end && "String contains multiple dots");
 2353   assert(p != end && "Hex strings require an exponent");
 2354   assert((*p == 'p' || *p == 'P') && "Invalid character in significand");
 2355   assert(p != begin && "Significand has no digits");
 2356   assert((dot == end || p - begin != 1) && "Significand has no digits");
 2444     assert(APInt::tcExtractBit
 2560         assert(decValue < 10U && "Invalid character in significand");
 2613   assert(!str.empty() && "Invalid string length");
 2626     assert(slen && "String has no digits");
 2630     assert(slen - 2 && "Invalid string");
 2789     assert(q >= p);
 2836   assert(semantics == (const llvm::fltSemantics*)&semX87DoubleExtended);
 2837   assert(partCount()==2);
 2853     assert(category == fcNaN && "Unknown category");
 2866   assert(semantics == (const llvm::fltSemantics *)&semPPCDoubleDoubleLegacy);
 2867   assert(partCount()==2);
 2883   assert(fs == opOK && !losesInfo);
 2888   assert(fs == opOK || fs == opInexact);
 2898     assert(fs == opOK && !losesInfo);
 2904     assert(fs == opOK && !losesInfo);
 2915   assert(semantics == (const llvm::fltSemantics*)&semIEEEquad);
 2916   assert(partCount()==2);
 2933     assert(category == fcNaN && "Unknown category!");
 2949   assert(semantics == (const llvm::fltSemantics*)&semIEEEdouble);
 2950   assert(partCount()==1);
 2966     assert(category == fcNaN && "Unknown category!");
 2977   assert(semantics == (const llvm::fltSemantics*)&semIEEEsingle);
 2978   assert(partCount()==1);
 2994     assert(category == fcNaN && "Unknown category!");
 3004   assert(semantics == (const llvm::fltSemantics*)&semIEEEhalf);
 3005   assert(partCount()==1);
 3021     assert(category == fcNaN && "Unknown category!");
 3050   assert(semantics == (const llvm::fltSemantics*)&semX87DoubleExtended &&
 3056   assert(semantics == (const llvm::fltSemantics*)&semIEEEsingle &&
 3063   assert(semantics == (const llvm::fltSemantics*)&semIEEEdouble &&
 3077   assert(api.getBitWidth()==80);
 3085   assert(partCount()==2);
 3111   assert(api.getBitWidth()==128);
 3120   assert(fs == opOK && !losesInfo);
 3127     assert(fs == opOK && !losesInfo);
 3135   assert(api.getBitWidth()==128);
 3143   assert(partCount()==2);
 3173   assert(api.getBitWidth()==64);
 3179   assert(partCount()==1);
 3204   assert(api.getBitWidth()==32);
 3210   assert(partCount()==1);
 3235   assert(api.getBitWidth()==16);
 3241   assert(partCount()==1);
 3553   assert(!buffer.empty() && "no characters in buffer!");
 3670   assert(reciprocal.isFiniteNonZero() &&
 3790         assert(exponent != semantics->maxExponent &&
 3823   assert(isNaN());
 3888   assert(Semantics == &semPPCDoubleDouble);
 3895   assert(Semantics == &semPPCDoubleDouble);
 3901   assert(Semantics == &semPPCDoubleDouble);
 3909   assert(Semantics == &semPPCDoubleDouble);
 3916   assert(Semantics == &semPPCDoubleDouble);
 3917   assert(&Floats[0].getSemantics() == &semIEEEdouble);
 3918   assert(&Floats[1].getSemantics() == &semIEEEdouble);
 3926   assert(Semantics == &semPPCDoubleDouble);
 3932   assert(Semantics == &semPPCDoubleDouble);
 4061   assert(LHS.getCategory() == fcNormal && RHS.getCategory() == fcNormal);
 4065   assert(&A.getSemantics() == &semIEEEdouble);
 4066   assert(&AA.getSemantics() == &semIEEEdouble);
 4067   assert(&C.getSemantics() == &semIEEEdouble);
 4068   assert(&CC.getSemantics() == &semIEEEdouble);
 4069   assert(&Out.Floats[0].getSemantics() == &semIEEEdouble);
 4070   assert(&Out.Floats[1].getSemantics() == &semIEEEdouble);
 4127   assert(LHS.getCategory() == fcNormal && RHS.getCategory() == fcNormal &&
 4175   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4184   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4193   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4204   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4214   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4264   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4272   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4278   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4310   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4320   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4328   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4339   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4347   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4358   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4369   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4380   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4409   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4417   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4423   assert(Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4434   assert(Arg.Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4441   assert(Arg.Semantics == &semPPCDoubleDouble && "Unexpected Semantics");
 4494     assert(&ToSemantics == &semPPCDoubleDouble);
 4525     assert(BitWidth == 128);
lib/Support/APInt.cpp
   92   assert(BitWidth && "Bitwidth too small");
   93   assert(bigVal.data() && "Null pointer detected!");
  120   assert(BitWidth && "Bitwidth too small");
  194   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  214   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  231   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  256   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
  276   assert(BitWidth == RHS.BitWidth && "Bit widths must be same for comparison");
  284   assert(BitWidth == RHS.BitWidth && "Bit widths must be same for comparison");
  340   assert(bitPosition < BitWidth && "Out of the bit-width range!");
  347   assert(0 < subBitWidth && (subBitWidth + bitPosition) <= BitWidth &&
  432   assert(numBits > 0 && "Can't extract zero bits");
  433   assert(bitPosition < BitWidth && (numBits + bitPosition) <= BitWidth &&
  470   assert(numBits > 0 && "Can't extract zero bits");
  471   assert(bitPosition < BitWidth && (numBits + bitPosition) <= BitWidth &&
  473   assert(numBits <= 64 && "Illegal bit extraction");
  494   assert(!str.empty() && "Invalid string length");
  495   assert((radix == 10 || radix == 8 || radix == 16 || radix == 2 ||
  507     assert(slen && "String is only a sign, needs a value.");
  557   assert(getBitWidth() % SplatSizeInBits == 0 &&
  578   assert(NewLen >= V.getBitWidth() && "Can't splat to smaller bit width!");
  645   assert(Count <= BitWidth);
  673   assert(BitWidth >= 16 && BitWidth % 16 == 0 && "Cannot byteswap!");
  852     assert(hiWord > 0 && "huh?");
  866   assert(width < BitWidth && "Invalid APInt Truncate request");
  867   assert(width && "Can't truncate to 0 bits");
  889   assert(Width > BitWidth && "Invalid APInt SignExtend request");
  913   assert(width > BitWidth && "Invalid APInt ZeroExtend request");
 1140   assert(this->ule(nextSquare) && "Error in APInt::sqrt computation");
 1156   assert(ult(modulo) && "This APInt must be smaller than the modulo");
 1295   assert(u && "Must provide dividend");
 1296   assert(v && "Must provide divisor");
 1297   assert(q && "Must provide quotient");
 1298   assert(u != v && u != q && v != q && "Must use different memory");
 1299   assert(n>1 && "n must be > 1");
 1455   assert(lhsWords >= rhsWords && "Fractional result");
 1527   assert(n != 0 && "Divide by zero?");
 1577   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
 1581     assert(RHS.U.VAL != 0 && "Divide by zero?");
 1589   assert(rhsWords && "Divided by zero???");
 1615   assert(RHS != 0 && "Divide by zero?");
 1670   assert(BitWidth == RHS.BitWidth && "Bit widths must be the same");
 1672     assert(RHS.U.VAL != 0 && "Remainder by zero?");
 1682   assert(rhsWords && "Performing remainder operation by zero ???");
 1708   assert(RHS != 0 && "Remainder by zero?");
 1763   assert(LHS.BitWidth == RHS.BitWidth && "Bit widths must be the same");
 1768     assert(RHS.U.VAL != 0 && "Divide by zero?");
 1780   assert(rhsWords && "Performing divrem operation by zero ???");
 1834   assert(RHS != 0 && "Divide by zero?");
 2094   assert(!str.empty() && "Invalid string length");
 2095   assert((radix == 10 || radix == 8 || radix == 16 || radix == 2 ||
 2105     assert(slen && "String is only a sign, needs a value.");
 2107   assert((slen <= numbits || radix != 2) && "Insufficient bit width");
 2108   assert(((slen-1)*3 <= numbits || radix != 8) && "Insufficient bit width");
 2109   assert(((slen-1)*4 <= numbits || radix != 16) && "Insufficient bit width");
 2110   assert((((slen-1)*64)/22 <= numbits || radix != 10) &&
 2125     assert(digit < radix && "Invalid character in digit string");
 2145   assert((Radix == 10 || Radix == 8 || Radix == 16 || Radix == 2 ||
 2247       assert(Digit < Radix && "divide failed");
 2293   assert(bits != 0 && bits <= APInt::APINT_BITS_PER_WORD);
 2323   assert(parts > 0);
 2398   assert(dstParts <= dstCount);
 2427   assert(c <= 1);
 2462   assert(c <= 1);
 2520   assert(dst <= src || dst >= src + srcParts);
 2521   assert(dstParts <= srcParts + 1);
 2579     assert(srcParts + 1 == dstParts);
 2606   assert(dst != lhs && dst != rhs);
 2627   assert(dst != lhs && dst != rhs);
 2648   assert(lhs != remainder && lhs != srhs && remainder != srhs);
 2844   assert(CoeffWidth == B.getBitWidth() && CoeffWidth == C.getBitWidth());
 2845   assert(RangeWidth <= CoeffWidth &&
 2847   assert(RangeWidth > 1 && "Value range bit width should be > 1");
 2913     assert(A.isStrictlyPositive());
 2970   assert(D.isNonNegative() && "Negative discriminant");
 2997   assert(X.isNonNegative() && "Solution should be non-negative");
 3004   assert((SQ*SQ).sle(D) && "SQ = |_sqrt(D)_|, so SQ*SQ <= D");
 3032   assert(A.getBitWidth() == B.getBitWidth() && "Must have the same bitwidth");
 3042   assert((IntVal.getBitWidth()+7)/8 >= StoreBytes && "Integer too small!");
 3067   assert((IntVal.getBitWidth()+7)/8 >= LoadBytes && "Integer too small!");
lib/Support/APSInt.cpp
   21   assert(!Str.empty() && "Invalid string length");
lib/Support/BinaryStreamReader.cpp
   89   assert(FoundOffset >= OriginalOffset);
  163   assert(!EC && "Cannot peek an empty buffer!");
  170   assert(getLength() >= Off);
lib/Support/BinaryStreamWriter.cpp
   84   assert(getLength() >= Off);
lib/Support/BlockFrequency.cpp
   74   assert(Frequency != 0);
lib/Support/BranchProbability.cpp
   40   assert(Denominator > 0 && "Denominator cannot be 0!");
   41   assert(Numerator <= Denominator && "Probability cannot be bigger than 1!");
   54   assert(Numerator <= Denominator && "Probability cannot be bigger than 1!");
   72   assert(D && "divide by 0");
lib/Support/Chrono.cpp
   31   assert(LT);
lib/Support/CommandLine.cpp
  343     assert(count_if(RegisteredOptionCategories,
  353     assert(count_if(RegisteredSubCommands,
  440   assert((S.empty() || S[0] != '-') && "Option can't start with '-");
  447   assert(!Categories.empty() && "Categories cannot be empty.");
  513   assert(&Sub != &*AllSubCommands);
  650       assert(argv && "null check");
  684     assert(argv && "null check");
  751     assert(OptionsMap.count(Arg) && OptionsMap.find(Arg)->second == PGOpt);
  767     assert(isGrouping(PGOpt) && "Broken getOptionPred!");
 1177   assert(FileStack.size() > 0 && Argv.size() == FileStack.back().End);
 1198   assert(progName && "Program name not specified");
 1199   assert(envVar && "Environment variable name missing");
 1260   assert(hasOptions() && "No options specified!");
 1299   assert(ChosenSubCommand);
 1310     assert(PositionalOpts.size() > 0 &&
 1529     assert(ConsumeAfterOpt && NumPositionalRequired <= PositionalVals.size());
 1653   assert(Indent >= FirstLineIndentedBy);
 1889       assert(GlobalWidth >= OptionName.size() + OptionPrefixesSize);
 1894         assert(NumSpaces >= EmptyOption.size());
 2191     assert(SortedCategories.size() > 0 && "No option categories registered!");
 2208         assert(CategorizedOptions.count(Cat) > 0 &&
 2457   assert(is_contained(Subs, &Sub));
lib/Support/ConvertUTF.cpp
  427   assert(!isLegalUTF8Sequence(source, sourceEnd));
  505   assert((b1 >= 0x80 && b1 <= 0xC1) || b1 >= 0xF5);
lib/Support/ConvertUTFWrapper.cpp
   21   assert(WideCharWidth == 1 || WideCharWidth == 2 || WideCharWidth == 4);
   60   assert((result != targetExhausted)
   87   assert(Out.empty());
  122   assert(CR != targetExhausted);
  144   assert(DstUTF16.empty());
  167   assert(CR != targetExhausted);
lib/Support/CrashRecoveryContext.cpp
   62     assert(!Failed && "Crash recovery context already failed!");
  349     assert(!Impl && "Crash recovery context already initialized!");
  366   assert(CRCI && "Crash recovery context never initialized!");
lib/Support/DAGDeltaAlgorithm.cpp
   82     assert(Predecessors.count(Node) && "Invalid node!");
   86     assert(Predecessors.count(Node) && "Invalid node!");
   91     assert(PredClosure.count(Node) && "Invalid node!");
   95     assert(PredClosure.count(Node) && "Invalid node!");
  100     assert(Successors.count(Node) && "Invalid node!");
  104     assert(Successors.count(Node) && "Invalid node!");
  109     assert(SuccClosure.count(Node) && "Invalid node!");
  113     assert(SuccClosure.count(Node) && "Invalid node!");
  131           assert(S.count(*it2) && "Attempt to run invalid changeset!");
lib/Support/DJB.cpp
   30   assert(!Buffer.empty());
   45   assert(CR == conversionOK && "Case folding produced invalid char?");
lib/Support/DataExtractor.cpp
  176   assert(*offset_ptr <= Data.size());
  196   assert(*offset_ptr <= Data.size());
lib/Support/DynamicLibrary.cpp
   92     assert(!((Order & SO_LoadedFirst) && (Order & SO_LoadedLast)) &&
lib/Support/Error.cpp
  140   assert(Err && "report_fatal_error called with success value");
lib/Support/ErrorHandling.cpp
   68   assert(!ErrorHandler && "Error handler already registered!\n");
  133   assert(!ErrorHandler && "Bad alloc error handler already registered!\n");
  194   assert(old == nullptr && "new-handler already installed");
lib/Support/FileCheck.cpp
  607   assert(BackrefNum >= 1 && BackrefNum <= 9 && "Invalid backref number");
  669   assert(!MatchInfo.empty() && "Didn't get any match");
  674     assert(VariableDef.second < MatchInfo.size() && "Internal paren error");
  684     assert(CaptureParenGroup < MatchInfo.size() && "Internal paren error");
  949   assert(Count > 0 && "zero and negative counts are not supported");
  950   assert((C == 1 || Kind == CheckPlain) &&
 1085     assert(Prefix.data() >= Buffer.data() &&
 1119   assert(!LineVariable && "@LINE pseudo numeric variable already created");
 1177     assert(UsedPrefix.data() == Buffer.data() &&
 1180     assert(AfterSuffix.data() >= Buffer.data() &&
 1339   assert(MatchErrors && "Called on successful match");
 1448   assert(Pat.getCount() != 0 && "pattern count can not be zero");
 1573     assert((Pat->getCheckTy() == Check::CheckNot) && "Expect CHECK-NOT!");
 1619     assert((Pat.getCheckTy() == Check::CheckDAG ||
 1628     assert((Pat.getCheckTy() == Check::CheckDAG) && "Expect CHECK-DAG!");
 1770   assert(GlobalVariableTable.empty() && GlobalNumericVariableTable.empty() &&
 1853       assert(DefinedNumericVariable && "No variable defined");
lib/Support/FoldingSet.cpp
  202   assert((Ptr & 1) && "Not a bucket pointer");
  229   assert(5 < Log2InitSize && Log2InitSize < 32 &&
  270   assert((NewBucketCount > NumBuckets) && "Can't shrink a folding set with GrowBucketCount");
  271   assert(isPowerOf2_32(NewBucketCount) && "Bad bucket count!");
  347   assert(!N->getNextInBucket());
lib/Support/FormatVariadic.cpp
   69     assert(false && "Invalid replacement sequence index!");
   76       assert(false && "Invalid replacement field layout specification!");
   85     assert(false && "Unexpected characters found in replacement string!");
  115       assert(
lib/Support/Host.cpp
 1257       assert(CurPhysicalId == -1 &&
 1262       assert(CurCoreId == -1 &&
lib/Support/IntEqClasses.cpp
   25   assert(NumClasses == 0 && "grow() called after compress().");
   32   assert(NumClasses == 0 && "join() called after compress().");
   53   assert(NumClasses == 0 && "findLeader() called after compress().");
lib/Support/IntervalMap.cpp
   19   assert(!path.empty() && "Can't replace missing root");
   48   assert(Level != 0 && "Cannot move the root node");
   55       assert(l != 0 && "Cannot move beyond begin()");
   98   assert(Level != 0 && "Cannot move the root node");
  122   assert(Elements + Grow <= Nodes * Capacity && "Not enough room for elements");
  123   assert(Position <= Elements && "Invalid position");
  137   assert(Sum == Elements + Grow && "Bad distribution sum");
  141     assert(PosPair.first < Nodes && "Bad algebra");
  142     assert(NewSize[PosPair.first] && "Too few elements to need Grow");
  149     assert(NewSize[n] <= Capacity && "Overallocated node");
  152   assert(Sum == Elements && "Bad distribution sum");
lib/Support/ItaniumManglingCanonicalizer.cpp
  167         assert(Remappings.find(Result.first) == Remappings.end() &&
lib/Support/JSON.cpp
  226     assert(Err);
  629   assert(Stack.back().Ctx != Object && "Only attributes allowed here");
  631     assert(Stack.back().Ctx != Singleton && "Only one value allowed here");
  655   assert(Stack.back().Ctx == Array);
  661   assert(!Stack.empty());
  673   assert(Stack.back().Ctx == Object);
  679   assert(!Stack.empty());
  683   assert(Stack.back().Ctx == Object);
  693     assert(false && "Invalid UTF-8 in attribute key");
  702   assert(Stack.back().Ctx == Singleton);
  703   assert(Stack.back().HasValue && "Attribute must have a value");
  705   assert(Stack.back().Ctx == Object);
lib/Support/KnownBits.cpp
   21   assert(!(CarryZero && CarryOne) &&
   37   assert((PossibleSumZero & Known) == (PossibleSumOne & Known) &&
   49   assert(Carry.getBitWidth() == 1 && "Carry must be 1-bit");
lib/Support/LineIterator.cpp
   43     assert(Buffer.getBufferEnd()[0] == '\0');
   51   assert(Buffer && "Cannot advance past the end!");
   54   assert(Pos == Buffer->getBufferStart() || isAtLineEnd(Pos) || *Pos == '\0');
lib/Support/LowLevelType.cpp
   26     assert(VT.getSizeInBits() != 0 && "invalid zero-sized type");
   42     assert(isScalar() && "unexpected type");
lib/Support/ManagedStatic.cpp
   35   assert(Creator);
   50     assert(!Ptr && !DeleterFn && !Next &&
   62   assert(DeleterFn && "ManagedStatic not initialized correctly!");
   63   assert(StaticList == this &&
lib/Support/Memory.cpp
   36   assert((PF & ~(Memory::MF_READ | Memory::MF_WRITE | Memory::MF_EXEC)) == 0 &&
lib/Support/MemoryBuffer.cpp
   47   assert((!RequiresNullTerminator || BufEnd[0] == 0) &&
  343   assert(End <= FileSize);
  491   assert(MapSize != uint64_t(-1));
lib/Support/NativeFormatting.cpp
   33   assert(!Buffer.empty());
   41   assert(Buffer.size() % 3 == 0);
lib/Support/Options.cpp
   25   assert(Options.find(Key) == Options.end() &&
lib/Support/Path.cpp
  241   assert(Position < Path.size() && "Tried to increment past end!");
  523   assert((!path.isSingleStringRef() ||
  797   assert(P.find_first_of(separators(Style::native)) == StringRef::npos &&
 1132 TempFile::~TempFile() { assert(Done); }
 1160   assert(!Done);
 1205   assert(!Done);
lib/Support/PluginLoader.cpp
   43   assert(Plugins.isConstructed() && num < Plugins->size() &&
lib/Support/PrettyStackTrace.cpp
  210   assert(PrettyStackTraceHead == this &&
lib/Support/Process.cpp
   38   assert(!path::is_absolute(FileName));
lib/Support/Program.cpp
   35   assert(Redirects.empty() || Redirects.size() == 3);
   56   assert(Redirects.empty() || Redirects.size() == 3);
lib/Support/Regex.cpp
  123       assert(pm[i].rm_eo >= pm[i].rm_so);
lib/Support/ScaledNumber.cpp
   59   assert(Dividend && "expected non-zero dividend");
   60   assert(Divisor && "expected non-zero divisor");
   82   assert(Dividend && "expected non-zero dividend");
   83   assert(Divisor && "expected non-zero divisor");
  125   assert(ScaleDiff >= 0 && "wrong argument order");
  126   assert(ScaleDiff < 64 && "numbers too far apart");
  138   assert(D < 10);
  163   assert(E >= ScaledNumbers::MinScale);
  164   assert(E <= ScaledNumbers::MaxScale);
  170   assert(Shift <= LeadingZeros);
  171   assert(Shift == LeadingZeros || NewE == ScaledNumbers::MaxScale);
  172   assert(Shift >= 0 && Shift < 64 && "undefined behavior");
  179     assert(E == ScaledNumbers::MaxScale);
  193   assert(NonZero != std::string::npos && "no . in floating point string");
lib/Support/SmallPtrSet.cpp
   25   assert(!isSmall() && "Can't shrink a small set!");
  145   assert(&RHS != this && "Self-copy should be handled by the caller.");
  148     assert(CurArraySize == RHS.CurArraySize &&
  190   assert(&RHS != this && "Self-move should be handled by the caller.");
  208   assert(RHS.CurArray == RHS.SmallArray);
  230     assert(RHS.CurArray == RHS.SmallArray);
  243     assert(this->CurArray == this->SmallArray);
  255   assert(this->isSmall() && RHS.isSmall());
  267   assert(this->CurArraySize == RHS.CurArraySize);
lib/Support/SourceMgr.cpp
   81     assert(Sz <= std::numeric_limits<T>::max());
   93   assert(Ptr >= BufStart && Ptr <= Buffer->getBufferEnd());
   95   assert(PtrDiff >= 0 && static_cast<size_t>(PtrDiff) <= std::numeric_limits<T>::max());
  128   assert(BufferID && "Invalid Location!");
  154   assert(CurBuf && "Invalid or unspecified location!");
  176     assert(CurBuf && "Invalid or unspecified location!");
  235     assert(CurBuf && "Invalid or unspecified location!");
  315     assert((size_t)sys::locale::columnWidth(I->getText()) ==
lib/Support/Statistic.cpp
  211     assert(yaml::needsQuotes(Stat->getDebugType()) == yaml::QuotingType::None &&
  213     assert(yaml::needsQuotes(Stat->getName()) == yaml::QuotingType::None &&
lib/Support/StringMap.cpp
   53   assert((InitSize & (InitSize-1)) == 0 &&
  180   assert(V == V2 && "Didn't find key?");
  193   assert(NumItems + NumTombstones <= NumBuckets);
lib/Support/StringPool.cpp
   21   assert(InternTable.empty() && "PooledStringPtr leaked!");
lib/Support/StringRef.cpp
  515   assert(Radix > 1 && Radix <= 36);
lib/Support/TargetRegistry.cpp
   93   assert(Name && ShortDesc && ArchMatchFn &&
lib/Support/ThreadPool.cpp
   90     assert(EnableFlag && "Queuing a thread during ThreadPool destruction");
lib/Support/TimeProfiler.cpp
   72     assert(!Stack.empty() && "Must call begin() first");
   77     assert((Entries.empty() ||
  107     assert(Stack.empty() &&
  189   assert(TimeTraceProfilerInstance == nullptr &&
  201   assert(TimeTraceProfilerInstance != nullptr &&
lib/Support/Timer.cpp
   99   assert(!TG && "Timer already initialized");
  138   assert(!Running && "Cannot start a running timer");
  145   assert(Running && "Cannot stop a paused timer");
  250   assert(TimersToPrint.size() == Records.size() && "Size mismatch");
  401   assert(yaml::needsQuotes(Name) == yaml::QuotingType::None &&
  403   assert(yaml::needsQuotes(R.Name) == yaml::QuotingType::None &&
lib/Support/Triple.cpp
  924       assert(Pos < Components.size() && Components[Pos] == Comp &&
 1016   assert(!Str.empty() && Str[0] >= '0' && Str[0] <= '9' && "Not a number");
lib/Support/Unix/Path.inc
  566   assert(status_known(A) && status_known(B));
  747   assert(Size != 0);
  792   assert(Mapping && "Mapping failed but used anyway!");
  797   assert(Mapping && "Mapping failed but used anyway!");
  802   assert(Mapping && "Mapping failed but used anyway!");
lib/Support/Unix/Process.inc
  201       assert(errno && "expected errno to be set if fstat failed!");
  209     assert(errno == EBADF && "expected errno to have EBADF at this point!");
lib/Support/Unix/Program.inc
   70   assert(!Name.empty() && "Must have a name!");
  212       assert(Redirects.size() == 3);
  338   assert(PI.Pid && "invalid pid to wait on, process not started?");
lib/Support/Unix/Signals.inc
  298     assert(Index < array_lengthof(RegisteredSignalInfo) &&
  502     assert(Entries < MaxEntries && "recursively called after END_OF_STACK?");
lib/Support/Unix/ThreadLocal.inc
   33   assert(errorcode == 0);
   40   assert(errorcode == 0);
   47   assert(errorcode == 0);
lib/Support/VersionTuple.cpp
   39   assert(value == 0);
lib/Support/VirtualFileSystem.cpp
   90   assert(isStatusKnown() && Other.isStatusKnown());
  183     assert(FD != kInvalidFile && "Invalid or inactive file descriptor");
  203   assert(FD != kInvalidFile && "cannot stat closed file");
  220   assert(FD != kInvalidFile && "cannot get buffer for closed file");
  463     assert(CurrentFS != Overlays.overlays_end() && "incrementing past end");
  477     assert((IsFirstTime || CurrentDirIter != directory_iterator()) &&
  704   assert(!EC);
  719   assert(!(HardLinkTarget && Buffer) && "HardLink cannot have a buffer");
  764       assert((isa<detail::InMemoryFile>(Node) ||
  814   assert(!EC);
  956   assert(!EC);
 1126     assert(DE && "Should be a directory");
 1274       assert(NewParentE && "Parent entry must exist");
 1386           assert(!FullPath.empty() &&
 1432       assert(NameValueNode && "Name presence should be checked earlier");
 1613     assert(!EC && "Overlay dir final path must be absolute");
 1660   assert(!isTraversalComponent(*Start) &&
 1712   assert(E != nullptr);
 1715     assert(!S || S->getName() == F->getExternalContentsPath());
 1831     assert(DE && "Must be a directory");
 1841   assert(Kind == RedirectingFileSystem::EK_File && "Must be a EK_File");
 1843   assert(FE && "Must be a file");
 1876   assert(sys::path::is_absolute(VirtualPath) && "virtual path not absolute");
 1877   assert(sys::path::is_absolute(RealPath) && "real path not absolute");
 1878   assert(!pathHasTraversal(VirtualPath) && "path traversal is not supported");
 1921   assert(!Parent.empty());
 1922   assert(containedIn(Parent, Path));
 1985       assert(RPath.substr(0, OverlayDirLen) == OverlayDir &&
 2007         assert(RPath.substr(0, OverlayDirLen) == OverlayDir &&
 2049   assert(!(IsExternalFSCurrent && ExternalDirIter == directory_iterator()) &&
 2070   assert((IsFirstTime || Current != End) && "cannot iterate past end");
 2116   assert(FS && State && !State->Stack.empty() && "incrementing past end");
 2117   assert(!State->Stack.top()->path().empty() && "non-canonical end iterator");
lib/Support/YAMLParser.cpp
  796     assert(!TokenQueue.empty() &&
  952   assert(Current <= End && "Skipped past the end");
 1230     assert(i != e && "SimpleKey not in token queue!");
 1260   assert(Position - 1 >= First);
 1331   assert(Indent >= -1 && "Indent must be >= -1 !");
 1579   assert(*Current == '|' || *Current == '>');
 1924     assert(!UnquotedValue.empty() && "Can't be empty!");
lib/Support/YAMLTraits.cpp
   90       assert(Strm->failed() && "Root is NULL iff parsing failed");
  328     assert(BitValuesUsed.size() == SQ->Entries.size());
  353   assert(hnode && "HNode must not be NULL");
lib/Support/raw_ostream.cpp
   82   assert(OutBufCur == OutBufStart &&
  105   assert(((Mode == Unbuffered && !BufferStart && Size == 0) ||
  110   assert(GetNumBytesInBuffer() == 0 && "Current buffer is non-empty!");
  119   assert(OutBufStart <= OutBufEnd && "Invalid size!");
  216   assert(OutBufCur > OutBufStart && "Invalid call to flush_nonempty.");
  261       assert(NumBytes != 0 && "undefined behavior");
  286   assert(Size <= size_t(OutBufEnd - OutBufCur) && "Buffer overrun!");
  340     assert(BytesUsed > NextBufferSize && "Didn't grow buffer!?");
  452       assert(BlockCharWidth >= CharsPrinted);
  522   assert((Access & sys::fs::FA_Write) &&
  688   assert(FD >= 0 && "File already closed.");
  744   assert(ShouldClose);
  753   assert(SupportsSeeking && "Stream does not support seeking!");
  787   assert(FD >= 0 && "File not yet open!");
  876   assert(!EC);
lib/TableGen/JSONBackend.cpp
  117   assert(!I.isConcrete());
lib/TableGen/Record.cpp
   70   assert(RHS && "NULL pointer");
  183       assert(i == j || !Classes[i]->isSubClassOf(Classes[j]));
  185     assert(&Classes[0]->getRecords() == &Classes[i]->getRecords());
  441       assert(CachedBitVarResolved && "Unresolved bitvar reference");
  580   assert(Range.empty() || !isa<TypedInit>(Range[0]) ||
  638   assert(i < NumValues && "List element index out of range!");
  728         assert(CurRec && "NULL pointer");
  766       assert(!LHSl->empty() && "Empty list in head");
  773       assert(!LHSl->empty() && "Empty list in tail");
  869   assert(isa<ListRecTy>(LHS->getType()) && "First arg must be a list");
 1438     assert(!isa<TypedInit>(Converted) ||
 1750   assert(CondRange.size() == ValRange.size() &&
 1772   assert(CondRange.size() == ValRange.size() &&
 1886     assert(Name != NameRange.end() && "Arg name underflow!");
 1890   assert(Name == NameRange.end() && "Arg name overflow!");
 1989   assert(Value && "Cannot create unset value for current type!");
 2000       assert(!isa<TypedInit>(Value) ||
 2136       assert(RV && "Template argument record not found??");
lib/TableGen/StringMatcher.cpp
   30   assert(!Matches.empty());
   51   assert(!Matches.empty() && "Must have at least one string to match!");
lib/TableGen/TGLexer.h
  109     assert((CurCode == tgtok::Id || CurCode == tgtok::StrVal ||
  115     assert(CurCode == tgtok::IntVal && "This token isn't an integer");
  119     assert(CurCode == tgtok::BinaryIntVal &&
lib/TableGen/TGParser.cpp
  345   assert(!E.Rec || !E.Loop);
  459   assert(Rec->getTemplateArgs().empty() && "How'd this get template args?");
  865       assert(RV && "Template arg doesn't exist??");
  996           assert(LHSt && "expected list type argument in unary operator");
 2325     assert(RV && "Template argument record not found??");
 2350       assert(RV && "Template argument record not found??");
 2400       assert(CurMultiClass);
 2498     assert(!IterType && "Type already initialized?");
 2520   assert(Lex.getCode() == tgtok::less && "Not a template arg list!");
 2695   assert(Lex.getCode() == tgtok::Def && "Unknown tok");
 2721   assert(Lex.getCode() == tgtok::Defset);
 2771   assert(Lex.getCode() == tgtok::Foreach && "Unknown tok");
 2820   assert(Lex.getCode() == tgtok::Class && "Unexpected token!");
 2907   assert(Lex.getCode() == tgtok::Let && "Unexpected token");
 2957   assert(Lex.getCode() == tgtok::MultiClass && "Unexpected token");
 3040   assert(Lex.getCode() == tgtok::Defm && "Unexpected token!");
 3077     assert(MC && "Didn't lookup multiclass correctly?");
lib/TableGen/TableGenBackend.cpp
   24   assert((Prefix.str().size() + Suffix.size() <= MAX_LINE_LEN) &&
   39   assert(PSLen < MAX_LINE_LEN);
lib/Target/AArch64/AArch64A53Fix835769.cpp
  177     assert(I && "Expected instruction");
lib/Target/AArch64/AArch64A57FPLoadBalancing.cpp
  216     assert((KillInstIdx == 0 || LastInstIdx < KillInstIdx) &&
  237     assert((KillInstIdx == 0 || LastInstIdx < KillInstIdx) &&
  460     assert((G1 == G2 || (G1->startsBefore(G2) ^ G2->startsBefore(G1))) &&
  511   assert(ChainBegin != ChainEnd && "Chain should contain instructions");
  588   assert(Substs.size() == 0 && "No substitutions should be left active!");
lib/Target/AArch64/AArch64AdvSIMDScalarPass.cpp
  211     assert(std::next(Def) == MRI->def_instr_end() && "Multiple def in SSA!");
  224     assert(std::next(Def) == MRI->def_instr_end() && "Multiple def in SSA!");
  293   assert(OldOpc != NewOpc && "transform an instruction to itself?!");
  304     assert(std::next(Def) == MRI->def_instr_end() && "Multiple def in SSA!");
  314         assert(MOSrc0 && "Can't delete copy w/o a valid original source!");
  323     assert(std::next(Def) == MRI->def_instr_end() && "Multiple def in SSA!");
  333         assert(MOSrc1 && "Can't delete copy w/o a valid original source!");
lib/Target/AArch64/AArch64AsmPrinter.cpp
  268   assert(TT.isOSBinFormatELF());
  471       assert(LabelIt != LOHInstToLabel.end() &&
  506     assert(Register::isPhysicalRegister(Reg));
  507     assert(!MO.getSubReg() && "Subregs should be eliminated!");
  551   assert(MO.isReg() && "Should only get here with a register!");
  555   assert(RI->regsOverlap(RegToPrint, Reg));
  661   assert(MO.isReg() && "unexpected inline asm memory operand");
  669   assert(NOps == 4);
  676   assert(MI->getOperand(0).isReg() && MI->getOperand(1).isImm());
  798   assert(NumNOPBytes % 4 == 0 && "Invalid number of NOP bytes requested!");
  830     assert((CallTarget & 0xFFFFFFFFFFFF) == CallTarget &&
  853   assert(NumBytes >= EncodedBytes &&
  855   assert((NumBytes - EncodedBytes) % 4 == 0 &&
  870       assert(AArch64::D0 <= DestReg && DestReg <= AArch64::D31);
 1129     assert(MI->getOperand(0).getImm() < 0 &&
 1140     assert(MI->getOperand(1).getImm() < 0 &&
 1147     assert((MI->getOperand(1).getImm() - MI->getOperand(0).getImm() == 1) &&
 1154     assert((MI->getOperand(1).getImm() - MI->getOperand(0).getImm() == 1) &&
 1156     assert(MI->getOperand(2).getImm() < 0 &&
 1168     assert(MI->getOperand(1).getImm() < 0 &&
 1175     assert((MI->getOperand(1).getImm() - MI->getOperand(0).getImm() == 1) &&
 1182     assert((MI->getOperand(1).getImm() - MI->getOperand(0).getImm() == 1) &&
 1184     assert(MI->getOperand(2).getImm() < 0 &&
lib/Target/AArch64/AArch64BranchTargets.cpp
  117   assert(HintNum != 32 && "No target kinds!");
lib/Target/AArch64/AArch64CallLowering.cpp
  241   assert(OrigArg.Regs.size() == SplitVTs.size() && "Regs / types mismatch");
  261   assert(((Val && !VRegs.empty()) || (!Val && VRegs.empty())) &&
  277     assert(VRegs.size() == SplitEVTs.size() &&
  387   assert(F.isVarArg() && "Expected F to be vararg?");
  742   assert((!Info.IsVarArg || CalleeCC == CallingConv::C) &&
  860     assert(FPDiff % 16 == 0 && "unaligned stack on tail call");
lib/Target/AArch64/AArch64CallingConvention.cpp
  130     assert(EltsPerReg == 2 && "unexpected ABI");
lib/Target/AArch64/AArch64CollectLOH.cpp
  349   assert(OpInfo.IsCandidate && "Expect valid state");
  363     assert((MI.getOpcode() == AArch64::LDRXui ||
  366     assert((MI.getOperand(2).getTargetFlags() & AArch64II::MO_GOT) &&
  534           assert(Def.isReg() && Def.isDef() && "Expected reg def");
  535           assert(Op.isReg() && Op.isUse() && "Expected reg use");
lib/Target/AArch64/AArch64CompressJumpTables.cpp
  102     assert(BlockOffset % 4 == 0 && "misaligned basic block");
  110   assert(MinBlock && "Failed to find minimum offset block");
lib/Target/AArch64/AArch64CondBrTuning.cpp
  275   assert(NewCmp && NewBr && "Expected new instructions.");
lib/Target/AArch64/AArch64ConditionOptimizer.cpp
  162     assert(!I->isTerminator() && "Spurious terminator");
  307     assert(Cond.size() == 1 && "Unknown Cond array format");
lib/Target/AArch64/AArch64ConditionalCompares.cpp
  225         assert((!HeadReg || HeadReg == Reg) && "Inconsistent PHI operands");
  229         assert((!CmpBBReg || CmpBBReg == Reg) && "Inconsistent PHI operands");
  275     assert(Cond.size() == 1 && "Unknown Cond array format");
  287     assert(Cond.size() == 3 && "Unknown Cond array format");
  292     assert(Cond.size() == 3 && "Unknown Cond array format");
  320     assert(!I->isTerminator() && "Spurious terminator");
  525     assert(TBB == Tail && "Unexpected TBB");
  595     assert(*Head->succ_begin() == Tail && "Head successor is not Tail");
  828     assert(Node != HeadNode && "Cannot erase the head node");
  829     assert(Node->getIDom() == HeadNode && "CmpBB should be dominated by Head");
lib/Target/AArch64/AArch64DeadRegisterDefinitionsPass.cpp
  152       assert(!MO.isImplicit() && "Unexpected implicit def!");
lib/Target/AArch64/AArch64ExpandImm.cpp
   24   assert(ChunkIdx < 4 && "Out of range chunk index specified!");
  220   assert(FirstMovkIdx != NotSet && "Constant materializable with single ORR!");
  345   assert(BitSize == 64 && "All 32-bit immediates can be expanded with a"
lib/Target/AArch64/AArch64ExpandPseudoInsts.cpp
   98     assert(MO.isReg() && MO.getReg());
  124   assert(Insn.size() != 0);
  181   assert(!MI.getOperand(2).isUndef() && "cannot handle undef");
  261   assert(!MI.getOperand(3).isUndef() && "cannot handle undef");
  492         assert(MO1.isCPI() &&
  529         assert(MO1.isCPI() &&
lib/Target/AArch64/AArch64FalkorHWPFFix.cpp
  825   assert(TRI->trackLivenessAfterRegAlloc(Fn) &&
lib/Target/AArch64/AArch64FastISel.cpp
  110       assert(isRegBase() && "Invalid base register access!");
  115       assert(isRegBase() && "Invalid base register access!");
  128       assert(isFIBase() && "Invalid base frame index  access!");
  133       assert(isFIBase() && "Invalid base frame index access!");
  309   assert((isa<ZExtInst>(I) || isa<SExtInst>(I)) &&
  311   assert(!I->getType()->isVectorTy() && I->getType()->isIntegerTy() &&
  357   assert(TLI.getValueType(DL, AI->getType(), true) == MVT::i64 &&
  533     assert(CPN->getType()->getPointerAddressSpace() == 0 &&
  535     assert(VT == MVT::i64 && "Expected 64-bit pointers");
  550   assert(CFP->isNullValue() &&
  801     assert(isa<ConstantInt>(RHS) && "Expected an ConstantInt.");
 1137     assert(Addr.isRegBase() && "Unexpected address kind.");
 1145       assert(Addr.getOffset() == 0 && "Unexpected offset");
 1261       assert(isa<ConstantInt>(MulRHS) && "Expected a ConstantInt.");
 1318   assert(LHSReg && RHSReg && "Invalid register number.");
 1355   assert(LHSReg && "Invalid register number.");
 1403   assert(LHSReg && RHSReg && "Invalid register number.");
 1404   assert(LHSReg != AArch64::SP && LHSReg != AArch64::WSP &&
 1446   assert(LHSReg && RHSReg && "Invalid register number.");
 1447   assert(LHSReg != AArch64::XZR && LHSReg != AArch64::WZR &&
 1647       assert(isa<ConstantInt>(MulRHS) && "Expected a ConstantInt.");
 1904     assert(ANDReg && "Unexpected AND instruction emission failure.");
 2166     assert(ANDReg && "Unexpected AND instruction emission failure.");
 2301   assert(isa<CmpInst>(BI->getCondition()) && "Expected cmp instruction");
 2476       assert((CC != AArch64CC::AL) && "Unexpected condition code.");
 2640   assert((CC != AArch64CC::AL) && "Unexpected condition code.");
 2667       assert(CI->isZero());
 2679       assert(CI->isZero());
 2710   assert(isa<SelectInst>(I) && "Expected a select instruction.");
 2802     assert((CC != AArch64CC::AL) && "Unexpected condition code.");
 2913   assert((DestVT == MVT::f32 || DestVT == MVT::f64) &&
 3122       assert(VA.isMemLoc() && "Assuming store on stack.");
 3493       assert(DestReg && "Unexpected LDR instruction emission failure.");
 3766         assert(VT == MVT::i64 && "Unexpected value type.");
 3798         assert(VT == MVT::i64 && "Unexpected value type.");
 3825     assert((ResultReg1 + 1) == ResultReg2 &&
 3994     assert(ResultReg && "Unexpected AND instruction emission failure.");
 4007   assert((DestVT == MVT::i8 || DestVT == MVT::i16 || DestVT == MVT::i32 ||
 4016     assert(ResultReg && "Unexpected AND instruction emission failure.");
 4108   assert(RetVT.SimpleTy >= SrcVT.SimpleTy &&
 4110   assert((SrcVT == MVT::i1 || SrcVT == MVT::i8 || SrcVT == MVT::i16 ||
 4113   assert((RetVT == MVT::i8 || RetVT == MVT::i16 || RetVT == MVT::i32 ||
 4215   assert(RetVT.SimpleTy >= SrcVT.SimpleTy &&
 4217   assert((SrcVT == MVT::i1 || SrcVT == MVT::i8 || SrcVT == MVT::i16 ||
 4220   assert((RetVT == MVT::i8 || RetVT == MVT::i16 || RetVT == MVT::i32 ||
 4336   assert(RetVT.SimpleTy >= SrcVT.SimpleTy &&
 4338   assert((SrcVT == MVT::i1 || SrcVT == MVT::i8 || SrcVT == MVT::i16 ||
 4341   assert((RetVT == MVT::i8 || RetVT == MVT::i16 || RetVT == MVT::i32 ||
 4417   assert(DestVT != MVT::i1 && "ZeroExt/SignExt an i1?");
 4452     assert(DestVT == MVT::i64 && "IntExt i32 to i32?!?");
 4547     assert(LoadMI && "Expected valid instruction");
 4567     assert((MI->getOpcode() == TargetOpcode::COPY &&
 4579   assert((isa<ZExtInst>(I) || isa<SExtInst>(I)) &&
 4668   assert(QuotReg && "Unexpected DIV instruction emission failure.");
 5083   assert(TM.getOptLevel() == CodeGenOpt::None &&
 5088   assert(RetPairTy->getTypeAtIndex(1U)->isIntegerTy(1) &&
 5144   assert((ResultReg1 + 1) == ResultReg2 && "Nonconsecutive result registers.");
lib/Target/AArch64/AArch64FrameLowering.cpp
  305       assert(Amount > -0xffffff && Amount < 0xffffff && "call frame too large");
  312     assert(CalleePopAmount < 0xffffff && "call frame too large");
  335   assert(Scope.equals("non-leaf") && "Expected all, none or non-leaf");
  635       assert(MBBI->getOperand(0).getReg() != AArch64::SP);
  702   assert(MBBI->getOperand(OpndIdx).getImm() == 0 &&
  705   assert(MBBI->getOperand(OpndIdx - 1).getReg() == AArch64::SP &&
  707   assert(CSStackSizeInc % Scale == 0);
  739       assert(MI.getOperand(0).getReg() != AArch64::SP);
  766   assert(MI.getOperand(OffsetIdx - 1).getReg() == AArch64::SP &&
  771   assert(LocalStackSize % Scale == 0);
  777     assert(MBBI != MI.getParent()->end() && "Expecting a valid instruction");
  778     assert(AArch64InstrInfo::isSEHInstruction(*MBBI) &&
  823   assert(Key.equals_lower("a_key") || Key.equals_lower("b_key"));
  903     assert(!HasFP && "unexpected function without stack frame but with FP");
  904     assert(!SVEStackSize &&
  952     assert(!SVEStackSize && "Cannot combine SP bump with SVE");
  962   assert(NumBytes >= 0 && "Negative stack allocation size!?");
 1120       assert(scratchSPReg != AArch64::NoRegister);
 1135       assert(NrBitsToZero > 1);
 1136       assert(scratchSPReg != AArch64::SP);
 1465     assert(!SVEStackSize && "Cannot combine SP bump with SVE");
 1477   assert(NumBytes >= 0 && "Negative stack allocation size!?");
 1658       assert(hasFP(MF) && "Re-aligned stack must have frame pointer");
 1676           assert(!SVEStackSize && "Expected BP to be available");
 1692         assert(
 1704   assert(((isFixed || isCSR) || !RegInfo->needsStackRealignment(MF) || !UseFP) &&
 1744     assert(!MFI.hasVarSizedObjects() &&
 1841   assert((!produceCompactUnwindFrame(MF) ||
 1901     assert((!RPI.isPaired() ||
 1905     assert((!RPI.isPaired() || !NeedsFrameRecord || RPI.Reg2 != AArch64::FP ||
 1911     assert((!produceCompactUnwindFrame(MF) ||
 1929       assert(Offset % 16 == 0);
 1930       assert(MFI.getObjectAlignment(RPI.FrameIdx) <= 16);
 1934     assert(Offset % Scale == 0);
 1936     assert((RPI.Offset >= -64 && RPI.Offset <= 63) &&
 2035     assert((!NeedsWinCFI || !(Reg1 == AArch64::LR && Reg2 == AArch64::FP)) &&
 2255   assert(MaxAlign <= 16 && "Cannot align scalable vectors more than 16 bytes");
 2308   assert((!MFI.isCalleeSavedInfoValid() ||
 2345   assert(getStackGrowthDirection() == TargetFrameLowering::StackGrowsDown &&
 2353   assert(MaxAlign <= 16 && "Cannot align scalable vectors more than 16 bytes");
 2377   assert(DstReg && "There must be a free register after frame setup");
lib/Target/AArch64/AArch64GenRegisterBankInfo.def
  193   assert(RBIdx != PartialMappingIdx::PMI_None && "No mapping needed for that");
  201   assert(ValMappingIdx >= First3OpsIdx && ValMappingIdx <= Last3OpsIdx &&
  217   assert(DstBankID < AArch64::NumRegisterBanks && "Invalid bank ID");
  218   assert(SrcBankID < AArch64::NumRegisterBanks && "Invalid bank ID");
  221   assert(DstRBIdx != PMI_None && "No such mapping");
  222   assert(SrcRBIdx != PMI_None && "No such mapping");
  227   assert(Size <= 64 && "GPR cannot handle that size");
  232   assert(ValMappingIdx >= FirstCrossRegCpyIdx &&
  254     assert((DstSize == 32 || DstSize == 64) && "Unexpected half extension");
  261     assert(DstSize == 64 && "Unexpected float extension");
  264   assert((SrcSize == 64 || DstSize == 128) && "Unexpected vector extension");
lib/Target/AArch64/AArch64ISelDAGToDAG.cpp
  377   assert(V.getOpcode() == ISD::SHL && "invalid opcode");
  466     assert(SrcVT != MVT::i64 && "extend from 64-bits?");
  478     assert(SrcVT != MVT::i64 && "extend from 64-bits?");
  685   assert(Ext != AArch64_AM::UXTX && Ext != AArch64_AM::SXTX);
  887   assert(N.getOpcode() == ISD::SHL && "Invalid opcode.");
 1107   assert(Regs.size() >= 2 && Regs.size() <= 4);
 1539   assert(N->getOpcode() == ISD::AND &&
 1547   assert((VT == MVT::i32 || VT == MVT::i64) &&
 1629   assert(N->getOpcode() == ISD::SIGN_EXTEND_INREG);
 1633   assert((VT == MVT::i32 || VT == MVT::i64) &&
 1708   assert((N->getOpcode() == ISD::SRA || N->getOpcode() == ISD::SRL) &&
 1716   assert((VT == MVT::i32 || VT == MVT::i64) &&
 1737     assert(VT == MVT::i64 && "the promoted type should be i64");
 1759   assert(SrlImm > 0 && SrlImm < VT.getSizeInBits() &&
 1773   assert(N->getOpcode() == ISD::SIGN_EXTEND);
 1871   assert((VT == MVT::i32 || VT == MVT::i64) &&
 2121     assert(ShlAmount < 0 && "expected right shift");
 2140   assert(BitWidth == 32 || BitWidth == 64);
 2152     assert((~APInt(BitWidth, AndImm) & ~Known.Zero) == 0);
 2185   assert(VT == MVT::i32 || VT == MVT::i64);
 2194   assert(N->getOpcode() == ISD::OR && "Expect a OR operation");
 2283   assert(N->getOpcode() == ISD::OR && "Expect a OR operation");
 2356     assert((VT == MVT::i32 || VT == MVT::i64) && "unexpected OR operand");
 2554         assert(SubVT == MVT::i64);
 2649   assert(Fields.size() == 5
 2661   assert(AllIntFields &&
 2741     assert (isa<ConstantSDNode>(N->getOperand(2))
 2747       assert(Immed < 2 && "Bad imm");
 2750       assert(Immed < 16 && "Bad imm");
 2848   assert(isa<ConstantSDNode>(N->getOperand(3)) &&
lib/Target/AArch64/AArch64ISelLowering.cpp
  818   assert(VT.isVector() && "VT should be a vector type");
  982   assert(((OldImm ^ NewImm) & Demanded.getZExtValue()) == 0 &&
  984   assert(OldImm != NewImm && "the new imm shouldn't be equal to the old imm");
 1022   assert((Size == 32 || Size == 64) &&
 1105         assert(BitWidth >= 8 && "Unexpected width!");
 1109         assert(BitWidth >= 16 && "Unexpected width!");
 1383   assert(!isAsynchronousEHPersonality(classifyEHPersonality(
 1526     assert(CondCode2 == AArch64CC::AL);
 1609     assert(VT != MVT::f128);
 1710     assert(LHS.getValueType() != MVT::f128);
 1792       assert(Opcode == ISD::AND && "Must be OR or AND");
 1827       assert(LHS.getValueType().isFloatingPoint());
 1851   assert(Val->hasOneUse() && "Valid conjunction/disjunction tree");
 1859   assert(ValidL && "Valid conjunction/disjunction tree");
 1866   assert(ValidR && "Valid conjunction/disjunction tree");
 1871     assert(!MustBeFirstR && "Valid conjunction/disjunction tree");
 1884       assert(CanNegateR && "at least one side must be negatable");
 1885       assert(!MustBeFirstR && "invalid conjunction/disjunction tree");
 1886       assert(!Negate);
 1898     assert(Opcode == ISD::AND && "Valid conjunction/disjunction tree");
 1899     assert(!Negate && "Valid conjunction/disjunction tree");
 2103   assert((Op.getValueType() == MVT::i32 || Op.getValueType() == MVT::i64) &&
 2182     assert(Op.getValueType() == MVT::i64 && "Expected an i64 value type");
 2389     assert(Locality <= 3 && "Prefetch locality out-of-range");
 2407   assert(Op.getValueType() == MVT::f128 && "Unexpected lowering");
 2603   assert(Op.getOperand(0).getValueType() == MVT::i16);
 2618   assert(OrigVT.isSimple() && "Expecting a simple value type");
 2638   assert(ExtTy.is128BitVector() && "Unexpected extension size");
 2681   assert(N->getOpcode() == ISD::BUILD_VECTOR && "expected BUILD_VECTOR");
 2754   assert(VT.is128BitVector() && VT.isInteger() &&
 2801     assert(Op0.getValueType().is64BitVector() &&
 2900   assert(VT.isVector() && "VT should be a vector type");
 2901   assert(MemVT == MVT::v4i8 && VT == MVT::v4i16);
 2935   assert (StoreNode && "Can only custom lower store nodes");
 2942   assert (VT.isVector() && "Can only custom lower vector store types");
 3176     assert(!Res && "Call operand has unhandled type");
 3179   assert(ArgLocs.size() == Ins.size());
 3240         assert(VA.getValVT().isScalableVector() &&
 3257       assert(VA.isMemLoc() && "CCValAssign is neither reg nor mem");
 3283         assert(VA.getValVT().isScalableVector() &&
 3351         assert(!FuncInfo->getSRetReturnReg());
 3499       assert(!VA.needsCustom() && VA.getLocVT() == MVT::i64 &&
 3614   assert((!isVarArg || CalleeCC == CallingConv::C) &&
 3770       assert(!Res && "Call operand has unhandled type");
 3797       assert(!Res && "Call operand has unhandled type");
 3835     assert(FPDiff % 16 == 0 && "unaligned stack on tail call");
 3887       assert(VA.getValVT() == MVT::i32 && "only expect 32 -> 64 upper bits");
 3902       assert(VA.getValVT().isScalableVector() &&
 3910         assert(VA.getLocVT() == MVT::i64 &&
 3912         assert(!Ins.empty() && Ins[0].VT == MVT::i64 &&
 3944       assert(VA.isMemLoc());
 4031       assert(Subtarget->isTargetWindows() &&
 4110   assert(Mask && "Missing call preserved mask for calling convention");
 4183     assert(VA.isRegLoc() && "Can only return in registers!");
 4206       assert(VA.getValVT() == MVT::i32 && "only expect 32 -> 64 upper bits");
 4365     assert(cast<GlobalAddressSDNode>(Op)->getOffset() == 0 &&
 4421   assert(Subtarget->isTargetDarwin() &&
 4504   assert(Subtarget->isTargetELF() && "This function expects an ELF target");
 4604   assert(Subtarget->isTargetWindows() && "Windows specific TLS lowering");
 4727     assert((LHS.getValueType() == RHS.getValueType()) &&
 4791   assert(LHS.getValueType() == MVT::f16 || LHS.getValueType() == MVT::f32 ||
 4920   assert((VT == MVT::v1i64 || VT == MVT::v2i64 || VT == MVT::v2i32 ||
 4965       assert(LHS.getValueType() == Op.getValueType() &&
 4983   assert(LHS.getValueType() == MVT::f16 || LHS.getValueType() == MVT::f32 ||
 5041     assert((LHS.getValueType() == RHS.getValueType()) &&
 5142       assert (CTVal && CFVal && "Expected constant operands for CSNEG.");
 5160   assert(LHS.getValueType() == MVT::f16 || LHS.getValueType() == MVT::f32 ||
 5162   assert(LHS.getValueType() == RHS.getValueType());
 5441   assert(Subtarget->isTargetDarwin() &&
 5459     assert(((Align & (Align - 1)) == 0) && "Expected Align to be a power of 2");
 5597   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 5606   assert(Op.getOpcode() == ISD::SRA_PARTS || Op.getOpcode() == ISD::SRL_PARTS);
 5654   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 5662   assert(Op.getOpcode() == ISD::SHL_PARTS);
 6017       assert(VT.isScalableVector());
 6255   assert(Op.getOpcode() == ISD::BUILD_VECTOR && "Unknown opcode!");
 6349       assert(2 * SrcVT.getSizeInBits() == VT.getSizeInBits());
 6358     assert(SrcVT.getSizeInBits() == 2 * VT.getSizeInBits());
 6401     assert(ShuffleVT.getVectorElementType() == SmallestEltTy);
 6410                  assert(Src.ShuffleVec.getValueType() == ShuffleVT););
 6536   assert((BlockSize == 16 || BlockSize == 32 || BlockSize == 64) &&
 6775     assert(LHSID == ((4 * 9 + 5) * 9 + 6) * 9 + 7 && "Illegal OP_COPY!");
 6797     assert(VT.getVectorElementType() == MVT::i8);
 7471   assert(Op.getOpcode() == ISD::BUILD_VECTOR && "Unknown opcode!");
 7492       assert(Lane.getValueType() == MVT::i32 &&
 7718       assert ((EltTy == MVT::f16 || EltTy == MVT::f32 || EltTy == MVT::f64) &&
 7826   assert(Op.getOpcode() == ISD::INSERT_VECTOR_ELT && "Unknown opcode!");
 7860   assert(Op.getOpcode() == ISD::EXTRACT_VECTOR_ELT && "Unknown opcode!");
 7983   assert(VT.isVector() && "vector shift count is not a vector type");
 7994   assert(VT.isVector() && "vector shift count is not a vector type");
 8054   assert(VT.getSizeInBits() == SrcVT.getSizeInBits() &&
 8154     assert(LHS.getValueType() == RHS.getValueType());
 8177   assert((!FullFP16 && LHS.getValueType().getVectorElementType() != MVT::f16) ||
 8232     assert(Op->getFlags().hasNoNaNs() && "fmax vector reduction needs NoNaN flag");
 8239     assert(Op->getFlags().hasNoNaNs() && "fmin vector reduction needs NoNaN flag");
 8315   assert(Subtarget->isTargetWindows() &&
 8476   assert(Mem);
 8786   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
 8788   assert(!Shuffles.empty() && "Empty shufflevector input");
 8789   assert(Shuffles.size() == Indices.size() &&
 8914   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
 8918   assert(VecTy->getVectorNumElements() % Factor == 0 &&
 9236   assert(Ty->isIntegerTy());
 9463   assert(!(NegateResult && TrailingZeroes) &&
 9617   assert((ResTy != MVT::v4i64 || DCI.isBeforeLegalizeOps()) &&
 9734   assert(N->getOpcode() == ISD::OR && "Unexpected root");
10018     assert(VT.getScalarSizeInBits() == 64);
10082     assert(Vec.getValueSizeInBits() == 128 &&
10247   assert(Op && Op->getOpcode() == ISD::ADD && "Unexpected operation!");
10353   assert(LHS.getValueType().is64BitVector() &&
10606   assert(!(NumElements & 1) && "Splitting vector, but not in half!");
10626   assert(!St.isTruncatingStore() && "cannot split truncating vector store");
11412   assert(isa<ConstantSDNode>(CCVal) && "Expected a ConstantSDNode here!");
11429   assert(LHS.getValueType() == RHS.getValueType() &&
11550       assert(NewOpc == AArch64ISD::TBNZ);
11606   assert((N0.getValueType() == MVT::i1 || N0.getValueType() == MVT::i32) &&
11633   assert(DCI.isBeforeLegalize() ||
11989   assert(N->getValueType(0) == MVT::i128 &&
12090     assert(N->getValueType(0) == MVT::i128 && "unexpected illegal conversion");
12400     assert(Entry->getParent()->getFunction().hasFnAttribute(
lib/Target/AArch64/AArch64InstrInfo.cpp
  102     assert(NumBytes % 4 == 0 && "Invalid number of NOP bytes requested!");
  107     assert(NumBytes % 4 == 0 && "Invalid number of NOP bytes requested!");
  181   assert(Bits >= 3 && "max branch displacement must be enough to jump"
  392   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  489   assert(Opc && SrcOpNum && "Missing parameters");
  640   assert(RC && "Unsupported regclass");
  938   assert(MIa.mayLoadOrStore() && "MIa must be a load or store.");
  939   assert(MIb.mayLoadOrStore() && "MIb must be a load or store.");
  991   assert(MI.getNumOperands() >= 2 && "All AArch64 cmps should have 2 operands");
 1049   assert(MBB && "Can't get MachineBasicBlock here");
 1051   assert(MF && "Can't get MachineFunction here");
 1070     assert(MO.isReg() &&
 1153   assert(std::find_if(++To.getReverse(), To->getParent()->rend(),
 1184   assert(CmpInstr.getParent());
 1185   assert(MRI);
 1204     assert(succeeded && "Some operands reg class are incompatible!");
 1211   assert((CmpValue == 0 || CmpValue == 1) && "CmpValue must be 0 or 1!");
 1311     assert(Idx >= 2);
 1326     assert(Idx >= 1);
 1333   assert(CC != AArch64CC::Invalid);
 1397   assert(MI);
 1398   assert(sForm(*MI) != AArch64::INSTRUCTION_LIST_END);
 1399   assert(CmpInstr);
 1443   assert(MRI);
 1463   assert(succeeded && "Some operands reg class are incompatible!");
 1526     assert(!Subtarget.isTargetILP32() && "how can large exist in ILP32?");
 1583       assert(MI.getDesc().getNumOperands() == 3 &&
 1612       assert(MI.getDesc().getNumOperands() == 4 &&
 1619       assert(MI.getDesc().getNumOperands() == 4 &&
 1642       assert(MI.getDesc().getNumOperands() == 3 && MI.getOperand(0).isReg() &&
 1933   assert((MI.getOperand(1).isReg() || MI.getOperand(1).isFI()) &&
 1991   assert(LdSt.mayLoadOrStore() && "Expected a memory operation.");
 2023     assert(LdSt.getNumExplicitOperands() == 4 && "invalid number of operands");
 2028   assert((BaseOp->isReg() || BaseOp->isFI()) &&
 2037   assert(LdSt.mayLoadOrStore() && "Expected a memory operation.");
 2039   assert(OfsOp.isImm() && "Offset operand wasn't immediate.");
 2307     assert(ObjectOffset1 <= ObjectOffset2 && "Object offsets are not ordered.");
 2334   assert((BaseOp1.isReg() || BaseOp1.isFI()) &&
 2376     assert((!BaseOp1.isIdenticalTo(BaseOp2) || Offset1 >= Offset2) &&
 2385   assert((!BaseOp1.isIdenticalTo(BaseOp2) || Offset1 <= Offset2) &&
 2416   assert(Subtarget.hasNEON() && "Unexpected register copy without NEON");
 2449   assert(DestEncoding % NumRegs == 0 && SrcEncoding % NumRegs == 0 &&
 2525     assert(Subtarget.hasSVE() && "Unexpected SVE register.");
 2536     assert(Subtarget.hasSVE() && "Unexpected SVE register.");
 2763     assert(AArch64::GPR64RegClass.contains(SrcReg) && "Invalid NZCV copy");
 2772     assert(AArch64::GPR64RegClass.contains(DestReg) && "Invalid NZCV copy");
 2833         assert(SrcReg != AArch64::WSP);
 2843         assert(SrcReg != AArch64::SP);
 2857       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2869       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2876       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2880       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2887       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2894       assert(Subtarget.hasNEON() && "Unexpected register store without NEON");
 2900   assert(Opc && "Unknown register class");
 2964         assert(DestReg != AArch64::WSP);
 2974         assert(DestReg != AArch64::SP);
 2988       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3000       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3007       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3011       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3018       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3025       assert(Subtarget.hasNEON() && "Unexpected register load without NEON");
 3031   assert(Opc && "Unknown register class");
 3094     assert((ThisVal >> ShiftSize) <= MaxEncoding &&
 3105       assert(Sign == 1 && "SEH directives should always have a positive sign");
 3117         assert((Offset - Imm) == 0 && "Expected remaining offset to be zero to "
 3122         assert(SrcReg == AArch64::SP && "Unexpected SrcReg for SEH_StackAlloc");
 3147     assert((DestReg != AArch64::SP || Bytes % 16 == 0) &&
 3159   assert(!(SetNZCV && (NumPredicateVectors || NumDataVectors)) &&
 3161   assert(!(NeedsWinCFI && (NumPredicateVectors || NumDataVectors)) &&
 3171     assert(DestReg != AArch64::SP && "Unaligned access to SP");
 3251       assert(TRI.getRegSizeInBits(*getRegClass(DstReg)) ==
 3273       assert(SrcMO.getSubReg() == 0 &&
 3337         assert(TRI.getRegSizeInBits(*getRegClass(SrcReg)) ==
 3343         assert(LoadDst.getSubReg() == 0 && "unexpected subreg on fill load");
 3429   assert(!(Remainder && useUnscaledOp) &&
 3432   assert(MinOff < MaxOff && "Unexpected Min/Max offsets");
 3610     assert(MI->getNumOperands() >= 4 && MI->getOperand(0).isReg() &&
 3699     assert(Root.getOperand(1).isReg() && Root.getOperand(2).isReg() &&
 3756     assert(false && "Unsupported FP instruction in combiner\n");
 3759     assert(Root.getOperand(1).isReg() && Root.getOperand(2).isReg() &&
 3766     assert(Root.getOperand(1).isReg() && Root.getOperand(2).isReg() &&
 3989   assert(IdxMulOpd == 1 || IdxMulOpd == 2);
 4037     assert(false && "Invalid FMA instruction kind \n");
 4067   assert(IdxMulOpd == 1 || IdxMulOpd == 2);
 4782   assert(MI.getParent() && "Incomplete machine instruciton\n");
 4826     assert(!MRI->def_empty(NewReg) && "Register must be defined.");
 5020   assert(C.LRUWasSet && "LRU wasn't set?");
 5309   assert(MBB.getParent()->getRegInfo().tracksLiveness() &&
 5519     assert(StackOffsetOperand.isImm() && "Stack offset wasn't immediate!");
 5521     assert(Scale != 0 && "Unexpected opcode!");
 5542       assert(Call->getOpcode() == AArch64::BLR);
 5559     assert(OF.FrameConstructionID != MachineOutlinerDefault &&
 5662     assert(Reg != 0 && "No callee-saved register available?");
lib/Target/AArch64/AArch64InstructionSelector.cpp
  565   assert(
  577   assert((DstSize <= 64 || DstBank.getID() == AArch64::FPRRegBankID) &&
  674     assert((I.isCopy() ||
  678     assert(KnownValid || isValidCopy(I, DstRegBank, MRI, TRI, RBI));
  703       assert(SubregRC && "Didn't get a register class for subreg?");
 1011   assert(I.getOpcode() == TargetOpcode::G_SHL);
 1041   assert(I.getOpcode() == TargetOpcode::G_ASHR);
 1175     assert(!ShiftTy.isVector() && "unexpected vector shift ty");
 1179     assert(AmtMI && "could not find a vreg definition for shift amount");
 1203   assert(I.getOpcode() == TargetOpcode::G_SHL && "unexpected op");
 1235   assert(I.getOpcode() == TargetOpcode::G_STORE && "Expected G_STORE");
 1276   assert(I.getParent() && "Instruction should be in a basic block!");
 1277   assert(I.getParent()->getParent() && "Instruction should be in a function!");
 1317   assert(I.getParent() && "Instruction should be in a basic block!");
 1318   assert(I.getParent()->getParent() && "Instruction should be in a function!");
 1478     assert(Opc != 0 && "Didn't get an opcode for G_BSWAP?");
 1598       assert(SrcRB.getID() == AArch64::FPRRegBankID &&
 1623       assert(SrcSize == 32 && DstTy.getSizeInBits() == 16 &&
 1655       assert(DstSize == 32 && SrcTy.getSizeInBits() == 16 &&
 1748     assert(PtrRB.getID() == AArch64::GPRRegBankID &&
 1750     assert(MRI.getType(PtrReg).isPointer() &&
 2071     assert((*RBI.getRegBank(DefReg, MRI, TRI)).getID() ==
 2334   assert(I.getOpcode() == TargetOpcode::G_BRJT && "Expected G_BRJT");
 2354   assert(I.getOpcode() == TargetOpcode::G_JUMP_TABLE && "Expected jump table");
 2355   assert(I.getOperand(1).isJTI() && "Jump table op should have a JTI!");
 2711   assert(I.getOpcode() == TargetOpcode::G_MERGE_VALUES && "unexpected opcode");
 2714   assert(!DstTy.isVector() && !SrcTy.isVector() && "invalid merge operation");
 2866   assert(I.getOpcode() == TargetOpcode::G_EXTRACT_VECTOR_ELT &&
 2873   assert(WideTy.getSizeInBits() >= NarrowTy.getSizeInBits() &&
 2875   assert(NarrowTy.isScalar() && "cannot extract vector into vector!");
 2879   assert(LaneIdxOp.isReg() && "Lane index operand was not a register?");
 2911   assert(NarrowTy.isVector() && "Expected an unmerge into vectors");
 2936   assert(I.getOpcode() == TargetOpcode::G_UNMERGE_VALUES &&
 2956   assert((WideTy.isVector() || WideTy.getSizeInBits() == 128) &&
 2958   assert(WideTy.getSizeInBits() > NarrowTy.getSizeInBits() &&
 3051   assert(I.getOpcode() == TargetOpcode::G_CONCAT_VECTORS &&
 3148   assert(LHS.isReg() && RHS.isReg() && "Expected LHS and RHS to be registers!");
 3172   assert(LHS.isReg() && RHS.isReg() && "Expected LHS and RHS to be registers!");
 3226   assert(LHS.isReg() && RHS.isReg() && "Expected LHS and RHS to be registers!");
 3240   assert((CmpTy.isScalar() || CmpTy.isPointer()) &&
 3287   assert(Op1Ty.isVector() && "Expected a vector for vector concat");
 3333   assert(I.getOpcode() == TargetOpcode::G_FCONSTANT &&
 3478   assert(LHS.isReg() && RHS.isReg() && Predicate.isPredicate() &&
 3697     assert(DstTy.getSizeInBits() == 64 && "Unexpected shuffle result ty");
 3775   assert(I.getOpcode() == TargetOpcode::G_INSERT_VECTOR_ELT);
 3851   assert(I.getOpcode() == TargetOpcode::G_BUILD_VECTOR);
 3916     assert(PrevMI && "PrevMI was null?");
 4503     assert(Size != 64 && "Extend from 64 bits?");
 4518     assert(Size != 64 && "Extend from 64 bits?");
 4638   assert(MI.getOpcode() == TargetOpcode::G_CONSTANT && "Expected G_CONSTANT");
 4640   assert(CstVal && "Expected constant value");
 4646   assert(I.getOpcode() == TargetOpcode::G_CONSTANT && "Expected G_CONSTANT");
 4654   assert(I.getOpcode() == TargetOpcode::G_CONSTANT && "Expected G_CONSTANT");
 4664   assert(MI.hasOneMemOperand() &&
lib/Target/AArch64/AArch64LegalizerInfo.cpp
  662   assert(MI.getOpcode() == TargetOpcode::G_ASHR ||
  669   assert(CstMI && "expected to find a vreg def");
  676   assert(MRI.getType(AmtReg).getSizeInBits() == 32);
  686   assert(MI.getOpcode() == TargetOpcode::G_STORE ||
lib/Target/AArch64/AArch64LoadStoreOptimizer.cpp
  604   assert(PairedRegOp < 2 && "Unexpected register operand idx.");
  622   assert(isMatchingStore(LoadInst, StoreInst) && "Expect only matched ld/st.");
  720   assert(isPromotableZeroStoreInst(*I) && isPromotableZeroStoreInst(*MergeMI) &&
  756     assert(((OffsetImm & 1) == 0) && "Unexpected offset to merge");
  825       assert(!(PairedOffset % getMemScale(*Paired)) &&
  850     assert(!(OffsetImm % getMemScale(*RtMI)) &&
  954   assert((IsStoreXReg ||
  990     assert(IsUnscaled == TII->isUnscaledLdSt(*StoreI) &&
  992     assert(LoadSize <= StoreSize && "Invalid load size");
 1005     assert((UnscaledLdOffset >= UnscaledStOffset &&
 1171   assert(!FirstMI.hasOrderedMemoryRef() &&
 1185   assert(IsValidLdStrOpc &&
 1248       assert(MI.mayLoadOrStore() && "Expected memory operation.");
 1376   assert((Update->getOpcode() == AArch64::ADDXri ||
 1387   assert(AArch64_AM::getShiftValue(Update->getOperand(3).getImm()) == 0 &&
 1630   assert(isPromotableZeroStoreInst(*MBBI) && "Expected narrow store.");
lib/Target/AArch64/AArch64MCInstLower.cpp
   44   assert(TheTriple.isOSWindows() &&
  130       assert(MO.isSymbol() &&
  234   assert(RefKind != AArch64MCExpr::VK_INVALID &&
  248   assert(Printer.TM.getTargetTriple().isOSBinFormatELF() && "Invalid target");
lib/Target/AArch64/AArch64MachineFunctionInfo.h
  192       assert(MFI.isCalleeSavedInfoValid() && "CalleeSavedInfo not calculated");
  207       assert((!HasCalleeSavedStackSize || getCalleeSavedStackSize() == Size) &&
  216     assert(HasCalleeSavedStackSize &&
  276       assert(isValidMCLOHType(Kind) && "Invalid LOH directive type!");
lib/Target/AArch64/AArch64PBQPRegAlloc.cpp
  150   assert(isFPReg(reg1) && "Expecting an FP register for reg1");
  151   assert(isFPReg(reg2) && "Expecting an FP register for reg2");
  278       assert(edge != G.invalidEdgeId() &&
lib/Target/AArch64/AArch64PromoteConstant.cpp
  425       assert(CommonDominator != CurBB &&
  470   assert(PC.ShouldConvert &&
  491   assert(!InsertPts.empty() && "Empty uses does not need a definition");
  506       assert(DT.dominates(LoadedCst,
lib/Target/AArch64/AArch64RedundantCopyElimination.cpp
  156   assert(PredMBB == CondBr.getParent() &&
lib/Target/AArch64/AArch64RegisterBankInfo.cpp
   53   assert(&AArch64::GPRRegBank == &RBGPR &&
   58   assert(&AArch64::FPRRegBank == &RBFPR &&
   63   assert(&AArch64::CCRegBank == &RBCCR && "The order in RegBanks is messed up");
   67   assert(RBGPR.covers(*TRI.getRegClass(AArch64::GPR32RegClassID)) &&
   69   assert(RBGPR.getSize() == 64 && "GPRs should hold up to 64-bit");
   73   assert(RBFPR.covers(*TRI.getRegClass(AArch64::QQRegClassID)) &&
   75   assert(RBFPR.covers(*TRI.getRegClass(AArch64::FPR64RegClassID)) &&
   77   assert(RBFPR.getSize() == 512 &&
   80   assert(RBCCR.covers(*TRI.getRegClass(AArch64::CCRRegClassID)) &&
   82   assert(RBCCR.getSize() == 32 && "CCR should hold up to 32-bit");
   86   assert(checkPartialMappingIdx(PMI_FirstGPR, PMI_LastGPR,
   89   assert(checkPartialMappingIdx(PMI_FirstFPR, PMI_LastFPR,
  102   CHECK_PARTIALMAP(PMI_GPR32, 0, 32, RBGPR);
  103   CHECK_PARTIALMAP(PMI_GPR64, 0, 64, RBGPR);
  104   CHECK_PARTIALMAP(PMI_FPR16, 0, 16, RBFPR);
  105   CHECK_PARTIALMAP(PMI_FPR32, 0, 32, RBFPR);
  106   CHECK_PARTIALMAP(PMI_FPR64, 0, 64, RBFPR);
  107   CHECK_PARTIALMAP(PMI_FPR128, 0, 128, RBFPR);
  108   CHECK_PARTIALMAP(PMI_FPR256, 0, 256, RBFPR);
  109   CHECK_PARTIALMAP(PMI_FPR512, 0, 512, RBFPR);
  122   CHECK_VALUEMAP(GPR, 32);
  123   CHECK_VALUEMAP(GPR, 64);
  124   CHECK_VALUEMAP(FPR, 16);
  125   CHECK_VALUEMAP(FPR, 32);
  126   CHECK_VALUEMAP(FPR, 64);
  127   CHECK_VALUEMAP(FPR, 128);
  128   CHECK_VALUEMAP(FPR, 256);
  129   CHECK_VALUEMAP(FPR, 512);
  140   CHECK_VALUEMAP_3OPS(GPR, 32);
  141   CHECK_VALUEMAP_3OPS(GPR, 64);
  142   CHECK_VALUEMAP_3OPS(FPR, 32);
  143   CHECK_VALUEMAP_3OPS(FPR, 64);
  144   CHECK_VALUEMAP_3OPS(FPR, 128);
  145   CHECK_VALUEMAP_3OPS(FPR, 256);
  146   CHECK_VALUEMAP_3OPS(FPR, 512);
  201   assert(verify(TRI) && "Invalid register bank information");
  376     assert((OpdMapper.getInstrMapping().getID() >= 1 &&
  425   assert(NumOperands <= 3 &&
  445     assert(
  452     assert(IsFPR == OpIsFPR && "Operand has incompatible type");
  581       assert(DstRB && SrcRB && "Both RegBank were nullptr");
lib/Target/AArch64/AArch64RegisterInfo.cpp
   45   assert(MF && "Invalid MachineFunction pointer.");
   76   assert(MF && "Invalid MachineFunction pointer.");
  147   assert(TT.isOSBinFormatELF() && "Invalid target");
  185   assert(CC != CallingConv::GHC && "should not be GHC calling convention.");
  217   assert(checkAllSuperRegsMarked(Reserved));
  337     assert(i < MI->getNumOperands() &&
  397   assert(Offset <= INT_MAX && "Offset too big to fit in int.");
  398   assert(MI && "Unable to get the legal offset for nil instruction.");
  436     assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
  442   assert(Done && "Unable to resolve frame index!");
  449   assert(SPAdj == 0 && "Unexpected");
  526   assert((!RS || !RS->isScavengingFrameIndex(FrameIndex)) &&
lib/Target/AArch64/AArch64SIMDInstrOpt.cpp
  633   assert (DefiningMI != NULL);
lib/Target/AArch64/AArch64SelectionDAGInfo.cpp
  116   assert(ObjSize % 16 == 0);
lib/Target/AArch64/AArch64SpeculationHardening.cpp
  200   assert(TBB != nullptr);
  210   assert(MBB.succ_size() == 2);
  212   assert(analyzeBranchCondCode.size() == 1 && "unknown Cond array format");
  261     assert(SplitEdgeTBB != nullptr);
  262     assert(SplitEdgeFBB != nullptr);
  331       assert(MI_Reg.second != 0);
  342       assert(MI_Reg.second != 0);
  433   assert(AArch64::GPR32allRegClass.contains(Reg) ||
  592   assert(!UseControlFlowSpeculationBarrier && "No need to insert CSDBs when "
lib/Target/AArch64/AArch64StackOffset.h
   48     assert(MVT(T).getSizeInBits() % 8 == 0 &&
  109     assert(isValid() && "Invalid frame offset");
lib/Target/AArch64/AArch64StackTagging.cpp
  450   assert(PrologueBB);
  571     assert(Info.AI);
lib/Target/AArch64/AArch64StackTaggingPreRA.cpp
  184   assert(MRI->isSSA());
  197         assert(I.getOperand(2).getImm() == 0);
lib/Target/AArch64/AArch64TargetObjectFile.cpp
   64   assert((Offset+MV.getConstant() == 0) &&
lib/Target/AArch64/AArch64TargetTransformInfo.cpp
   60   assert(Ty->isIntegerTy());
   85   assert(Ty->isIntegerTy());
  151   assert(Ty->isIntegerTy());
  191   assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2");
  265   assert(ISD && "Invalid opcode");
  403   assert((Opcode == Instruction::SExt || Opcode == Instruction::ZExt) &&
  411   assert(isa<IntegerType>(Dst) && isa<IntegerType>(Src) && "Invalid type");
  455   assert(Val->isVectorTy() && "This must be a vector type");
  679   assert(Factor >= 2 && "Invalid interleave factor");
  680   assert(isa<VectorType>(VecTy) && "Expect a vector type");
  897   assert(isa<VectorType>(Ty) && "Expected Ty to be a vector type");
  929   assert(ISD && "Invalid opcode");
lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp
  100         assert(Prefix.ElementSize != AArch64::ElementSizeNone &&
  112         assert(Prefix.ElementSize != AArch64::ElementSizeNone &&
  128       assert(Predicated);
  133       assert(Predicated);
  490     assert(Kind == k_Token && "Invalid access!");
  495     assert(Kind == k_Token && "Invalid access!");
  500     assert(Kind == k_Immediate && "Invalid access!");
  505     assert(Kind == k_ShiftedImm && "Invalid access!");
  510     assert(Kind == k_ShiftedImm && "Invalid access!");
  515     assert(Kind == k_CondCode && "Invalid access!");
  520     assert (Kind == k_FPImm && "Invalid access!");
  525     assert (Kind == k_FPImm && "Invalid access!");
  530     assert(Kind == k_Barrier && "Invalid access!");
  535     assert(Kind == k_Barrier && "Invalid access!");
  540     assert(Kind == k_Register && "Invalid access!");
  545     assert(Kind == k_Register && "Invalid access!");
  550     assert(Kind == k_VectorList && "Invalid access!");
  555     assert(Kind == k_VectorList && "Invalid access!");
  560     assert(Kind == k_VectorIndex && "Invalid access!");
  565     assert(Kind == k_SysReg && "Invalid access!");
  570     assert(Kind == k_SysCR && "Invalid access!");
  575     assert(Kind == k_Prefetch && "Invalid access!");
  580     assert(Kind == k_PSBHint && "Invalid access!");
  585     assert(Kind == k_PSBHint && "Invalid access!");
  590     assert(Kind == k_BTIHint && "Invalid access!");
  595     assert(Kind == k_BTIHint && "Invalid access!");
  600     assert(Kind == k_Prefetch && "Invalid access!");
  911     assert(N > 0 && "Branch target immediate cannot be 0 bits!");
 1220       assert(Desc && "Unknown enum value");
 1425     assert(N == 1 && "Invalid number of operands!");
 1430     assert(N == 1 && "Invalid number of operands!");
 1431     assert(
 1442     assert(N == 1 && "Invalid number of operands!");
 1443     assert(
 1469     assert(N == 1 && "Invalid number of operands!");
 1470     assert(
 1476     assert(N == 1 && "Invalid number of operands!");
 1477     assert(
 1483     assert(N == 1 && "Invalid number of operands!");
 1495     assert(N == 1 && "Invalid number of operands!");
 1508     assert((RegTy != VecListIdx_ZReg || NumRegs <= 4) &&
 1517     assert(N == 1 && "Invalid number of operands!");
 1523     assert(N == 1 && "Invalid number of operands!");
 1524     assert(bool(isExactFPImm<ImmIs0, ImmIs1>()) && "Invalid operand");
 1529     assert(N == 1 && "Invalid number of operands!");
 1538     assert(N == 2 && "Invalid number of operands!");
 1553     assert(N == 2 && "Invalid number of operands!");
 1562     assert(N == 1 && "Invalid number of operands!");
 1567     assert(N == 1 && "Invalid number of operands!");
 1581     assert(N == 1 && "Invalid number of operands!");
 1592     assert(N == 1 && "Invalid number of operands!");
 1599     assert(N == 1 && "Invalid number of operands!");
 1606     assert(N == 1 && "Invalid number of operands!");
 1615     assert(N == 1 && "Invalid number of operands!");
 1623     assert(N == 1 && "Invalid number of operands!");
 1633     assert(N == 1 && "Invalid number of operands!");
 1639     assert(MCE && "Invalid constant immediate operand!");
 1647     assert(N == 1 && "Invalid number of operands!");
 1653     assert(MCE && "Invalid constant immediate operand!");
 1661     assert(N == 1 && "Invalid number of operands!");
 1667     assert(MCE && "Invalid constant immediate operand!");
 1672     assert(N == 1 && "Invalid number of operands!");
 1678     assert(N == 1 && "Invalid number of operands!");
 1683     assert(N == 1 && "Invalid number of operands!");
 1689     assert(N == 1 && "Invalid number of operands!");
 1695     assert(N == 1 && "Invalid number of operands!");
 1701     assert(N == 1 && "Invalid number of operands!");
 1707     assert(N == 1 && "Invalid number of operands!");
 1712     assert(N == 1 && "Invalid number of operands!");
 1717     assert(N == 1 && "Invalid number of operands!");
 1722     assert(N == 1 && "Invalid number of operands!");
 1727     assert(N == 1 && "Invalid number of operands!");
 1734     assert(N == 1 && "Invalid number of operands!");
 1742     assert(N == 1 && "Invalid number of operands!");
 1750     assert(N == 2 && "Invalid number of operands!");
 1762     assert(N == 2 && "Invalid number of operands!");
 1771     assert(N == 1 && "Invalid number of operands!");
 1780     assert(N == 1 && "Invalid number of operands!");
 1788     assert(N == 1 && "Invalid number of operands!");
 1794     assert(N == 1 && "Invalid number of operands!");
 1837     assert((Kind == RegKind::NeonVector || Kind == RegKind::SVEDataVector ||
 2711   assert(Tok.is(AsmToken::Identifier) && "Token is not an Identifier");
 2951     assert(PRCTX_Op2 && "Invalid mnemonic for prediction restriction instruction");
 3723   assert(AOp1.isScalarReg() && AOp2.isScalarReg() &&
 3876   assert((ZReg >= AArch64::Z0) && (ZReg <= AArch64::Z31));
 4494   assert(!Operands.empty() && "Unexpect empty operand list!");
 4496   assert(Op.isToken() && "Leading operand should always be a mnemonic!");
 4825     assert(MissingFeatures.any() && "Unknown missing feature!");
 5343   assert(NbArgs != -1 && "Invalid number of arguments");
 5747     assert(Pattern >= 0 && Pattern < 32);
lib/Target/AArch64/MCTargetDesc/AArch64AddressingModes.h
  100   assert((Imm & 0x3f) == Imm && "Illegal shifted immedate value!");
  124   assert((Imm & 0x7) == Imm && "invalid immediate!");
  172   assert((Imm & 0x7) == Imm && "Illegal shifted immedate value!");
  240     assert(I < 64 && "undefined behavior");
  255   assert(Size > I && "I should be smaller than element size");
  285   assert(res && "invalid logical immediate");
  299   assert((regSize == 64 || N == 0) && "undefined logical immediate encoding");
  301   assert(len >= 0 && "undefined logical immediate encoding");
  305   assert(S != size - 1 && "undefined logical immediate encoding");
lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
   74     assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  165     assert(!IsResolved);
  386   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
  400     assert((Offset + FulleSizeInBytes) <= Data.size() && "Invalid fixup size!");
  401     assert(NumBytes <= FulleSizeInBytes && "Invalid fixup size!");
  585         assert(XReg == AArch64::FP && "Invalid frame pointer!");
  586         assert(i + 2 < e && "Insufficient CFI instructions to define a frame!");
  589         assert(LRPush.getOperation() == MCCFIInstruction::OpOffset &&
  592         assert(FPPush.getOperation() == MCCFIInstruction::OpOffset &&
  601         assert(LRReg == AArch64::LR && FPReg == AArch64::FP &&
  610         assert(StackSize == 0 && "We already have the CFA offset!");
  743   assert(TheTriple.isOSBinFormatELF() && "Invalid target");
  756   assert(TheTriple.isOSBinFormatELF() &&
lib/Target/AArch64/MCTargetDesc/AArch64ELFObjectWriter.cpp
  114   assert((!Target.getSymA() ||
  118   assert((!Target.getSymB() ||
lib/Target/AArch64/MCTargetDesc/AArch64InstPrinter.cpp
  742         assert(LdStDesc->NaturalOffset && "no offset on post-inc instruction?");
  759   assert(Opcode == AArch64::SYSxt && "Invalid opcode for SYS alias!");
  877     assert(Op.isExpr() && "unknown operand kind in printOperand");
  913   assert(Op.isReg() && "Non-register vreg operand!");
  922   assert(Op.isImm() && "System instruction C[nm] operands must be immediates!");
  932     assert(Val == MO.getImm() && "Add/sub immediate out of range!");
  942     assert(MO.isExpr() && "Unexpected operand type!");
 1041     assert(Suffix == 0 && "Unsupported suffix size");
 1083     assert(MO.isExpr() && "Unexpected operand type!");
 1095     assert(MO1.isExpr() && "Unexpected operand type!");
 1517   assert(AArch64_AM::getShiftType(Shift) == AArch64_AM::LSL &&
lib/Target/AArch64/MCTargetDesc/AArch64MCCodeEmitter.cpp
  207   assert(MO.isImm() && "did not expect relocated expression");
  221     assert(MO.isExpr() && "unable to encode load/store imm operand");
  241   assert(MO.isExpr() && "Unexpected target type!");
  265   assert(AArch64_AM::getShiftType(MO1.getImm()) == AArch64_AM::LSL &&
  268   assert((ShiftVal == 0 || ShiftVal == 12) &&
  272   assert(MO.isExpr() && "Unable to encode MCOperand!");
  303   assert(MO.isExpr() && "Unexpected target type!");
  325   assert(MO.isExpr() && "Unexpected target type!");
  353   assert(MO.isExpr() && "Unexpected movz/movk immediate");
  373   assert(MO.isExpr() && "Unexpected ADR target type!");
  395   assert(MO.isExpr() && "Unexpected ADR target type!");
  419   assert(MO.isImm() && "Expected an immediate value for the shift amount!");
  443   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  452   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  461   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  470   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  479   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  488   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  497   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  506   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  515   assert(MO.isImm() && "Expected an immediate value for the scale amount!");
  525   assert(AArch64_AM::getShiftType(ShiftOpnd) == AArch64_AM::LSL &&
  529   assert((ShiftVal == 0 || ShiftVal == 8) &&
  542   assert(MO.isImm() && "Expected an immediate value!");
  553   assert(MO.isImm() &&
  556   assert((ShiftVal == 8 || ShiftVal == 16) && "Invalid shift amount!");
lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
  251     assert(TheTriple.isOSBinFormatELF() && "Invalid target");
lib/Target/AArch64/MCTargetDesc/AArch64MachObjectWriter.cpp
  325     assert(!Symbol->isVariable() || Base);
  376     assert((Value & 0xff000000) == 0 && "Added relocation out of range!");
lib/Target/AArch64/MCTargetDesc/AArch64WinCOFFStreamer.cpp
   98   assert(Offset >= 0 && Offset <= 504 &&
  120   assert(Offset >= 0 && Offset <= 504 &&
  145   assert(Offset <= 2040 && "UOP_AddFP must have offset <= 2040");
lib/Target/AArch64/Utils/AArch64BaseInfo.cpp
  148   assert(Bits < 0x10000);
lib/Target/AMDGPU/AMDGPUArgumentUsageInfo.h
   72     assert(!IsStack);
   77     assert(IsStack);
  181       assert(F.isDeclaration());
lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
  174     assert(Success && "Malformed HSA Metadata");
  407   assert(isUInt<32>(PI.ScratchSize));
  408   assert(isUInt<32>(PI.ComputePGMRSrc1));
  409   assert(isUInt<32>(PI.ComputePGMRSrc2));
  446     assert(I.second && "should only be called once per function");
  725           assert(MI.isDebugInstr());
  769           assert(!AMDGPU::TTMP_32RegClass.contains(Reg) &&
  781           assert(!AMDGPU::TTMP_64RegClass.contains(Reg) &&
  798           assert(!AMDGPU::TTMP_128RegClass.contains(Reg) &&
  810           assert(!AMDGPU::TTMP_256RegClass.contains(Reg) &&
  818           assert(!AMDGPU::TTMP_512RegClass.contains(Reg) &&
 1218   assert(F.getCallingConv() == CallingConv::AMDGPU_KERNEL ||
lib/Target/AMDGPU/AMDGPUCallLowering.cpp
  166   assert(OrigArg.Regs.size() == SplitVTs.size());
  223   assert(DstRegs.size() > 1 && "Nothing to unpack");
  300   assert(!Val == VRegs.empty() && "Return value without a vreg");
  501     assert(LLTy.getElementType() == PartLLT.getElementType());
  509       assert(PartElts == 2 && DstElts % 2 != 0);
  520   assert(LLTy.isVector() && !PartLLT.isVector());
  532     assert(DstEltTy.getSizeInBits() % PartLLT.getSizeInBits() == 0);
lib/Target/AMDGPU/AMDGPUCodeGenPrepare.cpp
  203   assert(needsPromotionToI32(T) && "T does not need promotion to i32");
  211   assert(needsPromotionToI32(T) && "T does not need promotion to i32");
  284   assert(needsPromotionToI32(I.getType()) &&
  331   assert(needsPromotionToI32(I.getOperand(0)->getType()) &&
  358   assert(needsPromotionToI32(I.getType()) &&
  388   assert(I.getIntrinsicID() == Intrinsic::bitreverse &&
  390   assert(needsPromotionToI32(I.getType()) &&
  639   assert(Num->getType()->isIntegerTy(32));
  743   assert(Opc == Instruction::URem || Opc == Instruction::UDiv ||
lib/Target/AMDGPU/AMDGPUGenRegisterBankInfo.def
  142     assert(BankID != AMDGPU::VCCRegBankID);
  146     assert(BankID != AMDGPU::VCCRegBankID);
  152   assert(Log2_32_Ceil(Size) == Log2_32_Ceil(ValMappings[Idx].BreakDown->Length));
  153   assert(BankID == ValMappings[Idx].BreakDown->RegBank->getID());
  166   assert(BankID == AMDGPU::SGPRRegBankID);
  219   assert((Size == 256 || Size == 512) && BankID == AMDGPU::VGPRRegBankID);
lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp
  218   assert(F.getCallingConv() == CallingConv::AMDGPU_KERNEL ||
  936   assert(Func.getCallingConv() == CallingConv::AMDGPU_KERNEL ||
lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
  105   assert(N->getOpcode() == ISD::BUILD_VECTOR && N->getNumOperands() == 2);
  399   assert(Subtarget->d16PreservesUnusedBits());
  428       assert(LdHi->getMemoryVT() == MVT::i16);
  456       assert(LdLo->getMemoryVT() == MVT::i16);
  604   assert(N->getOperand(0).getValueType() == MVT::Other && "Expected chain");
  676   assert(NumVectorElts <= 32 && "Vectors with more than 32 elements not "
  698     assert(N->getOpcode() == ISD::SCALAR_TO_VECTOR && NOps < NumVectorElts);
  785     assert(VT.getVectorElementType().bitsEq(MVT::i32));
 1101   assert(VT == MVT::f32 || VT == MVT::f64);
 1117   assert(VT == MVT::f32 || VT == MVT::f64);
 1298     assert(4 * DWordOffset0 == CAddr->getZExtValue());
 1623   assert(isa<BuildVectorSDNode>(N));
 1681       assert(TII->isLegalFLATOffset(ImmField, AS, IsSigned));
 1682       assert(RemainderOffset + ImmField == COffsetVal);
 2012   assert(N->getOpcode() == ISD::BRCOND);
 2106   assert((IsFMA || !Subtarget->hasFP32Denormals()) &&
 2264   assert(HasVSrc || N->getNumOperands() == 3);
 2569     assert(Src.getValueType() == MVT::f16);
 2634   assert(CurDAG->getTarget().getTargetTriple().getArch() == Triple::amdgcn);
lib/Target/AMDGPU/AMDGPUISelLowering.cpp
   47   assert(StoreSize % 32 == 0 && "Store size not a multiple of 32");
  680   assert(LoadTy.getSizeInBits() == CastTy.getSizeInBits());
  744   assert(VT.isFloatingPoint());
  752   assert(VT.isFloatingPoint());
  964         assert(ArgVT.getVectorNumElements() > RegisterVT.getVectorNumElements());
  979         assert(ArgVT.getStoreSizeInBits() % NumRegs == 0);
  983           assert(!RegisterVT.getScalarType().isFloatingPoint());
  985           assert(MemoryBits % NumElements == 0);
 1002         assert(MemVT.getVectorNumElements() == 3 ||
 1209     assert(G->getOffset() == 0 &&
 1385   assert(LoVT.getVectorNumElements() +
 1461   assert(VT.getVectorNumElements() == 3);
 1638   assert(VT == MVT::i64 && "LowerUDIVREM64 expects an i64");
 2077   assert(Op.getValueType() == MVT::f64);
 2126   assert(Op.getValueType() == MVT::f64);
 2499   assert(Op.getOperand(0).getValueType() == MVT::i64 &&
 2520   assert(DestVT == MVT::f64);
 2526   assert(Op.getOperand(0).getValueType() == MVT::i64 &&
 2547   assert(DestVT == MVT::f64);
 2593   assert(N0.getSimpleValueType() == MVT::f64);
 2731   assert(VT.isVector());
 3843     assert(!Subtarget->has16BitInsts() && "should only see if f16 is illegal");
 3984     assert(!N->getValueType(0).isVector() &&
 4114       assert(MFI.getObjectSize(I) == Size);
 4156   assert(Arg && "Attempting to load missing argument");
lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp
  235   assert(MO.isImm());
  341   assert(!Sub && "illegal sub should not reach here");
 1098   assert(Size <= 32 || Size == 64);
 1479   assert(PtrMI);
 1489     assert(OpDef);
 1493       assert(GEPInfo.Imm == 0);
 2037   assert(Offset == 0);
 2180   assert(MI.getOpcode() == TargetOpcode::G_CONSTANT && "Expected G_CONSTANT");
 2182   assert(CstVal && "Expected constant value");
lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
  105     assert(EltSize < 32);
 1144   assert(AS == AMDGPUAS::LOCAL_ADDRESS || AS == AMDGPUAS::PRIVATE_ADDRESS);
 1228   assert(!DstTy.isVector());
 1261     assert(DestAS == AMDGPUAS::LOCAL_ADDRESS ||
 1323   assert(Ty.isScalar() && Ty.getSizeInBits() == 64);
 1352   assert(MRI.getType(Src) == S64);
 1398   assert(MRI.getType(Src) == S64);
 1445   assert(MRI.getType(Src) == S64 && MRI.getType(Dst) == S64);
 1506   assert(EltTy == MRI.getType(Dst));
 1536   assert(EltTy == MRI.getType(Ins));
 1720   assert(Ty.isScalar());
 1744   assert(SITargetLowering::isFlatGlobalAddrSpace(
 1792   assert(Arg->getRegister().isPhysical());
 2061   assert(StoreVT.isVector() && StoreVT.getElementType() == S16);
lib/Target/AMDGPU/AMDGPULibCalls.cpp
  584   assert(Callee->hasName() && "Invalid read_pipe/write_pipe function");
  685     assert ((FInfo.getPrefix() == AMDGPULibFunc::NATIVE ||
  692     assert ((FInfo.getPrefix() == AMDGPULibFunc::NATIVE ||
  751         assert(eltval && "Non-FP arguments in math function!");
  871   assert((FInfo.getId() == AMDGPULibFunc::EI_POW ||
  891     assert(VTy && "Oprand of vector function should be of vectortype");
 1050       assert ((int)CDV->getNumElements() == getVecSize(FInfo) &&
 1287   assert(fInfo.getId() == AMDGPULibFunc::EI_SIN ||
 1408   assert(BB && "Entry block not found!");
 1703     assert(FInfo.getId() == AMDGPULibFunc::EI_SINCOS &&
lib/Target/AMDGPU/AMDGPULibFunc.cpp
   90     assert(static_cast<unsigned>(Id) >
   97     assert(Index < TableSize &&
 1035   assert(AMDGPULibFuncBase::isMangled(Id) && CopyFrom.isMangled() &&
lib/Target/AMDGPU/AMDGPULibFunc.h
  312     assert(((AS + 1) & ~ADDR_SPACE) == 0);
  318     assert(Kind >= 1);
lib/Target/AMDGPU/AMDGPUMCInstLower.cpp
  110   assert(
  122   assert(MO.getTargetFlags() == SIInstrInfo::MO_LONG_BRANCH_BACKWARD);
lib/Target/AMDGPU/AMDGPUMachineCFGStructurizer.cpp
  152     assert((SI.second != SourceMBB || SourceReg == SI.first));
  215   assert(findPHIInfoElement(DestReg) == nullptr && "Dest already exsists");
  303   assert(PHI.isPHI());
  308   assert(PHI.isPHI());
  318   assert(PHI.isPHI());
  323   assert(PHI.isPHI());
  913   assert(Register != NewRegister && "Cannot replace a reg with itself");
 1045             assert(MRI->hasOneDef(Reg) && "Register has multiple definitions");
 1306       assert(InternalSucc == nullptr);
 1310       assert(ExternalSucc == nullptr);
 1964   assert(MRI->hasOneDef(Reg) && "Register has multiple definitions");
 2228   assert(Register != NewRegister && "Cannot replace a reg with itself");
 2271     assert(PHIInfo.sources_end(DestReg) == ++SRI &&
 2437   assert(PHIRegionIndices.size() == 1);
 2866           assert(Instr.getOperand(i * 2 + 1).isReg() &&
lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
  475             assert((Size == 32 || Size == 64) && "unsupported size");
lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp
  201   assert(IsAMDGCN);
lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp
  103   assert(&RBSGPR == &AMDGPU::SGPRRegBank);
  107   assert(&RBVGPR == &AMDGPU::VGPRRegBank);
  151   assert(ValMapping.NumBreakDowns == 2 &&
  577     assert(MRI.getType(MI.getOperand(0).getReg()).getSizeInBits() == 1);
  607   assert(HalfTy.getSizeInBits() == 32);
  628     assert(MRI.getType(Reg).getSizeInBits() == NewTy.getSizeInBits());
  635     assert(Ty.getNumElements() % 2 == 0);
  639   assert(Ty.getSizeInBits() % 2 == 0);
  965     assert(MI.getOperand(Op).isUse());
 1015   assert(Constrained && "Failed to constrain readfirstlane src reg");
 1060   assert(LoadSize % MaxNonSmrdLoadSize == 0);
 1143     assert(SrcReg.size() == 1);
 1347       assert(Src1Regs.empty() && Src2Regs.empty());
 1355       assert(Src0Regs.size() == 1);
 1395       assert(Src0Regs.empty() && Src1Regs.empty());
 1399     assert(DefRegs.size() == 2);
 1400     assert(Src0Regs.size() == Src1Regs.size() &&
 1598     assert(MI.getNumOperands() == 3 && OpdMapper.getVRegs(0).empty());
 1654     assert(OpdMapper.getVRegs(1).empty() && OpdMapper.getVRegs(2).empty());
 1668     assert(DstTy.getSizeInBits() == 64);
 1718     assert(OpdMapper.getVRegs(0).empty());
 1719     assert(OpdMapper.getVRegs(1).empty());
 1720     assert(OpdMapper.getVRegs(3).empty());
 1736     assert(InsTy.getSizeInBits() == 64);
 1795       assert(OpdMapper.getVRegs(0).empty());
 1796       assert(OpdMapper.getVRegs(3).empty());
 1804       assert(OpdMapper.getVRegs(0).empty());
 1805       assert(OpdMapper.getVRegs(2).empty());
 1806       assert(OpdMapper.getVRegs(3).empty());
 1828       assert(OpdMapper.getVRegs(0).empty());
 1914       assert(Bank->getID() == AMDGPU::SGPRRegBankID ||
 2173     assert(ResultBank != -1);
 2433     assert(SrcBank);
 2467     assert(MI.getOperand(0).isReg());
 2927     assert(CondBank == AMDGPU::VCCRegBankID || CondBank == AMDGPU::SCCRegBankID);
 2967     assert(MRI.getType(MI.getOperand(0).getReg()).getSizeInBits() == 1);
lib/Target/AMDGPU/AMDGPURegisterInfo.cpp
   78   assert(NumRegIndex < array_lengthof(SubRegFromChannelTable) &&
   80   assert(Channel < array_lengthof(SubRegFromChannelTable[0]));
lib/Target/AMDGPU/AMDGPURewriteOutArguments.cpp
  403           assert(CT->getNumElements() == 1);
  409           assert(isVec3ToVec4Shuffle(EffectiveEltTy, Val->getType()));
lib/Target/AMDGPU/AMDGPUSubtarget.cpp
  117   assert(!hasFP64() || (getGeneration() >= AMDGPUSubtarget::SOUTHERN_ISLANDS));
  496   assert(F.getCallingConv() == CallingConv::AMDGPU_KERNEL ||
lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h
  142     assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2");
lib/Target/AMDGPU/AMDGPUUnifyMetadata.cpp
   65         assert(VersionMD->getNumOperands() == 2);
lib/Target/AMDGPU/AMDILCFGStructurizer.cpp
  390   assert(DstMBB);
  430   assert(I.isValid() && "Expected valid iterator");
  565   assert(MBB->succ_size() == 2);
  646     assert(IsReturn);
  679   assert((!MBB->getParent()->getJumpTableInfo()
  741     assert(MBB->succ_size() <= 2);
  859       assert(((*It).first)->getNumber() != -1);
  945   assert(isCondBranch(BranchMI));
  957   assert (!TrueMBB->succ_empty() || !FalseMBB->succ_empty());
 1042   assert(!ExitingMBBs.empty() && "Infinite Loop not supported");
 1051   assert(ExitBlkSet.size() == 1);
 1053   assert(ExitBlk && "Loop has several exit block");
 1133       assert(Num > 0);
 1196   assert((!TrueMBB || TrueMBB->succ_size() <= 1)
 1380   assert (TrueMBB);
 1449   assert(BranchMI && isCondBranch(BranchMI));
 1472     assert(isCondBranch(MI));
 1510   assert(PreMBB->isSuccessor(SrcMBB));
 1512     assert(SrcMBB->succ_size() == 1);
 1528   assert(PredMBB->isSuccessor(MBB) &&
 1618   assert(BranchMI && isCondBranch(BranchMI));
 1666   assert(MBB->succ_size() == 0 && MBB->pred_size() == 0
lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
  118       assert(!(hasFPModifiers() && hasIntModifiers())
  670     assert(isExpr());
  676     assert(isToken());
  685     assert(isImm());
  690     assert(isImm());
  695     assert(isRegKind());
  712     assert(isRegKind() || isImmTy(ImmTyNone));
  717     assert(isRegKind() || isImmTy(ImmTyNone));
  779     assert(!hasIntModifiers());
  784     assert(!hasFPModifiers());
  791     assert(isRegKind());
  796     assert(!hasIntModifiers());
  801     assert(!hasFPModifiers());
  809       assert(isExpr());
 1672   assert(isImmTy(ImmTyNone) && Imm.Mods.hasFPModifiers());
 1673   assert(Size == 2 || Size == 4 || Size == 8);
 1694     assert(!isImmTy(ImmTyNone) || !hasModifiers());
 1703   assert(AMDGPU::isSISrcOperand(InstDesc, OpNum));
 1706     assert(AMDGPU::isSISrcFPOperand(InstDesc, OpNum));
 1834     assert(isSafeTruncation(Val, 16));
 1835     assert(AMDGPU::isInlinableLiteral16(static_cast<int16_t>(Val),
 1985   assert(R->isReg());
 2116   assert(isRegularReg(RegKind));
 2172   assert(isToken(AsmToken::Identifier));
 2187   assert(isToken(AsmToken::Identifier));
 2282   assert(SymbolName && "initializing invalid register kind");
 2340   assert(!isRegister());
 2341   assert(!isModifier());
 2416     assert(R->isReg());
 2905   assert(DstIdx != -1);
 2907   assert(Dst.isReg());
 2933     assert(ClampIdx != -1);
 2952   assert(VDataIdx != -1);
 2953   assert(DMaskIdx != -1);
 2954   assert(TFEIdx != -1);
 2987   assert(VAddr0Idx != -1);
 2988   assert(SrsrcIdx != -1);
 2989   assert(DimIdx != -1);
 2990   assert(SrsrcIdx > VAddr0Idx);
 3270   assert(OpNum != -1);
 4800       assert(SrcIdx < 4);
 4808       assert(SrcIdx < 4);
 4827   assert(SrcIdx == 4);
 5753     assert(Opr.isImm() || Opr.isExpr());
 5801   assert(IsAtomicReturn ? IsAtomic : true);
 5831     assert(Op.isImm());
 5889     assert(Op.isImm());
 5920     assert(Desc.getNumDefs() == 1);
 6171   assert(SrcNum > 0);
 6312     assert(!IsPacked);
 6330     assert(IsPacked);
 6692       assert((unsigned)TiedTo < Inst.getNumOperands());
lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.cpp
  235   assert(Bytes.size() >= sizeof(T));
  245   assert(MI.getOpcode() == 0);
  246   assert(MI.getNumOperands() == 0);
  261   assert(FiIdx != -1);
  490   assert(VDataIdx != -1);
  491   assert(DMaskIdx != -1);
  492   assert(TFEIdx != -1);
  595     assert(AddrSize <= Info->VAddrDwords);
  814   assert(Imm >= INLINE_INTEGER_C_MIN && Imm <= INLINE_INTEGER_C_MAX);
  897   assert(Imm >= AMDGPU::EncValues::INLINE_FLOATING_C_MIN
  920   assert(OPW_FIRST_ <= Width && Width < OPW_LAST_);
  935   assert(OPW_FIRST_ <= Width && Width < OPW_LAST_);
  953   assert(OPW_FIRST_ <= Width && Width < OPW_LAST_);
  970   assert(OPW_FIRST_ <= Width && Width < OPW_LAST_);
  998   assert(Val < 1024); // enum10
 1008     assert(SGPR_MIN == 0); // "SGPR_MIN <= Val" is always true and causes compilation warning.
 1041   assert(Val < 128);
 1042   assert(Width == OPW256 || Width == OPW512);
 1045     assert(SGPR_MIN == 0); // "SGPR_MIN <= Val" is always true and causes compilation warning.
 1165   assert((STI.getFeatureBits()[AMDGPU::FeatureGFX9] ||
lib/Target/AMDGPU/GCNDPPCombine.cpp
  158   assert(MovMI.getOpcode() == AMDGPU::V_MOV_B32_dpp);
  172     assert(Dst);
  178       assert(OldIdx == NumOperands);
  179       assert(isOfRegClass(CombOldVGPR, AMDGPU::VGPR_32RegClass, *MRI));
  194       assert(NumOperands == AMDGPU::getNamedOperandIdx(DPPOp,
  196       assert(0LL == (Mod0->getImm() & ~(SISrcMods::ABS | SISrcMods::NEG)));
  205     assert(Src0);
  217       assert(NumOperands == AMDGPU::getNamedOperandIdx(DPPOp,
  219       assert(0LL == (Mod1->getImm() & ~(SISrcMods::ABS | SISrcMods::NEG)));
  262   assert(OldOpnd->isImm());
  318   assert(CombOldVGPR.Reg);
  346   assert(Imm->isImm());
  351   assert(MovMI.getOpcode() == AMDGPU::V_MOV_B32_dpp);
  355   assert(DstOpnd && DstOpnd->isReg());
  368   assert(RowMaskOpnd && RowMaskOpnd->isImm());
  370   assert(BankMaskOpnd && BankMaskOpnd->isImm());
  375   assert(BCZOpnd && BCZOpnd->isImm());
  380   assert(OldOpnd && OldOpnd->isReg());
  381   assert(SrcOpnd && SrcOpnd->isReg());
  392   assert(!OldOpndValue || OldOpndValue->isImm() || OldOpndValue == OldOpnd);
  412         assert(!BoundCtrlZero); // by check [1]
  416       assert(!MaskAllLanes); // by check [1]
  562   assert(MRI->isSSA() && "Must be run on SSA");
lib/Target/AMDGPU/GCNHazardRecognizer.cpp
  704     assert(SRsrcIdx != -1 &&
 1198   assert(SIInstrInfo::isMAI(*MI));
lib/Target/AMDGPU/GCNILPSched.cpp
   88   assert(SU->NodeNum < SUNumbers.size());
  236   assert(left->NodeQueueId && right->NodeQueueId &&
  248       assert(NewBestSU == I->SU);
  281     assert(PredSU->isBoundaryNode() || PredSU->NumSuccsLeft > 0);
  335     assert(C);
  346   assert(SUnits.size() == Schedule.size());
lib/Target/AMDGPU/GCNIterativeScheduler.cpp
  202     assert(Sch.RegionBegin == Rgn.Begin && Sch.RegionEnd == Rgn.End);
  215     assert(Sch.RegionBegin == Rgn.Begin && Sch.RegionEnd == Rgn.End);
  264     assert(UPTracker.isValid());
  272   assert(UPTracker.isValid() ||
  364   assert(R.BestSchedule.get() && "No schedule specified");
  374   assert(RegionBegin == R.Begin && RegionEnd == R.End);
  375   assert(LIS != nullptr);
  422   assert((SchedMaxRP == RegionMaxRP && (MaxRP.empty() || SchedMaxRP == MaxRP))
  530           assert(R->MaxPressure.getOccupancy(ST) >= TgtOcc);
lib/Target/AMDGPU/GCNMinRegStrategy.cpp
   45     assert(!SU->isBoundaryNode());
   50     assert(!SU->isBoundaryNode());
   55     assert(!SU->isBoundaryNode());
   56     assert(NumPreds[SU->NodeNum] != std::numeric_limits<unsigned>::max());
   61     assert(!SU->isBoundaryNode());
   62     assert(NumPreds[SU->NodeNum] != std::numeric_limits<unsigned>::max());
   98       assert(!PSU->isBoundaryNode());
  115   assert(!RQ.empty() && Num <= RQ.size());
  177     assert(Num == 1);
  191       assert(!PSU->isBoundaryNode());
  200     assert(!SU->isBoundaryNode());
  225     assert(SuccSU->isBoundaryNode() || getNumPreds(SuccSU) > 0);
  257     assert(C);
  271   assert(SUnits.size() == Schedule.size());
lib/Target/AMDGPU/GCNRegBankReassign.cpp
  278   assert(Register::isPhysicalRegister(Reg));
lib/Target/AMDGPU/GCNRegPressure.cpp
   87   assert(Register::isVirtualRegister(Reg));
  116     assert(PrevMask.none() && NewMask == MaxMask);
  123     assert(NewMask < MaxMask || NewMask == MaxMask);
  124     assert(PrevMask < NewMask);
  130       assert(NewMask.any());
  200   assert(MO.isDef() && MO.isReg() && Register::isVirtualRegister(MO.getReg()));
  213   assert(MO.isUse() && MO.isReg() && Register::isVirtualRegister(MO.getReg()));
  266         assert(LiveMask < MRI.getMaxLaneMaskForVReg(Reg) ||
  312   assert(MRI && "call reset first");
  351   assert(CurPressure == getRegPressure(*MRI, LiveRegs));
  368   assert(MRI && "call reset first");
  375   assert(SI.isValid());
lib/Target/AMDGPU/GCNSchedStrategy.cpp
  196     assert(BotCand.Reason != NoCand && "failed to find the first candidate");
  204       assert(TCand.SU == BotCand.SU &&
  216     assert(TopCand.Reason != NoCand && "failed to find the first candidate");
  224       assert(TCand.SU == TopCand.SU &&
  271     assert(Top.Available.empty() && Top.Pending.empty() &&
  283         assert(TopCand.Reason != NoCand && "failed to find a candidate");
  293         assert(BotCand.Reason != NoCand && "failed to find a candidate");
  471     assert(isEqual(getLiveRegsBefore(*NonDbgMI, *LIS), LRS));
  505   assert(!Regions.empty());
lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp
  149   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp
  374     assert(STI.getFeatureBits()[AMDGPU::FeatureInv2PiInlineImm]);
  452     assert(isUInt<32>(Imm) || Imm == 0x3fc45f306dc9c882);
 1101   assert(Op.isImm());
 1112   assert(Op.isImm());
 1421   assert(Op.isImm() || Op.isExpr());
lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp
  510   assert(isPowerOf2_32(Align));
lib/Target/AMDGPU/MCTargetDesc/R600MCCodeEmitter.cpp
  193   assert(MO.isImm());
lib/Target/AMDGPU/MCTargetDesc/SIMCCodeEmitter.cpp
  228     assert(!MO.isFPImm());
  299     assert(vaddr0 >= 0 && srsrc > vaddr0);
  477     assert(Offset == 4 || Offset == 8);
lib/Target/AMDGPU/R600ClauseMergePass.cpp
   85   assert(isCFAlu(MI));
   92   assert(isCFAlu(MI));
  118   assert(isCFAlu(RootCFAlu) && isCFAlu(LatrCFAlu));
  206         assert(MI.getOperand(8).getImm() && "CF ALU instruction disabled");
lib/Target/AMDGPU/R600ControlFlowFinalizer.cpp
  122       assert(ST->getWavefrontSize() == 32);
  138   assert(!ST->hasCaymanISA());
  152     assert(ST->getGeneration() >= AMDGPUSubtarget::EVERGREEN);
  292     assert (Opcode && "No opcode selected");
  387         assert(Lits.size() < 4 && "Too many literals in Instruction Group");
  463     assert(ClauseContent.size() < 128 && "ALU clause is too big");
lib/Target/AMDGPU/R600EmitClauseMarkers.cpp
  139     assert(
  329           assert(next != I);
lib/Target/AMDGPU/R600ExpandSpecialInstrs.cpp
   99         assert(DstIdx != -1);
  168             assert(TRI.getHWRegChan(Src0) == TRI.getHWRegChan(Src1));
lib/Target/AMDGPU/R600ISelLowering.cpp
  303       assert(DstIdx != -1);
  339     assert(Register::isVirtualRegister(maskedRegister));
  491     assert((!Result.getNode() ||
  909   assert(isInt<16>(ByteOffset));
 1142   assert(Store->isTruncatingStore()
 1144   assert(Store->getAddressSpace() == AMDGPUAS::PRIVATE_ADDRESS);
 1148     assert(Store->getAlignment() >= 1);
 1151     assert(Store->getAlignment() >= 2);
 1277       assert(VT.bitsLE(MVT::i32));
 1282         assert(MemVT == MVT::i16);
 1283         assert(StoreNode->getAlignment() >= 2);
 1390   assert(Load->getAlignment() >= MemVT.getStoreSize());
 1504     assert(!MemVT.isVector() && (MemVT == MVT::i16 || MemVT == MVT::i8));
 1521     assert(VT == MVT::i32);
 1690   assert(RemapSwizzle.empty());
 1739   assert(RemapSwizzle.empty());
 1807   assert (isa<ConstantSDNode>(Ptr));
 2199       assert(C);
lib/Target/AMDGPU/R600InstrInfo.cpp
  333       assert(Operand.isGlobal());
  403   assert(Op < 3 && "Out of range swizzle index");
  482   assert(Idx < SwzCandidate.size());
  585   assert (Consts.size() <= 12 && "Too many operands in instructions group");
  762   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  763   assert(!BytesAdded && "code size not handled");
  771       assert(PredSet && "No previous predicate !");
  781       assert (CfAlu->getOpcode() == R600::CF_ALU);
  787     assert(PredSet && "No previous predicate !");
  797     assert (CfAlu->getOpcode() == R600::CF_ALU);
  805   assert(!BytesRemoved && "code size not handled");
  826     assert (CfAlu->getOpcode() == R600::CF_ALU_PUSH_BEFORE);
  851     assert (CfAlu->getOpcode() == R600::CF_ALU_PUSH_BEFORE);
 1019   assert(Channel == 0);
 1319   assert (MI->getOpcode() == R600::DOT_4 && "Not Implemented");
 1357     assert (MO.isImm());
 1391   assert(Idx != -1 && "Operand not supported for this instruction.");
 1392   assert(MI.getOperand(Idx).isImm());
 1408     assert(HAS_NATIVE_OPERANDS(TargetFlags));
 1436       assert(!IsOP3 && "Cannot set absolute value modifier for OP3 "
 1453     assert(FlagIndex != -1 && "Flag not supported for this instruction");
 1456       assert(FlagIndex != 0 &&
 1461   assert(FlagOp.isImm());
lib/Target/AMDGPU/R600MachineScheduler.cpp
   28   assert(dag->hasVRegLiveness() && "R600SchedStrategy needs vreg liveness");
   53   assert (GPRCount && "GPRCount cannot be 0");
  347   assert (OccupedSlotsMask && "Slot wasn't filled");
lib/Target/AMDGPU/R600OpenCLImageTypeLoweringPass.cpp
  147   assert(V.size() == NumKernelArgMDNodes);
lib/Target/AMDGPU/R600OptimizeVectorRegisters.cpp
   60   assert(MRI.isSSA());
   76     assert(MI->getOpcode() == R600::REG_SEQUENCE);
  224     assert(!is_contained(UpdatedUndef, Chan) &&
lib/Target/AMDGPU/R600Packetizer.cpp
  231     assert (!isTransSlot || VLIW5);
  335   assert(Packetizer.getResourceTracker() && "Empty DFA table!");
  336   assert(Packetizer.getResourceTracker()->getInstrItins());
lib/Target/AMDGPU/R600RegisterInfo.cpp
   96   assert(!Register::isVirtualRegister(Reg));
lib/Target/AMDGPU/SIAddIMGInit.cpp
   85         assert( (TFE && LWE) && "Expected tfe and lwe operands in instruction");
  106           assert(MO_Dmask && "Expected dmask operand in instruction");
lib/Target/AMDGPU/SIAnnotateControlFlow.cpp
  294   assert(Stack.back().first == BB);
lib/Target/AMDGPU/SIFixSGPRCopies.cpp
  243   assert(MI.isRegSequence());
  292     assert(TRI->isSGPRClass(SrcRC) &&
  465           assert(MDT.dominates(&*To, &*From));
lib/Target/AMDGPU/SIFoldOperands.cpp
   54       assert(FoldOp->isReg() || FoldOp->isGlobal());
  191   assert(Old.isReg());
  209       assert(ModIdx != -1);
  253     assert(Dst0.isDef() && Dst1.isDef());
  283   assert(!Fold.needsShrink() && "not handled");
  414         assert(MI->getOperand(1).isDef());
  458     assert (Sub->isReg());
  724             assert(Def->isReg());
  856       assert(UseOp.getSubReg() == AMDGPU::sub1);
 1221         assert(Fold.OpToFold && Fold.OpToFold->isReg());
lib/Target/AMDGPU/SIFrameLowering.cpp
  251   assert(ST.getGeneration() < AMDGPUSubtarget::GFX10);
  325   assert(MFI->isEntryFunction());
  376           assert(!hasFP(MF));
  394   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  455     assert(ST.isAmdHsaOrMesa(F) || ST.isMesaGfxShader(F));
  494   assert(SPReg != AMDGPU::SP_REG);
  500     assert(ScratchWaveOffsetReg);
  605     assert(!ST.isAmdHsaOrMesa(Fn));
  733       assert(FuncInfo->SGPRForFPSaveRestoreCopy != ScratchExecCopy);
  760     assert(!MFI.isDeadObjectIndex(FI) &&
  764     assert(Spill.size() == 1);
  788     assert(ScratchSPReg != AMDGPU::NoRegister &&
  819   assert((!HasFP || (FuncInfo->SGPRForFPSaveRestoreCopy != AMDGPU::NoRegister ||
  823   assert((HasFP || (FuncInfo->SGPRForFPSaveRestoreCopy == AMDGPU::NoRegister &&
  863     assert(!MF.getFrameInfo().isDeadObjectIndex(FI) &&
  868     assert(Spill.size() == 1);
  961   assert(allSGPRSpillsAreDead(MFI, None) &&
  968     assert(RS && "RegScavenger required if spilling");
 1116     assert(isUInt<32>(Amount) && "exceeded stack address space size");
lib/Target/AMDGPU/SIISelLowering.cpp
  865   assert(Ty->isStructTy() && "Expected struct type");
  879   assert((Ty->getContainedType(1) && Ty->getContainedType(1)->isIntegerTy(32)) && "Expected int32 type");
 1572     assert((!Arg->VT.isVector() || Arg->VT.getScalarSizeInBits() == 16) &&
 1585           assert((!Arg->VT.isVector() ||
 1666   assert(Reg != AMDGPU::NoRegister);
 1684   assert(Reg != AMDGPU::NoRegister);
 1921       assert(AMDGPU::isShader(MF.getFunction().getCallingConv()));
 1947     assert(!MFI.hasCalls());
 1960     assert(!MFI.hasCalls());
 2088     assert(!Info->hasDispatchPtr() &&
 2095     assert(Info->hasWorkGroupIDX() && Info->hasWorkItemIDX());
 2164     assert(VA.isRegLoc() && "Parameter must be in a register!");
 2311     assert(VA.isRegLoc() && "Can only return in registers!");
 2439   assert(CalleeFunc);
 2479     assert(IncomingArgRC == ArgRC);
 2490       assert(InputID == AMDGPUFunctionArgInfo::IMPLICIT_ARG_PTR);
 2814       assert(VA.isMemLoc());
 2948   assert(Mask && "Missing call preserved mask for calling convention");
 3345   assert(Idx->getReg() != AMDGPU::NoRegister);
 3496   assert(Val->getReg());
 3508     assert(Offset == 0);
 3697     assert(Found);
 3724     assert(getTargetMachine().getTargetTriple().getOS() == Triple::AMDHSA ||
 3952   assert(VT == MVT::v4f16);
 3972   assert(VT == MVT::v4i16 || VT == MVT::v4f16);
 3993   assert(VT == MVT::v4i16 || VT == MVT::v4f16);
 4020     assert((!Result.getNode() ||
 4470   assert(!SetCC ||
 4568   assert(Op.getValueType() == MVT::f16 &&
 4613   assert(UserSGPR != AMDGPU::NoRegister);
 4676   assert(UserSGPR != AMDGPU::NoRegister);
 4796   assert(VecSize <= 64);
 4842   assert(isPowerOf2_32(EltSize));
 4871   assert(VecSize <= 64);
 4883   assert(isPowerOf2_32(EltSize));
 4903   assert(Elt % 2 == 0);
 4981   assert(VT == MVT::v2f16 || VT == MVT::v2i16);
 4982   assert(!Subtarget->hasVOP3PInsts() && "this should be legal");
 5155   assert(!Elts.empty());
 5172     assert(Elts.size() <= 16);
 5615   assert(Opcode != -1);
 5665   assert((LoadVT.getScalarType() == MVT::i32 ||
 6726   assert(VTList.NumVTs == 2);
 6749   assert((StoreVT.getVectorNumElements() != 3) && "Handle v3f16");
 6762   assert(isTypeLegal(StoreVT));
 7272   assert((!MemVT.isVector() || Ld->getExtensionType() == ISD::NON_EXTLOAD) &&
 7288     assert(Ld->getExtensionType() == ISD::NON_EXTLOAD &&
 7301     assert(Ld->getExtensionType() == ISD::EXTLOAD);
 7370   assert(Op.getValueType().getVectorElementType() == MVT::i32 &&
 7489   assert(VT.getSizeInBits() == 64);
 7574   assert(GlueChain->getNumValues() == 3);
 7595   assert(GlueChain->getNumValues() == 3);
 7667   assert(ST->hasDenormModeInst() && "Requires S_DENORM_MODE");
 7872   assert(VT.isVector() &&
 7974   assert(AtomicNode->isCompareAndSwap());
 8186   assert(V.getValueSizeInBits() == 32);
 9655   assert(!VT.isVector());
10174   assert(NewOpcode != -1 &&
10203     assert(Node->hasNUsesOfValue(1, 0));
10345         assert(Src1.getMachineOpcode() == AMDGPU::IMPLICIT_DEF);
10685   assert(!TRI->isSubRegister(Info->getScratchRSrcReg(),
10814   assert(N->getOpcode() == ISD::CopyFromReg);
10854       assert(Reg == FLI->DemoteRegister || isCopyFromRegOfInlineAsm(N));
lib/Target/AMDGPU/SIInsertSkips.cpp
  251     assert(MI.getOperand(0).isReg());
  279     assert(KillVal == 0 || KillVal == -1);
  284       assert(Imm == 0 || Imm == -1);
  507         assert(!MF.getInfo<SIMachineFunctionInfo>()->returnsVoid());
lib/Target/AMDGPU/SIInsertWaitcnts.cpp
  218     assert(T < NUM_INST_CNTS);
  225     assert(T < NUM_INST_CNTS);
  239     assert(WaitEventMaskForInst[EXP_CNT] & (1 << E));
  247     assert(T == LGKM_CNT);
  313     assert(T < NUM_INST_CNTS);
  320     assert(T < NUM_INST_CNTS);
  338       assert(T == LGKM_CNT);
  471   assert(!Op.getSubReg() || !Op.isUndef());
  479     assert(Reg >= RegisterEncoding.VGPR0 && Reg <= RegisterEncoding.VGPRL);
  481     assert(Result.first >= 0 && Result.first < SQ_MAX_PGM_VGPRS);
  483     assert(Reg >= RegisterEncoding.SGPR0 && Reg < SQ_MAX_PGM_SGPRS);
  485     assert(Result.first >= NUM_ALL_VGPRS &&
  509     assert(TRI->isVGPR(*MRI, Opnd.getReg()));
 1079           assert(II->getOpcode() == AMDGPU::S_WAITCNT_VSCNT);
 1080           assert(II->getOperand(0).getReg() == AMDGPU::SGPR_NULL);
 1127         assert(II->getOpcode() == AMDGPU::S_WAITCNT_VSCNT);
 1128         assert(II->getOperand(0).getReg() == AMDGPU::SGPR_NULL);
 1164     assert(ST->hasVscnt());
 1212     assert(Inst.mayLoad() || Inst.mayStore());
 1463   assert(HardwareLimits.NumVGPRsMax <= SQ_MAX_PGM_VGPRS);
 1464   assert(HardwareLimits.NumSGPRsMax <= SQ_MAX_PGM_SGPRS);
lib/Target/AMDGPU/SIInstrInfo.cpp
  192     assert(getNumOperandsNoGlue(Load0) == getNumOperandsNoGlue(Load1));
  277       assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
  301         assert(LdSt.mayStore());
  311       assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
  353     assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
  367     assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
  386     assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
  500   assert(Offset1 > Offset0 &&
  531     assert(AMDGPU::VGPR_32RegClass.contains(SrcReg) ||
  556         assert(AMDGPU::VGPR_32RegClass.contains(SrcReg));
  582         assert(AMDGPU::VGPR_32RegClass.contains(SrcReg));
  602     assert(AMDGPU::SReg_32RegClass.contains(SrcReg));
  610     assert(AMDGPU::VGPR_32RegClass.contains(SrcReg) ||
  623         assert(DefOp.isReg() || DefOp.isImm());
  823   assert(MRI.getRegClass(DstReg) == &AMDGPU::VGPR_32RegClass &&
  837     assert(Cond[0].isImm() && "Cond[0] is not an immediate");
 1348   assert(Info->isEntryFunction());
 1425     assert(!SrcOp.isFPImm());
 1435       assert(SrcOp.isReg());
 1485     assert(VecReg == MI.getOperand(1).getReg());
 1565   assert (MI.getOpcode() == AMDGPU::V_MOV_B64_DPP_PSEUDO);
 1581       assert(MRI.isSSA());
 1588       assert(!SrcOp.isFPImm());
 1594         assert(SrcOp.isReg());
 1631   assert(Src1Mods &&
 1668   assert(!NewMI && "this should never be used");
 1675   assert(AMDGPU::getNamedOperandIdx(Opc, AMDGPU::OpName::src0) ==
 1744   assert(BranchOp != AMDGPU::S_SETPC_B64);
 1772   assert(RS && "RegScavenger required for long branching");
 1773   assert(MBB.empty() &&
 1775   assert(MBB.pred_size() == 1);
 2066   assert(TBB && Cond[0].isImm());
 2085   assert(TBB && FBB);
 2127     assert(MRI.getRegClass(FalseReg) == RC);
 2141     assert(MRI.getRegClass(FalseReg) == RC);
 2326   assert(ImmOp);
 2545   assert((MIa.mayLoad() || MIa.mayStore()) &&
 2547   assert((MIb.mayLoad() || MIb.mayStore()) &&
 2929   assert(MO.isImm() || MO.isTargetIndex() || MO.isFI() || MO.isGlobal());
 3071     assert(((MI.getOperand(0).getReg() == AMDGPU::VCC) ||
 3907   assert(Inst.getNumExplicitOperands() == 3);
 3945   assert(MO.isImm() || MO.isTargetIndex() || MO.isFI() || MO.isGlobal());
 3997     assert(DefinedRC);
 4002   assert(MO->isImm() || MO->isTargetIndex() || MO->isFI() || MO->isGlobal());
 4559         assert(SRC);
 4737       assert(MBB.getParent()->getSubtarget<GCNSubtarget>().getGeneration()
 5042       assert(OffsetWidthOp.isImm() &&
 5115     assert(Opc == AMDGPU::S_ADD_I32 || Opc == AMDGPU::S_SUB_I32);
 5120     assert(Inst.getOperand(3).getReg() == AMDGPU::SCC);
 5570   assert(Inst.getOpcode() == AMDGPU::S_BFE_I64 && BitWidth <= 32 &&
 5718   assert(Op.isReg() && Op.getReg() == AMDGPU::SCC && Op.isDef() &&
 5925   assert(!MI.memoperands_empty() &&
 5935   assert(Addr && Addr->isFI());
 5973     assert(!I->isBundle() && "No nested bundle!");
 6068   assert(TI != IfEntry->end());
 6094   assert(TI != LoopEnd->end());
 6373   assert(RegOpnd.isReg());
 6380   assert(MI.isRegSequence());
 6418   assert(MRI.isSSA());
 6455   assert(MRI.isSSA() && "Must be run on SSA");
 6487   assert(MRI.isSSA() && "Must be run on SSA");
lib/Target/AMDGPU/SIInstrInfo.h
  671     assert(MI.isCopy());
  707     assert(UseMO.getParent() == &MI);
  730       assert(Size == 8 || Size == 4);
  808       assert(OpInfo.OperandType == MCOI::OPERAND_IMMEDIATE);
  821         assert(RI.getRegSizeInBits(*RI.getSubClassWithSubReg(
 1046   assert(O.isReg());
lib/Target/AMDGPU/SILoadStoreOptimizer.cpp
  356       assert(Info);
  510   assert(InstClass == getInstClass(Paired->getOpcode(), TII));
  612   assert(MemOp.mayLoadOrStore());
  639   assert(CI.InstClass == MIMG);
  674   assert(CI.InstClass != MIMG);
  896   assert((isUInt<8>(NewOffset0) && isUInt<8>(NewOffset1)) &&
  994   assert((isUInt<8>(NewOffset0) && isUInt<8>(NewOffset1)) &&
 1061   assert(CI.I->hasOneMemOperand() && CI.Paired->hasOneMemOperand());
 1105   assert(CI.I->hasOneMemOperand() && CI.Paired->hasOneMemOperand());
 1164   assert(CI.I->hasOneMemOperand() && CI.Paired->hasOneMemOperand());
 1208     assert(CI.InstClass == BUFFER_LOAD || CI.InstClass == BUFFER_STORE);
 1224     assert("No overlaps" && (countPopulation(CI.DMask0 | CI.DMask1) == Width));
 1237     assert((countPopulation(CI.DMask0 | CI.DMask1) == CI.Width0 + CI.Width1) &&
 1252   assert(CI.Width0 >= 1 && CI.Width0 <= 3);
 1253   assert(CI.Width1 >= 1 && CI.Width1 <= 3);
 1331   assert(CI.I->hasOneMemOperand() && CI.Paired->hasOneMemOperand());
 1377   assert((TRI->getRegSizeInBits(Addr.Base.LoReg, *MRI) == 32 ||
 1381   assert((TRI->getRegSizeInBits(Addr.Base.HiReg, *MRI) == 32 ||
 1843   assert(MRI->isSSA() && "Must be run on SSA");
lib/Target/AMDGPU/SILowerControlFlow.cpp
  140   assert(ImpDefSCC.getReg() == AMDGPU::SCC && ImpDefSCC.isDef());
  183   assert(SaveExec.getSubReg() == AMDGPU::NoSubRegister);
  204   assert(Cond.getSubReg() == AMDGPU::NoSubRegister);
  207   assert(ImpDefSCC.getReg() == AMDGPU::SCC && ImpDefSCC.isDef());
  473   assert(MI.getNumExplicitOperands() == 3);
lib/Target/AMDGPU/SILowerI1Copies.cpp
  155     assert(Stack.empty());
  325     assert(LoopLevel < CommonDominators.size());
  521       assert(isVRegCompatibleReg(TII->getRegisterInfo(), *MRI, DstReg));
  522       assert(!MI.getOperand(0).getSubReg());
  575       assert(i + 1 < MI->getNumOperands());
  582         assert(isLaneMaskReg(IncomingReg) || isVreg1(IncomingReg));
  583         assert(!IncomingDef->getOperand(1).getSubReg());
  587         assert(IncomingDef->isPHI() || PhiRegisters.count(IncomingReg));
  698       assert(!MI.getOperand(1).getSubReg());
  702         assert(TII->getRegisterInfo().getRegSizeInBits(SrcReg, *MRI) == 32);
lib/Target/AMDGPU/SILowerSGPRSpills.cpp
  108         assert(std::distance(MIS.begin(), I) == 1);
  138       assert(I != RestoreBlock.begin() &&
  164     assert(MFI.getRestorePoint() && "Both restore and save must be set");
  237   assert(SaveBlocks.empty() && RestoreBlocks.empty());
  294         assert(MFI.getStackID(FI) == TargetStackID::SGPRSpill);
  298           assert(Spilled && "failed to spill SGPR to VGPR when allocated");
lib/Target/AMDGPU/SIMachineFunctionInfo.cpp
  276   assert(Size >= 4 && Size <= 64 && "invalid sgpr spill size");
  277   assert(TRI->spillSGPRToVGPR() && "not spilling SGPRs to VGPRs");
  331   assert(ST.hasMAIInsts() && FrameInfo.isSpillSlotObjectIndex(FI));
  410   assert(NumSystemSGPRs == 0 && "System SGPRs must be added after user SGPRs");
lib/Target/AMDGPU/SIMachineFunctionInfo.h
  703     assert(Reg != 0 && "Should never be unset");
  716     assert(Reg != 0 && "Should never be unset");
  721     assert(Reg != 0 && "Should never be unset");
  734     assert(Reg != 0 && "Should never be unset");
  858       assert(hasWorkGroupIDX());
  861       assert(hasWorkGroupIDY());
  864       assert(hasWorkGroupIDZ());
  876     assert(BufferRsrc);
  885     assert(ImgRsrc);
lib/Target/AMDGPU/SIMachineScheduler.cpp
  429   assert(SUnits.size() == ScheduledSUnits.size() &&
  432     assert(SU->isScheduled &&
  501   assert (!SU->NumPredsLeft);
  547   assert(none_of(Succs,
  572   assert(none_of(Preds,
  729         assert(!HasSubGraph);
  930   assert(DAGSize >= 1 &&
  989     assert(i == SU->NodeNum);
 1167         assert(!HasSubGraph);
 1323       assert(TopDownBlock2Index[i] > TopDownBlock2Index[Pred->getID()] &&
 1504     assert(Block->getID() == i);
 1705     assert (Pos != LiveRegs.end() && // Reg must be live.
 1734     assert(LiveRegsConsumers.find(RegP.first) == LiveRegsConsumers.end() ||
 2028   assert(TopRPTracker.getPos() == RegionBegin && "bad initial Top tracker");
 2041   assert(CurrentTop == CurrentBottom && "Nonempty unscheduled zone.");
lib/Target/AMDGPU/SIMachineScheduler.h
  185       assert(Best.Reason != NoCand && "uninitialized Sched candidate");
  378       assert(Best.Reason != NoCand && "uninitialized Sched candidate");
lib/Target/AMDGPU/SIMemoryLegalizer.cpp
  518   assert(MI->getNumMemOperands() > 0);
  546       assert(MMO->getFailureOrdering() != AtomicOrdering::Release &&
  577   assert(MI->getDesc().TSFlags & SIInstrFlags::maybeAtomic);
  591   assert(MI->getDesc().TSFlags & SIInstrFlags::maybeAtomic);
  605   assert(MI->getDesc().TSFlags & SIInstrFlags::maybeAtomic);
  638   assert(MI->getDesc().TSFlags & SIInstrFlags::maybeAtomic);
  669   assert(MI->mayLoad() && !MI->mayStore());
  703   assert(MI->mayLoad() ^ MI->mayStore());
  903   assert(MI->mayLoad() && !MI->mayStore());
  944   assert(MI->mayLoad() ^ MI->mayStore());
 1137   assert(MI->mayLoad() && !MI->mayStore());
 1182   assert(!MI->mayLoad() && MI->mayStore());
 1209   assert(MI->getOpcode() == AMDGPU::ATOMIC_FENCE);
 1247   assert(MI->mayLoad() && MI->mayStore());
lib/Target/AMDGPU/SIOptimizeExecMasking.cpp
  378         assert(SaveExecInst != &*J);
lib/Target/AMDGPU/SIOptimizeExecMaskingPreRA.cpp
  100     assert(MI.isFullCopy());
lib/Target/AMDGPU/SIPeepholeSDWA.cpp
  114     assert(Target->isReg());
  115     assert(Replaced->isReg());
  276   assert(To.isReg() && From.isReg());
  348     assert(!Sext &&
  377   assert(Src && (Src->isReg() || Src->isImm()));
  419     assert(Src && Src->isReg());
  431     assert(isSameReg(*Src, *getReplacedOperand()) &&
  475   assert(Operand &&
  480   assert(DstSel);
  483   assert(DstUnused);
  751     assert(OrSDWA && OrOther);
  756       assert(OrSDWA && OrOther);
  764     assert(OrSDWADef && OrOtherDef);
  841     assert(OrDst && OrDst->isReg());
  883   assert((Opc == AMDGPU::V_ADD_I32_e64 || Opc == AMDGPU::V_SUB_I32_e64) &&
 1004   assert(SDWAOpcode != -1);
 1015     assert(AMDGPU::getNamedOperandIdx(SDWAOpcode, AMDGPU::OpName::vdst) != -1);
 1018     assert(Dst &&
 1022     assert(AMDGPU::getNamedOperandIdx(SDWAOpcode, AMDGPU::OpName::sdst) != -1);
 1029   assert(
 1042     assert(
 1058     assert(Src2);
 1063   assert(AMDGPU::getNamedOperandIdx(SDWAOpcode, AMDGPU::OpName::clamp) != -1);
 1102   assert(AMDGPU::getNamedOperandIdx(SDWAOpcode, AMDGPU::OpName::src0_sel) != -1);
 1112     assert(AMDGPU::getNamedOperandIdx(SDWAOpcode, AMDGPU::OpName::src1_sel) != -1);
 1127     assert(Dst && Dst->isTied());
 1128     assert(Opcode == static_cast<unsigned int>(SDWAOpcode));
 1131     assert(PreserveDstIdx != -1);
lib/Target/AMDGPU/SIPreAllocateWWMRegs.cpp
  110       assert(PhysReg != 0);
  153     assert(PhysReg != 0);
lib/Target/AMDGPU/SIRegisterInfo.cpp
  104   assert(SGPRSetID < NumRegPressureSets &&
  230     assert(!isSubRegister(ScratchRSrcReg, ScratchWaveOffsetReg));
  240     assert(!isSubRegister(ScratchRSrcReg, StackPtrReg));
  246     assert(!isSubRegister(ScratchRSrcReg, FrameReg));
  314   assert(SIInstrInfo::isMUBUF(*MI));
  326   assert(Idx == AMDGPU::getNamedOperandIdx(MI->getOpcode(),
  399   assert(FIOp && FIOp->isFI() && "frame index must be address operand");
  400   assert(TII->isMUBUF(MI));
  401   assert(TII->getNamedOperand(MI, AMDGPU::OpName::soffset)->getReg() ==
  407   assert(isUInt<12>(NewOffset) && "offset should be legal");
  650   assert((Offset % EltSize) == 0 && "unexpected VGPR spill offset");
  768   assert(SpillToVGPR || (SuperReg != MFI->getStackPtrOffsetReg() &&
  772   assert(SuperReg != AMDGPU::M0 && "m0 should never spill");
  883   assert(SuperReg != AMDGPU::M0 && "m0 should never spill");
  993   assert(SPAdj == 0 && "unhandled SP adjustment in call sequence?");
 1043       assert(TII->getNamedOperand(*MI, AMDGPU::OpName::soffset)->getReg() ==
 1073       assert(TII->getNamedOperand(*MI, AMDGPU::OpName::soffset)->getReg() ==
 1144               assert(ConstOffsetReg && "this scavenge should not be able to fail");
 1202         assert(static_cast<int>(FIOperandNum) ==
 1206         assert(TII->getNamedOperand(*MI, AMDGPU::OpName::soffset)->getReg() ==
 1245   assert(!Register::isVirtualRegister(Reg));
 1306     assert(Size < 32 && "Invalid register class size");
 1663   assert(EltSize == 32 && "unhandled elt size");
 1701   assert(RC && "Register class for the reg not found");
 1708   assert(RC && "Register class for the reg not found");
 1912   assert(Def->modifiesRegister(Reg, this));
lib/Target/AMDGPU/SIShrinkInstructions.cpp
   73   assert(TII->isVOP1(MI) || TII->isVOP2(MI) || TII->isVOPC(MI));
  105           assert(MRI.use_empty(Reg));
  283         assert(
  457   assert(MovT.getOpcode() == AMDGPU::V_MOV_B32_e32 ||
lib/Target/AMDGPU/SIWholeQuadMode.cpp
  252   assert(!(Flag & StateExact) && Flag != 0);
  462   assert(!(II.Needs & StateExact));
  616     assert(Idx == LIS->getMBBEndIdx(&MBB));
  672   assert(SaveOrig);
  683   assert(SavedOrig);
  792         assert(SavedNonWWMReg);
  811           assert(WQMFromExec == (SavedWQMReg == 0));
  823           assert(Needs & State);
lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
  274   assert(FlatWorkGroupSize != 0);
  357   assert(WavesPerEU != 0);
  375   assert(WavesPerEU != 0);
  450   assert(WavesPerEU != 0);
  461   assert(WavesPerEU != 0);
  824   assert(msgRequiresOp(MsgId));
 1022   MAP_REG2REG
 1040   assert(OpNo < Desc.NumOperands);
 1047   assert(OpNo < Desc.NumOperands);
 1071   assert(OpNo < Desc.NumOperands);
 1134   assert(OpNo < Desc.NumOperands);
 1202   assert(HasInv2Pi);
lib/Target/AMDGPU/Utils/AMDKernelCodeTUtils.cpp
   50   assert(names.size() == altNames.size());
lib/Target/ARC/ARCBranchFinalize.cpp
  100   assert(isBRccPseudo(MI) && "Can't get BRcc for wrong instruction.");
  107   assert(isBRccPseudo(MI) && "Can't get BRcc for wrong instruction.");
lib/Target/ARC/ARCFrameLowering.cpp
   64   assert((AbsAmount % 4 == 0) && "Stack adjustments must be 4-byte aligned.");
   81     assert(Reg.getReg() >= ARC::R13 && Reg.getReg() <= ARC::R25 &&
  483       assert((Old.getOpcode() == ARC::ADJCALLSTACKDOWN ||
lib/Target/ARC/ARCISelLowering.cpp
  171   assert(LHS.getValueType() == MVT::i32 && "Only know how to SELECT_CC i32");
  181   assert(Op.getValueType() == MVT::i32 &&
  205   assert(LHS.getValueType() == MVT::i32 && "Only know how to BR_CC i32");
  288       assert(VA.isMemLoc() && "Must be register or memory argument.");
  347   assert(Mask && "Missing call preserved mask for calling convention");
  386       assert(VA.isMemLoc() && "Must be memory location.");
  500       assert(VA.isMemLoc());
  503       assert((ObjSize <= StackSlotSize) && "Unhandled argument");
  635     assert(VA.isMemLoc());
  717   assert(cast<ConstantSDNode>(Op.getOperand(0))->getZExtValue() == 0 &&
lib/Target/ARC/ARCInstrInfo.cpp
  205       assert(!FBB && "FBB should have been null.");
  256   assert(!BytesRemoved && "Code size not handled");
  285   assert(ARC::GPR32RegClass.contains(SrcReg) &&
  287   assert(ARC::GPR32RegClass.contains(DestReg) &&
  308   assert(MMO && "Couldn't get MachineMemOperand for store to stack.");
  309   assert(TRI->getSpillSize(*RC) == 4 &&
  311   assert(ARC::GPR32RegClass.hasSubClassEq(RC) &&
  335   assert(MMO && "Couldn't get MachineMemOperand for store to stack.");
  336   assert(TRI->getSpillSize(*RC) == 4 &&
  338   assert(ARC::GPR32RegClass.hasSubClassEq(RC) &&
  352   assert((Cond.size() == 3) && "Invalid ARC branch condition!");
  375   assert(!BytesAdded && "Code size not handled.");
  378   assert(TBB && "InsertBranch must not be told to insert a fallthrough");
  379   assert((Cond.size() == 3 || Cond.size() == 0) &&
lib/Target/ARC/ARCMCInstLower.cpp
   62   assert(Symbol && "Symbol creation failed.\n");
   69   assert(Offset > 0);
lib/Target/ARC/ARCMachineFunctionInfo.h
   47     assert(!ReturnStackOffsetSet && "Return stack offset set twice");
   53     assert(ReturnStackOffsetSet && "Return stack offset not set");
lib/Target/ARC/ARCOptAddrMode.cpp
  129     assert(MI.getOperand(2).isImm() && "Expected immediate operand");
  142   assert(Register::isVirtualRegister(VReg) && "Expected virtual register!");
  152         assert(InstBB != MBB && "Instruction found in empty MBB");
  188   assert((Ldst.mayLoad() || Ldst.mayStore()) && "LD/ST instruction expected");
  201   assert(Base.isReg() && "Base operand must be register");
  253     assert(NewOpcode > 0 && "No postincrement form found");
  266   assert(Ldst && Add && "NULL instruction passed");
  344   assert(Incr.isImm() && "Expected immediate increment");
  370       assert(isValidIncrementOffset(NewOffset) &&
  376       assert(MO.isImm() && "expected immediate operand");
  378       assert(isValidLoadStoreOffset(NewOffset) &&
lib/Target/ARC/ARCRegisterInfo.cpp
   42   assert(RS && "Need register scavenger.");
   67       assert(BaseReg && "Register scavenging failed.");
   84     assert((Offset % 4 == 0) && "LD needs 4 byte alignment.");
   88     assert((Offset % 2 == 0) && "LDH needs 2 byte alignment.");
   99     assert((Offset % 4 == 0) && "ST needs 4 byte alignment.");
  102     assert((Offset % 2 == 0) && "STH needs 2 byte alignment.");
  168   assert(SPAdj == 0 && "Unexpected");
  210   assert(ARC::GPR32RegClass.contains(Reg) && "Unexpected register operand");
  215       assert((Offset >= 0 && Offset < StackSize) && "SP Offset not in bounds.");
  218       assert((Offset < 0 && -Offset <= StackSize) &&
lib/Target/ARC/MCTargetDesc/ARCInstPrinter.cpp
  120     assert(SRE && CE && "Binary expression must be sym+const.");
  124     assert(SRE && "Unexpected MCExpr type.");
  126   assert(SRE->getKind() == MCSymbolRefExpr::VK_None);
  152   assert(Op.isExpr() && "unknown operand kind in printOperand");
  160   assert(base.isReg() && "Base should be register.");
  161   assert(offset.isImm() && "Offset should be immediate.");
  170   assert(Op.isImm() && "Predicate operand is immediate.");
  177   assert(Op.isImm() && "Predicate operand is immediate.");
lib/Target/ARM/A15SDOptimizer.cpp
  161   assert(MO->isReg() && "Non-register operand found!");
  541     assert(MRI->getRegClass(Reg)->hasSuperClassEq(&ARM::SPRRegClass) &&
lib/Target/ARM/ARMAsmPrinter.cpp
   81   assert(Size && "C++ constructor pointer had zero size!");
   84   assert(GV && "C++ constructor pointer was not a GlobalValue!");
  189   assert(MO.isGlobal() && "caller should check MO.isGlobal");
  207     assert(Register::isPhysicalRegister(Reg));
  208     assert(!MO.getSubReg() && "Subregs should be eliminated!");
  455   assert(MO.isReg() && "unexpected inline asm memory operand");
  732         assert((WCharWidth == 2 || WCharWidth == 4) &&
  743         assert((EnumWidth == 1 || EnumWidth == 4) &&
  824     assert(Subtarget->isTargetWindows() &&
  904     assert(ACPV->isExtSymbol() && "unrecognized constant pool value");
 1013   assert((OffsetWidth == 1 || OffsetWidth == 2) && "invalid tbb/tbh width");
 1065   assert(MI->getFlag(MachineInstr::FrameSetup) &&
 1094     assert(DstReg == ARM::SP &&
 1116       assert(SrcReg == ARM::SP &&
 1130           assert(RegList.empty() &&
 1148       assert(MI->getOperand(2).getReg() == ARM::SP &&
 1193         assert(CPI != -1U && "Invalid constpool index");
 1197         assert(!CPE.isMachineConstantPoolEntry() && "Invalid constpool entry");
 1262   assert(!convertAddSubFlagsOpcode(MI->getOpcode()) &&
 1314     assert(Subtarget->hasV4TOps());
 1668     assert(MI->getOperand(1).isKill() && "We need the index register as scratch!");
 2016     assert(Subtarget->hasV4TOps());
lib/Target/ARM/ARMBaseInstrInfo.cpp
  351       assert(!FBB && "FBB should have been null.");
  403   assert(!BytesRemoved && "code size not handled");
  434   assert(!BytesAdded && "code size not handled");
  443   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  444   assert((Cond.size() == 2 || Cond.size() == 0) &&
  579   assert(Opc.isImm());
  580   assert(Offset.isReg());
  762     assert(!I->isBundle() && "No nested bundle!");
  930     assert(ARM::GPRRegClass.contains(SrcReg));
  936     assert(ARM::GPRRegClass.contains(DestReg));
  942     assert(ARM::GPRRegClass.contains(SrcReg));
  948     assert(ARM::GPRRegClass.contains(DestReg));
  955   assert(Opc && "Impossible reg-to-reg copy");
  971     assert(Dst && Src && "Bad sub-register");
  973     assert(!DstRegs.count(Src) && "destructive vector copy");
 1569     assert(getSubtarget().getTargetTriple().isOSBinFormatMachO() &&
 1654   assert(MCPE.isMachineConstantPoolEntry() &&
 1925   assert(Offset2 > Offset1);
 2216   assert((MI.getOpcode() == ARM::MOVCCr || MI.getOpcode() == ARM::t2MOVCCr) &&
 2237   assert((MI.getOpcode() == ARM::MOVCCr || MI.getOpcode() == ARM::t2MOVCCr) &&
 2379     assert(ThisVal && "Didn't extract field correctly");
 2384     assert(ARM_AM::getSOImmVal(ThisVal) != -1 && "Bit extraction didn't work?");
 2420   assert((IsT1PushPop || (MI->getOperand(0).getReg() == ARM::SP &&
 2565     assert(ARM_AM::getSOImmVal(ThisImmVal) != -1 &&
 2627     assert((Offset & (Scale-1)) == 0 && "Can't encode this offset!");
 3169   assert(!isPredicated(*MI) && "Can't use flags from predicated instruction");
 3338     assert(UOps >= 0 && "bad # UOps");
 4027   assert(II->isInsideBundle() && "Empty bundle?");
 4038   assert(Idx != -1 && "Cannot find bundled definition!");
 4049   assert(II->isInsideBundle() && "Empty bundle?");
 4770   assert(!Subtarget.isROPI() && !Subtarget.isRWPI() &&
 4882   assert(DReg && "S-register with no D super-register?");
 4943     assert(!isPredicated(MI) && "Cannot predicate a VORRd");
 4946     assert(Subtarget.hasNEON() && "VORRd requires NEON");
 4965     assert(!isPredicated(MI) && "Cannot predicate a VGETLN");
 4992     assert(!isPredicated(MI) && "Cannot predicate a VSETLN");
 5143   assert(TRI && "Need TRI instance");
 5199   assert(OpNum < MI.getDesc().getNumDefs() && "OpNum is not a def");
 5200   assert(TRI && "Need TRI instance");
 5204   assert(Register::isPhysicalRegister(Reg) &&
 5211     assert(TRI->isSuperRegister(Reg, DReg) && "Register enums broken");
 5214   assert(ARM::DPRRegClass.contains(DReg) && "Can only break D-reg deps");
 5215   assert(MI.definesRegister(DReg, TRI) && "MI doesn't clobber full D-reg");
 5252   assert(DefIdx < MI.getDesc().getNumDefs() && "Invalid definition index");
 5253   assert(MI.isRegSequenceLike() && "Invalid kind of instruction");
 5279   assert(DefIdx < MI.getDesc().getNumDefs() && "Invalid definition index");
 5280   assert(MI.isExtractSubregLike() && "Invalid kind of instruction");
 5302   assert(DefIdx < MI.getDesc().getNumDefs() && "Invalid definition index");
 5303   assert(MI.isInsertSubregLike() && "Invalid kind of instruction");
lib/Target/ARM/ARMBaseInstrInfo.h
  448     assert(isFrameInstr(MI));
lib/Target/ARM/ARMBaseRegisterInfo.cpp
  114   assert(MF && "Invalid MachineFunction pointer.");
  147   assert(MF.getSubtarget<ARMSubtarget>().isTargetDarwin() &&
  218   assert(checkAllSuperRegsMarked(Reserved));
  551     assert(i < MI->getNumOperands() &&"Instr doesn't have FrameIndex operand!");
  665   assert(!AFI->isThumb1OnlyFunction() &&
  670     assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
  676     assert(AFI->isThumb2Function());
  679   assert(Done && "Unable to resolve frame index!");
  689     assert(i+1 < MI->getNumOperands() && "Instr doesn't have FrameIndex operand!");
  759   assert(!AFI->isThumb1OnlyFunction() &&
  772     assert(TFI->hasReservedCallFrame(MF) &&
  775     assert(!MF.getFrameInfo().hasVarSizedObjects() &&
  781   assert(!MI.isDebugValue() && "DBG_VALUEs should be handled in target-independent code");
  788     assert(AFI->isThumb2Function());
  797   assert(
  827       assert(AFI->isThumb2Function());
lib/Target/ARM/ARMBasicBlockInfo.cpp
   85     assert(I != MBB->end() && "Didn't find MI in its own basic block?");
  118   assert(BB->getParent() == &MF &&
lib/Target/ARM/ARMCallLowering.cpp
   97     assert((Size == 1 || Size == 2 || Size == 4 || Size == 8) &&
  117     assert(VA.isRegLoc() && "Value shouldn't be assigned to reg");
  118     assert(VA.getLocReg() == PhysReg && "Assigning to the wrong reg?");
  120     assert(VA.getValVT().getSizeInBits() <= 64 && "Unsupported value size");
  121     assert(VA.getLocVT().getSizeInBits() <= 64 && "Unsupported location size");
  130     assert((Size == 1 || Size == 2 || Size == 4 || Size == 8) &&
  142     assert(Arg.Regs.size() == 1 && "Can't handle multple regs yet");
  145     assert(VA.needsCustom() && "Value doesn't need custom handling");
  146     assert(VA.getValVT() == MVT::f64 && "Unsupported type");
  149     assert(NextVA.needsCustom() && "Value doesn't need custom handling");
  150     assert(NextVA.getValVT() == MVT::f64 && "Unsupported type");
  152     assert(VA.getValNo() == NextVA.getValNo() &&
  155     assert(VA.isRegLoc() && "Value should be in reg");
  156     assert(NextVA.isRegLoc() && "Value should be in reg");
  200   assert(OrigArg.Regs.size() == SplitVTs.size() && "Regs / types mismatch");
  268   assert(!Val == VRegs.empty() && "Return value without a vreg");
  294     assert((Size == 1 || Size == 2 || Size == 4 || Size == 8) &&
  311     assert((Size == 1 || Size == 2 || Size == 4 || Size == 8) &&
  319       assert(MRI.getType(ValVReg).isScalar() && "Only scalars supported atm");
  339     assert(VA.isRegLoc() && "Value shouldn't be assigned to reg");
  340     assert(VA.getLocReg() == PhysReg && "Assigning to the wrong reg?");
  345     assert(ValSize <= 64 && "Unsupported value size");
  346     assert(LocSize <= 64 && "Unsupported location size");
  352       assert(ValSize < LocSize && "Extensions not supported");
  366     assert(Arg.Regs.size() == 1 && "Can't handle multple regs yet");
  369     assert(VA.needsCustom() && "Value doesn't need custom handling");
  370     assert(VA.getValVT() == MVT::f64 && "Unsupported type");
  373     assert(NextVA.needsCustom() && "Value doesn't need custom handling");
  374     assert(NextVA.getValVT() == MVT::f64 && "Unsupported type");
  376     assert(VA.getValNo() == NextVA.getValNo() &&
  379     assert(VA.isRegLoc() && "Value should be in reg");
  380     assert(NextVA.isRegLoc() && "Value should be in reg");
lib/Target/ARM/ARMCallingConv.cpp
   77     assert((!Reg || Reg == ARM::R3) && "Wrong GPRs usage for f64");
   97   assert(T == LoRegList[i] && "Could not allocate register");
  181     assert(PendingMembers[0].getLocVT() == LocVT);
lib/Target/ARM/ARMCodeGenPrepare.cpp
  483     assert((isa<ConstantInt>(I->getOperand(1)) &&
  507     assert(V->getType() != ExtTy && "zext already extends to i32");
  587     assert(EnableDSP && "DSP intrinisc insertion not enabled!");
  689       assert(Trunc->getOperand(0)->getType() == ExtTy &&
  743   assert(isa<IntegerType>(OrigTy) && "expected integer type");
  745   assert(OrigTy->getPrimitiveSizeInBits() < ExtTy->getPrimitiveSizeInBits() &&
lib/Target/ARM/ARMConstantIslandPass.cpp
  305   assert(std::is_sorted(MF->begin(), MF->end(),
  522     assert(isPowerOf2_32(Align) && "Invalid alignment");
  525     assert((Size % Align) == 0 && "CP Entry not multiple of 4 bytes!");
  670   assert(CPI < MCP->getConstants().size() && "Invalid constant pool index.");
  848           assert(CPE && "Cannot find a corresponding CPEntry!");
 1109   assert(CPE && "Unexpected!");
 1327   assert(Align >= CPEAlign && "Over-aligned constant pool entry");
 1374       assert(I != UserMBB->end() && "Fell off end of block");
 1388     assert(MI != UserMBB->end() && "Fell off end of block");
 1430     assert(MI->getOpcode() == ARM::t2MOVi16 &&
 1438   assert(!isThumb || getITInstrPredicate(*MI, PredReg) == ARMCC::AL);
 1579   assert(!BBIsJumpedOver(CPEBB) && "How did this happen?");
 2174     assert(JTI < JT.size());
 2368     assert(JTI < JT.size());
lib/Target/ARM/ARMExpandPseudoInsts.cpp
   98     assert(MO.isReg() && MO.getReg());
  420     assert(std::is_sorted(std::begin(NEONLdStTable), std::end(NEONLdStTable)) &&
  459     assert(RegSpc == OddDblSpc && "unknown register spacing");
  475   assert(TableEntry && TableEntry->IsLoad && "NEONLdStTable lookup failed");
  492       assert(RegSpc == OddDblSpc && "Unexpected spacing!");
  536       assert(AM6Offset.getReg() == 0 &&
  586   assert(TableEntry && !TableEntry->IsLoad && "NEONLdStTable lookup failed");
  617       assert(AM6Offset.getReg() == 0 &&
  662   assert(TableEntry && "NEONLdStTable lookup failed");
  675   assert(RegSpc != OddDblSpc && "unexpected register spacing for VLD/VST-lane");
  680   assert(Lane < RegElts && "out of range lane for VLD/VST-lane");
  843     assert(!STI->isTargetWindows() && "Windows on ARM requires ARMv7+");
  851     assert (MO.isImm() && "MOVi32imm w/ non-immediate source operand!");
  939   assert(!MI.getOperand(2).isUndef() && "cannot handle undef");
 1058   assert(!MI.getOperand(2).isUndef() && "cannot handle undef");
 1165       assert(MBBI->isReturn() &&
 1187           assert(JumpTarget.isSymbol());
 1344         assert(MF.getSubtarget().getFrameLowering()->hasFP(MF) &&
 1362           assert (!AFI->isThumb1OnlyFunction());
 1364           assert(MaxAlign <= 256 && "The BIC instruction cannot encode "
 1928       assert(Reg == ARM::LR && "expect LR register!");
lib/Target/ARM/ARMFastISel.cpp
 1002   assert(ResultReg > 255 && "Expected an allocated virtual register.");
 1338   assert(isThumb2 || Subtarget->hasV4TOps());
 1633     assert(VT == MVT::i32 && "Expecting an i32.");
 1715   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported SDIV!");
 1744   assert(LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported SREM!");
 1958     assert((!ArgVT.isVector() && ArgVT.getSizeInBits() <= 64) &&
 1967         assert(Arg != 0 && "Failed to emit a sext");
 1976         assert(Arg != 0 && "Failed to emit a zext");
 1983         assert(BC != 0 && "Failed to emit a bitcast!");
 1998       assert(VA.getLocVT() == MVT::f64 &&
 2004       assert(VA.isRegLoc() && NextVA.isRegLoc() &&
 2014       assert(VA.isMemLoc());
 2027       assert(EmitRet && "Could not emit a store for argument!");
 2067       assert(RVLocs.size() == 1 &&"Can't handle non-double multi-reg retvals!");
 2146       assert(DestVT == MVT::i32 && "ARM should always ext to i32");
 2193   assert(GV->getType() == GVTy && "We miscomputed the type for the global!");
 2456         assert(Len == 1 && "Expected a length of 1!");
 2471     assert(RV && "Should be able to handle this load.");
 2473     assert(RV && "Should be able to handle this store.");
 2675   assert((SrcBits < DestBits) && "can only extend to larger types");
 2676   assert((DestBits == 32 || DestBits == 16 || DestBits == 8) &&
 2678   assert((SrcBits == 16 || SrcBits == 8 || SrcBits == 1) &&
 2683   assert((Bitness < 3) && "sanity-check table bounds");
 2689   assert(ARM::KILL != Opc && "Invalid table entry");
 2692   assert(((Shift == ARM_AM::no_shift) == (Opc != ARM::MOVsi)) &&
lib/Target/ARM/ARMFrameLowering.cpp
   92   assert(MF.getFunction().hasFnAttribute(Attribute::NoReturn) &&
  247     assert(Info != Insts.end() && "invalid sp adjusting instruction");
  291   assert(!AFI->isThumb1OnlyFunction() && "Thumb1 not supported");
  314       assert(!MustBeSingleInstruction &&
  332     assert(CanUseBFC);
  367   assert(!AFI->isThumb1OnlyFunction() &&
  467     assert(getMaxFPOffset(MF.getFunction(), *AFI) <= FPOffset &&
  486     assert(DPRGapSize == 4 && "unexpected alignment requirements for DPRs");
  721     assert(!AFI->isThumb1OnlyFunction());
  777   assert(!AFI->isThumb1OnlyFunction() &&
  831           assert(!MFI.getPristineRegs(MF).test(ARM::R4) &&
  864       assert(AFI->getDPRCalleeSavedGapSize() == 4 &&
  909     assert(hasFP(MF) && "dynamic stack realignment without a FP!");
  914       assert(RegInfo->hasBasePointer(MF) &&
  930       assert(RegInfo->hasBasePointer(MF) && "missing base pointer!");
 1203   assert(!AFI->isThumb1OnlyFunction() && "Can't realign stack for thumb1");
 1311   assert(MI->mayStore() && "Expecting spill instruction");
 1317     assert(MI->mayStore() && "Expecting spill instruction");
 1321     assert(MI->mayStore() && "Expecting spill instruction");
 1326     assert(MI->killsRegister(ARM::R4) && "Missed kill flag");
 1359   assert(!AFI->isThumb1OnlyFunction() && "Can't realign stack for thumb1");
 2013         assert(!MRI.isReserved(Reg) && "Should not be reserved");
 2164       assert(!AFI->isThumb1OnlyFunction() &&
 2179         assert(Opc == ARM::ADJCALLSTACKUP || Opc == ARM::tADJCALLSTACKUP);
 2436     assert(ST->isTargetAndroid() || ST->isTargetLinux());
lib/Target/ARM/ARMHazardRecognizer.cpp
   35   assert(Stalls == 0 && "ARM hazards don't support scoreboard lookahead");
lib/Target/ARM/ARMISelDAGToDAG.cpp
  331   assert(Scale > 0 && "Invalid scale!");
  490   assert(N.getOpcode() == ISD::MUL);
  491   assert(MaxShift > 0);
  594   assert(Parent->getOpcode() == ISD::OR && "unexpected parent");
 1858   assert((isVLDfixed(Opc) || isVSTfixed(Opc))
 1925   assert(NumVecs >= 1 && NumVecs <= 4 && "VLD NumVecs out-of-range");
 2024       assert(isa<ConstantSDNode>(Inc.getNode()) &&
 2064   assert(NumVecs >= 1 && NumVecs <= 4 && "VST NumVecs out-of-range");
 2196     assert(isa<ConstantSDNode>(Inc.getNode()) &&
 2215   assert(NumVecs >=2 && NumVecs <= 4 && "VLDSTLane NumVecs out-of-range");
 2506   assert(NumVecs >= 1 && NumVecs <= 4 && "VLDDup NumVecs out-of-range");
 2654         assert(Srl_imm > 0 && Srl_imm < 32 && "bad amount in shift node!");
 2689         assert(LSB + Width + 1 <= 32 && "Shouldn't create an invalid ubfx");
 2704     assert(Shl_imm > 0 && Shl_imm < 32 && "bad amount in shift node!");
 2707       assert(Srl_imm > 0 && Srl_imm < 32 && "bad amount in shift node!");
 2714       assert(LSB + Width + 1 <= 32 && "Shouldn't create an invalid ubfx");
 2731       assert(Srl_imm > 0 && Srl_imm < 32 && "bad amount in shift node!");
 2736       assert(Srl_imm + Width + 1 <= 32 && "Shouldn't create an invalid ubfx");
 2757     assert(LSB + Width <= 32 && "Shouldn't create an invalid ubfx");
 2846   assert(N->getOpcode() == ARMISD::CMPZ);
 3252       assert(Subtarget->hasThumb2() &&
 3329     assert(N1.getOpcode() == ISD::BasicBlock);
 3330     assert(N2.getOpcode() == ISD::Constant);
 3331     assert(N3.getOpcode() == ISD::Register);
 3541       assert(NumElts == 2 && "unexpected type for BUILD_VECTOR");
 3546     assert(EltVT == MVT::f32 && "unexpected type for BUILD_VECTOR");
 3552     assert(NumElts == 4 && "unexpected type for BUILD_VECTOR");
 4312     assert(AllIntFields &&
 4434       assert(Ops.size() == 3 &&
 4548       assert(Ops.size() == 3 &&
 4706     assert((i+2 < NumOps) && "Invalid number of operands in inline asm");
lib/Target/ARM/ARMISelLowering.cpp
 1943       assert(!VA.needsCustom() && VA.getLocVT() == MVT::i32 &&
 2035     assert(NextVA.isMemLoc());
 2172           assert(VA.isMemLoc());
 2184         assert(VA.getLocVT() == MVT::i32 &&
 2186         assert(!Ins.empty() && Ins[0].VT == MVT::i32 &&
 2195       assert(VA.isMemLoc());
 2246       assert(VA.isMemLoc());
 2284     assert((!isPositionIndependent() || Subtarget->isTargetWindows()) &&
 2325         assert(Subtarget->isTargetMachO() && "WrapperPIC use on non-MachO?");
 2335         assert(Subtarget->isTargetWindows() &&
 2418     assert(Mask && "Missing call preserved mask for calling convention");
 2542   assert(FI != std::numeric_limits<int>::max());
 2562   assert(Subtarget->supportsTailCall());
 2749     assert(VA.isRegLoc() && "Can only return in registers!");
 2962   assert(WriteValue.getValueType() == MVT::i64
 3078   assert(Subtarget->isTargetDarwin() &&
 3123   assert(Subtarget->isTargetWindows() && "Windows specific TLS lowering");
 3254     assert(model == TLSModel::LocalExec);
 3282   assert(Subtarget->isTargetELF() && "Only ELF implemented here");
 3504   assert(!Subtarget->isROPI() && !Subtarget->isRWPI() &&
 3529   assert(Subtarget->isTargetWindows() && "non-Windows COFF is not supported");
 3530   assert(Subtarget->useMovt() &&
 3532   assert(!Subtarget->isROPI() && !Subtarget->isRWPI() &&
 3600       assert(Mask && "Missing call preserved mask for calling convention");
 3766     assert(Subtarget->hasV6Ops() && !Subtarget->isThumb() &&
 3992     assert(VA.isMemLoc() && "unexpected byval pointer in reg");
 4103       assert(VA.isMemLoc());
 4104       assert(VA.getValVT() != MVT::i64 && "i64 should already be lowered");
 4119             assert(Ins[index].isOrigArg() &&
 4324   assert(Subtarget->hasFP64() || RHS.getValueType() != MVT::f64);
 4342   assert(Opc == ARMISD::FMSTAT && "unexpected comparison operation");
 4348     assert(Opc == ARMISD::CMPFPw0 && "unexpected operand of FMSTAT");
 4361   assert(Op.getValueType() == MVT::i32 &&  "Unsupported value type");
 4594         assert(True.getValueType() == VT);
 5389   assert((Op.getOperand(0).getValueType() == MVT::v4i16 ||
 5588   assert(N->getValueType(0) == MVT::i64
 5779   assert(VT.isVector() && "Expected a vector type");
 5791   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 5802   assert(Op.getOpcode() == ISD::SRA_PARTS || Op.getOpcode() == ISD::SRL_PARTS);
 5835   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 5845   assert(Op.getOpcode() == ISD::SHL_PARTS);
 5950   assert(ST->hasNEON() && "Custom ctpop lowering requires NEON.");
 5951   assert((VT == MVT::v1i64 || VT == MVT::v2i64 || VT == MVT::v2i32 ||
 6003   assert(VT.isVector() && "vector shift count is not a vector type");
 6018   assert(VT.isVector() && "vector shift count is not a vector type");
 6054   assert((N->getOpcode() == ISD::SRA || N->getOpcode() == ISD::SRL) &&
 6083   assert((N->getOpcode() == ISD::SRL || N->getOpcode() == ISD::SRA ||
 6173     assert(ST->hasMVEIntegerOps() &&
 6343   assert(LHS.getSimpleValueType().isInteger() && "SETCCCARRY is integer only.");
 6388     assert((SplatBits & ~0xff) == 0 && "one byte splat value is too big");
 6691   assert((BlockSize==16 || BlockSize==32 || BlockSize==64) &&
 7036   assert(ST->hasMVEIntegerOps() && "LowerBUILD_VECTOR_i1 called without MVE!");
 7244       assert(FVT == MVT::f32 || FVT == MVT::f16);
 7333   assert(Op.getOpcode() == ISD::BUILD_VECTOR && "Unknown opcode!");
 7473     assert(ShuffleVT.getVectorElementType() == SmallestEltTy);
 7482                  assert(Src.ShuffleVec.getValueType() == ShuffleVT););
 7516   assert(Sources.size() <= 2 && "Too many sources!");
 7623     assert(LHSID == ((4*9+5)*9+6)*9+7 && "Illegal OP_COPY!");
 7643     assert(VT.getVectorElementType() == MVT::i8);
 7699   assert((VT == MVT::v8i16 || VT == MVT::v16i8) &&
 7764   assert(ST->hasMVEIntegerOps() &&
 7913       assert(llvm::all_of(ShuffleMask, [&](int i) {
 7921         assert((WhichResult == 0) &&
 8000   assert(ST->hasMVEIntegerOps() &&
 8040     assert(getTypeAction(*DAG.getContext(), IEltVT) !=
 8063   assert(ST->hasMVEIntegerOps() &&
 8107   assert(Op1VT == Op2VT && "Operand types don't match!");
 8108   assert(VT.getScalarSizeInBits() == 1 &&
 8110   assert(ST->hasMVEIntegerOps() &&
 8157   assert(Op.getValueType().is128BitVector() && Op.getNumOperands() == 2 &&
 8184   assert(VT.getScalarSizeInBits() == 1 &&
 8186   assert(ST->hasMVEIntegerOps() &&
 8289   assert(OrigVT.isSimple() && "Expecting a simple value type");
 8312   assert(ExtTy.is128BitVector() && "Unexpected extension size");
 8359     assert((ISD::isSEXTLoad(LD) || ISD::isZEXTLoad(LD)) &&
 8376     assert(BVN->getOpcode() == ISD::BUILD_VECTOR &&
 8384   assert(N->getOpcode() == ISD::BUILD_VECTOR && "expected BUILD_VECTOR");
 8427   assert(VT.is128BitVector() && VT.isInteger() &&
 8474     assert(Op0.getValueType().is64BitVector() &&
 8571   assert((VT == MVT::v4i16 || VT == MVT::v8i8) &&
 8608   assert((VT == MVT::v4i16 || VT == MVT::v8i8) &&
 8726   assert(Subtarget->isTargetDarwin());
 8804   assert((VT == MVT::i32 || VT == MVT::i64) &&
 8882   assert(Op.getValueType() == MVT::i32 &&
 8911   assert(Op.getValueType() == MVT::i64 &&
 8931   assert((MemVT == MVT::v4i1 || MemVT == MVT::v8i1 || MemVT == MVT::v16i1) &&
 8933   assert(MemVT == Op.getValueType());
 8934   assert(LD->getExtensionType() == ISD::NON_EXTLOAD &&
 8936   assert(LD->isUnindexed() && "Expected a unindexed load");
 8961   assert((MemVT == MVT::v4i1 || MemVT == MVT::v8i1 || MemVT == MVT::v16i1) &&
 8963   assert(MemVT == ST->getValue().getValueType());
 8964   assert(!ST->isTruncatingStore() && "Expected a non-extending store");
 8965   assert(ST->isUnindexed() && "Expected a unindexed store");
 9072   assert(N->getValueType(0) == MVT::i64 &&
 9100   assert(Subtarget.getTargetTriple().isOSMSVCRT() &&
 9300     assert(Res.getNumOperands() == 2 && "DivRem needs two values");
 9313     assert(Subtarget->isTargetWindows() && "can only expand DIV on Windows");
 9340   assert(!Subtarget->isROPI() && !Subtarget->isRWPI() &&
 9517   assert(!LPadList.empty() &&
 9931   assert(LdOpc != 0 && "Should have a load opcode");
 9972   assert(StOpc != 0 && "Should have a store opcode");
10261   assert(Subtarget->isTargetWindows() &&
10263   assert(Subtarget->isThumb2() && "Windows on ARM requires Thumb-2 mode");
10737     assert(MCID->getNumOperands() ==
10775     assert(!NewOpc && "Optional cc_out operand required");
10794     assert(!NewOpc && "Optional cc_out operand required");
10797   assert(deadCPSR == !Node->hasAnyUseOfValue(1) && "inconsistent dead flag");
10799     assert(!MI.getOperand(ccOutIdx).getReg() &&
11244   assert((AddeSubeNode->getOpcode() == ARMISD::ADDE ||
11248   assert(AddeSubeNode->getNumOperands() == 3 &&
11267   assert(AddcSubcNode->getNumValues() == 2 &&
12441   assert(N->getOpcode() == ARMISD::BFI);
12452     assert(Shift.getLimitedValue() < 32 && "Shift too large!");
12525     assert(Width <
12548     assert(From1 == From2);
12702   assert(EltVT == MVT::f32 && "Unexpected type!");
12969       assert(isStore && "Node has to be a load, a store, or an intrinsic!");
13011         assert(NumVecs == 1 && "Unexpected multi-element generic load/store.");
13012         assert(!isLaneOp && "Unexpected generic load/store lane.");
13262   assert(StVT != VT && "Cannot truncate to the same type");
13276   assert(SizeRatio * NumElems * ToEltSz == VT.getSizeInBits());
13281   assert(WideVecVT.getSizeInBits() == VT.getSizeInBits());
13313   assert(StoreVecVT.getSizeInBits() == VT.getSizeInBits());
13349   assert(FromVT.getVectorNumElements() == ToVT.getVectorNumElements());
13841   assert(FromVT.getVectorNumElements() == ToVT.getVectorNumElements());
13967   assert(CmpZ->getOpcode() == ARMISD::CMPZ);
13981     assert(CC == ARMCC::NE && "How can a CMPZ node not be EQ or NE?");
14103     assert(N->getOpcode() == ISD::BR_CC && "Expected BRCOND or BR_CC!");
14138   assert((IsTrueIfZero(CC, Imm) || IsFalseIfZero(CC, Imm)) &&
14145   assert((N->hasOneUse() && N->use_begin()->getOpcode() == ISD::BR)
14843   assert(Ty1->getPrimitiveSizeInBits() <= 64 && "i128 is probably not a noop");
15136         assert(Ptr->getOpcode() == ISD::ADD);
15150         assert(Ptr->getOpcode() == ISD::ADD);
15193       assert(Ptr->getOpcode() == ISD::ADD);
15221       assert(Ptr->getOpcode() == ISD::ADD);
15331     assert(Op->getValueType(0) == MVT::i32 && "Non-i32 post-inc op?!");
15445     assert(VecVT.isVector() && "VGETLANE expected a vector type");
15448     assert(Pos->getAPIntValue().ult(NumSrcElts) &&
15458     assert(SrcSz == Known.getBitWidth());
15459     assert(DstSz > SrcSz);
15465     assert(DstSz == Known.getBitWidth());
15490   assert(VT == MVT::i32 && "Unexpected integer type");
15918   assert((N->getOpcode() == ISD::SDIVREM || N->getOpcode() == ISD::UDIVREM ||
15936   assert((N->getOpcode() == ISD::SDIVREM || N->getOpcode() == ISD::UDIVREM ||
15958   assert((Subtarget->isTargetAEABI() || Subtarget->isTargetAndroid() ||
15963   assert((Opcode == ISD::SDIVREM || Opcode == ISD::UDIVREM) &&
16056   assert(ResNode->getNumOperands() == 2 && "divmod should return two operands");
16062   assert(Subtarget->isTargetWindows() && "unsupported target platform");
16104   assert(DstSz > SrcSz && DstSz <= 64 && SrcSz >= 16 &&
16107   assert((!Subtarget->hasFP64() || !Subtarget->hasFPARMv8Base()) &&
16110   assert(!(DstSz == 32 && Subtarget->hasFP16()) &&
16128       assert(LC != RTLIB::UNKNOWN_LIBCALL &&
16142   assert(LC != RTLIB::UNKNOWN_LIBCALL &&
16154   assert(DstSz < SrcSz && SrcSz <= 64 && DstSz >= 16 &&
16157   assert((!Subtarget->hasFP64() || !Subtarget->hasFPARMv8Base()) &&
16168   assert(LC != RTLIB::UNKNOWN_LIBCALL &&
16176   assert(N->getValueType(0) == MVT::i64 && "Unexpected type (!= i64) on ABS.");
16385   assert(Ty->isIntegerTy());
16583   assert(VectorTy->isVectorTy() && "VectorTy is not a vector type");
16741   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
16743   assert(!Shuffles.empty() && "Empty shufflevector input");
16744   assert(Shuffles.size() == Indices.size() &&
16785   assert(isTypeLegal(EVT::getEVT(VecTy)) && "Illegal vldN vector type!");
16875   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
16879   assert(VecTy->getVectorNumElements() % Factor == 0 &&
16931   assert(isTypeLegal(EVT::getEVT(SubVecTy)) && "Illegal vstN vector type!");
17121     assert(Entry->getParent()->getFunction().hasFnAttribute(
lib/Target/ARM/ARMInstructionSelector.cpp
  189   assert(RegBank && "Can't get reg bank for virtual register");
  192   assert((RegBank->getID() == ARM::GPRRegBankID ||
  235   assert(TII.getSubtarget().hasVFP2Base() && "Can't select merge without VFP");
  241   assert(MRI.getType(VReg0).getSizeInBits() == 64 &&
  246   assert(MRI.getType(VReg1).getSizeInBits() == 32 &&
  251   assert(MRI.getType(VReg2).getSizeInBits() == 32 &&
  266   assert(TII.getSubtarget().hasVFP2Base() &&
  273   assert(MRI.getType(VReg0).getSizeInBits() == 32 &&
  278   assert(MRI.getType(VReg1).getSizeInBits() == 32 &&
  283   assert(MRI.getType(VReg2).getSizeInBits() == 64 &&
  453   assert(Preds.first != ARMCC::AL && "No comparisons needed?");
  632     assert((MIB->getOpcode() == ARM::LDRi12 ||
  774   assert(validReg(MRI, CondReg, 1, ARM::GPRRegBankID) &&
  788   assert(validOpRegPair(MRI, ResReg, TrueReg, 32, ARM::GPRRegBankID) &&
  805   assert(!STI.isThumb() && "Unsupported subtarget");
  814   assert(OldInst.getOpcode() == TargetOpcode::G_FCONSTANT &&
  819   assert(FPImmEncoding != -1 && "Invalid immediate value");
  826   assert(OldInst.getOpcode() == TargetOpcode::G_FCONSTANT &&
  831   assert(FPImmEncoding != -1 && "Invalid immediate value");
  837   assert(I.getParent() && "Instruction should be in a basic block!");
  838   assert(I.getParent()->getParent() && "Instruction should be in a function!");
  864     assert(MRI.getType(I.getOperand(0).getReg()).getSizeInBits() <= 32 &&
  924       assert(I.getOpcode() == G_TRUNC && "Unsupported operand for G_ANYEXT");
  925       assert(DstRegBank.getID() == ARM::GPRRegBankID &&
  927       assert(MRI.getType(SrcReg).getSizeInBits() == 64 && "Unsupported size");
  928       assert(MRI.getType(DstReg).getSizeInBits() <= 32 && "Unsupported size");
  974       assert(Val.isImm() && "Unexpected operand for G_CONSTANT");
  981     assert(!STI.isThumb() && "Unsupported subtarget");
  991     assert((Size == 4 || Size == 8) && "Unsupported FP constant type");
 1039     assert(STI.hasVFP2Base() && "Can't select fcmp without VFP");
 1090     assert((ValSize != 64 || STI.hasVFP2Base()) &&
lib/Target/ARM/ARMLegalizerInfo.cpp
   49   assert(v.size() >= 1);
   50   assert(v[0].first > 17);
  352   assert(CmpInst::isFPPredicate(Predicate) && "Unsupported FCmp predicate");
  397     assert(MRI.getType(MI.getOperand(2).getReg()) ==
  408       assert((Predicate == CmpInst::FCMP_TRUE ||
  417     assert((OpSize == 32 || OpSize == 64) && "Unsupported operand size");
  447         assert(CmpInst::isIntPredicate(ResultPred) && "Unsupported predicate");
  456       assert(Results.size() == 2 && "Unexpected number of results");
lib/Target/ARM/ARMLoadStoreOptimizer.cpp
  487   assert(isThumb1 && "Can only update base register uses for Thumb1!");
  630   assert(NumRegs > 1);
  644     assert(Base != ARM::SP && "Thumb1 does not allow SP in register list");
  748         assert(Offset % 4 == 0 && "tADDrSPi offset is scaled by 4");
  792     assert(isThumb1 && "expected Writeback only inThumb1");
  794       assert(!(ContainsReg(Regs, Base)) && "Thumb1 can't LDM ! with Base in Regs");
  832   assert((IsLoad || isi32Store(Opcode)) && "Must have integer load or store");
  835   assert(Regs.size() == 2);
  876         assert(MO.isImplicit());
  954     assert(isi32Store(Opcode) || Opcode == ARM::VSTRS || Opcode == ARM::VSTRD);
  963     assert(ImpDefs.empty());
 1507   assert((Opcode == ARM::t2LDRDi8 || Opcode == ARM::t2STRDi8) &&
 1545     assert(NewOpc == ARM::t2STRD_PRE || NewOpc == ARM::t2STRD_POST);
 1550   assert(TII->get(Opcode).getNumOperands() == 6 &&
 1685   assert((isT2 || MI->getOperand(3).getReg() == ARM::NoRegister) &&
 1729       assert(!TRI->regsOverlap(OddReg, BaseReg));
 1771   assert(Candidates.size() == 0);
 1772   assert(MergeBaseCandidates.size() == 0);
 1900       assert(Candidate->Instrs.size() == 1);
 1947       assert(((isThumb2 && Opcode == ARM::t2LDMIA_UPD) ||
 1957       assert(MFI.isCalleeSavedInfoValid() && "CSI should be valid");
 1983       assert(STI->hasV4TOps());
 2225     assert(LHS == RHS || LOffset != ROffset);
lib/Target/ARM/ARMMCInstLower.cpp
   80     assert(!MO.getSubReg() && "Subregs should be eliminated!");
lib/Target/ARM/ARMParallelDSP.cpp
  616       assert(PMul0 != PMul1 && "expected different chains");
  652     assert((isa<Instruction>(A) || isa<Instruction>(B)) &&
  680       assert(R.is64Bit() && "expected 64-bit result");
  734   assert(Loads.size() == 2 && "currently only support widening two loads");
  742   assert((BaseSExt && OffsetSExt)
lib/Target/ARM/ARMRegisterBankInfo.cpp
   56   assert(
   59   assert(
   62   assert(
   98   assert(checkValueMapping(ValueMappings[GPR3OpsIdx],
  101   assert(checkValueMapping(ValueMappings[GPR3OpsIdx + 1],
  104   assert(checkValueMapping(ValueMappings[GPR3OpsIdx + 2],
  108   assert(checkValueMapping(ValueMappings[SPR3OpsIdx],
  111   assert(checkValueMapping(ValueMappings[SPR3OpsIdx + 1],
  114   assert(checkValueMapping(ValueMappings[SPR3OpsIdx + 2],
  118   assert(checkValueMapping(ValueMappings[DPR3OpsIdx],
  121   assert(checkValueMapping(ValueMappings[DPR3OpsIdx + 1],
  124   assert(checkValueMapping(ValueMappings[DPR3OpsIdx + 2],
  146   assert(&ARM::GPRRegBank == &RBGPR && "The order in RegBanks is messed up");
  149   assert(RBGPR.covers(*TRI.getRegClass(ARM::GPRRegClassID)) &&
  151   assert(RBGPR.covers(*TRI.getRegClass(ARM::GPRwithAPSRRegClassID)) &&
  153   assert(RBGPR.covers(*TRI.getRegClass(ARM::GPRnopcRegClassID)) &&
  155   assert(RBGPR.covers(*TRI.getRegClass(ARM::rGPRRegClassID)) &&
  157   assert(RBGPR.covers(*TRI.getRegClass(ARM::tGPRRegClassID)) &&
  159   assert(RBGPR.covers(*TRI.getRegClass(ARM::tcGPRRegClassID)) &&
  161   assert(RBGPR.covers(*TRI.getRegClass(ARM::tGPR_and_tcGPRRegClassID)) &&
  163   assert(RBGPR.covers(*TRI.getRegClass(ARM::tGPREven_and_tGPR_and_tcGPRRegClassID)) &&
  165   assert(RBGPR.covers(*TRI.getRegClass(ARM::tGPROdd_and_tcGPRRegClassID)) &&
  167   assert(RBGPR.getSize() == 32 && "GPRs should hold up to 32-bit");
  377     assert(Ty.getSizeInBits() == 32 && "Unsupported size for G_SELECT");
  378     assert(Ty2.getSizeInBits() == 1 && "Unsupported size for G_SELECT");
  389     assert(Ty2.getSizeInBits() == 32 && "Unsupported size for G_ICMP");
  402     assert(Ty.getSizeInBits() == 1 && "Unsupported size for G_FCMP");
  403     assert(Ty1.getSizeInBits() == Ty2.getSizeInBits() &&
  407     assert((Size == 32 || Size == 64) && "Unsupported size for G_FCMP");
  473       assert(
lib/Target/ARM/ARMSubtarget.cpp
  152   assert((!TM.getMCAsmInfo() ||
  189   assert(hasV6T2Ops() || !hasThumb2());
  194     assert(hasV8MBaselineOps() && "Cannot generate execute-only code for this target");
  324   assert(TM.TargetABI != ARMBaseTargetMachine::ARM_ABI_UNKNOWN);
  328   assert(TM.TargetABI != ARMBaseTargetMachine::ARM_ABI_UNKNOWN);
  333   assert(TM.TargetABI != ARMBaseTargetMachine::ARM_ABI_UNKNOWN);
lib/Target/ARM/ARMTargetMachine.cpp
  195     assert(TT.isOSBinFormatELF() &&
lib/Target/ARM/ARMTargetObjectFile.cpp
   63   assert(Encoding == DW_EH_PE_absptr && "Can handle absptr encoding only");
lib/Target/ARM/ARMTargetTransformInfo.cpp
   66   assert(Ty->isIntegerTy());
  151   assert(ISD && "Invalid opcode");
  517   assert(MI && "MemcpyInst expected");
  763   assert(Factor >= 2 && "Invalid interleave factor");
  764   assert(isa<VectorType>(VecTy) && "Expect a vector type");
 1077   assert(isa<VectorType>(Ty) && "Expected Ty to be a vector type");
lib/Target/ARM/AsmParser/ARMAsmParser.cpp
  189     assert(getParser().getStreamer().getTargetStreamer() &&
  239       assert(PendingConditionalInsts.size() == 0);
  251     assert(PendingConditionalInsts.size() <= 4);
  282     assert(inImplicitITBlock());
  283     assert(ITState.CurPosition > 1);
  295     assert(inImplicitITBlock());
  296     assert(ITState.CurPosition == 1);
  329     assert(inImplicitITBlock());
  330     assert(!isITBlockFull());
  331     assert(Cond == ITState.Cond ||
  346     assert(!inITBlock());
  358     assert(!inITBlock());
  874     assert(Kind == k_Memory && "Invalid access!");
  879     assert(Kind == k_CondCode && "Invalid access!");
  884     assert(isVPTPred() && "Invalid access!");
  889     assert((Kind == k_CoprocNum || Kind == k_CoprocReg) && "Invalid access!");
  894     assert(Kind == k_Token && "Invalid access!");
  899     assert((Kind == k_Register || Kind == k_CCOut) && "Invalid access!");
  904     assert((Kind == k_RegisterList || Kind == k_RegisterListWithAPSR ||
  913     assert(isImm() && "Invalid access!");
  918     assert(isConstantPoolImm() && "Invalid access!");
  923     assert(Kind == k_VectorIndex && "Invalid access!");
  928     assert(Kind == k_MemBarrierOpt && "Invalid access!");
  933     assert(Kind == k_InstSyncBarrierOpt && "Invalid access!");
  938     assert(Kind == k_TraceSyncBarrierOpt && "Invalid access!");
  943     assert(Kind == k_ProcIFlags && "Invalid access!");
  948     assert(Kind == k_MSRMask && "Invalid access!");
  953     assert(Kind == k_BankedReg && "Invalid access!");
 2169     assert((Width == 8 || Width == 16 || Width == 32) &&
 2171     assert(NumElems * Width <= 64 && "Invalid result width");
 2205     assert((FromW == 8 || FromW == 16 || FromW == 32) &&
 2207     assert((ToW == 16 || ToW == 32 || ToW == 64) &&
 2209     assert(FromW < ToW && "ToW is not less than FromW");
 2333     assert(N == 1 && "Invalid number of operands!");
 2338     assert(N == 1 && "Invalid number of operands!");
 2343     assert(N == 2 && "Invalid number of operands!");
 2350     assert(N == 2 && "Invalid number of operands!");
 2357     assert(N == 3 && "Invalid number of operands!");
 2366       assert(TiedOp >= 0 &&
 2374     assert(N == 1 && "Invalid number of operands!");
 2379     assert(N == 1 && "Invalid number of operands!");
 2384     assert(N == 1 && "Invalid number of operands!");
 2389     assert(N == 1 && "Invalid number of operands!");
 2394     assert(N == 1 && "Invalid number of operands!");
 2399     assert(N == 1 && "Invalid number of operands!");
 2404     assert(N == 1 && "Invalid number of operands!");
 2409     assert(N == 1 && "Invalid number of operands!");
 2414     assert(N == 3 && "Invalid number of operands!");
 2415     assert(isRegShiftedReg() &&
 2424     assert(N == 2 && "Invalid number of operands!");
 2425     assert(isRegShiftedImm() &&
 2435     assert(N == 1 && "Invalid number of operands!");
 2441     assert(N == 1 && "Invalid number of operands!");
 2449     assert(N == 1 && "Invalid number of operands!");
 2473     assert(N == 1 && "Invalid number of operands!");
 2479     assert(N == 1 && "Invalid number of operands!");
 2489     assert(N == 1 && "Invalid number of operands!");
 2496     assert(N == 1 && "Invalid number of operands!");
 2503     assert(N == 1 && "Invalid number of operands!");
 2510     assert(N == 1 && "Invalid number of operands!");
 2517     assert(N == 1 && "Invalid number of operands!");
 2528     assert(N == 1 && "Invalid number of operands!");
 2533     assert(N == 1 && "Invalid number of operands!");
 2539     assert(N == 1 && "Invalid number of operands!");
 2545     assert(N == 1 && "Invalid number of operands!");
 2552     assert(N == 1 && "Invalid number of operands!");
 2560     assert(N == 1 && "Invalid number of operands!");
 2568     assert(N == 1 && "Invalid number of operands!");
 2574     assert(N == 1 && "Invalid number of operands!");
 2580     assert(N == 1 && "Invalid number of operands!");
 2586     assert(N == 1 && "Invalid number of operands!");
 2592     assert(N == 1 && "Invalid number of operands!");
 2600     assert(N == 1 && "Invalid number of operands!");
 2608     assert(N == 1 && "Invalid number of operands!");
 2616     assert(N == 1 && "Invalid number of operands!");
 2624     assert(N == 1 && "Invalid number of operands!");
 2632     assert(N == 1 && "Invalid number of operands!");
 2641     assert(N == 1 && "Invalid number of operands!");
 2650     assert(N == 1 && "Invalid number of operands!");
 2658     assert(N == 1 && "Invalid number of operands!");
 2666     assert(N == 1 && "Invalid number of operands!");
 2683     assert(N == 1 && "Invalid number of operands!");
 2695     assert(isGPRMem()  && "Unknown value type!");
 2696     assert(isa<MCConstantExpr>(Memory.OffsetImm) && "Unknown value type!");
 2701     assert(N == 1 && "Invalid number of operands!");
 2706     assert(N == 1 && "Invalid number of operands!");
 2711     assert(N == 1 && "Invalid number of operands!");
 2716     assert(N == 1 && "Invalid number of operands!");
 2721     assert(N == 1 && "Invalid number of operands!");
 2726     assert(N == 1 && "Invalid number of operands!");
 2731     assert(N == 1 && "Invalid number of operands!");
 2736     assert(N == 1 && "Invalid number of operands!");
 2742     assert(N == 1 && "Invalid number of operands!");
 2743     assert(isImm() && "Not an immediate!");
 2758     assert(N == 2 && "Invalid number of operands!");
 2808     assert(N == 3 && "Invalid number of operands!");
 2828     assert(N == 2 && "Invalid number of operands!");
 2830     assert(CE && "non-constant AM2OffsetImm operand!");
 2842     assert(N == 3 && "Invalid number of operands!");
 2871     assert(N == 2 && "Invalid number of operands!");
 2893     assert(N == 2 && "Invalid number of operands!");
 2915     assert(N == 2 && "Invalid number of operands!");
 2937     assert(N == 2 && "Invalid number of operands!");
 2953     assert(N == 2 && "Invalid number of operands!");
 2969     assert(N == 2 && "Invalid number of operands!");
 2977     assert(N == 2 && "Invalid number of operands!");
 2984     assert(N == 2 && "Invalid number of operands!");
 2990     assert(N == 2 && "Invalid number of operands!");
 3005     assert(N == 2 && "Invalid number of operands!");
 3020     assert(N == 1 && "Invalid number of operands!");
 3028     assert(N == 2 && "Invalid number of operands!");
 3034     assert(N == 2 && "Invalid number of operands!");
 3040     assert(N == 3 && "Invalid number of operands!");
 3050     assert(N == 3 && "Invalid number of operands!");
 3057     assert(N == 2 && "Invalid number of operands!");
 3063     assert(N == 2 && "Invalid number of operands!");
 3070     assert(N == 2 && "Invalid number of operands!");
 3077     assert(N == 2 && "Invalid number of operands!");
 3084     assert(N == 2 && "Invalid number of operands!");
 3091     assert(N == 1 && "Invalid number of operands!");
 3093     assert(CE && "non-constant post-idx-imm8 operand!");
 3102     assert(N == 1 && "Invalid number of operands!");
 3104     assert(CE && "non-constant post-idx-imm8s4 operand!");
 3114     assert(N == 2 && "Invalid number of operands!");
 3120     assert(N == 2 && "Invalid number of operands!");
 3131     assert(N == 1 && "Invalid number of operands!");
 3137     assert(N == 1 && "Invalid number of operands!");
 3142     assert(N == 1 && "Invalid number of operands!");
 3147     assert(N == 1 && "Invalid number of operands!");
 3152     assert(N == 1 && "Invalid number of operands!");
 3157     assert(N == 1 && "Invalid number of operands!");
 3182     assert(I < E && "Invalid vector list start register!");
 3188     assert(N == 2 && "Invalid number of operands!");
 3194     assert(N == 1 && "Invalid number of operands!");
 3199     assert(N == 1 && "Invalid number of operands!");
 3204     assert(N == 1 && "Invalid number of operands!");
 3209     assert(N == 1 && "Invalid number of operands!");
 3214     assert(N == 1 && "Invalid number of operands!");
 3219     assert(N == 1 && "Invalid number of operands!");
 3224     assert(N == 1 && "Invalid number of operands!");
 3232     assert(N == 1 && "Invalid number of operands!");
 3241     assert(N == 1 && "Invalid number of operands!");
 3250     assert(N == 1 && "Invalid number of operands!");
 3259     assert(N == 1 && "Invalid number of operands!");
 3270     assert((Inst.getOpcode() == ARM::VMOVv8i8 ||
 3283     assert(N == 1 && "Invalid number of operands!");
 3298     assert(N == 1 && "Invalid number of operands!");
 3306     assert(N == 1 && "Invalid number of operands!");
 3311     assert(N == 1 && "Invalid number of operands!");
 3313     assert((Inst.getOpcode() == ARM::VMOVv4i16 ||
 3327     assert(N == 1 && "Invalid number of operands!");
 3335     assert(N == 1 && "Invalid number of operands!");
 3337     assert((Inst.getOpcode() == ARM::VMOVv2i32 ||
 3349     assert(N == 1 && "Invalid number of operands!");
 3361     assert(N == 1 && "Invalid number of operands!");
 3367     assert(N == 1 && "Invalid number of operands!");
 3373     assert(N == 1 && "Invalid number of operands!");
 3376     assert((Imm == 48 || Imm == 64) && "Invalid saturate operand");
 3536     assert(Regs.size() > 0 && "RegList contains no registers?");
 3556     assert(std::is_sorted(Regs.begin(), Regs.end()) &&
 3736     assert((ITMask.Mask & 0xf) == ITMask.Mask);
 5629   assert(Operands.size() == 8);
 5679   assert((Tok.is(AsmToken::Colon) || Tok.is(AsmToken::Comma)) &&
 6129   assert(getLexer().is(AsmToken::Colon) && "expected a :");
 7823     assert(Inst.getOperand(0).isImm() == Inst.getOperand(2).isImm() &&
 9893       assert(isThumbTwo());
 9912       assert(isThumbTwo());
 9925     assert(isThumbTwo());
 9936     assert(isThumbTwo());
10072     assert(!inITBlock() && "nested IT blocks?!");
10173     assert(!inVPTBlock() && "Nested VPT blocks are not allowed");
10189     assert(MCID.hasOptionalDef() &&
10191     assert(MCID.NumOperands == Inst.getNumOperands() &&
10882     assert(Tag == ARMBuildAttrs::compatibility);
11264   assert(Section && "must have section to emit alignment");
11466     assert(Section && "must have section to emit alignment");
11835       assert((Value >= std::numeric_limits<int32_t>::min() &&
lib/Target/ARM/Disassembler/ARMDisassembler.cpp
   75         assert(NumTZ <= 3 && "Invalid IT mask!");
  113         assert(NumTZ <= 3 && "Invalid VPT mask!");
  626   assert(!STI.getFeatureBits()[ARM::ModeThumb] &&
  859       assert(TiedOp >= 0 &&
  913   assert(STI.getFeatureBits()[ARM::ModeThumb] &&
lib/Target/ARM/MCTargetDesc/ARMAddressingModes.h
   87     assert(Amt < 32 && "Invalid rotate amount");
   94     assert(Amt < 32 && "Invalid rotate amount");
  204     assert(V == (rotr32(255U, getSOImmValRotate(V)) & V));
  355     assert (isT2SOImmTwoPartVal(Imm) &&
  367     assert (getT2SOImmValSplatVal(Imm & 0x00ff00ffU) != -1);
  375     assert (getT2SOImmVal(Imm) != -1 &&
  401     assert(Imm12 < (1 << 12) && "Imm too large!");
  582     assert(Size >= 1 && Size <= 4 && "Invalid size");
  601     assert(isNEONi16splat(Value) && "Invalid NEON splat value");
  617     assert(isNEONi32splat(Value) && "Invalid NEON splat value");
lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp
  178   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  451     assert(STI != nullptr);
  464     assert(STI != nullptr);
  667     assert(STI != nullptr);
  692     assert(STI != nullptr);
  704     assert(STI != nullptr);
  877     assert(Sym && "How did we resolve this?");
 1047   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
 1053     assert((Offset + FullSizeBytes) <= Data.size() && "Invalid fixup size!");
 1054     assert(NumBytes <= FullSizeBytes && "Invalid fixup size!");
 1323     assert(TheTriple.isOSWindows() && "non-Windows ARM COFF is not supported");
 1326     assert(TheTriple.isOSBinFormatELF() && "using ELF for non-ELF target");
lib/Target/ARM/MCTargetDesc/ARMELFStreamer.cpp
   62   assert(Index < ARM::EHABI::NUM_PERSONALITY_INDEX &&
  143   assert((Reg != ARM::SP && Reg != ARM::PC) &&
  159   assert(RegList.size() && "RegList should not be empty");
  506       assert(!IsThumb);
  518       assert(IsThumb);
  758   assert(!Vendor.empty() && "Vendor cannot be empty.");
  766   assert(Contents.empty() &&
 1216   assert(EHSection && "Failed to get the required EH section");
 1257   assert(FnStart == nullptr);
 1263   assert(FnStart && ".fnstart must precedes .fnend");
 1295     assert(PersonalityIndex == ARM::EHABI::AEABI_UNWIND_CPP_PR0 &&
 1297     assert(Opcodes.size() == 4u &&
 1360   assert(!ExTab);
 1375   assert((Opcodes.size() % 4) == 0 &&
 1404   assert(Index < ARM::EHABI::NUM_PERSONALITY_INDEX && "invalid index");
 1410   assert((NewSPReg == ARM::SP || NewSPReg == FPReg) &&
 1423   assert((Reg != ARM::SP && Reg != ARM::PC) &&
 1425   assert(FPReg == ARM::SP && "current FP must be SP");
 1453     assert(Reg < (IsVector ? 32U : 16U) && "Register out of range");
lib/Target/ARM/MCTargetDesc/ARMInstPrinter.cpp
   44   assert((imm & ~0x1f) == 0 && "Invalid shift encoding");
   58   assert(!(ShOpc == ARM_AM::ror && !ShImm) && "Cannot have ror #0");
  115     assert(ARM_AM::getSORegOffset(MO3.getImm()) == 0);
  319     assert(Op.isExpr() && "unknown operand kind in printOperand");
  397   assert(ARM_AM::getSORegOffset(MO3.getImm()) == 0);
  483   assert(IdxMode != ARMII::IndexModePost && "Should be pre or offset index op");
  553   assert(ARM_AM::getAM3IdxMode(MI->getOperand(Op + 2).getImm()) !=
  744   assert(MO.isImm() && "Not a valid bf_inv_mask_imm value!");
  790   assert(Imm > 0 && Imm < 32 && "Invalid PKH shift immediate value!");
  801   assert(Imm > 0 && Imm <= 32 && "Invalid PKH shift immediate value!");
  809     assert(std::is_sorted(MI->begin() + OpNum, MI->end(),
  949   assert(TheReg && "invalid banked register operand");
  998     assert(MI->getOperand(OpNum).getReg() == ARM::CPSR &&
 1077   assert(NumTZ <= 3 && "Invalid IT mask!");
 1169   assert(MO2.isImm() && "Not a valid t2_so_reg value!");
 1245   assert(((OffImm & 0x3) == 0) && "Not a valid immediate!");
 1294   assert(((OffImm & 0x3) == 0) && "Not a valid immediate!");
 1317   assert(MO2.getReg() && "Invalid so_reg load / store address!");
 1323     assert(ShAmt <= 3 && "Not a valid Thumb2 addressing mode!");
 1361   assert(Imm <= 3 && "illegal ror immediate!");
 1661   assert(NumTZ <= 3 && "Invalid VPT mask!");
 1684   assert(Val <= 1 && "Invalid MVE saturate operand");
lib/Target/ARM/MCTargetDesc/ARMMCCodeEmitter.cpp
  348     assert(Encoded != ~0U && "Not a Thumb2 so_imm value?");
  634   assert(MO.isExpr() && "Unexpected branch target type!");
  861   assert(SoImmVal != -1 && "Not a valid so_imm value!");
  894   assert(MaskMO.isImm() && "Unexpected operand type!");
  902   assert(OpIdx > 0 && "IT mask appears first!");
  904   assert(CondMO.isImm() && "Unexpected operand type!");
 1073     assert(Qm < 8 && "Qm is supposed to be encodable in 3 bits");
 1105     assert(Qm < 8 && "Qm is supposed to be encodable in 3 bits");
 1128     assert(MO.isExpr() && "Unexpected machine operand type!");
 1265   assert((ShImm & ~0x1f) == 0 && "Out of range shift amount");
 1355     assert(MO.isExpr() && "Unexpected machine operand type!");
 1382   assert(MI.getOperand(OpIdx).getReg() == ARM::SP &&
 1433     assert(MO.isExpr() && "Unexpected machine operand type!");
 1473     assert(MO.isExpr() && "Unexpected machine operand type!");
 1540   assert(ARM_AM::getSORegOffset(MO2.getImm()) == 0);
 1586   assert(Offset < 32 && "Offset must be in range 0-31!");
 1706   assert(v != 0 && lsb < 32 && msb < 32 && "Illegal bitfield mask!");
 1741     assert(std::is_sorted(MI.begin() + Op, MI.end(),
 1912     assert(BranchMO.isExpr());
 1920   assert(MO.isImm() && BranchMO.isImm());
 1922   assert(Diff == 4 || Diff == 2);
 1931   assert(MO.isImm() && "Unexpected operand type!");
 1963   assert(MO.isImm() && "Unexpected operand type!");
 1967     assert(0 && "Unexpected Condition!");
 1991   assert(MO.isImm() && "Unexpected operand type!");
 2001   assert(MO.isImm() && "Unexpected operand type!");
lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp
   83   assert(!STI.getFeatureBits()[llvm::ARM::ModeThumb] &&
   86   assert(MI.getNumOperands() >= 4 && "expected >= 4 arguments");
   88     assert(MI.getOperand(OI).isReg() && "expected register");
  100   assert(!STI.getFeatureBits()[llvm::ARM::ModeThumb] &&
  103   assert(MI.getNumOperands() >= 4 && "expected >= 4 arguments");
  106     assert(MI.getOperand(OI).isReg() && "expected register");
lib/Target/ARM/MCTargetDesc/ARMMachObjectWriter.cpp
  290     assert(Type == MachO::ARM_RELOC_VANILLA && "invalid reloc for 2 symbols");
lib/Target/ARM/MCTargetDesc/ARMUnwindOpAsm.cpp
   45       assert(SizeInWords <= 0x100u &&
   52       assert(PI < ARM::EHABI::NUM_PERSONALITY_INDEX &&
  173       assert(Ops.size() <= 3 && "too many opcodes for __aeabi_unwind_cpp_pr0");
lib/Target/ARM/MCTargetDesc/ARMWinCOFFObjectWriter.cpp
   31     assert(!Is64Bit && "AArch64 support not yet implemented");
   50   assert(getMachine() == COFF::IMAGE_FILE_MACHINE_ARMNT &&
lib/Target/ARM/MVEVPTBlockPass.cpp
  186     assert(Pred != ARMVCC::Else && "VPT block pass does not expect Else preds");
  202       assert(NextPred != ARMVCC::Else &&
lib/Target/ARM/Thumb1FrameLowering.cpp
  137         assert(Opc == ARM::ADJCALLSTACKUP || Opc == ARM::tADJCALLSTACKUP);
  159   assert(NumBytes >= ArgRegsSaveSize &&
  483   assert((unsigned)NumBytes >= ArgRegsSaveSize &&
  515         assert(!MFI.getPristineRegs(MF).test(ARM::R4) &&
  554     assert(Done && "Emission of the special fixup failed!?");
  625       assert(MBBI_prev->getOpcode() == ARM::tPOP);
  626       assert(MBB.succ_size() == 1);
  685   assert(PopFriendly.any() && "No allocatable pop-friendly register?!");
  716   assert((PopReg || TemporaryReg) && "Cannot get LR");
  719     assert(PopReg && "Do not know how to get LR");
  741     assert(!PopReg && "Unnecessary MOV is about to be inserted");
  772   assert(PopReg && "Do not know how to get LR");
  996     assert(!CopyRegs.none());
lib/Target/ARM/Thumb1InstrInfo.cpp
   46   assert(ARM::GPRRegClass.contains(DestReg, SrcReg) &&
   82   assert((RC == &ARM::tGPRRegClass ||
  110   assert(
lib/Target/ARM/Thumb2ITBlockPass.cpp
  144   assert(MI->getOperand(0).getSubReg() == 0 &&
lib/Target/ARM/Thumb2InstrInfo.cpp
  310         assert((ThisVal & 3) == 0 && "Stack update is not multiple of 4?");
  330         assert(ARM_AM::getT2SOImmVal(ThisVal) != -1 &&
  334       assert(DestReg != ARM::SP && BaseReg != ARM::SP);
  347         assert(ARM_AM::getT2SOImmVal(ThisVal) != -1 &&
  540     assert(ARM_AM::getT2SOImmVal(ThisImmVal) != -1 &&
  592       assert((Offset & (Scale-1)) == 0 && "Can't encode this offset!");
  606       assert((Offset & (Scale-1)) == 0 && "Can't encode this offset!");
  623       assert((Offset & OffsetMask) == 0 && "Can't encode this offset!");
  630       assert((Offset & 3) == 0 && "Can't encode this offset!");
  635       assert((Offset & 3) == 0 && "Can't encode this offset!");
lib/Target/ARM/Thumb2SizeReduction.cpp
  472     assert(isARMLowRegister(Rt));
  473     assert(isARMLowRegister(Rn));
  500     assert(isARMLowRegister(BaseReg));
  596     assert((!HasShift || OffsetReg) && "Invalid so_reg load / store address!");
  994     assert(LiveCPSR && "CPSR liveness tracking is wrong!");
lib/Target/ARM/ThumbRegisterInfo.cpp
  110     assert(
  144     assert(BaseReg == ARM::SP && "Unexpected!");
  234       assert(!isSub && "Thumb1 does not have tSUBrSPi");
  268   assert(((Bytes & 3) == 0 || ExtraScale == 1) &&
  285   assert(RangeAfterCopy % ExtraScale == 0 &&
  365   assert(MBB.getParent()->getSubtarget<ARMSubtarget>().isThumb1Only() &&
  391     assert((Offset & (Scale - 1)) == 0 && "Can't encode this offset!");
  443     assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
  446   assert (Done && "Unable to resolve frame index!");
  477     assert(STI.getFrameLowering()->hasReservedCallFrame(MF) &&
  480     assert(!MF.getFrameInfo().hasVarSizedObjects() &&
  494   assert(MF.getInfo<ARMFunctionInfo>()->isThumbFunction() &&
  502   assert(Offset && "This code isn't needed if offset already handled!");
lib/Target/AVR/AVRAsmPrinter.cpp
   98       assert(RegOp.isReg() && "Operand must be a register when you're"
  113       assert(BytesPerReg <= 2 && "Only 8 and 16 bit regs are supported.");
  116       assert(RegIdx < NumOpRegs && "Multibyte index out of range.");
  145   assert(MO.isReg() && "Unexpected inline asm memory operand");
  154     assert(MI->getOperand(OpNum).getReg() == AVR::R29R28 &&
lib/Target/AVR/AVRExpandPseudoInsts.cpp
  126       assert(ExpandCount < 10 && "pseudo expand limit reached");
  638   assert(DstReg != SrcReg && "SrcReg and DstReg cannot be the same");
  669   assert(DstReg != SrcReg && "SrcReg and DstReg cannot be the same");
  703   assert(Imm <= 62 && "Offset is out of range");
  885   assert(Reg != -1 && "ran out of registers");
 1053   assert(DstReg != SrcReg && "SrcReg and DstReg cannot be the same");
 1087   assert(DstReg != SrcReg && "SrcReg and DstReg cannot be the same");
 1123   assert(Imm <= 62 && "Offset is out of range");
 1155   assert(Imm <= 62 && "Address is out of range");
 1185   assert(Imm <= 62 && "Address is out of range");
lib/Target/AVR/AVRFrameLowering.cpp
  157   assert(MBBI->getDesc().isReturn() &&
  254     assert(TRI->getRegSizeInBits(*TRI->getMinimalPhysRegClass(Reg)) == 8 &&
  292     assert(TRI->getRegSizeInBits(*TRI->getMinimalPhysRegClass(Reg)) == 8 &&
  323     assert(MI.getOperand(0).getReg() == AVR::SP &&
  384     assert(getStackAlignment() == 1 && "Unsupported stack alignment");
  389       assert(Opcode == TII.getCallFrameDestroyOpcode());
lib/Target/AVR/AVRISelDAGToDAG.cpp
  205   assert((ConstraintCode == InlineAsm::Constraint_m ||
  367   assert(Subtarget->hasLPM() && "cannot load from program memory on this mcu");
  475   assert(Type == MVT::i8 && "unexpected value type");
lib/Target/AVR/AVRISelLowering.cpp
  274   assert(!VT.isVector() && "No AVR SetCC type for vectors!");
  341   assert((Opcode == ISD::SDIVREM || Opcode == ISD::UDIVREM) &&
  960     assert(F != nullptr && "function should not be null");
 1112       assert(VA.isMemLoc());
 1244       assert(VA.isMemLoc());
 1284   assert(Mask && "Missing call preserved mask for calling convention");
 1402     assert(VA.isRegLoc() && "Can only return in registers!");
 1620   assert((Opc == AVR::Select16 || Opc == AVR::Select8) &&
 1878       assert(VT == MVT::i16 && "inline asm constraint too large");
lib/Target/AVR/AVRInstrInfo.cpp
  377     assert(Cond.size() == 1);
  378     assert(TBB);
  407   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  408   assert((Cond.size() == 1 || Cond.size() == 0) &&
  412     assert(!FBB && "Unconditional branch with multiple successors!");
  468   assert(Cond.size() == 1 && "Invalid AVR branch condition!");
lib/Target/AVR/AVRRegisterInfo.cpp
  131   assert(SPAdj == 0 && "Unexpected SPAdj value");
  157     assert(Offset > 0 && "Invalid offset");
  162     assert(DstReg != AVR::R29R28 && "Dest reg cannot be the frame pointer");
  244   assert(isUInt<6>(Offset) && "Offset is out of range");
  270     assert(AVR::DREGSRegClass.contains(Reg) && "can only split 16-bit registers");
lib/Target/AVR/AVRSubtarget.h
   78     assert(ELFArch != 0 &&
lib/Target/AVR/AsmParser/AVRAsmParser.cpp
  130     assert(Kind == k_Register && "Unexpected operand kind");
  131     assert(N == 1 && "Invalid number of operands!");
  147     assert(Kind == k_Immediate && "Unexpected operand kind");
  148     assert(N == 1 && "Invalid number of operands!");
  156     assert(Kind == k_Memri && "Unexpected operand kind");
  157     assert(N == 2 && "Invalid number of operands");
  164     assert(N == 1 && "Invalid number of operands!");
  186     assert(Kind == k_Token && "Invalid access!");
  191     assert((Kind == k_Register || Kind == k_Memri) && "Invalid access!");
  197     assert((Kind == k_Immediate || Kind == k_Memri) && "Invalid access!");
  440         assert(CurTok == AsmToken::Plus);
  476     assert(Parser.getTok().getKind() == AsmToken::LParen);
  486     assert(Parser.getTok().getKind() == AsmToken::RParen);
  491   assert(Parser.getTok().getKind() == AsmToken::RParen);
lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
  378   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
  450   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  460   assert((Count % 2) == 0 && "NOP instructions must be 2 bytes");
lib/Target/AVR/MCTargetDesc/AVRInstPrinter.cpp
  118     assert(Op.isExpr() && "Unknown operand kind in printOperand");
  140     assert(Op.isExpr() && "Unknown pcrel immediate operand");
  147   assert(MI->getOperand(OpNo).isReg() && "Expected a register for the first operand");
lib/Target/AVR/MCTargetDesc/AVRMCCodeEmitter.cpp
   70   assert(MI.getOperand(0).isReg() && MI.getOperand(1).isReg() &&
  103   assert(MO.isImm());
  118   assert(MO.isReg());
  139   assert(RegOp.isReg() && "Expected register operand");
  173   assert(MI.getOperand(OpNo).isImm());
  200   assert(MO.isImm());
  215   assert(MO.isImm());
  245   assert(Kind == MCExpr::SymbolRef);
  263   assert(MO.isExpr());
  290   assert(Size > 0 && "Instruction size cannot be zero");
lib/Target/AVR/MCTargetDesc/AVRMCExpr.cpp
   44   assert(Kind != VK_AVR_None);
lib/Target/BPF/AsmParser/BPFAsmParser.cpp
  147     assert(Kind == Register && "Invalid type access!");
  152     assert(Kind == Immediate && "Invalid type access!");
  157     assert(Kind == Token && "Invalid type access!");
  177     assert(Expr && "Expr shouldn't be null!");
  187     assert(N == 1 && "Invalid number of operands!");
  192     assert(N == 1 && "Invalid number of operands!");
lib/Target/BPF/BPFAbstractMemberAccess.cpp
  372   assert(PTy && CTy && "ParentType or ChildType is null or not composite");
  375   assert(PTyTag == dwarf::DW_TAG_array_type ||
  380   assert(CTyTag == dwarf::DW_TAG_array_type ||
  507   assert(CV);
  521   assert(SOff);
  533     assert(SOff);
  561         assert(SOffset);
  740     assert(CInfo.Kind == BPFPreserveArrayAI);
  752       assert(CTy->getTag() == dwarf::DW_TAG_array_type);
  761       assert(DTy->getTag() == dwarf::DW_TAG_pointer_type);
  796   assert(TypeName.size());
  816         assert(CallStack.size() == 1);
lib/Target/BPF/BPFAsmPrinter.cpp
  122   assert(OpNum + 1 < MI->getNumOperands() && "Insufficient operands");
  125   assert(BaseMO.isReg() && "Unexpected base pointer for inline asm memory operand.");
  126   assert(OffsetMO.isImm() && "Unexpected offset for inline asm memory operand.");
lib/Target/BPF/BPFISelLowering.cpp
  435     assert(VA.isRegLoc() && "Can only return in registers!");
  554   assert(N->getOffset() == 0 && "Invalid offset for global address");
  636   assert((isSelectRROp || isSelectRIOp || isMemcpyOp) &&
  727     assert (isInt<32>(imm32));
lib/Target/BPF/BPFInstrInfo.cpp
  225   assert(!BytesAdded && "code size not handled");
  228   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  232     assert(!FBB && "Unconditional branch with multiple successors!");
  242   assert(!BytesRemoved && "code size not handled");
lib/Target/BPF/BPFMISimplifyPatchable.cpp
  117               assert(MI.getOperand(2).getImm() == 0);
lib/Target/BPF/BPFRegisterInfo.cpp
   59   assert(SPAdj == 0 && "Unexpected");
   77     assert(i < MI.getNumOperands() && "Instr doesn't have FrameIndex operand!");
lib/Target/BPF/BTFDebug.cpp
   81     assert((Kind == BTF::BTF_KIND_PTR || Kind == BTF::BTF_KIND_CONST ||
  915     assert(SectionELF && "Null section for Function Label");
lib/Target/BPF/BTFDebug.h
  330     assert(ArrayIndexTypeId);
  339     assert(Ty && "Invalid null Type");
  340     assert(DIToIdMap.find(Ty) != DIToIdMap.end() &&
lib/Target/BPF/MCTargetDesc/BPFAsmBackend.cpp
   77     assert(Value <= UINT32_MAX);
   95     assert(Fixup.getKind() == FK_PCRel_2);
lib/Target/BPF/MCTargetDesc/BPFELFObjectWriter.cpp
   59         assert(SectionELF && "Null section for reloc symbol");
lib/Target/BPF/MCTargetDesc/BPFInstPrinter.cpp
   41   assert(SRE && "Unexpected MCExpr type.");
   45   assert(Kind == MCSymbolRefExpr::VK_None);
   52   assert((Modifier == 0 || Modifier[0] == 0) && "No modifiers supported");
   59     assert(Op.isExpr() && "Expected an expression");
   70   assert(RegOp.isReg() && "Register operand not a register");
   81     assert(0 && "Expected an immediate");
lib/Target/BPF/MCTargetDesc/BPFMCCodeEmitter.cpp
   95   assert(MO.isExpr());
   99   assert(Expr->getKind() == MCExpr::SymbolRef);
  163   assert(Op1.isReg() && "First operand is not register.");
  167   assert(Op2.isImm() && "Second operand is not immediate.");
lib/Target/Hexagon/AsmParser/HexagonAsmParser.cpp
  251     assert(Kind == Register && "Invalid access!");
  256     assert(Kind == Immediate && "Invalid access!");
  379     assert(N == 1 && "Invalid number of operands!");
  384     assert(N == 1 && "Invalid number of operands!");
  389     assert(N == 1 && "Invalid number of operands!");
  412     assert(Kind == Token && "Invalid access!");
  480       assert(!HexagonMCInstrInfo::isInnerLoop(MCB));
  481       assert(!HexagonMCInstrInfo::isOuterLoop(MCB));
  598   assert(InBrackets);
  617     assert(Operands.size() == 1 && "Brackets should be by themselves");
  627     assert(Operands.size() == 1 && "Brackets should be by themselves");
  670   assert((getLexer().isNot(AsmToken::EndOfStatement)) &&
  937   assert(Second.is(AsmToken::Colon));
 1176       assert(Expr != nullptr);
 1357     assert(Success && "Assured by matcher");
lib/Target/Hexagon/BitTracker.cpp
  204   assert(SelfR == 0 || Register::isVirtualRegister(SelfR));
  218   assert(B < W && E < W);
  221   assert(B > E || E-B+1 == RC.width());      // B <= E  =>  E-B+1 = |RC|.
  222   assert(B <= E || E+(W-B)+1 == RC.width()); // E < B   =>  E+(W-B)+1 = |RC|.
  237   assert(B < W && E < W);
  276   assert(B <= E);
  342   assert(Register::isPhysicalRegister(RR.Reg));
  357   assert(Register::isVirtualRegister(RR.Reg));
  382   assert(RR.Sub == 0 && "Unexpected sub-register in definition");
  398   assert(isInt(A));
  425   assert((unsigned)BW == A.getBitWidth() && "BitWidth overflow");
  435   assert(W == A2.width());
  468   assert(W == A2.width());
  520   assert(Sh <= A1.width());
  530   assert(Sh <= W);
  540   assert(Sh <= W);
  551   assert(W == A2.width());
  573   assert(W == A2.width());
  595   assert(W == A2.width());
  629   assert(BitN < A1.width());
  637   assert(BitN < A1.width());
  666   assert(FromN <= W);
  677   assert(FromN <= W);
  686   assert(B < W && E <= W);
  699   assert(AtN < W1 && AtN+W2 <= W1);
  708   assert(Sub == 0 && "Generic BitTracker::mask called for Sub != 0");
  710   assert(W > 0 && "Cannot generate mask for empty register");
  715   assert(Register::isPhysicalRegister(Reg));
  727       assert(RD.Sub == 0);
  732       assert(SS != ST);
  747       assert(RD.Sub == 0);
  750       assert(WD >= WS);
  804   assert(MD.getSubReg() == 0 && "Unexpected sub-register in definition");
  848   assert(!MI.isBranch() && "Unexpected branch instruction");
  877     assert(RD.Sub == 0 && "Unexpected sub-register in definition");
  931     assert(MI.isBranch() && "Expecting branch instruction");
 1000   assert(Map.count(OldRR.Reg) > 0 && "OldRR not present in map");
 1006   assert((OME-OMB == NME-NMB) &&
 1026   assert(BN >= 0);
 1033   assert(!MI.isBranch() && "Only non-branches are allowed");
 1120   assert(FlowQ.empty());
 1127     assert(B.getNumber() >= 0 && "Disconnected block");
lib/Target/Hexagon/BitTracker.h
  209     assert(T == 0 || T == 1);
  261     assert(Type == Zero || Type == One);
  307     assert(BitN < Bits.size());
  311     assert(BitN < Bits.size());
  358   assert(F != Map.end());
lib/Target/Hexagon/Disassembler/HexagonDisassembler.cpp
   77   assert(Success);
  296   assert(Bytes.size() >= HEXAGON_INSTR_SIZE);
  461     assert(MCO.isReg() && "New value consumers must be registers");
  494       assert(Producer != Hexagon::NoRegister);
  505       assert(Producer != Hexagon::NoRegister);
  724   assert(FullValue >= 0 && "Negative in unsigned decoder");
lib/Target/Hexagon/HexagonAsmPrinter.cpp
   68   assert(Hexagon::IntRegsRegClass.contains(Reg));
   71   assert(Hexagon::DoubleRegsRegClass.contains(Pair));
  215     assert(Imm.isExpr() && "Expected expression and found none");
  217     assert(MO.isGlobal() || MO.isCPI() || MO.isJTI());
  375     assert(Rt.isReg() && "Expected register and none was found");
  386     assert(Rt.isReg() && "Expected register and none was found");
  398     assert(Rt.isReg() && "Expected register and none was found");
  410     assert(Rs.isReg() && "Expected register and none was found");
  429     assert(Success && "Expected immediate and none was found");
  456     assert(Success && "Expected immediate and none was found");
  492     assert(Success && "Expected immediate and none was found");
  582     assert(Success);
  595     assert(Rt.isReg() && "Expected register and none was found");
  607     assert(Inst.getOperand(0).isReg() &&
  620     assert (Inst.getOperand(0).isReg() &&
  768   assert(Ok); (void)Ok;
lib/Target/Hexagon/HexagonBitSimplify.cpp
  122       assert(Idx < size());
  331   assert(B < RC.width() && B+W <= RC.width());
  340   assert(B < RC.width() && B+W <= RC.width());
  434   assert(I.getOpcode() == TargetOpcode::REG_SEQUENCE);
  441   assert((Sub1 == SubLo && Sub2 == SubHi) || (Sub1 == SubHi && Sub2 == SubLo));
  906     assert(Sub == HRI.getHexagonSubRegIndex(*RC, Hexagon::ps_sub_lo) ||
  978       assert(!UseI->getOperand(0).getSubReg());
 1126   assert(MI.getOperand(ImN).isImm());
 1191   assert(MI.getOperand(ImN).isImm());
 1258     assert(MI.getOperand(OpN).isReg());
 1265     assert(LB <= LE && LB < Width && LE <= Width);
 1667   assert(MI.getOperand(0).getSubReg() == 0);
 2264     assert(DefS != nullptr);
 2288       assert(DefI != nullptr);
 2293       assert(Op0.getSubReg() == 0);
 2405   assert(RD.Sub == 0);
 2443     assert(TopV.Type == BitTracker::BitValue::Ref);
 2587   assert(RD.Sub == 0);
 2653     assert(KnownZ != KnownNZ && "Register cannot be both 0 and non-0");
lib/Target/Hexagon/HexagonBitTracker.cpp
  114   assert(Register::isPhysicalRegister(Reg));
  141   assert(IsSubLo != IsSubHi && "Must refer to either low or high subreg");
  180     assert(n < Vector.size());
  199     assert(MO.getSubReg() == 0);
  273     assert(getRegBitWidth(Reg[N]) == W && "Register width mismatch");
  279     assert(RW <= RC.width());
  286     assert(RW <= W);
  292     assert(N*16+16 <= RC.width());
  299     assert(Ws == Rt.width());
  349       assert(PW <= RW);
  372       assert(W0 == 64 && W1 == 32);
  641       assert(W0 == 32);
  715       assert(Wd <= W0);
  731       assert(Wd < W0 && Of < W0);
  748       assert(W0 % 2 == 0);
  754       assert(W0 == 32);
  755       assert(getRegBitWidth(Reg[1]) == 32 && getRegBitWidth(Reg[2]) == 32);
  766       assert(W0 == 64);
  767       assert(getRegBitWidth(Reg[1]) == 32 && getRegBitWidth(Reg[2]) == 32);
  793       assert(WR == 64 && WP == 8);
  830       assert(W0 == 64 && W1 == 32);
 1062   assert(MI.mayLoad() && "A load that mayn't?");
 1190   assert(MD.isReg() && MD.isDef());
 1194   assert(W >= BitNum && BitNum > 0);
 1218   assert(MI.isCopy());
 1222   assert(RD.Sub == 0);
 1251   assert(PReg == 0 || Is64 || IntRegsRegClass.contains(PReg));
lib/Target/Hexagon/HexagonBlockRanges.cpp
   60   assert(end() == A.start() || overlaps(A));
  126     assert(AE != IndexType::None);
  164     assert(getIndex(&In) == IndexType::None && "Instruction already in map");
  186   assert (Idx != IndexType::None);
  198   assert (Idx != IndexType::None);
  278     assert(Register::isVirtualRegister(R.Reg));
  377       assert(!Register::isPhysicalRegister(S.Reg) ||
  386       assert(!Register::isPhysicalRegister(S.Reg) ||
lib/Target/Hexagon/HexagonBlockRanges.h
  175   assert(Index >= First);
  197   assert(Index != None);
  198   assert(Index != Exit);
lib/Target/Hexagon/HexagonBranchRelaxation.cpp
  180     assert(SecondTerm != B.instr_end() &&
  216         assert(MO.isMBB() && "Branch with unknown expandable field type");
lib/Target/Hexagon/HexagonCFGOptimizer.cpp
  190             assert(JumpAroundTarget && "jump target is needed to process second basic block");
lib/Target/Hexagon/HexagonCommonGEP.cpp
   87       assert(F1 != Map.end() && F2 != Map.end());
  213     assert(CI && "Struct type with non-constant index");
  573         assert(Ins.second && "Cannot add a class");
  604     assert(Ins.second && "Cannot add minimal element");
  622     assert((Min->Flags & Flags) == Min->Flags);
  771     assert(UF != Uses.end() && "Used node with no use information");
  980   assert(UF != Uses.end());
  998   assert(!NewUs.empty());
 1017     assert(UF != Uses.end());
 1096   assert((RN->Flags & GepNode::Root) && "Creating GEP for non-root");
 1149       assert(UF != Uses.end() && "No use information for used node");
 1234       assert(UF != Uses.end() && "No use information found");
lib/Target/Hexagon/HexagonConstExtenders.cpp
   43   assert(isPowerOf2_32(A));
   49   assert(isPowerOf2_32(A));
   92       assert(D % Align == 0);
  170       assert(N != nullptr);
  179       assert(N != nullptr);
  198         assert(It->getParent() == B);
  492     assert(ED.OpNum != -1u);
  638   assert(N != nullptr);
  641     assert(N->Range != D->Range && "N and D should not be equal");
  665   assert(Higher->Right == Lower);
  671   assert(height(Lower->Left) <= height(Lower->Right));
  680   assert(Higher->Left == Lower);
  686   assert(height(Lower->Left) >= height(Lower->Right));
  738       assert(!V.GV->getName().empty() && !ER.V.GV->getName().empty());
  743       assert(ThisB->getParent() == OtherB->getParent());
  776       assert(Offset == 0);
  779       assert(Offset == 0);
  790       assert(Offset == 0);
 1067   assert(D.mayLoad() || D.mayStore());
 1260     assert(ER == ExtRoot(Extenders[I].getOp()));
 1278     assert(ED.Rd.Reg != 0);
 1508   assert(!DefI || MDT->dominates(DefI->getParent(), DomB));
 1518     assert(It != End && "Should have found a ref in DomB");
 1539     assert(Ex.S == 0 && "Cannot have a shift of a stack slot");
 1540     assert(!Ex.Neg && "Cannot subtract a stack slot");
 1546     assert((Ex.Rs.Reg == 0 || Ex.Rs.isVReg()) && "Expecting virtual register");
 1574   assert(InitI);
 1718     assert(IdxOpc == Hexagon::A2_addi);
 1744     assert(Uses.contains(-Diff));
 1761     assert(Ex.Rs == RegOp && EV == ImmOp && Ex.Neg != IsAddi &&
 1784     assert(EV == V && Rs == Ex.Rs && IsSub == Ex.Neg && "Initializer mismatch");
 1798     assert(IdxOpc && "Expecting indexed opcode");
 1832   assert((!ED.IsDef || ED.Rd.Reg != 0) && "Missing Rd for def");
 1834   assert(ExtRoot(ExtValue(ED)) == ExtRoot(DefV) && "Extender root mismatch");
 1875       assert(P.first->getNumOperands() > J+1 &&
 1885       assert(ED.Rd.Sub == 0 && ExtR.Sub == 0);
 1923   assert(HII->isPredicated(MI));
 1928     assert(Op.getSubReg() == 0 && "Predicate register with a subregister");
 1935   assert(MI.mayLoad());
 1940   assert(MI.mayStore());
 1974     assert(BA->getNumber() != -1 && BB->getNumber() != -1);
lib/Target/Hexagon/HexagonConstPropagation.cpp
  203         assert(Top.isTop());
  342         assert((Cmp & (L|G)) != (L|G));
  540   assert(LC);
  597   assert(!isTop() && "Should not call this for a top cell");
  601   assert(size() > 0 && "Empty cell");
  626   assert(Register::isVirtualRegister(DefR.Reg));
  904     assert(It == End || !It->isPHI());
 1055   assert(FlowQ.empty());
 1099   assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 1129   assert(!IsTrue || !IsFalse);
 1138   assert(Inputs.has(R1.Reg));
 1156   assert(!IsTrue || !IsFalse);
 1165   assert(Inputs.has(R1.Reg));
 1184   assert(!IsTrue || !IsFalse);
 1204   assert((Cmp & (Comparison::L | Comparison::G)) && "Malformed comparison");
 1363   assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 1394   assert(Inputs.has(R1.Reg));
 1430   assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 1461   assert(Inputs.has(R1.Reg));
 1497   assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 1526   assert(Inputs.has(R1.Reg));
 1559   assert(Inputs.has(R1.Reg));
 1582   assert(Width >= Bits && BW >= Bits);
 1590   assert(Inputs.has(R1.Reg));
 1612   assert(Width >= Bits && BW >= Bits);
 1655   assert(Inputs.has(R1.Reg));
 1690   assert(Inputs.has(R1.Reg));
 1726   assert(Inputs.has(R1.Reg));
 1727   assert(Bits+Offset <= Width);
 1758   assert(Bits+Offset <= BW);
 1784   assert(Inputs.has(R1.Reg));
 1805   assert(Count > 0);
 1928   assert(!DefR.SubReg);
 1951     assert(Sub1 != Sub2);
 2041       assert(B >=0 && B < 32);
 2084       assert(Inputs.has(R1.Reg));
 2116       assert(Inputs.has(R1.Reg));
 2206   assert(!Input.isTop());
 2290     assert(Inputs.has(PR.Reg));
 2509   assert(Inputs.has(RL.Reg) && Inputs.has(RH.Reg));
 2522     assert(LoVs[i].getBitWidth() == 32);
 2528     assert(HiVs[i].getBitWidth() == 32);
 2670   assert(Inputs.has(CR.Reg));
 2713   assert(Inputs.has(R1.Reg));
 2758   assert(Inputs.has(R1.Reg));
 2837     assert(!MO.getSubReg());
 2838     assert(Inputs.has(R));
 2891       assert(W == 32 || W == 64);
 2962       assert(!DefR.SubReg);
 2965       assert(Inputs.has(R2.Reg) && Inputs.has(R3.Reg));
 3027       assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 3063       assert(Inputs.has(R1.Reg) && Inputs.has(R2.Reg));
 3114   assert(Register::isVirtualRegister(FromReg));
 3115   assert(Register::isVirtualRegister(ToReg));
 3142     assert(!FallsThru && "This should have been checked before");
lib/Target/Hexagon/HexagonCopyToCombine.cpp
  134     assert(Op0.isReg() && Op1.isReg());
  147     assert(Op0.isReg());
  229   assert(Register::isPhysicalRegister(Reg));
  320         assert(Added && "Must successfully update kill flag");
  373         assert(!KillingInstr && "Should only see one killing instruction");
  384       assert(Added && "Must successfully update kill flag");
  593     assert(ST->useHVXOps());
  601   assert(DoubleRegDest != 0 && "Expect a valid register");
  654   assert(LoOperand.isImm() && HiOperand.isImm() &&
  872     assert(ST->useHVXOps());
lib/Target/Hexagon/HexagonEarlyIfConv.cpp
  262   assert(T2I == B->end() || T2I->getOpcode() == Hexagon::J2_jump);
  409     assert(DefI && "Expecting a reaching def in MRI");
  467     assert(Inc.size() <= 2);
  473     assert(RA.isReg() && RB.isReg());
  721     assert(COpc);
  767     assert(!I->isPHI());
  836     assert(TR || FR);
  861   assert(OldTI != FP.SplitB->end());
  896       assert(!SSB);
  907     assert(!SSB || SSB == FP.JoinB);
  989     assert(PN->getNumOperands() == 3 && "Invalid phi node");
lib/Target/Hexagon/HexagonExpandCondsets.cpp
  288   assert(Register::isVirtualRegister(Reg));
  367   assert(Register::isVirtualRegister(Reg));
  555       assert(Register::isPhysicalRegister(R));
  558       assert(MRI->isReserved(R));
  586       assert(VC->begin() != VC->end() && "Empty register class");
  589       assert(Register::isPhysicalRegister(RS.Reg));
  673   assert(MD.isDef());
  926       assert(!Op.isDef() && "Not expecting a def");
  939   assert(Opc == Hexagon::A2_tfrt || Opc == Hexagon::A2_tfrf);
 1007         assert(RR.Sub && "Expecting a subregister on <def,read-undef>");
lib/Target/Hexagon/HexagonFixupHwLoops.cpp
  145         assert(MII->getOperand(0).isMBB() &&
lib/Target/Hexagon/HexagonFrameLowering.cpp
  557   assert(F.hasFnAttribute(Attribute::NoReturn) &&
  575   assert(!MFI.hasVarSizedObjects() &&
  618     assert((MI->getOpcode() == Hexagon::PS_alloca) && "Expected alloca");
  639     assert(alignTo(NumBytes, 8) == NumBytes);
  799   assert(MBB.getNumber() >= 0);
 1088   assert(SpillFunc && "Unknown spill kind");
 1164   assert((HasFP || !UseFP) && "This function must have frame pointer");
 1315       assert(It->isReturn() && std::next(It) == MBB.end());
 1348   assert((Opc == Hexagon::ADJCALLSTACKDOWN || Opc == Hexagon::ADJCALLSTACKUP) &&
 1381   assert(A <= 8 && "Unexpected local frame alignment");
 1532     assert(isPowerOf2_32(Align));
 2230     assert(F != BlockIndexes.end());
 2249         assert(SI.mayStore() && "Unexpected start instruction");
 2250         assert(EI.mayLoad() && "Unexpected end instruction");
 2303           assert(MI.getOperand(0).getSubReg() == 0);
 2308             assert(HII.getAddrMode(MI) == HexagonII::BaseImmOffset);
lib/Target/Hexagon/HexagonGenInsert.cpp
  138       assert(Idx < size());
  213       assert(F != end());
  257   assert(V1.RefI.Pos != V2.RefI.Pos && "Bit values should be different");
  389       assert(Idx < Seq.size());
  448   assert(Seq.size() <= MaxSize);
  610           assert(MO.getSubReg() == 0 && "Unexpected subregister in definition");
  752   assert(FromB != ToB);
  851     assert(B == E || L == W-S);
 1021       assert(DefI);
 1062   assert(F != IFMap.end());
 1150   assert(F != IFMap.end());
 1171   assert(F != IFMap.end());
 1269     assert(F != UseC.end());
 1335     assert(MinI != LL.end());
 1507   assert(!OptSelectAll0 || !OptSelectHas0);
lib/Target/Hexagon/HexagonGenMux.cpp
  367       assert(Op.getSubReg() == 0 && "Should have physical registers only");
lib/Target/Hexagon/HexagonGenPredicate.cpp
  248   assert(Register::isVirtualRegister(Reg.R));
  255   assert(DefI);
  258     assert(DefI->getOperand(0).isDef() && DefI->getOperand(1).isUse());
  371   assert(isConvertibleToPredForm(MI));
  414   assert(Op0.isDef());
  482       assert(!DR.S && !SR.S && "Unexpected subregister");
lib/Target/Hexagon/HexagonHardwareLoops.cpp
  147         assert ((!((Cmp & L) && (Cmp & G))) && "Malformed comparison operator");
  344       assert(isReg() && "Wrong CountValue accessor");
  349       assert(isReg() && "Wrong CountValue accessor");
  354       assert(isImm() && "Wrong CountValue accessor");
  569   assert(PI != TopMBB->pred_end() &&
  626   assert (TB && "Exit block without a branch?");
  638   assert ((!FB || TB == Header || FB == Header) && "Branches not to header?");
  809     assert (Dist1 > 0 && "Fishy thing.  Both operands have the same sign.");
  829   assert (PH && "Should have a preheader by now");
 1127   assert(L->getHeader() && "Loop without a header?");
 1254     assert(TripCount->isImm() && "Expecting immediate value for trip count");
 1322   assert (BumpI != CmpI && "Bump and compare in the same instruction?");
 1355   assert (FoundBump && "Cannot determine instruction order");
 1389   assert(Phi->isPHI() && "Expecting a Phi.");
 1584   assert(MO.isReg());
 1939     assert(Header->pred_size() == 2);
 1971       assert (!NotAnalyzed && "Should be analyzable!");
 1983   assert (!LatchNotAnalyzed && "Should be analyzable!");
lib/Target/Hexagon/HexagonHazardRecognizer.cpp
  125     assert(TII->mayBeNewStore(*MI) && "Expecting .new store");
  130     assert(Resources->canReserveResources(*NewMI));
lib/Target/Hexagon/HexagonISelDAGToDAG.cpp
   80   assert(LoadedVT.isSimple());
  152     assert(LoadedVT.getSizeInBits() <= 32);
  476   assert(StoredVT.isSimple());
  519     assert(StoredVT.getSizeInBits() < 64 && "Not a truncating store");
  721     assert(!(cast<ConstantSDNode>(N)->getZExtValue() >> 1));
  799     assert(VecLen == 64);
  813   assert(isPowerOf2_32(-Mask));
  853   assert(HST->getVectorLength() * 8 == OpTy.getSizeInBits());
  866   assert(HST->getVectorLength() * 8 == ResTy.getSizeInBits());
 1480   assert(RT == MVT::i32);
 1618   assert(RootWeights.count(N) && "Cannot get weight of unseen root!");
 1619   assert(RootWeights[N] != -1 && "Cannot get weight of unvisited root!");
 1620   assert(RootWeights[N] != -2 && "Cannot get weight of RAWU'd root!");
 1627   assert(RootWeights.count(N) && RootWeights[N] >= 0 &&
 1642     assert(Weight >= 0 && "Weight must be >= 0");
 1646     assert(A.Value.getNode() && B.Value.getNode());
 1878   assert(RootWeights.count(N) && "Cannot balance non-root node.");
 1879   assert(RootWeights[N] != -2 && "This node was RAUW'd!");
 1880   assert(!TopLevel || N->getOpcode() == ISD::ADD);
 1886   assert(isOpcodeHandled(N));
 2013       assert(ChildOpcode == NOpcode ||
 2024         assert(!NodeHeights.count(Child) && "Parent visited before children?");
 2145     assert(L0.Weight <= L1.Weight && "Priority queue is broken!");
 2170     assert(NodeHeights.count(V0) && NodeHeights.count(V1) &&
 2194   assert(Leaves.size() == 1);
 2197   assert(NodeHeights.count(NewRoot));
lib/Target/Hexagon/HexagonISelDAGToDAGHVX.cpp
  357       assert(isUInt<8>(W));
  625     assert(!R.isValue());
  629     assert(!R.isValue());
  723     assert((OpN & Whole) == LoHalf || (OpN & Whole) == HiHalf);
  868   assert(MaskL.size() == VecLen && MaskR.size() == VecLen);
  885   assert(A.size() > 0 && A.size() >= MaxLen);
  914   assert(Mask.size() < 0x00007FFF && "Sanity failure");
  991       assert(R.isValid());
 1006       assert(Idx >= 0 && unsigned(Idx) < Output.size());
 1010         assert(Part == OpRef::LoHalf || Part == OpRef::HiHalf);
 1020     assert(Node.Ty != MVT::Other);
 1062     assert(M.MinSrc >= 0 && M.MaxSrc >= 0);
 1177     assert(Idx < 2);
 1188       assert(Idx == 0 || Idx == 1);
 1222   assert(HwLen == VecLen);
 1224   assert(all_of(SM.Mask, [this](int M) { return M == -1 || M < int(HwLen); }));
 1365   assert(ElemTy == MVT::i8);
 1415     assert(L.getNode());
 1435   assert(!N->use_empty());
 1473       assert(F != NumOps.end());
 1474       assert(F->second > 0);
 1479   assert(SubNodes.size() == TmpQ.size());
 1573     assert(Strip.first == 0 || Strip.first == L);
 1603   assert(Strip.first == 0 || Strip.first == L);
 1629   assert(2*HwLen == unsigned(VecLen) && "Expecting vector-pair type");
 1679   assert(isPowerOf2_32(VecLen) && Log2_32(VecLen) <= 8);
 1684   assert(LogLen == HwLog || LogLen == HwLog+1);
 1785   assert(VecLen > 2);
 1866     assert(!(IsDeal || IsShuff) || IsDeal != IsShuff);
 2008   assert(ResTy.isVector() && ResTy.getVectorElementType() == MVT::i8);
 2019   assert(ResTy.getSizeInBits() / 8 == VecLen);
 2029     assert(Idx < 2*VecLen);
lib/Target/Hexagon/HexagonISelLowering.cpp
  511   assert(Mask && "Missing call preserved mask for calling convention");
  669   assert(AlignConst && "Non-constant Align in LowerDYNAMIC_STACKALLOC");
  746         assert(RegVT.getSizeInBits() <= 32);
  754         assert(RegSize == 32 || RegSize == 64 ||
  761       assert(VA.isMemLoc() && "Argument should be passed in memory");
  820     assert(ElemTy.isScalarInteger());
  878     assert(ElemTy.isScalarInteger());
  901   assert(isPowerOf2_32(NumVectorElements) &&
  910     assert((x == 0 || x == 255) && "Either all 0's or all 1's expected!");
  944   assert(cast<ConstantPoolSDNode>(T)->getTargetFlags() == TF &&
 1095   assert(Mask && "Missing call preserved mask for calling convention");
 1747   assert(Idx >= 0 && "Unexpected index to incoming argument in PHI");
 1914   assert(AM.size() <= 8 && "Unexpected shuffle mask");
 1918   assert(!Subtarget.isHVXVectorType(VecTy, true) &&
 1920   assert(VecTy.getSizeInBits() <= 64 && "Unexpected vector length");
 1956   assert(ByteMask.size() <= 8);
 2079   assert(ResTy.getSizeInBits() == InpTy.getSizeInBits());
 2126   assert(VecTy.getVectorNumElements() == Elem.size());
 2143     assert(Elem.size() == 2);
 2183     assert(Elem.size() == 4);
 2209   assert(VecTy.getVectorNumElements() == Elem.size());
 2271   assert(!ValTy.isVector() ||
 2276   assert((VecWidth % ElemWidth) == 0);
 2282     assert(VecWidth == VecTy.getVectorNumElements() && "Sanity failure");
 2283     assert(VecWidth == 8 || VecWidth == 4 || VecWidth == 2);
 2309     assert(ty(IdxV) == MVT::i32);
 2326   assert(VecWidth == 32 || VecWidth == 64);
 2338       assert(Off == 0 || Off == 32);
 2372     assert(ValTy.getVectorElementType() == MVT::i1);
 2376     assert(Scale > 1);
 2399   assert(VecWidth == 32 || VecWidth == 64);
 2400   assert((VecWidth % ValWidth) == 0);
 2434   assert(ty(Vec32).getSizeInBits() == 32);
 2443   assert(ty(Vec64).getSizeInBits() == 64);
 2453     assert(Ty.isInteger() && "Only integer vectors are supported here");
 2527     assert(Op.getNumOperands() == 2);
 2534     assert(VecTy == MVT::v2i1 || VecTy == MVT::v4i1 || VecTy == MVT::v8i1);
 2539     assert(Scale == Op.getNumOperands() && Scale > 1);
 2576     assert(Scale == 2 && Words[IdxW].size() == 2);
 2698   assert(LoadTy.getSizeInBits() == 8*NeedAlign);
 2749   assert(VTs.NumVTs == 2);
 2750   assert(VTs.VTs[1] == MVT::i1);
 2755     assert(VY != 0 && "This should have been folded");
 3213     assert(BitWidth == 2 * VecWidth);
 3246   assert((SZ == 32 || SZ == 64) && "Only 32/64-bit atomic loads supported");
 3270   assert((SZ == 32 || SZ == 64) && "Only 32/64-bit atomic stores supported");
lib/Target/Hexagon/HexagonISelLowering.h
  392       assert((TyWidth % ElemWidth) == 0);
lib/Target/Hexagon/HexagonISelLoweringHVX.cpp
  212   assert(Tys.first.getVectorElementType() == Tys.second.getVectorElementType());
  221   assert(VecTy.isVector());
  223   assert((NumElem % 2) == 0 && "Expecting even-sized vector type");
  299   assert(ElemWidth >= 8 && ElemWidth <= 32);
  316   assert(OpTy == ty(Op1));
  321   assert(ElemTy.getSizeInBits() >= 8);
  337   assert(ResTy.getVectorNumElements() == ByteMask.size());
  353   assert(ElemSize*VecLen == HwLen);
  357     assert((ElemSize == 1 || ElemSize == 2) && "Invalid element size");
  383     assert(SplatV.getNode());
  430       assert(I >= 0 && "Negative element index");
  475   assert(4*Words.size() == Subtarget.getVectorLength());
  533   assert(PredTy == MVT::v2i1 || PredTy == MVT::v4i1 || PredTy == MVT::v8i1);
  571   assert(Bytes == BitBytes);
  591   assert(VecLen <= HwLen || VecLen == 8*HwLen);
  610     assert(HwLen % VecLen == 0);
  642         assert(Values[I+B].isUndef() || Values[I+B] == F);
  662   assert(ElemWidth >= 8 && ElemWidth <= 32);
  684   assert(ResTy == MVT::i1);
  705   assert(ElemWidth >= 8 && ElemWidth <= 32);
  788   assert(ResTy.getSizeInBits() == 32 || ResTy.getSizeInBits() == 64);
  827     assert(isPowerOf2_32(Rep) && HwLen % Rep == 0);
  895         assert(Idx == 0 || Idx == VecTy.getVectorNumElements()/2);
  916   assert(SubTy.getSizeInBits() == 32 || SubTy.getSizeInBits() == 64);
  961   assert(Subtarget.isHVXVectorType(VecTy, true));
  967   assert(HwLen % VecLen == 0 && "Unexpected vector type");
 1007   assert(Subtarget.isHVXVectorType(ResTy));
 1011   assert(ty(VecV).getVectorNumElements() == ResTy.getVectorNumElements());
 1088   assert(VecTy.getVectorElementType() == MVT::i1);
 1090   assert(isPowerOf2_32(NumOp) && HwLen % NumOp == 0);
 1169   assert(Idx % DstTy.getVectorNumElements() == 0);
 1238   assert(ResTy == ty(InpV));
 1245   assert(isPowerOf2_32(ElemWidth) && ElemWidth <= 32);
 1269   assert(ResTy.isVector() && isHvxSingleTy(ResTy));
 1323   assert(ResTy.isVector());
 1356   assert(ElemTy == MVT::i32);
 1429   assert(Op.getOpcode() == ISD::ANY_EXTEND_VECTOR_INREG);
 1443   assert(!Op.isMachineOpcode());
 1477   assert(BN->isUnindexed());
 1507     assert(MemOpc == ISD::STORE);
lib/Target/Hexagon/HexagonInstrInfo.cpp
  557   assert(!BytesRemoved && "code size not handled");
  586   assert(validateBranchCond(Cond) && "Invalid branching condition");
  587   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  588   assert(!BytesAdded && "code size not handled");
  615       assert(Cond[1].isMBB());
  621       assert(Loop != nullptr && "Inserting an ENDLOOP without a LOOP");
  626       assert((Cond.size() == 3) && "Only supporting rr/ri version of nvjump");
  643       assert((Cond.size() == 2) && "Malformed cond vector");
  650   assert((!Cond.empty()) &&
  652   assert((!isNewValueJump(Cond[0].getImm())) &&
  657     assert(Cond[1].isMBB());
  663     assert(Loop != nullptr && "Inserting an ENDLOOP without a LOOP");
  734       assert(TripCount > 0 && "Can't create an empty or negative loop!");
 1260       assert(Op1.getSubReg() == 0);
 1294       assert(Op1.getSubReg() == 0);
 1526   assert(Cond[0].isImm() && "First entry in the cond vector not imm-val");
 1529   assert(get(opcode).isBranch() && "Should be a branching condition.");
 1568   assert (isPredicable(MI) && "Expected predicable instruction");
 1592   assert(GotPredReg);
 2062   assert(MO.isImm() && "Extendable operand must be Immediate type");
 2440   assert(isPredicated(MI));
 2446   assert(isPredicated(Opcode));
 2459   assert((F>> HexagonII::PredicatedPos) & HexagonII::PredicatedMask);
 2476   assert(get(Opcode).isBranch() &&
 2698     assert(isPowerOf2_32(VectorSize));
 2944   assert((!BaseOp || BaseOp->isReg()) &&
 3381   assert(getCompoundCandidateGroup(GA) == HexagonII::HCG_A);
 3382   assert(getCompoundCandidateGroup(GB) == HexagonII::HCG_B);
 3599     assert(MI.isConditionalBranch());
 3629         assert(NextIt->isUnconditionalBranch());
 3695     assert(NewOp >= 0 &&
 3701     assert(NewOp >= 0 && "Couldn't change new-value store to its old form.");
 4263   assert(Cond.size() == 2);
 4314       assert(NumDefs != MI.getNumOperands()-2 && "No asm string?");
 4316     assert(MI.getOperand(NumDefs).isSymbol() && "No asm string?");
 4344   assert(BundleHead->isBundle() && "Not a bundle header");
 4353   assert((isExtendable(MI)||isConstExtended(MI)) &&
 4359   assert((MO.isMBB() || MO.isImm()) &&
 4370   assert(MI.isBranch());
 4377   assert((TargetPos >= 0) && MI.getOperand(TargetPos).isMBB());
 4421   assert(PredRevOpcode > 0);
 4433   assert(MIB->isBundle());
 4442   assert(MIB.isBundle());
lib/Target/Hexagon/HexagonLoopIdiomRecognition.cpp
  342   assert(R != M.end());
  490     assert(!isa<PHINode>(U));
 1003   assert(!OrigTy->isVoidTy() && "Invalid instruction to promote");
 1023         assert(Ty->getBitWidth() < DestBW);
 1054   assert(LoopB);
 1068     assert(P.getIncomingBlock(0) == LoopB);
 1097       assert(Ty0 == DestTy);
 1224   assert(AE != AL);
 1488   assert(Q[0] == 1);
 1542     assert(QI && QI->getBitWidth() <= 32);
 1878   assert(FoundScan);
 2009   assert((SI->isSimple() || (SI->isVolatile() && HexagonVolatileMemcpy)) &&
 2387   assert(!isa<SCEVCouldNotCompute>(BECount) &&
lib/Target/Hexagon/HexagonMCInstLower.cpp
  109   assert(MCI->getOpcode() == static_cast<unsigned>(MI->getOpcode()) &&
lib/Target/Hexagon/HexagonMachineScheduler.cpp
  241   assert(CurrentTop == CurrentBottom && "Nonempty unscheduled zone.");
  284   assert((!ForceTopDown || !ForceBottomUp) &&
  308   assert(SU->getInstr() && "Scheduled SUnit must have instr");
  366   assert(MinReadyCycle < std::numeric_limits<unsigned>::max() &&
  451     assert(Pending.isInQueue(SU) && "bad ready count");
  472     assert(i <= (HazardRec->getMaxLookAhead() + MaxMinLatency) &&
  896   assert(BotResult != NoCand && "failed to find the first candidate");
  914   assert(TopResult != NoCand && "failed to find the first candidate");
  947     assert(Top.Available.empty() && Top.Pending.empty() &&
  958       assert(TopResult != NoCand && "failed to find the first candidate");
  969       assert(BotResult != NoCand && "failed to find the first candidate");
lib/Target/Hexagon/HexagonMachineScheduler.h
   57     assert(ResourcesModel && "Unimplemented CreateTargetScheduleState.");
lib/Target/Hexagon/HexagonNewValueJump.cpp
  159   assert(HadDef);
  569           assert(
  683           assert((isNewValueJumpCandidate(*cmpInstr)) &&
  703           assert(NewMI && "New Value Jump Instruction Not created!");
lib/Target/Hexagon/HexagonOptAddrMode.cpp
  394     assert(!(UseN.Addr->getFlags() & NodeAttrs::PhiRef) &&
  496       assert(NewOpCode >= 0 && "Invalid New opcode\n");
  507       assert(NewOpCode >= 0 && "Invalid New opcode\n");
  524       assert(NewOpCode >= 0 && "Invalid New opcode\n");
  556       assert(NewOpCode >= 0 && "Invalid New opcode\n");
  565       assert(NewOpCode >= 0 && "Invalid New opcode\n");
  578     assert(NewOpCode >= 0 && "Invalid New opcode\n");
  615     assert(!(UseUN.Addr->getFlags() & NodeAttrs::PhiRef) &&
  625     assert(HII->getAddrMode(*UseMI) == HexagonII::BaseImmOffset);
  630     assert(NewOpCode >= 0 && "Invalid New opcode\n");
  744       assert(!(UseN.Addr->getFlags() & NodeAttrs::PhiRef) &&
lib/Target/Hexagon/HexagonOptimizeSZextends.cpp
   80             assert (EVT::getEVT(SI->getType()) ==
lib/Target/Hexagon/HexagonPeephole.cpp
  136         assert(MI.getNumOperands() == 2);
  154         assert(MI.getNumOperands() == 3);
  171         assert(MI.getNumOperands() == 3);
  185         assert(MI.getNumOperands() == 2);
  203         assert(MI.getNumOperands() == 2);
lib/Target/Hexagon/HexagonRDFOpt.cpp
  123       assert(DstOp.getSubReg() == 0 && "Unexpected subregister");
lib/Target/Hexagon/HexagonRegisterInfo.cpp
  185   assert(SPAdj == 0 && "Unexpected");
  310   assert(GenIdx == Hexagon::ps_sub_lo || GenIdx == Hexagon::ps_sub_hi);
lib/Target/Hexagon/HexagonSplitDouble.cpp
  403   assert(Register::isVirtualRegister(Reg));
  500   assert(Cond[1].isReg() && "Unexpected Cond vector from analyzeBranch");
  503   assert(MRI->getRegClass(PR) == &Hexagon::PredRegsRegClass);
  647   assert(F != PairMap.end());
  678     assert(!UpdOp.getSubReg() && "Def operand with subreg");
  704   assert(Op0.isReg() && Op1.isImm());
  710   assert(F != PairMap.end());
  732   assert(Op0.isReg());
  737   assert(F != PairMap.end());
  761   assert(Op0.isReg() && Op1.isReg());
  766   assert(F != PairMap.end());
  784   assert(Op0.isReg() && Op1.isReg() && Op2.isImm());
  786   assert(Sh64 >= 0 && Sh64 < 64);
  790   assert(F != PairMap.end());
  909   assert(Op0.isReg() && Op1.isReg() && Op2.isReg() && Op3.isImm());
  911   assert(Sh64 >= 0 && Sh64 < 64);
  915   assert(F != PairMap.end());
lib/Target/Hexagon/HexagonStoreWidening.cpp
  123   assert(MO.isReg() && "Expecting register operand");
  129   assert(HexagonStoreWidening::handledStoreType(MI) && "Unhandled opcode");
  136       assert(MO.isImm() && "Expecting immediate offset");
  146   assert(!MI->memoperands_empty() && "Expecting memory operands");
  240   assert(handledStoreType(BaseStore) && "Unexpected instruction");
  307   assert(Begin != End && "No instructions to analyze");
  308   assert(OG.empty() && "Old group not empty on entry");
  314   assert(!FirstMI->memoperands_empty() && "Expecting some memory operands");
  321   assert(isPowerOf2_32(SizeAccum) && "First store size not a power of 2");
  406     assert(SO.isImm() && "Expecting an immediate operand");
  427     assert(WOpc && "Unexpected size");
  451     assert(WOpc && "Unexpected size");
  505   assert((InsertAt != MBB->end()) && "Cannot locate any store from the group");
  551     assert(OG.size() > 1 && "Created invalid group");
  552     assert(distance(I, E)+1 >= int(OG.size()) && "Too many elements");
  577     assert(G.size() > 1 && "Store group with fewer than 2 elements");
lib/Target/Hexagon/HexagonSubtarget.cpp
   88   assert(InstrItins.Itineraries != nullptr && "InstrItins not initialized");
  430     assert(DefIdx >= 0 && "Def Reg not found in Src MI");
  451     assert(F != Dst->Preds.end());
  468     assert(F != Dst->Preds.end());
lib/Target/Hexagon/HexagonSubtarget.h
  217     assert(useHVXOps());
lib/Target/Hexagon/HexagonTargetTransformInfo.cpp
   47   assert(VecTy->isVectorTy());
   65   assert((Ty->isIntegerTy() || Ty->isFloatingPointTy()) &&
  158   assert(Opcode == Instruction::Load || Opcode == Instruction::Store);
  167       assert(RegWidth && "Non-zero vector register width expected");
  175       assert(Alignment);
  193     assert(BoundAlignment <= Align(8));
lib/Target/Hexagon/HexagonVExtract.cpp
  141       assert(ExtI->getOpcode() == Hexagon::V6_extractw);
  143       assert(ExtI->getOperand(1).getReg() == VecR);
lib/Target/Hexagon/HexagonVLIWPacketizer.cpp
  171   assert(MI.isBundledWithPred());
  199   assert(!SingleI.isBundledWithSucc());
  221   assert(Packetizer.getResourceTracker() && "Empty DFA table!");
  371   assert(DepType == SDep::Data);
  453   assert(DepType == SDep::Data);
  509   assert(SUI->getInstr() && SUJ->getInstr());
  570   assert(HII->isPostIncrement(MI) && "Not a post increment operation.");
  622   assert(isLoadAbsSet(MI));
  711     assert((predRegClass == &Hexagon::PredRegsRegClass) &&
  723     assert((predRegClass == &Hexagon::PredRegsRegClass) &&
  944   assert(QII->isPredicated(MI) && "Must be predicated instruction");
 1271     assert((J.isCall() || HII->isTailCall(J)) && "Regmask on a non-call");
 1311   assert(SUI->getInstr() && SUJ->getInstr());
 1322   assert(!isSoloInstruction(I) && "Unexpected solo instr!");
 1622   assert(SUI->getInstr() && SUJ->getInstr());
 1702   assert(ResourceTracker->canReserveResources(MI));
 1729       assert(ResourceTracker->canReserveResources(MI));
 1732         assert(canReserveResourcesForConstExt());
 1735       assert(ResourceTracker->canReserveResources(NvjMI));
 1738         assert(canReserveResourcesForConstExt());
lib/Target/Hexagon/HexagonVectorLoopCarriedReuse.cpp
  423       assert(C2);
  595   assert(PN);
  608   assert(!DepChains.empty() && "No DepChains");
  655   assert(CurLoop->getSubLoops().empty() &&
  657   assert((CurLoop->getNumBlocks() == 1) &&
  704     assert(BEInst && "There should be a value over the backedge");
lib/Target/Hexagon/MCTargetDesc/HexagonAsmBackend.cpp
   78     assert(Extender != nullptr);
  197     assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  429     assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
  574     assert(HexagonMCInstrInfo::isBundle(MCB));
  653     assert(HexagonMCInstrInfo::isBundle(Inst) &&
  666         assert((HexagonMCInstrInfo::bundleSize(Res) < HEXAGON_PACKET_SIZE) &&
  680     assert(Update && "Didn't find relaxation target");
lib/Target/Hexagon/MCTargetDesc/HexagonInstPrinter.cpp
   35   assert(HexagonMCInstrInfo::isBundle(*MI));
   36   assert(HexagonMCInstrInfo::bundleSize(*MI) <= HEXAGON_PACKET_SIZE);
   37   assert(HexagonMCInstrInfo::bundleSize(*MI) > 0);
   83   assert (MO.isExpr());
lib/Target/Hexagon/MCTargetDesc/HexagonMCChecker.cpp
  417     assert(Op.isReg());
  499       assert(Operand.isReg() && "Def is not a register");
lib/Target/Hexagon/MCTargetDesc/HexagonMCCodeEmitter.cpp
  345       assert(!Duplex);
  346       assert(State.Index != Last);
  352       assert(!Duplex);
  353       assert(State.Index != Last);
  358     assert(State.Index == Last);
  372   assert(HexagonMCInstrInfo::isBundle(HMB));
  409   assert(!HexagonMCInstrInfo::isBundle(MI));
  414   assert(!HexagonMCInstrInfo::getDesc(MCII, MI).isPseudo() &&
  433     assert(Parse == HexagonII::INST_PARSE_DUPLEX &&
  481         assert(I+1 != N && "Extender cannot be last in packet");
  605       assert(OpIdx != ~0u);
  613   assert(ME->getKind() == MCExpr::SymbolRef ||
  653         assert(Shift < array_lengthof(GPRelFixups));
  729   assert((OperandNumber != ~0U) && "Operand not found");
  744       assert(I != Instrs.begin() - 1 && "Couldn't find producer");
  767       assert(HexagonMCInstrInfo::isPredicated(MCII, MI) &&
  782   assert(!MO.isImm());
lib/Target/Hexagon/MCTargetDesc/HexagonMCCompound.cpp
  178   assert((PredReg == Hexagon::P0) || (PredReg == Hexagon::P1) ||
  276     assert(Success);
  294     assert(Success);
  350   assert(HexagonMCInstrInfo::isBundle(MCI));
  400   assert(HexagonMCInstrInfo::isBundle(MCI) &&
lib/Target/Hexagon/MCTargetDesc/HexagonMCDuplexInfo.cpp
  769     assert(Absolute);(void)Absolute;
  894     assert(Absolute);(void)Absolute;
  926     assert(Absolute);(void)Absolute;
 1038   assert(isBundle(MCB));
lib/Target/Hexagon/MCTargetDesc/HexagonMCELFStreamer.cpp
   63   assert(MCB.getOpcode() == Hexagon::BUNDLE);
   64   assert(HexagonMCInstrInfo::bundleSize(MCB) <= HEXAGON_PACKET_SIZE);
   65   assert(HexagonMCInstrInfo::bundleSize(MCB) > 0);
lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.cpp
   85   assert((!Val || !MustNotExtend) && "Extension contradiction");
   91   assert((!Val || !MustExtend) && "Extension contradiction");
lib/Target/Hexagon/MCTargetDesc/HexagonMCInstrInfo.cpp
   89   assert(HexagonMCInstrInfo::isBundle(MCB));
  104   assert(isBundle(MCI));
  111   assert(isBundle(MCI));
  162   assert(HexagonMCInstrInfo::isExtendable(MCII, Inst) ||
  179   assert((iClass <= 0xf) && "iClass must have range of 0 to 0xf");
  192   assert(Index <= bundleSize(MCB));
  280   assert(HExpr.getExpr());
  296   assert((HexagonMCInstrInfo::isExtendable(MCII, MCI) ||
  323   assert(HexagonMCInstrInfo::isExtendable(MCII, MCI) ||
  334   assert(HexagonMCInstrInfo::isExtendable(MCII, MCI) ||
  364     assert((HexagonMCInstrInfo::isNewValue(MCII, MCI) ||
  384   assert((HexagonMCInstrInfo::isNewValue(MCII, MCI) ||
  475   assert(isBundle(MCB));
  476   assert(Index < HEXAGON_PACKET_SIZE);
  489   assert(!Result || (MCI.size() > 0 && MCI.getOperand(0).isImm()));
  515   assert(!MO.isImm());
  595   assert(isBundle(MCI));
  623   assert(isBundle(MCI));
  690   assert(isBundle(MCI));
  808   assert(isBundle(MCB));
  841   assert(Candidate.packetIndexI < MCB.size());
  842   assert(Candidate.packetIndexJ < MCB.size());
  843   assert(isBundle(MCB));
  848   assert(Duplex != nullptr);
  854   assert(isBundle(MCI));
  860   assert(isBundle(MCI));
  863   assert(isMemReorderDisabled(MCI));
  867   assert(isBundle(MCI));
lib/Target/Hexagon/MCTargetDesc/HexagonMCShuffler.cpp
   41       assert(!HexagonMCInstrInfo::getDesc(MCII, MI).isPseudo());
   63       assert(!HexagonMCInstrInfo::getDesc(MCII, *I.getInst()).isPseudo());
lib/Target/Hexagon/MCTargetDesc/HexagonMCTargetDesc.cpp
  142     assert(HexagonMCInstrInfo::isBundle(Inst));
  143     assert(HexagonMCInstrInfo::bundleSize(Inst) <= HEXAGON_PACKET_SIZE);
  418   assert(F != ElfFlags.end() && "Unrecognized Architecture");
  443     assert(Extended.isExpr());
lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
  387         assert(HexagonMCInstrInfo::getDesc(MCII, ID).mayStore());
lib/Target/Hexagon/RDFCopy.cpp
   48       assert(Register::isPhysicalRegister(DstR.Reg));
   49       assert(Register::isPhysicalRegister(SrcR.Reg));
   94     assert(RA.Addr->getKind() == NodeAttrs::Use);
  165         assert(DFG.IsCode<NodeAttrs::Stmt>(IA));
lib/Target/Hexagon/RDFGraph.cpp
  351   assert((Blocks.size() < ((size_t)1 << (8*sizeof(NodeId)-BitsPerIndex))) &&
  409   assert(NodeAttrs::type(Attrs) == NodeAttrs::Ref);
  412   assert(Ref.Op != nullptr);
  419   assert(NodeAttrs::type(Attrs) == NodeAttrs::Ref);
  420   assert(NodeAttrs::flags(Attrs) & NodeAttrs::PhiRef);
  427   assert(NodeAttrs::type(Attrs) == NodeAttrs::Ref);
  428   assert(!(NodeAttrs::flags(Attrs) & NodeAttrs::PhiRef));
  497   assert(MA.Id != 0);
  537     assert(NA.Addr->getType() == NodeAttrs::Code);
  553   assert(M.Addr->getType() == NodeAttrs::Code);
  561     assert(M.Addr->getKind() == NodeAttrs::Phi);
  566       assert(MN.Addr->getType() == NodeAttrs::Code);
  609   assert(Op.isReg());
  689   assert(!empty());
  696   assert(N != 0);
  704   assert(N != 0);
  722   assert(P < SS);
  727   assert(!IsDelim);
  735   assert(P > 0 && P <= Stack.size());
  742   assert(!IsDelim);
  816   assert(Flags & NodeAttrs::PhiRef);
  832   assert(Flags & NodeAttrs::PhiRef);
  896   assert(EntryB.pred_empty() && "Function entry block has predecessors");
  965   assert(PhysicalRegisterInfo::isRegMaskId(Reg) ||
  967   assert(Reg != 0);
  974   assert(Op.isReg() || Op.isRegMask());
 1062       assert(A != RR.Reg);
 1117       assert(A != RR.Reg);
 1130   assert(IA.Id != 0 && RA.Id != 0);
 1156   assert(IA.Id != 0 && RA.Id != 0);
 1195   assert(IA.Id != 0 && RA.Id != 0);
 1217   assert(IA.Id != 0 && RA.Id != 0);
 1238   assert(IA.Id != 0 && RA.Id != 0);
 1312     assert(!DoneDefs.test(R));
 1389   assert(BB);
 1620     assert(Kind == NodeAttrs::Def || Kind == NodeAttrs::Use);
 1624     assert(Kind != NodeAttrs::Def || !Defs.count(RR));
 1654   assert(BA.Addr && "block node address is needed to create a data-flow link");
 1687     assert(NA.Addr->getFlags() & NodeAttrs::PhiRef);
 1703         assert(RA.Id != 0);
 1726     assert(Sib == 0);
 1799     assert(Sib == 0);
lib/Target/Hexagon/RDFGraph.h
  380       assert(isPowerOf2_32(NPB));
  439       assert(LM.any());
  444       assert(LM.any());
  521       assert(!(getFlags() & NodeAttrs::PhiRef));
  543       assert(getType() == NodeAttrs::Ref);
  548       assert(getType() == NodeAttrs::Ref);
  581       assert(getFlags() & NodeAttrs::PhiRef);
  585       assert(getFlags() & NodeAttrs::PhiRef);
  683           assert(Pos >= 1);
  687           assert(Pos >= 1);
  903         assert(NA.Addr->getType() == NodeAttrs::Code);
lib/Target/Hexagon/RDFLiveness.cpp
  172     assert(IA.Addr->getKind() == NodeAttrs::Phi);
  521         assert((UA.Addr->getFlags() & NodeAttrs::Undef) == 0);
 1019         assert(!(IA.Addr->getFlags() & NodeAttrs::Phi));
 1044           assert(T);
lib/Target/Hexagon/RDFRegisters.cpp
   52     assert(R.isValid());
  104   assert(isRegMaskId(Reg) || Register::isPhysicalRegister(Reg));
  132   assert(Register::isPhysicalRegister(RA.Reg));
  133   assert(Register::isPhysicalRegister(RB.Reg));
  163   assert(Register::isPhysicalRegister(RR.Reg) && isRegMaskId(RM.Reg));
  198   assert(isRegMaskId(RM.Reg) && isRegMaskId(RN.Reg));
  311   assert(NR);
lib/Target/Hexagon/RDFRegisters.h
   41       assert(Idx != 0 && !Map.empty() && Idx-1 < Map.size());
   56       assert(F != Map.end());
  207         assert(Owner == I.Owner);
lib/Target/Lanai/AsmParser/LanaiAsmParser.cpp
  155     assert(isReg() && "Invalid type access!");
  160     assert(isImm() && "Invalid type access!");
  165     assert(isToken() && "Invalid type access!");
  170     assert(isMem() && "Invalid type access!");
  175     assert(isMem() && "Invalid type access!");
  180     assert(isMem() && "Invalid type access!");
  185     assert(isMem() && "Invalid type access!");
  401     assert(N == 1 && "Invalid number of operands!");
  406     assert(N == 1 && "Invalid number of operands!");
  411     assert(N == 1 && "Invalid number of operands!");
  416     assert(N == 1 && "Invalid number of operands!");
  421     assert(N == 1 && "Invalid number of operands!");
  426     assert(N == 1 && "Invalid number of operands!");
  432     assert(N == 3 && "Invalid number of operands!");
  440     assert(N == 3 && "Invalid number of operands!");
  442     assert(getMemOffsetReg() != 0 && "Invalid offset");
  455     assert(N == 1 && "Invalid number of operands!");
  460     assert(N == 1 && "Invalid number of operands!");
  465     assert(N == 1 && "Invalid number of operands!");
  472       assert(SymbolRefExpr &&
  479       assert(BinaryExpr && isa<LanaiMCExpr>(BinaryExpr->getLHS()) &&
  485       assert(false && "Operand type not supported.");
  489     assert(N == 1 && "Invalid number of operands!");
  493       assert(false && "Operand type not supported.");
  497     assert(N == 1 && "Invalid number of operands!");
  503       assert(SymbolRefExpr &&
  510       assert(BinaryExpr && isa<LanaiMCExpr>(BinaryExpr->getLHS()) &&
  516       assert(false && "Operand type not supported.");
  520     assert(N == 1 && "Invalid number of operands!");
  524       assert(false && "Operand type not supported.");
  528     assert(N == 1 && "Invalid number of operands!");
  534       assert(SymbolRefExpr &&
  542       assert(SymbolRefExpr &&
  549       assert(BinaryExpr && isa<LanaiMCExpr>(BinaryExpr->getLHS()) &&
  555       assert(false && "Operand type not supported.");
  576       assert(getMemOffset() == nullptr);
lib/Target/Lanai/LanaiAluCode.h
   63   assert(!isPostOp(AluOp) && "Operator can't be a post- and pre-op");
   68   assert(!isPreOp(AluOp) && "Operator can't be a post- and pre-op");
lib/Target/Lanai/LanaiAsmPrinter.cpp
  150   assert((MI->getOpcode() == Lanai::CALL || MI->getOpcode() == Lanai::CALLR) &&
lib/Target/Lanai/LanaiDelaySlotFiller.cpp
  108         assert(RI->getOpcode() == Lanai::LDW_RI && RI->getOperand(0).isReg() &&
  114         assert(RI->getOpcode() == Lanai::ADD_I_LO &&
  200   assert((!MI->isCall() && !MI->isReturn()) &&
lib/Target/Lanai/LanaiFrameLowering.cpp
   93   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
lib/Target/Lanai/LanaiISelLowering.cpp
  490       assert(VA.isMemLoc());
  555     assert(VA.isRegLoc() && "Can only return in registers!");
  572     assert(Reg &&
  688       assert(VA.isMemLoc());
  742   assert(Mask && "Missing call preserved mask for calling convention");
 1240   assert(Op.getNumOperands() == 3 && "Unexpected SHL!");
lib/Target/Lanai/LanaiInstrInfo.cpp
   90   assert(MIa.mayLoadOrStore() && "MIa must be a load or store.");
   91   assert(MIb.mayLoadOrStore() && "MIb must be a load or store.");
  442   assert(MI.getOpcode() == Lanai::SELECT && "unknown select instruction");
  496   assert(MI.getOpcode() == Lanai::SELECT && "unknown select instruction");
  648   assert((Condition.size() == 1) &&
  667   assert(TrueBlock && "insertBranch must not be told to insert a fallthrough");
  668   assert(!BytesAdded && "code size not handled");
  672     assert(!FalseBlock && "Unconditional branch with multiple successors!");
  678   assert((Condition.size() == 1) &&
  694   assert(!BytesRemoved && "code size not handled");
  791   assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
lib/Target/Lanai/LanaiMemAluCombiner.cpp
  247   assert((AluOffset.isReg() || AluOffset.isImm()) &&
  254   assert(AluOpcode != LPAC::UNKNOWN && "Unknown ALU code in merging");
  255   assert(NewOpc != 0 && "Unknown merged node opcode");
  375       assert(AluOperand.isImm() && "Unexpected memory operator type");
lib/Target/Lanai/LanaiRegisterInfo.cpp
  139   assert(SPAdj == 0 && "Unexpected");
  172     assert(RS && "Register scavenging must be on");
  176     assert(Reg && "Register scavenger failed");
  215         assert((MI.getOperand(3).getImm() == LPAC::ADD) &&
lib/Target/Lanai/LanaiTargetTransformInfo.h
   53     assert(Ty->isIntegerTy());
lib/Target/Lanai/MCTargetDesc/LanaiAsmBackend.cpp
  161   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
lib/Target/Lanai/MCTargetDesc/LanaiInstPrinter.cpp
  150   assert((Modifier == 0 || Modifier[0] == 0) && "No modifiers supported");
  157     assert(Op.isExpr() && "Expected an expression");
  169     assert(Op.isExpr() && "Expected an expression");
  183     assert(Op.isExpr() && "Expected an expression");
  195     assert(Op.isExpr() && "Expected an expression");
  207     assert(Op.isExpr() && "Expected an expression");
  214   assert(RegOp.isReg() && "Register operand expected");
  228   assert((OffsetOp.isImm() || OffsetOp.isExpr()) && "Immediate expected");
  230     assert(isInt<SizeInBits>(OffsetOp.getImm()) && "Constant value truncated");
  258   assert(OffsetOp.isReg() && RegOp.isReg() && "Registers expected.");
lib/Target/Lanai/MCTargetDesc/LanaiMCCodeEmitter.cpp
  118   assert(MCOp.isExpr());
  127   assert(isa<LanaiMCExpr>(Expr) || Expr->getKind() == MCExpr::SymbolRef);
  150   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isReg() &&
  193   assert(Op1.isReg() && "First operand is not register.");
  194   assert((Op2.isImm() || Op2.isExpr()) &&
  196   assert((LPAC::getAluOp(AluOp.getImm()) == LPAC::ADD) &&
  201     assert(isInt<16>(Op2.getImm()) &&
  225   assert(Op1.isReg() && "First operand is not register.");
  227   assert(Op2.isReg() && "Second operand is not register.");
  230   assert(AluMCOp.isImm() && "Third operator is not immediate.");
  264   assert(Op1.isReg() && "First operand is not register.");
  265   assert((Op2.isImm() || Op2.isExpr()) &&
  267   assert((LPAC::getAluOp(AluOp.getImm()) == LPAC::ADD) &&
  272     assert(isInt<10>(Op2.getImm()) &&
lib/Target/MSP430/AsmParser/MSP430AsmParser.cpp
  125     assert((Kind == k_Reg || Kind == k_IndReg || Kind == k_PostIndReg) &&
  127     assert(N == 1 && "Invalid number of operands!");
  143     assert(Kind == k_Imm && "Unexpected operand kind");
  144     assert(N == 1 && "Invalid number of operands!");
  150     assert(Kind == k_Mem && "Unexpected operand kind");
  151     assert(N == 2 && "Invalid number of operands");
  179     assert(Kind == k_Tok && "Invalid access!");
  184     assert(Kind == k_Reg && "Invalid access!");
  189     assert(Kind == k_Reg && "Invalid access!");
lib/Target/MSP430/Disassembler/MSP430Disassembler.cpp
  210   assert(0 < Words && Words < 4 && "Incorrect number of words");
  215     assert(Words < 3 && "Incorrect number of words");
  218     assert(Words < 3 && "Incorrect number of words");
  224     assert(Words > 1 && "Incorrect number of words");
  228     assert(Words < 3 && "Incorrect number of words");
lib/Target/MSP430/MCTargetDesc/MSP430AsmBackend.cpp
  149   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
lib/Target/MSP430/MCTargetDesc/MSP430InstPrinter.cpp
   46     assert(Op.isExpr() && "unknown pcrel immediate operand");
   53   assert((Modifier == nullptr || Modifier[0] == 0) && "No modifiers supported");
   60     assert(Op.isExpr() && "unknown operand kind in printOperand");
   86     assert(Disp.isImm() && "Expected immediate in displacement field");
lib/Target/MSP430/MCTargetDesc/MSP430MCCodeEmitter.cpp
  113   assert(MO.isExpr() && "Expected expr operand");
  124   assert(MO1.isReg() && "Register operand expected");
  133   assert(MO2.isExpr() && "Expr operand expected");
  159   assert(MO.isExpr() && "Expr operand expected");
  169   assert(MO.isImm() && "Expr operand expected");
  188   assert(MO.isImm() && "Immediate operand expected");
lib/Target/MSP430/MSP430BranchSelector.cpp
   72   assert((DistanceInBytes % WordSize == 0) &&
  185         assert(MBB->isSuccessor(NextMBB) &&
lib/Target/MSP430/MSP430FrameLowering.cpp
   42   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  252         assert(Old.getOpcode() == TII.getCallFrameDestroyOpcode());
  296     assert(FrameIdx == MF.getFrameInfo().getObjectIndexBegin() &&
lib/Target/MSP430/MSP430ISelDAGToDAG.cpp
  394     assert(Node->getValueType(0) == MVT::i16);
lib/Target/MSP430/MSP430ISelLowering.cpp
  474     assert(ArgsParts.size() == 2 &&
  508       assert(Parts == 4 &&
  659       assert(VA.isMemLoc());
  747     assert(VA.isRegLoc() && "Can only return in registers!");
  836       assert(VA.isMemLoc());
  960     assert(VT == MVT::i16 && "Can not shift i8 by 8 and more");
 1030   assert(!LHS.getValueType().isFloatingPoint() && "We don't handle FP yet");
 1228   assert(VT == MVT::i16 && "Only support i16 for now!");
 1553   assert((Opc == MSP430::Select16 || Opc == MSP430::Select8) &&
lib/Target/MSP430/MSP430InstrInfo.cpp
  108   assert(!BytesRemoved && "code size not handled");
  133   assert(Cond.size() == 1 && "Invalid Xbranch condition!");
  230     assert(I->getOpcode() == MSP430::JCC && "Invalid conditional branch");
  246     assert(Cond.size() == 1);
  247     assert(TBB);
  272   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  273   assert((Cond.size() == 1 || Cond.size() == 0) &&
  275   assert(!BytesAdded && "code size not handled");
  279     assert(!FBB && "Unconditional branch with multiple successors!");
lib/Target/MSP430/MSP430InstrInfo.h
   73     assert(isFrameInstr(I) && "Not a frame instruction");
   74     assert(I.getOperand(1).getImm() >= 0 && "Size must not be negative");
lib/Target/MSP430/MSP430RegisterInfo.cpp
  106   assert(SPAdj == 0 && "Unexpected");
lib/Target/Mips/AsmParser/MipsAsmParser.cpp
  868     assert(isRegIdx() && (RegIdx.Kind & RegKind_GPR) && "Invalid access!");
  877     assert(isRegIdx() && (RegIdx.Kind & RegKind_GPR) && "Invalid access!");
  885     assert(isRegIdx() && (RegIdx.Kind & RegKind_GPR) && "Invalid access!");
  894     assert(isRegIdx() && (RegIdx.Kind & RegKind_FGR) && "Invalid access!");
  904     assert(isRegIdx() && (RegIdx.Kind & RegKind_FGR) && "Invalid access!");
  912     assert(isRegIdx() && (RegIdx.Kind & RegKind_FGR) && "Invalid access!");
  920     assert(isRegIdx() && (RegIdx.Kind & RegKind_FCC) && "Invalid access!");
  928     assert(isRegIdx() && (RegIdx.Kind & RegKind_MSA128) && "Invalid access!");
  938     assert(isRegIdx() && (RegIdx.Kind & RegKind_MSACtrl) && "Invalid access!");
  946     assert(isRegIdx() && (RegIdx.Kind & RegKind_COP0) && "Invalid access!");
  954     assert(isRegIdx() && (RegIdx.Kind & RegKind_COP2) && "Invalid access!");
  962     assert(isRegIdx() && (RegIdx.Kind & RegKind_COP3) && "Invalid access!");
  970     assert(isRegIdx() && (RegIdx.Kind & RegKind_ACC) && "Invalid access!");
  978     assert(isRegIdx() && (RegIdx.Kind & RegKind_ACC) && "Invalid access!");
  986     assert(isRegIdx() && (RegIdx.Kind & RegKind_ACC) && "Invalid access!");
  994     assert(isRegIdx() && (RegIdx.Kind & RegKind_CCR) && "Invalid access!");
 1002     assert(isRegIdx() && (RegIdx.Kind & RegKind_HWRegs) && "Invalid access!");
 1026     assert(N == 1 && "Invalid number of operands!");
 1031     assert(N == 1 && "Invalid number of operands!");
 1036     assert(N == 1 && "Invalid number of operands!");
 1041     assert(N == 1 && "Invalid number of operands!");
 1046     assert(N == 1 && "Invalid number of operands!");
 1051     assert(N == 1 && "Invalid number of operands!");
 1056     assert(N == 1 && "Invalid number of operands!");
 1062     assert(N == 1 && "Invalid number of operands!");
 1070     assert(N == 1 && "Invalid number of operands!");
 1075     assert(N == 1 && "Invalid number of operands!");
 1080     assert(N == 1 && "Invalid number of operands!");
 1085     assert(N == 1 && "Invalid number of operands!");
 1090     assert(N == 1 && "Invalid number of operands!");
 1095     assert(N == 1 && "Invalid number of operands!");
 1106     assert(N == 1 && "Invalid number of operands!");
 1115     assert(N == 1 && "Invalid number of operands!");
 1120     assert(N == 1 && "Invalid number of operands!");
 1125     assert(N == 1 && "Invalid number of operands!");
 1130     assert(N == 1 && "Invalid number of operands!");
 1135     assert(N == 1 && "Invalid number of operands!");
 1140     assert(N == 1 && "Invalid number of operands!");
 1145     assert(N == 1 && "Invalid number of operands!");
 1150     assert(N == 1 && "Invalid number of operands!");
 1155     assert(N == 1 && "Invalid number of operands!");
 1160     assert(N == 1 && "Invalid number of operands!");
 1165     assert(N == 1 && "Invalid number of operands!");
 1171     assert(N == 1 && "Invalid number of operands!");
 1199     assert(N == 1 && "Invalid number of operands!");
 1208     assert(N == 1 && "Invalid number of operands!");
 1214     assert(N == 2 && "Invalid number of operands!");
 1225     assert(N == 2 && "Invalid number of operands!");
 1234     assert(N == 1 && "Invalid number of operands!");
 1407     assert(Kind == k_Token && "Invalid access!");
 1423     assert((Kind == k_Immediate) && "Invalid access!");
 1435     assert((Kind == k_Memory) && "Invalid access!");
 1440     assert((Kind == k_Memory) && "Invalid access!");
 1449     assert((Kind == k_RegList) && "Invalid access!");
 1551     assert(Regs.size() > 0 && "Empty list not allowed");
 1800       assert(hasCnMips() && "instruction only valid for octeon cpus");
 1807       assert(MCID.getNumOperands() == 3 && "unexpected number of operands");
 1837       assert(MCID.getNumOperands() == 2 && "unexpected number of operands");
 1853       assert(MCID.getNumOperands() == 3 && "unexpected number of operands");
 1866       assert(MCID.getNumOperands() == 2 && "unexpected number of operands");
 1877       assert(MCID.getNumOperands() == 2 && "unexpected number of operands");
 1890       assert(MCID.getNumOperands() == 2 && "unexpected number of operands");
 1923         assert(MCID.getNumOperands() == 3 && "unexpected number of operands");
 1941         assert(MCID.getNumOperands() == 3 && "unexpected number of operands");
 2315     assert(Inst.getOperand(0).isReg() && "expected register operand kind");
 2316     assert((Inst.getOperand(1).isImm() || Inst.getOperand(1).isExpr()) &&
 2327     assert(Inst.getOperand(0).isReg() && "expected register operand kind");
 2328     assert(Inst.getOperand(1).isReg() && "expected register operand kind");
 2329     assert((Inst.getOperand(2).isImm() || Inst.getOperand(2).isExpr()) &&
 2781   assert(ImmOp.isImm() && "expected immediate operand kind");
 2783   assert(DstRegOp.isReg() && "expected register operand kind");
 3097       assert(SrcReg == DstReg && !canUseATReg() &&
 3132     assert(
 3280   assert(Inst.getNumOperands() == 2 && "Invalid operand count");
 3281   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isImm() &&
 3297   assert(Inst.getNumOperands() == 2 && "Invalid operand count");
 3298   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isImm() &&
 3351   assert(Inst.getNumOperands() == 2 && "Invalid operand count");
 3352   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isImm() &&
 3416   assert(Inst.getNumOperands() == 2 && "Invalid operand count");
 3417   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isImm() &&
 3490   assert(getInstDesc(Inst.getOpcode()).getNumOperands() == 1 &&
 3501     assert(Offset.isImm() && "expected immediate operand kind");
 3534   assert(DstRegOp.isReg() && "expected register operand kind");
 3537   assert(ImmOp.isImm() && "expected immediate operand kind");
 3540   assert((MemOffsetOp.isImm() || MemOffsetOp.isExpr()) &&
 3599   assert(DstRegOp.isReg() && "expected register operand kind");
 3601   assert(BaseRegOp.isReg() && "expected register operand kind");
 3625     assert(BaseRegOp.isReg() && "expected register operand kind");
 3627     assert(ExprOp.isExpr() && "expected expression oprand kind");
 3722   assert(Inst.getOperand(OpNum - 1).isImm() &&
 4023   assert(RdRegOp.isReg() && "expected register operand kind");
 4027   assert(RsRegOp.isReg() && "expected register operand kind");
 4034   assert((RtOp.isReg() || RtOp.isImm()) &&
 4191   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 4192   assert(Inst.getOperand(0).isReg() && Inst.getOperand(1).isReg() &&
 4232   assert(DstRegOp.isReg() && "expected register operand kind");
 4234   assert(SrcRegOp.isReg() && "expected register operand kind");
 4236   assert(OffsetImmOp.isImm() && "expected immediate operand kind");
 4284   assert(DstRegOp.isReg() && "expected register operand kind");
 4286   assert(SrcRegOp.isReg() && "expected register operand kind");
 4288   assert(OffsetImmOp.isImm() && "expected immediate operand kind");
 4335   assert(DstRegOp.isReg() && "expected register operand kind");
 4337   assert(SrcRegOp.isReg() && "expected register operand kind");
 4339   assert(OffsetImmOp.isImm() && "expected immediate operand kind");
 4387   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 4388   assert(Inst.getOperand(0).isReg() &&
 4421   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 4422   assert(Inst.getOperand(0).isReg() &&
 4477   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 4478   assert(Inst.getOperand(0).isReg() &&
 4525   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 4526   assert(Inst.getOperand(0).isReg() &&
 5063   assert(Inst.getOperand(2).isImm() &&
 5110   assert(Inst.getOperand(2).isImm() &&
 5133   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 5134   assert(Inst.getOperand(0).isReg() &&
 5159   assert(Inst.getNumOperands() == 3 && "Invalid operand count");
 5160   assert(Inst.getOperand(0).isReg() &&
 5515     assert(Inst.getOperand(2).isImm() && Inst.getOperand(3).isImm() &&
 5525     assert(Inst.getOperand(2).isImm() && Inst.getOperand(3).isImm() &&
 5534     assert(Inst.getOperand(2).isImm() && Inst.getOperand(3).isImm() &&
 5544     assert(Inst.getOperand(2).isImm() && Inst.getOperand(3).isImm() &&
 5793   assert(
 5863     assert(FixedName != "" &&  "Register name is not one of t4-t7.");
 6076     assert(Operands.size() == 1);
 6093   assert(Operands.size() == 0);
lib/Target/Mips/Disassembler/MipsDisassembler.cpp
  610   assert(NSize != 0 && RegDecoder != nullptr);
 1714     assert(false && "Unexpected instruction");
 2403   assert(Insn < 16);
lib/Target/Mips/MCTargetDesc/MipsABIInfo.cpp
   66   assert(Options.getABIName().empty() && "Unknown ABI option for MIPS");
lib/Target/Mips/MCTargetDesc/MipsAsmBackend.cpp
  235   assert(i <= 3 && "Index out of range!");
  508   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
lib/Target/Mips/MCTargetDesc/MipsELFObjectWriter.cpp
  488     assert(MatchingType != ELF::R_MIPS_NONE &&
  522   assert(Relocs.size() == Sorted.size() && "Some relocs were not consumed");
lib/Target/Mips/MCTargetDesc/MipsInstPrinter.cpp
   32   assert(MI.getOperand(OpNo).isReg() && "Register operand expected.");
  137   assert(Op.isExpr() && "unknown operand kind in printOperand");
lib/Target/Mips/MCTargetDesc/MipsMCCodeEmitter.cpp
   61   assert(Inst.getNumOperands() == 3 && "Invalid no. of operands for shift!");
   62   assert(Inst.getOperand(2).isImm());
  103     assert(Reg0 != Reg1 && "Instruction has bad operands ($rs == $rt)!");
  244   assert(MO.isExpr() &&
  266   assert(MO.isExpr() &&
  289   assert(MO.isExpr() &&
  312   assert(MO.isExpr() &&
  334   assert(MO.isExpr() &&
  355   assert(MO.isExpr() &&
  376   assert(MO.isExpr() &&
  398   assert(MO.isExpr() &&
  420   assert(MO.isExpr() &&
  442   assert(MO.isExpr() &&
  464   assert(MO.isExpr() &&
  485   assert(MO.isExpr() &&
  506   assert(MO.isExpr() &&
  523   assert(MO.isExpr() &&
  540     assert((Res & 3) == 0);
  544   assert(MO.isExpr() &&
  759   assert(MO.isExpr());
  770   assert(MI.getOperand(OpNo).isReg());
  785   assert(MI.getOperand(OpNo).isReg());
  799   assert(MI.getOperand(OpNo).isReg());
  813   assert(MI.getOperand(OpNo).isReg());
  827   assert(MI.getOperand(OpNo).isReg() &&
  842   assert(MI.getOperand(OpNo).isReg() &&
  857   assert(MI.getOperand(OpNo).isReg());
  870   assert(MI.getOperand(OpNo).isReg());
  894   assert(MI.getOperand(OpNo).isReg());
  906   assert(MI.getOperand(OpNo).isReg());
  932   assert(MI.getOperand(OpNo).isReg());
  934   assert(MI.getOperand(OpNo+1).isImm());
  946   assert(MI.getOperand(OpNo-1).isImm());
  947   assert(MI.getOperand(OpNo).isImm());
  959   assert(MI.getOperand(OpNo).isImm());
  973     assert((Res & 3) == 0);
  977   assert(MO.isExpr() &&
  995     assert((Res & 7) == 0);
  999   assert(MO.isExpr() &&
 1013   assert(MI.getOperand(OpNo).isImm());
 1022   assert(MI.getOperand(OpNo).isImm());
 1111   assert(((OpNo == 2) || (OpNo == 3)) &&
 1115   assert(Op.isReg() && "Operand of movep is not a register!");
 1135   assert(MO.isImm() && "getSimm23Lsl2Encoding expects only an immediate");
 1138   assert((Res & 3) == 0);
lib/Target/Mips/MCTargetDesc/MipsNaClELFStreamer.cpp
   62       assert(MI.getOperand(0).isReg());
   92       assert(MI.getOperand(0).isReg());
  137       assert((Mips::SP == SPReg) && "Unexpected stack-pointer register.");
lib/Target/Mips/MCTargetDesc/MipsOptionRecord.cpp
   66     assert((ri_gp_value & 0xffffffff) == ri_gp_value);
lib/Target/Mips/Mips16ISelLowering.cpp
  250     assert((I == 0 || HardFloatLibCalls[I - 1] < HardFloatLibCalls[I]) &&
  374   assert(stubNum <= maxStubNum);
  377   assert(validStubNum[stubNum]);
lib/Target/Mips/Mips16InstrInfo.cpp
   88   assert(Opc && "Cannot copy registers");
  122   assert(Opc && "Register class not handled!");
  141   assert(Opc && "Register class not handled!");
lib/Target/Mips/Mips16RegisterInfo.cpp
   71   assert(Size == 4);
lib/Target/Mips/MipsAnalyzeImmediate.cpp
  116     assert(S->size() <= 7);
lib/Target/Mips/MipsAsmPrinter.cpp
  623   assert(OpNum + 1 < MI->getNumOperands() && "Insufficient operands");
  626   assert(BaseMO.isReg() && "Unexpected base pointer for inline asm memory operand.");
  627   assert(OffsetMO.isImm() && "Unexpected offset for inline asm memory operand.");
 1074   assert(!isPositionIndependent() &&
lib/Target/Mips/MipsBranchExpansion.cpp
  264   assert(!FirstBr->isIndirectBranch() && "Unexpected indirect branch found.");
  346       assert(MO.isMBB() && "MBB operand expected.");
  358     assert(Br->isBundledWithSucc());
  712     assert(I.Br->getDesc().getNumOperands() == 1);
lib/Target/Mips/MipsCCState.cpp
   33   assert(std::is_sorted(std::begin(LibCalls), std::end(LibCalls), Comp));
  163     assert(Ins[i].getOrigArgIndex() < MF.getFunction().arg_size());
lib/Target/Mips/MipsCallLowering.cpp
   69     assert(Args[ArgsIndex].Regs.size() == 1 && "Can't handle multple regs yet");
lib/Target/Mips/MipsConstantIslandPass.cpp
  556     assert(Size >= 4 && "Too small constant pool entry");
  558     assert(isPowerOf2_32(Align) && "Invalid alignment");
  561     assert((Size % Align) == 0 && "CP Entry not multiple of 4 bytes!");
  623   assert(CPEMI.getOpcode() == Mips::CONSTPOOL_ENTRY);
  630   assert(CPI < MCP->getConstants().size() && "Invalid constant pool index.");
  777           assert(CPE && "Cannot find a corresponding CPEntry!");
  811     assert(I != MBB->end() && "Didn't find MI in its own basic block?");
 1030   assert(CPE && "Unexpected!");
 1285     assert(MI != UserMBB->end() && "Fell off end of block");
 1436   assert(!BBIsJumpedOver(CPEBB) && "How did this happen?");
lib/Target/Mips/MipsDelaySlotFiller.cpp
  336     assert(MF.getSubtarget().getRegisterInfo()->getAllocatableSet(MF).test(R) &&
  367   assert(MI.isCall());
  691     assert((!CurrI->isCall() && !CurrI->isReturn() && !CurrI->isBranch()) &&
  867     assert(((R != MipsInstrInfo::BT_Uncond) || (TrueBB == &Dst)));
  872   assert((TrueBB == &Dst) || (FalseBB == &Dst));
  911   assert(!Candidate.isKill() &&
lib/Target/Mips/MipsExpandPseudo.cpp
  593   assert((OldVal != Ptr) && "Clobbered the wrong ptr reg!");
  594   assert((OldVal != Incr) && "Clobbered the wrong reg!");
  598     assert(AND && NOR &&
  603     assert(OR && "Unknown instruction for atomic pseudo expansion!");
lib/Target/Mips/MipsFastISel.cpp
  110       assert(isRegBase() && "Invalid base register access!");
  115       assert(isRegBase() && "Invalid base register access!");
  120       assert(isFIBase() && "Invalid base frame index access!");
  125       assert(isFIBase() && "Invalid base frame index access!");
  338   assert(TLI.getValueType(DL, AI->getType(), true) == MVT::i32 &&
 1019   assert(isa<SelectInst>(I) && "Expected a select instruction.");
 1245       assert(VA.isMemLoc() && "Assuming store on stack.");
lib/Target/Mips/MipsISelDAGToDAG.cpp
  224   assert(Node->getOpcode() == ISD::ADD && "Should only get 'add' here.");
  227   assert(VT.isVector() && "Should only be called for vectors.");
  257   assert(NegC && "Constant-folding failed!");
  298     assert((Subtarget->systemSupportsUnalignedAccess() ||
lib/Target/Mips/MipsISelLowering.cpp
  636   assert((CC >= Mips::FCOND_T && CC <= Mips::FCOND_GT) &&
 1559   assert(Size < 32);
 1570   assert((Size == 1 || Size == 2) &&
 1724   assert((MI.getOpcode() == Mips::ATOMIC_CMP_SWAP_I32 ||
 1779   assert((Size == 1 || Size == 2) &&
 1908   assert(!Subtarget.hasMips32r6() && !Subtarget.hasMips64r6());
 1928   assert(!Subtarget.hasMips32r6() && !Subtarget.hasMips64r6());
 1940   assert(!Subtarget.hasMips32r6() && !Subtarget.hasMips64r6());
 1943   assert(Cond.getOpcode() == MipsISD::FPCmp &&
 2080     assert(model == TLSModel::LocalExec);
 2569   assert((VT == MVT::i32) || (VT == MVT::i64));
 2599   assert((VT == MVT::i64) && (ExtType == ISD::ZEXTLOAD));
 2650   assert(VT == MVT::i64);
 2883   assert((Reg == Mips::A0) || (Reg == Mips::A2));
 2949   assert(Mask && "Missing call preserved mask for calling convention");
 3139       assert(Flags.getByValSize() &&
 3141       assert(ByValIdx < CCInfo.getInRegsParamsCount());
 3142       assert(!IsTailCall &&
 3215     assert(VA.isMemLoc());
 3355     assert(VA.isRegLoc() && "Can only return in registers!");
 3507       assert(Ins[i].isOrigArg() && "Byval arguments cannot be implicit");
 3512       assert(Flags.getByValSize() &&
 3514       assert(ByValIdx < CCInfo.getInRegsParamsCount());
 3565       assert(VA.isMemLoc());
 3672     assert(VA.isRegLoc() && "Can only return in registers!");
 3933       assert(Reg % 2 == 0);
 3941     assert(Prefix == "$");
 3945   assert(Reg < RC->getNumRegs());
 4373   assert(Size && "Byval argument's size shouldn't be 0.");
 4389     assert(!(Align % RegSizeInBytes) &&
 4418   assert(!(Subtarget.hasMips4() || Subtarget.hasMips32()) &&
 4494   assert(!(Subtarget.hasMips4() || Subtarget.hasMips32()) &&
lib/Target/Mips/MipsInstrInfo.cpp
   82   assert(getAnalyzableBrOpc(Opc) && "Not an analyzable branch");
  113     assert((Cond[i].isImm() || Cond[i].isReg()) &&
  127   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  128   assert(!BytesAdded && "code size not handled");
  135   assert((Cond.size() <= 3) &&
  156   assert(!BytesRemoved && "code size not handled");
  184   assert( (Cond.size() && Cond.size() <= 3) &&
  683   assert(!MI.isBundle() &&
lib/Target/Mips/MipsInstructionSelector.cpp
  131   assert(Imm.getBitWidth() == 32 && "Unsupported immediate size.");
  209       assert(STI.hasMSA() && "Vector instructions require target with MSA.");
  314     assert(isPowerOf2_32(EntrySize) &&
  526     assert((ToSize == 32) && "Unsupported integer size for G_FPTOSI");
  527     assert((FromSize == 32 || FromSize == 64) &&
lib/Target/Mips/MipsLegalizerInfo.cpp
  302   assert(ST.hasMSA() && "MSA intrinsic not supported on target without MSA.");
  317   assert(ST.hasMSA() && "MSA intrinsic not supported on target without MSA.");
  329   assert(ST.hasMSA() && "MSA intrinsic not supported on target without MSA.");
lib/Target/Mips/MipsMCInstLower.cpp
  165     assert(Offset > 0);
lib/Target/Mips/MipsMachineFunction.cpp
  125   assert(ABI.IsO32());
lib/Target/Mips/MipsOptimizePICCall.cpp
  140   assert(TRI.legalclasstypes_end(*RC) - TRI.legalclasstypes_begin(*RC) == 1);
  283   assert(DefMI);
  296   assert(DefMI->hasOneMemOperand());
  309   assert(Reg);
lib/Target/Mips/MipsRegisterBankInfo.cpp
  173   assert(!MRI.getType(Reg).isPointer() &&
  188   assert(!MRI.getType(Reg).isPointer() &&
  222   assert(isAmbiguous(MI->getOpcode()) &&
  253   assert(isAmbiguous(MI->getOpcode()) && "Visiting non-Ambiguous opcode.\n");
  336   assert((Register::isPhysicalRegister(CopyInst->getOperand(Op).getReg())) &&
  372   assert(static_cast<const MipsSubtarget &>(MF.getSubtarget()).hasMSA() &&
  571     assert((Op0Size == 32) && "Unsupported integer size");
  578     assert((MRI.getType(MI.getOperand(1).getReg()).getSizeInBits() == 32) &&
  637     assert(MRI.getType(Dest) == LLT::scalar(32) && "Unexpected operand type.");
  642     assert(MRI.getType(Dest).isPointer() && "Unexpected operand type.");
lib/Target/Mips/MipsRegisterBankInfo.h
  145       assert(wasVisited(MI) && "Instruction was not visited!");
  151       assert(wasVisited(MI) && "Instruction was not visited!");
  158       assert(WaitingQueues.count(MI) && "Instruction was not visited!");
  165       assert(WaitingQueues.count(MI) && "Instruction was not visited!");
lib/Target/Mips/MipsSEFrameLowering.cpp
  171   assert(I->getOperand(0).isReg() && I->getOperand(1).isFI());
  186   assert(I->getOperand(0).isReg() && I->getOperand(1).isFI());
  204   assert(I->getOperand(0).isReg() && I->getOperand(1).isFI());
  229   assert(I->getOperand(0).isReg() && I->getOperand(1).isFI());
  314     assert(Subtarget.isGP64bit() || Subtarget.hasMTHC1() ||
  380     assert(Subtarget.isGP64bit() || Subtarget.hasMTHC1() ||
  542       assert(isInt<16>(MFI.getMaxAlignment()) &&
  655   assert(InsSize != 0 && "Unknown interrupt type!");
lib/Target/Mips/MipsSEISelDAGToDAG.cpp
  219   assert(Opc == ISD::ADDE && "ISD::ADDE not in a chain of ADDE nodes!");
 1049       assert(FILLOp != 0 && "Unknown FILL Op for splat synthesis!");
 1050       assert((!ABI.IsO32() || (FILLOp != Mips::FILL_D)) &&
 1076       assert((Hi || Lo) && "Zero case reached 32 bit case splat synthesis!");
lib/Target/Mips/MipsSEISelLowering.cpp
  254     assert(Subtarget.isFP64bit() && "FR=1 is required for MIPS32r6");
  699     assert(Cond.getNode() && IfSet.getNode());
 1266   assert(!Subtarget.hasMips32r6());
 1323   assert(Op->getOperand(OpNo).getOpcode() == ISD::TargetConstant);
 1355   assert(Val->getValueType(1) == MVT::Other);
 2520     assert(ResTy.isVector());
 2637   assert((Indices.size() % 2) == 0);
 2669   assert((Indices.size() % 2) == 0);
 2715   assert((Indices.size() % 2) == 0);
 2762   assert((Indices.size() % 2) == 0);
 2809   assert((Indices.size() % 2) == 0);
 2857   assert((Indices.size() % 2) == 0);
 2900   assert((Indices.size() % 2) == 0);
 3215   assert(Subtarget.isFP64bit());
 3280   assert(Subtarget.isFP64bit());
 3475   assert(Subtarget.isFP64bit());
 3656   assert(Subtarget.hasMSA() && Subtarget.hasMips32r2());
 3761   assert(Subtarget.hasMSA() && Subtarget.hasMips32r2());
lib/Target/Mips/MipsSEInstrInfo.cpp
  172   assert(Opc && "Cannot copy registers");
  318   assert(Opc && "Register class not handled!");
  377   assert(Opc && "Register class not handled!");
  626   assert(Seq.size() && (!LastInstrIsADDiu || (Seq.size() > 1)));
  704   assert(Desc.NumOperands == 2 && "Unary instruction expected.");
  781   assert(N < 2 && "Invalid immediate");
  787   assert(!(Subtarget.isABI_FPXX() && !Subtarget.hasMips32r2()));
  791   assert(!(Subtarget.isFP64bit() && !Subtarget.useOddSPReg()));
  841   assert(!(Subtarget.isABI_FPXX() && !Subtarget.hasMips32r2()));
  845   assert(!(Subtarget.isFP64bit() && !Subtarget.useOddSPReg()));
lib/Target/Mips/MipsSERegisterInfo.cpp
   58   assert(Size == 8);
lib/Target/Mips/MipsSubtarget.cpp
  101   assert(((!isGP64bit() && isABI_O32()) ||
  144     assert(isFP64bit());
  145     assert(isNaN2008());
  146     assert(inAbs2008Mode());
  254     assert(isABI_O32() && "Unknown ABI for stack alignment!");
lib/Target/Mips/MipsTargetStreamer.h
  182     assert(ABI.hasValue() && "ABI hasn't been set!");
lib/Target/NVPTX/MCTargetDesc/NVPTXInstPrinter.cpp
   92     assert(Op.isExpr() && "Unknown operand kind in printOperand");
  305   assert(Op.isExpr() && "Call prototype is not an MCExpr?");
lib/Target/NVPTX/MCTargetDesc/NVPTXTargetStreamer.cpp
   87   assert(!SubSection && "SubSection is not null!");
lib/Target/NVPTX/NVPTXAsmPrinter.cpp
  351         assert(Ty->isFloatingPointTy() && "Floating point type expected here");
  585   assert(I != VRegMapping.end() && "Bad register class");
  589   assert(VI != RegMap.end() && "Bad virtual register");
  831   assert(GVVisited.size() == M.getGlobalList().size() &&
  833   assert(GVVisiting.size() == 0 && "Did not fully process a global variable");
 1554     assert(PTy && "Param with byval attribute should be a pointer type");
lib/Target/NVPTX/NVPTXAsmPrinter.h
  110       assert((curpos + Num) <= size);
  111       assert((curpos + Bytes) <= size);
  124       assert((curpos + Num) <= size);
lib/Target/NVPTX/NVPTXFrameLowering.cpp
   35     assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
lib/Target/NVPTX/NVPTXGenericToNVVM.cpp
  151   assert(GVMap.empty() && "Expected it to be empty by now");
lib/Target/NVPTX/NVPTXISelDAGToDAG.cpp
  742   assert(SrcAddrSpace != DstAddrSpace &&
  841   assert(LD->readMem() && "Expected load");
  894     assert(LoadedVT == MVT::v2f16 && "Unexpected vector type");
 1065     assert(N->getOpcode() == NVPTXISD::LoadV4 && "Unexpected load opcode.");
 1274       assert(NumElts % 2 == 0 && "Vector must have even number of elements");
 1706   assert(ST->writeMem() && "Expected store");
 1709   assert((PlainStore || AtomicStore) && "Expected store");
 1752     assert(StoreVT == MVT::v2f16 && "Unexpected vector type");
 1900   assert(StoreVT.isSimple() && "Store value is not simple");
 1937     assert(N->getOpcode() == NVPTXISD::StoreV4 && "Unexpected load opcode.");
lib/Target/NVPTX/NVPTXISelLowering.cpp
  236   assert(isPowerOf2_32(AccessSize) && "must be a power of 2!");
  308     assert(VectorInfo[I] == PVF_SCALAR && "Unexpected vector info state.");
  320         assert(I + 1 < E && "Not enough elements.");
  326         assert(I + 3 < E && "Not enough elements.");
 1265   assert(isABI && "Non-ABI compilation is not supported");
 1281         assert(retTy->isFloatingPointTy() &&
 1334       assert((getValueType(DL, Ty) == Outs[OIdx].VT ||
 1357     assert(PTy && "Param with byval attribute should be a pointer type");
 1386     assert(CalleeI && "Call target is not a function or derived value?");
 1438   assert(isABI && "Non-ABI compilation is not supported");
 1511           assert(StoreOperands.empty() && "Unfinished preceding store.");
 1520           assert(VTs.size() == 1 && "Scalar can't have multiple parts.");
 1570       assert(StoreOperands.empty() && "Unfinished parameter store.");
 1581     assert(PTy && "Type of a byval parameter should be pointer");
 1681     assert(CalleeFunc != nullptr && "Libcall callee must be set.");
 1768     assert(VTs.size() == Ins.size() && "Bad value decomposition");
 1799         assert(VecIdx == -1 && LoadVTs.empty() && "Orphaned operand list.");
 1944   assert(VectorVT == MVT::v2f16 && "Unexpected vector type.");
 1963   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 1964   assert(Op.getOpcode() == ISD::SRA_PARTS || Op.getOpcode() == ISD::SRL_PARTS);
 2024   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
 2025   assert(Op.getOpcode() == ISD::SHL_PARTS);
 2214   assert(Op.getValueType() == MVT::i1 && "Custom lowering enabled only for i1");
 2252   assert(LD->getExtensionType() == ISD::NON_EXTLOAD);
 2253   assert(Node->getValueType(0) == MVT::i1 &&
 2359       assert(EltVT == MVT::f16 && "Wrong type for the vector.");
 2417   assert(Tmp3.getValueType() == MVT::i1 && "Custom lowering for i1 store only");
 2478   assert(isABI && "Non-ABI compilation is not supported");
 2510       assert(isKernelFunction(*F) &&
 2522         assert(vtparts.size() > 0 && "empty aggregate type not expected");
 2559       assert(VTs.size() > 0 && "Unexpected empty type.");
 2567           assert(VecIdx == -1 && "Orphaned vector.");
 2636     assert(ObjectVT == Ins[InsIdx].VT &&
 2669   assert(isABI && "Non-ABI compilation is not supported");
 2677   assert(VTs.size() == OutVals.size() && "Bad return value decomposition");
 2692       assert(StoreOperands.empty() && "Orphaned operand list.");
 4355     assert (VT.isInteger());
 4542   assert(N->getOpcode() == ISD::SREM || N->getOpcode() == ISD::UREM);
 4784   assert(ResVT.isVector() && "Vector load must have vector type");
 4789   assert(ResVT.isSimple() && "Can only handle simple types");
 4858     assert(EltVT == MVT::f16 && "Unsupported v8 vector type.");
 5022       assert(ResVT.isSimple() && ResVT.getSimpleVT().SimpleTy == MVT::i8 &&
lib/Target/NVPTX/NVPTXInstrInfo.cpp
  156   assert(!BytesRemoved && "code size not handled");
  186   assert(!BytesAdded && "code size not handled");
  189   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  190   assert((Cond.size() == 1 || Cond.size() == 0) &&
lib/Target/NVPTX/NVPTXLowerArgs.cpp
  159   assert(PType && "Expecting pointer type in handleByValParam");
  190     assert(InsertPt != InsertPt->getParent()->end() &&
lib/Target/NVPTX/NVPTXMachineFunctionInfo.h
   44     assert(ImageHandleList.size() > Idx && "Bad index");
lib/Target/NVPTX/NVPTXPrologEpilogPass.cpp
   68           assert(i == 0 && "Frame indices can only appear as the first "
  146   assert(LocalAreaOffset >= 0
lib/Target/NVPTX/NVPTXProxyRegErasure.cpp
   99   assert(InOp.isReg() && "ProxyReg input operand should be a register.");
  100   assert(OutOp.isReg() && "ProxyReg output operand should be a register.");
lib/Target/NVPTX/NVPTXRegisterInfo.cpp
  115   assert(SPAdj == 0 && "Unexpected");
lib/Target/NVPTX/NVPTXReplaceImageHandles.cpp
  137   assert(Op.isReg() && "Handle is not in a reg?");
  153     assert(TexHandleDef.getOperand(6).isSymbol() && "Load is not a symbol!");
  157     assert(Sym.startswith(ParamBaseName) && "Invalid symbol reference");
  169     assert(TexHandleDef.getOperand(1).isGlobal() && "Load is not a global!");
  171     assert(GV->hasName() && "Global sampler must be named!");
lib/Target/NVPTX/NVPTXUtilities.cpp
   48   assert(md && "Invalid mdnode for annotation");
   49   assert((md->getNumOperands() % 2) == 1 && "Invalid number of operands");
   55     assert(prop && "Annotation property not a string");
   59     assert(Val && "Value operand not a constant int");
  137       assert((annot == 1) && "Unexpected annotation on a texture symbol");
  148       assert((annot == 1) && "Unexpected annotation on a surface symbol");
  161       assert((annot == 1) && "Unexpected annotation on a sampler symbol");
  220       assert((annot == 1) && "Unexpected annotation on a managed symbol");
  228   assert(val.hasName() && "Found texture variable with no name");
  233   assert(val.hasName() && "Found surface variable with no name");
  238   assert(val.hasName() && "Found sampler variable with no name");
lib/Target/NVPTX/NVVMReflect.cpp
   80     assert(F.isDeclaration() && "_reflect function should not have a body");
   81     assert(F.getReturnType()->isIntegerTy() &&
  124     assert(Call->getNumOperands() == 2 &&
  134     assert(isa<ConstantExpr>(Str) &&
  139     assert(isa<Constant>(Sym) &&
  146       assert(GV->hasInitializer() &&
  152     assert(isa<ConstantDataSequential>(Operand) &&
  154     assert(cast<ConstantDataSequential>(Operand)->isCString() &&
lib/Target/PowerPC/AsmParser/PPCAsmParser.cpp
  250     assert(Kind == Immediate && "Invalid access!");
  254     assert((Kind == Immediate || Kind == ContextImmediate) &&
  261     assert((Kind == Immediate || Kind == ContextImmediate) &&
  267     assert(Kind == Expression && "Invalid access!");
  272     assert(Kind == Expression && "Invalid access!");
  277     assert(Kind == TLSRegister && "Invalid access!");
  282     assert(isRegNumber() && "Invalid access!");
  287     assert(isVSRegNumber() && "Invalid access!");
  292     assert(isCCRegNumber() && "Invalid access!");
  297     assert(isCRBitNumber() && "Invalid access!");
  302     assert(isCRBitMask() && "Invalid access!");
  414     assert(N == 1 && "Invalid number of operands!");
  419     assert(N == 1 && "Invalid number of operands!");
  424     assert(N == 1 && "Invalid number of operands!");
  429     assert(N == 1 && "Invalid number of operands!");
  448     assert(N == 1 && "Invalid number of operands!");
  453     assert(N == 1 && "Invalid number of operands!");
  458     assert(N == 1 && "Invalid number of operands!");
  463     assert(N == 1 && "Invalid number of operands!");
  468     assert(N == 1 && "Invalid number of operands!");
  473     assert(N == 1 && "Invalid number of operands!");
  478     assert(N == 1 && "Invalid number of operands!");
  483     assert(N == 1 && "Invalid number of operands!");
  488     assert(N == 1 && "Invalid number of operands!");
  493     assert(N == 1 && "Invalid number of operands!");
  498     assert(N == 1 && "Invalid number of operands!");
  503     assert(N == 1 && "Invalid number of operands!");
  508     assert(N == 1 && "Invalid number of operands!");
  513     assert(N == 1 && "Invalid number of operands!");
  518     assert(N == 1 && "Invalid number of operands!");
  523     assert(N == 1 && "Invalid number of operands!");
  531     assert(N == 1 && "Invalid number of operands!");
  546     assert(N == 1 && "Invalid number of operands!");
  561     assert(N == 1 && "Invalid number of operands!");
  569     assert(N == 1 && "Invalid number of operands!");
  574     assert(Kind == Token && "Invalid access!");
 1100       assert(Inst.getNumOperands() == 2 && "Expecting two operands");
 1656       assert(Size <= 8 && "Invalid size");
lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
   78   assert(RegNo < N && "Invalid register number");
  182   assert(isUInt<N>(Imm) && "Invalid immediate");
  190   assert(isUInt<N>(Imm) && "Invalid immediate");
  203   assert(Base < 32 && "Invalid base register");
  238   assert(Base < 32 && "Invalid base register");
  259   assert(Base < 32 && "Invalid base register");
  274   assert(Base < 32 && "Invalid base register");
  289   assert(Base < 32 && "Invalid base register");
  304   assert(Base < 32 && "Invalid base register");
  316   assert(Zeros < 8 && "Invalid CR bit value");
lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp
  115     assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
lib/Target/PowerPC/MCTargetDesc/PPCInstPrinter.cpp
   76     assert((MI->getOperand(0).isReg() && MI->getOperand(1).isReg()) &&
   80     assert(isa<MCSymbolRefExpr>(MI->getOperand(2).getExpr()) &&
  293   assert(StringRef(Modifier) == "reg" &&
  310   assert(Value <= 1 && "Invalid u1imm argument!");
  317   assert(Value <= 3 && "Invalid u2imm argument!");
  324   assert(Value <= 8 && "Invalid u3imm argument!");
  331   assert(Value <= 15 && "Invalid u4imm argument!");
  345   assert(Value <= 31 && "Invalid u5imm argument!");
  352   assert(Value <= 63 && "Invalid u6imm argument!");
  359   assert(Value <= 127 && "Invalid u7imm argument!");
  375   assert(Value <= 1023 && "Invalid u10imm argument!");
  382   assert(Value <= 4095 && "Invalid u12imm argument!");
  565   assert(Op.isExpr() && "unknown operand kind in printOperand");
lib/Target/PowerPC/MCTargetDesc/PPCMCAsmInfo.cpp
   87   assert(!IsLittleEndian && "Little-endian XCOFF not supported.");
lib/Target/PowerPC/MCTargetDesc/PPCMCCodeEmitter.cpp
  110   assert(MI.getOperand(OpNo+1).isReg());
  128   assert(MI.getOperand(OpNo+1).isReg());
  146   assert(MI.getOperand(OpNo+1).isReg());
  151     assert(!(MO.getImm() % 16) &&
  168   assert(MI.getOperand(OpNo+1).isReg());
  172   assert(MO.isImm());
  183   assert(MI.getOperand(OpNo+1).isReg());
  187   assert(MO.isImm());
  198   assert(MI.getOperand(OpNo+1).isReg());
  202   assert(MO.isImm());
  240   assert((MI.getOpcode() == PPC::MTOCRF || MI.getOpcode() == PPC::MTOCRF8 ||
  267     assert((MI.getOpcode() != PPC::MTOCRF && MI.getOpcode() != PPC::MTOCRF8 &&
  277   assert(MO.isImm() &&
lib/Target/PowerPC/PPCAsmPrinter.cpp
  325       assert(MI->getOperand(OpNo).isReg());
  331   assert(MI->getOperand(OpNo).isReg());
  356   assert(NumNOPBytes % 4 == 0 && "Invalid number of NOP bytes requested!");
  389       assert((CallTarget & 0xFFFFFFFFFFFF) == CallTarget &&
  467   assert(NumBytes >= EncodedBytes &&
  469   assert((NumBytes - EncodedBytes) % 4 == 0 &&
  484   assert(MI->getOperand(0).isReg() &&
  488   assert(MI->getOperand(1).isReg() &&
  678     assert(!IsDarwin && "TOC is an ELF/XCOFF construct.");
  687     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() || MO.isBlockAddress()) &&
  715       assert(
  736     assert(!IsDarwin && "TOC is an ELF/XCOFF construct");
  745     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() || MO.isBlockAddress()) &&
  763     assert((IsAIX && !IsPPC64 && TM.getCodeModel() == CodeModel::Large) &&
  774     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() || MO.isBlockAddress()) &&
  793     assert(IsAIX && !IsPPC64 && TM.getCodeModel() == CodeModel::Large &&
  804     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() || MO.isBlockAddress()) &&
  823     assert(!IsDarwin && "TOC is an ELF/XCOFF construct");
  835     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() || MO.isBlockAddress()) &&
  863     assert(!IsDarwin && "TOC is an ELF/XCOFF construct");
  875     assert((MO.isGlobal() || MO.isCPI() || MO.isJTI() ||
  879     LLVM_DEBUG(assert(
  907     assert((MO.isGlobal() || MO.isCPI()) && "Invalid operand for ADDItocL.");
  909     LLVM_DEBUG(assert(
  923     assert(IsPPC64 && "Not supported for 32-bit PowerPC");
 1002     assert(IsPPC64 && "Not supported for 32-bit PowerPC");
 1047     assert(IsPPC64 && "Not supported for 32-bit PowerPC");
 1624   assert(Directive <= PPC::DIR_64 && "Directive out of range.");
 1626   assert(Directive < array_lengthof(CPUDirectives) &&
lib/Target/PowerPC/PPCBoolRetToInt.cpp
  111     assert((A || I) && "Unknown value type");
  254       assert((!First || Second) && "translated from user to non-user!?");
lib/Target/PowerPC/PPCBranchCoalescing.cpp
  289   assert(Cand.BranchBlock->canFallThrough() &&
  300   assert(Succ && "Expecting a valid fall-through block\n");
  693   assert(TargetRegion.FallThroughBlock->empty() &&
  703   assert(SourceRegion.BranchBlock->empty() &&
  707   assert(SourceRegion.FallThroughBlock->empty() &&
  751       assert(MPDT->dominates(Cand2.BranchTargetBlock, Cand1.BranchBlock) &&
lib/Target/PowerPC/PPCCallingConv.cpp
  129   assert(T == LoRegList[i] && "Could not allocate register");
lib/Target/PowerPC/PPCExpandISEL.cpp
  204       assert(isISEL(**I) && "Expecting an ISEL instruction");
  269     assert(isISEL(**MI) && "Expecting an ISEL instruction");
  332   assert((IsTrueBlockRequired || IsFalseBlockRequired) &&
  437     assert(isISEL(*MI) && "Expecting an ISEL instruction");
lib/Target/PowerPC/PPCFastISel.cpp
  447     assert(IndexReg && "Unexpected error in PPCMaterializeInt!");
  496       assert(UseRC->hasSuperClassEq(&PPC::G8RCRegClass) &&
  625   assert(SrcReg && "Nothing to store!");
  642       assert(Is32BitInt && "Not GPRC for i32??");
 1506     assert(RVLocs.size() == 1 && "No support for multi-reg return values!");
 1507     assert(VA.isRegLoc() && "Can only return in registers!");
 1540     assert(ResultReg && "ResultReg unset!");
 1743         assert(VA.isRegLoc() && "Can only return in registers!");
 1819       assert(DestVT == MVT::i64 && "Signed extend from i32 to i32??");
 1831       assert(SrcVT == MVT::i16 && "Unsigned extend from i32 to i32??");
 2000   assert(Align > 0 && "Unexpectedly missing alignment information!");
 2059   assert(VT == MVT::i64 && "Non-address!");
lib/Target/PowerPC/PPCFrameLowering.cpp
  300   assert(MBBI != Entry->end() && MBBI->getOpcode() == PPC::MTVRSAVE);
  326     assert(MBBI != Entry->begin() && "UPDATE_VRSAVE is first instr in block?");
  328     assert(MBBI->getOpcode() == PPC::MFVRSAVE && "VRSAVE instrs wandered?");
  627     assert (SR1 && "Asking for the second scratch register but not the first?");
  794   assert((Subtarget.isDarwinABI() || isSVR4ABI || isAIXABI) &&
  863   assert((isPPC64 || !isSVR4ABI || !(!FrameSize && (MustSaveLR || HasFP))) &&
  870   assert(SingleScratchReg &&
  882       assert(FPIndex && "No Frame Pointer Save Slot!");
  894       assert(BPIndex && "No Base Pointer Save Slot!");
  905     assert(PBPIndex && "No PIC Base Pointer Save Slot!");
  912     assert(isPowerOf2_32(MaxAlign) && isInt<16>(MaxAlign) &&
  919   assert((isPPC64 || !MustSaveCR) &&
 1034     assert(HasRedZone && "A red zone is always available on PPC64");
 1077       assert(!SingleScratchReg && "Only a single scratch reg available");
 1116     assert(isELFv2ABI && "TOC saves in the prologue only supported on ELFv2");
 1124     assert(!isPPC64 && "A red zone is always available on PPC64");
 1249       assert(NegFrameSize);
 1430   assert(SingleScratchReg &&
 1438       assert(FPIndex && "No Frame Pointer Save Slot!");
 1449       assert(BPIndex && "No Base Pointer Save Slot!");
 1459     assert(PBPIndex && "No PIC Base Pointer Save Slot!");
 1477       assert(StackAdjust.isImm() && "Expecting immediate value.");
 1481       assert((Delta >= 0) && "Delta must be positive");
 1544       assert(HasFP && "Expecting a valid frame pointer.");
 1569         assert(FPOffset <= 0 && BPOffset <= 0 && PBPOffset <= 0 &&
 1592   assert(RBReg != ScratchReg && "Should have avoided ScratchReg");
 1597   assert((isPPC64 || !MustSaveCR) &&
 1605     assert(HasRedZone && "Expecting red zone");
 1628     assert(isPPC64 && "Expecting 64-bit mode");
 1629     assert(RBReg == SPReg && "Should be using SP as a base register");
 1661     assert(!HasRedZone && "This should not happen with red zone");
 1672     assert(RBReg != ScratchReg && "Should be using FP or SP as base register");
 1728   assert(MBBI != MBB.end() && "Failed to find the first terminator.");
 1742     assert(MBBI->getOperand(0).isReg() && "Expecting register operand.");
 1755     assert(MBBI->getOperand(0).isReg() && "Expecting register operand.");
 1886     assert((!MF.getInfo<PPCFunctionInfo>()->mustSaveTOC() ||
 1962     assert(FI && "No Frame Pointer Save Slot!");
 1970     assert(FI && "No PIC Base Pointer Save Slot!");
 1980     assert(FI && "No Base Pointer Save Slot!");
 2074     assert(LowerBound <= 0 && "Expect LowerBound have a non-positive value!");
 2420         assert(I != MBB.begin() &&
lib/Target/PowerPC/PPCHazardRecognizers.cpp
  326   assert(Stalls == 0 && "PPC hazards don't support scoreboard lookahead");
  424   assert(NumIssued < 5 && "Illegal dispatch group!");
lib/Target/PowerPC/PPCISelDAGToDAG.cpp
  517   assert(isa<BasicBlockSDNode>(DestMBB));
 1137       assert(hasValue() && "Cannot get the value of a constant bit");
 1142       assert(hasValue() && "Cannot get the value bit index of a constant bit");
 1655           assert(std::next(I) == BitGroups.end() &&
 1725     assert(V.getValueSizeInBits() == 32);
 1739     assert(V.getValueSizeInBits() == 64);
 1765       assert((ANDIMask != 0 || ANDISMask != 0) &&
 1898       assert((ANDIMask != 0 || ANDISMask != 0) &&
 1959       assert(InstMaskStart >= 32 && "Mask cannot start out of range");
 1960       assert(InstMaskEnd   >= 32 && "Mask cannot end out of range");
 2023       assert(InstMaskStart >= 32 && "Mask cannot start out of range");
 2024       assert(InstMaskEnd   >= 32 && "Mask cannot end out of range");
 2179         assert((ANDIMask != 0 || ANDISMask != 0) &&
 2324         assert((ANDIMask != 0 || ANDISMask != 0) &&
 2375       assert(Bits.size() == 64 && "Not 64 bits here?");
 2497     assert(CurDAG->getTargetLoweringInfo()
 2531   assert((N->getOpcode() == ISD::ZERO_EXTEND ||
 2573   assert(isLogicOp(N->getOpcode()) &&
 2611     assert(LoweredLogical.getConstantOperandVal(1) == 1 &&
 2623     assert((NewOpc != -1 || !IsBitwiseNegate) &&
 2652   assert(isLogicOp(LogicOp.getOpcode()) &&
 2654   assert(LogicOp.getValueType() == MVT::i1 &&
 2720   assert(Input.getValueType() == MVT::i32 &&
 2753   assert(Input.getValueType() == MVT::i32 &&
 2802   assert(Conv == ExtOrTruncConversion::Trunc &&
 2861   assert(Is32Bit && "Should have handled the 32-bit sequences above.");
 3553   assert(Compare.getOpcode() == ISD::SETCC &&
 3578   assert((Compare.getOpcode() == ISD::SETCC ||
 3828     assert(LHS.getValueType() == MVT::f128 && "Unknown vt!");
 3829     assert(PPCSubTarget->hasVSX() && "__float128 requires VSX");
 4210   assert(N->getOpcode() == ISD::SELECT_CC && "Expecting a SELECT_CC here.");
 4220   assert((N->getSimpleValueType(0) == MVT::i64 ||
 4451       assert(N->getValueType(0) == MVT::i32 &&
 4493         assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
 4504         assert(LD->getValueType(0) == MVT::i64 && "Unknown load result type!");
 4505         assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
 4530         assert((!isSExt || LoadedVT == MVT::i16) && "Invalid sext update load");
 4543         assert(LD->getValueType(0) == MVT::i64 && "Unknown load result type!");
 4544         assert((!isSExt || LoadedVT == MVT::i16 || LoadedVT == MVT::i32) &&
 4624         assert(Imm < 64 && "Illegal shift amount");
 4790     assert((InVT == MVT::i64 || InVT == MVT::i32) &&
 5072     assert(!PPCSubTarget->isDarwin() && "TOC is an ELF/XCOFF construct");
 5076     assert(!(CModel == CodeModel::Tiny || CModel == CodeModel::Kernel) &&
 5100         assert(TM.isPositionIndependent() &&
 5114     assert(CModel != CodeModel::Small && "All small code models handled.");
 5116     assert((isPPC64 || (isAIXABI && !isPPC64)) && "We are dealing with 64-bit"
 5155     assert(PPCSubTarget->is32BitELFABI() &&
 5165     assert(isa<ConstantSDNode>(N->getOperand(0)) &&
 5185       assert(EltSize == 4 && "Invalid element size on VADD_SPLAT!");
 5248   assert(N->getOpcode() == ISD::OR &&
 5611     assert((User->getMachineOpcode() == PPC::SELECT_I4 ||
lib/Target/PowerPC/PPCISelLowering.cpp
 1435   assert(VT.isFloatingPoint() && "Non-floating-point FMA?");
 1584   assert((UnitSize == 1 || UnitSize == 2 || UnitSize == 4) &&
 1793   assert(N->getValueType(0) == MVT::v16i8 && isPowerOf2_32(EltSize) &&
 1835   assert((Width == 2 || Width == 4 || Width == 8 || Width == 16) &&
 1837   assert((StepLen == 1 || StepLen == -1) && "Unexpected element width.");
 1937   assert(N->getValueType(0) == MVT::v16i8 && "Shuffle vector expects v16i8");
 1951     assert(M0 < 4 && "Indexing into an undef vector?");
 1998   assert(N->getValueType(0) == MVT::v16i8 && "Shuffle vector expects v16i8");
 2036   assert(N->getValueType(0) == MVT::v16i8 && "Shuffle vector expects v16i8");
 2044   assert(((M0 | M1) < 4) && "A mask element out of bounds?");
 2093   assert(isSplatShuffleMask(SVOp, EltSize));
 2115     assert(Multiple > 1 && Multiple <= 4 && "How can this happen?");
 2178     assert(CN->getValueType(0) == MVT::f32 && "Only one legal FP vector type!");
 2392       assert(!cast<ConstantSDNode>(N.getOperand(1).getOperand(1))->getZExtValue()
 2395       assert(Disp.getOpcode() == ISD::TargetGlobalAddress ||
 3038   assert(!Subtarget.isPPC64() && "LowerVAARG is PPC32 only");
 3129   assert(!Subtarget.isPPC64() && "LowerVACOPY is PPC32 only");
 3533         assert(i + 1 < e && "No second half of double precision argument");
 3553       assert(VA.isMemLoc());
 3702   assert(!(CallConv == CallingConv::Fast && isVarArg) &&
 3792       assert(Ins[ArgNo].isOrigArg() && "Byval arguments cannot be implicit");
 4013       assert(ObjectVT.getSimpleVT().SimpleTy == MVT::v4f32 &&
 4233       assert(Ins[ArgNo].isOrigArg() && "Byval arguments cannot be implicit");
 4545   assert(Subtarget.is64BitELFABI());
 5169     assert(VA.isRegLoc() && "Can only return in registers!");
 5245   assert(Mask && "Missing call preserved mask for calling convention");
 5253     assert(((Callee.getOpcode() == ISD::Register &&
 5366       assert(isa<GlobalAddressSDNode>(Callee) &&
 5422   assert((CallConv == CallingConv::C ||
 5540       assert((j < ByValArgLocs.size()) && "Index out of bounds!");
 5542       assert((VA.getValNo() == ByValVA.getValNo()) && "ValNo mismatch!");
 5595       assert(VA.isMemLoc());
 5695   assert(!(CallConv == CallingConv::Fast && isVarArg) &&
 6047         assert(HasParameterArea &&
 6134         assert(HasParameterArea &&
 6171         assert(HasParameterArea &&
 6205         assert(HasParameterArea &&
 6219       assert(Arg.getValueType().getSimpleVT().SimpleTy == MVT::v4f32 &&
 6227         assert(HasParameterArea &&
 6261         assert(HasParameterArea &&
 6277   assert((!HasParameterArea || NumBytesActuallyUsed == ArgOffset) &&
 6741     assert(IsPPC64 && "PPC32 should have split i64 values.");
 6790   assert((CallConv == CallingConv::C ||
 6906     assert(VA.isRegLoc() && "Can only return in registers!");
 7110   assert(Op.getValueType() == MVT::i1 &&
 7135   assert(Op.getOperand(1).getValueType() == MVT::i1 &&
 7155   assert(Op.getValueType() == MVT::i1 &&
 7185   assert(Op.getValueType().isVector() && "Vector type expected.");
 7190   assert(SrcSize <= 128 && "Source must fit in an Altivec/VSX vector");
 7348   assert(Op.getOperand(0).getValueType().isFloatingPoint());
 7364     assert((Op.getOpcode() == ISD::FP_TO_SINT || Subtarget.hasFPCVT()) &&
 7411   assert(Op.getOperand(0).getValueType().isFloatingPoint());
 7429     assert((Op.getOpcode() == ISD::FP_TO_SINT || Subtarget.hasFPCVT()) &&
 7529     assert(LD->getAddressingMode() == ISD::PRE_INC &&
 7561   assert(TF.getNode() != NewResChain.getNode() &&
 7604   assert((Op.getValueType() == MVT::f32 ||
 7607   assert(Subtarget.hasFPCVT() &&
 7633   assert(VecVT.isVector() && "Expected a vector type.");
 7634   assert(VecVT.getSizeInBits() < 128 && "Vector is already full width.");
 7654   assert((Opc == ISD::UINT_TO_FP || Opc == ISD::SINT_TO_FP) &&
 7656   assert((Op.getValueType() == MVT::v2f64 || Op.getValueType() == MVT::v4f32) &&
 7747   assert((Op.getOpcode() == ISD::SINT_TO_FP || Subtarget.hasFPCVT()) &&
 7853       assert(cast<StoreSDNode>(Store)->getMemoryVT() == MVT::i32 &&
 7881   assert(Op.getOperand(0).getValueType() == MVT::i32 &&
 7905       assert(cast<StoreSDNode>(Store)->getMemoryVT() == MVT::i32 &&
 7926     assert(Subtarget.isPPC64() &&
 8021   assert(Op.getNumOperands() == 3 &&
 8050   assert(Op.getNumOperands() == 3 &&
 8079   assert(Op.getNumOperands() == 3 &&
 8112   assert(Val >= -16 && Val <= 15 && "vsplti is out of range!");
 8265   assert(BVN && "Expected a BuildVectorSDNode in LowerBUILD_VECTOR");
 8278     assert(BVN->getNumOperands() == 4 &&
 8610     assert(LHSID == ((4*9+5)*9+6)*9+7 && "Illegal OP_COPY!");
 9527     assert(ArgStart == 1 && "llvm.ppc.cfence must carry a chain argument.");
 9528     assert(Subtarget.isPPC64() && "Only 64-bit is supported for now.");
 9574   assert(Op.getOpcode() == ISD::ATOMIC_CMP_SWAP &&
 9624   assert(Op.getOpcode() == ISD::INSERT_VECTOR_ELT &&
 9656   assert(N->getOperand(0).getValueType() == MVT::v4i1 &&
 9747         assert(LN->getAddressingMode() == ISD::PRE_INC &&
 9773   assert(Op.getValueType() == MVT::v4i1 && "Unknown load to lower");
 9774   assert(LN->isUnindexed() && "Indexed v4i1 loads are not supported");
 9839         assert(SN->getAddressingMode() == ISD::PRE_INC &&
 9861   assert(SN->isUnindexed() && "Indexed v4i1 stores are not supported");
 9862   assert(Value.getValueType() == MVT::v4i1 && "Unknown store to lower");
 9998   assert(Op.getOpcode() == ISD::ABS && "Should only be called for ISD::ABS");
10001   assert(VT.isVector() &&
10003   assert((VT == MVT::v2i64 || VT == MVT::v4i32 || VT == MVT::v8i16 ||
10006   assert((VT != MVT::v2i64 || Subtarget.hasP8Altivec()) &&
10037   assert(Op.getOpcode() == ISD::FP_EXTEND &&
10052     assert(Op0.getNumOperands() == 2 &&
10207     assert(N->getValueType(0) == MVT::i1 &&
10314     assert(Subtarget.hasPartwordAtomics() && "Call this only with size >=4");
10319     assert(Subtarget.hasPartwordAtomics() && "Call this only with size >=4");
10624   assert(TRI->isTypeLegalForClass(*RC, MVT::i32) && "Invalid destination!");
10629   assert((PVT == MVT::i64 || PVT == MVT::i32) &&
10761   assert((PVT == MVT::i64 || PVT == MVT::i32) &&
11158       assert(Subtarget.hasPartwordAtomics() && "No support partword atomics.");
11163       assert(Subtarget.hasPartwordAtomics() && "No support partword atomics.");
11532           assert((RegInfo.getRegClass(DestReg) == &PPC::G8RCRegClass) &&
11539           assert((RegInfo.getRegClass(SrcReg) == &PPC::G8RCRegClass) &&
11943   assert(N->getOpcode() == ISD::SETCC && "ISD::SETCC Expected.");
11975   assert(N->getOpcode() == ISD::SETCC && "ISD::SETCC Expected.");
12020   assert(Subtarget.useCRBits() && "Expecting to be tracking CR bits");
12440       assert(PromBits < OpBits && "Truncation not to a smaller bit count?");
12568   assert(N->getOpcode() == ISD::SIGN_EXTEND &&
12581   assert(N->getOpcode() == ISD::SETCC &&
12628   assert(N->getOpcode() == ISD::BUILD_VECTOR &&
12635   assert(FirstInput.getOpcode() == PPCISD::MFVSR &&
12713   assert(N->getOpcode() == ISD::BUILD_VECTOR &&
12767   assert(!(InputsAreConsecutiveLoads && InputsAreReverseConsecutive) &&
12779     assert(LD1 && "Input needs to be a LoadSDNode.");
12785     assert(LDL && "Input needs to be a LoadSDNode.");
12932   assert(N->getOpcode() == ISD::BUILD_VECTOR &&
13015   assert((N->getOpcode() == ISD::SINT_TO_FP ||
13070   assert((Op.getOpcode() == ISD::SINT_TO_FP || Subtarget.hasFPCVT()) &&
13259   assert((Opcode == ISD::FP_TO_SINT || Opcode == ISD::FP_TO_UINT)
13312   assert((ISD::isNormalLoad(LSBase) || ISD::isNormalStore(LSBase)) &&
13583         assert(LD->getAddressingMode() == ISD::PRE_INC &&
13953         assert(UI != VCMPoNode->use_end() && "Didn't find user!");
13980       assert(Cond.getNode()->hasOneUse() &&
14010       assert((CC == ISD::SETEQ || CC == ISD::SETNE) &&
14020       assert(LHS.getNode()->hasOneUse() &&
14033       assert(isDot && "Can't compare against a vector result!");
14851   assert(Ty->isIntegerTy());
14894   assert(DestVT.isFloatingPoint() && SrcVT.isFloatingPoint() &&
15053     assert(Entry->getParent()->getFunction().hasFnAttribute(
15223   assert(Constant && "Constant Should not be a null pointer.");
15472   assert((N->getOpcode() == ISD::ABS) && "Need ABS node here");
15473   assert(Subtarget.hasP9Altivec() &&
15516   assert((N->getOpcode() == ISD::VSELECT) && "Need VSELECT node here");
15517   assert(Subtarget.hasP9Altivec() &&
lib/Target/PowerPC/PPCInstrInfo.cpp
  137     assert(DAG->TII && "No InstrInfo?");
  393   assert(((OpIdx1 == 1 && OpIdx2 == 2) || (OpIdx1 == 2 && OpIdx2 == 1)) &&
  407     assert(MI.getDesc().getOperandConstraint(0, MCOI::TIED_TO) &&
  409     assert(MI.getOperand(0).getSubReg() == SubReg1 && "Tied subreg mismatch");
  672   assert(!BytesRemoved && "code size not handled");
  709   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  710   assert((Cond.size() == 2 || Cond.size() == 0) &&
  712   assert(!BytesAdded && "code size not handled");
  797   assert(Cond.size() == 2 &&
  804   assert(RC && "TrueReg and FalseReg must have overlapping register classes");
  808   assert((Is64Bit ||
  900   assert(Ret != 4 && "Invalid CR bit register");
  957     assert(Subtarget.hasDirectMove() &&
  965     assert(Subtarget.hasDirectMove() &&
 1315   assert(Cond.size() == 2 && "Invalid PPC branch opcode!");
 1352   assert(UseIdx < UseMI.getNumOperands() && "Cannot find Reg in UseMI");
 1353   assert(UseIdx < UseMCID.getNumOperands() && "No operand description for Reg");
 1525   assert(Pred1.size() == 2 && "Invalid PPC first predicate");
 1526   assert(Pred2.size() == 2 && "Invalid PPC second predicate");
 1881         assert((!equalityOnly ||
 1890         assert((!equalityOnly || NewSubReg == PPC::sub_eq) &&
 1903   assert(!(Value != 0 && ShouldSwap) &&
 1992   assert(MI->definesRegister(PPC::CR0) &&
 2138     assert(Subtarget.isTargetLinux() &&
 2152     assert(Subtarget.hasP9Vector() &&
 2154     assert(MI.getOperand(2).isReg() &&
 2164     assert(Subtarget.hasP8Vector() &&
 2166     assert(MI.getOperand(2).isReg() && MI.getOperand(1).isReg() &&
 2172     assert(Subtarget.hasVSX() &&
 2174     assert(MI.getOperand(2).isReg() && MI.getOperand(1).isReg() &&
 2272   assert(MI.getOperand(OpNo).isReg() && "Operand must be a REG");
 2325   assert(!MI.getParent()->getParent()->getRegInfo().isSSA() &&
 2461   assert((StartMI.getParent() == EndMI.getParent()) &&
 2516         assert(&*It == &StartMI && "No new def between StartMI and EndMI.");
 2526   assert((IsKillSet || (MO && MO->isDead())) &&
 2599   assert(ADDIMI && "There should be ADDIMI for valid ToBeChangedReg.");
 2695   assert(RegOperand.isReg() && "Instruction format is not right");
 2711   assert((Index == 1 || Index == 2) && "Invalid operand index for add.");
 2763   assert(ForwardingOperand < MI.getNumOperands() &&
 2972             assert(Immediate && "Transformation converted zero to non-zero?");
 3408   assert(Op1 != Op2 && "Cannot swap operand with itself.");
 3493   assert(DefMI.getNumOperands() >= 3 &&
 3533   assert((&*It) == &DefMI && "DefMI is missing");
 3547   assert(isAnImmediateOperand(ImmMO) && "ImmMO is NOT an immediate");
 3619   assert(ImmMO && RegMO && "Imm and Reg operand must have been set");
 4126     assert(MI.getOperand(1).isReg() && MI.getOperand(2).isReg());
 4269   assert(LdSt.mayLoadOrStore() && "Expected a memory operation.");
 4288   assert(MIa.mayLoadOrStore() && "MIa must be a load or store.");
 4289   assert(MIb.mayLoadOrStore() && "MIb must be a load or store.");
lib/Target/PowerPC/PPCLoopPreIncPrep.cpp
  176   assert(I && "Invalid paramater!");
  219   assert((MemI && GetPointerOperand(MemI)) &&
  221   assert(LSCEV && "Invalid SCEV for Ptr value.");
  336   assert(BasePtrSCEV->getLoop() == L && "AddRec for the wrong loop?");
  342   assert(BasePtr && "No pointer operand");
  419     assert(Ptr && "No pointer operand");
  570     assert((PtrValue && I) && "Invalid parameter!");
lib/Target/PowerPC/PPCMCInstLower.cpp
   52     assert(MO.isSymbol() && "Isn't a symbol reference");
   70       assert(MO.isGlobal() && "Extern symbol not handled yet");
  169     assert(!MO.getSubReg() && "Subregs should be eliminated!");
  170     assert(MO.getReg() > PPC::NoRegister &&
lib/Target/PowerPC/PPCMIPeephole.cpp
  147   assert(Op && "Invalid Operand!");
  219   assert(TII->isTOCSaveMI(*MI) && "Expecting a TOC save instruction here");
  220   assert(MF->getSubtarget<PPCSubtarget>().isELFv2ABI() &&
  722           assert(PhiOp && "Invalid Operand!");
  731           assert(PhiOp && "Invalid Operand!");
  732           assert(DominatorOp && "Invalid Operand!");
  779           assert((LiMI->getOpcode() == PPC::LI ||
 1286           assert(Inst->getOpcode() == PPC::PHI &&
 1403   assert(MI.getNumOperands() == 4 && "RLDICR should have 4 operands");
 1429   assert(SrcMI->getNumOperands() == 2 && "EXTSW should have 2 operands");
 1430   assert(SrcMI->getOperand(1).isReg() &&
lib/Target/PowerPC/PPCPreEmitPeephole.cpp
   91         assert(BBI->getOperand(0).isReg() &&
  113             assert(!DeadOrKillToUnset && "Shouldn't kill same register twice");
  126           assert(AfterBBI->getOperand(0).isReg() &&
  256             assert(It->isTerminator() && "Non-terminator after a terminator");
lib/Target/PowerPC/PPCReduceCRLogicals.cpp
   88   assert(OrigMBB->isSuccessor(NewMBB) &&
  140   assert(BSI.allInstrsInSameMBB() &&
  146   assert(MRI->isSSA() && "Can only do this while the function is in SSA form.");
  232     assert(FirstTerminator->getOperand(0).isReg() &&
  477     assert(Def1 && "Must be able to find a definition of operand 1.");
  487       assert(Def2 && "Must be able to find a definition of operand 2.");
lib/Target/PowerPC/PPCRegisterInfo.cpp
  199   assert(MF && "Invalid MachineFunction pointer.");
  240     assert(!Subtarget.hasAltivec() && "Altivec is not implemented on AIX yet.");
  343   assert(checkAllSuperRegsMarked(Reserved));
  394   assert(Register::isPhysicalRegister(PhysReg));
  518   assert((maxCallFrameSize & (MaxAlign-1)) == 0 &&
  704   assert(MI.definesRegister(DestReg) &&
  827   assert(MI.definesRegister(DestReg) &&
  900   assert(MI.definesRegister(DestReg) &&
  986   assert(SPAdj == 0 && "Unexpected");
 1076   assert(OpC != PPC::DBG_VALUE &&
 1121     assert(ImmToIdxMap.count(OpC) &&
 1176   assert(Offset < 0 && "Local offset must be negative");
 1246     assert(FIOperandNum < MI.getNumOperands() &&
 1271     assert(FIOperandNum < MI->getNumOperands() &&
lib/Target/PowerPC/PPCRegisterInfo.h
   53   assert(Reg != 0 && "Invalid CR bit register");
lib/Target/PowerPC/PPCTargetMachine.cpp
  207   assert(Options.MCOptions.getABIName().empty() &&
  258   assert(TT.isOSBinFormatELF() && "All remaining PPC OSes are ELF based.");
  263   assert(TT.isArch64Bit() && "Unsupported PPC architecture.");
lib/Target/PowerPC/PPCTargetTransformInfo.cpp
   51   assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2");
   62   assert(Ty->isIntegerTy());
   92   assert(Ty->isIntegerTy());
  126   assert(Ty->isIntegerTy());
  602   assert(ClassID == GPRRC || ClassID == FPRRC ||
  605     assert(ClassID == GPRRC || ClassID == VSXRC);
  608   assert(ClassID == GPRRC || ClassID == FPRRC || ClassID == VRRC);
  727   assert(TLI->InstructionOpcodeToISD(Opcode) && "Invalid opcode");
  751   assert(TLI->InstructionOpcodeToISD(Opcode) && "Invalid opcode");
  764   assert(Val->isVectorTy() && "This must be a vector type");
  767   assert(ISD && "Invalid opcode");
  841   assert((Opcode == Instruction::Load || Opcode == Instruction::Store) &&
  896   assert(Alignment);
  921   assert(isa<VectorType>(VecTy) &&
lib/Target/PowerPC/PPCVSXCopy.cpp
  100           assert((IsF8Reg(SrcMO.getReg(), MRI) ||
  121           assert((IsF8Reg(DstMO.getReg(), MRI) ||
lib/Target/PowerPC/PPCVSXFMAMutate.cpp
  240         assert(OldFMAReg == AddendMI->getOperand(0).getReg() &&
lib/Target/PowerPC/PPCVSXSwapRemoval.cpp
  565     assert(MI->isSubregToReg() && "bad opcode for lookThruCopyLike");
  618       assert(SwapMap.find(DefMI) != SwapMap.end() &&
lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
  597     assert(Kind == KindTy::Register && "Invalid type access!");
  602     assert(Kind == KindTy::SystemRegister && "Invalid access!");
  607     assert(Kind == KindTy::Immediate && "Invalid type access!");
  612     assert(Kind == KindTy::Token && "Invalid type access!");
  676     assert(Expr && "Expr shouldn't be null!");
  689     assert(N == 1 && "Invalid number of operands!");
  694     assert(N == 1 && "Invalid number of operands!");
  699     assert(N == 1 && "Invalid number of operands!");
  718     assert(N == 1 && "Invalid number of operands!");
  729     assert(FRM != RISCVFPRndMode::Invalid && "Invalid rounding mode");
  734     assert(N == 1 && "Invalid number of operands!");
  745   assert(Reg >= RISCV::F0_D && Reg <= RISCV::F31_D && "Invalid register");
  954   assert(!(RegNo >= RISCV::F0_F && RegNo <= RISCV::F31_F));
 1733   assert(Inst.getOpcode() == RISCV::PseudoAddTPRel && "Invalid instruction");
 1734   assert(Inst.getOperand(2).isReg() && "Unexpected second operand kind");
lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
  173   assert(isUInt<N>(Imm) && "Invalid immediate");
  191   assert(isUInt<N>(Imm) && "Invalid immediate");
  211   assert(isUInt<N>(Imm) && "Invalid immediate");
  222   assert(isUInt<6>(Imm) && "Invalid immediate");
  233   assert(isUInt<3>(Imm) && "Invalid immediate");
  266   assert(Result == MCDisassembler::Success && "Invalid immediate");
  278   assert(Result == MCDisassembler::Success && "Invalid immediate");
  291   assert(Result == MCDisassembler::Success && "Invalid immediate");
lib/Target/RISCV/MCTargetDesc/RISCVAsmBackend.cpp
  301   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
lib/Target/RISCV/MCTargetDesc/RISCVAsmBackend.h
  129     assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
lib/Target/RISCV/MCTargetDesc/RISCVELFStreamer.cpp
   30   assert(ABI != RISCVABI::ABI_Unknown && "Improperly initialised target ABI");
lib/Target/RISCV/MCTargetDesc/RISCVInstPrinter.cpp
   87   assert((Modifier == 0 || Modifier[0] == 0) && "No modifiers supported");
  100   assert(MO.isExpr() && "Unknown operand kind in printOperand");
  119   assert (((FenceArg >> 4) == 0) && "Invalid immediate in printFenceArg");
  145   assert(MO.isReg() && "printAtomicMemOp can only print register operands");
lib/Target/RISCV/MCTargetDesc/RISCVMCAsmInfo.cpp
   45   assert(Encoding & dwarf::DW_EH_PE_sdata4 && "Unexpected encoding");
lib/Target/RISCV/MCTargetDesc/RISCVMCCodeEmitter.cpp
  117   assert(Func.isExpr() && "Expected expression");
  145   assert(TPReg.isReg() && TPReg.getReg() == RISCV::X4 &&
  149   assert(SrcSymbol.isExpr() &&
  153   assert(Expr && Expr->getKind() == RISCVMCExpr::VK_RISCV_TPREL_ADD &&
  238     assert((Res & 1) == 0 && "LSB is non-zero");
  258   assert(MO.isExpr() &&
  351   assert(FixupKind != RISCV::fixup_riscv_invalid && "Unhandled expression!");
lib/Target/RISCV/RISCVExpandPseudoInsts.cpp
  277   assert(OldValReg != ScratchReg && "OldValReg and ScratchReg must be unique");
  278   assert(OldValReg != MaskReg && "OldValReg and MaskReg must be unique");
  279   assert(ScratchReg != MaskReg && "ScratchReg and MaskReg must be unique");
  299   assert(Width == 32 && "Should never need to expand masked 64-bit operations");
  411   assert(IsMasked == true &&
  413   assert(Width == 32 && "Should never need to expand masked 64-bit operations");
lib/Target/RISCV/RISCVFrameLowering.cpp
  103   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  194     assert(SecondSPAdjustAmount > 0 &&
  254     assert(hasFP(MF) && "frame pointer should not have been eliminated");
  262     assert(SecondSPAdjustAmount > 0 &&
  355     assert(!MFI.hasVarSizedObjects() &&
lib/Target/RISCV/RISCVISelDAGToDAG.cpp
  161     assert(!Subtarget->is64Bit() && "READ_CYCLE_WIDE is only used on riscv32");
lib/Target/RISCV/RISCVISelLowering.cpp
   51   assert(ABI != RISCVABI::ABI_Unknown && "Improperly initialised target ABI");
  396     assert(Subtarget.is64Bit() && Subtarget.hasStdExtF() &&
  868     assert(!Subtarget.is64Bit() &&
  883     assert(N->getValueType(0) == MVT::i32 && Subtarget.is64Bit() &&
  892     assert(N->getValueType(0) == MVT::i32 && Subtarget.is64Bit() &&
  901     assert(N->getValueType(0) == MVT::i32 && Subtarget.is64Bit() &&
  909     assert(N->getValueType(0) == MVT::i32 && Subtarget.is64Bit() &&
  967     assert(Op0.getOpcode() == ISD::FABS);
 1012     assert(Op0.getOpcode() == ISD::FABS);
 1091   assert(MI.getOpcode() == RISCV::ReadCycleWide && "Unexpected instruction");
 1153   assert(MI.getOpcode() == RISCV::SplitF64Pseudo && "Unexpected instruction");
 1184   assert(MI.getOpcode() == RISCV::BuildPairF64Pseudo &&
 1356     assert(!Subtarget.is64Bit() &&
 1452   assert(XLen == 32 || XLen == 64);
 1520   assert(PendingLocs.size() == PendingArgFlags.size() &&
 1526     assert(!ArgFlags.isSplit() && PendingLocs.empty() &&
 1562     assert(PendingLocs.size() == 2 && "Unexpected PendingLocs.size()");
 1586     assert(ArgFlags.isSplitEnd() && "Expected ArgFlags.isSplitEnd()");
 1587     assert(PendingLocs.size() > 2 && "Unexpected PendingLocs.size()");
 1601   assert((!UseGPRForF32 || !UseGPRForF64 || LocVT == XLenVT) &&
 1772   assert(VA.getLocVT() == MVT::i32 && VA.getValVT() == MVT::f64 &&
 1786   assert(VA.isRegLoc() && "Expected register VA assignment");
 1928       assert(Ins[i].PartOffset == 0);
 2183         assert(RegLo < RISCV::X31 && "Invalid register pair");
 2205       assert(Outs[i].PartOffset == 0);
 2229       assert(VA.isMemLoc() && "Argument not register or memory");
 2230       assert(!IsTailCall && "Tail call not allowed if stack is used "
 2303     assert(Mask && "Missing call preserved mask for calling convention");
 2344       assert(VA.getLocReg() == ArgGPRs[0] && "Unexpected reg assignment");
 2403     assert(VA.isRegLoc() && "Can only return in registers!");
 2407       assert(VA.isRegLoc() && "Expected return via registers");
 2413       assert(RegLo < RISCV::X31 && "Invalid register pair");
lib/Target/RISCV/RISCVInstrInfo.cpp
  177   assert(Seq.size() > 0);
  206   assert(LastInst.getDesc().isConditionalBranch() &&
  342   assert(TBB && "InsertBranch must not be told to insert a fallthrough");
  343   assert((Cond.size() == 3 || Cond.size() == 0) &&
  377   assert(RS && "RegScavenger required for long branching");
  378   assert(MBB.empty() &&
  380   assert(MBB.pred_size() == 1);
  416   assert((Cond.size() == 3) && "Invalid branch condition!");
  423   assert(MI.getDesc().isBranch() && "Unexpected opcode!");
lib/Target/RISCV/RISCVMergeBaseOffset.cpp
  137   assert((TailAdd.getOpcode() == RISCV::ADD) && "Expected ADD instruction!");
  182   assert(MRI->hasOneUse(DestReg) && "expected one use for LoADDI");
lib/Target/RISCV/RISCVRegisterInfo.cpp
   85   assert(checkAllSuperRegsMarked(Reserved));
  105   assert(SPAdj == 0 && "Unexpected non-zero SPAdj value");
  128     assert(isInt<32>(Offset) && "Int32 expected");
lib/Target/RISCV/RISCVSubtarget.h
   98     assert(i < RISCV::NUM_TARGET_REGS && "Register out of range");
lib/Target/RISCV/RISCVTargetMachine.cpp
   45     assert(TT.isArch32Bit() && "only RV32 and RV64 are currently supported");
lib/Target/RISCV/RISCVTargetTransformInfo.cpp
   19   assert(Ty->isIntegerTy() &&
   34   assert(Ty->isIntegerTy() &&
lib/Target/RISCV/Utils/RISCVMatInt.cpp
   41   assert(IsRV64 && "Can't emit >32-bit imm for non-RV64 target");
lib/Target/Sparc/AsmParser/SparcAsmParser.cpp
  281     assert(Kind == k_Token && "Invalid access!");
  286     assert((Kind == k_Register) && "Invalid access!");
  291     assert((Kind == k_Immediate) && "Invalid access!");
  296     assert((Kind == k_MemoryReg || Kind == k_MemoryImm) && "Invalid access!");
  301     assert((Kind == k_MemoryReg) && "Invalid access!");
  306     assert((Kind == k_MemoryImm) && "Invalid access!");
  326     case k_MemoryImm: assert(getMemOff() != nullptr);
  334     assert(N == 1 && "Invalid number of operands!");
  339     assert(N == 1 && "Invalid number of operands!");
  355     assert(N == 2 && "Invalid number of operands!");
  359     assert(getMemOffsetReg() != 0 && "Invalid offset");
  364     assert(N == 2 && "Invalid number of operands!");
  373     assert(N == 1 && "Invalid number of operands!");
  408     assert(Op.Reg.Kind == rk_IntReg);
  427     assert(Op.Reg.Kind == rk_FloatReg);
  461     assert(Op.Reg.Kind == rk_CoprocReg);
  510   assert(MCRegOp.isReg());
  511   assert(MCValOp.isImm() || MCValOp.isExpr());
lib/Target/Sparc/DelaySlotFiller.cpp
  154       assert (J != MBB.end() && "MI needs a delay instruction.");
  301     assert(MI->getNumOperands() >= 2);
  303     assert(Reg.isReg() && "CALL first operand is not a register.");
  304     assert(Reg.isUse() && "CALL first operand is not a use.");
  310     assert(Operand1.isReg() && "CALLrr second operand is not a register.");
  311     assert(Operand1.isUse() && "CALLrr second operand is not a use.");
  465   assert(RestoreMI->getOpcode() == SP::RESTORErr);
  488   assert(MBBI->getOpcode() == SP::RESTORErr
lib/Target/Sparc/MCTargetDesc/SparcAsmBackend.cpp
   87     assert(Value == 0 && "Sparc TLS relocs expect zero Value");
  218       assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
lib/Target/Sparc/MCTargetDesc/SparcInstPrinter.cpp
  135   assert(MO.isExpr() && "Unknown operand kind in printOperand");
lib/Target/Sparc/MCTargetDesc/SparcMCCodeEmitter.cpp
  116     assert(op == 0 && "Unexpected operand value!");
  133   assert(MO.isExpr());
  163     assert(SExpr && SExpr->getSubExpr()->getKind() == MCExpr::SymbolRef &&
  166     assert(SymExpr->getSymbol().getName() == "__tls_get_addr" &&
lib/Target/Sparc/SparcAsmPrinter.cpp
  176   assert(MO.getReg() != SP::O7 &&
  301       assert(TF == SparcMCExpr::VK_Sparc_None &&
  304       assert((TF == SparcMCExpr::VK_Sparc_HI
  314       assert((TF == SparcMCExpr::VK_Sparc_None
  319       assert((TF == SparcMCExpr::VK_Sparc_TLS_GD_ADD
  325       assert(TF == SparcMCExpr::VK_Sparc_TLS_IE_LD &&
  328       assert(TF == SparcMCExpr::VK_Sparc_TLS_IE_LDX &&
  331       assert((TF == SparcMCExpr::VK_Sparc_TLS_LDO_LOX10
  335       assert((TF == SparcMCExpr::VK_Sparc_LO
lib/Target/Sparc/SparcFrameLowering.cpp
   89   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  227   assert(MBBI->getOpcode() == SP::RETL &&
  369   assert(verifyLeafProcRegUse(&MRI));
lib/Target/Sparc/SparcISelDAGToDAG.cpp
  221     assert((i+2 < NumOps) && "Invalid number of operands in inline asm");
lib/Target/Sparc/SparcISelLowering.cpp
   45   assert (ArgFlags.isSRet());
  109   assert((LocVT == MVT::f32 || LocVT == MVT::f128
  154   assert(LocVT.getSizeInBits() == 32 && "Can't handle non-32 bits locations");
  235     assert(VA.isRegLoc() && "Can only return in registers!");
  240       assert(VA.getLocVT() == MVT::v2i32);
  318     assert(VA.isRegLoc() && "Can only return in registers!");
  418         assert(VA.getLocVT() == MVT::f64 || VA.getLocVT() == MVT::v2i32);
  424         assert(i+1 < e);
  462     assert(VA.isMemLoc());
  468       assert(VA.getValVT() == MVT::f64 || VA.getValVT() == MVT::v2i32);
  545       assert(!ArgOffset);
  633     assert(VA.isMemLoc());
  820       assert(VA.needsCustom());
  829       assert(Outs[realArgIdx].OrigArgIndex == 0);
  837       assert(VA.getLocVT() == MVT::f64 || VA.getLocVT() == MVT::v2i32);
  870         assert(i+1 != e);
  912     assert(VA.isMemLoc());
  967   assert(Mask && "Missing call preserved mask for calling convention");
 1066     assert(Offset < 16*8 && "Offset out of range, bad register enum?");
 1076         assert(ValTy == MVT::f128 && "Unexpected type!");
 1213     assert(VA.isMemLoc());
 1267   assert(Mask && "Missing call preserved mask for calling convention");
 2059     assert(Mask && "Missing call preserved mask for calling convention");
 2109   assert(model == TLSModel::LocalExec);
 2176   assert(Op->getNumOperands() >= numArgs && "Not enough operands!");
 2190   assert (RetTy->isFP128Ty() && "Unexpected return type!");
 2335   assert(VT == MVT::i32 || VT == MVT::i64);
 2364   assert(OpVT == MVT::i32 || (OpVT == MVT::i64));
 2399   assert(VT == MVT::i32 || VT == MVT::i64);
 2413   assert(OpVT == MVT::i32 || OpVT == MVT::i64);
 2693   assert(SrcReg64.getValueType() == MVT::f64 && "LowerF64Op called on non-double!");
 2694   assert(opcode == ISD::FNEG || opcode == ISD::FABS);
 2729   assert(LdNode && LdNode->getOffset().isUndef()
 2783   assert(StNode && StNode->getOffset().isUndef()
 2839   assert((Op.getOpcode() == ISD::FNEG || Op.getOpcode() == ISD::FABS)
 2936   assert((opcode == ISD::UMULO || opcode == ISD::SMULO) && "Invalid Opcode.");
 2974   assert(MulResult->use_empty() && "Illegally typed node still in use!");
 3362     assert(Subtarget->hasLeonCycleCounter());
lib/Target/Sparc/SparcInstrInfo.cpp
  248   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  249   assert((Cond.size() == 1 || Cond.size() == 0) &&
  251   assert(!BytesAdded && "code size not handled");
  254     assert(!FBB && "Unconditional branch with multiple successors!");
  275   assert(!BytesRemoved && "code size not handled");
  299   assert(Cond.size() == 1);
  380     assert(Dst && Src && "Bad sub-register");
  497     assert(Subtarget.isTargetLinux() &&
lib/Target/Sparc/SparcRegisterInfo.cpp
  167   assert(SPAdj == 0 && "Unexpected");
lib/Target/SystemZ/AsmParser/SystemZAsmParser.cpp
  214     assert(Kind == KindToken && "Not a token");
  226     assert(Kind == KindReg && "Not a register");
  238     assert(Kind == KindImm && "Not an immediate");
  248     assert(Kind == KindImmTLS && "Not a TLS immediate");
  280     assert(Kind == KindMem && "Not a Mem operand");
  296     assert(N == 1 && "Invalid number of operands");
  300     assert(N == 1 && "Invalid number of operands");
  304     assert(N == 2 && "Invalid number of operands");
  305     assert(isMem(BDMem) && "Invalid operand type");
  310     assert(N == 3 && "Invalid number of operands");
  311     assert(isMem(BDXMem) && "Invalid operand type");
  317     assert(N == 3 && "Invalid number of operands");
  318     assert(isMem(BDLMem) && "Invalid operand type");
  324     assert(N == 3 && "Invalid number of operands");
  325     assert(isMem(BDRMem) && "Invalid operand type");
  331     assert(N == 3 && "Invalid number of operands");
  332     assert(isMem(BDVMem) && "Invalid operand type");
  338     assert(N == 2 && "Invalid number of operands");
  339     assert(Kind == KindImmTLS && "Invalid operand type");
 1049   assert(Entry->Format == Format);
 1259     assert(MissingFeatures.any() && "Unknown missing feature!");
lib/Target/SystemZ/Disassembler/SystemZDisassembler.cpp
   85   assert(RegNo < Size && "Invalid register");
  252   assert(isUInt<N>(Imm) && "Invalid PC-relative offset");
  296   assert(Base < 16 && "Invalid BDAddr12");
  306   assert(Base < 16 && "Invalid BDAddr20");
  317   assert(Index < 16 && "Invalid BDXAddr12");
  329   assert(Index < 16 && "Invalid BDXAddr20");
  341   assert(Length < 16 && "Invalid BDLAddr12Len4");
  353   assert(Length < 256 && "Invalid BDLAddr12Len8");
  365   assert(Length < 16 && "Invalid BDRAddr12");
  377   assert(Index < 32 && "Invalid BDVAddr12");
lib/Target/SystemZ/MCTargetDesc/SystemZInstPrinter.cpp
   68   assert(isUInt<N>(Value) && "Invalid uimm argument");
   75   assert(isInt<N>(Value) && "Invalid simm argument");
  231   assert(Imm > 0 && Imm < 15 && "Invalid condition");
lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
   91   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  107   assert(Offset + Size <= Data.size() && "Invalid fixup offset!");
lib/Target/SystemZ/MCTargetDesc/SystemZMCCodeEmitter.cpp
  188   assert(isUInt<4>(Base) && isUInt<12>(Disp));
  198   assert(isUInt<4>(Base) && isInt<20>(Disp));
  209   assert(isUInt<4>(Base) && isUInt<12>(Disp) && isUInt<4>(Index));
  220   assert(isUInt<4>(Base) && isInt<20>(Disp) && isUInt<4>(Index));
  232   assert(isUInt<4>(Base) && isUInt<12>(Disp) && isUInt<4>(Len));
  243   assert(isUInt<4>(Base) && isUInt<12>(Disp) && isUInt<8>(Len));
  254   assert(isUInt<4>(Base) && isUInt<12>(Disp) && isUInt<4>(Len));
  265   assert(isUInt<4>(Base) && isUInt<12>(Disp) && isUInt<5>(Index));
lib/Target/SystemZ/MCTargetDesc/SystemZMCObjectWriter.cpp
  129     assert(!IsPCRel && "NTPOFF shouldn't be PC-relative");
  138     assert(!IsPCRel && "DTPOFF shouldn't be PC-relative");
  142     assert(!IsPCRel && "TLSLDM shouldn't be PC-relative");
  146     assert(!IsPCRel && "TLSGD shouldn't be PC-relative");
  155     assert(IsPCRel && "@PLT shouldt be PC-relative");
lib/Target/SystemZ/MCTargetDesc/SystemZMCTargetDesc.cpp
  145   assert(Reg < SystemZ::NUM_TARGET_REGS);
lib/Target/SystemZ/SystemZAsmPrinter.cpp
  576   assert(NumNOPBytes % 2 == 0 && "Invalid number of NOP bytes requested!");
  647   assert(NumBytes >= EncodedBytes &&
  649   assert((NumBytes - EncodedBytes) % 2 == 0 &&
lib/Target/SystemZ/SystemZElimCompare.cpp
  187   assert(reg);
  334   assert((ReusableCCMask & ~CCValues) == 0 && "Invalid CCValues");
  536   assert((CCMask.getImm() & ~SystemZ::CCMASK_ICMP) == 0 &&
  547   assert(CCUse >= 0 && "BRC/BCR must use CC");
lib/Target/SystemZ/SystemZFrameLowering.cpp
  152       assert(Offset && "Unexpected GPR save");
  180     assert(LowGPR != HighGPR && "Should be saving %r15 and something else");
  258     assert(LowGPR != HighGPR && "Should be loading %r15 and something else");
  343   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  482   assert(MBBI->isReturn() && "Can only insert epilogue into returning blocks");
  504       assert(NewOpcode && "No restore instruction available");
  537     assert(hasReservedCallFrame(MF) &&
lib/Target/SystemZ/SystemZHazardRecognizer.cpp
   51   assert((SC->NumMicroOps != 2 || (SC->BeginGroup && !SC->EndGroup)) &&
   53   assert((SC->NumMicroOps < 3 || (SC->BeginGroup && SC->EndGroup)) &&
   55   assert((SC->NumMicroOps < 3 || (SC->NumMicroOps % 3 == 0)) &&
  103   assert ((CurrGroupSize < 2 || !CurrGroupHas4RegOps) &&
  111   assert ((getNumDecoderSlots(SU) <= 1) && (CurrGroupSize < 3) &&
  142   assert((CurrGroupSize <= 3 || CurrGroupSize % 3 == 0) &&
  331   assert((CurrGroupSize <= GroupLim || CurrGroupSize == getNumDecoderSlots(SU))
  372   assert (SU->isUnbuffered);
  446   assert ((!MI->isTerminator() || isBranchRetTrap(MI)) &&
lib/Target/SystemZ/SystemZISelDAGToDAG.cpp
  100   assert(Count <= 64);
  495   assert(selectDisp(DR, Val) && "Invalid displacement");
  636     assert(VT == MVT::i32 && Base.getValueType() == MVT::i64 &&
  947   assert(N.getValueType() == VT && "Unexpected value types");
 1145   assert((VCI.Opcode == SystemZISD::BYTE_MASK ||
 1149   assert(VCI.VecVT.getSizeInBits() == 128 && "Expected a vector type");
 1601     assert(Success && "Expected legal FP immediate");
lib/Target/SystemZ/SystemZISelLowering.cpp
  767   assert(BVN->isConstant() && "Expected a constant BUILD_VECTOR");
 1058   assert(*(Constraint.end()-1) == '}' && "Missing '}'");
 1257     assert(VA.getLocVT() == MVT::i64);
 1258     assert(VA.getValVT().isVector());
 1262     assert(VA.getLocInfo() == CCValAssign::Full && "Unsupported getLocInfo");
 1281     assert(VA.getLocVT() == MVT::i64);
 1282     assert(VA.getValVT().isVector());
 1358       assert(VA.isMemLoc() && "Argument not register or memory");
 1383       assert (Ins[I].PartOffset == 0);
 1515       assert (Outs[I].PartOffset == 0);
 1534       assert(VA.isMemLoc() && "Argument not register or memory");
 1593   assert(Mask && "Missing call preserved mask for calling convention");
 1687     assert(VA.isRegLoc() && "Can only return in registers!");
 1905   assert(Op->getNumValues() == 2 && "Expected only CC result and chain");
 2250   assert(Mask != 0 && "ANDs with zero should have been removed by now");
 2694     assert(IsFP && "Unexpected integer comparison");
 2706     assert(IsFP && "Unexpected integer comparison");
 2891   assert(Mask && "Missing call preserved mask for calling convention");
 3381   assert(Op.getValueType() == MVT::i64 && "Should be 64-bit operation");
 3747     assert(Op.getValueType() == MemVT && "Mismatched VTs");
 3923     assert(Op->getNumValues() == 2 && "Expected only CC result and chain");
 3941     assert(Op->getNumValues() == 2 && "Expected a CC and non-CC result");
 4380   assert(Bytes.size() == SystemZ::VectorBytes && "Incomplete vector");
 4422             assert(unsigned(NewBytesMap[J]) < SystemZ::VectorBytes &&
 4426             assert(NewBytesMap[J] < 0 && "Invalid double permute");
 4762     assert(Index < VT.getVectorNumElements() &&
 4908       assert(Index < VT.getVectorNumElements() &&
 6244       assert(VT == MVT::v16i8 && "Unexpected type.");
 6246       assert (FirstIdx > 0 && FirstIdx < 16 && "Unused operand.");
 6313   assert (Known.getBitWidth() == VT.getScalarSizeInBits() &&
 6315   assert ((!VT.isVector() ||
 6410   assert (SrcBitWidth == VTBits && "Expected operands of same bitwidth.");
 6621   assert(isSelectPseudo(MI) && "Bad call to emitSelect()");
 6641       assert(NextMIIt->getOperand(3).getImm() == CCValid &&
 6658         assert(NextMIIt->isDebugValue() && "Unhandled debug opcode.");
 6836   assert(LOpcode && CSOpcode && "Displacement out of range");
 6954   assert(LOpcode && CSOpcode && "Displacement out of range");
 7063   assert(LOpcode && CSOpcode && "Displacement out of range");
lib/Target/SystemZ/SystemZInstrInfo.cpp
  109   assert(HighOpcode && LowOpcode && "Both offsets should be in range");
  126   assert(NewOpcode && "No support for huge argument lists yet");
  425     assert(Cond.size() == 2 && TBB && "Should have seen a conditional branch");
  447   assert(!BytesRemoved && "code size not handled");
  472   assert(Cond.size() == 2 && "Invalid condition");
  488   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  489   assert((Cond.size() == 2 || Cond.size() == 0) &&
  491   assert(!BytesAdded && "code size not handled");
  495     assert(!FBB && "Unconditional branch with multiple successors!");
  519   assert(MI.isCompare() && "Caller should have checked for a comparison");
  575   assert(Pred.size() == 2 && "Invalid condition");
  720   assert(Pred.size() == 2 && "Invalid condition");
  723   assert(CCMask > 0 && CCMask < 15 && "Invalid predicate");
 1015       assert(!CCUnit.isValid() && "CC only has one reg unit.");
 1038   assert(Size * 8 ==
 1167       assert(NumOps == 3 && "Expected two source registers.");
 1188       assert(AccessBytes != 0 && "Size of access should be known");
 1189       assert(AccessBytes <= Size && "Access outside the frame index");
 1588     assert(LSB > 0 && "Bottom bit must be set");
 1589     assert(LSB + Length < BitSize && "Top bit must be set");
 1745     assert(isInt<32>(Value) && "Huge values not handled yet");
lib/Target/SystemZ/SystemZLongBranch.cpp
  298         assert(MI->isTerminator() && "Terminator followed by non-terminator");
  447       assert(Position.Address <= TI->Address &&
lib/Target/SystemZ/SystemZMachineScheduler.cpp
   54   assert ((PredMBB == nullptr || !Loop || Loop->contains(PredMBB))
   79   assert ((SchedStates.find(NextMBB) == SchedStates.end()) &&
  196   assert (Best.SU != nullptr);
lib/Target/SystemZ/SystemZPostRewrite.cpp
  168   assert(DestReg == MI.getOperand(1).getReg() &&
lib/Target/SystemZ/SystemZRegisterInfo.cpp
   47     assert (SystemZ::GRH32BitRegClass.contains(PhysReg) &&
   52   assert (RC == &SystemZ::GRX32BitRegClass);
  255   assert(SPAdj == 0 && "Outgoing arguments should be part of the frame");
  298       assert(Mask && "One offset must be OK");
  343   assert (MI->isCopy() && "Only expecting COPY instructions");
lib/Target/SystemZ/SystemZRegisterInfo.h
   37   assert(SystemZ::GR32BitRegClass.contains(Reg) && "Invalid GRX32");
lib/Target/SystemZ/SystemZSelectionDAGInfo.cpp
  124     assert(Bytes >= 2 && "Should have dealt with 0- and 1-byte cases already");
  185     assert(Bytes > 0 && "Caller should have handled 0-size case");
lib/Target/SystemZ/SystemZTargetTransformInfo.cpp
   34   assert(Ty->isIntegerTy());
   67   assert(Ty->isIntegerTy());
  185   assert(Ty->isIntegerTy());
  234   assert(isPowerOf2_32(TyWidth) && "Type width must be power of 2");
  336   assert(Size > 0 && "Element must have non-zero size.");
  344   assert(Ty->isVectorTy() && "Expected vector type");
  346   assert(WideBits > 0 && "Could not compute size of vector");
  396     assert(ST->hasVector() &&
  516   assert (Tp->isVectorTy());
  517   assert (ST->hasVector() && "getShuffleCost() called.");
  565   assert (SrcTy->isVectorTy() && DstTy->isVectorTy());
  566   assert (SrcTy->getPrimitiveSizeInBits() > DstTy->getPrimitiveSizeInBits() &&
  568   assert (SrcTy->getVectorNumElements() == DstTy->getVectorNumElements() &&
  605   assert (SrcTy->isVectorTy() && DstTy->isVectorTy() &&
  640       assert (!OpTy->isVectorTy() && "Expected scalar type");
  657   assert (Dst->isVectorTy());
  677     assert (ST->hasVector() && "getCastInstrCost() called with vector type.");
  678     assert (Dst->isVectorTy());
  764     assert (!Dst->isVectorTy());
  811     assert (ST->hasVector() && "getCmpSelInstrCost() called with vector type.");
  847       assert (Opcode == Instruction::Select);
 1000   assert(!Src->isVoidTy() && "Invalid type");
 1007       assert (UserI->getNumOperands() == 2 && "Expected a binop.");
 1073   assert(isa<VectorType>(VecTy) &&
 1080   assert(Factor > 1 && NumElts % Factor == 0 && "Invalid interleave factor");
 1106       assert (NumSrcVecs >= NumDstVecs && "Expected at least as many sources");
 1115     assert (NumSrcVecs > 1 && "Expected at least two source vectors.");
lib/Target/TargetLoweringObjectFile.cpp
   97     assert(NumElts != 0 && "Can't have an empty CDS");
  118   assert(!Suffix.empty());
  145   assert(!GO->isDeclaration() && !GO->hasAvailableExternallyLinkage() &&
  203             assert(ITy->getBitWidth() == 32 && "Unknown width");
lib/Target/TargetMachine.cpp
  171   assert(TT.isOSBinFormatELF() || TT.isOSBinFormatWasm());
  172   assert(RM != Reloc::DynamicNoPIC);
lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp
  104     assert(isToken());
  117     assert(N == 1 && "Invalid number of operands!");
  127     assert(N == 1 && "Invalid number of operands!");
  135     assert(N == 1 && isBrList() && "Invalid BrList!");
  655     assert(DirectiveID.getKind() == AsmToken::Identifier);
lib/Target/WebAssembly/Disassembler/WebAssemblyDisassembler.cpp
  190   assert(WasmInst->ET == ET_Instruction);
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyAsmBackend.cpp
   88   assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  108   assert(Info.Flags == 0 && "WebAssembly does not use MCFixupKindInfo flags");
  118   assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!");
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyInstPrinter.cpp
   42   assert(RegNo != WebAssemblyFunctionInfo::UnusedReg);
  203   assert(Written != 0);
  204   assert(Written < BufBytes);
  234       assert(Info.OperandType == WebAssembly::OPERAND_F64IMM);
  238     assert(Op.isExpr() && "unknown operand kind in printOperand");
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCCodeEmitter.cpp
   68     assert(Binary <= UINT16_MAX && "Several-byte opcodes not supported yet");
  136         assert(Info.OperandType == WebAssembly::OPERAND_F64IMM);
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
   60   assert(SyntaxVariant == 0 && "WebAssembly only has one syntax variant");
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyTargetStreamer.cpp
   64   assert(Sym->isFunction());
   71   assert(Sym->isGlobal());
   79   assert(Sym->isEvent());
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyWasmObjectWriter.cpp
   68   assert(RefA);
   77       assert(SymA.isFunction());
   80       assert(SymA.isData());
lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp
   71   assert(Register::isVirtualRegister(RegNo) &&
   73   assert(!MFI->isVRegStackified(RegNo));
   75   assert(WAReg != WebAssemblyFunctionInfo::UnusedReg);
  271   assert(MF->getConstantPool()->getConstants().empty() &&
  295     assert(Idx->getNumOperands() == 1);
  383       assert(MI->getOpcode() == WebAssembly::INLINEASM);
lib/Target/WebAssembly/WebAssemblyCFGSort.cpp
  154   assert((AnyBarrier || AllAnalyzable) &&
  355   assert(Entries.empty() && "Active sort region list not finished");
  367     assert(MBB.getNumber() >= 0 && "Renumbered blocks should be non-negative.");
  375           assert(
  382           assert(Pred->getNumber() < MBB.getNumber() &&
  385       assert(OnStack.insert(Region) &&
  391         assert(Pred->getNumber() < MBB.getNumber() &&
  393       assert(OnStack.count(RI.getRegionFor(&MBB)) &&
  399   assert(OnStack.pop_back_val() == nullptr &&
  401   assert(OnStack.empty() &&
lib/Target/WebAssembly/WebAssemblyCFGStackify.cpp
  145         assert(!AfterSet.count(&*std::prev(Pos)));
  169         assert(!BeforeSet.count(&*Pos));
  193   assert(BeginToEnd.count(Begin));
  195   assert(EndToBegin.count(End));
  200     assert(EHPadToTry.count(EHPad));
  210   assert(!MBB.isEHPad());
  231           assert(!BrOnExn && "There should be only one br_on_exn per block");
  242   assert(&MBB != &MF.front() && "Header blocks shouldn't have predecessors");
  432   assert((!ScopeTops[AfterLoop->getNumber()] ||
  440   assert(MBB.isEHPad());
  453       assert(!explicitlyBranchesTo(Pred, &MBB) &&
  463   assert(WE);
  473   assert(Cont != &MF.front());
  905   assert(EHPadStack.empty());
  958   assert(EHPadStack.empty());
 1023     assert(Catch && "EH pad does not have a catch");
 1024     assert(ExnReg != 0 && "Invalid register");
 1218   assert(Depth < Stack.size() && "Branch destination should be in scope");
 1306         assert(ScopeTops[Stack.back()->getNumber()]->getNumber() <=
 1313         assert(Stack.back() == &MBB && "Loop top should be balanced");
 1342   assert(Stack.empty() && "Control flow should be balanced");
lib/Target/WebAssembly/WebAssemblyExceptionInfo.h
  160     assert(!WE->getParentException() && "Not a top level exception!");
lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp
  172   assert(MFI.isVRegStackified(Reg));
  211     assert(!MFI.isVRegStackified(Reg));
  230       assert(!WebAssembly::isArgument(MI.getOpcode()));
  239         assert(MFI.isVRegStackified(MI.getOperand(0).getReg()));
  240         assert(!MFI.isVRegStackified(MI.getOperand(1).getReg()));
  271       assert(MI.getDesc().getNumDefs() <= 1);
  319           assert(MI.isInlineAsm());
  389         assert(
lib/Target/WebAssembly/WebAssemblyFastISel.cpp
   69       assert(!isSet() && "Can't change kind with non-zero base");
   76       assert(isRegBase() && "Invalid base register access!");
   77       assert(Base.Reg == 0 && "Overwriting non-zero register");
   81       assert(isRegBase() && "Invalid base register access!");
   85       assert(isFIBase() && "Invalid base frame index access!");
   86       assert(Base.FI == 0 && "Overwriting non-zero frame index");
   90       assert(isFIBase() && "Invalid base frame index access!");
   95       assert(NewOffset >= 0 && "Offsets must be non-negative");
  580   assert(MRI.getRegClass(Reg) == &WebAssembly::I32RegClass);
 1150   assert(Iter->isBitcast());
lib/Target/WebAssembly/WebAssemblyFixIrreducibleControlFlow.cpp
   81           assert(inRegion(Pred));
   90     assert(inRegion(From) && inRegion(To));
  106     assert(inRegion(LoopEntry));
  108     assert(I != LoopEnterers.end());
  143       assert(inRegion(MBB) && Succ != Entry && inRegion(Succ));
  161     assert(!Loopers.count(Entry));
  210       assert(!Enterers.count(MBB));
  325   assert(Entries.size() >= 2);
  338     assert(Block->getNumber() != -1);
  344       assert(ANum != BNum);
  370     assert(Pair.second);
lib/Target/WebAssembly/WebAssemblyFrameLowering.cpp
  112   assert(needsSP(MF));
  141   assert(!I->getOperand(0).getImm() && (hasFP(MF) || hasBP(MF)) &&
  156   assert(MFI.getCalleeSavedInfo().empty() &&
  204     assert((1u << countTrailingZeros(Alignment)) == Alignment &&
lib/Target/WebAssembly/WebAssemblyISelDAGToDAG.cpp
  151     assert(PtrVT == MVT::i32 && "only wasm32 is supported for now");
  173       assert(PtrVT == MVT::i32 && "only wasm32 is supported for now");
  183       assert(PtrVT == MVT::i32 && "only wasm32 is supported for now");
  199       assert(PtrVT == MVT::i32 && "only wasm32 is supported for now");
lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
  318     assert(BitWidth >= Log2_32_Ceil(VT.getSizeInBits()) &&
  323   assert(Result != MVT::INVALID_SIMPLE_VALUE_TYPE &&
  482       assert(VT != MVT::iPTR && "Pointer MVT not expected here");
  672         assert(!MustTail);
  748       assert(VT != MVT::iPTR && "Legalized args should be concrete");
  773       assert(ArgLocs[ValNo].getValNo() == ValNo &&
  816     assert(!In.Flags.isByVal() && "byval is not valid for return values");
  817     assert(!In.Flags.isNest() && "nest is not valid for return values");
  864   assert((Subtarget->hasMultivalue() || Outs.size() <= 1) &&
  875     assert(!Out.Flags.isByVal() && "byval is not valid for return values");
  876     assert(!Out.Flags.isNest() && "nest is not valid for return values");
  877     assert(Out.IsFixed && "non-fixed return value is not valid");
  946   assert(MFI->getParams().size() == Params.size() &&
 1094   assert(GA->getTargetFlags() == 0 &&
 1140   assert(ES->getTargetFlags() == 0 &&
 1162   assert(JT->getTargetFlags() == 0 && "WebAssembly doesn't set target flags");
 1260   assert(!Subtarget->hasSignExt() && Subtarget->hasSIMD128());
 1277     assert(Scale > 1);
 1454   assert(VecType.is128BitVector() && "Unexpected shuffle vector type");
 1517   assert(Op.getSimpleValueType().isVector());
lib/Target/WebAssembly/WebAssemblyInstrInfo.cpp
  159   assert(!BytesRemoved && "code size not handled");
  182   assert(!BytesAdded && "code size not handled");
  192   assert(Cond.size() == 2 && "Expected a flag and a successor block");
  209     assert(!IsBrOnExn && "br_on_exn does not have a reversed condition");
  221   assert(Cond.size() == 2 && "Expected a flag and a condition expression");
lib/Target/WebAssembly/WebAssemblyLateEHPrepare.cpp
  272     assert(EHPad && "No matching EH pad for extract_exception");
  342       assert(ClangCallTerminateFn &&
lib/Target/WebAssembly/WebAssemblyLowerBrUnless.cpp
   76         assert(MRI.hasOneDef(Cond));
  201       assert(Inverted);
lib/Target/WebAssembly/WebAssemblyLowerEmscriptenEHSjLj.cpp
  960       assert(!isa<InvokeInst>(&I));
 1004         assert(Threw && ThrewLI && "Cannot find __THREW__ load after invoke");
 1005         assert(ThrewResetSI && "Cannot find __THREW__ store after invoke");
 1028       assert(Label && LongjmpResult && EndBB);
lib/Target/WebAssembly/WebAssemblyMCInstLower.cpp
  261           assert(BT != WebAssembly::BlockType::Invalid);
  291       assert(MO.getTargetFlags() == 0 &&
  298       assert(MO.getTargetFlags() == 0 &&
  331   assert(StackOpcode != -1 && "Failed to stackify instruction");
lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.cpp
   24   assert(WARegs.empty());
lib/Target/WebAssembly/WebAssemblyMachineFunctionInfo.h
   84     assert(VarargVreg != -1U && "Vararg vreg hasn't been set");
   90     assert(BasePtrVreg != -1U && "Base ptr vreg hasn't been set");
   98     assert(MF.getRegInfo().getUniqueVRegDef(VReg));
  118     assert(WAReg != UnusedReg);
  120     assert(I < WARegs.size());
  125     assert(I < WARegs.size());
  131     assert(Reg & INT32_MIN);
lib/Target/WebAssembly/WebAssemblyMemIntrinsicResults.cpp
  195   assert(MRI.tracksLiveness() &&
lib/Target/WebAssembly/WebAssemblyOptimizeLiveIntervals.cpp
   79   assert(MRI.tracksLiveness() && "OptimizeLiveIntervals expects liveness");
lib/Target/WebAssembly/WebAssemblyPeephole.cpp
   86   assert(End->getOpcode() == WebAssembly::END_FUNCTION);
lib/Target/WebAssembly/WebAssemblyPrepareForLiveIntervals.cpp
   84   assert(!mustPreserveAnalysisID(LiveIntervalsID) &&
lib/Target/WebAssembly/WebAssemblyRegColoring.cpp
  109     assert(LI->weight == 0.0f);
lib/Target/WebAssembly/WebAssemblyRegStackify.cpp
  103   assert(MI->getOpcode() == TargetOpcode::IMPLICIT_DEF);
  172   assert(!MI.isTerminator());
  297   assert(DefVNI);
  318   assert(Def->getParent() == Insert->getParent());
  443         assert(MRI.hasOneNonDBGUse(DefReg));
  672     assert((Worklist.empty() ||
  688     assert(hasRemainingOperands(Instr) &&
  740       assert(!Declined &&
  811         assert(Op.isUse() && "explicit_uses() should only iterate over uses");
  812         assert(!Op.isImplicit() &&
  924             assert(Stack.pop_back_val() == Reg &&
  931     assert(Stack.empty() &&
lib/Target/WebAssembly/WebAssemblyRegisterInfo.cpp
   56   assert(SPAdj == 0);
   66   assert(MFI.getObjectSize(FrameIndex) != 0 &&
   78     assert(FrameOffset >= 0 && MI.getOperand(OffsetOperandNum).getImm() >= 0);
  146   assert(Kind == 0 && "Only one kind of pointer on WebAssembly");
lib/Target/WebAssembly/WebAssemblyReplacePhysRegs.cpp
   73   assert(!mustPreserveAnalysisID(LiveIntervalsID) &&
lib/Target/WebAssembly/WebAssemblyRuntimeLibcallSignatures.cpp
  502         assert(Map.find(NameLibcall.first) == Map.end() &&
  522   assert(Rets.empty());
  523   assert(Params.empty());
lib/Target/WebAssembly/WebAssemblySetP2AlignOperands.cpp
   58   assert(MI.getOperand(OperandNo).getImm() == 0 &&
   60   assert(MI.hasOneMemOperand() &&
   62   assert((*MI.memoperands_begin())->getSize() ==
   65   assert(MI.getDesc().OpInfo[OperandNo].OperandType ==
lib/Target/WebAssembly/WebAssemblyTargetMachine.cpp
  282         assert(!Features[WebAssembly::FeatureAtomics] ||
lib/Target/WebAssembly/WebAssemblyTargetTransformInfo.cpp
   24   assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2");
lib/Target/WebAssembly/WebAssemblyUtilities.cpp
   53   assert(MO.isGlobal() || MO.isSymbol());
lib/Target/X86/AsmParser/X86AsmParser.cpp
   93     assert(getParser().getStreamer().getTargetStreamer() &&
  151       assert (!PostfixStack.empty() && "Poped an empty stack!");
  158       assert ((Op == IC_IMM || Op == IC_REGISTER) &&
  231           assert (OperandStack.size() > 0 && "Too few operands.");
  233           assert (Operand.first == IC_IMM &&
  247           assert (OperandStack.size() > 1 && "Too few operands.");
  264             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  270             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  272             assert (Op2.second != 0 && "Division by zero!");
  277             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  283             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  289             assert(Op1.first == IC_IMM && Op2.first == IC_IMM &&
  295             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  301             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  307             assert (Op1.first == IC_IMM && Op2.first == IC_IMM &&
  315       assert (OperandStack.size() == 1 && "Expected a single result.");
  726         assert(!BracCount && "BracCount should be zero on parsing's start");
  752             assert (!IndexReg && "BaseReg/IndexReg already set!");
  941     assert(FeatureBitset({mode}) == (STI.getFeatureBits() & AllModes));
 1280     assert(OrigOperands.size() == FinalOperands.size() + 1 &&
 1625   assert(isParsingInlineAsm() && "Expected to be parsing inline assembly.");
 1645   assert((End.getPointer() == EndPtr ||
 1655     assert(InternalName.size() && "We should have an internal name here.");
 2216       assert(!isa<X86MCExpr>(Disp) && "Expected non-register here.");
 3085   assert(MissingFeatures.any() && "Unknown missing feature!");
 3144   assert(!Operands.empty() && "Unexpect empty operand list!");
 3145   assert((*Operands[0]).isToken() && "Leading operand should always be a mnemonic!");
 3296     assert(OriginalError == Match_InvalidOperand && "Unexpected error");
 3350   assert(!Operands.empty() && "Unexpect empty operand list!");
 3351   assert((*Operands[0]).isToken() && "Leading operand should always be a mnemonic!");
 3509     assert(UnsizedMemOp &&
lib/Target/X86/AsmParser/X86Operand.h
  149     assert(Kind == Token && "Invalid access!");
  153     assert(Kind == Token && "Invalid access!");
  159     assert(Kind == Register && "Invalid access!");
  164     assert(Kind == Prefix && "Invalid access!");
  169     assert(Kind == Immediate && "Invalid access!");
  174     assert(Kind == Memory && "Invalid access!");
  178     assert(Kind == Memory && "Invalid access!");
  182     assert(Kind == Memory && "Invalid access!");
  186     assert(Kind == Memory && "Invalid access!");
  190     assert(Kind == Memory && "Invalid access!");
  194     assert(Kind == Memory && "Invalid access!");
  198     assert(Kind == Memory && "Invalid access!");
  318     assert(Kind == Memory && "Invalid access!");
  497     assert(N == 1 && "Invalid number of operands!");
  502     assert(N == 1 && "Invalid number of operands!");
  510     assert(N == 1 && "Invalid number of operands!");
  515     assert(N == 1 && "Invalid number of operands!");
  520     assert(N == 1 && "Invalid number of operands!");
  544     assert((N == 5) && "Invalid number of operands!");
  553     assert((N == 1) && "Invalid number of operands!");
  562     assert((N == 2) && "Invalid number of operands!");
  568     assert((N == 1) && "Invalid number of operands!");
  573     assert((N == 2) && "Invalid number of operands!");
  650     assert((SegReg || BaseReg || IndexReg) && "Invalid memory operand!");
  653     assert(((Scale == 1 || Scale == 2 || Scale == 4 || Scale == 8)) &&
lib/Target/X86/Disassembler/X86Disassembler.cpp
  339     assert(insn.mode == MODE_16BIT);
  364     assert(insn.mode == MODE_16BIT);
lib/Target/X86/MCTargetDesc/X86ATTInstPrinter.cpp
  378     assert(Op.isExpr() && "unknown operand kind in printOperand");
  401     assert(DispSpec.isExpr() && "non-immediate displacement for LEA?");
  462     assert(DispSpec.isExpr() && "non-immediate displacement?");
lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp
  100     assert(unsigned(Kind - FirstTargetFixupKind) < getNumFixupKinds() &&
  102     assert(Infos[Kind - FirstTargetFixupKind].Name && "Empty fixup name!");
  115     assert(Fixup.getOffset() + Size <= Data.size() && "Invalid fixup offset!");
  121     assert((Size == 0 || isIntN(Size * 8 + 1, Value)) &&
  711     assert((RegEnc & 0x3FFFF) == RegEnc &&
  781     assert((permutationEncoding & 0x3FF) == permutationEncoding &&
lib/Target/X86/MCTargetDesc/X86ELFObjectWriter.cpp
  137     assert(Type == RT64_64);
  138     assert(!IsPCRel);
  141     assert(!IsPCRel);
  155     assert(!IsPCRel);
  169     assert(!IsPCRel);
  260     assert(Type == RT32_32);
  272     assert(Type == RT32_32);
  273     assert(!IsPCRel);
  280     assert(Type == RT32_32);
  281     assert(!IsPCRel);
  284     assert(Type == RT32_32);
  285     assert(!IsPCRel);
  288     assert(Type == RT32_32);
  289     assert(!IsPCRel);
  292     assert(Type == RT32_32);
  293     assert(!IsPCRel);
  296     assert(Type == RT32_32);
  299     assert(Type == RT32_32);
  300     assert(!IsPCRel);
  303     assert(Type == RT32_32);
  304     assert(!IsPCRel);
  307     assert(Type == RT32_32);
  308     assert(!IsPCRel);
  311     assert(Type == RT32_32);
  312     assert(!IsPCRel);
  326   assert((getEMachine() == ELF::EM_386 || getEMachine() == ELF::EM_IAMCU) &&
lib/Target/X86/MCTargetDesc/X86InstPrinterCommon.cpp
  300     assert(Op.isExpr() && "unknown pcrel immediate operand");
lib/Target/X86/MCTargetDesc/X86IntelInstPrinter.cpp
  338     assert(Op.isExpr() && "unknown operand kind in printOperand");
  372     assert(DispSpec.isExpr() && "non-immediate displacement for LEA?");
  421     assert(DispSpec.isExpr() && "non-immediate displacement?");
lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp
  151   assert(Triple.isOSWindows() && "Windows is the only supported COFF target");
lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp
  117     assert(Mod < 4 && RegOpcode < 8 && RM < 8 && "ModRM Fields out of range!");
  169   assert(((TSFlags & X86II::EncodingMask) == X86II::EVEX) &&
  180   assert((CD8_Scale & Mask) == 0 && "Invalid memory object size.");
  218     assert(IndexReg.getReg() == 0 && "Invalid eip-based address.");
  323       assert(ImmOffset == 0);
  328         assert(Size == 4);
  392     assert(is64BitMode(STI) && "Rip-relative addressing requires 64-bit mode");
  393     assert(IndexReg.getReg() == 0 && "Invalid rip-relative address");
  405         assert(Rex);
  460       assert(RMfield && "invalid 16-bit base register");
  465         assert(IndexReg16 && "invalid 16-bit index register");
  467         assert(((IndexReg16 ^ RMfield) & 2) &&
  469         assert(Scale.getImm() == 1 &&
  575   assert(IndexReg.getReg() != X86::ESP &&
  647   assert(!(TSFlags & X86II::LOCK) && "Can't have LOCK VEX.");
  898         assert(RcOperand >= CurOp);
  900         assert(EVEX_rc <= 3 && "Invalid rounding control!");
 1011     assert(Encoding == X86II::EVEX && "unknown encoding!");
 1017     assert((VEX_5M & 0x3) == VEX_5M
 1187     assert(!(TSFlags & X86II::REX_W) && "REX.W requires 64bit mode.");
 1269     assert(!Is16BitMemOperand(MI, MemoryOperand, STI));
 1272     assert(!Is64BitMemOperand(MI, MemoryOperand));
 1275     assert(is16BitMode(STI));
 1276     assert(!Is64BitMemOperand(MI, MemoryOperand));
 1304     assert(((siReg == X86::SI && MI.getOperand(0).getReg() == X86::DI) ||
 1345     assert(OpcodeOffset < 16 && "Unexpected opcode offset!");
 1458     assert(HasVEX_I8Reg && "MRMSrcRegOp4 should imply VEX_I8Reg");
 1512     assert(HasVEX_I8Reg && "MRMSrcRegOp4 should imply VEX_I8Reg");
 1616     assert(I8RegNum < 16 && "Register encoding out of range");
 1620       assert(Val < 16 && "Immediate operand value out of range");
lib/Target/X86/MCTargetDesc/X86MCTargetDesc.cpp
  421   assert(Mask.getBitWidth() == NumDefs + NumImplicitDefs &&
  777   assert(Res != X86::NoRegister && "Unexpected register or VT");
lib/Target/X86/MCTargetDesc/X86MachObjectWriter.cpp
  471   assert(SymA->getKind() == MCSymbolRefExpr::VK_TLVP && !is64Bit() &&
lib/Target/X86/MCTargetDesc/X86WinCOFFTargetStreamer.cpp
  321   assert((StackAlign == 0 || FrameReg != 0) &&
  396   assert(FPO->Begin && FPO->End && FPO->PrologueEnd && "missing FPO label");
lib/Target/X86/Utils/X86ShuffleDecode.cpp
   48   assert((Idx + Len) <= NumElts && "Insertion out of range");
  138   assert(isPowerOf2_32(NumElts) && "NumElts should be power of 2");
  340   assert(RawMask.size() == 16 && "Illegal VPPERM shuffle mask size");
  389   assert(SrcScalarBits < DstScalarBits &&
  498   assert((VecSize == 128 || VecSize == 256 || VecSize == 512) &&
  500   assert((ScalarBits == 32 || ScalarBits == 64) && "Unexpected element size");
  520   assert((VecSize == 128 || VecSize == 256) && "Unexpected vector size");
  521   assert((ScalarBits == 32 || ScalarBits == 64) && "Unexpected element size");
  522   assert((NumElts == RawMask.size()) && "Unexpected mask size");
lib/Target/X86/X86AsmPrinter.cpp
  310     assert(IndexReg.getReg() != X86::ESP &&
  330   assert(isMem(*MI, OpNo) && "Invalid memory reference!");
lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
  292   assert(AddrOffset != -1 && "Expected Memory Operand");
  430   assert(StoreSrcVReg.isReg() && "Expected virtual register");
  494   assert(Size == 0 && "Wrong size division");
  553           assert(MI.hasOneMemOperand() &&
  555           assert(StoreMI.hasOneMemOperand() &&
  678   assert(MRI->isSSA() && "Expected MIR to be in SSA form");
  699       assert(PBInst->hasOneMemOperand() && "Expected One Memory Operand");
lib/Target/X86/X86AvoidTrailingCall.cpp
   63   assert(STI.isTargetWin64() && "pass only runs on Win64");
lib/Target/X86/X86CallFrameOptimization.cpp
  245   assert(isPowerOf2_32(SlotSize) && "Expect power of 2 stack slot size");
  363   assert(I->getOpcode() == TII->getCallFrameSetupOpcode());
  437     assert(StackDisp >= 0 &&
  445     assert((size_t)StackDisp < Context.ArgStoreVector.size() &&
lib/Target/X86/X86CallLowering.cpp
   64   assert(OrigArg.Regs.size() == 1 && "Can't handle multple regs yet");
  140       assert((PhysRegSize == 128 || PhysRegSize == 80)  && "We expect that to be 128 bit");
  190   assert(((Val && !VRegs.empty()) || (!Val && VRegs.empty())) &&
  204     assert(VRegs.size() == SplitEVTs.size() &&
lib/Target/X86/X86CallingConv.cpp
   57     assert(Reg && "Expecting a register will be available");
  105       assert(AssigedReg == Reg && "Expecting a valid register allocation");
  268   assert(ArgFlags.isSplitEnd());
lib/Target/X86/X86CmovConversion.cpp
  595   assert(X86::getCondFromCMov(*Last) != X86::COND_INVALID &&
  612   assert(!Group.empty() && "No CMOV instructions to convert");
  729     assert(X86::getCondFromCMov(MI) == OppCC &&
  763     assert(Unfolded && "Should never fail to unfold a loading cmov!");
  768     assert(X86::getCondFromCMov(*NewCMOV) == OppCC &&
lib/Target/X86/X86CondBrFolding.cpp
  142   assert(MBBInfo && "Expecting a candidate MBB");
  152     assert(SaveMBB == PredMBBInfo->TBB || SaveMBB == PredMBBInfo->FBB);
  156     assert(CC == X86::COND_L || CC == X86::COND_G || CC == X86::COND_E);
  285   assert(MBBInfo && "Expecting a candidate MBB");
  292   assert(PredMBBInfo && "Expecting a candidate MBB");
  303   assert(RootMBBInfo && "Expecting a candidate MBB");
lib/Target/X86/X86DiscriminateMemOps.cpp
  100   assert(ReferenceDI && "ReferenceDI should not be nullptr");
  163         assert(DI && "DI should not be nullptr");
  169         assert(MustInsert.second && "New discriminator shouldn't be present in set");
lib/Target/X86/X86DomainReassignment.cpp
   68   assert(Domain == MaskDomain && "add domain");
   94     assert(MI->getOpcode() == SrcOpcode &&
  119     assert(isLegal(MI, TII) && "Cannot convert instruction");
  153     assert(isLegal(MI, TII) && "Cannot convert instruction");
  181     assert(isLegal(MI, TII) && "Cannot convert instruction");
  238     assert(MI->getOpcode() == TargetOpcode::COPY && "Expected a COPY");
  269     assert(isLegal(MI, TII) && "Cannot convert instruction");
  483   assert(C.isLegal(DstDomain) && "Cannot calculate cost for illegal closure");
  498   assert(C.isLegal(Domain) && "Cannot convert illegal closure");
  740   assert(MRI->isSSA() && "Expected MIR to be in SSA form");
lib/Target/X86/X86EvexToVex.cpp
  136     assert(!(Reg >= X86::ZMM0 && Reg <= X86::ZMM31) &&
  155     assert((NewOpc == X86::VPALIGNRrri || NewOpc == X86::VPALIGNRrmi) &&
  171     assert((NewOpc == X86::VPERM2F128rr || NewOpc == X86::VPERM2I128rr ||
  240     assert(std::is_sorted(std::begin(X86EvexToVex128CompressTable),
  243     assert(std::is_sorted(std::begin(X86EvexToVex256CompressTable),
lib/Target/X86/X86ExpandPseudo.cpp
  199     assert(StackAdjust.isImm() && "Expecting immediate value.");
  205     assert(MaxTCDelta <= 0 && "MaxTCDelta should never be positive");
  209     assert(Offset >= 0 && "Offset should never be negative");
  212       assert(Offset == 0 && "Conditional tail call cannot adjust the stack.");
  234         assert(!MBB.getParent()->hasWinCFI() &&
  250         assert(JumpTarget.isSymbol());
  288     assert(DestAddr.isReg() && "Offset should be in register!");
  320       assert(!STI->is64Bit() &&
lib/Target/X86/X86FastISel.cpp
  404     assert(HasAVX);
  415     assert(HasAVX);
  429     assert(HasAVX);
  440     assert(HasAVX512);
  447     assert(HasAVX512);
  457     assert(HasAVX512);
  579     assert(HasAVX);
  589     assert(HasAVX);
  602     assert(HasAVX);
  612     assert(HasAVX512);
  619     assert(HasAVX512);
  629     assert(HasAVX512);
  754           assert(AM.Base.Reg == 0 && AM.IndexReg == 0);
  817       assert(AM.Scale == 1 && "Scale with no index!");
 1074       assert(AM.Base.Reg == 0 && AM.IndexReg == 0);
 1090       assert(AM.Scale == 1 && "Scale with no index!");
 1231       assert(DstVT == MVT::i32 && "X86 should always ext to i32");
 1267     assert(Reg &&
 1504   assert(CC <= X86::LAST_VALID_COND && "Unexpected condition code.");
 1685       assert(CC <= X86::LAST_VALID_COND && "Unexpected condition code.");
 2055     assert(CC <= X86::LAST_VALID_COND && "Unexpected condition code.");
 2471   assert((I->getOpcode() == Instruction::FPExt ||
 2589     assert(RV && "Failed to emit load or store??");
 2646       assert(Op->getType()->isIntegerTy(16) && "Expected a 16-bit integer!");
 2695     assert(((FrameReg == X86::RBP && VT == MVT::i64) ||
 2785     assert(DI->getAddress() && "Null address should be checked earlier!");
 2791     assert(DI->getVariable()->isValidLocationForIntrinsic(DbgLoc) &&
 2869     assert(Ty->getTypeAtIndex(1)->isIntegerTy() &&
 2977     assert((ResultReg+1) == ResultReg2 && "Nonconsecutive result registers.");
 3332       assert(VA.getLocVT().isInteger() && !VA.getLocVT().isVector() &&
 3340       assert(Emitted && "Failed to emit a sext!"); (void)Emitted;
 3345       assert(VA.getLocVT().isInteger() && !VA.getLocVT().isVector() &&
 3360       assert(Emitted && "Failed to emit a zext!"); (void)Emitted;
 3365       assert(VA.getLocVT().isInteger() && !VA.getLocVT().isVector() &&
 3376       assert(Emitted && "Failed to emit a aext!"); (void)Emitted;
 3383       assert(ArgReg && "Failed to emit a bitcast!");
 3408       assert(VA.isMemLoc());
 3465     assert((Subtarget->hasSSE1() || !NumXMMRegs)
 3495     assert(GV && "Not a direct call");
 3875   assert(C->isStaticAlloca() && "dynamic alloca in the static alloca map?");
lib/Target/X86/X86FixupBWInsts.cpp
  253     assert((MO.isDef() || MO.isUse()) && "Expected Def or Use only!");
  300   assert(MI->getNumExplicitOperands() == 2);
lib/Target/X86/X86FixupLEAs.cpp
  635   assert(DestReg != BaseReg && "DestReg == BaseReg should be handled already!");
  636   assert(IsInefficientBase && "efficient base should be handled already!");
lib/Target/X86/X86FlagsCopyLowering.cpp
  242   assert(SplitI.getParent() == &MBB &&
  244   assert(SplitI.isBranch() &&
  246   assert(X86::getCondFromBranch(SplitI) != X86::COND_INVALID &&
  251   assert(PrevI.isBranch() && "Must split after a branch!");
  252   assert(X86::getCondFromBranch(PrevI) != X86::COND_INVALID &&
  254   assert(!std::prev(PrevI.getIterator())->isTerminator() &&
  266                     assert(MI.isTerminator() &&
  300   assert(MBB.isSuccessor(&NewMBB) &&
  313         assert(OpMBB.isMBB() && "Block operand to a PHI is not a block!");
  368     assert(VOp.isReg() &&
  403     assert(DOp.isDef() && "Expected register def!");
  404     assert(DOp.getReg() == X86::EFLAGS && "Unexpected copy def register!");
  437       assert(MDT->dominates(BeginMBB, EndMBB) &&
  546           assert(&UseMBB == &MBB && VisitedBlocks.count(&MBB) &&
  602           assert(MI.findRegisterDefOperand(X86::EFLAGS) &&
  727       assert(MI.getOperand(0).isDef() &&
  897   assert(SetBI.getOperand(0).isReg() &&
  924     assert(OrigRegSize <= 8 && "No GPRs larger than 64-bits!");
  925     assert(TargetRegSize <= 8 && "No GPRs larger than 64-bits!");
 1027     assert(SetCCI.getOperand(0).isReg() &&
lib/Target/X86/X86FloatingPoint.cpp
  176         assert(RegMap[Stack[i]] == i && "Stack[] doesn't match RegMap[]!");
  184       assert(RegNo < NumFPRegs && "Regno out of range!");
  209       assert(Reg < NumFPRegs && "Register number out of range!");
  315   assert(MO.isReg() && "Expected an FP register!");
  317   assert(Reg >= X86::FP0 && Reg <= X86::FP6 && "Expected FP register!");
  366     assert((Bundle.Mask & 0xFE) == 0 &&
  393   assert(LiveBundles.empty() && "Stale data in LiveBundles");
  521   assert(Bundle.isFixed() && "Reached block before any predecessors");
  792   assert(Opc != -1 && "FP Stack instruction not in OpcodeTable!");
  897   assert((Kills & Defs) == 0 && "Register needs killing and def'ing?");
  943   assert(StackTop == countPopulation(Mask) && "Live count mismatch");
  985         assert(MO.isDef() && MO.isImplicit());
  996   assert(STReturns == 0 || (isMask_32(STReturns) && N <= 2));
 1023     assert(Op.isUse() &&
 1032       assert(SecondFPRegOp == ~0U && "More than two fp operands!");
 1054     assert(StackTop == 1 && FirstFPRegOp == getStackEntry(0) &&
 1068     assert(FirstFPRegOp == SecondFPRegOp && FirstFPRegOp == getStackEntry(0)&&
 1079   assert(StackTop == 2 && "Must have two values live!");
 1084     assert(getStackEntry(1) == FirstFPRegOp && "Unknown regs live");
 1090   assert(getStackEntry(0) == FirstFPRegOp && "Unknown regs live");
 1091   assert(getStackEntry(1) == SecondFPRegOp && "Unknown regs live");
 1116   assert((NumOps == X86::AddrNumOperands + 1 || NumOps == 1) &&
 1177   assert(NumOps >= 2 && "FPRW instructions must have 2 ops!!");
 1288   assert(NumOperands == 3 && "Illegal TwoArgFP instruction!");
 1331   assert((TOS == Op0 || TOS == Op1) && (KillsOp0 || KillsOp1) &&
 1352   assert(Opcode != -1 && "Unknown TwoArgFP pseudo instruction!");
 1364     assert(!updateST0 && "Should have updated other operand!");
 1371   assert(UpdatedSlot < StackTop && Dest < 7);
 1384   assert(NumOperands == 2 && "Illegal FUCOM* instruction!");
 1461     assert(isLive(SrcFP) && "Cannot copy dead register");
 1594         assert((1 << getFPReg(MI.getOperand(I)) & STDefs) == 0 &&
lib/Target/X86/X86FrameLowering.cpp
  291       assert(Is64Bit && "can't have 32-bit 16GB stack frame");
  349   assert(Offset != 0 && "zero offset stack adjustment requested");
  371     assert((UseLEA || !flagsNeedToBePreservedBeforeTheTerminators(MBB)) &&
  424     assert(PI->getOperand(1).getReg() == StackPtr);
  437     assert(PI->getOperand(1).getReg() == StackPtr);
  514     assert(!ChkStkStub->isBundled() &&
  517     assert(std::prev(MBBI) == ChkStkStub &&
  531   assert(STI.is64Bit() && "different expansion needed for 32 bit");
  532   assert(STI.isTargetWindowsCoreCLR() && "custom expansion expects CoreCLR");
  828   assert(InProlog && "ChkStkStub called outside prolog!");
  878   assert(&STI == &MF.getSubtarget<X86Subtarget>() &&
  973   assert(&STI == &MF.getSubtarget<X86Subtarget>() &&
 1095     assert(MF.getRegInfo().isReserved(MachineFramePtr) && "FP reserved");
 1117       assert(StackSize);
 1160     assert(!IsFunclet && "funclets without FPs not yet implemented");
 1194       assert(StackSize);
 1212     assert(HasFP && "There should be a frame pointer if stack is realigned.");
 1242     assert(!X86FI->getUsesRedZone() &&
 1358       assert(!NeedsWinFPO && "this setframe incompatible with FPO data");
 1373       assert(Personality == EHPersonality::MSVC_CXX);
 1401           assert(!NeedsWinFPO && "SEH_SaveXMM incompatible with FPO data");
 1434     assert(HasFP && "There should be a frame pointer if stack is realigned.");
 1471       assert(UsedReg == BasePtr);
 1482       assert(StackSize);
 1548   assert(Offset >= 0 && SPReg == TRI->getStackRegister());
 1623     assert(HasFP && "EH funclets without FP not yet implemented");
 1751     assert(Offset >= 0 && "TCDelta should never be positive");
 1797     assert(!MFI.hasCalls() || (StackSize % 16) == 8);
 1815     assert((!MFI.hasCalls() || (FPDelta % 16) == 0) &&
 1821     assert(HasFP && "VLAs and dynamic stack realign, but no FP?!");
 1826       assert((-(Offset + StackSize)) % MFI.getObjectAlignment(FI) == 0);
 1834       assert((-(Offset + StackSize)) % MFI.getObjectAlignment(FI) == 0);
 1928   assert(MF.getInfo<X86MachineFunctionInfo>()->getTCReturnAddrDelta() >= 0 &&
 2045     assert(SpillSlotOffset < 0 && "SpillSlotOffset should always < 0 on X86");
 2140   assert(!isAsynchronousEHPersonality(classifyEHPersonality(
 2297   assert(&(*MF.begin()) == &PrologueMBB && "Shrink-wrapping not supported yet");
 2300   assert(!MF.getRegInfo().isLiveIn(ScratchReg) &&
 2431       assert((!MF.getRegInfo().isLiveIn(ScratchReg2) || SaveScratch2) &&
 2588   assert(&(*MF.begin()) == &PrologueMBB && "Shrink-wrapping not supported yet");
 2605   assert(STI.isTargetLinux() &&
 2686     assert(!MF.getRegInfo().isLiveIn(ScratchReg) &&
 2906   assert(MBB.getParent() && "Block is not attached to a function!");
 2912   assert(MBB.getParent() && "Block is not attached to a function!");
 2947   assert(STI.isTargetWindowsMSVC() && "funclets only supported in MSVC env");
 2948   assert(STI.isTargetWin32() && "EBP/ESI restoration only required on win32");
 2949   assert(STI.is32Bit() && !Uses64BitFramePtr &&
 2985     assert(EndOffset >= 0 &&
 2993     assert(X86FI->getHasSEHFramePtrSave());
 2996     assert(UsedReg == BasePtr);
lib/Target/X86/X86ISelDAGToDAG.cpp
  191       assert((!OptForMinSize || OptForSize) &&
  305         assert(!AM.Disp && "Non-zero displacement is ignored with ES.");
  308         assert(!AM.Disp && "Non-zero displacement is ignored with MCSym.");
  309         assert(AM.SymbolFlags == 0 && "oo");
  312         assert(!AM.Disp && "Non-zero displacement is ignored with JT.");
  424       assert((VecWidth == 128 || VecWidth == 256) && "Unexpected vector width");
  432       assert((VecWidth == 128 || VecWidth == 256) && "Unexpected vector width");
  441       assert(N->getOpcode() == ISD::AND && "Unexpected opcode");
  724     assert(Chain.getOpcode() == ISD::TokenFactor &&
 1757     assert(X.getValueType() != VT);
 1948     assert(N.getSimpleValueType().getSizeInBits() <= 64 &&
 2101     assert(N.getSimpleValueType().getSizeInBits() <= 64 &&
 2418     assert(Index.getValueType() == MVT::i32 &&
 2448   assert (T == AM.Segment);
 2524   assert(N.getOpcode() == ISD::TargetGlobalTLSAddress);
 2589   assert(Root && P && "Unknown root/parent nodes");
 2603   assert(Root && P && "Unknown root/parent nodes");
 2638   assert(N->isMachineOpcode() && "Unexpected node");
 3188   assert(
 3216       assert(V.getSimpleValueType() == MVT::i32 &&
 3415     assert(ShiftAmt.getValueType() == MVT::i8 &&
 3515     assert(Subtarget->hasBMI2() && "We must have BMI2's BZHI then.");
 3534       assert(Subtarget->hasBMI() && "We must have BMI1's BEXTR then.");
 3842   assert((Node->getOpcode() == ISD::ADD || Node->getOpcode() == ISD::SUB) &&
 3846   assert(VT.isVector() && "Should only be called for vectors.");
 3859   assert(VT.getSizeInBits() % 32 == 0 &&
 3865   assert(NumElts > 0 && "Expected to get non-empty vector.");
 4112   assert(Subtarget->hasAVX512() && "Expected AVX512!");
 4113   assert(Setcc.getSimpleValueType().getVectorElementType() == MVT::i1 &&
 4245     assert(!FoldedLoad && "Shouldn't have folded the load");
 4303   assert(N->getOpcode() == ISD::OR && "Unexpected opcode!");
 4428       assert(Target.getSimpleValueType() == llvm::MVT::i32);
 4458     assert(Subtarget->hasSSE41() && "Expected SSE4.1 support!");
 4771       assert(LoReg && "Register for low half is not defined!");
 4781       assert(HiReg && "Register for high half is not defined!");
lib/Target/X86/X86ISelLowering.cpp
 1743       assert(isOperationCustom(ISD::UINT_TO_FP, MVT::v2f32) &&
 2222   assert(isPositionIndependent() && Subtarget.isPICStyleGOT());
 2384   assert(SrcAS != DestAS && "Expected different address spaces!");
 2443   assert(Subtarget.hasBWI() && "Expected AVX512BW target!");
 2444   assert(Subtarget.is32Bit() && "Expecting 32 bit target");
 2445   assert(Arg.getValueType() == MVT::i64 && "Expecting 64 bit value");
 2446   assert(VA.isRegLoc() && NextVA.isRegLoc() &&
 2497     assert(VA.isRegLoc() && "Can only return in registers!");
 2520     assert(VA.getLocInfo() != CCValAssign::FPExt &&
 2571       assert(VA.getValVT() == MVT::v64i1 &&
 2577       assert(2 == RegsToPass.size() &&
 2737   assert((Subtarget.hasBWI()) && "Expected AVX512BW target!");
 2738   assert(Subtarget.is32Bit() && "Expecting 32 bit target");
 2739   assert(VA.getValVT() == MVT::v64i1 &&
 2741   assert(NextVA.getValVT() == VA.getValVT() &&
 2743   assert(VA.isRegLoc() && NextVA.isRegLoc() &&
 2794     assert(ValLoc == MVT::i64 && "Expecting only i64 locations");
 2872       assert(VA.getValVT() == MVT::v64i1 &&
 3119   assert(Subtarget.is64Bit());
 3138   assert(Subtarget.is64Bit());
 3150   assert(!(isSoftFloat && NoImplicitFloatOps) &&
 3190   assert(
 3212   assert(isSortedByValueNo(ArgLocs) &&
 3218     assert(InsIndex < Ins.size() && "Invalid Ins index");
 3224         assert(
 3301       assert(VA.isMemLoc());
 3353   assert(!(Subtarget.useSoftFloat() &&
 3365     assert(!(NumXMMRegs && !Subtarget.hasSSE1()) &&
 3513       assert(Is64Bit);
 3674   assert(!(isVarArg && canGuaranteeTCO(CallConv)) &&
 3747   assert(isSortedByValueNo(ArgLocs) &&
 3755     assert(OutIndex < Outs.size() && "Invalid Out index");
 3820       assert(VA.getValVT() == MVT::v64i1 &&
 3843       assert(VA.isMemLoc());
 3896     assert((Subtarget.hasSSE1() || !NumXMMRegs)
 3933           assert((CallConv == CallingConv::X86_RegCall) &&
 3943       assert(VA.isMemLoc());
 3994     assert(Is64Bit && "Large code model is only legal in 64-bit mode.");
 4041   assert(Mask && "Missing call preserved mask for calling convention");
 4273   assert(FI != INT_MAX);
 4862   assert(cast<LoadSDNode>(Load)->isSimple() && "illegal to narrow");
 4897   assert(Ty->isIntegerTy());
 5115   assert(((N->getOpcode() == ISD::SHL &&
 5329   assert(WidenedMask.size() == Mask.size() / 2 &&
 5393   assert(Bits.size() == Undefs.getBitWidth() &&
 5413     assert(V.getBitWidth() == VT.getScalarSizeInBits() && "Unexpected sizes");
 5435   assert((VT.is128BitVector() || VT.is256BitVector() || VT.is512BitVector() ||
 5448     assert((Subtarget.hasBWI() || VT.getVectorNumElements() <= 16) &&
 5468   assert(isPowerOf2_32(ElemsPerChunk) && "Elements per chunk not power of 2");
 5491   assert((Vec.getValueType().is256BitVector() ||
 5499   assert(Vec.getValueType().is512BitVector() && "Unexpected vector size!");
 5506   assert((vectorWidth == 128 || vectorWidth == 256) &&
 5517   assert(isPowerOf2_32(ElemsPerChunk) && "Elements per chunk not power of 2");
 5535   assert(Vec.getValueType().is128BitVector() && "Unexpected vector size!");
 5544   assert(Vec.getValueSizeInBits() < VT.getSizeInBits() &&
 5558   assert(Vec.getValueSizeInBits() < WideSizeInBits &&
 5571   assert(Ops.empty() && "Expected an empty ops vector");
 5612   assert(Subtarget.hasSSE2() && "Target assumed to support at least SSE2");
 5618       assert((VT.getSizeInBits() % 512) == 0 && "Illegal vector size");
 5623       assert((VT.getSizeInBits() % 256) == 0 && "Illegal vector size");
 5628       assert((VT.getSizeInBits() % 128) == 0 && "Illegal vector size");
 5692   assert(IdxVal + SubVecNumElems <= NumElems &&
 5717     assert(IdxVal != 0 && "Unexpected index");
 5724     assert(IdxVal != 0 && "Unexpected index");
 5799   assert(V1.getValueType() == V2.getValueType() && "subvector type mismatch");
 5813   assert((VT.is128BitVector() || VT.is256BitVector() || VT.is512BitVector()) &&
 5841   assert(VT.isVector() && InVT.isVector() && "Expected vector VTs.");
 5842   assert((ISD::ANY_EXTEND == Opcode || ISD::SIGN_EXTEND == Opcode ||
 5849     assert(VT.getSizeInBits() == InVT.getSizeInBits() &&
 5949   assert(LD && "Unexpected null LoadSDNode");
 5959   assert(EltBits.empty() && "Expected an empty EltBits vector");
 5965   assert((SizeInBits % EltSizeInBits) == 0 && "Can't split constant!");
 5972     assert((NumSrcElts * SrcEltSizeInBits) == SizeInBits &&
 6340   assert(Mask.empty() && "Expected an empty shuffle mask vector");
 6423   assert(Mask.empty() && "getTargetShuffleMask expects an empty Mask vector");
 6424   assert(Ops.empty() && "getTargetShuffleMask expects an empty Ops vector");
 6430     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6431     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6437     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6438     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6445     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6446     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6452     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6462     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6463     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6473     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6474     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6479     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6480     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6485     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6486     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6491     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6492     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6497     assert(VT.getScalarType() == MVT::i8 && "Byte vector expected");
 6498     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6499     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6508     assert(VT.getScalarType() == MVT::i8 && "Byte vector expected");
 6509     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6516     assert(VT.getScalarType() == MVT::i8 && "Byte vector expected");
 6517     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6525     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6532     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6539     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6546     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6570     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6581     assert(VT.getScalarType() == MVT::i8 && "Byte vector expected");
 6582     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6583     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6593     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6600     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6601     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6605     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6606     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6613     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6614     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6621     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6626     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6631     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6636     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6637     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6653     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6654     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6664     assert(N->getOperand(1).getValueType() == VT && "Unexpected value type");
 6677     assert(N->getOperand(0).getValueType() == VT && "Unexpected value type");
 6678     assert(N->getOperand(2).getValueType() == VT && "Unexpected value type");
 6744   assert((VT.getSizeInBits() % Mask.size()) == 0 &&
 6762       assert(isUndefOrZero(M) && "Unknown shuffle sentinel value!");
 6805   assert(VT.getVectorNumElements() == (unsigned)Size &&
 6815   assert(KnownUndef.getBitWidth() == NumElts &&
 6866   assert(NumElts == DemandedElts.getBitWidth() && "Unexpected vector size");
 7004       assert(((SubMask.size() % NumSubElts) == 0 ||
 7114     assert(N0.getValueType().getVectorNumElements() == (NumElts / 2) &&
 7186       assert((NumSizeInBits % SrcVT.getSizeInBits()) == 0 &&
 7218       assert((NumSizeInBits % SrcVT.getSizeInBits()) == 0 &&
 7361     assert(0 <= Elt && Elt < (2*NumElems) && "Shuffle index out of range");
 7416   assert(((VT == MVT::v8i16 && Subtarget.hasSSE2()) ||
 7437         assert(0 == i && "Expected insertion into zero-index");
 7559   assert(Zeroable.size() - Zeroable.count() > 1 &&
 7583   assert(FirstNonZero.getNode() && "Unexpected build vector of all zeros!");
 7639   assert(V1.getNode() && "Expected at least two non-zero elements!");
 7649   assert((InsertPSMask & ~0xFFu) == 0 && "Invalid mask!");
 7660   assert(VT.is128BitVector() && "Unknown type for VShift");
 7664   assert(NumBits % 8 == 0 && "Only support byte sized shifts");
 7837   assert((ZeroMask.countPopulation() + UndefMask.countPopulation() +
 7854   assert(EltBaseVT.getSizeInBits() == EltBaseVT.getStoreSizeInBits() &&
 7857   assert(LDBase && "Did not find base load for merging consecutive loads");
 7861   assert((BaseSizeInBits % 8) == 0 && "Sub-byte element loads detected");
 7900     assert(LDBase->isSimple() &&
 8065   assert(Elts.size() == VT.getVectorNumElements());
 8083         assert(ScalarSize == 64 && "Unsupported floating point scalar size");
 8167   assert((VT.is128BitVector() || VT.is256BitVector() || VT.is512BitVector()) &&
 8319     assert(!CVT.isVector() && "Must not broadcast a vector type");
 8333       assert(C && "Invalid constant type");
 8398   assert(ShuffleVecVT.getVectorElementType() ==
 8482   assert(ISD::isBuildVectorOfConstantSDNodes(Op.getNode()) &&
 8500   assert((VT.getVectorElementType() == MVT::i1) &&
 8536     assert(Cond.getValueType() == MVT::i8 && "Unexpected VT!");
 8599   assert(VT.is256BitVector() && "Only use for matching partial 256-bit h-ops");
 8600   assert(BaseIdx * 2 <= LastIdx && "Invalid Indices in input!");
 8601   assert(VT.isVector() && VT.getVectorNumElements() >= LastIdx &&
 8713   assert(VT.is256BitVector() && VT == V1.getSimpleValueType() &&
 9139       assert((!V0.isUndef() || !V1.isUndef()) && "Horizontal-op of undefs?");
 9290   assert(IndicesVec.getValueType().getVectorNumElements() >= NumElts &&
 9317     assert(isPowerOf2_64(Scale) && "Illegal variable permute shuffle scale");
 9508   assert((VT.getSizeInBits() == ShuffleVT.getSizeInBits()) &&
 9627       assert(i < sizeof(NonZeros) * 8); // Make sure the shift is within range.
 9661         assert(!VarElt.getNode() && !InsIndex.getNode() &&
 9687     assert(VT.getSizeInBits() > 128 && "Invalid insertion index?");
 9688     assert(Subtarget.hasAVX() && "Must have AVX with >16-byte vector");
 9712         assert((VT.is128BitVector() || VT.is256BitVector() ||
 9896   assert(Values.size() > 1 && "Expected non-undef and non-splat vector");
 9956   assert((ResVT.is256BitVector() ||
 9970       assert(i < sizeof(NonZeros) * CHAR_BIT); // Ensure the shift is in range.
10016   assert(NumOperands > 1 && isPowerOf2_32(NumOperands) &&
10025     assert(i < sizeof(NonZeros) * CHAR_BIT); // Ensure the shift is in range.
10076   assert(countPopulation(NonZeros) == 2 && "Simple cases not handled?");
10095   assert((VT.is256BitVector() && Op.getNumOperands() == 2) ||
10126     assert(Mask[i] >= -1 && "Out of bound mask element!");
10165     assert(Mask[i] == SM_SentinelUndef || Mask[i] >= 0);
10215     assert(isUndefOrZero(Mask[i]) || (Mask[i] >= 0));
10265     assert(Mask[i] >= -1 && "Out of bound mask element!");
10295   assert(isUndefOrZeroOrInRange(ExpectedMask, 0, 2 * Size) &&
10390   assert(Mask.size() % 2 == 0 && "Expecting even number of elements in mask");
10408   assert(Mask.size() == 4 && "Only 4-lane shuffle masks");
10409   assert(Mask[0] >= -1 && Mask[0] < 4 && "Out of bound mask element!");
10410   assert(Mask[1] >= -1 && Mask[1] < 4 && "Out of bound mask element!");
10411   assert(Mask[2] >= -1 && Mask[2] < 4 && "Out of bound mask element!");
10412   assert(Mask[3] >= -1 && Mask[3] < 4 && "Out of bound mask element!");
10446   assert(!(VectorSizeInBits % ScalarSizeInBits) && "Illegal shuffle mask size");
10519     assert(Mask[i] >= -1 && "Out of bound mask element!");
10548   assert((Subtarget.hasSSSE3() && VT.is128BitVector()) ||
10583   assert(V && "Failed to find a source input");
10610   assert((NumElts == 4 || NumElts == 8 || NumElts == 16) &&
10635   assert(!((Undef1 || Zero1) && (Undef2 || Zero2)) &&
10953   assert(VT.isInteger() && "Only supports integer vector types!");
10986   assert(Mask.size() <= 64 && "Shuffle mask too big for blend mask");
11054     assert(Subtarget.hasAVX2() && "256-bit integer blends require AVX2!");
11058     assert(Subtarget.hasAVX() && "256-bit float blends require AVX!");
11065     assert(Subtarget.hasSSE41() && "128-bit blends require SSE41!");
11069     assert(Subtarget.hasAVX2() && "v16i16 blends require AVX2!");
11073       assert(RepeatedMask.size() == 8 && "Repeated mask size doesn't match!");
11098     assert(Subtarget.hasAVX2() && "256-bit byte-blends require AVX2!");
11101     assert(Subtarget.hasSSE41() && "128-bit byte-blends require SSE41!");
11202     assert(Mask[i] < Size * 2 && "Shuffle input is out of bounds.");
11263   assert((MatchLo ^ MatchHi) && "Failed to match UNPCKLO/UNPCKHI");
11319         assert(Lane <= M && M < (Lane + NumEltsPerLane) && "Out of range mask");
11326         assert(Lane <= M && M < (Lane + NumEltsPerLane) && "Out of range mask");
11442     assert((M == SM_SentinelUndef || (0 <= M && M < (2*NumElts))) &&
11483   assert(Rotation != 0 && "Failed to locate a viable rotation!");
11484   assert((Lo || Hi) && "Failed to find a rotated input vector!");
11538   assert(!isNoopShuffleMask(Mask) && "We shouldn't lower no-op shuffles!");
11553     assert((!VT.is512BitVector() || Subtarget.hasBWI()) &&
11560   assert(VT.is128BitVector() &&
11562   assert(Mask.size() <= 16 &&
11564   assert(ByteVT == MVT::v16i8 &&
11595   assert((VT.getScalarType() == MVT::i32 || VT.getScalarType() == MVT::i64) &&
11599   assert((Subtarget.hasVLX() || (!VT.is128BitVector() && !VT.is256BitVector()))
11615   assert(!isNoopShuffleMask(Mask) && "We shouldn't lower no-op shuffles!");
11616   assert(VT.is128BitVector() && "Only 128-bit vectors supported");
11765   assert(Size == (int)VT.getVectorNumElements() && "Unexpected mask size");
11785   assert(DAG.getTargetLoweringInfo().isTypeLegal(ShiftVT) &&
11800   assert(Size == (int)VT.getVectorNumElements() && "Unexpected mask size");
11801   assert(!Zeroable.isAllOnesValue() && "Fully zeroable shuffle mask");
11813   assert(Len > 0 && "Zeroable shuffle mask");
11841   assert((Idx + Len) <= HalfSize && "Illegal extraction mask");
11856   assert(Size == (int)VT.getVectorNumElements() && "Unexpected mask size");
11947   assert(Scale > 1 && "Need a scale to extend.");
11952   assert((EltBits == 8 || EltBits == 16 || EltBits == 32) &&
11954   assert(Scale * EltBits <= 64 && "Cannot zero extend past 64 bits.");
11955   assert(0 <= Offset && "Extension offset must be positive.");
11956   assert((Offset < NumEltsPerLane || Offset % NumEltsPerLane == 0) &&
11992   assert(VT.is128BitVector() && "Only 128-bit vectors can be extended.");
12021     assert(NumElements == (int)Mask.size() && "Unexpected shuffle mask size!");
12022     assert(VT.is128BitVector() && "Unexpected vector width!");
12046     assert(NumElements == 16 && "Unexpected byte vector width!");
12114   assert(VT.getScalarSizeInBits() <= 32 &&
12116   assert((int)Mask.size() == NumElements && "Unexpected shuffle mask size");
12182   assert(Bits % 64 == 0 &&
12189     assert(NumElements % NumExtElements == 0 &&
12311     assert(VT == ExtVT && "Cannot change extended type when non-zeroable!");
12322     assert((EltVT == MVT::f32 || EltVT == MVT::f64) &&
12364   assert(Subtarget.hasAVX2() &&
12370   assert(VT.isInteger() && "Unexpected non-integer trunc broadcast!");
12371   assert(V0VT.isVector() && "Unexpected non-vector vector-sized value!");
12384   assert(((V0EltSize % EltSize) == 0) &&
12415   assert(Mask.size() == 4 && "Unsupported mask size!");
12416   assert(Mask[0] >= -1 && Mask[0] < 8 && "Out of bound mask element!");
12417   assert(Mask[1] >= -1 && Mask[1] < 8 && "Out of bound mask element!");
12418   assert(Mask[2] >= -1 && Mask[2] < 8 && "Out of bound mask element!");
12419   assert(Mask[3] >= -1 && Mask[3] < 8 && "Out of bound mask element!");
12438   assert((VT.is128BitVector() &&
12519   assert(BroadcastIdx < (int)Mask.size() && "We only expect to be called with "
12562   assert((BitOffset % NumEltBits) == 0 && "Illegal bit-offset");
12604     assert((int)(Offset * 8) == BitOffset && "Unexpected bit-offset");
12628     assert((BitOffset % V.getScalarValueSizeInBits()) == 0 &&
12630     assert((V.getValueSizeInBits() == 256 || V.getValueSizeInBits() == 512) &&
12642     assert(NumEltBits == BroadcastVT.getScalarSizeInBits() &&
12684   assert(V1.getSimpleValueType().is128BitVector() && "Bad operand type!");
12685   assert(V2.getSimpleValueType().is128BitVector() && "Bad operand type!");
12686   assert(Mask.size() == 4 && "Unexpected mask size for v4 shuffle!");
12752     assert((InsertPSMask & ~0xFFu) == 0 && "Invalid mask!");
12771   assert(V1.getSimpleValueType() == MVT::v4f32 && "Bad operand type!");
12772   assert(V2.getSimpleValueType() == MVT::v4f32 && "Bad operand type!");
12796   assert(!VT.isFloatingPoint() &&
12798   assert(VT.is128BitVector() &&
12800   assert(!V2.isUndef() &&
12802   assert(Mask.size() >= 2 && "Single element masks are invalid.");
12873     assert((NumLoInputs > 0 || NumHiInputs > 0) &&
12887       assert(Mask[i] % Size >= HalfOffset && "Found input from wrong half!");
12912   assert(V1.getSimpleValueType() == MVT::v2f64 && "Bad operand type!");
12913   assert(V2.getSimpleValueType() == MVT::v2f64 && "Bad operand type!");
12914   assert(Mask.size() == 2 && "Unexpected mask size for v2 shuffle!");
12939   assert(Mask[0] >= 0 && "No undef lanes in multi-input v2 shuffles!");
12940   assert(Mask[1] >= 0 && "No undef lanes in multi-input v2 shuffles!");
12941   assert(Mask[0] < 2 && "We sort V1 to be the first input.");
12942   assert(Mask[1] >= 2 && "We sort V2 to be the second input.");
12996   assert(V1.getSimpleValueType() == MVT::v2i64 && "Bad operand type!");
12997   assert(V2.getSimpleValueType() == MVT::v2i64 && "Bad operand type!");
12998   assert(Mask.size() == 2 && "Unexpected mask size for v2 shuffle!");
13018   assert(Mask[0] != -1 && "No undef lanes in multi-input v2 shuffles!");
13019   assert(Mask[1] != -1 && "No undef lanes in multi-input v2 shuffles!");
13020   assert(Mask[0] < 2 && "We sort V1 to be the first input.");
13021   assert(Mask[1] >= 2 && "We sort V2 to be the second input.");
13181   assert(V1.getSimpleValueType() == MVT::v4f32 && "Bad operand type!");
13182   assert(V2.getSimpleValueType() == MVT::v4f32 && "Bad operand type!");
13183   assert(Mask.size() == 4 && "Unexpected mask size for v4 shuffle!");
13277   assert(V1.getSimpleValueType() == MVT::v4i32 && "Bad operand type!");
13278   assert(V2.getSimpleValueType() == MVT::v4i32 && "Bad operand type!");
13279   assert(Mask.size() == 4 && "Unexpected mask size for v4 shuffle!");
13404   assert(VT.getVectorElementType() == MVT::i16 && "Bad input type!");
13407   assert(Mask.size() == 8 && "Shuffle mask length doesn't match!");
13531     assert((AToAInputs.size() == 3 || AToAInputs.size() == 1) &&
13533     assert((BToAInputs.size() == 1 || BToAInputs.size() == 3) &&
13535     assert(AToAInputs.size() + BToAInputs.size() == 4 &&
13595           assert(IsFixIdxInput != IsFixFreeIdxInput &&
13615           assert(NumFlippedAToBInputs != 0 && "Impossible given predicates!");
13679     assert(InPlaceInputs.size() == 2 && "Cannot handle 3 or 4 inputs!");
13731             assert(SourceHalfMask[SourceHalfMask[Input - SourceOffset]] ==
13745           assert(PSHUFDMask[(Input - SourceOffset + DestOffset) / 2] ==
13756           assert(M >= 0 && "This should never wrap below zero!");
13811             assert((SourceHalfMask[i] < 0 || SourceHalfMask[i] == i) &&
13813           assert(InputsFixed[1] != (InputsFixed[0] ^ 1) &&
13846     assert(PSHUFDMask[FreeDWord] < 0 && "DWord not free");
13874   assert(count_if(LoMask, [](int M) { return M >= 4; }) == 0 &&
13876   assert(count_if(HiMask, [](int M) { return M >= 0 && M < 4; }) == 0 &&
13900   assert(!is128BitLaneCrossingShuffleMask(VT, Mask) &&
13964   assert(V1.getSimpleValueType() == MVT::v8i16 && "Bad operand type!");
13965   assert(V2.getSimpleValueType() == MVT::v8i16 && "Bad operand type!");
13966   assert(Mask.size() == 8 && "Unexpected mask size for v8 shuffle!");
14007   assert(llvm::any_of(Mask, [](int M) { return M >= 0 && M < 8; }) &&
14108   assert(isPowerOf2_32((uint32_t)ShuffleModulus) &&
14172   assert(V1.getSimpleValueType() == MVT::v16i8 && "Bad operand type!");
14173   assert(V2.getSimpleValueType() == MVT::v16i8 && "Bad operand type!");
14174   assert(Mask.size() == 16 && "Unexpected mask size for v16 shuffle!");
14296           assert(MappedMask < 8 && "Invalid v8 shuffle mask!");
14300             assert(PostDupI16Shuffle[i / 2] == MappedMask &&
14403     assert(NumEvenDrops <= 3 &&
14515   assert(VT.getSizeInBits() >= 256 &&
14517   assert(V1.getSimpleValueType() == VT && "Bad operand type!");
14518   assert(V2.getSimpleValueType() == VT && "Bad operand type!");
14642   assert(!V2.isUndef() && "This routine must not be used to lower single-input "
14763   assert(VT.is256BitVector() && "Only for 256-bit vector shuffles!");
14787   assert(V2.isUndef() &&
14798   assert(!is128BitLaneCrossingShuffleMask(VT, InLaneMask) &&
14890   assert((WidenedMask[0] >= 0 || IsLowZero) &&
14917   assert(!V2.isUndef() && "This is only useful with multiple inputs.");
14962       assert(M1.size() == M2.size() && "Unexpected mask size");
14970       assert(Mask.size() == MergedMask.size() && "Unexpected mask size");
14975         assert((MergedMask[i] < 0 || MergedMask[i] == M) &&
15085   assert((Mask.size() == HalfMask.size() * 2) &&
15138   assert(V1.getValueType() == V2.getValueType() && "Different sized vectors?");
15139   assert(V1.getValueType().isSimple() && "Expecting only simple types");
15178   assert((VT.is256BitVector() || VT.is512BitVector()) &&
15185   assert((!UndefLower || !isUndefUpperHalf(Mask)) &&
15215   assert(HalfMask.size() == HalfNumElts && "Unexpected shuffle mask length");
15222   assert(NumLowerHalves + NumUpperHalves <= 2 && "Only 1 or 2 halves allowed");
15259     assert(NumUpperHalves == 2 && "Half vector count went wrong");
15287   assert((Input == 0 || Input == 1) && "Only two inputs to shuffles.");
15417         assert((RepeatedSubLaneMask[i] < 0 || RepeatedSubLaneMask[i] == M) &&
15434   assert(0 <= TopSrcSubLane && TopSrcSubLane < NumSubLanes &&
15471   assert(VT.getScalarSizeInBits() == 64 &&
15474   assert(isUndefOrZeroOrInRange(Mask, 0, 2 * NumElts) &&
15516   assert((VT == MVT::v2f64 || VT == MVT::v4f64 || VT == MVT::v8f64) &&
15543   assert(VT == MVT::v32i8 && "Unexpected type!");
15579   assert(V1.getSimpleValueType() == MVT::v4f64 && "Bad operand type!");
15580   assert(V2.getSimpleValueType() == MVT::v4f64 && "Bad operand type!");
15581   assert(Mask.size() == 4 && "Unexpected mask size for v4 shuffle!");
15687   assert(V1.getSimpleValueType() == MVT::v4i64 && "Bad operand type!");
15688   assert(V2.getSimpleValueType() == MVT::v4i64 && "Bad operand type!");
15689   assert(Mask.size() == 4 && "Unexpected mask size for v4 shuffle!");
15690   assert(Subtarget.hasAVX2() && "We can only lower v4i64 with AVX2!");
15785   assert(V1.getSimpleValueType() == MVT::v8f32 && "Bad operand type!");
15786   assert(V2.getSimpleValueType() == MVT::v8f32 && "Bad operand type!");
15787   assert(Mask.size() == 8 && "Unexpected mask size for v8 shuffle!");
15802     assert(RepeatedMask.size() == 4 &&
15884   assert(V1.getSimpleValueType() == MVT::v8i32 && "Bad operand type!");
15885   assert(V2.getSimpleValueType() == MVT::v8i32 && "Bad operand type!");
15886   assert(Mask.size() == 8 && "Unexpected mask size for v8 shuffle!");
15887   assert(Subtarget.hasAVX2() && "We can only lower v8i32 with AVX2!");
15921     assert(RepeatedMask.size() == 4 && "Unexpected repeated mask size!");
15995   assert(V1.getSimpleValueType() == MVT::v16i16 && "Bad operand type!");
15996   assert(V2.getSimpleValueType() == MVT::v16i16 && "Bad operand type!");
15997   assert(Mask.size() == 16 && "Unexpected mask size for v16 shuffle!");
15998   assert(Subtarget.hasAVX2() && "We can only lower v16i16 with AVX2!");
16095   assert(V1.getSimpleValueType() == MVT::v32i8 && "Bad operand type!");
16096   assert(V2.getSimpleValueType() == MVT::v32i8 && "Bad operand type!");
16097   assert(Mask.size() == 32 && "Unexpected mask size for v32 shuffle!");
16098   assert(Subtarget.hasAVX2() && "We can only lower v32i8 with AVX2!");
16258   assert(VT.getScalarSizeInBits() == 64 &&
16263   assert(VT.is512BitVector() && "Unexpected vector size for 512bit shuffle.");
16296   assert(WidenedMask.size() == 4);
16302     assert(WidenedMask[i] >= -1);
16333     assert(WidenedMask[i] >= -1);
16358   assert(V1.getSimpleValueType() == MVT::v8f64 && "Bad operand type!");
16359   assert(V2.getSimpleValueType() == MVT::v8f64 && "Bad operand type!");
16360   assert(Mask.size() == 8 && "Unexpected mask size for v8 shuffle!");
16412   assert(V1.getSimpleValueType() == MVT::v16f32 && "Bad operand type!");
16413   assert(V2.getSimpleValueType() == MVT::v16f32 && "Bad operand type!");
16414   assert(Mask.size() == 16 && "Unexpected mask size for v16 shuffle!");
16420     assert(RepeatedMask.size() == 4 && "Unexpected repeated mask size!");
16465   assert(V1.getSimpleValueType() == MVT::v8i64 && "Bad operand type!");
16466   assert(V2.getSimpleValueType() == MVT::v8i64 && "Bad operand type!");
16467   assert(Mask.size() == 8 && "Unexpected mask size for v8 shuffle!");
16528   assert(V1.getSimpleValueType() == MVT::v16i32 && "Bad operand type!");
16529   assert(V2.getSimpleValueType() == MVT::v16i32 && "Bad operand type!");
16530   assert(Mask.size() == 16 && "Unexpected mask size for v16 shuffle!");
16546     assert(RepeatedMask.size() == 4 && "Unexpected repeated mask size!");
16597   assert(V1.getSimpleValueType() == MVT::v32i16 && "Bad operand type!");
16598   assert(V2.getSimpleValueType() == MVT::v32i16 && "Bad operand type!");
16599   assert(Mask.size() == 32 && "Unexpected mask size for v32 shuffle!");
16600   assert(Subtarget.hasBWI() && "We can only lower v32i16 with AVX-512-BWI!");
16650   assert(V1.getSimpleValueType() == MVT::v64i8 && "Bad operand type!");
16651   assert(V2.getSimpleValueType() == MVT::v64i8 && "Bad operand type!");
16652   assert(Mask.size() == 64 && "Unexpected mask size for v64 shuffle!");
16653   assert(Subtarget.hasBWI() && "We can only lower v64i8 with AVX-512-BWI!");
16720   assert(Subtarget.hasAVX512() &&
16778     assert((M == SM_SentinelUndef || (0 <= M && M < NumElts)) &&
16794   assert(ShiftAmt >= 0 && "All undef?");
16851   assert(Subtarget.hasAVX512() &&
16871   assert(SubvecElts != NumElts && "Identity shuffle?");
16879     assert(Src >= 0 && "Expected a source!");
16949     assert(Subtarget.hasBWI() && "Expected AVX512BW support");
16991   assert(NumV1Elements > 0 && "No V1 indices");
17053   assert((VT.getSizeInBits() != 64 || Is1BitVector) &&
17082   assert(llvm::all_of(OrigMask,
17099     assert(!Zeroable.isNullValue() && "V2's non-undef elements are used?!");
17132         assert(find(WidenedMask, SM_SentinelZero) != WidenedMask.end() &&
17333   assert((VecVT.getVectorNumElements() <= 16 || Subtarget.hasBWI()) &&
17426     assert(isPowerOf2_32(ElemsPerChunk) && "Elements per chunk not power of 2");
17435   assert(VecVT.is128BitVector() && "Unexpected vector length");
17602     assert(isPowerOf2_32(NumEltsIn128));
17612   assert(VT.is128BitVector() && "Only 128-bit vector types should be left!");
17627       assert(Subtarget.hasSSE2() && "SSE2 required for PINSRW");
17630       assert(VT == MVT::v16i8 && "PINSRB requires v16i8 vector");
17631       assert(Subtarget.hasSSE41() && "SSE41 required for PINSRB");
17703   assert(OpVT.is128BitVector() && OpVT.isInteger() && OpVT != MVT::v2i64 &&
17720   assert(Op.getSimpleValueType().getVectorElementType() == MVT::i1);
17727   assert(Op.getSimpleValueType().getVectorElementType() == MVT::i1 &&
18230   assert(Op.getNumOperands() == 3 && "Not a double-shift!");
18279   assert((Op.getOpcode() == ISD::FSHL || Op.getOpcode() == ISD::FSHR) &&
18290     assert(Subtarget.hasVBMI2() && "Expected VBMI2");
18306   assert((VT == MVT::i16 || VT == MVT::i32 || VT == MVT::i64) &&
18330   assert((Op.getOpcode() == ISD::SINT_TO_FP ||
18440   assert(SrcVT <= MVT::i64 && SrcVT >= MVT::i16 &&
18650   assert(N0.getSimpleValueType() == MVT::v2i32 && "Unexpected input type");
18712   assert((VecIntVT == MVT::v4i32 || VecIntVT == MVT::v8i32) &&
18786     assert(!Subtarget.hasAVX512());
18843   assert(SrcVT == MVT::i64 && "Unexpected type in UINT_TO_FP");
18926     assert(DstTy == MVT::i32 && "Unexpected FP_TO_UINT");
18930   assert(DstTy.getSimpleVT() <= MVT::i64 &&
18973     assert(Status == APFloat::opOK && !LosesInfo &&
18998     assert(DstTy == MVT::i64 && "Invalid FP_TO_SINT to lower!");
19004     assert(FLDSize <= MemSize && "Stack slot not big enough");
19036   assert(VT.isVector() && InVT.isVector() && "Expected vector type");
19037   assert((Opc == ISD::ANY_EXTEND || Opc == ISD::ZERO_EXTEND) &&
19039   assert(VT.getVectorNumElements() == VT.getVectorNumElements() &&
19041   assert((VT.getVectorElementType() == MVT::i16 ||
19045   assert((InVT.getVectorElementType() == MVT::i8 ||
19098   assert((VT == MVT::v16i8 || VT == MVT::v16i16) && "Unexpected VT.");
19115   assert(InVT.getVectorElementType() == MVT::i1 && "Unexpected input type!");
19175   assert(Subtarget.hasAVX() && "Expected AVX support");
19187   assert((Opcode == X86ISD::PACKSS || Opcode == X86ISD::PACKUS) &&
19189   assert(DstVT.isVector() && "VT not a vector?");
19213   assert(DstVT.getVectorNumElements() == NumElems && "Illegal truncation");
19214   assert(SrcSizeInBits > DstSizeInBits && "Illegal truncation");
19279   assert(SrcSizeInBits >= 256 && "Expected 256-bit vector or greater");
19297   assert(VT.getVectorElementType() == MVT::i1 && "Unexpected vector type.");
19317     assert((InVT.is256BitVector() || InVT.is128BitVector()) &&
19320     assert((NumElts == 8 || NumElts == 16) && "Unexpected number of elements");
19372   assert(VT.getVectorNumElements() == InVT.getVectorNumElements() &&
19380       assert(Subtarget.hasVLX() && "Unexpected subtarget!");
19433   assert(VT.is128BitVector() && InVT.is256BitVector() && "Unexpected types!");
19552     assert(Subtarget.hasDQI() && Subtarget.hasVLX() && "Requires AVX512DQVL!");
19562   assert(!VT.isVector());
19575     assert(VT == MVT::i32 && "Unexpected VT!");
19591     assert(IsSigned && "Expected i16 FP_TO_UINT to have been promoted!");
19618   assert(SVT == MVT::v2f32 && "Only customize MVT::v2f32 type legalization!");
19647   assert(Op.getOperand(0).getValueType() != MVT::f128 &&
19703   assert((BitWidth == 128 || BitWidth == 256 || BitWidth == 512) &&
19733   assert((Op.getValueType() == MVT::f32 || Op.getValueType() == MVT::f64) &&
19741   assert((Op.getOpcode() == ISD::FABS || Op.getOpcode() == ISD::FNEG) &&
19757   assert((VT == MVT::f64 || VT == MVT::f32 || VT == MVT::f128 ||
19817   assert((VT == MVT::f64 || VT == MVT::f32 || VT == MVT::f128 ||
19873   assert((OpVT == MVT::f32 || OpVT == MVT::f64) &&
19902   assert(Op.getOpcode() == unsigned(BinOp) &&
19962   assert(Op.getOpcode() == ISD::OR && "Only check OR'd tree.");
20144   assert((CmpVT == MVT::i8 || CmpVT == MVT::i16 ||
20210   assert(Subtarget.hasLAHFSAHF() && "Target doesn't support SAHF or FCOMI?");
20312   assert((Divisor.isPowerOf2() || (-Divisor).isPowerOf2()) &&
20366   assert(And.getOpcode() == ISD::AND && "Expected AND node!");
20492   assert(VT.is256BitVector() && Op.getOpcode() == ISD::SETCC &&
20525   assert(VT.getVectorElementType() == MVT::i1 &&
20639     assert(EltVT == MVT::f32 || EltVT == MVT::f64);
20644       assert(VT.getVectorNumElements() <= 16);
20667         assert(Cond == ISD::SETONE);
20695   assert(VTOp0 == Op1.getSimpleValueType() &&
20697   assert(VT.getVectorNumElements() == VTOp0.getVectorNumElements() &&
20702   assert((Subtarget.hasAVX512() || (VT == VTOp0)) &&
20709     assert((VTOp0.getScalarSizeInBits() >= 32 || Subtarget.hasBWI()) &&
20861       assert(Subtarget.hasSSE2() && "Don't know how to lower!");
20902       assert(Subtarget.hasSSE2() && !FlipSigns && "Don't know how to lower!");
21063   assert(VT == MVT::i8 && "SetCC type must be 8-bit integer");
21076       assert(Op0.getValueType() == Op.getValueType() &&
21097   assert(LHS.getSimpleValueType().isInteger() && "SETCCCARRY is integer only.");
21117   assert(Op.getResNo() == 0 && "Unexpected result number!");
21172   assert(Op->getValueType(1) == MVT::i8 && "Unexpected VT!");
21225       assert(!VT.isVector() && "Not a scalar type?");
21276     assert(Subtarget.hasBWI() && "Expected BWI to be legal");
21524   assert(InVT.getVectorElementType() == MVT::i1 && "Unexpected input type!");
21583   assert(Subtarget.hasAVX() && "Expected AVX support");
21600   assert(SVT.getSizeInBits() > InSVT.getSizeInBits());
21629     assert(VT.getSizeInBits() > 128 && "Unexpected 128-bit vector extension");
21644     assert(VT.is256BitVector() && "256-bit vector expected");
21660   assert(Opc == ISD::SIGN_EXTEND_VECTOR_INREG && "Unexpected opcode!");
21661   assert(VT.is128BitVector() && InVT.is128BitVector() && "Unexpected VTs");
21693     assert(Curr.getValueType() == MVT::v4i32 && "Unexpected input VT");
21713   assert(VT.isVector() && InVT.isVector() && "Expected vector type");
21714   assert(VT.getVectorNumElements() == VT.getVectorNumElements() &&
21716   assert((VT.getVectorElementType() == MVT::i16 ||
21720   assert((InVT.getVectorElementType() == MVT::i8 ||
21763   assert((StoredVal.getValueType().is256BitVector() ||
21799   assert(StoreVT.is128BitVector() &&
21839     assert(StoredVal.getValueType().getVectorNumElements() <= 8 &&
21841     assert(!St->isTruncatingStore() && "Expected non-truncating store");
21842     assert(Subtarget.hasAVX512() && !Subtarget.hasDQI() &&
21872   assert(StoreVT.isVector() && StoreVT.getSizeInBits() == 64 &&
21874   assert(TLI.getTypeAction(*DAG.getContext(), StoreVT) ==
21894   assert(Subtarget.hasSSE1() && "Expected SSE");
21911   assert(RegVT.isVector() && "We only custom lower vector loads.");
21912   assert(RegVT.isInteger() &&
21920     assert(EVT(RegVT) == Ld->getMemoryVT() && "Expected non-extending load");
21921     assert(RegVT.getVectorNumElements() <= 8 && "Unexpected VT");
21922     assert(Subtarget.hasAVX512() && !Subtarget.hasDQI() &&
21930     assert(NewLd->getNumValues() == 2 && "Loads must carry a chain!");
22084             assert(NewBR == User);
22125           assert(NewBR == User);
22218     assert(SPReg && "Target cannot require DYNAMIC_STACKALLOC expansion and"
22333   assert(Subtarget.is64Bit() &&
22335   assert(Op.getNumOperands() == 4);
22368     assert(!Subtarget.useSoftFloat() &&
22395   assert(Subtarget.is64Bit() && "This code only handles 64-bit va_copy!");
22457   assert((Opc == X86ISD::VSHLI || Opc == X86ISD::VSRLI || Opc == X86ISD::VSRAI)
22520   assert((SVT == MVT::i32 || SVT == MVT::i64) && "Unexpected value type!");
22594   assert(MaskVT.bitsLE(Mask.getSimpleValueType()) && "Unexpected mask size!");
22597     assert(MaskVT == MVT::v64i1 && "Expected v64i1 mask!");
22598     assert(Subtarget.hasBWI() && "Expected AVX512BW target!");
22662   assert(Mask.getValueType() == MVT::i8 && "Unexpect type");
22940       assert(Op.getNumOperands() == (6U + HasRounding) &&
23254       assert(IntrData->Opc0 == X86ISD::VRNDSCALE && "Unexpected opcode");
23264       assert(IntrData->Opc0 == X86ISD::VRNDSCALES && "Unexpected opcode");
23274       assert(IntrData->Opc0 == X86ISD::BEXTR && "Unexpected opcode");
23806     assert(N->getNumOperands() == 3 && "Unexpected number of operands!");
24092     assert((HintVal == 2 || HintVal == 3) &&
24142     assert(MemIntr && "Expected MemIntrinsicSDNode!");
24240   assert(((FrameReg == X86::RBP && VT == MVT::i64) ||
24271       assert((FrameReg == X86::EBP || FrameReg == X86::RBP) &&
24300   assert(!isFuncletEHPersonality(classifyEHPersonality(PersonalityFn)));
24317   assert(((FrameReg == X86::RBP && PtrVT == MVT::i64) ||
24593   assert(EltVT == Src.getSimpleValueType().getVectorElementType() &&
24609   assert(Op.getSimpleValueType().is256BitVector() &&
24617   assert(Op.getSimpleValueType().is512BitVector() &&
24631   assert(Op.getOpcode() == ISD::CTLZ);
24637   assert((EltVT == MVT::i8 || EltVT == MVT::i16) &&
24646   assert((NewVT.is256BitVector() || NewVT.is512BitVector()) &&
24759   assert(Subtarget.hasSSSE3() && "Expected SSSE3 support for PSHUFB");
24809   assert(!VT.isVector() && Op.getOpcode() == ISD::CTTZ &&
24828   assert(VT.is256BitVector() && VT.isInteger() &&
24857   assert(VT.is512BitVector() && VT.isInteger() &&
24891   assert(Op.getSimpleValueType().is256BitVector() &&
24939   assert(Op.getSimpleValueType().is256BitVector() &&
24970     assert(VT.isInteger() &&
24994     assert((Opcode == ISD::UMIN || Opcode == ISD::UMAX) &&
25088     assert(Subtarget.hasSSE2() && !Subtarget.hasSSE41() &&
25114   assert((VT == MVT::v2i64 || VT == MVT::v4i64 || VT == MVT::v8i64) &&
25116   assert(!Subtarget.hasDQI() && "DQI should use MULLQ");
25177     assert((VT == MVT::v4i32 && Subtarget.hasSSE2()) ||
25242   assert((VT == MVT::v16i8 || (VT == MVT::v32i8 && Subtarget.hasInt256()) ||
25384   assert(Subtarget.isTargetWin64() && "Unexpected target");
25386   assert(VT.isInteger() && VT.getSizeInBits() == 128 &&
25408     assert(ArgVT.isInteger() && ArgVT.getSizeInBits() == 128 &&
25495     assert((VT == MVT::v2i64 || VT == MVT::v4i64) && "Unexpected SRA type");
25501       assert((VT != MVT::v4i64 || Subtarget.hasInt256()) &&
25566         assert(VT == MVT::v64i8 && "Unexpected element type!");
25623       assert(EltVT.bitsLE(MVT::i64) && "Unexpected element type!");
25774   assert(VT.isVector() && "Custom lowering only for vector shifts!");
25775   assert(Subtarget.hasSSE2() && "Only custom lower when we have SSE2!");
25986     assert((!Subtarget.hasBWI() || VT == MVT::v32i8 || VT == MVT::v16i8) &&
26012     assert(ISD::isBuildVectorOfConstantSDNodes(Amt.getNode()) &&
26245   assert(VT.isVector() && "Custom lowering only for vector rotates!");
26283   assert((Opcode == ISD::ROTL) && "Only ROTL supported");
26291     assert(VT.is128BitVector() && "Only rotate 128-bit vectors!");
26308   assert((VT == MVT::v4i32 || VT == MVT::v8i16 || VT == MVT::v16i8 ||
26401   assert(Scale && "Failed to convert ROTL amount to scale");
26413   assert(VT == MVT::v4i32 && "Only v4i32 vector rotate expected");
26701     assert(Subtarget.is64Bit() && "Node not type legal!");
26765     assert(!Subtarget.is64Bit() && "Expected 32-bit mode");
26766     assert(Subtarget.hasBWI() && "Expected BWI target");
26791     assert(!Subtarget.hasAVX512() && "Should use K-registers with AVX512");
26799   assert((SrcVT == MVT::v2i32 || SrcVT == MVT::v4i16 || SrcVT == MVT::v8i8 ||
26802   assert(Subtarget.hasSSE2() && "Requires at least SSE2!");
26817     assert(SrcVT == MVT::i64 && !Subtarget.is64Bit() &&
26844   assert(ByteVecVT.getVectorElementType() == MVT::i8 &&
26846   assert(EltVT != MVT::i8 &&
26849   assert(ByteVecVT.getSizeInBits() == VecSize && "Cannot change vector size!");
26889   assert(EltVT == MVT::i16 && "Unknown how to handle type");
26909   assert(EltVT == MVT::i8 && "Only vXi8 vector CTPOP lowering supported.");
26952   assert((VT.is512BitVector() || VT.is256BitVector() || VT.is128BitVector()) &&
26960     assert((VT.getVectorElementType() == MVT::i8 ||
26995   assert(Op.getSimpleValueType().isVector() &&
27022   assert(VT.is128BitVector() &&
27052   assert(Subtarget.hasSSSE3() && "SSSE3 required for BITREVERSE");
27060     assert(!Subtarget.hasBWI() && "BWI should Expand BITREVERSE");
27065   assert(VT.getScalarType() == MVT::i8 &&
27156     assert(Opc == ISD::ATOMIC_LOAD_ADD &&
27178       assert(!N->hasAnyUseOfValue(0));
27185     assert(!N->hasAnyUseOfValue(0));
27193   assert(!N->hasAnyUseOfValue(0));
27281   assert(Subtarget.isTargetDarwin() && Subtarget.is64Bit());
27345   assert(InVT.getVectorElementType() == NVT.getVectorElementType() &&
27350   assert(WidenNumElts > InNumElts && WidenNumElts % InNumElts == 0 &&
27386   assert(Subtarget.hasAVX512() &&
27392   assert(VT.getScalarSizeInBits() >= 32 && "Unsupported scatter op");
27402     assert(Mask.getValueType() == MVT::v2i1 && "Unexpected mask type");
27479   assert((!N->isExpandingLoad() || Subtarget.hasAVX512()) &&
27482   assert((!N->isExpandingLoad() || ScalarVT.getSizeInBits() >= 32) &&
27485   assert(Subtarget.hasAVX512() && !Subtarget.hasVLX() && !VT.is512BitVector() &&
27488   assert((ScalarVT.getSizeInBits() >= 32 ||
27500   assert(Mask.getSimpleValueType().getScalarType() == MVT::i1 &&
27528   assert((!N->isCompressingStore() || Subtarget.hasAVX512()) &&
27531   assert((!N->isCompressingStore() || ScalarVT.getSizeInBits() >= 32) &&
27534   assert(Subtarget.hasAVX512() && !Subtarget.hasVLX() && !VT.is512BitVector() &&
27537   assert((ScalarVT.getSizeInBits() >= 32 ||
27548   assert(Mask.getSimpleValueType().getScalarType() == MVT::i1 &&
27562   assert(Subtarget.hasAVX2() &&
27574   assert(VT.getScalarSizeInBits() >= 32 && "Unsupported gather op");
27807   assert((N->getNumValues() == Res->getNumValues()) &&
27829     assert(N->getValueType(0) == MVT::i64 && "Unexpected VT!");
27850     assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
27870     assert(Subtarget.hasSSE2() && "Requires at least SSE2!");
27874     assert(VT.getSizeInBits() < 128 && 128 % VT.getSizeInBits() == 0 &&
27876     assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
27899     assert(N->getValueType(0) == MVT::i64 &&
27928     assert(VT == MVT::v2f32 && "Unexpected type (!= v2f32) on FMIN/FMAX.");
27943       assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
28041     assert(N->getValueType(0) == MVT::v8i8 &&
28051       assert(getTypeAction(*DAG.getContext(), InVT) == TypeWidenVector &&
28053       assert(N->getOpcode() == ISD::SIGN_EXTEND && "Unexpected opcode");
28097       assert(isTypeLegal(LoVT) && "Split VT not legal?");
28124       assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
28157       assert((IsSigned || Subtarget.hasAVX512()) &&
28159       assert(Subtarget.hasSSE2() && "Requires at least SSE2!");
28160       assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
28181     assert(!VT.isVector() && "Vectors should have been handled above!");
28185       assert(!Subtarget.is64Bit() && "i64 should be legal");
28208     assert(Subtarget.hasDQI() && Subtarget.hasVLX() && "Requires AVX512DQVL!");
28216     assert(Subtarget.hasSSE2() && "Requires at least SSE2!");
28249     assert(N->getValueType(0) == MVT::v2f32 &&
28279     assert((T == MVT::i64 || T == MVT::i128) && "can only expand cmpxchg pair");
28281     assert((!Regs64bit || Subtarget.hasCmpxchg16b()) &&
28322       assert(((Regs64bit == (BasePtr == X86::RBX)) || BasePtr == X86::EBX) &&
28362     assert(N->getValueType(0) == MVT::i64 && "Unexpected VT!");
28437     assert(Subtarget.hasSSE2() && "Requires at least SSE2!");
28444       assert(!Subtarget.is64Bit() && "Expected 32-bit mode");
28468       assert(getTypeAction(*DAG.getContext(), DstVT) == TypeWidenVector &&
28486       assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
28490       assert(Mask.getValueType() == MVT::v2i1 && "Unexpected mask type");
28517     assert(VT.isVector() && VT.getSizeInBits() == 64 && "Unexpected VT");
28518     assert(getTypeAction(*DAG.getContext(), VT) == TypeWidenVector &&
28537     assert(Subtarget.hasSSE1() && "Expected SSE");
29027   assert(Ty1->getPrimitiveSizeInBits() <= 64 && "i128 is probably not a noop");
29265   assert(MI.getNumOperands() == 10 && "VAARG_64 should have 10 operands!");
29282   assert(MI.hasOneMemOperand() && "Expected VAARG_64 to have one memoperand");
29402     assert(OffsetReg != 0);
29465     assert(isPowerOf2_32(Align) && "Alignment must be a power of 2");
29560   assert((MI.getNumOperands() <= 3 ||
30020   assert(MF->shouldSplitStack());
30154   assert(!isAsynchronousEHPersonality(
30166   assert(BB->succ_size() == 1);
30234   assert(Subtarget.isTargetDarwin() && "Darwin only instr emitted?");
30235   assert(MI.getOperand(3).isGlobal() && "This should be a global");
30318       assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30321       assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30324       assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30327       assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30330       assert(Subtarget.is64Bit() && "Should not be using a 64-bit thunk!");
30339     assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30342     assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30345     assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30348     assert(!Subtarget.is64Bit() && "Should not be using a 32-bit thunk!");
30351     assert(Subtarget.is64Bit() && "Should not be using a 64-bit thunk!");
30487   assert(TRI->isTypeLegalForClass(*RC, MVT::i32) && "Invalid destination!");
30495   assert((PVT == MVT::i64 || PVT == MVT::i32) &&
30813   assert((PVT == MVT::i64 || PVT == MVT::i32) &&
30893   assert((PVT == MVT::i64 || PVT == MVT::i32) && "Invalid Pointer Size!");
30955       assert(MI.isEHLabel() && "expected EH_LABEL");
30981   assert(!LPadList.empty() &&
31223     assert(Push->getOperand(2).getReg() == X86::EFLAGS &&
31226     assert(Push->getOperand(3).getReg() == X86::DF &&
31372     assert(TRI->getBaseRegister() == X86::ESI &&
31489   assert((Opc >= ISD::BUILTIN_OP_END ||
31593     assert(VT.getScalarType() == MVT::i64 &&
31641           assert(0 <= M && (unsigned)M < (NumOps * NumElts) &&
31682     assert(VTBits < NumSrcBits && "Illegal truncation input type");
31777           assert(0 <= M && (unsigned)M < (NumOps * NumElts) &&
31848         assert(MatchZero && "Failed to match zext but matched aext?");
31899     assert(Subtarget.hasAVX() && "AVX required for 256-bit vector shuffles");
31918     assert(Subtarget.hasAVX512() &&
31988         assert(((M / 2) == (i / 2)) && "Out of range shuffle mask index");
32165           assert(RepeatedMask.size() == 8 &&
32293   assert(!BaseMask.empty() && "Cannot combine an empty shuffle mask!");
32294   assert((Inputs.size() == 1 || Inputs.size() == 2) &&
32307   assert(VT1.getSizeInBits() == RootVT.getSizeInBits() &&
32316     assert(BaseMask[0] == 0 && "Invalid shuffle index found!");
32381     assert((BaseMaskEltSizeInBits % 64) == 0 && "Illegal mask size");
32730       assert((M / 16) == (i / 16) && "Lane crossing detected");
32838     assert((Offset % BaseVT.getVectorNumElements()) == 0 &&
32852   assert((WideSizeInBits % RootSizeInBits) == 0 &&
32866     assert((WideSizeInBits % NewInput.getValueSizeInBits()) == 0 &&
32871     assert(WideSizeInBits == NewInput.getValueSizeInBits() &&
32889   assert(!WideInputs.empty() && "Shuffle with no inputs detected");
32958     assert(0 <= M && M < (int)(NumMaskElts * NumOps));
32979   assert((UndefElts | ZeroElts | ConstantElts).isAllOnesValue());
33029   assert(RootMask.size() > 0 && (RootMask.size() > 1 || RootMask[0] == 0) &&
33046   assert(Root.getSimpleValueType().isVector() &&
33048   assert(VT.getSizeInBits() == Root.getSimpleValueType().getSizeInBits() &&
33087   assert(((RootMask.size() > OpMask.size() &&
33097   assert(isPowerOf2_32(RootMask.size()) && "Non-power-of-2 shuffle mask sizes");
33098   assert(isPowerOf2_32(OpMask.size()) && "Non-power-of-2 shuffle mask sizes");
33105   assert((RootRatio == 1 || OpRatio == 1) &&
33108   assert(isPowerOf2_32(MaskWidth) && "Non-power-of-2 shuffle mask sizes");
33109   assert(isPowerOf2_32(RootRatio) && "Non-power-of-2 shuffle mask sizes");
33110   assert(isPowerOf2_32(OpRatio) && "Non-power-of-2 shuffle mask sizes");
33158     assert(0 <= OpInputIdx[InputIdx] && "Unknown target shuffle input");
33178   assert(!Ops.empty() && "Shuffle with no inputs detected");
33262   assert(HaveMask);
33271         assert(Mask[j] == Mask[i * LaneElts + j] - (LaneElts * i) &&
33301   assert(N.getOpcode() == X86ISD::PSHUFD &&
33580     assert(Mask.size() == 4);
33612     assert(VT == MVT::v4f32 && "INSERTPS ValueType must be MVT::v4f32");
33645       assert(0 <= M && M < 8 && "Shuffle index out of range");
33732     assert(VT.getVectorElementType() == MVT::i16 && "Bad word shuffle type!");
33873     assert(V2.getOpcode() == ISD::FSUB && "Unexpected opcode");
34055       assert(!HorizOp.getOperand(1).isUndef() && "Not expecting foldable h-op");
34058       assert(!HorizOp.getOperand(0).isUndef() && "Not expecting foldable h-op");
34075       assert((HOp.getValueType() == MVT::v2f64 ||
34285     assert(AmtVT.is128BitVector() && "Unexpected value type");
34318     assert(Amt->getAPIntValue().ult(NumElts) && "Out of range shift amount");
34357     assert(Amt->getAPIntValue().ult(NumElts) && "Out of range shift amount");
34778       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
34799       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
34841       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
35047       assert((IdentityOp == 0 || IdentityOp.countPopulation() == 1) &&
35110   assert(ShuffleMask.size() == NumOriginalElts && "Shuffle mask size mismatch");
35127   assert(0 <= Idx && Idx < (int)(2 * NumOriginalElts) &&
35316   assert(SrcVT.getVectorElementType() == MVT::i1 &&
35318   assert(ISD::isBuildVectorOfConstantSDNodes(Op.getNode()) &&
35334   assert(N->getOpcode() == ISD::BITCAST && "Expected a bitcast");
35780   assert(((SrcVT == MVT::v8i16 && ExtractVT == MVT::i16) ||
35917   assert((NumElts <= 32 || NumElts == 64) &&
36145     assert(SrcSVT == VT && "Unexpected extraction type");
36153     assert(VT.getSizeInBits() >= SrcSVT.getSizeInBits() &&
36168   assert(ExtElt->getOpcode() == ISD::EXTRACT_VECTOR_ELT && "Expected extract");
36267   assert(ExtElt->getOpcode() == ISD::EXTRACT_VECTOR_ELT && "Unexpected caller");
36280   assert(isNullConstant(Index) &&
36331     assert(VecVT == MVT::v16i8 && "v16i8 reduction expected");
36421       assert(SrcVT == InputVector.getOperand(0).getValueType() &&
36531   assert(CondVT.isVector() && "Vector select expects a vector selector!");
37415     assert(X86::CondCode(SetCC.getConstantOperandVal(0)) == X86::COND_B &&
37646         assert(Diff.getBitWidth() == N->getValueType(0).getSizeInBits() &&
37805   assert(N->getNumOperands() == 2 && "NumOperands of Mul are 2");
38143   assert(SignMulAmt != INT64_MIN && "Int min should have been handled!");
38207     assert(C->getZExtValue() != 0 &&
38300       assert(N0.getValueType().isVector() && "Invalid vector shift type");
38417   assert((X86ISD::PACKSS == Opcode || X86ISD::PACKUS == Opcode) &&
38425   assert(N0.getScalarValueSizeInBits() == SrcBitsPerElt &&
38516   assert((X86ISD::VSHL == N->getOpcode() || X86ISD::VSRA == N->getOpcode() ||
38550   assert((X86ISD::VSHLI == Opcode || X86ISD::VSRAI == Opcode ||
38558   assert(VT == N0.getValueType() && (NumBitsPerElt % 8) == 0 &&
38560   assert(N1.getValueType() == MVT::i8 && "Unexpected shift amount type");
38603     assert(EltBits.size() == VT.getVectorNumElements() &&
38628   assert(((N->getOpcode() == X86ISD::PINSRB && VT == MVT::v16i8) ||
38753   assert(N->getOpcode() == ISD::AND);
38786   assert(VT.isVector() && "Expected vector type");
38788   assert((N->getOpcode() == ISD::ANY_EXTEND ||
39081   assert(VT == MVT::i32 && "Unexpected VT!");
39112   assert(N->getOpcode() == ISD::AND && "Unexpected opcode!");
39122   assert(!VT.isVector() && "Expected scalar VT!");
39291   assert(N->getOpcode() == ISD::OR && "Unexpected Opcode");
39388   assert(MaskVT.isInteger() &&
39440   assert(N->getOpcode() == ISD::OR && "Unexpected Opcode");
39885   assert(InVT.getScalarSizeInBits() > VT.getScalarSizeInBits() &&
39930   assert(NumSrcBits > NumDstBits && "Unexpected types for truncate operation");
39981       assert(Mid && "Failed to pack!");
40011         assert(Mid && "Failed to pack!");
40014         assert(V && "Failed to pack!");
40779   assert((VT.is128BitVector() || VT.is256BitVector()) &&
40875   assert((NumEltsPer128BitChunk % 2 == 0) &&
40920   assert((IsFadd || N->getOpcode() == ISD::FSUB) && "Wrong opcode");
40939   assert(N->getOpcode() == ISD::TRUNCATE && "Wrong opcode");
41343     assert(InVT.getScalarType() == MVT::i8 &&
41345     assert(InVT == Ops[1].getValueType() && "Operands' types mismatch");
41875   assert(N->getOpcode() == X86ISD::FOR || N->getOpcode() == X86ISD::FXOR);
41893   assert(N->getOpcode() == X86ISD::FMIN || N->getOpcode() == X86ISD::FMAX);
41993     assert(InVT.is128BitVector() && "Expected 128-bit input vector");
42028     assert(InVT.is128BitVector() && "Expected 128-bit input vector");
42099   assert(N->getOpcode() == ISD::SIGN_EXTEND_INREG);
42161   assert(N->getOpcode() == ISD::SIGN_EXTEND_INREG);
42357   assert(NumElts == SclVT.getSizeInBits() && "Unexpected bool vector size");
42365     assert((NumElts % EltSizeInBits) == 0 && "Unexpected integer scale");
42652   assert((CC == ISD::SETNE || CC == ISD::SETEQ) && "Bad comparison predicate");
42858       assert(VT == LHS.getOperand(0).getValueType() &&
42867       assert((CC == ISD::SETNE || CC == ISD::SETLT) &&
42907     assert(VT == MVT::i32 && "Unexpected result type");
43251       assert(InVT == MVT::v2i64 && "Unexpected VT!");
43292   assert(Flags.getValueType() == MVT::i32 && "Unexpected VT!");
43330   assert(Flags.getValueType() == MVT::i32 && "Unexpected VT!");
43445   assert((X86ISD::ADD == N->getOpcode() || X86ISD::SUB == N->getOpcode()) &&
43812     assert(VT.getSizeInBits() % ResVT.getSizeInBits() == 0 && "Unexpected VTs");
43922     assert(InVT.getScalarType() == MVT::i32 &&
43924     assert(InVT == Ops[1].getValueType() && "Operands' types mismatch");
44048     assert(OpVT.getScalarType() == MVT::i16 &&
44050     assert(OpVT == Ops[1].getValueType() && "Operands' types mismatch");
44167   assert((VT == MVT::v8i32 || VT == MVT::v16i32 || VT == MVT::v8i64) &&
44272   assert(Subtarget.hasAVX() && "AVX assumed for concat_vectors");
44546   assert((SelVT.is256BitVector() || SelVT.is512BitVector()) &&
45186   assert(SrcVT.getVectorNumElements() == ShuffleMask.size() &&
45188   assert(
45801       assert((Subtarget.is32Bit() || Subtarget.is16Bit()) &&
46198     assert(
lib/Target/X86/X86ISelLowering.h
 1658     assert(Mask.empty() && "Expected an empty shuffle mask vector");
 1677     assert(0 < Scale && "Unexpected scaling factor");
lib/Target/X86/X86IndirectBranchTracking.cpp
   73   assert(TII && "Target instruction info was not initialized");
   74   assert((X86::ENDBR64 == EndbrOpcode || X86::ENDBR32 == EndbrOpcode) &&
lib/Target/X86/X86InsertPrefetch.cpp
  109   assert(Prefetches.empty() &&
  148   assert(max_index + 1 >= 0 &&
  150   assert(static_cast<size_t>(max_index + 1) == Prefetches.size() &&
  206       assert(!Prefetches.empty() &&
  217         assert(X86::AddrBaseReg == 0 && X86::AddrScaleAmt == 1 &&
lib/Target/X86/X86InstrBuilder.h
   66     assert(Scale == 1 || Scale == 2 || Scale == 4 || Scale == 8);
   72       assert(BaseType == X86AddressMode::FrameIndexBase);
  174   assert(AM.Scale == 1 || AM.Scale == 2 || AM.Scale == 4 || AM.Scale == 8);
  179     assert(AM.BaseType == X86AddressMode::FrameIndexBase);
lib/Target/X86/X86InstrFMA3Info.cpp
  119     assert(std::is_sorted(std::begin(Groups), std::end(Groups)) &&
  164   assert(I != Table.end() && I->Opcodes[FormIndex] == Opcode &&
lib/Target/X86/X86InstrFoldTables.cpp
 5520     assert(std::is_sorted(std::begin(MemoryFoldTable2Addr),
 5526     assert(std::is_sorted(std::begin(MemoryFoldTable0),
 5532     assert(std::is_sorted(std::begin(MemoryFoldTable1),
 5538     assert(std::is_sorted(std::begin(MemoryFoldTable2),
 5544     assert(std::is_sorted(std::begin(MemoryFoldTable3),
 5550     assert(std::is_sorted(std::begin(MemoryFoldTable4),
 5556     assert(std::is_sorted(std::begin(BroadcastFoldTable2),
 5562     assert(std::is_sorted(std::begin(BroadcastFoldTable3),
 5649     assert(std::adjacent_find(Table.begin(), Table.end()) == Table.end() &&
lib/Target/X86/X86InstrInfo.cpp
  476     assert(!isPICBase && "More than one PIC base?");
  722     assert(!Src.isUndef() && "Undef op doesn't need optimization");
  739     assert(!Src.isUndef() && "Undef op doesn't need optimization");
  765   assert((Is8BitOp || RegInfo.getTargetRegisterInfo()->getRegSizeInBits(
  796   assert(!MI.getOperand(1).isUndef() && "Undef op doesn't need optimization");
  836     assert(!MI.getOperand(2).isUndef() && "Undef op doesn't need optimization");
  923     assert(MI.getNumOperands() >= 3 && "Unknown shift instruction!");
  943     assert(MI.getNumOperands() >= 3 && "Unknown shift instruction!");
  975     assert(MI.getNumOperands() >= 3 && "Unknown shift instruction!");
  983     assert(MI.getNumOperands() >= 2 && "Unknown inc instruction!");
 1005     assert(MI.getNumOperands() >= 2 && "Unknown dec instruction!");
 1037     assert(MI.getNumOperands() >= 3 && "Unknown add instruction!");
 1081     assert(MI.getNumOperands() >= 3 && "Unknown add instruction!");
 1090     assert(MI.getNumOperands() >= 3 && "Unknown add instruction!");
 1131     assert(MI.getNumOperands() >= 3 && "Unknown add instruction!");
 1159     assert(MI.getNumOperands() >= 3 && "Unknown sub instruction!");
 1369   assert(!(FMA3Group.isIntrinsic() && (SrcOpIdx1 == 1 || SrcOpIdx2 == 1)) &&
 1375   assert(Case < 3 && "Unexpected case number!");
 1420   assert(Case < 3 && "Unexpected case value!");
 1640       assert(AltIdx < 4 && "Illegal insertion index");
 1672     assert(MI.getOpcode() == X86::MOVSDrr &&
 1683     assert(MI.getOperand(3).getImm() == 0x02 && "Unexpected immediate!");
 1788     assert(Subtarget.hasSSE2() && "Commuting MOVHLP/UNPCKHPD requires SSE2!");
 2421   assert(BranchCond.size() == 1);
 2440   assert(canMakeTailCallConditional(BranchCond, TailCall));
 2448       assert(0 && "Can't find the branch to replace!");
 2451     assert(BranchCond.size() == 1);
 2616     assert(Cond.size() == 1);
 2617     assert(TBB);
 2691   assert(MBP.TrueDest && "expected!");
 2748   assert(!BytesRemoved && "code size not handled");
 2776   assert(TBB && "insertBranch must not be told to insert a fallthrough");
 2777   assert((Cond.size() == 1 || Cond.size() == 0) &&
 2779   assert(!BytesAdded && "code size not handled");
 2783     assert(!FBB && "Unconditional branch with multiple successors!");
 2806       assert(FBB && "MBB cannot be the last block in function when the false "
 2873   assert(Cond.size() == 1 && "Invalid Cond array");
 2899       assert(Subtarget.hasBWI());
 2912       assert(Subtarget.hasBWI());
 2985       assert(X86::GR8_NOREXRegClass.contains(SrcReg, DestReg) &&
 3073     assert(X86::GR8RegClass.hasSubClassEq(RC) && "Unknown 1-byte regclass");
 3083     assert(X86::GR16RegClass.hasSubClassEq(RC) && "Unknown 2-byte regclass");
 3099       assert(STI.hasBWI() && "KMOVD requires BWI");
 3127       assert(STI.hasBWI() && "KMOVQ requires BWI");
 3132     assert(X86::RFP80RegClass.hasSubClassEq(RC) && "Unknown 10-byte regclass");
 3167     assert(X86::VR256XRegClass.hasSubClassEq(RC) && "Unknown 32-byte regclass");
 3186     assert(X86::VR512RegClass.hasSubClassEq(RC) && "Unknown 64-byte regclass");
 3187     assert(STI.hasAVX512() && "Using 512-bit register requires AVX512");
 3224   assert(BaseOp->isReg() && "getMemOperandWithOffset only supports base "
 3250   assert(MF.getFrameInfo().getObjectSize(FrameIdx) >= TRI->getSpillSize(*RC) &&
 3632         assert(J->definesRegister(X86::EFLAGS) && "Must be an EFLAGS def!");
 3816   assert(FlagDef && "Unable to locate a def EFLAGS operand");
 3839   assert(DefMI);
 3879   assert(Desc.getNumOperands() == 3 && "Expected two-addr instruction.");
 3887   assert(MIB->getOperand(1).getReg() == Reg &&
 3900   assert(Desc.getNumOperands() == 3 && "Expected two-addr instruction.");
 3930   assert(Imm != 0 && "Using push/pop for 0 is not efficient.");
 3936     assert(MIB->getOpcode() == X86::MOV64ImmSExti8 ||
 3956     assert(MIB->getOpcode() == X86::MOV32ImmSExti8);
 4106     assert(HasAVX && "AVX not supported");
 4620     assert(MOs.size() == 5 && "Unexpected memory operand list length");
 4702       assert(MO.isReg() && "Expected to fold into reg operand!");
 5409   assert(STI.hasAVX512() && "Expected at least AVX512!");
 5411   assert((SpillSize == 64 || STI.hasVLX()) &&
 5947   assert(Offset2 > Offset1);
 5994   assert(Cond.size() == 1 && "Invalid X86 branch condition!");
 6016   assert((!Subtarget.is64Bit() ||
 6560   assert(((OldWidth % NewWidth) == 0 || (NewWidth % OldWidth) == 0) &&
 6689   assert(Domain > 0 && Domain < 4 && "Invalid execution domain");
 6691   assert(dom && "Not an SSE instruction");
 6718           assert(!Is256 && "128-bit vector expected");
 6723       assert(table && table[Domain - 1] && "Unknown domain op");
 6781     assert(table && "Instruction not found in table?");
 6861   assert(Domain>0 && Domain<4 && "Invalid execution domain");
 6863   assert(dom && "Not an SSE instruction");
 6871     assert((Subtarget.hasAVX2() || Domain < 3) &&
 6877     assert((!table || Domain < 3) &&
 6881     assert(Subtarget.hasAVX2() &&
 6886     assert(Subtarget.hasAVX512() && "Requires AVX-512");
 6893     assert((Subtarget.hasDQI() || Domain >= 3) && "Requires AVX-512DQ");
 6901     assert((Subtarget.hasDQI() || Domain >= 3) && "Requires AVX-512DQ");
 6906   assert(table && "Cannot change domain");
 7236   assert((Inst.getNumOperands() == 3 || Inst.getNumOperands() == 4) &&
 7246     assert(Inst.getOperand(3).isReg() &&
 7578     assert(Op2.isReg() && (Op2.getReg() == X86::NoRegister ||
 7619         assert(Op2.getReg() != X86::NoRegister);
 7624         assert(Op2.getReg() != X86::NoRegister);
 7651     assert(!MI.isMoveImmediate() && "Unexpected MoveImm instruction");
 7667   assert(NewMI1.getNumOperands() == 4 && NewMI2.getNumOperands() == 4 &&
 7675   assert(OldOp1.isReg() && OldOp1.getReg() == X86::EFLAGS && OldOp1.isDead() &&
 7677   assert(OldOp2.isReg() && OldOp2.getReg() == X86::EFLAGS && OldOp2.isDead() &&
 7683   assert(NewOp1.isReg() && NewOp1.getReg() == X86::EFLAGS &&
 7685   assert(NewOp2.isReg() && NewOp2.getReg() == X86::EFLAGS &&
lib/Target/X86/X86InstrInfo.h
  156     assert(isFrameInstr(I));
  165     assert(isFrameInstr(I));
lib/Target/X86/X86InstructionSelector.cpp
  216   assert(Register::isPhysicalRegister(Reg));
  241     assert(I.isCopy() && "Generic operators do not allow physical registers");
  267   assert((!Register::isPhysicalRegister(SrcReg) || I.isCopy()) &&
  269   assert((DstSize == SrcSize ||
  308   assert(I.getParent() && "Instruction should be in a basic block!");
  309   assert(I.getParent()->getParent() && "Instruction should be in a function!");
  328   assert(I.getNumOperands() == I.getNumExplicitOperands() &&
  475   assert(I.getOperand(0).isReg() && "unsupported opperand.");
  476   assert(MRI.getType(I.getOperand(0).getReg()).isPointer() &&
  503   assert((Opc == TargetOpcode::G_STORE || Opc == TargetOpcode::G_LOAD) &&
  510   assert(I.hasOneMemOperand());
  563   assert((Opc == TargetOpcode::G_FRAME_INDEX || Opc == TargetOpcode::G_GEP) &&
  589   assert((I.getOpcode() == TargetOpcode::G_GLOBAL_VALUE) &&
  615     assert(AM.Base.Reg == 0 && AM.IndexReg == 0);
  635   assert((I.getOpcode() == TargetOpcode::G_CONSTANT) &&
  707   assert((I.getOpcode() == TargetOpcode::G_TRUNC ||
  773   assert((I.getOpcode() == TargetOpcode::G_ZEXT) && "unexpected instruction");
  781   assert(!(SrcTy == LLT::scalar(8) && DstTy == LLT::scalar(32)) &&
  783   assert(!(SrcTy == LLT::scalar(16) && DstTy == LLT::scalar(32)) &&
  884   assert((I.getOpcode() == TargetOpcode::G_ANYEXT) && "unexpected instruction");
  895   assert(DstRB.getID() == SrcRB.getID() &&
  898   assert(DstTy.getSizeInBits() > SrcTy.getSizeInBits() &&
  939   assert((I.getOpcode() == TargetOpcode::G_ICMP) && "unexpected instruction");
  990   assert((I.getOpcode() == TargetOpcode::G_FCMP) && "unexpected instruction");
 1059   assert(CC <= X86::LAST_VALID_COND && "Unexpected condition code.");
 1081   assert((I.getOpcode() == TargetOpcode::G_UADDE) && "unexpected instruction");
 1140   assert((I.getOpcode() == TargetOpcode::G_EXTRACT) &&
 1205   assert(SrcTy.getSizeInBits() > DstTy.getSizeInBits() &&
 1244   assert(SrcTy.getSizeInBits() < DstTy.getSizeInBits() &&
 1273   assert((I.getOpcode() == TargetOpcode::G_INSERT) && "unexpected instruction");
 1330   assert((I.getOpcode() == TargetOpcode::G_UNMERGE_VALUES) &&
 1355   assert((I.getOpcode() == TargetOpcode::G_MERGE_VALUES ||
 1405   assert((I.getOpcode() == TargetOpcode::G_BRCOND) && "unexpected instruction");
 1426   assert((I.getOpcode() == TargetOpcode::G_FCONSTANT) &&
 1491   assert((I.getOpcode() == TargetOpcode::G_IMPLICIT_DEF ||
 1520   assert((I.getOpcode() == TargetOpcode::G_SDIV ||
 1531   assert(RegTy == MRI.getType(Op1Reg) && RegTy == MRI.getType(Op2Reg) &&
 1720   assert(I.getOpcode() == TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS &&
lib/Target/X86/X86InterleavedAccess.cpp
  170   assert((isa<LoadInst>(VecInst) || isa<ShuffleVectorInst>(VecInst)) &&
  175   assert(VecWidth->isVectorTy() &&
  257   assert(VT.getSizeInBits() >= 256 &&
  691   assert(Matrix.size() == 4 && "Invalid matrix size");
  809   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
  811   assert(!Shuffles.empty() && "Empty shufflevector input");
  812   assert(Shuffles.size() == Indices.size() &&
  826   assert(Factor >= 2 && Factor <= getMaxSupportedInterleaveFactor() &&
  829   assert(SVI->getType()->getVectorNumElements() % Factor == 0 &&
lib/Target/X86/X86IntrinsicsInfo.h
 1159   assert(std::is_sorted(std::begin(IntrinsicsWithoutChain),
 1164   assert((std::adjacent_find(std::begin(IntrinsicsWithoutChain),
lib/Target/X86/X86LegalizerInfo.cpp
   48   assert(v.size() >= 1);
   49   assert(v[0].first > 1);
lib/Target/X86/X86MCInstLower.cpp
  120   assert((MO.isGlobal() || MO.isSymbol() || MO.isMBB()) &&
  150     assert(Suffix.empty());
  168       assert(MO.isGlobal() && "Extern symbol not handled yet");
  179       assert(MO.isGlobal() && "Extern symbol not handled yet");
  269       assert(MAI.doesSetDirectiveSuppressReloc());
  294   assert(Inst.getOperand(0).isReg() &&
  353   assert(
  479     assert(OutMI.getNumOperands() == 1 + X86::AddrNumOperands &&
  481     assert(OutMI.getOperand(1 + X86::AddrSegmentReg).getReg() == 0 &&
  719     assert(OutMI.getNumOperands() == 1 && "Unexpected number of operands!");
  753     assert(OutMI.getNumOperands() == 1 && "Unexpected number of operands!");
  759     assert(OutMI.getNumOperands() == 2 && "Unexpected number of operands!");
  766     assert(OutMI.getNumOperands() == X86::AddrNumOperands &&
  992   assert(Is64Bit && "EmitNops only supports X86-64");
 1082   assert(NopSize <= NumBytes && "We overemitted?");
 1093     assert(NopsToEmit >= NumBytes && "Emitted more than I asked for!");
 1099   assert(Subtarget->is64Bit() && "Statepoint currently only supports X86-64");
 1166   assert(FK < FaultMaps::FaultKindMax && "Invalid Faulting Kind!");
 1227       assert(NopSize == MinSize && "Could not implement MinSize!");
 1248   assert(Subtarget->is64Bit() && "Patchpoint currently only supports X86-64");
 1297   assert(NumBytes >= EncodedBytes &&
 1306   assert(Subtarget->is64Bit() && "XRay custom events only supports X86-64");
 1352       assert(Op->isReg() && "Only support arguments in registers");
 1400   assert(Subtarget->is64Bit() && "XRay typed events only supports X86-64");
 1448       assert(Op->isReg() && "Only supports arguments in registers");
 1619   assert((!C || ConstantEntry.getType() == C->getType()) &&
 1661     assert((SrcOp1Idx == 2 || SrcOp1Idx == 3) && "Unexpected writemask");
 1744   assert(MF->hasWinCFI() && "SEH_ instruction in function without WinCFI?");
 1745   assert(getSubtarget().isOSWindows() && "SEH_ instruction Windows only");
 1762       assert(MI->getOperand(1).getImm() == 0 &&
 1900     assert(Disp >= 0 && Disp <= INT32_MAX - 2 && "Unexpected displacement");
 1931     assert(Disp >= 0 && Disp <= INT32_MAX - 2 && "Unexpected displacement");
 2088     assert(MF->hasWinCFI() && "SEH_ instruction in function without WinCFI?");
 2142     assert(MI->getNumOperands() >= 6 &&
 2214     assert(MI->getNumOperands() >= 6 &&
 2234     assert(MI->getNumOperands() >= 8 &&
 2262     assert(MI->getNumOperands() >= 7 &&
lib/Target/X86/X86OptimizeLEAs.cpp
  133     assert(Val.Disp != PtrInfo::getEmptyKey() && "Cannot hash the empty key");
  134     assert(Val.Disp != PtrInfo::getTombstoneKey() &&
  189   assert((isLEA(MI) || MI.mayLoadOrStore()) &&
  213   assert(isValidDispOp(MO1) && isValidDispOp(MO2) &&
  314   assert(Last.getParent() == First.getParent() &&
  316   assert(InstrPos.find(&First) != InstrPos.end() &&
  365     assert(DistTemp != 0 &&
  397   assert(isSimilarDispOp(Op1, Op2) &&
  418   assert(isLEA(First) && isLEA(Last) &&
  493   assert(!LEAs.empty());
  538       assert(((InstrPos[DefMI] == 1 &&
  582     assert(MI.getOperand(1).getImm() == 0 && "DBG_VALUE with nonzero offset");
  606         assert(calcInstrDist(First, Last) > 0 &&
  659         assert(MRI->use_empty(LastVReg) &&
lib/Target/X86/X86PadShortFunction.cpp
  124       assert(MBB->size() > 0 &&
  130       assert(ReturnLoc->isReturn() && !ReturnLoc->isCall() &&
lib/Target/X86/X86RegisterBankInfo.cpp
   34   assert(&X86::GPRRegBank == &RBGPR && "Incorrect RegBanks inizalization.");
   38   assert(RBGPR.covers(*TRI.getRegClass(X86::GR64RegClassID)) &&
   40   assert(RBGPR.getSize() == 64 && "GPRs should hold up to 64-bit");
  227     assert(Ty1.getSizeInBits() == Ty2.getSizeInBits() &&
  232     assert((Size == 32 || Size == 64) && "Unsupported size for G_FCMP");
lib/Target/X86/X86RegisterInfo.cpp
  281   assert(MF && "MachineFunction required");
  345     assert(!Is64Bit && "CFGuard check mechanism only used on 32-bit X86");
  401   assert(MF && "Invalid MachineFunction pointer.");
  463     assert(!Is64Bit && "CFGuard check mechanism only used on 32-bit X86");
  603   assert(checkAllSuperRegsMarked(Reserved,
  617   assert(!(Mask[X86::EFLAGS / 32] & (1U << (X86::EFLAGS % 32))) &&
  731     assert((!needsStackRealignment(MF) ||
  771     assert(BasePtr == FramePtr && "Expected the FP as base register");
  781     assert((!Is64Bit || isInt<32>((long long)FIOffset + Imm)) &&
lib/Target/X86/X86RetpolineThunks.cpp
  138     assert(MF.getName() == "__llvm_retpoline_r11" &&
  196   assert(Name.startswith(ThunkNamePrefix) &&
lib/Target/X86/X86SelectionDAGInfo.cpp
   58   assert(!isBaseRegConflictPossible(DAG, ClobberSet));
  218   assert((Align != 0) && "Align is normalized");
  219   assert(isPowerOf2_64(Align) && "Align is a power of 2");
  251   assert(!Subtarget.hasERMSB() && "No efficient RepMovs");
  269   assert(BytesLeft && "We have leftover at this point");
lib/Target/X86/X86ShuffleDecodeConstantPool.cpp
   49   assert((CstSizeInBits % MaskEltSizeInBits) == 0 &&
   58     assert(NumCstElts == NumMaskElts && "Unaligned shuffle mask size");
  116   assert((Width == 128 || Width == 256 || Width == 512) &&
  127   assert((NumElts == 16 || NumElts == 32 || NumElts == 64) &&
  154   assert((Width == 128 || Width == 256 || Width == 512) &&
  157   assert((ElSize == 32 || ElSize == 64) && "Unexpected vector element size.");
  167   assert((NumElts == 2 || NumElts == 4 || NumElts == 8 || NumElts == 16) &&
  193   assert((MaskTySize == 128 || MaskTySize == 256) &&
  204   assert((NumElts == 2 || NumElts == 4 || NumElts == 8) &&
  248   assert(Width == 128 && Width >= MaskTySize && "Unexpected vector size.");
  257   assert(NumElts == 16 && "Unexpected number of vector elements.");
  297   assert((Width == 128 || Width == 256 || Width == 512) &&
  300   assert((ElSize == 8 || ElSize == 16 || ElSize == 32 || ElSize == 64) &&
  323   assert((Width == 128 || Width == 256 || Width == 512) &&
  326   assert((ElSize == 8 || ElSize == 16 || ElSize == 32 || ElSize == 64) &&
lib/Target/X86/X86SpeculativeLoadHardening.cpp
  227   assert(!Succ.isEHPad() && "Shouldn't get edges to EH pads!");
  240     assert(Br->getOperand(0).getMBB() == &Succ &&
  250       assert(MBB.isSuccessor(&OldLayoutSucc) &&
  266     assert(!UncondBr &&
  268     assert(NewMBB.isLayoutSuccessor(&Succ) &&
  293       assert(OpMBB.isMBB() && "Block operand to a PHI is not a block!");
  486     assert(ZeroEFLAGSDefOp && ZeroEFLAGSDefOp->isImplicit() &&
  518       assert(!MBB.isEHScopeEntry() && "Only Itanium ABI EH supported!");
  519       assert(!MBB.isEHFuncletEntry() && "Only Itanium ABI EH supported!");
  520       assert(!MBB.isCleanupFuncletEntry() && "Only Itanium ABI EH supported!");
  741           assert((InsertPt == CheckingMBB.end() || !InsertPt->isPHI()) &&
  816     assert(SuccCounts[UncondSucc] == 1 &&
  918         assert(Unfolded &&
 1064     assert(!MBB.isEHPad() &&
 1072     assert(!MBB.isLiveIn(X86::EFLAGS) &&
 1774         assert(!(HardenLoadAddr.count(&MI) && HardenPostLoad.count(&MI)) &&
 1781           assert(MemRefBeginIdx >= 0 && "Cannot have an invalid index here!");
 1796           assert(!MI.isCall() && "Must not try to post-load harden a call!");
 1854       assert(MI.isCall() && "Should only reach here for calls!");
 1968     assert(IndexMO.getReg() == X86::NoRegister &&
 1987     assert(BaseMO.isReg() &&
 1997   assert((HardenOpRegs.size() == 1 || HardenOpRegs.size() == 2) &&
 1999   assert((HardenOpRegs.size() == 1 ||
 2042       assert(Subtarget->hasAVX2() && "AVX2-specific register classes!");
 2080       assert(Subtarget->hasAVX512() && "AVX512-specific register classes!");
 2084         assert(Subtarget->hasVLX() && "AVX512VL-specific register classes!");
 2110       assert(OpRC->hasSuperClassEq(&X86::GR64RegClass) &&
 2136     assert(!AddrRegToHardenedReg.count(Op->getReg()) &&
 2150   assert(isDataInvariantLoad(InitialMI) &&
 2170           assert(isDataInvariant(UseMI) &&
 2179         assert(MemRefBeginIdx >= 0 &&
 2245   assert(RegIdx < 4 && "Unsupported register size");
 2283   assert(canHardenRegister(Reg) && "Cannot harden this register!");
 2284   assert(Register::isVirtualRegister(Reg) && "Cannot harden a physical register!");
 2607   assert(!MI.mayLoad() && "Found a lingering loading instruction!");
lib/Target/X86/X86TargetTransformInfo.cpp
   61   assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2");
  182   assert(ISD && "Invalid opcode");
  928         assert(NumElts >= NumSubElts && NumElts > OrigSubElts &&
  943         assert(SubTp->getPrimitiveSizeInBits() == 16 &&
 1275   assert(ISD && "Invalid opcode");
 1702   assert(ISD && "Invalid opcode");
 2377   assert(Val->isVectorTy() && "This must be a vector type");
 2437   assert((Opcode == Instruction::Load || Opcode == Instruction::Store) &&
 2589   assert(ISD && "Invalid opcode");
 2693     assert(ValTy->isFPOrFPVectorTy() &&
 2927   assert(Ty->isIntegerTy());
 2962   assert(Ty->isIntegerTy());
 3059   assert(Ty->isIntegerTy());
 3111   assert(isa<VectorType>(SrcVTy) && "Unexpected type in getGSVectorCost");
 3219   assert(SrcVTy->isVectorTy() && "Unexpected data type for Gather/Scatter");
 3224   assert(PtrTy && "Unexpected type for Ptr argument");
 3582     assert(Opcode == Instruction::Store &&
 3688   assert(Opcode == Instruction::Store &&
lib/Target/X86/X86VZeroUpper.cpp
  169   assert(MI.isCall() && "Can only be called on call instructions.");
  309   assert(BlockStates.empty() && DirtySuccessors.empty() &&
lib/Target/X86/X86WinAllocaExpander.cpp
   80   assert(MI->getOpcode() == X86::WIN_ALLOCA_32 ||
   82   assert(MI->getOperand(0).isReg());
  212   assert(SlotSize == 4 || SlotSize == 8);
  216     assert(Amount >= SlotSize);
  230     assert(Amount > 0);
lib/Target/X86/X86WinEHState.cpp
  126   assert(TheModule == &M);
  274   assert(Personality == EHPersonality::MSVC_CXX ||
  521   assert(BBColors.size() == 1 && "multi-color BB not removed by preparation");
  539     assert(FuncInfo.InvokeStateMap.count(II) && "invoke has no state!");
  574     assert(PredState != OverdefinedState &&
  610     assert(SuccState != OverdefinedState &&
lib/Target/XCore/MCTargetDesc/XCoreInstPrinter.cpp
   57     assert(SRE && CE && "Binary expression must be sym+const.");
   61     assert(SRE && "Unexpected MCExpr type.");
   63   assert(SRE->getKind() == MCSymbolRefExpr::VK_None);
   87   assert(Op.isExpr() && "unknown operand kind in printOperand");
lib/Target/XCore/XCoreAsmPrinter.cpp
   89   assert( ( GV->hasExternalLinkage() || GV->hasWeakLinkage() ||
lib/Target/XCore/XCoreFrameLowering.cpp
  103     assert(Adjusted < FrameSize && "OffsetFromTop is beyond FrameSize");
  126     assert(RemainingAdj && "OffsetFromTop is beyond FrameSize");
  164   assert(XFI->hasEHSpillSlot() && "There are no EH register spill slots");
  196     assert(SpillList[i].Offset % 4 == 0 && "Misaligned stack offset");
  197     assert(SpillList[i].Offset <= 0 && "Unexpected positive stack offset");
  225   assert(&MF.front() == &MBB && "Shrink-wrapping not yet supported");
  247   assert(MFI.getStackSize()%4 == 0 && "Misaligned frame size");
  281     assert(SpillList[i].Offset % 4 == 0 && "Misaligned stack offset");
  282     assert(SpillList[i].Offset <= 0 && "Unexpected positive stack offset");
  303   assert(Adjusted==FrameSize && "IfNeededExtSP has not completed adjustment");
  332       assert(SpillList.size()==2 && "Unexpected SpillList size");
  355   assert(RemainingAdj%4 == 0 && "Misaligned frame size");
  398       assert(RetOpcode == XCore::RETSP_u6
  435     assert(Reg != XCore::LR && !(Reg == XCore::R10 && hasFP(*MF)) &&
  465     assert(Reg != XCore::LR && !(Reg == XCore::R10 && hasFP(*MF)) &&
  470     assert(MI != MBB.begin() &&
  502       assert(Amount%4 == 0);
  520         assert(Old.getOpcode() == XCore::ADJCALLSTACKUP);
  575   assert(RS && "requiresRegisterScavenging failed");
lib/Target/XCore/XCoreISelLowering.cpp
  359   assert((NumEntries >> 31) == 0);
  413   assert(LD->getExtensionType() == ISD::NON_EXTLOAD &&
  415   assert(LD->getMemoryVT() == MVT::i32 && "Unexpected load EVT");
  488   assert(!ST->isTruncatingStore() && "Unexpected store type");
  489   assert(ST->getMemoryVT() == MVT::i32 && "Unexpected store EVT");
  541   assert(Op.getValueType() == MVT::i32 && Op.getOpcode() == ISD::SMUL_LOHI &&
  558   assert(Op.getValueType() == MVT::i32 && Op.getOpcode() == ISD::UMUL_LOHI &&
  694   assert(N->getValueType(0) == MVT::i64 &&
  939   assert(N->getOpcode() == ISD::ATOMIC_LOAD && "Bad Atomic OP");
  940   assert((N->getOrdering() == AtomicOrdering::Unordered ||
  970   assert(N->getOpcode() == ISD::ATOMIC_STORE && "Bad Atomic OP");
  971   assert((N->getOrdering() == AtomicOrdering::Unordered ||
 1074       assert(VA.isMemLoc());
 1165       assert(VA.isMemLoc());
 1319       assert(VA.isMemLoc());
 1472     assert(VA.isMemLoc());
 1527   assert((MI.getOpcode() == XCore::SELECT_CC) &&
 1792     assert((StoreBits % 8) == 0 &&
lib/Target/XCore/XCoreInstrInfo.cpp
  278   assert(TBB && "insertBranch must not be told to insert a fallthrough");
  279   assert((Cond.size() == 2 || Cond.size() == 0) &&
  281   assert(!BytesAdded && "code size not handled");
  297   assert(Cond.size() == 2 && "Unexpected number of components!");
  307   assert(!BytesRemoved && "code size not handled");
  404   assert((Cond.size() == 2) &&
lib/Target/XCore/XCoreMCInstLower.cpp
   70   assert(Offset > 0);
lib/Target/XCore/XCoreMachineFunctionInfo.h
   56     assert(LRSpillSlotSet && "LR Spill slot not set");
   63     assert(FPSpillSlotSet && "FP Spill slot not set");
   70     assert(EHSpillSlotSet && "EH Spill slot not set");
   75     assert(!ReturnStackOffsetSet && "Return stack offset set twice");
   81     assert(ReturnStackOffsetSet && "Return stack offset not set");
lib/Target/XCore/XCoreRegisterInfo.cpp
   96   assert(RS && "requiresRegisterScavenging failed");
  164   assert(RS && "requiresRegisterScavenging failed");
  262   assert(SPAdj == 0 && "Unexpected");
  299   assert(Offset%4 == 0 && "Misaligned stack offset");
  305   assert(XCore::GRRegsRegClass.contains(Reg) && "Unexpected register operand");
lib/Target/XCore/XCoreTargetObjectFile.cpp
  139   assert((Kind.isThreadLocal() || Kind.isCommon()) && "Unknown section kind");
  150   assert((Kind.isReadOnly() || Kind.isReadOnlyWithRel()) &&
lib/TextAPI/MachO/TextStub.cpp
  289     assert((!Ctx || (Ctx && Ctx->FileKind != FileType::Invalid)) &&
  311     assert((!Ctx || (Ctx && Ctx->FileKind != FileType::Invalid)) &&
  614       assert(Ctx);
  763     assert((!Ctx || !IO.outputting() ||
  806       assert(Ctx);
  909       assert(Ctx);
lib/TextAPI/MachO/TextStubCommon.cpp
   48   assert((!Ctx || Ctx->FileKind != FileType::Invalid) &&
   57   assert(Values.size() == 1U);
   83   assert((!Ctx || Ctx->FileKind != FileType::Invalid) &&
  178   assert((!Ctx || Ctx->FileKind != FileType::Invalid) &&
lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp
  114     assert((IID == Intrinsic::fshl || IID == Intrinsic::fshr) &&
lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp
  202   assert(MinBitWidth >= TruncBitWidth);
  278   assert(Ty && !Ty->isVectorTy() && "Expect Scalar Type");
  296   assert(Entry.NewValue);
  305     assert(!NodeInfo.NewValue && "Instruction has been evaluated");
  319         assert(!isa<TruncInst>(I) && "Cannot reach here with TruncInst");
lib/Transforms/CFGuard/CFGuard.cpp
  160   assert(Triple(CB->getModule()->getTargetTriple()).isOSWindows() &&
  162   assert(CB->isIndirectCall() &&
  184   assert(Triple(CB->getModule()->getTargetTriple()).isOSWindows() &&
  186   assert(CB->isIndirectCall() &&
  211     assert(isa<InvokeInst>(CB) && "Unknown indirect call type");
  247     assert(GuardMechanism == CF_Dispatch && "Invalid CFGuard mechanism");
lib/Transforms/Coroutines/CoroElide.cpp
   58     assert(ValueTy->isPointerTy() && IntrTy->isPointerTy());
  230   assert(Resumers && "PostSplit coro.id Info argument must refer to an array"
  268   assert(DevirtFn && "coro.devirt.fn not found");
lib/Transforms/Coroutines/CoroFrame.cpp
   58     assert(I != V.end() && *I == BB && "BasicBlockNumberng: Unknown block");
  108     assert(Block[UseIndex].Consumes[DefIndex] && "use must consume def");
  131       assert(UseBB && "should have split coro.suspend into its own block");
  149       assert(DefBB && "should have split coro.suspend into its own block");
  307     assert(FieldNo != InvalidFieldIndex && "Accessing unassigned field");
  311     assert(FieldNo == InvalidFieldIndex && "Reassigning field number");
  424     assert(PromiseAlloca == nullptr && "lowering doesn't support promises");
  611     assert(Shape.ABI == coro::ABI::Switch);
  641     assert(Index != InvalidFieldIndex && "accessing unassigned field number");
  702           assert(!I->isTerminator() && "unexpected terminator");
  732       assert(PN->getNumIncomingValues() == 1 && "unexpected number of incoming "
  829     assert(BBIdx != (unsigned)-1 && "Invalid PHI Index!");
  979       assert(PN->getNumIncomingValues() == 1 && "unexpected number of incoming "
 1240     assert(isa<CallInst>(User) || isa<InvokeInst>(User));
 1250   assert(isAllocaPromotable(Alloca));
lib/Transforms/Coroutines/CoroInstr.h
   51     assert(Index >= IndexFirst && Index < IndexLast &&
  130     assert((isa<BitCastInst>(Arg) || isa<GetElementPtrInst>(Arg)) &&
  168     assert(GV->isConstant() && GV->hasDefinitiveInitializer());
  186     assert(isa<ConstantPointerNull>(getArgOperand(CoroutineArg)) &&
  380     assert(isa<ConstantTokenNone>(Arg));
lib/Transforms/Coroutines/CoroInternal.h
  133     assert(ABI == coro::ABI::Switch);
  138     assert(ABI == coro::ABI::Retcon ||
  144     assert(ABI == coro::ABI::Switch);
  145     assert(FrameTy && "frame type not assigned");
  153     assert(ABI == coro::ABI::Switch);
  154   assert(FrameTy && "frame type not assigned");
  172     assert(ABI == coro::ABI::Retcon ||
  185     assert(ABI == coro::ABI::Retcon ||
lib/Transforms/Coroutines/CoroSplit.cpp
  112     assert(Shape.ABI == coro::ABI::Switch);
  121     assert(Shape.ABI == coro::ABI::Retcon ||
  123     assert(NewF && "need existing function for continuation");
  124     assert(ActiveSuspend && "need active suspend point for continuation");
  128     assert(NewF != nullptr && "declaration not yet set");
  162   assert(Shape.ABI == coro::ABI::Retcon ||
  264   assert(Shape.ABI == coro::ABI::Switch);
  372   assert(Shape.ABI == coro::ABI::Switch &&
  415   assert(Shape.ABI == coro::ABI::Retcon ||
  430     assert(Args.size() == 1);
  502       assert(CachedSlot->getType()->getPointerElementType() == ValueTy &&
  511         assert(Arg.getType()->getPointerElementType() == ValueTy &&
  537       assert(Op->getNumArgOperands() == 1);
  573   assert(Entry->hasOneUse());
  575   assert(BranchToEntry->isUnconditional());
  602     assert(Branch->isUnconditional());
  751     assert(ActiveSuspend != nullptr &&
  822   assert(Shape.ABI == coro::ABI::Switch);
  825   assert(!Args.empty());
  844   assert(Shape.ABI == coro::ABI::Switch);
 1158   assert(Shape.ABI == coro::ABI::Switch);
 1177   assert(Clones.empty());
 1190   assert(Shape.ABI == coro::ABI::Retcon ||
 1192   assert(Clones.empty());
 1265       assert(ReturnPHIs.empty());
 1306     assert(NextPHIIndex == ReturnPHIs.size());
 1309   assert(Clones.size() == Shape.CoroSuspends.size());
 1387   assert(DevirtFn && "coro.devirt.trigger function not found");
lib/Transforms/Coroutines/Coroutines.cpp
  112   assert(Index >= CoroSubFnInst::IndexFirst &&
  156     assert(isCoroutineIntrinsicName(Name) && "not a coroutine intrinsic");
  242   assert(!SuspendInst->getCoroSave());
lib/Transforms/IPO/ArgumentPromotion.cpp
  202         assert(Params.back());
  244     assert(CS.getCalledFunction() == F);
  430         assert(ArgIndices.begin()->second.empty() &&
  452           assert(It != ArgIndices.end() && "GEP not handled??");
  495     assert(CS && "Should only have direct calls!");
  615       assert(SafeToUnconditionallyLoad.empty());
  812   assert(arg->hasByValAttr());
 1038         assert(&F == &OldF && "Called with an unexpected function!");
lib/Transforms/IPO/Attributor.cpp
  217       assert(LivenessAA &&
  406     assert(ICS && "Expected call site!");
  414     assert(ICS && "Expected call site!");
  428     assert(ICS && ArgNo >= 0 && "Expected call site!");
  472     assert(KindOrArgNo >= 0 && "Expected argument or call site argument!");
  473     assert((isa<CallBase>(AnchorVal) || isa<Argument>(AnchorVal)) &&
  476       assert(cast<Argument>(AnchorVal)->getArgNo() == unsigned(getArgNo()) &&
  478       assert(cast<Argument>(AnchorVal) == &getAssociatedValue() &&
  481       assert(cast<CallBase>(*AnchorVal).arg_size() > unsigned(getArgNo()) &&
  483       assert(cast<CallBase>(*AnchorVal).getArgOperand(getArgNo()) ==
  489     assert(!AnchorVal && "Expected no value for an invalid position!");
  492     assert((!isa<CallBase>(&getAssociatedValue()) &&
  497     assert(isa<Function>(AnchorVal) &&
  499     assert(AnchorVal == &getAssociatedValue() && "Associated value mismatch!");
  502     assert((isa<CallBase>(AnchorVal)) &&
  504     assert(AnchorVal == &getAssociatedValue() && "Associated value mismatch!");
  507     assert((isa<CallBase>(AnchorVal)) &&
  509     assert(AnchorVal == &getAssociatedValue() && "Associated value mismatch!");
  512     assert(isa<Function>(AnchorVal) &&
  514     assert(AnchorVal == &getAssociatedValue() && "Associated value mismatch!");
  540   assert((QueryingAA.getIRPosition().getPositionKind() ==
  614   assert(QueryingAA.getIRPosition().getPositionKind() ==
  675     assert(this->getIRPosition().getPositionKind() ==
  966   assert(isValidState());
 1004       assert(isa<CallBase>(AnchorValue) &&
 1221     assert(!It.second.empty() && "Entry does not add anything.");
 1362   assert(!ImmutableCallSite(I) && !isa<CallBase>(I) &&
 2138     assert(getState().isValidState() &&
 2199           assert(!NormalDestBB->isLandingPad() &&
 2236     assert(BB->getParent() == getAssociatedFunction() &&
 2251     assert(I->getParent()->getParent() == getAssociatedFunction() &&
 2418     assert(!isValidState() && "Expected an invalid state!");
 3163   assert(F && "Expected a function!");
 3551     assert(getState().isValidState() &&
 3807     assert(Attrs.size() == 0);
 3814     assert(Attrs.size() <= 1);
 4156   assert(UserI->mayReadOrWriteMemory());
 4593   assert(
 4688       assert((!ImmutableCallSite(&I)) && (!isa<CallBase>(&I)) &&
 4841   assert(Success && !AnyDead && "Expected the check call to be successful!");
 4856   assert(Success && !AnyDead && "Expected the check call to be successful!");
lib/Transforms/IPO/CalledValuePropagation.cpp
   73     assert(std::is_sorted(this->Functions.begin(), this->Functions.end(),
lib/Transforms/IPO/ConstantMerge.cpp
  109   assert(!hasMetadataOtherThanDebugLoc(New));
  129   assert(Old->hasLocalLinkage() &&
lib/Transforms/IPO/CrossDSOCFI.cpp
   95       assert(Func->getNumOperands() >= 2);
  124   assert(args == F->arg_end());
lib/Transforms/IPO/DeadArgumentElimination.cpp
  123   assert(Fn.getFunctionType()->isVarArg() && "Function isn't varargs!");
  344   assert(!RetTy->isVoidTy() && "void type has no subtype");
  445         assert(CS.getArgument(ArgNo)
  819         assert(isa<ArrayType>(RetTy) && "unexpected multi-value return");
  831   assert(NRetTy && "No new return type found?");
  843     assert(!RAttrs.overlaps(AttributeFuncs::typeIncompatible(NRetTy)) &&
  853   assert(ArgAttrVec.size() == Params.size());
  923     assert(ArgAttrVec.size() == Args.size());
  966         assert((RetTy->isStructTy() || RetTy->isArrayTy()) &&
 1040           assert(RetTy->isStructTy() || RetTy->isArrayTy());
lib/Transforms/IPO/ExtractGV.cpp
   35     assert(!GV.isDiscardableIfUnused());
lib/Transforms/IPO/FunctionAttrs.cpp
  383     assert(UseIndex < CS.data_operands_size() &&
  388       assert(CS.hasOperandBundles() && "Must be!");
  399       assert(F->isVarArg() && "More params than args in non-varargs call");
  518       assert(UseIndex < CS.data_operands_size() &&
  524         assert(F->isVarArg() && "More params than args in non-varargs call");
  665   assert((R == Attribute::ReadOnly || R == Attribute::ReadNone)
  667   assert(A && "Argument must not be null.");
  971   assert(F->getReturnType()->isPointerTy() &&
 1559   assert(!F.isDeclaration() && "Cannot deduce norecurse without a definition!");
 1560   assert(!F.doesNotRecurse() &&
 1562   assert(F.hasInternalLinkage() &&
lib/Transforms/IPO/FunctionImport.cpp
  404       assert(PreviouslyVisited);
  426           assert(FailureInfo &&
  443             assert(FailureInfo &&
  451           assert(!FailureInfo &&
  465       assert(ResolvedCalleeSummary->instCount() <= NewThreshold &&
  578       assert(FailureInfo);
  718     assert(GlobalList.second.SummaryList.size() == 1 &&
  737   assert(!Index.withGlobalValueDeadStripping());
  886       assert(DS != DefinedGVSummaries.end() &&
  982         assert(GV.hasLinkOnceODRLinkage() && GV.hasGlobalUnnamedAddr());
 1036         assert(GS != DefinedGlobals.end());
 1091     assert(FunctionsToImportPerModule != ImportList.end());
 1096     assert(&DestModule.getContext() == &SrcModule->getContext() &&
lib/Transforms/IPO/GlobalOpt.cpp
  467   assert(GV->hasLocalLinkage());
  485       assert(In && "Couldn't get element of initializer?");
  520       assert(In && "Couldn't get element of initializer?");
  554     assert(((isa<ConstantExpr>(GEP) &&
  773       assert(GlobalUser->getOperand(1) == GV &&
  780       assert((isa<PHINode>(GlobalUser) || isa<SelectInst>(GlobalUser) ||
 1202     assert(isa<ConstantPointerNull>(SCI->getOperand(1)));
 1218     assert(GEPI->getNumOperands() >= 3 && isa<ConstantInt>(GEPI->getOperand(2))
 1410     assert(isa<ConstantPointerNull>(SI->getOperand(0)) &&
 1429     assert(FieldPN->getNumIncomingValues() == 0 &&"Already processed this phi");
 1639   assert(InitVal->getType() != Type::getInt1Ty(GV->getContext()) &&
 1716           assert(LI->getOperand(0) == GV && "Not a copy!");
 1722           assert((isa<CastInst>(StoredVal) || isa<SelectInst>(StoredVal)) &&
 1725           assert(isa<LoadInst>(StoreVal) && "Not a load of NewGV!");
 1817     assert(I->getParent()->getParent() == F);
 1898       assert(
 2392     assert(Val->getType() == Init->getType() && "Type mismatch!");
 2405     assert(Idx < STy->getNumElements() && "Struct index out of range!");
 2420   assert(CI->getZExtValue() < NumElts);
 2433     assert(GV->hasInitializer());
 2509     assert(GVPair.first->hasInitializer());
 2529         assert(CurrentGV && "Expected a GV to commit to!");
 2689   assert((!U.usedCount(&GA) || !U.compilerUsedCount(&GA)) &&
 2704   assert((!U.usedCount(&V) || !U.compilerUsedCount(&V)) &&
lib/Transforms/IPO/HotColdSplitting.cpp
  146   assert(!F.hasOptNone() && "Can't mark this cold");
  297   assert(!Region.empty());
  498     assert(!empty() && !isEntireFunctionCold() && "Nothing to extract");
  615     assert(!Region.empty() && "Empty outlining region in worklist");
lib/Transforms/IPO/IPConstantPropagation.cpp
  125   assert(NumNonconstant != ArgumentConstants.size());
lib/Transforms/IPO/Inliner.cpp
  486     assert(unsigned(InlineHistoryID) < InlineHistory.size() &&
  867     assert(InlinerFunctionImportStats != InlinerFunctionImportStatsOpts::No);
  880   assert(InitialC.size() > 0 && "Cannot handle an empty SCC!");
 1131           assert(find(DeadFunctions, &Callee) == DeadFunctions.end() &&
lib/Transforms/IPO/LowerTypeTests.cpp
  877     assert(GV->getType()->getAddressSpace() == 0);
 1047   assert(F->getType()->getAddressSpace() == 0);
 1480   assert(!Functions.empty());
 1534         assert(F->getType()->getAddressSpace() == 0);
 1561   assert(!Functions.empty());
 1659   assert(!(ExportSummary && ImportSummary));
 1853         assert(FuncMD->getNumOperands() >= 2);
 2137         assert(AliasMD->getNumOperands() >= 4);
 2179         assert(Symver->getNumOperands() >= 2);
lib/Transforms/IPO/MergeFunctions.cpp
  486     assert(DestTy->isStructTy());
  487     assert(SrcTy->getStructNumElements() == DestTy->getStructNumElements());
  499   assert(!DestTy->isStructTy());
  759   assert(F->hasLocalLinkage() || F->hasExternalLinkage()
  802     assert(G->isInterposable());
  866   assert(FunctionComparator(F, G, &GlobalNumbers).compare() == 0 &&
  870   assert(I != FNodesInTree.end() && "F should be in FNodesInTree");
  871   assert(FNodesInTree.count(G) == 0 && "FNodesInTree should not contain G");
  874   assert(&(*IterToFNInFnTree) == &FN && "F should map to FN in FNodesInTree.");
  907     assert(FNodesInTree.count(NewFunction) == 0);
  921     assert(OldF.getFunc() != F && "Must have swapped the functions.");
lib/Transforms/IPO/PartialInlining.cpp
  637   assert(OutliningInfo->Entries[0] == &F->front() &&
  768   assert(Callee == Cloner.ClonedFunc);
  778   assert(Call && "invalid callsite for partial inline");
  904   assert(OutlinedFunctionCost >= Cloner.OutlinedRegionCost &&
  954       assert(CurrentCallerBFI && "CallerBFI is not set");
 1111   assert(ClonedOMRI && "Expecting OutlineInfo for multi region outline");
 1159       assert(OutliningCallBB->getParent() == ClonedFunc);
 1190   assert(ClonedOI && "Expecting OutlineInfo for single region outline");
 1228     assert(OutliningCallBB->getParent() == ClonedFunc);
 1377   assert(Cloner.OrigFunc->users().empty() &&
lib/Transforms/IPO/PruneEH.cpp
  232   assert(pred_empty(BB) && "BB is not dead!");
lib/Transforms/IPO/SampleProfile.cpp
  499   assert(PSI && "PSI is expected to be non null");
  595   assert(Used <= Total &&
  854   assert(isa<CallInst>(I) || isa<InvokeInst>(I));
  857   assert(CalledFunction);
  906   assert((!ProfAccForSymsInList ||
lib/Transforms/IPO/StripSymbols.cpp
  141   assert(C->use_empty() && "Constant is not dead!");
  261       assert(CI->use_empty() && "llvm.dbg intrinsic should have void result");
lib/Transforms/IPO/SyntheticCountsPropagation.cpp
  113     assert(isa<Instruction>(Edge.first));
lib/Transforms/IPO/WholeProgramDevirt.cpp
  484     assert(!(ExportSummary && ImportSummary));
  717     assert(VI.getSummaryList().size() == 1 &&
  726       assert(TIdSum);
  728       assert(WPDRes != TIdSum->WPDRes.end());
  846     assert(P.VTableVI.getSummaryList().size() == 1 ||
 1024   assert(!Res->SingleImplName.empty());
 1336     assert(UniqueMember);
 1692     assert(!Res.SingleImplName.empty());
 1703     assert(!IsExported);
 1748     assert(!IsExported);
 1983     assert(TidSummary);
lib/Transforms/InstCombine/InstCombineAddSub.cpp
   65       assert(!insaneIntVal(C) && "Insane coefficient");
   91       assert(IsFp && BufHasFpVal && "Incorret state");
   96       assert(IsFp && BufHasFpVal && "Incorret state");
  133       assert((Val == T.Val) && "Symbolic-values disagree");
  304     assert(!insaneIntVal(Res) && "Insane int value");
  427   assert(I->hasAllowReassoc() && I->hasNoSignedZeros() &&
  434   assert((I->getOpcode() == Instruction::FAdd ||
  515   assert(AddendNum <= 4 && "Too many addends");
  583   assert((NextTmpIdx <= array_lengthof(TmpResult) + 1) &&
  602   assert(!Opnds.empty() && "Expect at least one addend");
  651   assert(CreateInstrNum == InstrNeeded &&
 1079   assert(I.getOpcode() == Instruction::Add && "Expecting add instruction");
 1103   assert((I.getOpcode() == Instruction::Add ||
 1435   assert((I.getOpcode() == Instruction::FAdd ||
 1437   assert(I.hasAllowReassoc() && I.hasNoSignedZeros() &&
 1691       assert(BO->getOpcode() == Instruction::Sub &&
lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
   28   assert(FCmpInst::FCMP_FALSE <= CC && CC <= FCmpInst::FCMP_TRUE &&
   68   assert(FCmpInst::FCMP_FALSE <= Pred && Pred <= FCmpInst::FCMP_TRUE &&
   84   assert(I.isBitwiseLogicOp() && "Unexpected opcode for bswap simplifying");
  167   assert((isSigned ? Lo.slt(Hi) : Lo.ult(Hi)) &&
  558   assert(IsSubSetOrEqual(BCst, DCst) && "Precondition due to above code");
  577   assert(ICmpInst::isEquality(PredL) && ICmpInst::isEquality(PredR) &&
  614   assert(ICmpInst::isEquality(PredL) && ICmpInst::isEquality(PredR) &&
  931   assert(CxtI.getOpcode() == Instruction::And);
  959   assert(HighestBit.isPowerOf2() && "expected to be power of two (non-zero)");
  987   assert(!UnsetBitsMask.isNullValue() && "empty mask makes no sense.");
 1288   assert(LHSC != RHSC && "Compares not folded above?");
 1416   assert((Opcode == Instruction::And || Opcode == Instruction::Or) &&
 1461   assert((Opcode == Instruction::And || Opcode == Instruction::Or) &&
 1537   assert(I.isBitwiseLogicOp() && "Unexpected opcode for bitwise logic folding");
 1603   assert(I.getOpcode() == Instruction::And);
 1629   assert(I.getOpcode() == Instruction::Or);
 1980   assert(Or.getOpcode() == Instruction::Or && "bswap requires an 'or'");
 2380   assert(LHSC != RHSC && "Compares not folded above?");
 2419       assert(!RHSC->isMaxValue(false) && "Missed icmp simplification");
 2436       assert(!RHSC->isMaxValue(true) && "Missed icmp simplification");
 2739   assert(I.getOpcode() == Instruction::Xor);
 2799   assert(I.getOpcode() == Instruction::Xor && I.getOperand(0) == LHS &&
lib/Transforms/InstCombine/InstCombineAtomicRMW.cpp
  113   assert(Ordering != AtomicOrdering::NotAtomic &&
lib/Transforms/InstCombine/InstCombineCalls.cpp
  100     assert((isa<ConstantInt>(Elt) || isa<ConstantFP>(Elt)) &&
  144   assert(Size && "0-sized memory transferring should be removed already.");
  250   assert(Len && "0-sized memory setting should be removed already.");
  354   assert((LogicalShift || !ShiftLeft) && "Only logical shifts can shift left");
  370     assert((64 % BitWidth) == 0 && "Unexpected packed shift size");
  464   assert((LogicalShift || !ShiftLeft) && "Only logical shifts can shift left");
  514         assert(LogicalShift && "Logical shift expected");
  557   assert(ResTy->getVectorNumElements() == (2 * NumSrcElts) &&
  563   assert(SrcScalarSizeInBits == (2 * DstScalarSizeInBits) &&
  647   assert(RetTy->getStructElementType(0)->isIntegerTy(8) &&
  674   assert(VecTy->getNumElements() == 4 && "insertps with wrong vector type");
  924   assert((NumElts == 16 || NumElts == 32 || NumElts == 64) &&
  973   assert(NumElts == 16 || NumElts == 8 || NumElts == 4 || NumElts == 2);
 1021   assert((Size == 4 || Size == 8 || Size == 16 || Size == 32 || Size == 64) &&
 1183   assert((II.getIntrinsicID() == Intrinsic::cttz ||
 1259   assert(II.getIntrinsicID() == Intrinsic::ctpop &&
 1384   assert(Cmp0 != APFloat::cmpUnordered && "nans handled separately");
 1389   assert(Cmp1 != APFloat::cmpUnordered && "nans handled separately");
 1462   assert(I.getNumArgOperands() >= NumOperands && "Not enough operands");
 1463   assert(E.getNumArgOperands() >= NumOperands && "Not enough operands");
 1481   assert(I.getIntrinsicID() == StartID &&
 1759   assert(Call.getNumArgOperands() > 1 && "Need at least 2 args to swap");
 1959       assert(ConstantExpr::getICmp(ICmpInst::ICMP_UGT, WidthC, ShAmtC) ==
 1973       assert(IID == Intrinsic::fshl &&
 2463     assert(RetWidth <= ArgWidth && "Unexpected input/return vector widths");
 2464     assert(ArgType->isIntOrIntVectorTy() &&
 2467     assert(RetType->getScalarType()->isFloatTy() &&
 2795     assert(Arg1->getType()->getPrimitiveSizeInBits() == 128 &&
 2908     assert(Op0->getType()->getPrimitiveSizeInBits() == 128 &&
 2946     assert(Op0->getType()->getPrimitiveSizeInBits() == 128 && VWidth == 2 &&
 2970     assert(Op0->getType()->getPrimitiveSizeInBits() == 128 &&
 3007     assert(Op0->getType()->getPrimitiveSizeInBits() == 128 &&
 3069       assert(Mask->getType()->getPrimitiveSizeInBits() ==
 3165       assert(Mask->getType()->getVectorNumElements() == 16 &&
 3315     assert(II->getArgOperand(CarryOp)->getType()->getScalarSizeInBits() == 32 &&
 3553     assert(Width != 0);
 4286   assert(ArgNo == Call.arg_size() && "sanity check");
 4619   assert((ArgAttrs.size() == FT->getNumParams() || FT->isVarArg()) &&
lib/Transforms/InstCombine/InstCombineCasts.cpp
  319   assert(!isa<Constant>(V) && "Constant should already be handled.");
  366     assert(BitWidth < OrigBitWidth && "Unexpected bitwidths!");
  496   assert((isa<VectorType>(Trunc.getSrcTy()) ||
  660   assert((Opcode == Instruction::Trunc || Opcode == Instruction::FPTrunc) &&
  705     assert(Res->getType() == DestTy);
 1105     assert(BitsToClear <= SrcTy->getScalarSizeInBits() &&
 1114     assert(Res->getType() == DestTy);
 1313   assert(V->getType()->getScalarSizeInBits() < Ty->getScalarSizeInBits() &&
 1386     assert(Res->getType() == DestTy);
 1900   assert(isMultipleOfTypeSize(Shift, VecEltTy) &&
 2245       assert(NewV);
 2270           assert(hasStoreUsersOnly(*NewBC));
 2443       assert(ShufOp0->getType() == SrcTy && "Unexpected shuffle mask");
 2444       assert(isa<UndefValue>(ShufOp1) && "Unexpected shuffle op");
lib/Transforms/InstCombine/InstCombineCompares.cpp
  104   assert(Known.getBitWidth() == Min.getBitWidth() &&
  126   assert(Known.getBitWidth() == Min.getBitWidth() &&
  363     assert(TrueRangeEnd != FirstTrueElement && "Should emit single compare");
  378     assert(FalseRangeEnd != FirstFalseElement && "Should emit single compare");
  638   assert(isa<Constant>(V) && "Setting insertion point for unknown value!");
 1027   assert(ICI.isEquality() && "Cannot fold non-equality comparison.");
 1054     assert(Worklist.size() <= MaxIter);
 1107   assert(!!C && "C should not be zero!");
 1144   assert(Pred == ICmpInst::ICMP_SGT || Pred == ICmpInst::ICMP_SGE);
 1155   assert(I.isEquality() && "Cannot fold icmp gt/lt");
 1214   assert(I.isEquality() && "Cannot fold icmp gt/lt");
 1471   assert((TrueBB == CmpBB || FalseBB == CmpBB) &&
 2063       assert(!C.isMinSignedValue() && "Unexpected icmp slt");
 2093       assert(C.ugt(0) && "ult 0 should have been eliminated");
 2235   assert(((IsAShr && C.shl(ShAmtVal).ashr(ShAmtVal) == C) ||
 2302   assert(*C2 != 0 && "udiv 0, X should have been simplified already.");
 2307     assert(!C.isMaxValue() &&
 2315     assert(C != 0 && "icmp ult X, 0 should have been simplified already.");
 2665     assert(FlippedStrictness->first == ICmpInst::ICMP_SGE && "Sanity check");
 2678   assert(C && "Cmp RHS should be a constant int!");
 2689     assert(C1LessThan && C2Equal && C3GreaterThan);
 3305     assert(X == I.getOperand(0) && "instsimplify took care of commut. variant");
 3310     assert(X == I.getOperand(1) && "instsimplify took care of commut. variant");
 3315     assert(X == I.getOperand(1) && "instsimplify took care of commut. variant");
 3320     assert(X == I.getOperand(0) && "instsimplify took care of commut. variant");
 3401   assert(MaskedBits != 0 && "shift by zero should be folded away already.");
 3425   assert(BitWidth.ugt(MaskedBits) && "shifts should leave some bits untouched");
 3429   assert(KeptBits.ugt(0) && KeptBits.ult(BitWidth) && "unreachable");
 3432   assert(ICmpCst.isPowerOf2());
 3435   assert(AddCst.ult(ICmpCst) && AddCst.isPowerOf2());
 3480   assert(NarrowestShift->getType() == I.getOperand(0)->getType() &&
 3744       assert(B == D);
 4300   assert(isa<CastInst>(ICmp.getOperand(0)) && "Expected cast for operand 0");
 4386   assert(ICmp.getPredicate() == ICmpInst::ICMP_UGT && "ICmp should be folded!");
 4534   assert(I.getOperand(0) == MulVal || I.getOperand(1) == MulVal);
 4535   assert(I.getOperand(0) == OtherVal || I.getOperand(1) == OtherVal);
 4539   assert(MulInstr->getOpcode() == Instruction::Mul);
 4543   assert(LHS->getOpcode() == Instruction::ZExt);
 4544   assert(RHS->getOpcode() == Instruction::ZExt);
 4704         assert(BO->getOpcode() == Instruction::And);
 4825   assert(DI && UI && "Instruction not defined\n");
 4900   assert((SIOpd == 1 || SIOpd == 2) && "Invalid select operand!");
 5104     assert(!isa<ConstantInt>(Op1) && "ICMP_SGE with ConstantInt not folded!");
 5113     assert(!isa<ConstantInt>(Op1) && "ICMP_SLE with ConstantInt not folded!");
 5122     assert(!isa<ConstantInt>(Op1) && "ICMP_UGE with ConstantInt not folded!");
 5131     assert(!isa<ConstantInt>(Op1) && "ICMP_ULE with ConstantInt not folded!");
 5154   assert(ICmpInst::isRelational(Pred) && ICmpInst::isIntPredicate(Pred) &&
 5230   assert(A->getType()->isIntOrIntVectorTy(1) && "Bools only");
 5497     assert(Op1->getType()->isPointerTy() && "Comparing pointer with non-pointer?");
 5634         assert(P == FCmpInst::FCMP_ONE || P == FCmpInst::FCMP_UNE);
 5671   assert(!RHS.isNaN() && "NaN comparison not already folded!");
 5927     assert(!I.hasNoNaNs() && "fcmp should have simplified");
 5932     assert(!I.hasNoNaNs() && "fcmp should have simplified");
 5972   assert(OpType == Op1->getType() && "fcmp with different-typed operands?");
lib/Transforms/InstCombine/InstCombineInternal.h
  247   assert(In->getType()->isVectorTy() && "Not expecting scalars here");
  286   assert(SafeC && "Must have safe constant for binop");
  641     assert(New && !New->getParent() &&
  707     assert(I.use_empty() && "Cannot erase instruction that is used!");
lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
  119         assert(I->use_empty() && "Lifetime markers have no result to use!");
  300     assert(V && "Operand not replaced");
  308     assert(V && "Operand not replaced");
  318     assert(V && "Operand not replaced");
  334   assert(PT != NT && PT->getElementType() == NT->getElementType() &&
  454   assert((!LI.isAtomic() || isSupportedAtomicType(NewTy)) &&
  476   assert((!SI.isAtomic() || isSupportedAtomicType(V->getType())) &&
  530   assert(V->getType()->isPointerTy() && "Expected pointer type.");
  609       assert(LI.use_empty() && "Failed to remove all users of the load!");
  645   assert(LI.getAlignment() && "Alignment must be set at this point");
 1034         assert(LI.isUnordered() && "implied by above");
 1438         assert(SI.isUnordered() && "can't eliminate ordering operation");
 1489   assert(SI.isUnordered() &&
lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
  657   assert(C1.getBitWidth() == C2.getBitWidth() && "Constant widths not equal");
  765     assert(!Ty->isIntOrIntVectorTy(1) && "i1 divide not removed?");
lib/Transforms/InstCombine/InstCombinePHI.cpp
   37   assert(!isa<CallInst>(Inst));
  179   assert(AvailablePtrVals.size() == PN.getNumIncomingValues() &&
  205     assert(MatchingPtrPHI->getType() == IntToPtr->getType() &&
  245     assert((isa<PHINode>(IncomingVal) ||
  285   assert(isa<BinaryOperator>(FirstInst) || isa<CmpInst>(FirstInst));
  880   assert(isa<IntegerType>(PN.getType()) && "Expect only integer type phi");
 1052       assert(EltPHI->getType() != PN->getType() &&
lib/Transforms/InstCombine/InstCombineSelect.cpp
   52   assert(CmpInst::isIntPredicate(Pred) && "Expected integer predicate");
  151     assert(ICmpInst::isEquality(Pred) && "Not equality test?");
  704   assert((Pred == ICmpInst::ICMP_UGE || Pred == ICmpInst::ICMP_UGT) &&
 1016   assert(Sel.getTrueValue() == RHS && Sel.getFalseValue() == LHS &&
 1045   assert(isKnownNegation(TVal, FVal) &&
 1077     assert(RHS->hasOneUse() && "RHS use number is not right");
 1092     assert(FVal == LHS && "Unexpected results from matchSelectPattern");
 1096     assert(TVal == LHS && "Unexpected results from matchSelectPattern");
 1980   assert(SelectPatternResult::isMinOrMax(SPF) && "Expected min/max pattern");
 2083   assert(SelectPatternResult::isMinOrMax(SPF) && "Expected a min/max");
lib/Transforms/InstCombine/InstCombineShifts.cpp
  111   assert(IdenticalShOpcodes && "Should not get here with different shifts.");
  179   assert(OuterShift->getOpcode() == Instruction::BinaryOps::Shl &&
  288   assert(Op0->getType() == Op1->getType());
  346   assert(InnerShift->isLogicalShift() && "Unexpected instruction type");
  519   assert(InnerShAmt > OuterShAmt &&
  627   assert(!Op1C->uge(TypeBits) &&
  664         assert(I.getOpcode() == Instruction::LShr && "Unknown logical shift");
 1029       assert(*ShOp1 == ShAmt);
 1037       assert(ShAmt < X->getType()->getScalarSizeInBits() &&
 1099   assert(OldAShr.getOpcode() == Instruction::AShr &&
lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
   41   assert(I && "No instruction?");
   42   assert(OpNo < I->getNumOperands() && "Operand index too large");
  119   assert(V != nullptr && "Null pointer of Value???");
  120   assert(Depth <= 6 && "Limit Search Depth");
  123   assert(
  171     assert(!RHSKnown.hasConflict() && "Bits known to be one AND zero?");
  172     assert(!LHSKnown.hasConflict() && "Bits known to be one AND zero?");
  205     assert(!RHSKnown.hasConflict() && "Bits known to be one AND zero?");
  206     assert(!LHSKnown.hasConflict() && "Bits known to be one AND zero?");
  237     assert(!RHSKnown.hasConflict() && "Bits known to be one AND zero?");
  238     assert(!LHSKnown.hasConflict() && "Bits known to be one AND zero?");
  347     assert(!RHSKnown.hasConflict() && "Bits known to be one AND zero?");
  348     assert(!LHSKnown.hasConflict() && "Bits known to be one AND zero?");
  368     assert(InputKnown.getBitWidth() == SrcBitWidth && "Src width changed?");
  371     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  393     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  422     assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  487       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  511       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  557       assert(!Known.hasConflict() && "Bits known to be one AND zero?");
  566       assert(BitWidth > ShiftAmt && "Shift amount not saturated?");
  630         assert(!Known.hasConflict() && "Bits known to be one AND zero?");
 1095   assert((DemandedElts & ~EltMask) == 0 && "Invalid DemandedElts!");
 1258           assert(MaskVal < LHSVWidth * 2 &&
 1625       assert(VWidth == (InnerVWidth * 2) && "Unexpected input size");
lib/Transforms/InstCombine/InstCombineVectorOps.cpp
  266     assert(EEI->getVectorOperand() == V);
  447   assert(LHS->getType() == RHS->getType() &&
  504               assert(EI->getOperand(0) == RHS);
  610   assert(V->getType()->isVectorTy() && "Invalid shuffle!");
  641           assert(LR.second == nullptr || LR.second == RHS);
  887       assert(isa<UndefValue>(OldMask->getAggregateElement(i)) &&
 1002         assert(!Mask[I]);
 1012         assert(!Mask[I]);
 1236       assert(NewOps.size() == 2 && "binary operator with #ops != 2");
 1252       assert(NewOps.size() == 2 && "icmp with #ops != 2");
 1256       assert(NewOps.size() == 2 && "fcmp with #ops != 2");
 1273       assert(NewOps.size() == 1 && "cast with #ops != 1");
 1292   assert(V->getType()->isVectorTy() && "can't reorder non-vector elements");
 1470   assert(Shuf.isSelect() && "Must have select-equivalent shuffle");
 1603       assert(isa<Constant>(AltB0.Op1) && "Expecting constant with alt binop");
 1607       assert(isa<Constant>(AltB1.Op1) && "Expecting constant with alt binop");
 1745   assert(NumElts < Mask->getType()->getVectorNumElements() &&
 1795     assert(NewInsIndex != -1 && "Did not fold shuffle with unused operand?");
 1844   assert(isa<UndefValue>(Shuffle0->getOperand(1)) &&
 1854   assert(WideElts > NarrowElts && "Unexpected types for identity with padding");
 1877       assert(Mask[i] < NarrowElts && "Unexpected shuffle mask");
 1880       assert(Mask[i] < (WideElts + NarrowElts) && "Unexpected shuffle mask");
 2002     assert(SrcElemBitWidth && "vector elements must have a bitwidth");
 2038       assert(SrcElemsPerTgtElem);
 2195           assert(isa<UndefValue>(RHSShuffle->getOperand(1))
lib/Transforms/InstCombine/InstructionCombining.cpp
  524   assert(Op && "Expected a binary operator");
  544   assert(A && B && C && D && "All values must be provided");
  832   assert(I.isBinaryOp() && "Unexpected opcode for select folding");
 1111       assert(Offset >= 0);
 1113     assert((uint64_t)Offset < (uint64_t)TySize && "Out of range offset");
 1126       assert(Offset < (int64_t)SL->getSizeInBytes() &&
 1137       assert(EltSize && "Cannot index into a zero-sized array");
 1163   assert(isa<IntegerType>(Val->getType()) && "Can only descale integers!");
 1164   assert(cast<IntegerType>(Val->getType())->getBitWidth() ==
 1308         assert(SmallScale.exactLogBase2() == logScale);
 1334         assert(Scale.exactLogBase2() == logScale);
 1359   assert(Parent.first->hasOneUse() && "Drilled down when more than one use!");
 1360   assert(Op != Parent.first->getOperand(Parent.second) &&
 1389     assert((Ancestor->getOpcode() != Instruction::SExt || NoSignedWrap) &&
 1397     assert(Ancestor->hasOneUse() && "Drilled down when more than one use!");
 1408   assert(cast<VectorType>(LHS->getType())->getNumElements() == NumElts);
 1409   assert(cast<VectorType>(RHS->getType())->getNumElements() == NumElts);
 1493     assert(Inst.getType()->getScalarType() == V1->getType()->getScalarType() &&
 1511         assert(ShMask[I] < (int)NumElts && "Not expecting narrowing shuffle");
 2068           assert(Idx->getType() == DL.getIndexType(GEPType) &&
 2109           assert(Idx->getType() == DL.getIndexType(GEPType) &&
 2494   assert(FreeInstrBB == (Pred == ICmpInst::ICMP_EQ ? FalseBB : TrueBB) &&
 2506   assert(FreeInstrBB->size() == 1 &&
 2600       assert(isa<ConstantInt>(NewCase) &&
 2852       assert(LI.isFilter(i) && "Unsupported landingpad clause!");
 2872         assert(NumTypeInfos > 0 && "Should have handled empty filter already!");
 2952         assert(MakeNewInstruction && "New filter but not a new instruction!");
 3036           assert(FElts <= LElts && "Should have handled this case earlier!");
 3048         assert(FElts > 0 && "Should have eliminated the empty filter earlier!");
 3106     assert(!CleanupFlag && "Adding a cleanup, not removing one?!");
 3119   assert(I->hasOneUse() && "Invariants didn't hold!");
lib/Transforms/Instrumentation/AddressSanitizer.cpp
  603       assert(CI && "non-constant array size");
  661       assert(Pass->ProcessedAllocas.empty() &&
  663       assert(!Pass->LocalDynamicShadow);
 1114   assert(MDN->getNumOperands() == 3);
 1131     assert(MDN->getNumOperands() == 5);
 1224   assert(!CompileKernel || Recover);
 1238   assert(!CompileKernel || Recover);
 1245   assert(Res < kNumberOfAccessSizes);
 1556   assert(Addr);
 1690     assert(cast<BranchInst>(TagCheckTerm)->isUnconditional());
 1712     assert(cast<BranchInst>(CheckTerm)->isUnconditional());
 1882       assert(ErrorCode.empty() && "Invalid section specifier.");
 1988       assert(G->hasLocalLinkage());
 2011   assert(G->hasComdat());
 2042   assert(ExtendedGlobals.size() == MetadataInitializers.size());
 2055     assert(isPowerOf2_32(SizeOfGlobalStruct) &&
 2067   assert(ExtendedGlobals.size() == MetadataInitializers.size());
 2125   assert(ExtendedGlobals.size() == MetadataInitializers.size());
 2182   assert(ExtendedGlobals.size() == MetadataInitializers.size());
 2184   assert(N > 0);
 2278     assert(((RightRedzoneSize + SizeInBytes) % MinRZ) == 0);
 2588   assert(ProcessedAllocas.empty() && "must process localescape before allocas");
 2602         assert(AI && AI->isStaticAlloca() &&
 2809       assert(!ShadowBytes[i]);
 2852   assert(ShadowMask.size() == ShadowBytes.size());
 2856       assert(!ShadowBytes[i]);
 2882   assert(LocalStackSize <= kMaxStackMallocSize);
 2894     assert(CopyInsertPoint);
 2940     assert(Alloca->isStaticAlloca());
 2942   assert((ClRealignStack & (ClRealignStack - 1)) == 0);
 2958     assert(DynamicAllocaPoisonCallVec.empty());
 2964     assert(APC.InsBefore);
 2965     assert(APC.AI);
 2966     assert(ASan.isInterestingAlloca(*APC.AI));
 2967     assert(!APC.AI->isStaticAlloca());
 2985     assert(StaticAllocaPoisonCallVec.empty());
 3002   assert(InsBeforeB == &F.getEntryBlock());
 3037     assert(APC.InsBefore);
 3038     assert(APC.AI);
 3039     assert(ASan.isInterestingAlloca(*APC.AI));
 3040     assert(APC.AI->isStaticAlloca());
 3093     assert(StackMallocIdx <= kMaxAsanStackMallocSizeClass);
 3172       assert(Desc.Offset % L.Granularity == 0);
 3193       assert(StackMallocIdx >= 0);
lib/Transforms/Instrumentation/CFGMST.h
   83     assert(It->second.get() != nullptr);
lib/Transforms/Instrumentation/ControlHeightReduction.cpp
  177     assert(RI.R && "Null RegionIn");
  182     assert(RegInfos.size() > 0 && "Empty CHRScope");
  184     assert(Parent && "Unexpected to call this on the top-level region");
  189     assert(RegInfos.size() > 0 && "Empty CHRScope");
  194     assert(RegInfos.size() > 0 && "Empty CHRScope");
  216     assert(RegInfos.size() > 0 && "Empty CHRScope");
  217     assert(Next->RegInfos.size() > 0 && "Empty CHRScope");
  218     assert(getParentRegion() == Next->getParentRegion() &&
  220     assert(getExitBlock() == Next->getEntryBlock() &&
  236     assert(IsChild && "Must be a child");
  244     assert(Boundary && "Boundary null");
  245     assert(RegInfos.begin()->R != Boundary &&
  262       assert(Sub && "null Sub");
  268         assert(std::find_if(RegInfos.begin(), RegInfos.end(),
  276     assert(HoistStopMap.empty() && "MapHoistStops must be empty");
  451   assert(PSI.hasProfileSummary() && "Empty PSI?");
  470   assert(RegInfos.size() > 0 && "Empty CHRScope");
  559   assert(InsertPoint && "Null InsertPoint");
  564     assert(DT.getNode(I->getParent()) && "DT must contain I's parent block");
  565     assert(DT.getNode(InsertPoint->getParent()) && "DT must contain Destination");
  623   assert(SumWt >= TrueWt && SumWt >= FalseWt &&
  671   assert((IfThen == R->getExit() || IfElse == R->getExit()) &&
  724   assert(HoistPoint && "Null HoistPoint");
  736       assert(&I == HoistPoint &&
  750   assert(Entry && "Entry must not be null");
  751   assert((Exit == nullptr) == (R->isTopLevelRegion()) &&
  940         assert(InsertPoint != Branch && "Branch must not be the hoist point");
  964       assert(!DT.dominates(Branch, InsertPoint) &&
  967       assert(checkHoistValue(Branch->getCondition(), InsertPoint,
  972       assert(!DT.dominates(SI, InsertPoint) &&
  975       assert(checkHoistValue(SI->getCondition(), InsertPoint, DT,
 1074   assert(InsertPoint && "Null InsertPoint");
 1134     assert(!Scope->BranchInsertPoint &&
 1142     assert(Scope->BranchInsertPoint && "BranchInsertPoint must be set");
 1155     assert(OuterConditionValues && "Null OuterConditionValues");
 1156     assert(OuterInsertPoint && "Null OuterInsertPoint");
 1237   assert(PrevInsertPoint && "Null PrevInsertPoint");
 1239   assert(Splits.size() == SplitsConditionValues.size() &&
 1272     assert(Result.empty() &&
 1279     assert(Scope->TrueBiasedRegions.empty() && Scope->FalseBiasedRegions.empty() && "Empty");
 1367     assert(Scope->HoistStopMap.empty() && Scope->CHRRegions.empty() &&
 1403       assert((OutermostScope->TrueBiasedRegions.count(R) > 0 ||
 1411       assert(IsHoistable && "Must be hoistable");
 1416       assert((OutermostScope->TrueBiasedSelects.count(SI) > 0 ||
 1423       assert(IsHoistable && "Must be hoistable");
 1455   assert(IT != HoistStopMap.end() && "Region must be in hoist stop map");
 1472     assert(isHoistableInstructionType(I) && "Unhoistable instruction type");
 1473     assert(DT.getNode(I->getParent()) && "DT must contain I's block");
 1474     assert(DT.getNode(HoistPoint->getParent()) &&
 1539       assert(BI->isConditional() && "Must be conditional");
 1553         assert(Scope->FalseBiasedSelects.count(SI) == 0 &&
 1557         assert(Scope->TrueBiasedSelects.count(SI) == 0 &&
 1652     assert(HasBiasedBranchOrSelect(RI, Scope) &&
 1673         assert((I->getParent() == PreEntryBlock ||
 1687         assert((I->getParent() == PreEntryBlock ||
 1698   assert(Scope->RegInfos.size() >= 1 && "Should have at least one Region");
 1726   assert(NewEntryBlock->getSinglePredecessor() == EntryBlock &&
 1776       assert(BB != PreEntryBlock && "Don't copy the preetntry block");
 1807           assert(VMap.find(Pred) != VMap.end() && "Pred must have been cloned");
 1820   assert(OldBR->isUnconditional() && OldBR->getSuccessor(0) == NewEntryBlock &&
 1822   assert(NewEntryBlock->getSinglePredecessor() == EntryBlock &&
 1824   assert(VMap.find(NewEntryBlock) != VMap.end() &&
 1834   assert(NewEntryBlock->getSinglePredecessor() == EntryBlock &&
 1887   assert((IsTrueBiased || Scope->FalseBiasedRegions.count(R)) &&
 1890   assert(BranchBiasMap.find(R) != BranchBiasMap.end() &&
 1893   assert(Bias >= getCHRBiasThreshold() && "Must be highly biased");
 1900   assert(RegionExitBlock && "Null ExitBlock");
 1901   assert((IfThen == RegionExitBlock || IfElse == RegionExitBlock) &&
 1916   assert(ConditionTrue == (HotTarget == BI->getSuccessor(0)) &&
 1931   assert((IsTrueBiased ||
 1933   assert(SelectBiasMap.find(SI) != SelectBiasMap.end() &&
 1936   assert(Bias >= getCHRBiasThreshold() && "Must be highly biased");
lib/Transforms/Instrumentation/DataFlowSanitizer.cpp
  497   assert(!T->isVarArg());
 1048         assert(Shadow->getType() == DFS.ShadowTy);
 1061   assert(!ValShadowMap.count(I));
 1062   assert(Shadow->getType() == DFS.ShadowTy);
 1067   assert(Addr != RetvalTLS && "Reinstrumenting?");
 1692       assert(CS->getIterator() != CS->getParent()->end());
lib/Transforms/Instrumentation/GCOVProfiling.cpp
   81     assert((Options.EmitNotes || Options.EmitData) &&
  233       assert((unsigned)(4 - (s.size() % 4)) > 0);
  234       assert((unsigned)(4 - (s.size() % 4)) <= 4);
  254       assert(Line != 0 && "Line zero is not a valid real line number.");
  320       assert(LinesByFile.empty());
  321       assert(OutEdges.empty());
  820             assert(It != EdgeToCounter.end());
  836             assert(It != EdgeToCounter.end());
 1026     assert(CountersSize == (int)EmitFunctionCallArgsArray.size() &&
 1028     assert(CountersSize == (int)EmitArcsCallArgsArray.size() &&
 1207   assert(WriteoutF && "Need to create the writeout function first!");
lib/Transforms/Instrumentation/HWAddressSanitizer.cpp
  342   assert(!CompileKernel || Recover);
  579   assert(Res < kNumberOfAccessSizes);
  766     assert(CI && "non-constant array size");
  935   assert(SlotPtr);
 1163   assert(!LocalDynamicShadow);
lib/Transforms/Instrumentation/IndirectCallPromotion.cpp
  236     assert(Count <= TotalCount);
  341     assert(TotalCount >= Count);
lib/Transforms/Instrumentation/InstrProfiling.cpp
  189     assert(isa<LoadInst>(L));
  190     assert(isa<StoreInst>(S));
  599   assert(It != ProfileDataMap.end() && It->second.DataVar &&
  663     assert(isa<GlobalVariable>(V) && "Missing reference to function name");
lib/Transforms/Instrumentation/Instrumentation.cpp
   43   assert(&BB.getParent()->getEntryBlock() == &BB);
   79   assert(F.hasName());
lib/Transforms/Instrumentation/MemorySanitizer.cpp
 1082     assert(IntptrSize == kOriginSize * 2);
 1093     assert(IntptrAlignment >= kMinOriginAlignment);
 1094     assert(IntptrSize >= kOriginSize);
 1514     assert(!ShadowMap.count(V) && "Values may only have one shadow");
 1521     assert(!OriginMap.count(V) && "Values may only have one origin");
 1543     assert(ShadowTy);
 1587         assert(Shadow && "No shadow for a value");
 1666       assert(*ShadowPtr && "Could not find shadow for an argument");
 1683     assert((isa<Instruction>(V) || isa<Argument>(V)) &&
 1690     assert(Origin && "Missing origin");
 1704     assert(Shadow);
 1708     assert((isa<IntegerType>(ShadowTy) || isa<VectorType>(ShadowTy)) &&
 1720     assert(Val);
 1780     assert(I.getType()->isSized() && "Load type must have size");
 1781     assert(!I.getMetadata("nosanitize"));
 1824     assert(isa<AtomicRMWInst>(I) || isa<AtomicCmpXchgInst>(I));
 2012         assert(OpShadow);
 2022         assert(OpOrigin);
 2050         assert(Shadow);
 2055         assert(Origin);
 2075     assert(!(Ty->isVectorTy() && Ty->getScalarType()->isPointerTy()) &&
 2354     assert(I.isRelational());
 2364     assert(I.isUnsigned());
 2623       assert(isa<ConstantInt>(I.getArgOperand(2)) && "Invalid rounding mode");
 2657     assert(AggShadow->getType()->isIntegerTy());
 2663       assert(CopyOp->getType() == I.getType());
 2664       assert(CopyOp->getType()->isVectorTy());
 2685     assert(S->getType()->getPrimitiveSizeInBits() <= 64);
 2700     assert(T->isVectorTy());
 2713     assert(I.getNumArgOperands() == 2);
 2733     assert(EltSizeInBits != 0 && (X86_MMXSizeInBits % EltSizeInBits) == 0 &&
 2778     assert(I.getNumArgOperands() == 2);
 2783     assert(isX86_MMX || S1->getType()->isVectorTy());
 3255     assert(!I.getMetadata("nosanitize"));
 3256     assert((CS.isCall() || CS.isInvoke() || CS.isCallBr()) &&
 3271       assert(!isa<IntrinsicInst>(&I) && "intrinsics are handled elsewhere");
 3314         assert(A->getType()->isPointerTy() &&
 3340       assert(Size != 0 && Store != nullptr);
 3362       assert(NextInsn != I.getParent()->end());
 3376       assert(NextInsn != NormalDest->end() &&
 3637       assert(!isOutput);
 3805         assert(A->getType()->isPointerTy());
 3936     assert(!VAArgOverflowSize && !VAArgTLSCopy &&
 4084     assert(!VAArgSize && !VAArgTLSCopy &&
 4274     assert(!VAArgOverflowSize && !VAArgTLSCopy &&
 4419         assert(A->getType()->isPointerTy());
 4521     assert(!VAArgSize && !VAArgTLSCopy &&
lib/Transforms/Instrumentation/PGOInstrumentation.cpp
  688     assert(F.getLinkage() == GlobalValue::AvailableExternallyLinkage);
  705       assert(dyn_cast<Function>(GA->getAliasee()->stripPointerCasts()) == &F);
  713     assert(CF);
  822     assert(Builder.GetInsertPoint() != InstrBB->end() &&
  834   assert(I == NumCounters);
  852       assert(Builder.GetInsertPoint() != Cand.InsertPt->getParent()->end() &&
  860       assert(ToProfile && "value profiling Value is of unexpected type");
 1266     assert(BI->CountValid && "BB count is not valid");
 1282   assert(CountPosition == ProfileCountSize);
 1363   assert(*CurCtrIdx < CountFromProfile.size() &&
 1415   assert(Kind <= IPVK_Last);
 1700   assert(MaxCount > 0 && "Bad max count");
lib/Transforms/Instrumentation/PGOMemOPSizeOpt.cpp
  214   assert(Count <= TotalCount);
  232   assert(MI);
  299     assert(RemainCount >= C);
  301     assert(SavedRemainCount >= VD.Count);
  345   assert(It != DefaultBB->end());
  379     assert(SizeType && "Expected integer type size argument.");
lib/Transforms/Instrumentation/PoisonChecking.cpp
   85   assert(V->getType()->isIntegerTy(1));
  107   assert(isa<BinaryOperator>(I));
  238   assert(Cond->getType()->isIntegerTy(1));
  252   assert(Cond->getType()->isIntegerTy(1));
lib/Transforms/Instrumentation/SanitizerCoverage.cpp
  335   assert(CtorFunc->getName() == CtorName);
  670   assert(N);
  729   assert(Options.TracePC || Options.TracePCGuard || Options.Inline8bitCounters);
lib/Transforms/Instrumentation/ThreadSanitizer.cpp
  496     assert(!F.hasFnAttribute(Attribute::SanitizeThread));
  724   assert(OrigTy->isSized());
  733   assert(Idx < kNumberOfAccessSizes);
lib/Transforms/ObjCARC/ARCRuntimeEntryPoints.h
   73     assert(TheModule != nullptr && "Not initialized.");
lib/Transforms/ObjCARC/BlotMapVector.h
  110     assert(Map.empty() == Vector.empty());
lib/Transforms/ObjCARC/ObjCARC.h
   58     assert((IsForwarding(GetBasicARCInstKind(CI)) ||
lib/Transforms/ObjCARC/ObjCARCAPElim.cpp
  149   assert(GV->hasDefinitiveInitializer() &&
lib/Transforms/ObjCARC/ObjCARCContract.cpp
  326     assert(CV.size() == 1 && "non-unique color for block!");
  663             assert(DT->dominates(Inst, &InsertBB->back()) &&
lib/Transforms/ObjCARC/ObjCARCOpts.cpp
  733     assert(CV.size() == 1 && "non-unique color for block!");
 1123     assert((Seq == S_Retain || Seq == S_CanRelease || Seq == S_Use) &&
 1136       assert(BBI != BBStates.end());
 1279     assert(I != BBStates.end());
 1285       assert(I != BBStates.end());
 1414     assert(I != BBStates.end());
 1420       assert(I != BBStates.end());
 1648       assert(It != Retains.end());
 1673           assert(PathCount != BBState::OverflowOccurredValue &&
 1704                 assert(PathCount != BBState::OverflowOccurredValue &&
 1720       assert(It != Releases.end());
 1745           assert(PathCount != BBState::OverflowOccurredValue &&
 1762                 assert(PathCount != BBState::OverflowOccurredValue &&
 1809   assert(OldCount != 0 && "Unreachable code?");
lib/Transforms/ObjCARC/PtrState.cpp
  261     assert(!HasReverseInsertPts());
  396     assert(!HasReverseInsertPts());
lib/Transforms/Scalar/ADCE.cpp
  594     assert((PreferredSucc && PreferredSucc->PostOrder > 0) &&
lib/Transforms/Scalar/BDCE.cpp
   40   assert(I->getType()->isIntOrIntVectorTy() &&
lib/Transforms/Scalar/CallSiteSplitting.cpp
  110   assert(isa<Constant>(Cmp->getOperand(1)) && "Expected a constant operand.");
  173       assert(Cond.second == ICmpInst::ICMP_NE);
  181   assert(Preds.size() == 2 && "Expected exactly 2 predecessors!");
  251   assert(RI && "`musttail` call must be followed by `ret` instruction");
  324   assert(Preds.size() == 2 && "The ValueToValueMaps array has size 2.");
  333     assert(SplitBlock && "Unexpected new basic block split.");
  369     assert(Splits.size() == 2 && "Expected exactly 2 splits!");
  429           assert(PN->getNumIncomingValues() == 2 &&
  470   assert(DTU.hasDomTree() && "We need a DTU with a valid DT!");
lib/Transforms/Scalar/ConstantHoisting.cpp
  186   assert(Entry != Inst->getParent() && "PHI or landing pad in entry block!");
  195     assert(Entry != IDom->getBlock() && "eh pad in entry block");
  208   assert(!BBs.count(Entry) && "Assume Entry is not in BBs");
  231       assert(DT.getNode(Node)->getIDom() &&
  310   assert(!ConstInfo.RebasedConstants.empty() && "Invalid constant info entry.");
  345   assert((BBs.size() == 1) && "Expected only one element.");
  773     assert(CastInst->isCast() && "Expected an cast instruction!");
  802     assert(ConstExpr->isCast() && "ConstExpr should be a cast");
  869         assert(BaseGV && "A base constant expression must have an base GV");
  894       assert(!Base->use_empty() && "The use list is empty!?");
  895       assert(isa<Instruction>(Base->user_back()) &&
  902     assert(UsesNum == (ReBasesNum + NotRebasedNum) &&
lib/Transforms/Scalar/CorrelatedValuePropagation.cpp
  593   assert(ArgNo == CS.arg_size() && "sanity check");
  620   assert(Instr->getOpcode() == Instruction::UDiv ||
lib/Transforms/Scalar/DeadStoreElimination.cpp
  223   assert(hasAnalyzableMemoryWrite(Inst, TLI) && "Unknown instruction case");
  305   assert(Loc.Ptr &&
  459         assert(ILI->second > LaterIntStart && "Unexpected interval");
  518     assert(int64_t(LaterOff + LaterSize) < int64_t(EarlierOff + EarlierSize) &&
  611       assert(B == SecondBB && "first block is not the store block");
  626       assert(B != &FirstBB->getParent()->getEntryBlock() &&
  991     assert(LaterStart + LaterSize < EarlierStart + EarlierSize &&
 1009     assert(isRemovable(EarlierWrite) && "Expect only removable instruction");
 1200           assert(!EnablePartialOverwriteTracking && "Do not expect to perform "
 1235             assert(EarlierValue.getBitWidth() > LaterValue.getBitWidth());
lib/Transforms/Scalar/DivRemPairs.cpp
   85     assert((DivInst->getOpcode() == Instruction::UDiv ||
   88     assert(DivInst->getType() == RemInst->getType() && "Types should match.");
  222     assert((!E.isRemExpanded() || !HasDivRemOp) &&
  259       assert(!RemOriginallyWasInExpandedForm &&
lib/Transforms/Scalar/EarlyCSE.cpp
   99     assert((isSentinel() || canHandle(I)) && "Inst can't be handled!");
  242   assert((isa<CallInst>(Inst) || isa<GetElementPtrInst>(Inst) ||
  281     assert(isa<BinaryOperator>(RHSI) &&
  290     assert(isa<CmpInst>(RHSI) &&
  358   assert(!Result || (LHS.isSentinel() && LHS.Inst == RHS.Inst) ||
  375     assert((isSentinel() || canHandle(I)) && "Inst can't be handled!");
  706     assert(isa<IntrinsicInst>(Inst) && "Instruction not supported");
  814   assert(BI->isConditional() && "Should be a conditional branch!");
  815   assert(BI->getCondition() == CondInst && "Wrong condition?");
  816   assert(BI->getSuccessor(0) == BB || BI->getSuccessor(1) == BB);
 1159         assert(Inst->mayReadFromMemory() && "relied on to prevent DSE above");
 1182         assert((!LastStore ||
 1218           assert(LastStoreMemInst.isUnordered() &&
 1281   assert(!CurrentGeneration && "Create a new EarlyCSE instance to rerun it.");
lib/Transforms/Scalar/Float2Int.cpp
  256         assert(Ops.size() == 1 && "FNeg is a unary operator!");
  267         assert(Ops.size() == 2 && "its a binary operator!");
  280         assert(Ops.size() == 1 && "FPTo[US]I is a unary operator!");
  290         assert(Ops.size() == 2 && "FCmp is a binary operator!");
  300         assert(SeenInsts.find(OI) != SeenInsts.end() &&
  396     assert(ConvertedToTy && "Must have set the convertedtoty by this point!");
  476     assert(P != CmpInst::BAD_ICMP_PREDICATE && "Unhandled predicate!");
lib/Transforms/Scalar/GVN.cpp
  216     assert(isSimpleValue() && "Wrong accessor");
  221     assert(isCoercedLoadValue() && "Wrong accessor");
  226     assert(isMemIntrinValue() && "Wrong accessor");
  284     assert(I->getNumOperands() == 2 && "Unsupported commutative instruction!");
  311   assert((Opcode == Instruction::ICmp || Opcode == Instruction::FCmp) &&
  329   assert(EI && "Not an ExtractValueInst?");
  560     assert(VI != valueNumbering.end() && "Value not numbered?");
  603     assert(I->first != V && "Inst still occurs in value numbering map!");
  738     assert(!ValuesPerBlock[0].AV.isUndefValue() &&
  811     assert(isUndefValue() && "Should be UndefVal");
  815   assert(Res && "failed to materialize?");
  860   assert((DepInfo.isDef() || DepInfo.isClobber()) &&
  862   assert(LI->isUnordered() && "rules below are incorrect for ordered access");
  924   assert(DepInfo.isDef() && "follows from above");
 1020   assert(NumDeps == ValuesPerBlock.size() + UnavailableBlocks.size() &&
 1080   assert(TmpBB);
 1139   assert(NumUnavailablePreds != 0 &&
 1152     assert(!PredLoads.count(OrigPred) && "Split edges shouldn't be in map!");
 1399   assert(IntrinsicI->getIntrinsicID() == Intrinsic::assume &&
 1673     assert(Exp.varargs.size() == 2 && "Unsupported commutative expression!");
 1742   assert((!Pred || Pred == E.getStart()) &&
 1791     assert(LHS->getType() == RHS->getType() && "Equality but unequal types!");
 1800     assert((isa<Argument>(LHS) || isa<Instruction>(LHS)) && "Unexpected value!");
 2147   assert(InstrsToErase.empty() &&
 2176       assert(I->getParent() == BB && "Removing instruction from wrong block?");
 2300     assert(BlockRPONumber.count(P) && BlockRPONumber.count(CurrentBlock) &&
 2377   assert(PREInstr != nullptr || NumWithout == 0);
 2509     assert(Node->Val != Inst && "Inst still in value numbering scope!");
 2513       assert(Node->Val != Inst && "Inst still in value numbering scope!");
lib/Transforms/Scalar/GVNHoist.cpp
  376     assert(I1->getParent() == I2->getParent());
  379     assert(I1DFS && I2DFS);
  448     assert(DT->dominates(NewBB, OldBB) && "invalid path");
  449     assert(DT->dominates(Def->getDefiningAccess()->getBlock(), NewBB) &&
  487     assert(DT->dominates(HoistPt, SrcBB) && "Invalid path");
  550       assert(UBB == DBB);
  551       assert(MSSA->locallyDominates(D, U));
  851     assert(allGepOperandsAvailable(Gep, HoistPt) &&
 1028         assert(allOperandsAvailable(Repl, DestBB) &&
lib/Transforms/Scalar/GVNSink.cpp
  278       assert(VI != Values.end());
  288     assert(Blocks.size() == NewBlocks.size());
  514     assert(VI != ValueNumbering.end() && "Value not numbered?");
  851     assert(!Op->getType()->isTokenTy() && "Can't PHI tokens!");
lib/Transforms/Scalar/GuardWidening.cpp
   96     assert(GI->getIntrinsicID() == Intrinsic::experimental_guard &&
  111     assert(GI->getIntrinsicID() == Intrinsic::experimental_guard &&
  315     assert(Threshold > 0 && "Zero threshold makes no sense!");
  346   assert(EliminatedGuardsAndBranches.empty() || Changed);
  349       assert(isa<ConstantInt>(getCondition(I)) && "Should be!");
  353         assert(isa<BranchInst>(I) &&
  381     assert(GuardsInBlock.count(CurBB) && "Must have been populated by now!");
  398       assert(Index == GuardsInCurBB.size() &&
  403     assert((i == (e - 1)) == (Instr->getParent() == CurBB) && "Bad DFS?");
  422   assert(BestSoFar != Instr && "Should have never visited same guard!");
  423   assert(DT.dominates(BestSoFar, Instr) && "Should be!");
  511   assert(!isa<PHINode>(Loc) &&
  513   assert(DT.isReachableFromEntry(Inst->getParent()) &&
  524   assert(isSafeToSpeculativelyExecute(Inst, Loc, &DT) &&
  594         assert(Result && "Failed to find result value");
  662     assert((!BaseInst || DT.isReachableFromEntry(BaseInst->getParent())) &&
  706     assert(CurrentChecks.size() != 0 && "We know we have at least one!");
  782   assert(RangeChecksOut.size() <= OldCount && "We pessimized!");
lib/Transforms/Scalar/IndVarSimplify.cpp
  270   assert(DT->dominates(DefI, InsertPt) && "def does not dominate all uses");
  273   assert(!L || L->contains(LI->getLoopFor(InsertPt->getParent())));
  354   assert(TheBr->isConditional() && "Can't use fcmp if not conditional");
  586   assert(L->isRecursivelyLCSSAForm(*DT, *LI) &&
  692               assert(EVL->contains(L) && "LCSSA breach detected!");
  751   assert(L->isLCSSAForm(*DT));
  800         assert(LoopPreheader && "Invalid loop");
  803           assert(ExitVal->getParent() == L->getHeader() &&
 1033     assert(L->getHeader() == OrigPhi->getParent() && "Phi must be an IV");
 1233   assert(It != ExtendKindMap.end() && "Instruction not yet extended!");
 1266   assert(DU.NarrowUse->getOperand(1-ExtendOperIdx) == DU.NarrowDef && "bad DU");
 1384   assert(CastWidth <= IVWidth && "Unexpected width while widening compare.");
 1429   assert(DU.NarrowUse->getOperand(1 - ExtendOperIdx) == DU.NarrowDef &&
 1544   assert(ExtendKindMap.count(DU.NarrowDef) &&
 1631   assert((WideAddRec.first == nullptr) == (WideAddRec.second == Unknown));
 1656   assert(DU.NarrowUse != DU.NarrowUse->getParent()->getTerminator() &&
 1736   assert(SE->getEffectiveSCEVType(WideIVExpr->getType()) == WideType &&
 1747   assert(
 1791   assert(Widened.empty() && NarrowIVUsers.empty() && "expect initial state" );
 2072   assert(L->getLoopLatch() && "Must be in simplified form");
 2221   assert(Phi->getParent() == L->getHeader());
 2222   assert(L->getLoopLatch());
 2258   assert(LatchBlock && "Must be in simplified form");
 2334   assert(isLoopCounter(IndVar, L, SE));
 2356     assert(SE->isLoopInvariant(IVOffset, L) &&
 2361     assert(SE->getSizeOfExpr(IntegerType::getInt64Ty(IndVar->getContext()),
 2381     assert(AR->getStepRecurrence(*SE)->isOne() && "only handles unit stride");
 2404     assert(SE->isLoopInvariant(IVLimit, L) &&
 2425   assert(L->getLoopLatch() && "Loop no longer in simplified form?");
 2426   assert(isLoopCounter(IndVar, L, SE));
 2474   assert(ExitCnt->getType()->isPointerTy() ==
 2501     assert(!CmpIndVar->getType()->isPointerTy() &&
 2671       assert(DT.dominates(ExitingBB, L->getLoopLatch()) &&
 2752     assert(!isa<SCEVCouldNotCompute>(ExitCount) && "checked above");
 2776     assert(MaxExitCount->getType() == ExitCount->getType());
 2862     assert(!isa<SCEVCouldNotCompute>(ExactBTC) && "implied by having exact trip count");
 2908   assert(llvm::all_of(ExitingBlocks, [&](BasicBlock *ExitingBB) {
 2977   assert(L->isRecursivelyLCSSAForm(*DT, *LI) &&
 3116   assert(L->isRecursivelyLCSSAForm(*DT, *LI) &&
 3132     assert(BackedgeTakenCount == NewBECount && "indvars must preserve SCEV");
lib/Transforms/Scalar/InductiveRangeCheckElimination.cpp
  191       assert(Begin->getType() == End->getType() && "ill-typed range!");
  654   assert(SE.isKnownNegative(Step) && "expecting negative step");
  673   assert(LatchBrExitIdx == 0 &&
  721   assert(LatchBrExitIdx == 0 && "LatchBrExitIdx should be 0 or 1");
  745   assert(Latch && "Simplified loops only have one latch!");
  860   assert(!StepCI->isZero() && "Zero step?");
  935       assert(!DecreasedRightValueByOne &&
 1002       assert(!IncreasedRightValueByOne &&
 1008   assert(SE.getLoopDisposition(LatchCount, &L) ==
 1012   assert(!L.contains(LatchExit) && "expected an exit block!");
 1137     assert(V && "null values not in domain!");
 1156     assert(Result.Map[OriginalBB] == ClonedBB && "invariant!");
 1390   assert(!isa<SCEVCouldNotCompute>(LatchTakenCount) && Preheader != nullptr &&
 1603   assert(!B->isZero() && "Recurrence with zero step?");
 1610   assert(!D->getValue()->isZero() && "Recurrence with zero step?");
 1702   assert(!R1Value.isEmpty(SE, /* IsSigned */ true) &&
 1731   assert(!R1Value.isEmpty(SE, /* IsSigned */ false) &&
 1852         assert(
lib/Transforms/Scalar/InferAddressSpaces.cpp
  227     assert(Op.getType()->isPointerTy());
  310   assert(V->getType()->isPointerTy());
  453     assert(Src->getType()->getPointerAddressSpace() == NewAddrSpace);
  473     assert(I->getType()->isPointerTy());
  492     assert(I->getType()->isPointerTy());
  513     assert(CE->getOperand(0)->getType()->getPointerAddressSpace() ==
  588   assert(isAddressExpression(*V) &&
  696   assert(InferredAddrSpace.count(&V));
  745   assert(OldAS != FlatAddrSpace);
  817       assert(isa<MemMoveInst>(MTI));
  834   assert(NewAS != UninitializedAddressSpace);
  897     assert(isa<UndefValue>(NewV->getOperand(OperandNo)));
  905     assert(WVH && "value was unexpectedly deleted");
lib/Transforms/Scalar/JumpThreading.cpp
  380   assert(DTU && "DTU isn't passed into JumpThreading before using it.");
  381   assert(DTU->hasDomTree() && "JumpThreading relies on DomTree to proceed.");
  452   assert(Cond->getType() == ToVal->getType());
  479   assert(StopAt->getParent() == BB && "Not an instruction from proper BB?");
  688     assert(Preference == WantInteger && "One-bit non-integer type?");
  747     assert(Preference != WantBlockAddress
  769     assert(Preference == WantInteger && "Compares only produce integers");
  929           assert(isa<UndefValue>(Cond) && "Unexpected condition value");
 1148       assert(CondBr->isConditional() && "Threading on unconditional terminator");
 1373     assert(LoadI->isUnordered() &&
 1470     assert(UnavailablePred->getTerminator()->getNumSuccessors() == 1 &&
 1502     assert(I != AvailablePreds.end() && I->first == P &&
 1534   assert(!PredToDestList.empty());
 1578       assert(i != TI->getNumSuccessors() && "Didn't find any successor!");
 1604   assert(!PredValues.empty() &&
 1637       assert(isa<ConstantInt>(Val) && "Expecting a constant integer");
 1640       assert(isa<ConstantInt>(Val) && "Expecting a constant integer");
 1643       assert(isa<IndirectBrInst>(BB->getTerminator())
 1645       assert(isa<BlockAddress>(Val) && "Expecting a constant blockaddress");
 1836     assert(XorOpValues.empty());
 1843   assert(!XorOpValues.empty() &&
 2146   assert(TI->getNumSuccessors() > 1 && "not a split");
 2171   assert(BFI && BPI && "BFI & BPI should have been created here");
 2264   assert(!PredBBs.empty() && "Can't handle an empty set");
 2688   assert(BI->getNumSuccessors() == 2 && "Wrong number of successors?");
 2689   assert(BI->isConditional() && "Unconditional branch has 2 successors?");
 2725   assert(GuardedBlock && "Could not create the guarded block?");
 2731   assert(UnguardedBlock && "Could not create the unguarded block?");
 2743   assert(InsertionPoint && "Empty block?");
lib/Transforms/Scalar/LICM.cpp
  252     assert(all_of(AliasSetMap,
  332   assert(L->isLCSSAForm(*DT) && "Loop is not in LCSSA form.");
  443         assert(
  472   assert(L->isLCSSAForm(*DT) && "Loop not left in LCSSA form after LICM!");
  473   assert((!L->getParentLoop() || L->getParentLoop()->isLCSSAForm(*DT)) &&
  503   assert(N != nullptr && AA != nullptr && LI != nullptr && DT != nullptr &&
  506   assert(((CurAST != nullptr) ^ (MSSAU != nullptr)) &&
  630         assert(It != F->end() && "Could not find successor in function");
  710     assert(std::find_if(++It, HoistableBranches.end(), HasBBAsSuccessor) ==
  745       assert(TargetSucc && "Expected hoist target to have a single successor");
  783     assert(CurLoop->getLoopPreheader() &&
  802   assert(N != nullptr && AA != nullptr && LI != nullptr && DT != nullptr &&
  805   assert(((CurAST != nullptr) ^ (MSSAU != nullptr)) &&
  919           assert(DT->dominates(PN, BB) && "Conditional PHIs not expected");
  948             assert(DT->dominates(Dominator, HoistPoint->getParent()) &&
 1092     assert(Flags != nullptr && "Flags cannot be null.");
 1187       assert(Begin != CurAST->end() && "must contain FI");
 1196       assert(UniqueI == FI && "AS must contain FI");
 1219       assert(UniqueI == SI && "AS must contain SI");
 1254                 assert(!LI->isUnordered() && "Expected unordered load");
 1277   assert(!I.mayReadOrWriteMemory() && "unhandled aliasing");
 1380       assert(CV.size() == 1 && "non-unique color for exit block!");
 1459   assert(isTriviallyReplaceablePHI(*TPN, *I) &&
 1501   assert(ExitBlockSet.count(ExitBB) && "Expect the PHI is in an exit block.");
 1539     assert(CurLoop->contains(PredBB) &&
 1648     assert(ExitBlockSet.count(PN->getParent()) &&
 1876   assert(LI != nullptr && DT != nullptr && CurLoop != nullptr &&
 2334   assert(CurLoop->contains(BB) && "Only valid if BB is IN the loop");
lib/Transforms/Scalar/LoopDataPrefetch.cpp
  201   assert(TTI->getCacheLineSize() && "Cache line size is not set for target");
lib/Transforms/Scalar/LoopDeletion.cpp
   99   assert(Preheader && "Needs preheader!");
  116   assert(!pred_empty(Preheader) &&
  137   assert(L->isLCSSAForm(DT) && "Expected LCSSA!");
lib/Transforms/Scalar/LoopDistribute.cpp
  225           assert(!isa<BranchInst>(NewInst) &&
  446     assert(Pred && "Preheader does not have a single predecessor");
  448     assert(ExitBlock && "No single exit block");
  451     assert(!PartitionContainer.empty() && "at least two partitions expected");
  454     assert(&*OrigPH->begin() == OrigPH->getTerminator() &&
  531       assert(Partition != -2 && "Pointer not belonging to any partition");
  666     assert(L->empty() && "Only process inner loops.");
  729       assert(NumUnsafeDependencesActive >= 0 &&
  810       assert(!LAI->hasConvergentOp() && "inserting illegal loop versioning");
  846       assert(DT->verify(DominatorTree::VerificationLevel::Fast));
  948     assert(Op && mdconst::hasa<ConstantInt>(*Op) && "invalid metadata");
lib/Transforms/Scalar/LoopFuse.cpp
  222     assert(isValid() && "Candidate is not valid!!");
  223     assert(!L->isInvalid() && "Loop is invalid!");
  224     assert(Preheader == L->getLoopPreheader() && "Preheader is out of sync");
  225     assert(Header == L->getHeader() && "Header is out of sync");
  226     assert(ExitingBlock == L->getExitingBlock() &&
  228     assert(ExitBlock == L->getExitBlock() && "Exit block is out of sync");
  229     assert(Latch == L->getLoopLatch() && "Latch is out of sync");
  252     assert(GuardBranch && "Only valid on guarded loops.");
  253     assert(GuardBranch->isConditional() &&
  261     assert(L && "Expecting loop to be valid.");
  262     assert(Latch && "Expecting latch to be valid.");
  337     assert(L && Preheader && "Fusion candidate not initialized properly!");
  361     assert(DT && LHS.PDT && "Expecting valid dominator tree");
  367       assert(LHS.PDT->dominates(LHSEntryBlock, RHSEntryBlock));
  373       assert(LHS.PDT->dominates(RHSEntryBlock, LHSEntryBlock));
  539         assert(LV.size() > 0 && "Empty loop set was build!");
  573     assert(DT.verify());
  574     assert(PDT.verify());
  592     assert(FC0.Preheader && FC1.Preheader && "Expecting valid preheaders");
  708         assert(!LDT.isRemovedLoop(FC0->L) &&
  712           assert(!LDT.isRemovedLoop(FC1->L) &&
  809           assert(FusedCand.isEligibleForFusion(SE) &&
  820           assert(InsertPos.second &&
  982     assert(FC0.L->getLoopDepth() == FC1.L->getLoopDepth());
  983     assert(DT.dominates(FC0.getEntryBlock(), FC1.getEntryBlock()));
 1065     assert(FC0.GuardBranch && FC1.GuardBranch &&
 1090     assert(FC.GuardBranch && "Expecting a fusion candidate with guard branch.");
 1107     assert(FC.Preheader && "Expecting a valid preheader");
 1112     assert(FC.ExitBlock && "Expecting a valid exit block");
 1146     assert(FC0.isValid() && FC1.isValid() &&
 1158     assert(FC1.Preheader == FC0.ExitBlock);
 1159     assert(FC1.Preheader->size() == 1 &&
 1208     assert(pred_begin(FC1.Preheader) == pred_end(FC1.Preheader));
 1231       assert(L1LatchBBIdx >= 0 &&
 1295     assert(!verifyFunction(*FC0.Header->getParent(), &errs()));
 1296     assert(DT.verify(DominatorTree::VerificationLevel::Fast));
 1297     assert(PDT.verify());
 1322     assert(FC0.Preheader && FC1.Preheader &&
 1351     assert(FC0.GuardBranch && FC1.GuardBranch && "Expecting guarded loops");
 1358     assert(FC0NonLoopBlock == FC1GuardBlock && "Loops are not adjacent");
 1387     assert(pred_begin(FC1GuardBlock) == pred_end(FC1GuardBlock) &&
 1389     assert(succ_begin(FC1GuardBlock) == succ_end(FC1GuardBlock) &&
 1409     assert(OriginalFC0PHIs.empty() && "Expecting OriginalFC0PHIs to be empty!");
 1443     assert(pred_begin(FC0.ExitBlock) == pred_end(FC0.ExitBlock) &&
 1450     assert(pred_begin(FC1.Preheader) == pred_end(FC1.Preheader));
 1473       assert(L1LatchBBIdx >= 0 &&
 1509     assert(succ_begin(FC1GuardBlock) == succ_end(FC1GuardBlock) &&
 1511     assert(pred_begin(FC1GuardBlock) == pred_end(FC1GuardBlock) &&
 1548     assert(!verifyFunction(*FC0.Header->getParent(), &errs()));
 1549     assert(DT.verify(DominatorTree::VerificationLevel::Fast));
 1550     assert(PDT.verify());
lib/Transforms/Scalar/LoopIdiomRecognize.cpp
  384   assert(!isa<SCEVCouldNotCompute>(BECount) &&
  606       assert(false && "unhandled return value");
  673     assert(SL[i]->isSimple() && "Expected only non-volatile stores.");
  696     assert((FirstSplatValue || FirstPatternValue) &&
  711       assert(SL[k]->isSimple() && "Expected only non-volatile stores.");
  729       assert((SecondSplatValue || SecondPatternValue) &&
  951   assert((SplatValue || PatternValue) &&
 1057   assert(SI->isUnordered() && "Expected only non-volatile non-ordered stores.");
 1067   assert(LI->isUnordered() && "Expected only non-volatile non-ordered loads.");
 1974   assert(ExitBlocks.size() <= 2U && "Can't have more than two exit blocks.");
 1985   assert(!is_contained(ExitBlocks, CmpLoop.HeaderBrEqualBB) &&
 1992   assert(CurLoop->isLCSSAForm(*DT) && "Should only get LCSSA-form loops here.");
 2108   assert(Iterations != SE->getCouldNotCompute() &&
 2184   assert(Iterations != SE->getCouldNotCompute() && "Promotion failed.");
 2195   assert(NBytes != SE->getCouldNotCompute() &&
 2264   assert(cast<BranchInst>(PreheaderBB->getTerminator())->isUnconditional() &&
 2329     assert(CurLoop->contains(OldBB) && "Only for loop's basic blocks.");
 2340   assert(LoopExitEdges.size() == 2 && "Should have only to two exit edges.");
 2346     assert(CurLoop->contains(OldLoopBB) && !CurLoop->contains(SuccessorBB) &&
 2352     assert(NewBB->empty() && "Should not get same new basic block here twice.");
 2371   assert(DTUpdates.size() == 8 && "Update count prediction failed.");
 2440   assert(isa<UnreachableInst>(PhonySuccessorBB->getTerminator()) &&
 2456   assert(DTUpdates.size() == 3 && "Update count prediction failed.");
 2550     assert(OldTerminator->isUnconditional() && "That's the one we created.");
 2564   assert(DTUpdates.size() == 6 && "Update count prediction failed.");
 2626     assert(SE->getTypeSizeInBits(Len->getType()) ==
 2633     assert(Len->getType() == CmpFuncSizeTy && "Should have correct type now.");
lib/Transforms/Scalar/LoopInstSimplify.cpp
  130           assert((L.contains(UserI) || isa<PHINode>(UserI)) &&
  142         assert(I.use_empty() && "Should always have replaced all uses!");
lib/Transforms/Scalar/LoopInterchange.cpp
  126         assert(D->isOrdered() && "Expected an output, flow or anti dep.");
  697         assert(PHI.getNumIncomingValues() == 2 &&
 1259         assert(!NewI->mayHaveSideEffects() &&
 1323   assert(llvm::count_if(successors(BI),
 1352     assert(P.getNumIncomingValues() == 1 &&
 1362     assert(all_of(P.users(),
 1433   assert(OuterLoopPreHeader != OuterLoop->getHeader() &&
 1543     assert(OuterInnerReductions.find(PHI) != OuterInnerReductions.end() &&
 1548     assert(OuterInnerReductions.find(PHI) != OuterInnerReductions.end() &&
lib/Transforms/Scalar/LoopLoadElimination.cpp
  104     assert(LoadPtrType->getPointerAddressSpace() ==
  207         assert(Dep.isForward() && "Needs to be a forward dependence");
  234     assert(I != InstOrder.end() && "No index for instruction");
lib/Transforms/Scalar/LoopPassManager.cpp
   61     assert(L.isRecursivelyLCSSAForm(AR.DT, AR.LI) &&
lib/Transforms/Scalar/LoopPredication.cpp
  394   assert(Ty == RHS->getType() && "expandCheck operands have different types?");
  431   assert(DL.getTypeSizeInBits(LatchCheck.IV->getType()) >
  709   assert(Step->getType() ==
  721     assert(Step->isAllOnesValue() && "Step should be -1!");
  808   assert(isGuardAsWidenableBranch(BI) && "Must be!");
  826   assert(isGuardAsWidenableBranch(BI) &&
  849   assert(
  885       assert(Step->isAllOnesValue() && "Step should be -1!");
  919   assert(LatchBlock && "Should have a single latch at this point!");
  921   assert(LatchTerm->getNumSuccessors() == 2 &&
lib/Transforms/Scalar/LoopRerollPass.cpp
  201         assert(isa<PHINode>(P) && "First reduction instruction must be a PHI");
  210         assert(Valid && "Using invalid reduction");
  215         assert(Valid && "Using invalid reduction");
  220         assert(Valid && "Using invalid reduction");
  228         assert(Valid && "Using invalid reduction");
  236         assert(Valid && "Using invalid reduction");
  241         assert(Valid && "Using invalid reduction");
  313           assert(PossibleRedIdx.count(J2) &&
  320           assert(Idx == PossibleRedIdx[J2] &&
  595           assert(!LoopControlIV && "Found two loop control only IV");
  610   assert(!Valid && "Cannot add to an already-valid chain");
  968   assert(RootSets.empty() && "Unclean state!");
 1410     assert(BaseIt == Uses.end() && RootIt == Uses.end() &&
lib/Transforms/Scalar/LoopSimplifyCFG.cpp
   85   assert((!LastLoop || LastLoop->contains(FirstLoop->getHeader())) &&
   87   assert(FirstLoop->contains(BB) && "Must be a loop block!");
  188     assert(DFS.isComplete() && "DFS is expected to be finished");
  211     assert(DFS.isComplete() && "DFS is expected to be finished");
  258     assert(L.getNumBlocks() == LiveLoopBlocks.size() + DeadLoopBlocks.size() &&
  306     assert(BlocksInLoopAfterFolding.count(L.getHeader()) &&
  308     assert(BlocksInLoopAfterFolding.size() <= LiveLoopBlocks.size() &&
  374       assert(DummyIdx != 0 && "Too many dead exits!");
  380     assert(L.getLoopPreheader() == NewPreheader && "Malformed CFG?");
  407         assert(FixLCSSALoop && "Should be a loop!");
  444         assert(LI.getLoopFor(BB) != &L && "Attempt to remove current loop!");
  457       assert(BB != L.getHeader() &&
  477       assert(LI.getLoopFor(BB) == &L && "Should be a loop block!");
  479       assert(TheOnlySucc && "Should have one live successor!");
  500       assert(TheOnlySuccDuplicates > 0 && "Should be!");
  530     assert(L.getLoopLatch() && "Should be single latch!");
  605     assert(DT.verify(DominatorTree::VerificationLevel::Fast) &&
  608     assert(DT.isReachableFromEntry(Header));
lib/Transforms/Scalar/LoopSink.cpp
  225     assert(LoopBlockNumber.find(N)->second >
  300     assert(L.hasLoopInvariantOperands(I) &&
lib/Transforms/Scalar/LoopStrengthReduce.cpp
  275   assert(It != RegUsesMap.end());
  277   assert(RSD.UsedByIndices.size() > LUIdx);
  283   assert(LUIdx <= LastLUIdx);
  310   assert(I != RegUsesMap.end() && "Unknown register!");
  501   assert(!BaseRegs.empty() && "1*reg => reg, should not be needed.");
 1052     assert(isValid() && "invalid cost");
 1327   assert(F.isCanonical(*L) && "Cost is accurate only for canonical formula");
 1383     assert(isValid() && "invalid cost");
 1420   assert(isValid() && "invalid cost");
 1534   assert(F.isCanonical(L) && "Invalid canonical representation");
 1548   assert((!F.ScaledReg || !F.ScaledReg->isZero()) &&
 1552     assert(!BaseReg->isZero() && "Zero allocated in a base register!");
 1714   assert((F.isCanonical(L) || F.Scale != 0));
 1780     assert(ScaleCostMinOffset >= 0 && ScaleCostMaxOffset >= 0 &&
 1878     assert(!Incs.empty());
 2307   assert(AR->getLoop() == L &&
 2847   assert(!Chain.Incs.empty() && "empty IV chains are not allowed");
 3106   assert(!Chain.Incs.empty() && "empty IV chains are not allowed");
 3112     assert(UseI != Inc.UserInst->op_end() && "cannot find IV operand");
 3170   assert(IVSrc && "Failed to find IV chain source");
 3201         assert(IVTy == IVOper->getType() && "inconsistent IV increment type");
 3208       assert(SE.getTypeSizeInBits(IVTy) >= SE.getTypeSizeInBits(OperTy) &&
 3229         assert(PostIncTy->isPointerTy() && "mixing int/ptr IV types");
 3249     assert(UseI != UserInst->op_end() && "cannot find IV operand");
 3346   assert(Inserted && "Initial formula already exists!"); (void)Inserted;
 3358   assert(Inserted && "Supplemental formula already exists!"); (void)Inserted;
 3373   assert(isLegalUse(TTI, LU.MinOffset, LU.MaxOffset, LU.Kind, LU.AccessTy, F) &&
 3664   assert(Base.isCanonical(*L) && "Input must be in the canonical form");
 3733     assert(CombinedIntegerType && "Missing a type for the unfolded offset");
 3882   assert(!Base.BaseGV && "ICmpZero use is not legal!");
 3967   assert(Base.Scale == 0 && "unscale did not did its job!");
 4800     assert(LU.Formulae.size() == 1 && "Should be exactly 1 min regs formula");
 4841     assert(Best && "Failed to find best LSRUse candidate");
 4862           assert(e != 0 && "Use has no formulae left! Is Regs inconsistent?");
 4999   assert(Solution.size() == Uses.size() && "Malformed solution!");
 5099   assert(!isa<PHINode>(LowestIP) && !LowestIP->isEHPad()
 5161     assert(!Reg->isZero() && "Zero allocated in a base register!");
 5186         assert(F.Scale == -1 &&
 5271     assert(!F.BaseGV && "ICmp does not support folding a global value and "
 5285       assert((F.Scale == 0 || F.Scale == 1) &&
 5544       assert(DomLoop->getLoopPreheader() && "LSR needs a simplified loop nest");
 5600       assert(isLegalUse(TTI, LU.MinOffset, LU.MaxOffset, LU.Kind, LU.AccessTy,
lib/Transforms/Scalar/LoopUnrollAndJamPass.cpp
  104     assert(LoopID->getNumOperands() > 0 && "requires at least one operand");
  105     assert(LoopID->getOperand(0) == LoopID && "invalid loop id");
  133     assert(MD->getNumOperands() == 2 &&
  137     assert(Count >= 1 && "Unroll count must be positive.");
  147   assert(LoopSize >= UP.BEInsns && "LoopSize should not be less than BEInsns!");
lib/Transforms/Scalar/LoopUnrollPass.cpp
  340   assert(UnrollMaxIterationsCountToAnalyze <
  385     assert(Iteration >= 0 && "Cannot have a negative iteration!");
  386     assert(CostWorklist.empty() && "Must start with an empty cost list");
  387     assert(PHIUsedList.empty() && "Must start with an empty phi used list");
  412             assert(Cost.IsFree && "Loop PHIs shouldn't be evaluated as they "
  454       assert(Iteration > 0 &&
  463   assert(L->isLoopSimplifyForm() && "Must put loop into normal form first.");
  464   assert(L->isLCSSAForm(DT) &&
  485       assert(
  532         assert(Inserted && "Cannot have a state for an unvisited instruction!");
  693     assert(MD->getNumOperands() == 2 &&
  697     assert(Count >= 1 && "Unroll count must be positive.");
  724   assert(LoopSize >= UP.BEInsns && "LoopSize should not be less than BEInsns!");
  808   assert((ExactTripCount == 0 || FullUnrollMaxTripCount == 0) &&
  912   assert(TripCount == 0 &&
 1393     assert(PreOrderLoops.empty() && "Must start with an empty preorder walk.");
 1394     assert(PreOrderWorklist.empty() &&
lib/Transforms/Scalar/LoopUnswitch.cpp
  380     assert(NewInst && "All instructions that are in SrcBB must be in VMap.");
  513   assert((!FCond || OpChain != OC_OpChainMixed) &&
  530     assert(DT && "Cannot update MemorySSA without a valid DomTree.");
  544     assert(currentLoop->isLCSSAForm(*DT));
  781           assert(OpChain == OC_OpChainNone &&
  937   assert(OldBranch->isUnconditional() && "Preheader is not split correctly");
  938   assert(TrueDest != FalseDest && "Branch targets should be different");
 1025   assert(!L->contains(ExitBlock) && "Exit block is in the loop?");
 1032   assert(OldBranch && "Failed to split the preheader");
 1314     assert(NewExit->getTerminator()->getNumSuccessors() == 1 &&
 1354   assert(OldBR->isUnconditional() && OldBR->getSuccessor(0) == LoopBlocks[0] &&
 1445   assert(!isa<Constant>(LIC) && "Why are we unswitching on a constant?");
 1623         assert(SinglePred == Pred && "CFG broken");
lib/Transforms/Scalar/LoopVersioningLICM.cpp
  330   assert(I != nullptr && "Null instruction found!");
lib/Transforms/Scalar/MakeGuardsExplicit.cpp
   62   assert(ExplicitGuard->isConditional() && "Must be!");
lib/Transforms/Scalar/MemCpyOptimizer.cpp
  901     assert(isa<AllocaInst>(cpyDest) && "Can only increase alloca alignment!");
lib/Transforms/Scalar/MergeICmps.cpp
  126     assert(Base && "invalid base");
  203       assert(BB);
  204       assert(CmpI);
  205       assert(BranchI);
  279       assert(canSinkBCECmpInst(&Inst, BlockInsts, AA) &&
  381     assert(BranchI->getNumSuccessors() == 2 && "expecting a cond branch");
  438   assert(!Blocks.empty() && "a chain should have at least one block");
  444     assert(Block && "invalid block");
  572     assert(!Comparisons.empty() && "no basic block");
  610   assert(!Comparisons.empty() && "merging zero comparisons");
  679   assert(Comparisons_.size() >= 2 && "simplifying trivial BCECmpChain");
  763   assert(LastBlock && "invalid last block");
lib/Transforms/Scalar/MergedLoadStoreMotion.cpp
  132   assert(isDiamondHead(BB) && "Basic block is not head of a diamond");
  262   assert(S0->getParent() == A0->getParent());
  263   assert(S1->getParent() == A1->getParent());
  287   assert(SinkBB && "Footer of a diamond cannot be empty");
  290   assert(SI != succ_end(HeadBB) && "Diamond head cannot have zero successors");
  293   assert(SI != succ_end(HeadBB) && "Diamond head cannot have single successor");
lib/Transforms/Scalar/NaryReassociate.cpp
  398   assert(Candidate->getType() == GEP->getType());
lib/Transforms/Scalar/NewGVN.cpp
  198     assert(ComponentID > 0 &&
  363     assert(StoreCount != 0 && "Store count went negative");
  839     assert(isa<Instruction>(V) && "This should not be used for MemoryAccesses");
  853     assert(isa<MemoryAccess>(MA) &&
  922     assert(Parent && "Every fake instruction should have a block");
  927   assert(MP && "Should have been an instruction or a MemoryPhi");
  935   assert(isa<BasicExpression>(E));
 1075     assert(isa<BasicExpression>(E) &&
 1133     assert(I->getNumOperands() == 2 && "Unsupported commutative instruction!");
 1148     assert(I->getOperand(0)->getType() == I->getOperand(1)->getType() &&
 1150     assert((E->getOperand(0)->getType() == I->getOperand(0)->getType() &&
 1159       assert(E->getOperand(1)->getType() == I->getOperand(1)->getType() &&
 1312   assert(CC->getMemoryLeader() &&
 1418   assert((!LI || LI->isSimple()) && "Not a simple load");
 1654   assert(Result && "Should have found memory class");
 1662   assert(NewClass &&
 1835   assert(isa<CmpInst>(I) && "Expected a cmp instruction.");
 2066   assert(User && To != User);
 2074     assert(isa<Instruction>(User) && "Use of value not within an instruction?");
 2150   assert(!CC->definesNoMemory() && "Can't get next leader if there is none");
 2159   assert(CC->getStoreCount() == 0);
 2205   assert((!InstMA || !OldClass->getMemoryLeader() ||
 2213     assert(NewClass->size() == 1 ||
 2337   assert(IClass && "Should have found a IClass");
 2339   assert(!IClass->isDead() && "Found a dead class");
 2368       assert(!isa<VariableExpression>(E) &&
 2383         assert((isa<Constant>(EClass->getLeader()) ||
 2389       assert(EClass && "Somehow don't have an eclass");
 2391       assert(!EClass->isDead() && "We accidentally looked up a dead class");
 3013     assert(ProcessedCount[V] < 100 &&
 3069   assert(OldState != MPS_Invalid && "Invalid memory phi state");
 3171       assert((CC->getStoredValue() || !isa<StoreInst>(CC->getLeader())) &&
 3174       assert(CC->getMemoryLeader() &&
 3180       assert(MemoryAccessToClass.lookup(CC->getMemoryLeader()) == CC &&
 3184       assert(MemoryAccessToClass.lookup(M) == CC &&
 3223         assert((singleReachablePHIPath(VisitedMAS, FirstMUD, SecondMUD) ||
 3248       assert(is_splat(PhiOpClasses) &&
 3295       assert(BeforeCC->isEquivalentTo(AfterCC) &&
 3330       assert(Okay && "Stored expression conflict exists in expression table");
 3332       assert(ValueExpr && ValueExpr->equals(*SE) &&
 3429     assert(Node && "RPO and Dominator tree should have same reachability");
 3476     assert(ToErase->getParent() &&
 3568     assert(BB && "Should have figured out a basic block for value");
 3587     assert(isa<Instruction>(D) &&
 3744     assert(ValueStack.size() == DFSStack.size() &&
 3887         assert((!ReachableBlocks.count(cast<Instruction>(M)->getParent()) ||
 3895     assert(CC->getLeader() && "We should have had a leader");
 3915         assert(Leader != I && "About to accidentally remove our leader");
 4020           assert(isa<Instruction>(U->get()) &&
 4022           assert(isa<Instruction>(U->getUser()) &&
 4118         assert(!EliminationStack.empty());
 4121         assert(DT->dominates(Leader->getParent(), Member->getParent()));
lib/Transforms/Scalar/PlaceSafepoints.cpp
  212   assert(DT.dominates(Header, Pred) && "loop latch not dominated by header?");
  276     assert(!isa<InvokeInst>(&*BBI) &&
  316     assert(L->contains(Pred));
  404     assert(HasNextInstruction(I) &&
  430   assert((HasNextInstruction(Cursor) || Cursor->isTerminator()) &&
  556         assert(!Headers.empty() && "poll location is not a loop latch?");
  625   assert(M && "must be part of a module");
  632   assert(F && "gc.safepoint_poll function is missing");
  633   assert(F->getValueType() ==
  636   assert(!F->empty() && "gc.safepoint_poll must be a non-empty function");
  648   assert(After != OrigBB->end() && "must have successor");
  653   assert(InlineStatus && "inline must succeed");
  657   assert(IFI.StaticAllocas.empty() && "can't have allocs");
  668   assert(isPotentiallyReachable(&*Start, &*After) &&
  672   assert(!Calls.empty() && "slow path not found for safepoint poll");
  678   assert(ParsePointsNeeded.empty());
  688   assert(ParsePointsNeeded.size() <= Calls.size());
lib/Transforms/Scalar/Reassociate.cpp
  118   assert(!isa<ConstantInt>(V) && "No ConstantInt");
  221   assert(isa<BinaryOperator>(I) && "Expected binary operator.");
  222   assert(I->isCommutative() && "Expected commutative operator.");
  269   assert((isa<UnaryOperator>(Neg) || isa<BinaryOperator>(Neg)) &&
  325     assert(LHS == 1 && RHS == 1 && "Weights not reduced!");
  330     assert(LHS == 1 && RHS == 1 && "Weights not reduced!");
  340   assert((Opcode == Instruction::Mul || Opcode == Instruction::FMul) &&
  357     assert(LHS.ult(Threshold) && RHS.ult(Threshold) && "Weights not reduced!");
  367     assert(LHS.getZExtValue() < Threshold && RHS.getZExtValue() < Threshold &&
  453   assert((isa<UnaryOperator>(I) || isa<BinaryOperator>(I)) &&
  458   assert(I->isAssociative() && I->isCommutative() &&
  505       assert(!Op->use_empty() && "No uses, so how did we get to it?!");
  510         assert(Visited.insert(Op).second && "Not first visit!");
  520         assert(Visited.insert(Op).second && "Not first visit!");
  533         assert(It != Leaves.end() && Visited.count(Op) &&
  572       assert((!isa<Instruction>(Op) ||
  577       assert(Op->hasOneUse() && "Has uses outside the expression tree!");
  596       assert(!isReassociableOp(Op, Opcode) && "Value was morphed?");
  610     assert(!isReassociableOp(V, Opcode) && "Shouldn't be a leaf!");
  625     assert(Identity && "Associative operation without identity!");
  636   assert(Ops.size() > 1 && "Single values should be used directly!");
 1137     assert(i < Ops.size());
 1152     assert(i < Ops.size());
 1163       assert(Opcode == Instruction::Xor);
 1423       assert(ConstOpnd.isNullValue());
 1540     assert(Factors.size() > 1 && "Bad linearize!");
 1632     assert(NumAddedValues > 1 && "Each occurrence should contribute a value");
 1714   assert(FactorPowerSum >= 4);
 1748   assert(Factors[0].Power);
 1896   assert(isInstructionTriviallyDead(I) && "Trivially dead instructions only!");
 1910   assert(isInstructionTriviallyDead(I) && "Trivially dead instructions only!");
 1993   assert((I->getOpcode() == Instruction::FAdd ||
 2014       assert(!match(Negatible->getOperand(1), m_Constant()) &&
 2016       assert(C->isNegative() && "Expected negative FP constant");
 2021       assert(!match(Negatible->getOperand(0), m_Constant()) &&
 2023       assert(C->isNegative() && "Expected negative FP constant");
 2028   assert(MadeChange == true && "Negative constant candidate was not changed");
 2036   assert(Candidates.size() % 2 == 1 && "Expected odd number");
 2376             assert(res.first->second.isValid() && "WeakVH invalidated");
 2410     assert(RankMap.count(&*BI) && "BB should be ranked.");
 2417         assert(II->getParent() == &*BI && "Moved to a different block!");
lib/Transforms/Scalar/Reg2Mem.cpp
   76   assert(pred_empty(BBEntry) &&
lib/Transforms/Scalar/RewriteStatepointsForGC.cpp
  292     assert(AllowStatepointWithNoDeoptInfo &&
  415     assert(!MustBeBase || MustBeBase == IsKnownBase);
  483   assert((isa<SelectInst>(I) || isa<PHINode>(I)) &&
  493   assert(I->getType()->isPtrOrPtrVectorTy() &&
  523     assert(cast<PointerType>(Def->getType())->getAddressSpace() ==
  529     assert(!isa<CastInst>(Def) && "shouldn't find another cast here");
  569   assert(!isa<LandingPadInst>(I) && "Landing Pad is unimplemented");
  577   assert(!isa<AtomicRMWInst>(I) && "Xchg handled above, all others are "
  588   assert(!isa<InsertValueInst>(I) &&
  605   assert((isa<SelectInst>(I) || isa<PHINode>(I)) &&
  618   assert(Cache[I] != nullptr);
  668     assert(Status != Base || BaseValue);
  728     assert(LHS.getBaseValue() && "can't be null");
  734         assert(LHS == RHS && "equality broken!");
  739     assert(RHS.isConflict() && "only three states!");
  752   assert(Result == meetBDVStateImpl(RHS, LHS) &&
  812       assert(!isKnownBaseResult(Current) && "why did it get added?");
  820         assert(isExpectedBDVType(Base) && "the only non-base values "
  859     assert(I != States.end() && "lookup failed!");
  875       assert(!isKnownBaseResult(BDV) && "why did it get added?");
  917     assert(OldSize == States.size() &&
  933     assert(!isKnownBaseResult(I) && "why did it get added?");
  934     assert(!State.isUnknown() && "Optimistic algorithm didn't complete!");
  955     assert(!isa<InsertElementInst>(I) || State.isConflict());
  966         assert(NumPreds > 0 && "how did we reach here");
 1014       assert(States.count(BDV));
 1017     assert(Base && "Can't be null");
 1031     assert(!isKnownBaseResult(BDV) && "why did it get added?");
 1032     assert(!State.isUnknown() && "Optimistic algorithm didn't complete!");
 1065           assert(Base->stripPointerCasts() == OldBase->stripPointerCasts() &&
 1077       assert(BasePHI->getNumIncomingValues() == NumPHIValues);
 1120     assert(BDV && Base);
 1121     assert(!isKnownBaseResult(BDV) && "why did it get added?");
 1130       assert(isKnownBaseResult(Base) &&
 1134       assert((!isKnownBaseResult(Cache[BDV]) || Cache[BDV] == Base) &&
 1139   assert(Cache.count(Def));
 1164     assert(base && "failed to find base pointer");
 1166     assert((!isa<Instruction>(base) || !isa<Instruction>(ptr) ||
 1230   assert(!isa<PHINode>(Ret->begin()) &&
 1278     assert(ValIt != LiveVec.end() && "Val not found in LiveVec!");
 1280     assert(Index < LiveVec.size() && "Bug in std::find?");
 1293     assert(isHandledGCPointerType(Ty));
 1341     assert(Old != New && Old && New &&
 1359     assert(F && F->getIntrinsicID() == Intrinsic::experimental_deoptimize &&
 1373     assert(OldI != NewI && "Disallowed at construction?!");
 1374     assert((!IsDeoptimize || !New) &&
 1407     assert(F && F->hasFnAttribute(DeoptLowering));
 1419   assert(BasePtrs.size() == LiveVariables.size());
 1458     assert(DeoptLowering.equals("live-through") && "Unsupported value!");
 1506     assert(CI->getNextNode() && "Not a terminator, must have next!");
 1532     assert(!isa<PHINode>(UnwindBlock->begin()) &&
 1549     assert(!isa<PHINode>(NormalDest->begin()) &&
 1558   assert(Token && "Should be set in one of the above branches!");
 1613     assert(PointerToBase.count(L));
 1617   assert(LiveVec.size() == BaseVec.size());
 1639     assert(AllocaMap.count(OriginalValue));
 1645     assert(Relocate->getNextNode() &&
 1672     assert(AllocaMap.count(OriginalValue) &&
 1853         assert(!Inst->isTerminator() &&
 1859       assert(isa<Argument>(Def));
 1864   assert(PromotableAllocas.size() == Live.size() + NumRematerializedValues &&
 1875   assert(InitialAllocaNum == 0 && "We must not introduce any extra allocas");
 1964       assert(CI->isNoopCast(CI->getModule()->getDataLayout()) &&
 2031     assert(Info.PointerToBase.count(LiveValue));
 2062       assert(Info.LiveSet.count(AlternateRootPhi));
 2100         assert(isa<GetElementPtrInst>(Instr) || isa<CastInst>(Instr));
 2109           assert(LastValue);
 2115             assert(!is_contained(ChainToBase, OpValue) &&
 2119             assert(OpValue != RootOfChain && OpValue != AlternateLiveBase);
 2135       assert(LastClonedValue);
 2143       assert(InsertBefore);
 2178   assert(Uniqued.size() == ToUpdate.size() && "no duplicates please!");
 2181     assert(Call->getFunction() == &F);
 2208       assert(!isUnhandledGCPointerType(Arg->getType()) &&
 2354     assert(DT.isReachableFromEntry(Info.StatepointToken->getParent()) &&
 2361       assert(DT.isReachableFromEntry(LiveInst->getParent()) &&
 2363       assert(DT.dominates(LiveInst, Info.StatepointToken) &&
 2373     assert(isHandledGCPointerType(Ptr->getType()) &&
 2506   assert(llvm::any_of(M, shouldRewriteStatepointsIn) && "precondition!");
 2519   assert(!F.isDeclaration() && !F.empty() &&
 2521   assert(shouldRewriteStatepointsIn(F) && "mismatch in rewrite decision");
 2548       assert(DT.isReachableFromEntry(I.getParent()) &&
 2611         assert(VF == 0 ||
 2652       assert(!isUnhandledGCPointerType(V->getType()) &&
 2679       assert(!isUnhandledGCPointerType(V->getType()) &&
 2707       assert(DT.dominates(I, TI) &&
 2736       assert(!Data.LiveSet[&BB].count(Kill) && "live set contains kill");
 2757       assert(Data.LiveIn.count(Succ));
 2774     assert(Data.LiveIn.count(BB));
 2796   assert(Data.LiveOut.count(BB));
 2819       assert(isKnownBaseResult(V) &&
 2826     assert(Info.PointerToBase.count(V) &&
 2842     assert(Updated.count(KVPair.first) && "record for non-live value");
lib/Transforms/Scalar/SCCP.cpp
  118     assert(isConstant() && "Cannot get the constant of a non-constant!");
  134       assert(getConstant() == V && "Marking constant with different value");
  140       assert(V && "Marking constant with NULL");
  143       assert(getLatticeValue() == forcedconstant &&
  173     assert(isUnknown() && "Can't force a defined value!");
  267     assert(A != AnalysisResults.end() && "Need analysis results for function.");
  357     assert(STy && "getStructLatticeValueFor() can be called only on structs");
  360       assert(I != StructValueState.end() && "Value not in valuemap!");
  367     assert(!V->getType()->isStructTy() &&
  370     assert(I != ValueState.end() &&
  414       assert(It != TrackedMultipleRetVals.end());
  441     assert(!V->getType()->isStructTy() && "structs should use mergeInValue");
  446     assert(!V->getType()->isStructTy() && "structs should use mergeInValue");
  481     assert(!V->getType()->isStructTy() &&
  490     assert(!V->getType()->isStructTy() && "Should use getStructValueState");
  510     assert(!V->getType()->isStructTy() && "Should use getStructValueState");
  525     assert(V->getType()->isStructTy() && "Should use getValueState");
  526     assert(i < cast<StructType>(V->getType())->getNumElements() &&
  729     assert(Addr->getFunction() == T->getParent() &&
 1116     assert(State.isConstant() && "Unknown state!");
 1284         assert(State.isConstant() && "Unknown state!");
 1775   assert(Const && "Constant is nullptr here!");
 1934   assert(
 1996     assert(Solver.isEdgeFeasible(I->getParent(), Dest) &&
 2146         assert(Folded &&
 2200     assert(F->getReturnType()->isStructTy() &&
 2219     assert(!I->second.isOverdefined() &&
lib/Transforms/Scalar/SROA.cpp
  391     assert(BeginOffset < EndOffset && "Partitions must span some bytes!");
  459     assert((P.SI != SE || !P.SplitTails.empty()) &&
  478         assert(llvm::any_of(P.SplitTails,
  483         assert(llvm::all_of(P.SplitTails,
  494       assert(P.SplitTails.empty() && "Failed to clear the split slices!");
  545       assert(P.BeginOffset == P.SI->beginOffset());
  563     assert(P.SI->isSplittable() && "Forming a splittable partition!");
  576       assert(!P.SJ->isSplittable());
  583     assert(SE == RHS.SE &&
  592       assert(P.SJ == RHS.P.SJ &&
  594       assert(P.SplitTails.size() == RHS.P.SplitTails.size() &&
  696     assert(AllocSize >= BeginOffset); // Established above.
  780     assert((!LI.isSimple() || LI.getType()->isSingleValueType()) &&
  823     assert((!SI.isSimple() || ValOp->getType()->isSingleValueType()) &&
  829     assert(II.getRawDest() == *U && "Pointer use is not the destination?");
  922     assert(AS.Slices[PrevIdx].getUse()->getUser() == &II &&
  992     assert(isa<PHINode>(I) || isa<SelectInst>(I));
 1063     assert(PointerEscapingInstr && "Did not track a bad instruction");
 1363     assert(LI->isSimple() && "We only speculate simple loads");
 1627           assert(I->use_empty() && "Built a GEP with uses some how!");
 1653     assert(Ptr->getType()->isPointerTy() && "Unexpected operand type!");
 1717     assert(cast<IntegerType>(OldTy)->getBitWidth() !=
 1763   assert(canConvertValue(DL, OldTy, NewTy) && "Value not convertable to type");
 1768   assert(!(isa<IntegerType>(OldTy) && isa<IntegerType>(NewTy)) &&
 1827   assert(EndIndex > BeginIndex && "Empty vector!");
 1854       assert(LTy->isIntegerTy());
 1864       assert(STy->isIntegerTy());
 1942       assert(DL.getTypeSizeInBits(RHSTy) == DL.getTypeSizeInBits(LHSTy) &&
 1944       assert(RHSTy->getElementType()->isIntegerTy() &&
 1946       assert(LHSTy->getElementType()->isIntegerTy() &&
 1959       assert(VTy->getElementType() == CommonEltTy &&
 1961       assert(VTy == CandidateTys[0] &&
 1976     assert((DL.getTypeSizeInBits(VTy) % 8) == 0 &&
 2135   assert(DL.getTypeStoreSize(Ty) + Offset <= DL.getTypeStoreSize(IntTy) &&
 2144   assert(Ty->getBitWidth() <= IntTy->getBitWidth() &&
 2157   assert(Ty->getBitWidth() <= IntTy->getBitWidth() &&
 2164   assert(DL.getTypeStoreSize(Ty) + Offset <= DL.getTypeStoreSize(IntTy) &&
 2188   assert(NumElements <= VecTy->getNumElements() && "Too many elements!");
 2213   assert(VecTy && "Can only insert a vector into a vector");
 2224   assert(Ty->getNumElements() <= VecTy->getNumElements() &&
 2227     assert(V->getType() == VecTy && "Vector type mismatch");
 2342       assert((DL.getTypeSizeInBits(ElementTy) % 8) == 0 &&
 2346     assert((!IntTy && !VecTy) || (IntTy && !VecTy) || (!IntTy && VecTy));
 2361     assert(BeginOffset < NewAllocaEndOffset);
 2362     assert(EndOffset > NewAllocaBeginOffset);
 2378       assert(CanSROA);
 2395     assert(IsSplit || BeginOffset == NewBeginOffset);
 2445     assert(VecTy && "Can only call getIndex when rewriting a vector");
 2447     assert(RelOffset / ElementSize < UINT32_MAX && "Index out of bounds");
 2449     assert(Index * ElementSize == RelOffset);
 2462     assert(EndIndex > BeginIndex && "Empty vector!");
 2470     assert(IntTy && "We cannot insert an integer to the alloca");
 2471     assert(!LI.isVolatile());
 2475     assert(NewBeginOffset >= NewAllocaBeginOffset && "Out of bounds offset");
 2486     assert(cast<IntegerType>(LI.getType())->getBitWidth() >= SliceSize * 8 &&
 2496     assert(OldOp == OldPtr);
 2568       assert(!LI.isVolatile());
 2569       assert(LI.getType()->isIntegerTy() &&
 2571       assert(SliceSize < DL.getTypeStoreSize(LI.getType()) &&
 2573       assert(DL.typeSizeEqualsStoreSize(LI.getType()) &&
 2603       assert(EndIndex > BeginIndex && "Empty vector!");
 2605       assert(NumElements <= VecTy->getNumElements() && "Too many elements!");
 2627     assert(IntTy && "We cannot extract an integer from the alloca");
 2628     assert(!SI.isVolatile());
 2633       assert(BeginOffset >= NewAllocaBeginOffset && "Out of bounds offset");
 2651     assert(OldOp == OldPtr);
 2665       assert(!SI.isVolatile());
 2666       assert(V->getType()->isIntegerTy() &&
 2668       assert(DL.typeSizeEqualsStoreSize(V->getType()) &&
 2731     assert(Size > 0 && "Expected a positive number of bytes.");
 2733     assert(VTy->getBitWidth() == 8 && "Expected an i8 value for the byte");
 2757     assert(II.getRawDest() == OldPtr);
 2765       assert(!IsSplit);
 2766       assert(NewBeginOffset == BeginOffset);
 2819       assert(ElementTy == ScalarTy);
 2823       assert(EndIndex > BeginIndex && "Empty vector!");
 2825       assert(NumElements <= VecTy->getNumElements() && "Too many elements!");
 2839       assert(!II.isVolatile());
 2852         assert(V->getType() == IntTy &&
 2858       assert(NewBeginOffset == NewAllocaBeginOffset);
 2859       assert(NewEndOffset == NewAllocaEndOffset);
 2886     assert((IsDest && II.getRawDest() == OldPtr) ||
 2932       assert(NewBeginOffset == BeginOffset);
 2948       assert(AI != &OldAI && AI != &NewAI &&
 3071     assert(II.isLifetimeStartOrEnd());
 3073     assert(II.getArgOperand(1) == OldPtr);
 3136       assert(isa<BitCastInst>(I) || isa<AddrSpaceCastInst>(I) ||
 3147     assert(BeginOffset >= NewAllocaBeginOffset && "PHIs are unsplittable");
 3148     assert(EndOffset <= NewAllocaEndOffset && "PHIs are unsplittable");
 3180     assert((SI.getTrueValue() == OldPtr || SI.getFalseValue() == OldPtr) &&
 3182     assert(BeginOffset >= NewAllocaBeginOffset && "Selects are unsplittable");
 3183     assert(EndOffset <= NewAllocaEndOffset && "Selects are unsplittable");
 3319           assert(Indices.size() == OldSize && "Did not return to the old size");
 3334           assert(Indices.size() == OldSize && "Did not return to the old size");
 3359       assert(Ty->isSingleValueType());
 3372     assert(LI.getPointerOperand() == *U);
 3399       assert(Ty->isSingleValueType());
 3529     assert(Offset == 0);
 3533     assert(Size > ElementSize);
 3565   assert(Offset == 0);
 3584     assert(Index < EndIndex);
 3676       assert(P.endOffset() > S.beginOffset() &&
 3681         assert(!LI->isVolatile() && "Cannot split volatile loads!");
 3707         assert(!SI->isVolatile() && "Cannot split volatile stores!");
 3718       assert(Offsets.Splits.empty() &&
 3733       assert(Offsets.S == S && "Found a mismatched slice!");
 3734       assert(!Offsets.Splits.empty() &&
 3736       assert(Offsets.Splits.back() ==
 3841     assert(LoadSize > 0 && "Cannot have a zero-sized integer load!");
 3844     assert(LoadSize == Offsets.S->endOffset() - Offsets.S->beginOffset() &&
 3847     assert(BaseOffset + LoadSize > BaseOffset &&
 3964     assert(StoreSize > 0 && "Cannot have a zero-sized integer store!");
 3967     assert(StoreSize == Offsets.S->endOffset() - Offsets.S->beginOffset() &&
 3970     assert(BaseOffset + StoreSize > BaseOffset &&
 3983       assert(SplitLoads->size() == Offsets.Splits.size() + 1 &&
 4051         assert(OtherAI != &AI && "We can't re-split our own alloca!");
 4056         assert(OtherAI != &AI && "We can't re-split our own alloca!");
 4071       assert(*LI->user_begin() == SI && "Single use isn't this store!");
 4133   assert(DL.getTypeAllocSize(SliceTy) >= P.size());
 4380           assert(Start >= OrigFragment->OffsetInBits &&
lib/Transforms/Scalar/Scalarizer.cpp
  251     assert(Size == CachePtr->size() && "Inconsistent vector sizes");
  315   assert(Gathered.empty() && Scattered.empty());
  449   assert(Op.size() == NumElems && "Mismatched unary operation");
  470   assert(Op0.size() == NumElems && "Mismatched binary operation");
  471   assert(Op1.size() == NumElems && "Mismatched binary operation");
  521       assert(Scattered[I].size() == NumElems && "mismatched call operands");
  561   assert(Op1.size() == NumElems && "Mismatched select");
  562   assert(Op2.size() == NumElems && "Mismatched select");
  568     assert(Op0.size() == NumElems && "Mismatched select");
  652   assert(Op0.size() == NumElems && "Mismatched cast");
lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp
  651     assert(isa<ConstantInt>(U));
  657     assert(
  685     assert(isa<ConstantInt>(UserChain[ChainIndex]));
  690   assert(BO->getNumUses() <= 1 &&
  696   assert(BO->getOperand(OpNo) == UserChain[ChainIndex - 1]);
lib/Transforms/Scalar/SimpleLoopUnswitch.cpp
  105   assert(!L.isLoopInvariant(&Root) &&
  143   assert(!isa<Constant>(Invariant) && "Why are we unswitching on a constant?");
  205       assert(PN.getIncomingBlock(i) == &OldExitingBB &&
  224   assert(&ExitBB != &UnswitchedBB &&
  285     assert(NewParentL->contains(OldParentL) &&
  290   assert(OldParentL == LI.getLoopFor(&Preheader) &&
  352   assert(BI.isConditional() && "Can only unswitch a conditional branch!");
  440     assert(LoopExitBB->getUniquePredecessor() == BI.getParent() &&
  476       assert(cast<Instruction>(BI.getCondition())->getOpcode() ==
  480       assert(cast<Instruction>(BI.getCondition())->getOpcode() ==
  757       assert(W &&
  775       assert(Case.getCaseSuccessor() == CommonSuccBB &&
  789     assert(SI.getNumCases() > 0 &&
  824   assert(DT.verify(DominatorTree::VerificationLevel::Fast));
 1031     assert(ClonedExitBB->getTerminator()->getNumSuccessors() == 1 &&
 1033     assert(ClonedExitBB->getTerminator()->getSuccessor(0) == MergeBB &&
 1046       assert(
 1050       assert(VMap.lookup(&I) == &ClonedI && "Mismatch in the value map!");
 1144     assert(ClonedL.getBlocks().empty() && "Must start with an empty loop!");
 1227   assert((!ParentL || ParentL == OrigL.getParentLoop() ||
 1255     assert(ClonedLoopBlocks.count(Pred) && "Found a predecessor of the loop "
 1274       assert(BlocksInClonedLoop.count(BB) &&
 1335         assert(BlocksInClonedLoop.count(
 1372     assert(Worklist.empty() && "Didn't clear worklist!");
 1390           assert(
 1401         assert(Inserted && "Should only visit an unlooped block once!");
 1424     assert(LI.getLoopFor(BB) == OuterL &&
 1440       assert(VMap.count(ChildLoopBB) &&
 1526     assert(llvm::all_of(ChildL->blocks(),
 1541     assert(!DT.getNode(BB) && "Should already have cleared domtree!");
 1582     assert(L.contains(Pred) && "Found a predecessor of the loop header other "
 1600     assert(LoopBlockSet.count(BB) && "Didn't put block into the loop set!");
 1612         assert(L.contains(InnerL) &&
 1617         assert(L.contains(InnerPH) && "Cannot contain an inner loop block "
 1632             assert(LoopBlockSet.count(InnerBB) &&
 1653   assert(LoopBlockSet.count(Header) && "Cannot fail to add the header!");
 1761     assert(Worklist.empty() && "Didn't clear worklist!");
 1762     assert(NewExitLoopBlocks.empty() && "Didn't clear loop set!");
 1767     assert(ExitL.contains(&L) && "Exit loop must contain the inner loop!");
 1789           assert((NewExitLoopBlocks.count(PredBB) ||
 1800         assert(Inserted && "Should only visit an unlooped block once!");
 1861     assert(SubLoops.empty() &&
 1894       assert(Visited.insert(ChildN).second &&
 1912   assert((SI || (BI && BI->isConditional())) &&
 1916     assert(Invariants.size() == 1 &&
 1919     assert(isa<Instruction>(BI->getCondition()) &&
 1935       assert(cast<Instruction>(BI->getCondition())->getOpcode() ==
 1954   assert(!UnswitchedSuccBBs.count(RetainedSuccBB) &&
 1961   assert(LI.getLoopFor(ParentBB) == &L && "Branch in an inner loop!");
 2054       assert(SI && "Must either be a branch or switch!");
 2057       assert(SI->getDefaultDest() == RetainedSuccBB &&
 2100       assert(UnswitchedSuccBBs.size() == 1 &&
 2114       assert(NewSI->getDefaultDest() == RetainedSuccBB &&
 2135     assert(BI && "Only branches have partial unswitching.");
 2136     assert(UnswitchedSuccBBs.size() == 1 &&
 2192   assert(DT.verify(DominatorTree::VerificationLevel::Fast));
 2199     assert(UnswitchedSuccBBs.size() == 1 &&
 2256       assert(ChildL->isRecursivelyLCSSAForm(DT, LI) &&
 2349   assert(Inserted && "Should not insert a node while visiting children!");
 2648     assert(Cost >= 0 && "Must not have negative costs!");
 2650     assert(LoopCost >= 0 && "Must not have negative loop costs!");
 2693           assert(cast<Instruction>(BI.getCondition())->getOpcode() ==
 2711         assert(Cost >= 0 &&
 2722     assert(SuccessorsCount > 1 &&
 2741       assert(
 2759   assert(BestUnswitchTI && "Failed to find loop unswitch candidate");
 2806   assert(L.isRecursivelyLCSSAForm(DT, LI) &&
 2885   assert(AR.DT.verify(DominatorTree::VerificationLevel::Fast));
 2975   assert(DT.verify(DominatorTree::VerificationLevel::Fast));
lib/Transforms/Scalar/Sink.cpp
   96   assert(Inst && "Instruction to be sunk is null");
   97   assert(SuccToSinkTo && "Candidate sink target is null");
lib/Transforms/Scalar/SpeculateAroundPHIs.cpp
  171     assert(PotentialSpecSet.count(I) &&
  320   assert(TotalFoldedCost <= TotalMatCost && "If each constant's folded cost is "
  379         assert(!IsVisited(UI) && "Should not have already visited a node!");
  434     assert(UserSet.empty() && "Must start with an empty user set!");
  471         assert(Inserted && "Must not re-insert a cost during the DFS!");
  482               assert(
  531           assert(SpecCostMap.find(SpecI)->second == 0 &&
  580       assert(PredBB->getSingleSuccessor() == ParentBB &&
  582       assert(!isa<InvokeInst>(PredBB->getTerminator()) &&
  654     assert(PredBB->getSingleSuccessor() == ParentBB &&
  673         assert(SpeculatedVals[PredIdx] &&
  675         assert(SpeculatedVals[PredIdx]->getType() == OpI->getType() &&
  690       assert(SpeculatedValueMap[OrigI][PredIdx] == NewI &&
  723     assert(SpecPN->use_empty() && "All users should have been speculated!");
lib/Transforms/Scalar/StraightLineStrengthReduce.cpp
  392   assert(I->getNumOperands() == 2 && "isn't I an add?");
  460   assert(I->getNumOperands() == 2 && "isn't I a mul?");
  623   assert(C.CandidateKind == Basis.CandidateKind && C.Base == Basis.Base &&
  627   assert(Basis.Ins->getParent() != nullptr && "the basis is unlinked");
lib/Transforms/Scalar/StructurizeCFG.cpp
  542     assert(Term->isConditional());
  637   assert(DeletedPhis.empty());
  902     assert(EntryDominatesExit);
lib/Transforms/Scalar/TailRecursionElimination.cpp
  424   assert(I->getNumOperands() == 2 &&
  694   assert(BB->getFirstNonPHIOrDbg() == Ret &&
lib/Transforms/Utils/ASanStackFrameLayout.cpp
   56   assert(Granularity >= 8 && Granularity <= 64 &&
   58   assert(MinHeaderSize >= 16 && (MinHeaderSize & (MinHeaderSize - 1)) == 0 &&
   61   assert(NumVars > 0);
   72   assert((Offset % Granularity) == 0);
   78     assert((Alignment & (Alignment - 1)) == 0);
   79     assert(Layout.FrameAlignment >= Alignment);
   80     assert((Offset % Alignment) == 0);
   81     assert(Size > 0);
   93   assert((Layout.FrameSize % MinHeaderSize) == 0);
  118   assert(Vars.size() > 0);
  141     assert(Var.LifetimeSize <= Var.Size);
lib/Transforms/Utils/BasicBlockUtils.cpp
   81     assert(BB->getInstList().size() == 1 &&
   98   assert(Dead.size() == BBs.size() && "Duplicating blocks?");
  101       assert(Dead.count(Pred) && "All predecessors must be dead!");
  308     assert(BB->getInstList().size() == 1 &&
  337   assert(I->getParent() == nullptr &&
  376     assert(SP == BB && "CFG broken");
  383   assert(BB->getTerminator()->getNumSuccessors() == 1 &&
  445       assert(NewBB == &NewBB->getParent()->getEntryBlock());
  461   assert(DT && "DT should be available to update LoopInfo!");
  633     assert(!isa<IndirectBrInst>(Preds[i]->getTerminator()) &&
  635     assert(!isa<CallBrInst>(Preds[i]->getTerminator()) &&
  670   assert(OrigBB->isLandingPad() && "Trying to split a non-landing pad!");
  688     assert(!isa<IndirectBrInst>(Preds[i]->getTerminator()) &&
  706     assert(!isa<IndirectBrInst>(Pred->getTerminator()) &&
  750       assert(!LPad->getType()->isTokenTy() &&
  963   assert(BI->isConditional() && "Two successors but not conditional?");
lib/Transforms/Utils/BreakCriticalEdges.cpp
  110   assert((SplitBB->getFirstNonPHI() == SplitBB->getTerminator() ||
  142   assert(!isa<IndirectBrInst>(TI) &&
  265           assert(DestLoop->getHeader() == DestBB &&
  275         assert(!TIL->contains(NewBB) &&
  306           assert(!DestBB->isEHPad() && "We don't split edges to EH pads!");
  438     assert(&*End == Target->getTerminator() &&
lib/Transforms/Utils/BuildLibCalls.cpp
  108   assert(F.getReturnType()->isPointerTy() &&
  805   assert(hasFloatFn(TLI, Ty, DoubleFn, FloatFn, LongDoubleFn) &&
 1045   assert((Name != "") && "Must specify Name to emitUnaryFloatFnCall");
 1087   assert((Name != "") && "Must specify Name to emitBinaryFloatFnCall");
 1109   assert((Name != "") && "Must specify Name to emitBinaryFloatFnCall");
lib/Transforms/Utils/BypassSlowDivision.cpp
  236   assert(LongLen > ShortLen && "Value type must be wider than BypassType");
  329   assert((Op1 || Op2) && "Nothing to check");
lib/Transforms/Utils/CallPromotionUtils.cpp
  321   assert(!CS.getCalledFunction() && "Only indirect call sites can be promoted");
  367   assert(!CS.getCalledFunction() && "Only indirect call sites can be promoted");
lib/Transforms/Utils/CloneFunction.cpp
   91   assert(NameSuffix && "NameSuffix cannot be null!");
   95     assert(VMap.count(&I) && "No mapping from source argument specified!");
  130     assert(!MustCloneSP || ModuleLevelChanges);
  455   assert(NameSuffix && "NameSuffix cannot be null!");
  465       assert(VMap.count(&II) && "No mapping from source argument specified!");
  539           assert(InVal && "Unknown input value?");
  558       assert(NumPreds < PN->getNumIncomingValues());
  592         assert(VMap[&*OldI] == PN && "VMap mismatch");
  690     assert(!isa<PHINode>(Dest->begin()));
  769   assert(OrigPH && "No preheader");
  789       assert(OrigParent && "Could not find the original parent loop");
  791       assert(NewParentLoop && "Could not find the new parent loop");
  800     assert(NewLoop && "Expecting new loop to be allocated");
  839   assert(count(successors(PredBB), BB) == 1 &&
lib/Transforms/Utils/CodeExtractor.cpp
  198   assert(!BBs.empty() && "The set of blocks to extract must be non-empty");
  387   assert(!Blocks.count(CommonExitBlock) &&
  420   assert(!getFirstPHI(CommonExitBlock) && "Phi not expected");
  559       assert(LMI.LifeStart &&
 1024       assert((!isa<Instruction>(Mem) || cast<Instruction>(Mem)->getFunction() ==
 1252     assert((InsertBefore->getFunction() == newFunction ||
 1255     assert(OAI != newFunction->arg_end() &&
 1399     assert(BPI && "Both BPI and BFI are required to preserve profile info");
 1473   assert(HoistingCands.empty() || CommonExit);
 1489   assert((SinkingCands.empty() || FirstSunkAlloca) &&
 1565           assert(IncomingCodeReplacerVal == PN.getIncomingValue(i) &&
lib/Transforms/Utils/DemoteRegToStack.cpp
   49       assert(isCriticalEdge(II, SuccNum) && "Expected a critical edge!");
   51       assert(BB && "Unable to split critical edge.");
  133       assert(II->getParent() != P->getIncomingBlock(i) &&
lib/Transforms/Utils/FlattenCFG.cpp
  174     assert(PBI->isConditional());
  486   assert(BB && BB->getParent() && "Block not embedded in function!");
  487   assert(BB->getTerminator() && "Degenerate basic block encountered!");
lib/Transforms/Utils/FunctionComparator.cpp
  174   assert(LCS && RCS && "Must be calls or invokes!");
  175   assert(LCS.isCall() == RCS.isCall() && "Can't compare otherwise!");
  371           assert(&BB != RBB);
  384       assert(LBA->getFunction() == FnL && RBA->getFunction() == FnR);
  441     assert(PTyL && PTyR && "Both types must be pointers here.");
  711   assert(L->getFunctionType() != R->getFunctionType());
  772       assert(InstL->getNumOperands() == InstR->getNumOperands());
  780         assert(cmpTypes(OpL->getType(), OpR->getType()) == 0);
  826   assert(FnL->arg_size() == FnR->arg_size() &&
  872     assert(TermL->getNumSuccessors() == TermR->getNumSuccessors());
lib/Transforms/Utils/FunctionImportUtils.cpp
   27   assert(!isa<GlobalAlias>(SGV) &&
   44   assert(SGV->hasLocalLinkage());
   51     assert((!GlobalsToImport->count(const_cast<GlobalValue *>(SGV)) ||
   69   assert(Summary && "Missing summary for global value when exporting");
   72     assert(!isNonRenamableLocal(*SGV) &&
  152     assert(!doImportAsDefinition(SGV));
  190     assert(!doImportAsDefinition(SGV));
  285     assert(GO->hasAvailableExternallyLinkage() &&
lib/Transforms/Utils/GlobalStatus.cpp
  163         assert(MSI->getArgOperand(0) == V && "Memset only takes one pointer!");
lib/Transforms/Utils/ImportedFunctionsInliningStatistics.cpp
   54     assert(It != NodesMap.end() && "The node should be already there.");
  107     assert(Node->second->NumberOfInlines >= Node->second->NumberOfRealInlines);
  176   assert(!GraphNode.Visited);
lib/Transforms/Utils/InlineFunction.cpp
  238     assert(!MemoMap.count(CurrentPad));
  283             assert(getParentPad(ChildUnwindDestToken) == CatchPad);
  394   assert((UnwindDestToken == nullptr) != (MemoMap.count(EHPad) != 0));
  423     assert(!MemoMap.count(AncestorPad) || MemoMap[AncestorPad]);
  464       assert(getParentPad(Memo->second) == getParentPad(UselessPad));
  476     assert(!MemoMap.count(UselessPad) || TempMemos.count(UselessPad));
  486       assert(CatchSwitch->getUnwindDest() == nullptr && "Expected useless pad");
  490           assert(
  501       assert(isa<CleanupPadInst>(UselessPad));
  503         assert(!isa<CleanupReturnInst>(U) && "Expected useless pad");
  504         assert((!isa<InvokeInst>(U) ||
  566       assert(FuncletUnwindMap->count(MemoKey) &&
  646   assert(UnwindDest->getFirstNonPHI()->isEHPad() && "unexpected BasicBlock!");
  687         assert(!FuncletUnwindMap.count(CleanupPad) ||
  868     assert(TempM->isTemporary() && "Expected temporary node");
 1363   assert(OrigLoopId && OrigLoopId->getNumOperands() > 0 &&
 1365   assert(OrigLoopId && OrigLoopId->getOperand(0).get() == OrigLoopId &&
 1542   assert(TheCall->getParent() && TheCall->getFunction()
 2152         assert(!OpBundles.empty() &&
 2296   assert(Br && Br->getOpcode() == Instruction::Br &&
 2328         assert(RI->getReturnValue()->getType() == PHI->getType() &&
 2390   assert(cast<BranchInst>(Br)->isUnconditional() && "splitBasicBlock broken!");
lib/Transforms/Utils/IntegerDivision.cpp
   41     assert(BitWidth == 32 && "Unexpected bit width");
  113     assert(BitWidth == 32 && "Unexpected bit width");
  171     assert(BitWidth == 32 && "Unexpected bit width");
  376   assert((Rem->getOpcode() == Instruction::SRem ||
  382   assert(!Rem->getType()->isVectorTy() && "Div over vectors not supported");
  383   assert((Rem->getType()->getIntegerBitWidth() == 32 ||
  418     assert(UDiv->getOpcode() == Instruction::UDiv && "Non-udiv in expansion?");
  434   assert((Div->getOpcode() == Instruction::SDiv ||
  440   assert(!Div->getType()->isVectorTy() && "Div over vectors not supported");
  441   assert((Div->getType()->getIntegerBitWidth() == 32 ||
  486   assert((Rem->getOpcode() == Instruction::SRem ||
  491   assert(!RemTy->isVectorTy() && "Div over vectors not supported");
  495   assert(RemTyBitWidth <= 32 &&
  535   assert((Rem->getOpcode() == Instruction::SRem ||
  540   assert(!RemTy->isVectorTy() && "Div over vectors not supported");
  544   assert(RemTyBitWidth <= 64 && "Div of bitwidth greater than 64 not supported");
  584   assert((Div->getOpcode() == Instruction::SDiv ||
  589   assert(!DivTy->isVectorTy() && "Div over vectors not supported");
  593   assert(DivTyBitWidth <= 32 && "Div of bitwidth greater than 32 not supported");
  632   assert((Div->getOpcode() == Instruction::SDiv ||
  637   assert(!DivTy->isVectorTy() && "Div over vectors not supported");
  641   assert(DivTyBitWidth <= 64 &&
lib/Transforms/Utils/LCSSA.cpp
   92     assert(!I->getType()->isTokenTy() && "Tokens shouldn't be in the worklist");
   95     assert(L && "Instruction belongs to a BB that's not part of a loop");
   98     assert(LoopExitBlocks.count(L));
  379   assert(L.isLCSSAForm(DT));
  425       assert(all_of(*LI,
lib/Transforms/Utils/LibCallsShrinkWrap.cpp
  282   assert(Cond && "performCallErrors should not see an empty condition");
  485   assert(Cond != nullptr && "ShrinkWrapCI is not expecting an empty call inst");
  494   assert(SuccBB && "The split block should have a single successor");
  507   assert(Callee && "perform() should apply to a non-empty callee");
  509   assert(Func && "perform() is not expecting an empty function");
  531   assert(!DT || DT->verify(DominatorTree::VerificationLevel::Fast));
lib/Transforms/Utils/Local.cpp
  145       assert(BI->getParent() && "Terminator not inserted in block!");
  281         assert(SICase && SIDef);
  459     assert(I.use_empty() && "Instructions with uses are not dead.");
  460     assert(isInstructionTriviallyDead(&I, TLI) &&
  621     assert(!BI->isTerminator());
  683   assert(PredBB && "Block doesn't have a single predecessor!");
  728     assert(PredBB->getInstList().size() == 1 &&
  760   assert(*succ_begin(BB) == Succ && "Succ is not successor of BB!");
  834     assert((!IncomingValues.count(BB) ||
  898   assert(OldVal && "No entry in PHI for Pred BB!");
  951   assert(BB != &BB->getParent()->getEntryBlock() &&
 1040       assert(PN->use_empty() && "There shouldn't be any uses here!");
 1064   assert(succ_empty(BB) && "The successor list of BB isn't empty before "
 1138   assert(PrefAlign > Alignment);
 1186   assert(V->getType()->isPointerTy() &&
 1240     assert(DVI->getValue() == APN);
 1289   assert(DII->isAddressOfVariable());
 1291   assert(DIVar && "Missing variable");
 1321   assert(DIVar && "Missing variable");
 1352   assert(DIVar && "Missing variable");
 1450   assert(BB && "No BasicBlock to clone dbg.value(s) from.");
 1482         assert(InsertionPt != Parent->end() && "Ill-formed basic block");
 1547     assert(DIVar && "Missing variable");
 1571   assert(DIVar && "Missing variable");
 1827   assert(&From != &To && "Can't replace something with itself");
 1847     assert(FromBits != ToBits && "Unexpected no-op conversion");
 2223   assert(Reachable.size() < F.size());
 2250       assert(TI && "Basic block should have a terminator");
 2257       assert(succ_empty(BB) && "The successor list of BB isn't empty before "
 2463   assert(From->getType() == To->getType());
 2480    assert(From->getType() == To->getType());
lib/Transforms/Utils/LoopRotationUtils.cpp
  285   assert(NewHeader && "Unable to determine new loop header");
  286   assert(L->contains(NewHeader) && !L->contains(Exit) &&
  291   assert(NewHeader->getSinglePredecessor() &&
  418   assert(L->getHeader() == NewHeader && "Latch block is our new header");
  445   assert(PHBI->isConditional() && "Should be clone of BI condbr!");
  478     assert(SplitLatchEdge &&
  496   assert(L->getLoopPreheader() && "Invalid loop preheader after loop rotation");
  497   assert(L->getLoopLatch() && "Invalid loop latch after loop rotation");
  642   assert((!MadeChange || L->isLoopExiting(L->getLoopLatch())) &&
lib/Transforms/Utils/LoopSimplify.cpp
  234   assert(!Header->isEHPad() && "Can't insert backedge to EH pad");
  335     assert(NewOuter->isRecursivelyLCSSAForm(*DT, *LI) &&
  351   assert(L->getNumBackEdges() > 1 && "Must have > 1 backedge!");
  362   assert(!Header->isEHPad() && "Can't insert backedge to EH pad");
  418     assert(PreheaderIdx != ~0U && "PHI has no preheader entry??");
  671       assert(pred_begin(ExitingBlock) == pred_end(ExitingBlock));
  718     assert(DT && "DT not available.");
  719     assert(LI && "LI not available.");
  720     assert(L->isRecursivelyLCSSAForm(*DT, *LI) &&
  825     assert(InLCSSA && "LCSSA is broken after loop-simplify.");
lib/Transforms/Utils/LoopUnroll.cpp
  136   assert(OldLoop && "Should (at least) be in the loop being unrolled!");
  141     assert(OriginalBB == OldLoop->getHeader() &&
  188   assert(PreHeader && Header);
  366   assert(ULO.Count > 0);
  367   assert(ULO.TripMultiple > 0);
  368   assert(ULO.TripCount == 0 || ULO.TripCount % ULO.TripMultiple == 0);
  393   assert((!RuntimeTripCount || !ULO.PeelCount) &&
  408       assert(ExitingBlock && "Loop without exiting block?");
  409       assert(L->isLoopExiting(ExitingBlock) && "Latch is not exiting?");
  425         assert((!HasConvergent || ULO.TripMultiple % ULO.Count == 0) &&
  559       assert(L->contains(Term->getSuccessor(0)));
  562       assert(L->contains(Term->getSuccessor(1)));
  611       assert((*BB != Header || LI->getLoopFor(*BB) == L) &&
  707       assert(Latches.back() == LastValueMap[LatchBlock] && "bad last latch");
  763         assert(NeedConditional &&
  870   assert(!DT || !UnrollVerifyDomtree ||
  877     assert((Term ||
  941         assert(OuterL->isLCSSAForm(*DT) &&
  964   assert(LoopID->getNumOperands() > 0 && "requires at least one operand");
  965   assert(LoopID->getOperand(0) == LoopID && "invalid loop id");
lib/Transforms/Utils/LoopUnrollAndJam.cpp
  180   assert(L->getSubLoops().size() == 1);
  189   assert(Count > 0);
  190   assert(TripMultiple > 0);
  191   assert(TripCount == 0 || TripCount % TripMultiple == 0);
  251   assert(Preheader && LatchBlock && Header);
  252   assert(BI && !BI->isUnconditional());
  373         assert(OriginalBBIDom);
  374         assert(LastValueMap[cast<Value>(OriginalBBIDom)]);
  394       assert(OldValue && "should have incoming edge from Aft[It]");
  399       assert(Phi.getNumOperands() == 2);
  550         assert(Fold == BB);
  574   assert(OutestLoop->isRecursivelyLCSSAForm(*DT, *LI));
  576     assert(L->isLoopSimplifyForm());
  577   assert(SubLoop->isLoopSimplifyForm());
  578   assert(DT->verify());
  633         assert(D->isOrdered() && "Expected an output, flow or anti dep.");
  649           assert(LoopDepth + 1 <= D->getLevels());
lib/Transforms/Utils/LoopUnrollPeel.cpp
  128   assert(Phi->getParent() == L->getHeader() &&
  130   assert(BackEdge == L->getLoopLatch() && "Wrong latch?");
  174   assert(L.isLoopSimplifyForm() && "Loop needs to be in loop simplify form");
  262   assert(LoopSize > 0 && "Zero loop size is not allowed!");
  310     assert(BackEdge && "Loop is not in simplified form?");
  329       assert(DesiredPeelCount > 0 && "Wrong loop size estimation?");
  581   assert(PeelCount > 0 && "Attempt to peel out zero iterations?");
  582   assert(canPeel(L) && "Attempt to peel a loop which is not peelable?");
  613     assert(L->hasDedicatedExits() && "No dedicated exits?");
  619       assert(L->contains(BB) && "IDom is not in a loop");
  757   assert(DT->verify(DominatorTree::VerificationLevel::Fast));
lib/Transforms/Utils/LoopUnrollRuntime.cpp
   84   assert(Latch && "Loop must have a latch");
  151   assert(Count != 0 && "nonsensical Count!");
  188   assert(Latch && "Loop must have a latch");
  218     assert(PN.hasOneUse() && "The phi should have 1 use");
  220     assert(EpilogPN->getParent() == Exit && "EpilogPN should be in Exit block");
  234     assert(EpilogPN->getBasicBlockIndex(EpilogPreHeader) >= 0 &&
  273   assert(Exit && "Loop must have a single exit block only");
  400     assert(NewLoop && "L should have been cloned");
  466   assert(canSafelyUnrollMultiExitLoop(L, LatchExit, PreserveLCSSA,
lib/Transforms/Utils/LoopUtils.cpp
   60     assert(InLoopPredecessors.empty() &&
   81     assert(!InLoopPredecessors.empty() && "Must have *some* loop predecessor!");
  311   assert(OrigLoopID->getOperand(0) == OrigLoopID);
  509   assert((!DT || L->isLCSSAForm(*DT)) && "Expected LCSSA!");
  511   assert(Preheader && "Preheader should exist!");
  526   assert(ExitBlock && "Should have a unique exit block!");
  527   assert(L->hasDedicatedExits() && "Loop should have dedicated exits!");
  530   assert(OldBr && "Preheader must end with a branch");
  531   assert(OldBr->isUnconditional() && "Preheader must have a single successor");
  580     assert((P.getNumIncomingValues() == 1 &&
  623           assert(!DT->isReachableFromEntry(U) &&
  644   assert(InsertDbgValueBefore &&
  691   assert((LatchBR->getSuccessor(0) == L->getHeader() ||
  806       assert(MinMaxKind != RecurrenceDescriptor::MRK_Invalid &&
  827   assert(isPowerOf2_32(VF) &&
  849       assert(MinMaxKind != RecurrenceDescriptor::MRK_Invalid &&
  866   assert(isa<VectorType>(Src->getType()) && "Type must be a vector");
lib/Transforms/Utils/LoopVersioning.cpp
   37   assert(L->getExitBlock() && "No single exit block");
   38   assert(L->isLoopSimplifyForm() && "Loop is not in loop-simplify form");
   85   assert(RuntimeCheck && "called even though we don't need "
  126   assert(PHIBlock && "No single successor to loop exit block");
  154     assert(PN->getNumOperands() == 1 &&
lib/Transforms/Utils/LowerMemIntrinsics.cpp
  108       assert(GepIndex * OperandSize == BytesCopied &&
  131   assert(BytesCopied == CopyLen->getZExtValue() &&
  168   assert(ILengthType &&
lib/Transforms/Utils/LowerSwitch.cpp
  253   assert(LowerBound && UpperBound && "Bounds must be initialized");
  389     assert(BlockIdx != -1 && "Switch didn't go to this successor??");
  424       assert(nextValue > currentValue && "Cases should be strictly ascending");
  534         assert(Low > LastRange.Low);
  554       assert(I->Low <= I->High);
  557         assert(Next->Low > I->High);
  570     assert(MaxPop > 0 && PopSucc);
lib/Transforms/Utils/MisExpect.cpp
   53   assert(I != nullptr && "MisExpect target Instruction cannot be nullptr");
lib/Transforms/Utils/ModuleUtils.cpp
  112   assert(!InitName.empty() && "Expected init function name");
  123   assert(!InitName.empty() && "Expected init function name");
  124   assert(InitArgs.size() == InitArgTypes.size() &&
  149   assert(!CtorName.empty() && "Expected ctor function name");
  167   assert(!Name.empty() && "Expected init function name");
  197     assert(C && "Expected all input GVs to be in a comdat!");
lib/Transforms/Utils/PredicateInfo.cpp
   59   assert(isa<PredicateWithEdge>(PB) &&
   68   assert(isa<PredicateWithEdge>(PB) &&
   77   assert(isa<PredicateWithEdge>(PB) &&
  141     assert((A.DFSIn != B.DFSIn || A.DFSOut == B.DFSOut) &&
  181     assert(DomASrc->getDFSNumIn() == (unsigned)A.DFSIn &&
  183     assert(DomBSrc->getDFSNumIn() == (unsigned)B.DFSIn &&
  185     assert(A.DFSIn == B.DFSIn && "Values must be in the same block");
  198     assert((!A.Def || !A.U) && (!B.Def || !B.U) &&
  215       assert(VD.PInfo &&
  217       assert(isa<PredicateAssume>(VD.PInfo) &&
  379       assert(BinOp->getOpcode() == Instruction::And &&
  447       assert((BinOp->getOpcode() == Instruction::And ||
  567       assert(PAssume &&
  714       assert(DT.dominates(cast<Instruction>(Result.Def), *VD.U) &&
  728     assert(InsertResult.second && "Value info number already existed?");
  737   assert(OINI != 0 && "Operand was not really in the Value Info Numbers");
  738   assert(OINI < ValueInfos.size() &&
  762     assert(F->user_begin() == F->user_end() &&
lib/Transforms/Utils/PromoteMemoryToRegister.cpp
  198     assert(isInterestingInstruction(I) &&
  216     assert(It != InstNumbers.end() && "Didn't insert instruction?");
  543     assert(isAllocaPromotable(AI) && "Cannot promote non-promotable alloca!");
  544     assert(AI->getParent()->getParent() == &F &&
  744       assert(EntIt != Preds.end() && *EntIt == SomePHI->getIncomingBlock(i) &&
  896       assert(NumEdges && "Must be at least one edge from Pred to BB!");
lib/Transforms/Utils/SSAUpdater.cpp
   72   assert(ProtoType && "Need to initialize SSAUpdater");
   73   assert(ProtoType == V->getType() &&
  441     assert(StoredValue && "Already checked that there is a store in block");
  470       assert(NewVal && "not a replaced load?");
lib/Transforms/Utils/SSAUpdaterBulk.cpp
   52   assert(Var < Rewrites.size() && "Variable not found!");
   62   assert(Var < Rewrites.size() && "Variable not found!");
  181       assert(OldVal && "Invalid use!");
lib/Transforms/Utils/SimplifyCFG.cpp
  266   assert(SI1->isUnconditional() && SI2->isConditional());
  317   assert(isSafeToSpeculativelyExecute(I) &&
  801   assert(isa<BranchInst>(I) || isa<SelectInst>(I));
  823   assert(ThisVal && "This isn't a value comparison!!");
  853       assert(ThisCases.size() == 1 && "Branch can only have one case!");
  899   assert(TIV && "No edge from pred to succ?");
  971   assert(MD);
  981     assert(Weights.size() == 2);
 1006   assert(CV && "Not a comparison?");
 1290       assert (isa<DbgInfoIntrinsic>(I1) && isa<DbgInfoIntrinsic>(I2));
 1522       assert(I->getNumOperands() == I0->getNumOperands());
 1593     assert(!Op->getType()->isTokenTy() && "Can't PHI tokens!");
 1970     assert(ThenBB == BI->getSuccessor(1) && "No edge from 'if' block?");
 1973   assert(EndBB == BI->getSuccessor(!Invert) && "No edge from to end block");
 2403   assert(DomBlock && "Failed to find root DomBlock");
 2447   assert(BI->isConditional() && "Must be a conditional branch");
 2817         assert(PBI_C->getType()->isIntegerTy(1));
 2921       assert(Succ->hasNPredecessors(2));
 3019     assert(BudgetRemaining >= 0 &&
 3222   assert(PBI->isConditional() && BI->isConditional());
 3618     assert(VVal && "Should have a unique destination value");
 3901   assert(RI->getValue() == LPInst &&
 3982       assert(Idx != -1);
 4227         assert(BI->getSuccessor(0) == BB && "Incorrect CFG");
 4237           assert(BI->getSuccessor(1) == BB && "Incorrect CFG");
 4314   assert(Cases.size() >= 1);
 4338   assert(SI->getNumCases() > 1 && "Degenerate switch?");
 4366   assert(DestA && DestB &&
 4368   assert(DestA != DestB);
 4369   assert(DestB != SI->getDefaultDest());
 4370   assert(!CasesB.empty() && "There must be non-default cases.");
 4371   assert(!CasesA.empty() || HasDefault);
 4488   assert(NumUnknownBits <= Bits);
 4502     assert(CaseI != SI->case_default() &&
 4532     assert(Idx >= 0 && "PHI has no entry for predecessor?");
 4834   assert(ResultVector.size() == 2 &&
 4901   assert(PHI != nullptr && "PHI for value select not found");
 4979   assert(Values.size() && "Can't build lookup table without values!");
 4980   assert(TableSize >= Values.size() && "Can't fit values in table!");
 4992     assert(CaseRes->getType() == ValueType);
 5003     assert(DefaultValue &&
 5005     assert(DefaultValue->getType() == ValueType);
 5028     assert(TableSize >= 2 && "Should be a SingleValue table.");
 5259     assert((CaseConst == TrueConst || CaseConst == FalseConst) &&
 5294   assert(SI->getNumCases() > 1 && "Degenerate switch?");
 5317   assert(!SI->cases().empty());
 5408   assert(MaxTableSize >= TableSize &&
 5596   assert(Shift < 64);
 5746   assert(Succ);
 5771       assert(II->getNormalDest() != BB && II->getUnwindDest() == BB &&
 6044   assert(BB && BB->getParent() && "Block not embedded in function!");
 6045   assert(BB->getTerminator() && "Degenerate basic block encountered!");
lib/Transforms/Utils/SimplifyIndVar.cpp
   68       assert(LI && "IV simplification requires LoopInfo");
  132     assert(SE->isSCEVable(IVSrc->getType()) && "Expect SCEVable IV operand");
  163   assert(SE->getSCEV(UseInst) == FoldedExpr && "bad SCEV with folded oper");
  181     assert(IVOperand == ICmp->getOperand(1) && "Can't find IVOperand");
  251     assert(IVOperand == ICmp->getOperand(1) && "Can't find IVOperand");
  281     assert(ICmp->getPredicate() == OriginalPred && "Predicate changed?");
  465         assert(EVI->getIndices()[0] == 0 && "Only two possibilities!");
  546     assert(L->contains(ICI->getParent()) && "LCSSA form broken?");
  591       assert(DoesZExtCollapse && "Unprofitable zext?");
  595       assert(DoesSExtCollapse && "Unprofitable sext?");
  597       assert(Pred == ICmpInst::getSignedPredicate(Pred) && "Must be signed!");
  891       assert(N <= Simplified.size() && "runaway iteration");
lib/Transforms/Utils/SimplifyLibCalls.cpp
 1333     assert(Op->getType()->isArrayTy() && "Unexpected signature for cabs!");
 1337     assert(CI->getNumArgOperands() == 2 && "Unexpected signature for cabs!");
 1389   assert(Exp != 0 && "Incorrect exponent 0 not handled");
 2080     assert(T.getArch() != Triple::x86 && "x86 messy and unsupported for now");
 2815     assert((ignoreCallingConv(Func) ||
lib/Transforms/Utils/SplitModule.cpp
   63   assert((!isa<Constant>(U) || isa<GlobalValue>(U)) && "Bad user");
lib/Transforms/Utils/VNCoercion.cpp
   55   assert(canCoerceMustAliasedValueToLoad(StoredVal, LoadedTy, DL) &&
  100   assert(StoredValSize >= LoadedValSize &&
  277   assert(DepLI->isSimple() && "Cannot widen volatile/atomic load!");
  278   assert(DepLI->getType()->isIntegerTy() && "Can't widen non-integer load");
  414     assert(SrcVal->isSimple() && "Cannot widen volatile/atomic load!");
  415     assert(SrcVal->getType()->isIntegerTy() && "Can't widen non-integer load");
lib/Transforms/Utils/ValueMapper.cpp
  129   ~Mapper() { assert(!hasWorkToDo() && "Expected to be flushed"); }
  344     assert(I->second && "Unexpected null mapping");
  420     assert((Mapped || (Flags & RF_NullMapMissingGlobalValues)) &&
  486   assert(isa<ConstantPointerNull>(C));
  523       assert((!*MappedOp || M.getVM().count(CMD->getValue()) ||
  527       assert((isa<MDString>(Op) || M.getVM().getMappedMD(Op)) &&
  550   assert(N.isDistinct() && "Expected a distinct node");
  551   assert(!M.getVM().getMappedMD(&N) && "Expected an unmapped node");
  584   assert(Where != Info.end() && "Expected a valid reference");
  599   assert(!N.isUniqued() && "Expected distinct or temporary nodes");
  626   assert(G.Info.empty() && "Expected a fresh traversal");
  627   assert(FirstN.isUniqued() && "Expected uniqued node in POT");
  644     assert(WE.N->isUniqued() && "Expected only uniqued nodes");
  645     assert(WE.Op == WE.N->op_end() && "Expected to visit all operands");
  669     assert(OpN.isUniqued() &&
  717       assert(G.Info[Old].ID > D.ID && "Expected a forward reference");
  737   assert(DistinctWorklist.empty() && "MDNodeMapper::map is not recursive");
  738   assert(!(M.Flags & RF_NoModuleLevelChanges) &&
  742   assert(N.isResolved() && "Unexpected unresolved node");
  756   assert(FirstN.isUniqued() && "Expected uniqued node");
  798   assert(isa<MDNode>(MD) && "Expected a metadata node");
  804   assert(MD && "Expected valid metadata");
  805   assert(!isa<LocalAsMetadata>(MD) && "Unexpected local metadata");
  860       assert((Flags & RF_IgnoreMissingLocals) &&
  872         assert((Flags & RF_IgnoreMissingLocals) &&
  997   assert(AlreadyScheduled.insert(&GV).second && "Should not reschedule");
  998   assert(MCID < MCs.size() && "Invalid mapping context");
 1013   assert(AlreadyScheduled.insert(&GV).second && "Should not reschedule");
 1014   assert(MCID < MCs.size() && "Invalid mapping context");
 1029   assert(AlreadyScheduled.insert(&GIS).second && "Should not reschedule");
 1030   assert(MCID < MCs.size() && "Invalid mapping context");
 1041   assert(AlreadyScheduled.insert(&F).second && "Should not reschedule");
 1042   assert(MCID < MCs.size() && "Invalid mapping context");
 1052   assert(!hasWorkToDo() && "Expected to have flushed the worklist");
 1067     assert(!M.hasWorkToDo() && "Expected to be flushed");
lib/Transforms/Vectorize/LoadStoreVectorizer.cpp
  355   assert(OffsetA.getMinSignedBits() <= NewPtrBitWidth &&
  572     assert(PtrOperand && "Instruction must have a pointer operand.");
  610         assert(isa<LoadInst>(I) &&
  613         assert(isa<StoreInst>(I) &&
  707       assert(OBB.dominates(BarrierMemoryInstr, ChainInstr));
  956   assert(StoreTy && "Failed to find store type");
 1107   assert(LoadTy && "Can't determine LoadInst type from chain");
lib/Transforms/Vectorize/LoopVectorizationLegality.cpp
  187   assert(LoopID->getNumOperands() > 0 && "requires at least one operand");
  188   assert(LoopID->getOperand(0) == LoopID && "invalid loop id");
  204       assert(Args.size() == 0 && "too many arguments for MDString");
  299   assert(Lp->getLoopLatch() && "Expected loop with a single latch.");
  304   assert(OuterLp->contains(Lp) && "OuterLp must contain Lp.");
  424   assert(!TheLoop->empty() && "We are not vectorizing an outer loop.");
  743           assert(VecTy && "did not find vectorized version of stored type");
  745           assert(Alignment && "Alignment should be set");
  760           assert(VecTy && "did not find vectorized version of load type");
  762           assert(Alignment && "Alignment should be set");
  931   assert(TheLoop->getNumBlocks() > 1 && "Single block loops are vectorizable");
 1002   assert((UseVPlanNativePath || Lp->empty()) &&
 1113     assert(UseVPlanNativePath && "VPlan-native path is not enabled.");
 1129   assert(TheLoop->empty() && "Inner loop expected.");
lib/Transforms/Vectorize/LoopVectorizationPlanner.h
   97     assert(TheBB && "Attempting to set a null insert point");
lib/Transforms/Vectorize/LoopVectorize.cpp
  308   assert((isa<LoadInst>(I) || isa<StoreInst>(I)) &&
 1034     assert(VF > 1 && "Profitable to scalarize relevant only for VF > 1.");
 1042     assert(Scalars != InstsToScalarize.end() &&
 1058     assert(UniformsPerVF != Uniforms.end() &&
 1074     assert(ScalarsPerVF != Scalars.end() &&
 1101     assert(VF >= 2 && "Expected VF >=2");
 1109     assert(VF >= 2 && "Expected VF >=2");
 1126     assert(VF >= 2 && "Expected VF >=2");
 1143     assert(VF >= 2 && "Expected VF >=2");
 1145     assert(WideningDecisions.find(InstOnVF) != WideningDecisions.end() &&
 1528   assert(!OuterLp->empty() && "This is not an outer loop");
 1676   assert((isa<PHINode>(EntryVal) || isa<TruncInst>(EntryVal)) &&
 1684     assert(Start->getType()->isIntegerTy() &&
 1769   assert((isa<PHINode>(EntryVal) || isa<TruncInst>(EntryVal)) &&
 1795   assert((IV->getType()->isIntegerTy() || IV != OldInduction) &&
 1799   assert(II != Legal->getInductionVars()->end() && "IV is not an induction");
 1802   assert(IV->getType() == ID.getStartValue()->getType() && "Types must match");
 1822   assert(PSE.getSE()->isLoopInvariant(ID.getStep(), OrigLoop) &&
 1859       assert(Step->getType()->isIntegerTy() &&
 1894   assert(Val->getType()->isVectorTy() && "Must be a vector");
 1898   assert((STy->isIntegerTy() || STy->isFloatingPointTy()) &&
 1900   assert(Step->getType() == STy && "Step has wrong type");
 1911     assert(Cv->getType() == Val->getType() && "Invalid consecutive vec");
 1913     assert(Step->getType() == Val->getType() && "Invalid step vec");
 1921   assert((BinOp == Instruction::FAdd || BinOp == Instruction::FSub) &&
 1951   assert(VF > 1 && "VF should be greater than one");
 1955   assert(ScalarIVTy == Step->getType() &&
 1989   assert(V != Induction && "The new induction variable should not be used.");
 1990   assert(!V->getType()->isVectorTy() && "Can't widen a vector");
 1991   assert(!V->getType()->isVoidTy() && "Type does not produce a value");
 2069   assert(Instance.Lane > 0
 2085     assert(VF == 1 && "Value not scalarized has non-vector type");
 2097   assert(V != Induction && "The new induction variable should not be used.");
 2098   assert(!V->getType()->isVectorTy() && "Can't pack a vector");
 2099   assert(!V->getType()->isVoidTy() && "Type does not produce a value");
 2109   assert(Vec->getType()->isVectorTy() && "Invalid type");
 2162   assert(Group && "Fail to get an interleaved access group.");
 2187     assert(!Group->isReverse() && "Reversed masked interleave-group "
 2232     assert(MaskForGaps && "Mask for Gaps is required but it is null");
 2242         assert(useMaskedInterleavedAccesses(*TTI) &&
 2305       assert(Member && "Fail to get a member from an interleaved store group");
 2351   assert((LI || SI) && "Invalid Load/Store instruction");
 2355   assert(Decision != LoopVectorizationCostModel::CM_Unknown &&
 2380   assert((ConsecutiveStride || CreateGatherScatter) &&
 2455   assert(LI && "Must have a load instruction");
 2487   assert(!Instr->getType()->isAggregateType() && "Can't handle vectors");
 2558   assert(L && "Create Trip Count for null loop.");
 2563   assert(BackedgeTakenCount != SE->getCouldNotCompute() &&
 2567   assert(IdxTy && "No type for induction");
 2618     assert(isPowerOf2_32(VF * UF) &&
 2652   assert((VF == SrcVecTy->getNumElements()) && "Vector dimensions do not match");
 2655   assert((DL.getTypeSizeInBits(SrcElemTy) == DL.getTypeSizeInBits(DstElemTy)) &&
 2666   assert((DstElemTy->isPointerTy() != SrcElemTy->isPointerTy()) &&
 2668   assert((DstElemTy->isFloatingPointTy() != SrcElemTy->isFloatingPointTy()) &&
 2725   assert(!BB->getParent()->hasOptSize() &&
 2761     assert(Cost->Hints->getForce() == LoopVectorizeHints::FK_Enabled &&
 2802   assert(Index->getType() == Step->getType() &&
 2812     assert(X->getType() == Y->getType() && "Types don't match!");
 2823     assert(X->getType() == Y->getType() && "Types don't match!");
 2835     assert(Index->getType() == StartValue->getType() &&
 2844     assert(isa<SCEVConstant>(Step) &&
 2852     assert(Step->getType()->isFloatingPointTy() && "Expected FP Step value");
 2854     assert(InductionBinOp &&
 2920   assert(VectorPH && "Invalid loop structure");
 2921   assert(ExitBlock && "Must have an exit block");
 3042   assert(isa<BranchInst>(OrigLoop->getLoopLatch()->getTerminator()) &&
 3114   assert(OrigLoop->getExitBlock() && "Expected a single exit block");
 3124       assert(isa<PHINode>(UI) && "Expected LCSSA form");
 3137       assert(isa<PHINode>(UI) && "Expected LCSSA form");
 3183     assert(canHandle(I) && "Unknown instruction!");
 3267   assert(ID && "Expected intrinsic call!");
 3422     assert(EnableVPlanNativePath &&
 3645   assert(Legal->isReductionVariable(Phi) &&
 3732           assert(!Sel && "Reduction exit feeding two selects");
 3735           assert(isa<PHINode>(U) && "Reduction exit must feed Phi's or select");
 3737       assert(Sel && "Reduction exit feeds no select");
 3824     assert(LCSSAPhi.getNumIncomingValues() < 3 && "Invalid LCSSA PHI");
 3836   assert(IncomingEdgeBlockIdx >= 0 && "Invalid block index");
 3938     assert(ScalarBBPredecessors.size() == VectorBBPredecessors.size() &&
 3981   assert(PN->getParent() == OrigLoop->getHeader() &&
 4004   assert(Legal->getInductionVars()->count(P) && "Not an induction variable");
 4019     assert(P->getType()->isPointerTy() && "Unexpected type.");
 4052   assert((I.getOpcode() == Instruction::UDiv ||
 4127         assert((VF == 1 || NewGEP->getType()->isVectorTy()) &&
 4282     assert((UseVectorIntrinsic || !NeedToScalarize) &&
 4306         assert(!VFnName.empty() && "Vector function name is empty.");
 4316       assert(VectorF && "Can't create vector function.");
 4348   assert(DT->properlyDominates(LoopBypassBlocks.front(), LoopExitBlock) &&
 4356   assert(DT->verify(DominatorTree::VerificationLevel::Fast));
 4363   assert(VF >= 2 && Scalars.find(VF) == Scalars.end() &&
 4379     assert(WideningDecision != CM_Unknown &&
 4384     assert(Ptr == getLoadStorePointerOperand(MemAccess) &&
 4561       assert(WideningDecision != CM_Unknown &&
 4581   assert(isAccessInterleaved(I) && "Expecting interleaved access.");
 4582   assert(getWideningDecision(I, VF) == CM_Unknown &&
 4585   assert(Group && "Must have a group.");
 4607   assert(useMaskedInterleavedAccesses(TTI) &&
 4621   assert((LI || SI) && "Invalid memory instruction");
 4650   assert(VF >= 2 && Uniforms.find(VF) == Uniforms.end() &&
 4691     assert(WideningDecision != CM_Unknown &&
 4963   assert(MaxVectorSize <= 256 && "Did not expect to pack so many elements"
 5224   assert(LoopCost && "Non-zero loop cost expected");
 5504   assert(isPredicatedInst(I) && "Expecting a scalar emulated instruction");
 5546   assert(!isUniformAfterVectorization(PredInst, VF) &&
 5628         assert(VectorType::isValidElementType(J->getType()) &&
 5730   assert(VF > 1 && "Scalarization cost of instruction implies vectorization.");
 5778   assert((ConsecutiveStride == 1 || ConsecutiveStride == -1) &&
 5836   assert(Group && "Fail to get an interleaved access group.");
 5859     assert(!Legal->isMaskRequired(I) &&
 5975         assert((ConsecutiveStride == 1 || ConsecutiveStride == -1) &&
 5988         assert(Group && "Fail to get an interleaved access group.");
 6250       assert(Decision != CM_Unknown &&
 6412     assert(EnableVPlanNativePath && "VPlan-native path is not enabled.");
 6413     assert(isPowerOf2_32(VF) && "VF needs to be a power of two");
 6432   assert(OrigLoop->empty() && "Inner loop expected.");
 6449     assert(isPowerOf2_32(UserVF) && "VF needs to be a power of two");
 6459   assert(MaxVF != 0 && "MaxVF is zero.");
 6489   assert(VPlans.size() == 1 && "Best VF has not a single VPlan.");
 6514   assert(VPlans.size() == 1 && "Not a single VPlan to execute.");
 6567   assert(!Ty->isVectorTy() && "Val must be a scalar");
 6616   assert(Range.End > Range.Start && "Trying to test an empty VF range.");
 6643   assert(is_contained(predecessors(Dst), Src) && "Invalid edge");
 6655   assert(BI && "Unexpected terminator found");
 6661   assert(EdgeMask && "No Edge Mask found for condition");
 6673   assert(OrigLoop->contains(BB) && "Block is not a part of a loop");
 6734   assert(I == IG->getInsertPos() &&
 6758     assert(Decision != LoopVectorizationCostModel::CM_Unknown &&
 6760     assert(Decision != LoopVectorizationCostModel::CM_Interleave &&
 6824     assert((EdgeMask || NumIncoming == 1) &&
 6915       assert(CM.getWideningDecision(I, VF) ==
 6966   assert(VPBB->getSuccessors().empty() &&
 6988   assert(Instr->getParent() && "Predicated instruction not in any basic block");
 7046   assert(OrigLoop->empty() && "Inner loop expected.");
 7193   assert(PreEntry->empty() && "Expecting empty pre-entry block.");
 7231   assert(!OrigLoop->empty());
 7232   assert(EnableVPlanNativePath && "VPlan-native path is not enabled.");
 7286   assert(!State.Instance && "Int or FP induction being replicated.");
 7305   assert((User || NumIncoming == 1) &&
 7334   assert(!State.Instance && "Interleave group being replicated.");
 7372   assert(State.Instance && "Branch on Mask works only on single instance.");
 7391   assert(isa<UnreachableInst>(CurrentTerminator) &&
 7399   assert(State.Instance && "Predicated instruction PHI works per instance.");
 7404   assert(PredicatingBB && "Predicated block has no single predecessor.");
 7466   assert(EnableVPlanNativePath && "VPlan-native path is disabled.");
 7507   assert((EnableVPlanNativePath || L->empty()) &&
 7572   assert(L->empty() && "Inner loop expected.");
 7748     assert(IC > 1 && "interleave count should not be 1 or 0");
lib/Transforms/Vectorize/SLPVectorizer.cpp
  422   assert((Opcode == Instruction::ExtractElement ||
  887       assert(!VL.empty() && "Bad VL");
  888       assert((empty() || VL.size() == getNumLanes()) &&
  890       assert(isa<Instruction>(VL[0]) && "Expected instruction");
  897           assert(isa<Instruction>(VL[Lane]) && "Expected instruction");
  972       assert(OpsVec[OpIdx].size() == getNumLanes() &&
 1050             assert(LastLane >= 0 && LastLane < (int)NumLanes &&
 1252       assert(Operands[OpIdx].size() == 0 && "Already resized?");
 1260       assert(Operands.empty() && "Already initialized?");
 1269           assert(I->getNumOperands() == NumOperands &&
 1278       assert(OpIdx < Operands.size() && "Off bounds");
 1287       assert(OpIdx < Operands.size() && "Off bounds");
 1288       assert(!Operands[OpIdx].empty() && "No operand available");
 1402         assert(!getTreeEntry(VL[i]) && "Scalar already in tree!");
 1413       assert((!Bundle.getValue() || Lane == VL.size()) &&
 1574       assert(isSchedulingEntity() &&
 1752               assert(!DepBundle->IsScheduled &&
 1766           assert(Lane >= 0 && "Lane not set");
 1784             assert(!DepBundle->IsScheduled &&
 2085     assert(Pair.getFirst()->use_empty() &&
 2155             assert(!UseEntry->NeedToGather && "Bad state");
 2174   assert((allConstant(VL) || allSameType(VL)) && "Invalid types!");
 2303     assert((!BS.getScheduleData(VL0) ||
 2545         assert(P0 == SwapP0 && "Commutative Predicate mismatch");
 2836   assert(E0->getOpcode() == Instruction::ExtractElement ||
 2838   assert(E0->getOpcode() == getSameOpcode(VL).getOpcode() && "Invalid opcode");
 2960   assert(E->getOpcode() && allSameType(VL) && allSameBlock(VL) && "Invalid VL");
 3225       assert(E->isAltShuffle() &&
 3246         assert(E->isOpcodeOrAlt(I) && "Unexpected main/alternate opcode");
 3344   assert(VectorizableTree.empty()
 3559   assert(llvm::all_of(make_range(E->Scalars.begin(), E->Scalars.end()),
 3608   assert(LastInst && "Failed to find last instruction in bundle");
 3636         assert(FoundLane >= 0 && "Could not find the correct lane");
 3787       assert(NewPhi->getNumIncomingValues() == PH->getNumIncomingValues() &&
 4159       assert(E->isAltShuffle() &&
 4202         assert(E->isOpcodeOrAlt(OpInst) && "Unexpected main/alternate opcode");
 4286     assert(E && "Invalid scalar");
 4287     assert(!E->NeedToGather && "Extracting from a gather list");
 4290     assert(Vec && "Can't find vectorizable value");
 4297       assert(ExternallyUsedValues.count(Scalar) &&
 4363     assert(Entry->VectorizedValue && "Can't find vectorizable value");
 4376           assert((getTreeEntry(U) || is_contained(UserIgnoreList, U)) &&
 4428       assert(DT->isReachableFromEntry(N));
 4444     assert((I == CSEWorkList.begin() || !DT->dominates(*I, *std::prev(I))) &&
 4467         assert(!is_contained(Visited, In));
 4500     assert(BundleMember &&
 4510     assert(BundleMember->isSchedulingEntity() &&
 4541   assert(Bundle && "Failed to find schedule bundle");
 4575   assert(!Bundle->IsScheduled &&
 4577   assert(Bundle->isSchedulingEntity() && Bundle->isPartOfBundle() &&
 4583     assert(BundleMember->FirstInBundle == Bundle && "corrupt bundle links");
 4609   assert(I && "bundle member must be an instruction");
 4610   assert(!isa<PHINode>(I) && "phi nodes don't need to be scheduled");
 4615     assert(isInSchedulingRegion(ISD) &&
 4632     assert(ScheduleEnd && "tried to vectorize a terminator?");
 4668         assert(ScheduleEnd && "tried to vectorize a terminator?");
 4675     assert((UpIter != UpperEnd || DownIter != LowerEnd) &&
 4693     assert(!isInSchedulingRegion(SD) &&
 4720   assert(SD->isSchedulingEntity());
 4731       assert(isInSchedulingRegion(BundleMember));
 4782             assert(isInSchedulingRegion(DepDest));
 4843   assert(ScheduleStart &&
 4847       assert(isInSchedulingRegion(SD) &&
 4881       assert(SD->isPartOfBundle() ==
 4917   assert(NumToSchedule == 0 && "could not schedule all instructions");
 5128         assert(R->hasOneUse() && "Root should have only one use!");
 5589         assert(Ops.size() == 2);
 5691   assert((IsPairwise || !IsLeft) && "Don't support a <0,1,undef,...> mask");
 5789       assert(isVectorizable() &&
 5805         assert(Opcode == Instruction::ICmp && "Expected integer types.");
 5809         assert(Opcode == Instruction::ICmp && "Expected integer types.");
 5833       assert(Kind != RK_None && "One of the reduction operations is expected.");
 5840       assert(!!*this && "The opcode is not set.");
 5856       assert(Kind != RK_None && !!*this && LHS && RHS &&
 5874       assert(Kind != RK_None && !!*this && LHS && RHS &&
 5898       assert(Kind != RK_None && !!*this && LHS && RHS &&
 5918       assert(Kind != RK_None && !!*this && LHS && RHS &&
 5936       assert(Kind != RK_None && !!*this && LHS && RHS &&
 5956       assert(Kind != RK_None && *this && LHS && RHS &&
 5967         assert(Opcode == Instruction::ICmp &&
 5984       assert(((Kind != OD.Kind) || ((!LHS == !OD.LHS) && (!RHS == !OD.RHS))) &&
 5999       assert(isVectorizable() && "Expected vectorizable operation.");
 6026       assert(isVectorizable() &&
 6050       assert(isVectorizable() &&
 6245     assert((!Phi || is_contained(Phi->operands(), B)) &&
 6400       assert(Pair.first && "DebugLoc must be set.");
 6580     assert(VectorizedValue && "Need to have a vectorized tree node");
 6581     assert(isPowerOf2_32(ReduxWidth) &&
 6587       assert(Builder.getFastMathFlags().isFast() && "Expected 'fast' FMF");
 7091         assert(GEP->getNumIndices() == 1 || !isa<Constant>(GEPIdx));
lib/Transforms/Vectorize/VPlan.cpp
   91   assert(Parent->getExit() == this &&
   99   assert(Parent->getEntry() == this &&
  135       assert(EnableVPlanNativePath &&
  141     assert(PredBB && "Predecessor basic-block not found building successor.");
  145       assert(PredVPSuccessors.size() == 1 &&
  150       assert(PredVPSuccessors.size() == 2 &&
  153       assert(!PredBBTerminator->getSuccessor(idx) &&
  205     assert(IRCBV && "Unexpected null underlying value for condition bit");
  219     assert(isa<UnreachableInst>(CurrentTerminator) &&
  256   assert(!State->Instance && "Replicating a Region with non-null instance.");
  332   assert(!State.Instance && "VPInstruction executing an Instance");
  389   assert(VectorHeaderBB && "Loop preheader does not have a single successor.");
  416     assert(EnableVPlanNativePath &&
  419     assert(BB && "Unexpected null basic block for VPBB");
  434   assert((EnableVPlanNativePath ||
  437   assert((!EnableVPlanNativePath || isa<BranchInst>(LastBB->getTerminator())) &&
  445   assert(Merged && "Could not merge last basic block with latch.");
  456   assert(LoopHeaderBB && "Loop preheader does not have a single successor.");
  465     assert(Succs.size() <= 2 &&
  469       assert(PostDomSucc->getSinglePredecessor() &&
  479     assert(InterimSucc->getSingleSuccessor() == PostDomSucc &&
  481     assert(InterimSucc->getSinglePredecessor() &&
  483     assert(PostDomSucc->hasNPredecessors(2) &&
  618   assert(Region->getEntry() && "Region contains no inner blocks.");
  735       assert(isa<VPInstruction>(&VPI) && "Can only handle VPInstructions");
lib/Transforms/Vectorize/VPlan.h
  137     assert(Part < UF && "Queried Vector Part is too large.");
  141     assert(Entry.size() == UF && "VectorParts has wrong dimensions.");
  152     assert(Instance.Part < UF && "Queried Scalar Part is too large.");
  153     assert(Instance.Lane < VF && "Queried Scalar Lane is too large.");
  157     assert(Entry.size() == UF && "ScalarParts has wrong dimensions.");
  158     assert(Entry[Instance.Part].size() == VF &&
  166     assert(hasVectorValue(Key, Part) && "Getting non-existent value.");
  173     assert(hasScalarValue(Key, Instance) && "Getting non-existent value.");
  180     assert(!hasVectorValue(Key, Part) && "Vector value already set for part");
  191     assert(!hasScalarValue(Key, Instance) && "Scalar value already set");
  208     assert(hasVectorValue(Key, Part) && "Vector value not set for part");
  218     assert(hasScalarValue(Key, Instance) &&
  360     assert(Successor && "Cannot add nullptr successor!");
  366     assert(Predecessor && "Cannot add nullptr predecessor!");
  373     assert(Pos && "Predecessor does not exist");
  380     assert(Pos && "Successor does not exist");
  506     assert(Successors.empty() && "Setting one successor when others exist.");
  516     assert(Successors.empty() && "Setting two successors when others exist.");
  517     assert(Condition && "Setting two successors without condition!");
  527     assert(Predecessors.empty() && "Block predecessors already set.");
  801     assert((Phi->getNumIncomingValues() == 1 ||
 1043     assert(Recipe && "No recipe to append.");
 1044     assert(!Recipe->Parent && "Recipe already in VPlan");
 1088     assert(Entry->getPredecessors().empty() && "Entry block has predecessors.");
 1089     assert(Exit->getSuccessors().empty() && "Exit block has successors.");
 1113     assert(EntryBlock->getPredecessors().empty() &&
 1131     assert(ExitBlock->getSuccessors().empty() &&
 1237     assert(V && "Trying to add a null Value to VPlan");
 1238     assert(!Value2VPValue.count(V) && "Value already exists in VPlan");
 1243     assert(V && "Trying to get the VPValue of a null Value");
 1244     assert(Value2VPValue.count(V) && "Value does not exist in VPlan");
 1466     assert(NewBlock->getSuccessors().empty() &&
 1484     assert(IfTrue->getSuccessors().empty() &&
 1486     assert(IfFalse->getSuccessors().empty() &&
 1500     assert((From->getParent() == To->getParent()) &&
 1502     assert(From->getNumSuccessors() < 2 &&
 1511     assert(To && "Successor to disconnect is null.");
 1519     assert(FromBlock->getParent() == ToBlock->getParent() &&
lib/Transforms/Vectorize/VPlanHCFGBuilder.cpp
   95     assert(IRDef2VPValue.count(Phi) && "Missing VPInstruction for PHINode.");
   97     assert(isa<VPInstruction>(VPVal) && "Expected VPInstruction for phi node.");
   99     assert(VPPhi->getNumOperands() == 0 &&
  138   assert(InstParent && "Expected instruction parent.");
  142   assert(PH && "Expected loop pre-header.");
  150   assert(Exit && "Expected loop with single exit.");
  179   assert(isExternalDef(IRVal) && "Expected external definition as operand.");
  200     assert(!IRDef2VPValue.count(Inst) &&
  253   assert((PreheaderBB->getTerminator()->getNumSuccessors() == 1) &&
  275     assert(TI && "Terminator expected.");
  280       assert(SuccVPBB && "VPBB Successor not found.");
  284       assert(SuccVPBB0 && "Successor 0 not found.");
  286       assert(SuccVPBB1 && "Successor 1 not found.");
  289       assert(isa<BranchInst>(TI) && "Unsupported terminator!");
  294       assert(IRDef2VPValue.count(BrCond) &&
  311   assert(LoopExitBB && "Loops with multiple exits are not supported.");
lib/Transforms/Vectorize/VPlanPredicator.cpp
  105   assert(Worklist.size() == 1 && "Expected 1 item in worklist");
  122       assert(Count < 2 && "Switch not supported currently");
  169       assert(isa<VPBasicBlock>(PredBlock) && "Only BBs have multiple exits");
  196     assert(!isa<VPRegionBlock>(Block) && "Nested region not expected");
  213     assert(!isa<VPRegionBlock>(CurrBlock) && "Nested region not expected");
lib/Transforms/Vectorize/VPlanSLP.cpp
   64       assert(!T->isVectorTy() && "Only scalar types supported for now");
   71   assert(Res.second &&
  244   assert((Mode == OpMode::Load || Mode == OpMode::Opcode) &&
  361   assert(!Values.empty() && "Need some operands!");
  374         assert(*UI == FirstUser && "Currently we only support SLP trees.");
  391   assert(getOpcode(Values) && "Opcodes for all values must match");
  462   assert(CombinedOperands.size() > 0 && "Need more some operands");
lib/Transforms/Vectorize/VPlanValue.h
   68     assert(!UnderlyingVal && "Underlying Value is already set.");
  163     assert(N < Operands.size() && "Operand index out of bounds");
lib/Transforms/Vectorize/VPlanVerifier.cpp
   48     assert(VPB->getParent() == Region && "VPBlockBase has wrong parent");
   52       assert(VPB->getCondBit() && "Missing condition bit!");
   54       assert(!VPB->getCondBit() && "Unexpected condition bit!");
   60     assert(!hasDuplicates(Successors) &&
   66       assert(std::find(SuccPreds.begin(), SuccPreds.end(), VPB) !=
   77     assert(!hasDuplicates(Predecessors) &&
   82       assert(Pred->getParent() == VPB->getParent() &&
   87       assert(std::find(PredSuccs.begin(), PredSuccs.end(), VPB) !=
  102   assert(!Entry->getNumPredecessors() && "Region entry has predecessors.");
  103   assert(!Exit->getNumSuccessors() && "Region exit has successors.");
  130   assert(!TopRegion->getParent() && "VPlan Top Region should have no parent.");
lib/XRay/BlockVerifier.cpp
  124   assert(Mapping.From == CurrentRecord &&
lib/XRay/FDRRecordProducer.cpp
  131     assert(R != nullptr);
  132     assert(isa<BufferExtents>(R.get()));
  193   assert(R != nullptr);
lib/XRay/FDRTraceWriter.cpp
   52   assert(Bytes <= 15 && "Must only ever write at most 16 byte metadata!");
lib/XRay/Profile.cpp
  185   assert(Node->Func == P.front());
lib/XRay/RecordInitializer.cpp
   54   assert(OffsetPtr - BeginOffset <= MetadataRecord::kMetadataBodySize);
  143   assert(OffsetPtr > BeginOffset &&
  163   assert(OffsetPtr >= PreReadOffset);
  207   assert(OffsetPtr > BeginOffset &&
  227   assert(OffsetPtr >= PreReadOffset);
  279   assert(OffsetPtr > BeginOffset &&
  299   assert(OffsetPtr >= PreReadOffset);
  426   assert(FunctionRecord::kFunctionRecordSize == (OffsetPtr - BeginOffset));
projects/compiler-rt/lib/builtins/cpu_model.c
  688   assert(__cpu_model.__cpu_vendor < VENDOR_MAX);
  689   assert(__cpu_model.__cpu_type < CPU_TYPE_MAX);
  690   assert(__cpu_model.__cpu_subtype < CPU_SUBTYPE_MAX);
projects/compiler-rt/lib/cfi/cfi.cpp
  108     assert(!is_invalid() && !is_unchecked());
  161   assert((cfi_check & (kShadowAlign - 1)) == 0);
  265       assert(p->st_info == ELF32_ST_INFO(STB_GLOBAL, STT_FUNC) ||
projects/compiler-rt/lib/dfsan/dfsan_custom.cpp
  916     assert(new_fmt);
projects/compiler-rt/lib/gwp_asan/guarded_pool_allocator.cpp
  219   assert(pointerIsMine(Ptr) && "Pointer is not mine!");
  252   assert(pointerIsMine(Ptr));
  255   assert(Meta->Addr == reinterpret_cast<uintptr_t>(Ptr));
  266   assert(pointerIsMine(reinterpret_cast<void *>(Ptr)));
  276   assert(pointerIsMine(reinterpret_cast<void *>(Ptr)));
  281   assert(pointerIsMine(reinterpret_cast<void *>(Ptr)));
  303   assert(FreeSlotsLength < MaxSimultaneousAllocations);
  308   assert(Size > 0);
  447   assert(Meta != nullptr && "Metadata is non-null for printAllocDeallocTraces");
projects/compiler-rt/lib/gwp_asan/platform_specific/mutex_posix.cpp
   17   assert(Status == 0);
   26   assert(Status == 0);
projects/openmp/libomptarget/src/device.cpp
  285       assert(HT.RefCount == 0 && "did not expect a negative ref count");
projects/openmp/libomptarget/src/omptarget.cpp
   81     assert(TransTable->TargetsImages.size() > (size_t)device_id &&
  125         assert(CurrDeviceEntry->size == CurrHostEntry->size &&
  305           assert(parent_rc > 0 && "parent struct not found");
  406             assert(parent_rc > 0 && "parent struct not found");
  630   assert(TM->Table->TargetsTable.size() > (size_t)device_id &&
  634   assert(TargetTable && "Global data has not been mapped\n");
  656         assert((arg_types[i] & OMP_TGT_MAPTYPE_MEMBER_OF) &&
  660         assert(tgtIdx != -1 && "Base address must be translated already.");
  758   assert(tgt_args.size() == tgt_offsets.size() &&
projects/openmp/libomptarget/src/rtl.cpp
  139   assert(TT.TargetsTable.size() == TT.TargetsImages.size() &&
  199   assert(flags != OMP_REQ_UNDEFINED &&
  276         assert((size_t) R.Idx == start &&
  335       assert(R->isUsed && "Expecting used RTLs.");
tools/bugpoint/BugDriver.cpp
  133   assert(!Program && "Cannot call addSources multiple times!");
  134   assert(!Filenames.empty() && "Must specify at least on input filename!");
tools/bugpoint/CrashDebugger.cpp
  155     assert(CMGV && "Global Variable not in module?!");
  216     assert(UsedVar->use_empty());
  248     assert(CMF && "Function not in module?!");
  249     assert(CMF->getFunctionType() == Funcs[i]->getFunctionType() && "wrong ty");
  250     assert(CMF->getName() == Funcs[i]->getName() && "wrong name");
  765     assert(!Insts[i]->isTerminator());
 1131       assert(Fn && "Could not find funcion?");
tools/bugpoint/ExecutionDriver.cpp
  301   assert(AI && "Interpreter should have been created already!");
  389   assert(Interpreter && "Interpreter should have been created already!");
tools/bugpoint/ExtractFunction.cpp
  170     assert(M->size() < NewM->size() && "Loop extract removed functions?");
  223   assert(F->isDeclaration() && "This didn't make the function external!");
  229   assert(!TorList.empty() && "Don't create empty tor list!");
  294   assert(GV && "Not a clone of M1?");
  295   assert(GV->use_empty() && "llvm.ctors shouldn't have uses!");
tools/bugpoint/ListReducer.h
  102         assert(!Result.takeError() && "Shuffling caused internal error?");
tools/bugpoint/Miscompilation.cpp
  403         assert(NewF && "Function not found??");
  434       assert(NewF && "Function not found??");
  599     assert(NewF && "Function not found??");
tools/clang/include/clang/AST/APValue.h
  381     assert(isInt() && "Invalid accessor");
  395     assert(isFloat() && "Invalid accessor");
  403     assert(isFixedPoint() && "Invalid accessor");
  411     assert(isComplexInt() && "Invalid accessor");
  419     assert(isComplexInt() && "Invalid accessor");
  427     assert(isComplexFloat() && "Invalid accessor");
  435     assert(isComplexFloat() && "Invalid accessor");
  455     assert(isVector() && "Invalid accessor");
  456     assert(I < getVectorLength() && "Index out of range");
  463     assert(isVector() && "Invalid accessor");
  468     assert(isArray() && "Invalid accessor");
  469     assert(I < getArrayInitializedElts() && "Index out of range");
  479     assert(isArray() && "Invalid accessor");
  480     assert(hasArrayFiller() && "No array filler");
  487     assert(isArray() && "Invalid accessor");
  491     assert(isArray() && "Invalid accessor");
  496     assert(isStruct() && "Invalid accessor");
  500     assert(isStruct() && "Invalid accessor");
  504     assert(isStruct() && "Invalid accessor");
  508     assert(isStruct() && "Invalid accessor");
  519     assert(isUnion() && "Invalid accessor");
  523     assert(isUnion() && "Invalid accessor");
  535     assert(isAddrLabelDiff() && "Invalid accessor");
  539     assert(isAddrLabelDiff() && "Invalid accessor");
  544     assert(isInt() && "Invalid accessor");
  548     assert(isFloat() && "Invalid accessor");
  552     assert(isFixedPoint() && "Invalid accessor");
  556     assert(isVector() && "Invalid accessor");
  563     assert(R.getBitWidth() == I.getBitWidth() &&
  565     assert(isComplexInt() && "Invalid accessor");
  570     assert(&R.getSemantics() == &I.getSemantics() &&
  572     assert(isComplexFloat() && "Invalid accessor");
  582     assert(isUnion() && "Invalid accessor");
  601     assert(isAbsent() && "Bad state change");
  606     assert(isAbsent() && "Bad state change");
  611     assert(isAbsent() && "Bad state change");
  616     assert(isAbsent() && "Bad state change");
  621     assert(isAbsent() && "Bad state change");
  626     assert(isAbsent() && "Bad state change");
  633     assert(isAbsent() && "Bad state change");
  638     assert(isAbsent() && "Bad state change");
  645     assert(isAbsent() && "Bad state change");
tools/clang/include/clang/AST/ASTContext.h
  625       assert(N < size() && "Out of bounds!");
  798     assert(LangOpts.RetainCommentsFromSystemHeaders ||
 1405     assert(Decl && "Passed null for Decl param");
 1409       assert(PrevDecl->TypeForDecl && "previous decl has no TypeForDecl");
 1701     assert(Target && "Expected target to be initialized");
 1710     assert(Target && "Expected target to be initialized");
 1967     assert(type.getObjCLifetime() == Qualifiers::OCL_None);
 1968     assert(lifetime != Qualifiers::OCL_None);
tools/clang/include/clang/AST/ASTImporter.h
  195         assert(Nodes.size() >= 2);
tools/clang/include/clang/AST/ASTNodeTraverser.h
  439         assert(isa<CXXRecordDecl>(RedeclWithBadType) &&
tools/clang/include/clang/AST/ASTTypeTraits.h
  319     assert(getMemoizationData() && Other.getMemoizationData());
  339     assert(getMemoizationData() && Other.getMemoizationData());
  374       assert(Val.getMemoizationData());
  400       assert(ASTNodeKind::getFromNodeKind<T>().isBaseOf(NodeKind));
  420       assert(ASTNodeKind::getFromNodeKind<T>().isSame(NodeKind));
  440       assert(ASTNodeKind::getFromNodeKind<T>().isSame(NodeKind));
tools/clang/include/clang/AST/ASTUnresolvedSet.h
  108     assert(Impl.empty() || Impl.Decls.isLazy());
tools/clang/include/clang/AST/ASTVector.h
  112     assert(Begin + idx < End);
  116     assert(Begin + idx < End);
tools/clang/include/clang/AST/Attr.h
  219     assert(isValid() && I.isValid() &&
  225     assert(HasThis == I.HasThis &&
  242     assert(Idx >= 1 && "Idx must be one-origin");
  262     assert((!P.IsValid || P.Idx >= 1) && "valid Idx must be one-origin");
  276     assert(isValid() && "ParamIdx must be valid");
  287     assert(isValid() && "ParamIdx must be valid");
  288     assert(Idx >= 1 + HasThis &&
  298     assert(isValid() && "ParamIdx must be valid");
  299     assert(Idx >= 1 && "stored index must be base-1");
tools/clang/include/clang/AST/AttrIterator.h
   87     assert((Left.Current == nullptr) == (Right.Current == nullptr));
tools/clang/include/clang/AST/CanonicalType.h
  634   assert((!Result || Result.Stored.getAsOpaquePtr() == (void*)-1 ||
  641   assert((Other.isNull() || Other.isCanonical()) && "Type is not canonical!");
  642   assert((Other.isNull() || isa<T>(Other.getTypePtr())) &&
  670   assert(!Stored.isNull() && isa<U>(Stored.getTypePtr()));
tools/clang/include/clang/AST/CharUnits.h
  195         assert(Quantity != 0 && "offsetting from unknown alignment?");
tools/clang/include/clang/AST/Comment.h
  782     assert(isParamIndexValid());
  786     assert(isParamIndexValid());
  787     assert(!isVarArgParam());
  793     assert(isParamIndexValid());
  794     assert(!isVarArgParam());
  847     assert(isPositionValid());
  852     assert(isPositionValid());
  858     assert(isPositionValid());
tools/clang/include/clang/AST/CommentLexer.h
   99     assert(is(tok::text));
  104     assert(is(tok::text));
  110     assert(is(tok::unknown_command));
  115     assert(is(tok::unknown_command));
  121     assert(is(tok::backslash_command) || is(tok::at_command));
  126     assert(is(tok::backslash_command) || is(tok::at_command));
  131     assert(is(tok::verbatim_block_begin) || is(tok::verbatim_block_end));
  136     assert(is(tok::verbatim_block_begin) || is(tok::verbatim_block_end));
  141     assert(is(tok::verbatim_block_line));
  146     assert(is(tok::verbatim_block_line));
  152     assert(is(tok::verbatim_line_name));
  157     assert(is(tok::verbatim_line_name));
  162     assert(is(tok::verbatim_line_text));
  167     assert(is(tok::verbatim_line_text));
  173     assert(is(tok::html_start_tag));
  178     assert(is(tok::html_start_tag));
  184     assert(is(tok::html_ident));
  189     assert(is(tok::html_ident));
  195     assert(is(tok::html_quoted_string));
  200     assert(is(tok::html_quoted_string));
  206     assert(is(tok::html_end_tag));
  211     assert(is(tok::html_end_tag));
  308     assert(Loc >= BufferStart && Loc <= BufferEnd &&
tools/clang/include/clang/AST/ComparisonCategories.h
  121     assert(Info &&
  123     assert(Info->hasValidIntValue() &&
  169     assert(isEquality());
  173     assert(isOrdered());
  177     assert(isOrdered());
  181     assert(isPartial());
  200     assert(Result != nullptr &&
tools/clang/include/clang/AST/CurrentSourceLocExprScope.h
   54     assert(DefaultExpr && "the new scope should not be empty");
tools/clang/include/clang/AST/Decl.h
  277     assert(Name.isIdentifier() && "Name is not a simple identifier");
  773     assert(index < getNumTemplateParameterLists());
 1042     assert(VarDeclBits.TSCSpec == TSC && "truncation");
 1336     assert(isThisDeclarationADefinition() && "Not a definition!");
 1337     assert(!isa<ParmVarDecl>(this) && "Cannot demote ParmVarDecls!");
 1347     assert(!isa<ParmVarDecl>(this));
 1365     assert(!isa<ParmVarDecl>(this));
 1375     assert(!isa<ParmVarDecl>(this));
 1408     assert(!isa<ParmVarDecl>(this));
 1413     assert(!isa<ParmVarDecl>(this));
 1422     assert(!isa<ParmVarDecl>(this));
 1431     assert(!isa<ParmVarDecl>(this));
 1447     assert(!isa<ParmVarDecl>(this));
 1611     assert(ParmVarDeclBits.HasInheritedDefaultArg == false);
 1612     assert(ParmVarDeclBits.DefaultArgKind == DAK_None);
 1613     assert(ParmVarDeclBits.IsKNRPromoted == false);
 1614     assert(ParmVarDeclBits.IsObjCMethodParam == false);
 1635     assert(!ParmVarDeclBits.IsObjCMethodParam);
 1638     assert(ParmVarDeclBits.ScopeDepthOrObjCQuals == scopeDepth
 1663     assert(ParmVarDeclBits.IsObjCMethodParam);
 1757     assert(ParmVarDeclBits.ParameterIndex == parameterIndex && "truncation!");
 2350     assert(i < getNumParams() && "Illegal param #");
 2354     assert(i < getNumParams() && "Illegal param #");
 2753     assert(!hasCapturedVLAType() && !BitField &&
 2755     assert(Width && "no bit width specified");
 2767     assert(isBitField() && "no bitfield width to remove");
 2808     assert(hasInClassInitializer() && !getInClassInitializer());
 2817     assert(hasInClassInitializer() && "no initializer to remove");
 2932     assert(chain().size() >= 2);
 2937     assert(chain().size() >= 2);
 3379     assert(i < getNumTemplateParameterLists());
 3451     assert(EnumDeclBits.NumPositiveBits == Num && "can't store this bitcount");
 4065     assert(i < getNumParams() && "Illegal param #");
 4069     assert(i < getNumParams() && "Illegal param #");
 4195     assert(i < NumParams);
 4199     assert(i < NumParams);
 4213     assert(ContextParam < NumParams);
 4217     assert(i < NumParams);
 4397   assert(RedeclLink.isFirst() &&
 4405     assert(First->RedeclLink.isFirst() && "Expected first");
 4422   assert(!isa<NamedDecl>(static_cast<decl_type*>(this)) ||
tools/clang/include/clang/AST/DeclBase.h
  470     assert(AccessDeclContextSanity());
  474     assert(AccessDeclContextSanity());
  631     assert(isFromASTFile() && "Only works on a deserialized declaration");
  742     assert(hasLocalOwningModuleStorage() &&
  747     assert(!isFromASTFile() && hasOwningModule() &&
  792     assert(!(getModuleOwnershipKind() == ModuleOwnershipKind::Unowned &&
  921       assert(Current && "Advancing while iterator has reached end");
  924       assert(Next && "Should return next redeclaration or itself, never null!");
 1049     assert((IdentifierNamespace & ~(IDNS_OrdinaryFriend | IDNS_Tag)) == 0 &&
 1073     assert((OldNS & (IDNS_Tag | IDNS_Ordinary |
 1077     assert(!(OldNS & ~(IDNS_Tag | IDNS_Ordinary | IDNS_Type |
 1121     assert(getKind() == Function || getKind() == FunctionTemplate);
 1122     assert((IdentifierNamespace & IDNS_Ordinary) &&
 2329     assert(this == getPrimaryContext() &&
tools/clang/include/clang/AST/DeclCXX.h
  435     assert(DD && "queried property of class with no definition");
  443     assert(DD && DD->IsLambda && "queried lambda property of non-lambda class");
  525       assert(Recent->getPreviousDecl());
  679     assert((!needsOverloadResolutionForCopyConstructor() ||
  688     assert((!needsOverloadResolutionForMoveConstructor() ||
  696     assert((!needsOverloadResolutionForDestructor() ||
  828     assert((data().DefaultedCopyConstructorIsDeleted ||
  837     assert((data().DefaultedMoveConstructorIsDeleted ||
  846     assert((data().DefaultedDestructorIsDeleted ||
  918     assert((data().DefaultedMoveAssignmentIsDeleted ||
  999     assert(isLambda());
 1668     assert(DeclAccess != AS_none);
 1707     assert(isLambda() && "Not a lambda closure type!");
 1714     assert(isLambda() && "Not a lambda closure type!");
 1733     assert(isLambda() && "Not a lambda closure type!");
 2245     assert(isPackExpansion() && "Initializer is not a pack expansion");
 2260     assert(isBaseInitializer() && "Must call this on base initializer!");
 2321     assert(!IsWritten &&
 2323     assert(SourceOrder == 0 &&
 2325     assert(Pos >= 0 &&
 2402     assert((!ES.getExpr() ||
 2508     assert(CXXConstructorDeclBits.NumCtorInitializers ==
 2799     assert(!RBraceLoc.isValid() || LinkageSpecDeclBits.HasBraces);
 3135     assert(ND && "Target decl is null!");
tools/clang/include/clang/AST/DeclContextInternals.h
   98     assert(!getAsVector() && "Not inline");
  102     assert(*(NamedDecl **)&Data == ND &&
  107     assert(!isNull() && "removing from empty list");
  109       assert(Singleton == D && "list is different singleton");
  117     assert(I != Vec.end() && "list does not contain decl");
  120     assert(llvm::find(Vec, D) == Vec.end() && "list still contains decl");
  149       assert(!isNull() && "Empty list isn't allowed");
  155     assert(getAsVector() && "Must have a vector at this point");
  190     assert(!isNull() && "don't AddSubsequentDecl when we have no decls");
tools/clang/include/clang/AST/DeclFriend.h
  132     assert(N < NumTPLists);
  206     assert(Ptr && "attempt to increment past end of friend list");
  226     assert(N >= 0 && "cannot rewind a CXXRecordDecl::friend_iterator");
  252   assert(!FD->NextFriend && "friend already has next friend?");
tools/clang/include/clang/AST/DeclGroup.h
   41     assert (i < NumDecls && "Out-of-bounds access.");
   46     assert (i < NumDecls && "Out-of-bounds access.");
   84     assert(isSingleDecl() && "Isn't a single decl");
   92     assert(isDeclGroup() && "Isn't a declgroup");
tools/clang/include/clang/AST/DeclObjC.h
   94     assert(Idx < NumElts && "Invalid access");
  295     assert(Index < getNumSelectorLocs() && "Index out of range!");
  372     assert(Idx < NumParams && "Index out of bounds!");
  690     assert(size() > 0 && "empty Objective-C type parameter list");
  695     assert(size() > 0 && "empty Objective-C type parameter list");
 1262     assert(Data.getPointer() && "Declaration has no definition!");
 1341     assert(hasDefinition() && "Caller did not check for forward reference!");
 2087     assert(Data.getPointer() && "Objective-C protocol has no definition!");
 2121     assert(hasDefinition() && "No definition available!");
 2178     assert(hasDefinition() && "Protocol is not defined");
 2673     assert(getIdentifier() && "Name is not a simple identifier");
 2797     assert(PK == Dynamic || PropertyIvarDecl);
tools/clang/include/clang/AST/DeclTemplate.h
  133     assert(Idx < size() && "Template parameter index out-of-range");
  137     assert(Idx < size() && "Template parameter index out-of-range");
  217             (assert(N == Params.size()),
  218              assert(HasRequiresClause == static_cast<bool>(RequiresClause)),
  270     assert(Idx < NumArguments && "Invalid template argument index");
  318     assert(!Parm->getDefaultArgStorage()
  357     assert(!isSet() && "default argument already set");
  363     assert(!isInherited() && "default argument already inherited");
  445     assert(!TemplatedDecl && "TemplatedDecl already set!");
  446     assert(!TemplateParams && "TemplateParams already set!");
  535     assert(TSK != TSK_Undeclared &&
  620     assert(TSK != TSK_Undeclared &&
  639     assert(TSK != TSK_Undeclared &&
  708     assert(I < getNumTemplates() && "template index out of range");
  722     assert(I < getNumTemplateArgs() && "template arg index out of range");
  878     assert(getCommonPtr()->InstantiatedFromMember.getPointer() &&
  924     assert(!getCommonPtr()->InstantiatedFromMember.getPointer());
 1404     assert(ExpandedParameterPack && "Not an expansion parameter pack");
 1411     assert(I < NumExpandedTypes && "Out-of-range expansion type index");
 1420     assert(I < NumExpandedTypes && "Out-of-range expansion type index");
 1541     assert(ExpandedParameterPack && "Not an expansion parameter pack");
 1548     assert(I < NumExpandedParams && "Out-of-range expansion type index");
 1774     assert(Loc.isValid() && "point of instantiation must be valid!");
 1828     assert(!SpecializedTemplate.is<SpecializedPartialSpecialization*>() &&
 1839     assert(!SpecializedTemplate.is<SpecializedPartialSpecialization*>() &&
 2045     assert(First->InstantiatedFromMember.getPointer() &&
 2054     assert(getTypeForDecl() && "partial specialization has no type set!");
 2322     assert(i <= NumParams);
 2618     assert(Loc.isValid() && "point of instantiation must be valid!");
 2672     assert(!SpecializedTemplate.is<SpecializedPartialSpecialization *>() &&
 2683     assert(!SpecializedTemplate.is<SpecializedPartialSpecialization *>() &&
 2878     assert(First->InstantiatedFromMember.getPointer() &&
tools/clang/include/clang/AST/DeclarationName.h
  264     assert((Kind & ~PtrMask) == 0 &&
  266     assert((PAsInteger & PtrMask) == 0 &&
  279     assert((StoredKind == StoredCXXConstructorName ||
  294     assert((getStoredNameKind() == StoredIdentifier) &&
  302     assert((getStoredNameKind() == StoredDeclarationNameExtra) &&
  310     assert((getStoredNameKind() == StoredCXXConstructorName ||
  320     assert((getStoredNameKind() == StoredCXXOperatorName) &&
  328     assert(getNameKind() == CXXDeductionGuideName &&
  336     assert(getNameKind() == CXXLiteralOperatorName &&
  443       assert(getPtr() && "getCXXNameType on a null DeclarationName!");
  453       assert(getPtr() &&
  464       assert(getPtr() && "getCXXOverloadedOperator on a null DeclarationName!");
  474       assert(getPtr() && "getCXXLiteralIdentifier on a null DeclarationName!");
  482     assert((getNameKind() == ObjCZeroArgSelector ||
  493     assert(getPtr() && "getFETokenInfo on an empty DeclarationName!");
  500     assert(getPtr() && "setFETokenInfo on an empty DeclarationName!");
  741     assert(Name.getNameKind() == DeclarationName::CXXConstructorName ||
  761     assert(Name.getNameKind() == DeclarationName::CXXOperatorName);
  780     assert(Name.getNameKind() == DeclarationName::CXXLiteralOperatorName);
tools/clang/include/clang/AST/DependentDiagnostic.h
   65     assert(getKind() == Access);
   70     assert(getKind() == Access);
   75     assert(getKind() == Access);
   80     assert(getKind() == Access);
   85     assert(getKind() == Access);
   90     assert(getKind() == Access);
  139     assert(Ptr && "attempt to increment past end of diag list");
  159     assert(N >= 0 && "cannot rewind a DeclContext::ddiag_iterator");
  176   assert(isDependentContext()
tools/clang/include/clang/AST/Expr.h
  128     assert(ExprBits.ObjectKind == OK && "truncated kind");
  145     assert((t.isNull() || !t->isReferenceType()) &&
  358       assert(Modifiable != CM_Untested && "Did not test for modifiability.");
  487     assert(BuiltinType::isPlaceholderTypeKind(K));
  974     assert(ConstantExprBits.ResultKind == ConstantExpr::RSK_Int64 &&
  982     assert(ConstantExprBits.ResultKind == ConstantExpr::RSK_APValue &&
 1111     assert((!V || SourceExpr) &&
 1576     assert(&getSemantics() == &Val.getSemantics() && "Inconsistent semantics");
 1745     assert(TokNum < getNumConcatenated() && "Invalid tok number");
 1770     assert(getCharByteWidth() == 1 &&
 1785     assert(i < getLength() && "out of bounds access");
 1834     assert(TokNum < getNumConcatenated() && "Invalid tok number");
 1912     assert(hasFunctionName() &&
 2197     assert(getKind() == Array);
 2203     assert(getKind() == Field);
 2213     assert(getKind() == Base);
 2292     assert(Idx < NumComps && "Subscript out of range");
 2297     assert(Idx < NumComps && "Subscript out of range");
 2306     assert(Idx < NumExprs && "Subscript out of range");
 2311     assert(Idx < NumExprs && "Subscript out of range");
 2316     assert(Idx < NumComps && "Subscript out of range");
 2388     assert(isArgumentType() && "calling getArgumentType() when arg is expr");
 2392     assert(!isArgumentType() && "calling getArgumentExpr() when arg is type");
 2590     assert(I < getNumPreArgs() && "Prearg access out of range!");
 2594     assert(I < getNumPreArgs() && "Prearg access out of range!");
 2598     assert(I < getNumPreArgs() && "Prearg access out of range!");
 2678     assert(Arg < getNumArgs() && "Arg access out of range!");
 2682     assert(Arg < getNumArgs() && "Arg access out of range!");
 2688     assert(Arg < getNumArgs() && "Arg access out of range!");
 2699     assert((NewNumArgs <= getNumArgs()) &&
 3156     assert((CastExprBits.BasePathSize == BasePathSize) &&
 3158     assert(CastConsistency());
 3166     assert((CastExprBits.BasePathSize == BasePathSize) &&
 3210     assert(getCastKind() == CK_ToUnion);
 3431     assert(!isCompoundAssignmentOp() &&
 3547     assert(isCompoundAssignmentOp(Opc));
 3641     assert(isCompoundAssignmentOp() &&
 3810     assert(OpaqueValue->getSourceExpr() == common && "Wrong opaque value");
 4012     assert((Index < NumExprs) && "Arg access out of range!");
 4016     assert((Index < NumExprs) && "Arg access out of range!");
 4023     assert((N < NumExprs - 2) && "Shuffle idx out of range!");
 4131     assert(!isConditionDependent() &&
 4424     assert(Init < getNumInits() && "Initializer access out of range!");
 4429     assert(Init < getNumInits() && "Initializer access out of range!");
 4434     assert(Init < getNumInits() && "Initializer access out of range!");
 4494     assert((FD == nullptr
 4741       assert(Kind == FieldDesignator && "Only valid on a field designator");
 4749       assert(Kind == FieldDesignator && "Only valid on a field designator");
 4754       assert(Kind == FieldDesignator && "Only valid on a field designator");
 4759       assert(Kind == FieldDesignator && "Only valid on a field designator");
 4764       assert((Kind == ArrayDesignator || Kind == ArrayRangeDesignator) &&
 4770       assert((Kind == ArrayDesignator || Kind == ArrayRangeDesignator) &&
 4776       assert(Kind == ArrayRangeDesignator &&
 4782       assert((Kind == ArrayDesignator || Kind == ArrayRangeDesignator) &&
 4864     assert(Idx < NumSubExprs && "Subscript out of range");
 4869     assert(Idx < NumSubExprs && "Subscript out of range");
 5144     assert(Init < getNumExprs() && "Initializer access out of range!");
 5380     assert(!isResultDependent() &&
 5419     assert(I < getNumAssocs() &&
 5427     assert(I < getNumAssocs() &&
 5762     assert(index + 1 < getNumSubExprs());
 5846     assert(getScopeModel() && "No scope");
 5852     assert(NumSubExprs > VAL1);
 5856     assert(NumSubExprs > ORDER_FAIL);
 5862     assert(NumSubExprs > VAL2);
 5866     assert(NumSubExprs > WEAK);
 5944     assert(T->isDependentType() && "TypoExpr given a non-dependent type");
tools/clang/include/clang/AST/ExprCXX.h
  812     assert(isTypeOperand() && "Cannot call getTypeOperand for typeid(expr)");
  817     assert(isTypeOperand() && "Cannot call getTypeOperand for typeid(expr)");
  822     assert(!isTypeOperand() && "Cannot call getExprOperand for typeid(type)");
  827     assert(!isTypeOperand() && "Cannot call getExprOperand for typeid(type)");
 1037     assert(isTypeOperand() && "Cannot call getTypeOperand for __uuidof(expr)");
 1042     assert(isTypeOperand() && "Cannot call getTypeOperand for __uuidof(expr)");
 1047     assert(!isTypeOperand() && "Cannot call getExprOperand for __uuidof(type)");
 1052     assert(!isTypeOperand() && "Cannot call getExprOperand for __uuidof(type)");
 1308     assert(Field->getInClassInitializer() && "initializer hasn't been parsed");
 1312     assert(Field->getInClassInitializer() && "initializer hasn't been parsed");
 1574     assert(Arg < getNumArgs() && "Arg access out of range!");
 1578     assert(Arg < getNumArgs() && "Arg access out of range!");
 1584     assert(Arg < getNumArgs() && "Arg access out of range!");
 1639     assert(!T->isDependentType());
 1792   assert((getStmtClass() == CXXConstructExprClass) &&
 2246     assert((I < getNumPlacementArgs()) && "Index out of range!");
 2671     assert(!isValueDependent());
 2680     assert(I < getNumArgs() && "Argument out-of-range");
 2760   uint64_t getValue() const { assert(!isTypeDependent()); return Value; }
 2905     assert(E->getType()->isSpecificBuiltinType(BuiltinType::Overload));
 2911       assert(cast<UnaryOperator>(E)->getOpcode() == UO_AddrOf);
 3340     assert(i < getNumObjects() && "Index out of range");
 3466     assert(I < arg_size() && "Argument index out-of-range");
 3471     assert(I < arg_size() && "Argument index out-of-range");
 3476     assert(I < arg_size() && "Argument index out-of-range");
 3610     assert(!isImplicitAccess());
 3849     assert(!isImplicitAccess());
 3853     assert(!isImplicitAccess());
 4133     assert((!Length || PartialArgs.empty()) &&
 4169     assert(!isValueDependent() &&
 4185     assert(isPartiallySubstituted());
 4648     assert(Common->isTypeDependent() && Ty->isDependentType() &&
 4757     assert(Ty->isDependentType() &&
 4936     assert(!isValueDependent()
tools/clang/include/clang/AST/ExprObjC.h
  231     assert((Index < NumElements) && "Arg access out of range!");
  235     assert((Index < NumElements) && "Arg access out of range!");
  361     assert((Index < NumElements) && "Arg access out of range!");
  656     assert(t->isSpecificPlaceholderType(BuiltinType::PseudoObject));
  667     assert(t->isSpecificPlaceholderType(BuiltinType::PseudoObject));
  678     assert(T->isSpecificPlaceholderType(BuiltinType::PseudoObject));
  688     assert(T->isSpecificPlaceholderType(BuiltinType::PseudoObject));
  698     assert(T->isSpecificPlaceholderType(BuiltinType::PseudoObject));
  708     assert(!isImplicitProperty());
  713     assert(isImplicitProperty());
  718     assert(isImplicitProperty());
 1039     assert((Num >> NumArgsBitWidth) == 0 && "Num of args is out of range!");
 1396     assert(Arg < NumArgs && "Arg access out of range!");
 1400     assert(Arg < NumArgs && "Arg access out of range!");
 1406     assert(Arg < NumArgs && "Arg access out of range!");
 1426     assert(Index < getNumSelectorLocs() && "Index out of range!");
tools/clang/include/clang/AST/ExternalASTSource.h
   84       assert(Source);
  373     assert((Offset << 1 >> 1) == Offset && "Offsets must require < 63 bits");
  402       assert(Source &&
tools/clang/include/clang/AST/FormatString.h
   41     assert(position);
   46     assert(position);
  210         assert(IsPrintf);
  295     assert(A.K >= InvalidTy && "ArgType cannot be pointer to invalid/unknown");
  355     assert(hasDataArgument());
  360     assert(hs == Constant);
  370     assert(hs == Constant);
  380     assert(hasDataArgument());
tools/clang/include/clang/AST/GlobalDecl.h
   45     assert(!isa<CXXConstructorDecl>(D) && "Use other ctor with ctor decls!");
   46     assert(!isa<CXXDestructorDecl>(D) && "Use other ctor with dtor decls!");
   80     assert(isa<CXXConstructorDecl>(getDecl()) && "Decl is not a ctor!");
   85     assert(isa<CXXDestructorDecl>(getDecl()) && "Decl is not a dtor!");
   90     assert(isa<VarDecl>(getDecl()) &&
   97     assert(isa<FunctionDecl>(getDecl()) &&
  124     assert(isa<CXXConstructorDecl>(getDecl()));
  131     assert(isa<CXXDestructorDecl>(getDecl()));
  138     assert(isa<FunctionDecl>(getDecl()) &&
tools/clang/include/clang/AST/JSONNodeDumper.h
  360         assert(isa<CXXRecordDecl>(RedeclWithBadType) &&
tools/clang/include/clang/AST/LambdaCapture.h
  105     assert(capturesVariable() && "No variable available for capture");
  134     assert(isPackExpansion() && "No ellipsis location for a non-expansion");
tools/clang/include/clang/AST/LexicallyOrderedRecursiveASTVisitor.h
  147     assert(!BaseType::getDerived().shouldTraversePostOrder() &&
tools/clang/include/clang/AST/LocInfoType.h
   42     assert(getTypeClass() == (TypeClass)LocInfo && "LocInfo didn't fit in TC?");
tools/clang/include/clang/AST/OSLog.h
   84     assert(((Flags == 0) || (Flags == IsPrivate) || (Flags == IsPublic) ||
tools/clang/include/clang/AST/OpenMPClause.h
  118     assert(get(This) && "get is not tuned for pre-init.");
  151     assert(get(This) && "get is not tuned for post-update.");
  214     assert(VL.size() == NumVars &&
 1339       assert(Modifiers[SECOND] == OMPC_SCHEDULE_MODIFIER_unknown);
 4354     assert(UDs.size() == NumUniqueDeclarations &&
 4378     assert(DNLs.size() == NumUniqueDeclarations &&
 4404     assert(CLSs.size() == NumComponentLists &&
 4430     assert(Components.size() == NumComponents &&
 4432     assert(CLSs.size() == NumComponentLists &&
 4443     assert(getUniqueDeclarationsTotalNumber(Declarations) ==
 4446     assert(getComponentsTotalNumber(ComponentLists) == NumComponents &&
 4448     assert(Declarations.size() == ComponentLists.size() &&
 4450     assert(Declarations.size() == NumComponentLists &&
 4462         assert(!CI->empty() && "Invalid component list!");
 4544     assert(DMDs.size() == OMPVarListClause<T>::varlist_size() &&
 4608       assert(UniqueDecls.size() == DeclsListNum.size() &&
 4629         assert(*NumListsCur > 0 && "No lists associated with declaration??");
 4663       assert(ListSizeCur != ListSizeEnd && "Invalid iterator!");
 4675       assert(ListSizeCur != ListSizeEnd && RemainingLists &&
 4692           assert(RemainingLists && "No lists in the following declaration??");
 4881     assert(llvm::array_lengthof(MapTypeModifiers) == MapModifiers.size() &&
 4885     assert(llvm::array_lengthof(MapTypeModifiersLoc) ==
 4906     assert(I < NumberOfModifiers &&
 4916     assert(I < NumberOfModifiers &&
 4991     assert(Cnt < NumberOfModifiers &&
 5001     assert(Cnt < NumberOfModifiers &&
tools/clang/include/clang/AST/RecordLayout.h
  203     assert(CXXInfo && "Record layout does not have C++ specific info!");
  211     assert(CXXInfo && "Record layout does not have C++ specific info!");
  218     assert(CXXInfo && "Record layout does not have C++ specific info!");
  226     assert(CXXInfo && "Record layout does not have C++ specific info!");
  233     assert(CXXInfo && "Record layout does not have C++ specific info!");
  234     assert(CXXInfo->BaseOffsets.count(Base) && "Did not find base!");
  241     assert(CXXInfo && "Record layout does not have C++ specific info!");
  242     assert(CXXInfo->VBaseOffsets.count(VBase) && "Did not find base!");
  248     assert(CXXInfo && "Record layout does not have C++ specific info!");
  260     assert(CXXInfo && "Record layout does not have C++ specific info!");
  268     assert(CXXInfo && "Record layout does not have C++ specific info!");
  280     assert(CXXInfo && "Record layout does not have C++ specific info!");
  286     assert(CXXInfo && "Record layout does not have C++ specific info!");
  299     assert(CXXInfo && "Record layout does not have C++ specific info!");
  306     assert(CXXInfo && "Record layout does not have C++ specific info!");
  311     assert(CXXInfo && "Record layout does not have C++ specific info!");
  316     assert(CXXInfo && "Record layout does not have C++ specific info!");
tools/clang/include/clang/AST/Redeclarable.h
  138       assert(!isFirst() && "decl became non-canonical unexpectedly");
  143       assert(isFirst() && "decl became canonical unexpectedly");
  159       assert(isFirst() && "expected a canonical decl");
  259       assert(Current && "Advancing while iterator has reached end");
  263           assert(0 && "Passed first decl twice, invalid redecl chain!");
tools/clang/include/clang/AST/Stmt.h
 1571     assert(
 1602     assert(caseStmtIsGNURange() &&
 1929     assert(hasElseStorage() &&
 1976     assert(hasInitStorage() &&
 1990     assert(hasElseStorage() &&
 2119     assert(hasInitStorage() &&
 2169     assert(!SC->getNextSwitchCase() &&
 2671     assert(hasNRVOCandidate() &&
 2925       assert(isOperand());
 2930       assert(isOperand() && "Range is currently used only for Operands.");
 3127     assert(i < NumOutputs);
 3140     assert(i < NumInputs);
 3482     assert(D && "null RecordDecl");
tools/clang/include/clang/AST/StmtIterator.h
   65     assert(inDeclGroup() || inSizeOfTypeVA());
tools/clang/include/clang/AST/StmtObjC.h
  218     assert(I < NumCatchStmts && "Out-of-bounds @catch index");
  224     assert(I < NumCatchStmts && "Out-of-bounds @catch index");
  230     assert(I < NumCatchStmts && "Out-of-bounds @catch index");
  248     assert(HasFinally && "@try does not have a @finally slot!");
tools/clang/include/clang/AST/StmtOpenMP.h
   86     assert(hasAssociatedStmt() && "no associated statement.");
  209       assert(std::next(Clauses.begin()) == Clauses.end() &&
  254     assert(hasAssociatedStmt() && "no associated statement.");
  258     assert(hasAssociatedStmt() && "no associated statement.");
  269     assert(std::any_of(
  284     assert(hasAssociatedStmt() && getAssociatedStmt() &&
  288     assert(!CaptureRegions.empty() &&
  608     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  615     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  622     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  629     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  636     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  643     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  650     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  657     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  664     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  669     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  674     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  679     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  684     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  689     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  694     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  699     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  704     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  709     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  714     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  719     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  724     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
  946     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  954     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  962     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  970     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  978     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  986     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
  994     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
 1002     assert((isOpenMPWorksharingDirective(getDirectiveKind()) ||
 1010     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1016     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1022     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1028     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1034     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1040     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1046     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1052     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1058     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1064     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1070     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1076     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1082     assert(isOpenMPLoopBoundSharingDirective(getDirectiveKind()) &&
 1094       assert(isa<CXXForRangeStmt>(Body) &&
 1103         assert(isa<CXXForRangeStmt>(Body) &&
tools/clang/include/clang/AST/TemplateBase.h
  153     assert(D && "Expected decl");
  257     assert(getKind() == Type && "Unexpected kind");
  264     assert(getKind() == Declaration && "Unexpected kind");
  269     assert(getKind() == Declaration && "Unexpected kind");
  275     assert(getKind() == NullPtr && "Unexpected kind");
  281     assert(getKind() == Template && "Unexpected kind");
  288     assert((getKind() == Template || getKind() == TemplateExpansion) &&
  301     assert(getKind() == Integral && "Unexpected kind");
  315     assert(getKind() == Integral && "Unexpected kind");
  320     assert(getKind() == Integral && "Unexpected kind");
  330     assert(getKind() == Expression && "Unexpected kind");
  340     assert(getKind() == Pack);
  347     assert(getKind() == Pack);
  360     assert(getKind() == Pack);
  366     assert(getKind() == Pack);
  462     assert(Argument.getKind() == TemplateArgument::Type);
  470     assert(Argument.getKind() == TemplateArgument::NullPtr ||
  482     assert(Argument.getKind() == TemplateArgument::Template ||
  507     assert(Argument.getKind() == TemplateArgument::Type);
  512     assert(Argument.getKind() == TemplateArgument::Expression);
  517     assert(Argument.getKind() == TemplateArgument::Declaration);
  522     assert(Argument.getKind() == TemplateArgument::NullPtr);
  527     assert(Argument.getKind() == TemplateArgument::Integral);
  695   assert(Idx < getNumArgs() && "Template argument out of range");
  701   assert(Idx < getNumArgs() && "Template argument out of range");
tools/clang/include/clang/AST/TemplateName.h
  505     assert(isIdentifier() && "Template name isn't an identifier?");
  515     assert(isOverloadedOperator() &&
tools/clang/include/clang/AST/Type.h
  274     assert(!(mask & ~CVRMask) && "bitmask contains non-CVR bits");
  278     assert(!(mask & ~CVRMask) && "bitmask contains non-CVR bits");
  285     assert(!(mask & ~CVRMask) && "bitmask contains non-CVR bits");
  289     assert(!(mask & ~CVRMask & ~UMask) && "bitmask contains non-CVRU bits");
  307     assert(type);
  335     assert(type);
  336     assert(!hasObjCLifetime());
  365     assert(Addr == LangAS::Default || hasTargetSpecificAddressSpace());
  374     assert((unsigned)space <= MaxAddressSpace);
  380     assert(space != LangAS::Default);
  389     assert(!(mask & ~FastMask) && "bitmask contains non-fast qualifier bits");
  393     assert(!(mask & ~FastMask) && "bitmask contains non-fast qualifier bits");
  400     assert(!(mask & ~FastMask) && "bitmask contains non-fast qualifier bits");
  454     assert(getAddressSpace() == qs.getAddressSpace() ||
  456     assert(getObjCGCAttr() == qs.getObjCGCAttr() ||
  458     assert(getObjCLifetime() == qs.getObjCLifetime() ||
  659     assert(!isNull() && "Cannot retrieve a NULL type pointer");
  840     assert(!(TQs & ~Qualifiers::FastMask)
  852     assert(!(Mask & ~Qualifiers::FastMask) && "mask has non-fast qualifiers");
 1349     assert(Quals.hasNonFastQualifiers()
 1351     assert(!Quals.hasFastQualifiers()
 1378     assert(!Quals.hasFastQualifiers() && "fast qualifiers in ExtQuals hash!");
 1486       assert(isCacheValid() && "getting linkage from invalid cache");
 1491       assert(isCacheValid() && "getting linkage from invalid cache");
 2472     assert(!str.empty() && str.data()[str.size()] == '\0');
 2919       assert(!can.isNull() && "canonical constant array should not have size");
 3534        assert((!hasRegParm || regParm < 7) && "Invalid regparm value");
 3604       assert(RegParm < 7 && "Invalid regparm value");
 3930     assert(i < getNumParams() && "invalid parameter index");
 3996     assert(i < getNumExceptions() && "Invalid exception number!");
 4103     assert(hasExtParameterInfos());
 4118     assert(I < getNumParams() && "parameter index out of range");
 4125     assert(I < getNumParams() && "parameter index out of range");
 4132     assert(I < getNumParams() && "parameter index out of range");
 4202     assert(!isa<TypedefType>(can) && "Invalid canonical type");
 4229     assert(isa<AttributedType>(UnderlyingTy) &&
 4304     assert(!isa<TypedefType>(can) && "Invalid canonical type");
 4970     assert(isTypeAlias() && "not a type alias template specialization");
 5080     assert(isa<TemplateSpecializationType>(TST));
 5081     assert(!TST.hasQualifiers());
 5082     assert(TST->isDependentType());
 5235     assert(!(Keyword == ETK_None && NNS == nullptr) &&
 5503     assert(getNumProtocols() == protocols.size() &&
 5528     assert(I < getNumProtocols() && "Out-of-range protocol access");
 5746     assert(CachedSuperClassType.getInt() && "Superclass not set?");
 6255   assert(!(Mask & ~Qualifiers::CVRMask) && "mask has non-CVR bits");
 6638   assert(BuiltinType::isPlaceholderTypeKind((BuiltinType::Kind) K));
 6928   assert(isa<T>(CanonicalType));
 6933   assert(isa<ArrayType>(CanonicalType));
 6944   assert(isa<PointerType>(Adjusted));
tools/clang/include/clang/AST/TypeLoc.h
   76     assert(T::isKind(*this));
  199     assert(getType() == Other.getType());
  207     assert(getType() == Other.getType());
  208     assert(getFullDataSize() == Size);
  793     assert(i < getNumProtocols() && "Index is out of bounds!");
  798     assert(i < getNumProtocols() && "Index is out of bounds!");
  803     assert(i < getNumProtocols() && "Index is out of bounds!");
  956     assert(i < getNumTypeArgs() && "Index is out of bounds!");
  961     assert(i < getNumTypeArgs() && "Index is out of bounds!");
  986     assert(i < getNumProtocols() && "Index is out of bounds!");
  991     assert(i < getNumProtocols() && "Index is out of bounds!");
  996     assert(i < getNumProtocols() && "Index is out of bounds!");
 1374     assert(hasExceptionSpec() && "No exception spec range");
 1642     assert(size == Loc.getFullDataSize());
 1988     assert(QualifierLoc.getNestedNameSpecifier()
 2017     assert(size == Loc.getFullDataSize());
 2047     assert(QualifierLoc.getNestedNameSpecifier()
 2070     assert(size == Loc.getFullDataSize());
 2116     assert(QualifierLoc.getNestedNameSpecifier()
 2183     assert(size == Loc.getFullDataSize());
tools/clang/include/clang/AST/VTableBuilder.h
   71     assert(!isa<CXXDestructorDecl>(MD) &&
   89     assert(!isa<CXXDestructorDecl>(MD) &&
  101     assert(getKind() == CK_VCallOffset && "Invalid component kind!");
  107     assert(getKind() == CK_VBaseOffset && "Invalid component kind!");
  113     assert(getKind() == CK_OffsetToTop && "Invalid component kind!");
  119     assert(isRTTIKind() && "Invalid component kind!");
  124     assert(isFunctionPointerKind() && "Invalid component kind!");
  131     assert(isDestructorKind() && "Invalid component kind!");
  136     assert(getKind() == CK_UnusedFunctionPointer && "Invalid component kind!");
  153     assert(isUsedFunctionPointerKind() &&
  192     assert((ComponentKind == CK_VCallOffset ||
  195     assert(Offset.getQuantity() < (1LL << 56) && "Offset is too big!");
  196     assert(Offset.getQuantity() >= -(1LL << 56) && "Offset is too small!");
  202     assert((isRTTIKind(ComponentKind) || isFunctionPointerKind(ComponentKind)) &&
  205     assert((Ptr & 7) == 0 && "Pointer not sufficiently aligned!");
  211     assert((getKind() == CK_VCallOffset || getKind() == CK_VBaseOffset ||
  218     assert((getKind() == CK_RTTI || isFunctionPointerKind()) &&
  272     assert(AddressPoints.count(Base) && "Did not find address point!");
  288       assert(i == 0);
  296       assert(i == 0);
  379     assert(VTableLayouts.count(RD) && "No layout for this record decl!");
  500       assert(VBase != other.VBase);
tools/clang/include/clang/ASTMatchers/ASTMatchers.h
 2571   assert(!RegExp.empty());
 3160   assert(!RegExp.empty());
tools/clang/include/clang/ASTMatchers/ASTMatchersInternal.h
  446     assert(canConvertTo<T>());
  510     assert(Implementation.getSupportedKind().isSame(
  586     assert(this->Implementation.getSupportedKind()
  606   assert(canConvertTo<QualType>());
tools/clang/include/clang/ASTMatchers/Dynamic/VariantValue.h
   43   ArgKind(Kind K) : K(K) { assert(K != AK_Matcher); }
   51     assert(K == AK_Matcher);
  200     assert(hasTypedMatcher<T>() && "hasTypedMatcher<T>() == false");
tools/clang/include/clang/Analysis/Analyses/Dominators.h
   88     assert(cfg);
  100       assert(*I &&
  118         assert((IsDomTreeRoot || IsPostDomTreeRoot) &&
  246     assert(It != ControlDepenencyMap.end());
  261       assert(BB &&
tools/clang/include/clang/Analysis/Analyses/ThreadSafetyTIL.h
  717     assert(Vd->Definition == nullptr);
  724     assert(Vd->Definition == nullptr);
  914     assert(Cvd && "ValueDecl must not be null");
 1742     assert(BB->CFGPtr == nullptr);
tools/clang/include/clang/Analysis/Analyses/ThreadSafetyUtil.h
  139     assert(i < Size && "Array index out of bounds.");
  144     assert(i < Size && "Array index out of bounds.");
  179     assert(Size < Capacity);
  185     assert(Size > n);
  190     assert(Sz <= Capacity);
  323     assert(writable() && "Vector is not writable!");
  330     assert(writable() && "Vector is not writable!");
  336     assert(writable() && "Vector is not writable!");
tools/clang/include/clang/Analysis/CFG.h
   89     assert(getKind() == kind);
   99     assert(T::isKind(*this));
  135     assert(isKind(*this));
  160     assert(C);
  189     assert(isa<CallExpr>(E) || isa<ObjCMessageExpr>(E));
  199     assert(isCXXRecordTypedCall(E));
  200     assert(C && (isa<TemporaryObjectConstructionContext>(C) ||
  370     assert(kind >= DTOR_BEGIN && kind <= DTOR_END);
  531   CFGTerminator() { assert(!isValid()); }
  611       assert(i < Impl.size());
  714       assert(Parent == Other.Parent);
 1345     assert(Synthetic->isSingleDecl() && "Can handle single declarations only");
 1346     assert(Synthetic != Source && "Don't include original DeclStmts in map");
 1347     assert(!SyntheticDeclStmts.count(Synthetic) && "Already in map");
tools/clang/include/clang/Analysis/CloneDetection.h
   85     assert(!empty());
   93     assert(!empty());
  114     assert(D);
tools/clang/include/clang/Analysis/ConstructionContext.h
  119     assert(isa<CallExpr>(E) || isa<CXXConstructExpr>(E) ||
  137     assert(hasStatement());
  149     assert(hasInitializer());
  160     assert(hasIndex());
  306     assert(classof(this));
  307     assert(DS);
  354     assert(BTE);
  373     assert(classof(this));
  374     assert(I);
  424     assert(BTE);
  445     assert(NE);
  539     assert(ElidedCE && ElidedCE->isElidable() && ElidedCC);
  563     assert(classof(this));
  564     assert(RS);
  614     assert(BTE);
  643     assert(isa<CallExpr>(CE) || isa<CXXConstructExpr>(CE) ||
tools/clang/include/clang/Analysis/PathDiagnostic.h
  187     assert(K == SingleLocK || S);
  188     assert(K == SingleLocK || Loc.isValid());
  189     assert(K == SingleLocK || Range.isValid());
  195     assert(D);
  196     assert(Loc.isValid());
  197     assert(Range.isValid());
  205     assert(Loc.isValid());
  206     assert(Range.isValid());
  309   const Stmt *asStmt() const { assert(isValid()); return S; }
  316   const Decl *asDecl() const { assert(isValid()); return D; }
  328   const SourceManager& getManager() const { assert(isValid()); return *SM; }
  480     assert(Pos.isValid() && Pos.hasValidLocation() &&
  616     assert(!LPairs.empty() &&
  622     assert(!LPairs.empty() &&
  783     assert(!Loc.isValid() && "End location already set!");
  785     assert(Loc.isValid() && "Invalid location for end-of-path piece");
tools/clang/include/clang/Analysis/ProgramPoint.h
  109         assert(getKind() == k);
  110         assert(getLocationContext() == l);
  111         assert(getData1() == P);
  141     assert(T::isKind(*this));
  230     assert(B && "BlockEntrance requires non-null block");
  276     assert(S);
  439     assert(getData2() == nullptr);
  507     assert(B1 && "BlockEdge: source block must be non-null");
  508     assert(B2 && "BlockEdge: destination block must be non-null");
tools/clang/include/clang/Analysis/Support/BumpVector.h
  113     assert(Begin + idx < End);
  174     assert(I >= Begin && I <= End && "Iterator out of bounds.");
tools/clang/include/clang/Basic/AddressSpaces.h
   62   assert(isTargetAddressSpace(AS));
tools/clang/include/clang/Basic/AttributeCommonInfo.h
  162     assert((isAttributeSpellingListCalculated() || AttrName) &&
tools/clang/include/clang/Basic/Diagnostic.h
  523     assert(SourceMgr && "SourceManager not set!");
  528     assert(DiagStatesByLoc.empty() &&
 1065     assert(diagObj && "DiagnosticBuilder requires a valid DiagnosticsEngine!");
 1144     assert(isActive() && "Clients must not add to cleared diagnostic!");
 1145     assert(NumArgs < DiagnosticsEngine::MaxArguments &&
 1152     assert(isActive() && "Clients must not add to cleared diagnostic!");
 1153     assert(NumArgs < DiagnosticsEngine::MaxArguments &&
 1160     assert(isActive() && "Clients must not add to cleared diagnostic!");
 1165     assert(isActive() && "Clients must not add to cleared diagnostic!");
 1292   assert(CurDiagID == std::numeric_limits<unsigned>::max() &&
 1341     assert(Idx < getNumArgs() && "Argument index out of range!");
 1348     assert(getArgKind(Idx) == DiagnosticsEngine::ak_std_string &&
 1356     assert(getArgKind(Idx) == DiagnosticsEngine::ak_c_string &&
 1364     assert(getArgKind(Idx) == DiagnosticsEngine::ak_sint &&
 1372     assert(getArgKind(Idx) == DiagnosticsEngine::ak_uint &&
 1380     assert(getArgKind(Idx) == DiagnosticsEngine::ak_identifierinfo &&
 1388     assert(getArgKind(Idx) != DiagnosticsEngine::ak_std_string &&
 1400     assert(Idx < getNumRanges() && "Invalid diagnostic range index!");
 1414     assert(Idx < getNumFixItHints() && "Invalid index!");
tools/clang/include/clang/Basic/FixedPoint.h
   39     assert(Width >= Scale && "Not enough room for the scale");
   40     assert(!(IsSigned && HasUnsignedPadding) &&
   99      assert(Val.getBitWidth() == Sema.getWidth() &&
tools/clang/include/clang/Basic/IdentifierTable.h
  197     assert(TokenID != tok::identifier && "Already at tok::identifier");
  202     assert(TokenID == tok::identifier && "Should be at tok::identifier");
  246     assert(ObjCOrBuiltinID - unsigned(tok::NUM_OBJC_KEYWORDS) == ID
  545     assert(II.TokenID == (unsigned) TokenCode && "TokenCode too large");
  694     assert((InfoPtr & ArgFlags) == 0 &&"Insufficiently aligned IdentifierInfo");
  695     assert(nArgs < 2 && "nArgs not equal to 0/1");
  701     assert((InfoPtr & ArgFlags) == 0 &&"Insufficiently aligned IdentifierInfo");
  916     assert(ExtraKindOrNumArgs >= (unsigned)ObjCMultiArgSelector &&
tools/clang/include/clang/Basic/Module.h
  437     assert(!Parent);
  478     assert((File == nullptr || getASTFile() == nullptr ||
  503     assert(File);
tools/clang/include/clang/Basic/OpenCLOptions.h
   79     assert(!Ext.empty() && "Extension is empty.");
tools/clang/include/clang/Basic/PartialDiagnostic.h
  140       assert(Allocator != reinterpret_cast<StorageAllocator *>(~uintptr_t(0)));
  275     assert(DiagStorage->NumDiagArgs < Storage::MaxArguments &&
  285     assert(DiagStorage->NumDiagArgs < Storage::MaxArguments &&
  338     assert(DiagStorage && "No diagnostic storage?");
  339     assert(I < DiagStorage->NumDiagArgs && "Not enough diagnostic args");
  340     assert(DiagStorage->DiagArgumentsKind[I]
tools/clang/include/clang/Basic/PlistSupport.h
   46   assert(I != FIDs.end());
  127   assert(R.isCharRange() && "cannot handle a token range");
tools/clang/include/clang/Basic/Sanitizers.h
  153     assert(K.isPowerOf2() && "Has to be a single sanitizer.");
  162     assert(K.isPowerOf2() && "Has to be a single sanitizer.");
tools/clang/include/clang/Basic/SourceLocation.h
  116     assert((ID & MacroIDBit) == 0 && "Ran out of source locations!");
  123     assert((ID & MacroIDBit) == 0 && "Ran out of source locations!");
  133     assert(((getOffset()+Offset) & MacroIDBit) == 0 && "offset overflow");
  306     assert(isValid());
  311     assert(isValid());
  319     assert(isValid());
  327     assert(isValid());
  335     assert(isValid());
  357       assert(hasSrcMgr == isValid() && "FullSourceLoc has location but no manager");
  363     assert(SrcMgr && "SourceManager is NULL.");
  412     assert(Loc.isValid());
  413     assert(SrcMgr == Loc.SrcMgr && "Loc comes from another SourceManager!");
tools/clang/include/clang/Basic/SourceManager.h
  167       assert(RHS.Buffer.getPointer() == nullptr &&
  456       assert(isFile() && "Not a file SLocEntry!");
  461       assert(isExpansion() && "Not a macro expansion SLocEntry!");
  466       assert(!(Offset & (1u << 31)) && "Offset is too large");
  475       assert(!(Offset & (1u << 31)) && "Offset is too large");
  560     assert(LHS != RHS);
  816     assert(PreambleFileID.isInvalid() && "PreambleFileID already set!");
  836     assert(IR && "getOrCreateContentCache() cannot return NULL");
  846     assert(IR && "getOrCreateContentCache() cannot return NULL");
 1075     assert((Force || Entry.getFile().NumCreatedFIDs == 0) && "Already set!");
 1339     assert(((Start.getOffset() < NextLocalOffset &&
 1682     assert(Index < LocalSLocEntryTable.size() && "Invalid index");
 1692     assert(Index < LoadedSLocEntryTable.size() && "Invalid index");
 1710     assert(LoadedSLocEntryTable.empty() &&
 1736     assert(FID.ID != -1 && "Using FileID sentinel value");
 1776     assert(ID != -1 && "Using FileID sentinel value");
 1900     assert(SourceMgr);
tools/clang/include/clang/Basic/SourceManagerInternals.h
  104     assert(ID < FilenamesByID.size() && "Invalid FilenameID");
tools/clang/include/clang/Basic/TargetInfo.h
  219     assert(TargetOpts && "Missing target options");
  876       assert(hasTiedOperand() && "Has no tied operand!");
  996     assert(DataLayout && "Uninitialized DataLayout!");
 1174     assert(RegParmMax < 7 && "RegParmMax value is larger than AST can handle");
tools/clang/include/clang/Basic/Visibility.h
   63     assert(getLinkage() == L && getVisibility() == V &&
tools/clang/include/clang/Basic/XRayInstr.h
   47     assert(llvm::isPowerOf2_32(K));
   54     assert(llvm::isPowerOf2_32(K));
tools/clang/include/clang/CodeGen/CGFunctionInfo.h
  103     assert(canHavePaddingType());
  108     assert(isCoerceAndExpand());
  136     assert(Ty->isIntegralOrEnumerationType() && "Unexpected QualType");
  146     assert(Ty->isIntegralOrEnumerationType() && "Unexpected QualType");
  158     assert(Ty->isIntegralOrEnumerationType() && "Unexpected QualType");
  217     assert(!unpaddedStruct || unpaddedStruct->getNumElements() != 1);
  225         assert(unpaddedStruct->getElementType(unpaddedIndex) == eltType);
  227         assert(unpaddedIndex == 0 && unpaddedCoerceToType == eltType);
  234       assert(unpaddedStruct->getNumElements() == unpaddedIndex);
  236       assert(unpaddedIndex == 1);
  248       assert(eltType->getArrayElementType()->isIntegerTy(8));
  270     assert((isDirect() || isExtend()) && "Not a direct or extend kind");
  274     assert((isDirect() || isExtend()) && "Not a direct or extend kind");
  279     assert(isExtend() && "Invalid kind!");
  283     assert(isExtend() && "Invalid kind!");
  299     assert(canHaveCoerceToType() && "Invalid kind!");
  304     assert(canHaveCoerceToType() && "Invalid kind!");
  309     assert(isCoerceAndExpand());
  314     assert(isCoerceAndExpand());
  319     assert(isCoerceAndExpand());
  329     assert((isDirect() || isExtend() || isIndirect()) && "Invalid kind!");
  334     assert((isDirect() || isExtend() || isIndirect()) && "Invalid kind!");
  340     assert(isIndirect() && "Invalid kind!");
  344     assert(isIndirect() && "Invalid kind!");
  349     assert(isIndirect() && "Invalid kind!");
  353     assert(isIndirect() && "Invalid kind!");
  358     assert(isIndirect() && "Invalid kind!");
  362     assert(isIndirect() && "Invalid kind!");
  367     assert(isIndirect() && "Invalid kind!");
  371     assert(isIndirect() && "Invalid kind!");
  376     assert(isInAlloca() && "Invalid kind!");
  380     assert(isInAlloca() && "Invalid kind!");
  387     assert(isInAlloca() && "Invalid kind!");
  392     assert(isInAlloca() && "Invalid kind!");
  397     assert(isDirect() && "Invalid kind!");
  402     assert(isDirect() && "Invalid kind!");
  420     assert(n != ~0U);
  457     assert(allowsOptionalArgs());
  642     assert(argIndex <= NumArgs);
tools/clang/include/clang/CodeGen/ConstantInitBuilder.h
   72     assert(Buffer.empty() && "didn't claim all values out of buffer");
   73     assert(SelfReferences.empty() && "didn't apply all self-references");
  120       assert(!parent->Frozen && "parent already has child builder active");
  123       assert(!builder.Frozen && "builder already has child builder active");
  129     assert(Finished && "didn't finish aggregate builder");
  133     assert(!Frozen && "child builder still active");
  134     assert(!Finished && "builder already finished");
  137       assert(Parent->Frozen &&
  141       assert(Builder.Frozen &&
  168     assert(!this->Finished && "cannot query after finishing builder");
  169     assert(!this->Frozen && "cannot query while sub-builder is active");
  170     assert(this->Begin <= this->getBuffer().size());
  187     assert(value && "adding null value to constant initializer");
  188     assert(!Finished && "cannot add more values after finishing builder");
  189     assert(!Frozen && "cannot add values while subbuilder is active");
  214     assert(!Finished && "cannot add more values after finishing builder");
  215     assert(!Frozen && "cannot add values while subbuilder is active");
  250     assert(!Finished && "cannot add more values after finishing builder");
  251     assert(!Frozen && "cannot add values while subbuilder is active");
  272     assert(!Finished && "cannot add more values after finishing builder");
  273     assert(!Frozen && "cannot add values while subbuilder is active");
  290     assert(!Finished && "cannot change values after finishing builder");
  291     assert(!Frozen && "cannot add values while subbuilder is active");
  293     assert(slot == nullptr && "placeholder already filled");
  361     assert(this->Parent == &parent && "adding to non-parent builder");
  370     assert(!this->Parent && "finishing non-root builder");
  379     assert(!this->Parent && "finishing non-root builder");
tools/clang/include/clang/CodeGen/ConstantInitFuture.h
   60     assert(initializer && "creating null future");
tools/clang/include/clang/CodeGen/SwiftCallingConv.h
   74     assert(Finished && "didn't finish lowering before calling empty()");
tools/clang/include/clang/Driver/Compilation.h
  166     assert(TCs.first != TCs.second &&
  168     assert(std::next(TCs.first) == TCs.second &&
  175     assert(OffloadKind != Action::OFK_Host && OffloadKind != Action::OFK_None &&
tools/clang/include/clang/Driver/Multilib.h
   46     assert(GCCSuffix.empty() ||
   57     assert(OSSuffix.empty() ||
   68     assert(IncludeSuffix.empty() ||
   93     assert(F.front() == '+' || F.front() == '-');
tools/clang/include/clang/Driver/ToolChain.h
  228     assert(!EffectiveTriple.getTriple().empty() && "No effective triple");
tools/clang/include/clang/Frontend/ASTUnit.h
  457     assert(TheSema && "ASTUnit does not have a Sema object!");
  462     assert(LangOpts && "ASTUnit does not have language options");
  467     assert(HSOpts && "ASTUnit does not have header search options");
  472     assert(PPOpts && "ASTUnit does not have preprocessor options");
  503     assert(!isMainFileAST() && "Invalid call for AST based ASTUnit!");
  510     assert(!isMainFileAST() && "Invalid call for AST based ASTUnit!");
  517     assert(!isMainFileAST() && "Invalid call for AST based ASTUnit!");
  522     assert(!isMainFileAST() && "Invalid call for AST based ASTUnit!");
tools/clang/include/clang/Frontend/CompilerInstance.h
  237     assert(Invocation && "Compiler instance has no invocation!");
  342     assert(Diagnostics && "Compiler instance has no diagnostics!");
  350     assert(Diagnostics && Diagnostics->getClient() &&
  377     assert(Target && "Compiler instance has no target!");
  409     assert(FileMgr && "Compiler instance has no file manager!");
  429     assert(SourceMgr && "Compiler instance has no source manager!");
  449     assert(PP && "Compiler instance has no preprocessor!");
  469     assert(Context && "Compiler instance has no AST context!");
  492     assert(Consumer && "Compiler instance has no AST consumer!");
  510     assert(TheSema && "Compiler instance has no Sema object!");
  535     assert(Invocation && "cannot determine module format without invocation");
  549     assert(Invocation && "cannot determine module format without invocation");
  567     assert(CompletionConsumer &&
  583     assert(FrontendTimer && "Compiler instance has no frontend timer!");
tools/clang/include/clang/Frontend/FrontendAction.h
  120     assert(Instance && "Compiler instance not registered!");
  131     assert(!CurrentInput.isEmpty() && "No current file!");
  140     assert(!CurrentInput.isEmpty() && "No current file!");
  145     assert(!CurrentInput.isEmpty() && "No current file!");
  152     assert(!CurrentInput.isEmpty() && "No current file!");
  157     assert(CurrentASTUnit && "No current AST unit!");
tools/clang/include/clang/Frontend/FrontendOptions.h
  216     assert(isFile());
  221     assert(isBuffer());
tools/clang/include/clang/Frontend/VerifyDiagnosticConsumer.h
  224       assert(!DirectiveLoc.isInvalid() && "DirectiveLoc is invalid!");
  225       assert((!DiagnosticLoc.isInvalid() || MatchAnyLine) &&
  272     assert((!SrcManager || SrcManager == &SM) && "SourceManager changed!");
tools/clang/include/clang/Lex/HeaderSearch.h
  272     assert(angledDirIdx <= systemDirIdx && systemDirIdx <= dirs.size() &&
  313     assert(IncludeAliases && "Trying to map headers when there's no map");
tools/clang/include/clang/Lex/Lexer.h
  195     assert(LexingRawMode && "Not already in raw mode!");
  213     assert((!Val || LexingRawMode || LangOpts.TraditionalCPP) &&
  228     assert(!isKeepWhitespaceMode() &&
  270     assert(BufferPtr >= BufferStart && "Invalid buffer state");
tools/clang/include/clang/Lex/LiteralSupport.h
   87     assert(saw_ud_suffix);
   91     assert(saw_ud_suffix);
  197     assert(!UDSuffixBuf.empty() && "no ud-suffix");
  264     assert(!UDSuffixBuf.empty() && "no ud-suffix");
  269     assert(!UDSuffixBuf.empty() && "no ud-suffix");
tools/clang/include/clang/Lex/MacroInfo.h
  166     assert(ParameterList == nullptr && NumParameters == 0 &&
  236     assert(Tok < ReplacementTokens.size() && "Invalid token #");
  249     assert(
  261     assert(IsDisabled && "Cannot enable an already-enabled macro!");
  266     assert(!IsDisabled && "Cannot disable an already-disabled macro!");
  412     assert(MI && "MacroInfo is null");
  433     assert(UndefLoc.isValid() && "Invalid UndefLoc!");
tools/clang/include/clang/Lex/ModuleMap.h
  565     assert(!ExistingModule->Parent && "expected top-level module");
  566     assert(ModuleScopeIDs.count(ExistingModule) && "unknown module");
tools/clang/include/clang/Lex/PreprocessingRecord.h
  479       assert(end <= LoadedPreprocessedEntities.size());
tools/clang/include/clang/Lex/Preprocessor.h
   92     assert(Kind != tok::raw_identifier && "Raw identifiers are not supported.");
   93     assert(Kind != tok::identifier &&
   95     assert(!tok::isLiteral(Kind) && "Literals are not supported.");
   96     assert(!tok::isAnnotation(Kind) && "Annotations are not supported.");
 1443     assert(LexLevel == 0 && "cannot use lookahead while lexing");
 1456     assert(isBacktrackEnabled() &&
 1458     assert(signed(CachedLexPos) - signed(N) >= signed(BacktrackPositions.back())
 1460     assert(signed(CachedLexPos) - signed(N) >= 0 &&
 1480       assert(IsReinject && "new tokens in the middle of cached stream");
 1494     assert(Tok.isAnnotation() && "Expected annotation token");
 1502     assert(CachedLexPos != 0);
 1526     assert(Tok.isAnnotation() && "Expected annotation token");
 1538     assert(Tok.getIdentifierInfo() && "Expected identifier token");
 1595     assert(isCodeCompletionEnabled() && "Code-completion not enabled!");
 1721     assert(Tok.is(tok::numeric_constant) &&
 1723     assert(!Tok.needsCleaning() && "Token can't need cleaning with length 1");
 1989     assert(CurLexerKind != CLK_CachingLexer && "cannot push a caching lexer");
 2136     assert(PredefinesFileID.isInvalid() && "PredefinesFileID already set!");
 2202       assert((AK == None || Mod) && "no module for module action");
tools/clang/include/clang/Lex/PreprocessorLexer.h
  118     assert(!ConditionalStack.empty() && "No conditionals active!");
  147     assert(PP &&
tools/clang/include/clang/Lex/Token.h
  130     assert(!isAnnotation() && "Annotation tokens have no length field");
  136     assert(!isAnnotation() && "Annotation tokens have no length field");
  141     assert(isAnnotation() && "Used AnnotEndLocID on non-annotation token");
  145     assert(isAnnotation() && "Used AnnotEndLocID on non-annotation token");
  180     assert(isNot(tok::raw_identifier) &&
  182     assert(!isAnnotation() &&
  193     assert(is(tok::eof));
  197     assert(is(tok::eof));
  198     assert(!PtrData);
  206     assert(is(tok::raw_identifier));
  210     assert(is(tok::raw_identifier));
  218     assert(isLiteral() && "Cannot get literal data of non-literal");
  222     assert(isLiteral() && "Cannot set literal data of non-literal");
  227     assert(isAnnotation() && "Used AnnotVal on non-annotation token");
  231     assert(isAnnotation() && "Used AnnotVal on non-annotation token");
tools/clang/include/clang/Lex/VariadicMacroSupport.h
   39       assert(Ident__VA_ARGS__->isPoisoned() && "__VA_ARGS__ should be poisoned "
   42       assert(
   91       assert(!isInVAOpt() && "Must NOT be within VAOPT context to call this");
   97       assert(isInVAOpt() && "Must be within VAOPT context to call this");
  105       assert(isInVAOpt() && "Must be within VAOPT context to call this");
  112       assert(isInVAOpt() && "Must be within VAOPT context to call this");
  144       assert(!isReset() &&
  191       assert(!isReset() &&
  196       assert(!isReset() &&
  202       assert(!isReset() &&
  211       assert(!isReset() &&
  217       assert(hasStringifyBefore() &&
  224       assert(VAOptLoc.isFileID() && "Must not come from a macro expansion");
  225       assert(isReset() && "Must only be called if the state has been reset");
  229       assert(NumOfTokensPriorToVAOpt > -1 &&
  234       assert(!isReset() &&
  236       assert(VAOptLoc.isValid() && "__VA_OPT__ location must be valid");
tools/clang/include/clang/Parse/Parser.h
  449     assert(!isTokenSpecial() &&
  459     assert(!isTokenSpecial() &&
  545     assert(Tok.isAnnotation() && "wrong consume method");
  555     assert(isTokenParen() && "wrong consume method");
  570     assert(isTokenBracket() && "wrong consume method");
  586     assert(isTokenBrace() && "wrong consume method");
  604     assert(isTokenStringLiteral() &&
  617     assert(Tok.is(tok::code_completion));
  858     assert(getLangOpts().ObjC);
  908       assert(isActive && "Parsing action was finished!");
  915       assert(isActive && "Parsing action was finished!");
  927       assert(!isActive && "Forgot to call Commit or Revert!");
 1333     assert(!ClassStack.empty() && "No lexed method stacks!");
 1352       assert(!Popped && "Nested class has already been popped");
 2397     assert(Tok.is(tok::l_square));
 2649       assert(!EnteredScope && "Already entered the scope!");
 2650       assert(SS.isSet() && "C++ scope was not set!");
 2661         assert(SS.isSet() && "C++ scope was cleared ?");
tools/clang/include/clang/Parse/RAIIObjectsForParser.h
   69       assert(Active && "trying to end an inactive suppression");
   75       assert(!Active && "redelaying without having ended first");
   78       assert(DiagnosticPool.pool_empty());
  150       assert(!Popped && "ParsingDeclaration has already been popped!");
tools/clang/include/clang/Rewrite/Core/RewriteRope.h
   40       assert(RefCount > 0 && "Reference count is already zero.");
  197     assert(Offset <= size() && "Invalid position to insert!");
  203     assert(Offset+NumBytes <= size() && "Invalid region to erase!");
tools/clang/include/clang/Rewrite/Core/TokenRewriter.h
   64       assert(I != token_end() && "Cannot insert after token_end()!");
tools/clang/include/clang/Sema/CXXFieldCollector.h
   62     assert(!FieldCount.empty() && "no currently-parsed class");
tools/clang/include/clang/Sema/CodeCompleteConsumer.h
  602     assert(I < size() && "Chunk index out-of-range");
  659     assert(AllocatorRef);
  921     assert(((Kind == RK_Declaration) || (Kind == RK_Pattern)) &&
  928     assert(Kind == RK_Keyword && "Not a keyword result");
 1057       assert(getKind() == CK_FunctionTemplate && "Not a function template");
tools/clang/include/clang/Sema/DeclSpec.h
  200     assert(R.isValid() && "Must have a valid source range");
  483     assert(isTypeRep((TST) TypeSpecType) && "DeclSpec does not store a type");
  487     assert(isDeclRep((TST) TypeSpecType) && "DeclSpec does not store a decl");
  491     assert(isExprRep((TST) TypeSpecType) && "DeclSpec does not store an expr");
  510     assert(isDeclRep((TST) TypeSpecType) || TypeSpecType == TST_typename);
  689     assert(isDeclRep((TST) TypeSpecType));
  693     assert(isTypeRep((TST) TypeSpecType));
  697     assert(isExprRep((TST) TypeSpecType));
  862     assert(((getObjCDeclQualifier() & DQ_CSNullability) ||
  869     assert(((getObjCDeclQualifier() & DQ_CSNullability) ||
  876     assert(((getObjCDeclQualifier() & DQ_CSNullability) ||
 1432       assert(MethodQualifiers);
 1438       assert(MethodQualifiers);
 1444       assert(MethodQualifiers);
 1474       assert(ExceptionSpecType != EST_None);
 1481       assert(ExceptionSpecType == EST_None);
 2190     assert(i < DeclTypeInfo.size() && "Invalid type chunk");
 2194     assert(i < DeclTypeInfo.size() && "Invalid type chunk");
 2207     assert(!DeclTypeInfo.empty() && "No type chunks to drop.");
 2279     assert(isFunctionDeclarator() && "Not a function declarator!");
tools/clang/include/clang/Sema/DelayedDiagnostic.h
   90     assert(!IsMember); return cast<CXXRecordDecl>(Target);
  105     assert(isQuiet() && "partial diagnostic already defined");
  109     assert(isQuiet() && "partial diagnostic already defined");
  110     assert(DiagID && "creating null diagnostic");
  174     assert(Kind == Access && "Not an access diagnostic.");
  178     assert(Kind == Access && "Not an access diagnostic.");
  183     assert(Kind == Availability && "Not an availability diagnostic.");
  192     assert(Kind == Availability && "Not an availability diagnostic.");
  197     assert(Kind == Availability && "Not an availability diagnostic.");
  203     assert(Kind == Availability && "Not an availability diagnostic.");
  212     assert(Kind == ForbiddenType && "not a forbidden-type diagnostic");
  217     assert(Kind == ForbiddenType && "not a forbidden-type diagnostic");
  222     assert(Kind == ForbiddenType && "not a forbidden-type diagnostic");
  331   assert(shouldDelayDiagnostics() && "trying to delay without pool");
tools/clang/include/clang/Sema/Designator.h
   74     assert(isFieldDesignator() && "Invalid accessor");
   79     assert(isFieldDesignator() && "Invalid accessor");
   84     assert(isFieldDesignator() && "Invalid accessor");
   89     assert(isArrayDesignator() && "Invalid accessor");
   94     assert(isArrayRangeDesignator() && "Invalid accessor");
   98     assert(isArrayRangeDesignator() && "Invalid accessor");
  103     assert((isArrayDesignator() || isArrayRangeDesignator()) &&
  112     assert((isArrayDesignator() || isArrayRangeDesignator()) &&
  121     assert(isArrayRangeDesignator() && "Invalid accessor");
  160     assert((isArrayDesignator() || isArrayRangeDesignator()) &&
  194     assert(Idx < Designators.size());
tools/clang/include/clang/Sema/IdentifierResolver.h
   89       assert((Ptr & 0x1) == 0 && "Invalid Ptr!");
  101       assert(isIterator() && "Ptr not an iterator!");
  196     assert((reinterpret_cast<uintptr_t>(Ptr) & 0x1) == 1
tools/clang/include/clang/Sema/Initialization.h
  447     assert(isParameterKind() && "Not a parameter");
  453     assert(getKind() == EK_Base && "Not a base specifier");
  459     assert(getKind() == EK_Base && "Not a base specifier");
  484     assert(getKind() == EK_Result && "No 'return' location!");
  491     assert(getKind() == EK_Exception && "No 'throw' location!");
  498     assert(getKind() == EK_ArrayElement || getKind() == EK_VectorElement ||
  506     assert(getKind() == EK_ArrayElement || getKind() == EK_VectorElement ||
  513     assert(getKind() == EK_LambdaCapture && "Not a lambda capture!");
  520     assert(getKind() == EK_LambdaCapture && "Not a lambda capture!");
  723     assert(Kind == IK_Copy && "Only copy initialization has an '='");
  751     assert(hasParenOrBraceRange() && "Only direct, value, and direct-list "
 1345     assert((Failure != FK_Incomplete || !FailedIncompleteType.isNull()) &&
 1374     assert(Failed() && "Not an initialization failure!");
tools/clang/include/clang/Sema/Lookup.h
  322     assert(sanity());
  327     assert(isAmbiguous());
  453     assert(ResultKind == NotFound && Decls.empty());
  497         assert(WasAmbiguous);
  518     assert(getResultKind() == Found
  525     assert(!Decls.empty() && "cannot get representative of empty set");
  635       assert(CalledDone &&
  644       assert(I != Results.end() && "next() called on empty filter");
  673       assert(!CalledDone && "done() called twice");
tools/clang/include/clang/Sema/Overload.h
  333       assert(Idx < 3 && "To type index is out of range");
  348       assert(Idx < 3 && "To type index is out of range");
  597       assert(isInitialized() && "querying uninitialized conversion");
  995       assert(uintptr_t(FreeSpaceStart) % alignof(void *) == 0 &&
 1054       assert((Conversions.empty() || Conversions.size() == NumConversions) &&
 1090       assert((Kind == CSK_InitByConstructor ||
tools/clang/include/clang/Sema/Ownership.h
  199       assert((PtrWithInvalid & 0x01) == 0 && "Badly aligned pointer");
  228       assert((PtrWithInvalid & 0x01) == 0 && "Badly aligned pointer");
  289     assert(!R.isInvalid() && "operation was asserted to never fail!");
  294     assert(!R.isInvalid() && "operation was asserted to never fail!");
tools/clang/include/clang/Sema/ParsedAttr.h
  318     assert(IsProperty);
  322     assert(IsProperty);
  350     assert(hasProcessingCache());
  375     assert(Arg < NumArgs && "Arg access out of range!");
  396     assert(getParsedKind() == AT_Availability &&
  402     assert(getParsedKind() == AT_Availability &&
  408     assert(getParsedKind() == AT_Availability &&
  414     assert(getParsedKind() == AT_Availability &&
  420     assert(getParsedKind() == AT_Availability &&
  426     assert(getParsedKind() == AT_Availability &&
  432     assert(getParsedKind() == AT_Availability &&
  438     assert(getParsedKind() == AT_TypeTagForDatatype &&
  444     assert(getParsedKind() == AT_TypeTagForDatatype &&
  450     assert(getParsedKind() == AT_TypeTagForDatatype &&
  456     assert(HasParsedType && "Not a type attribute");
  461     assert(isDeclspecPropertyAttribute() &&
  467     assert(isDeclspecPropertyAttribute() &&
  488     assert(hasMacroIdentifier() && "Can only get the macro expansion location "
  616     assert(llvm::is_contained(Attrs, attr) &&
  739     assert(newAttr);
  744     assert(is_contained(AttrList, ToBeRemoved) &&
  792     assert(!empty());
  796     assert(!empty());
  800     assert(!empty());
  804     assert(!empty());
tools/clang/include/clang/Sema/ParsedTemplate.h
   77       assert(Kind == Type && "Not a template type argument");
   83       assert(Kind == NonType && "Not a non-type template argument");
   89       assert(Kind == Template && "Not a template template argument");
   99       assert(Kind == Template &&
  107       assert(Kind == Template &&
tools/clang/include/clang/Sema/Scope.h
  277     assert(isFunctionPrototypeScope());
  348       assert(FnS->getParent() && "TUScope not created?");
  416       assert(isOpenMPDirectiveScope() &&
tools/clang/include/clang/Sema/ScopeInfo.h
  449     assert(FirstCoroutineStmtLoc.isInvalid() &&
  459     assert(FirstCoroutineStmtLoc.isValid()
  471     assert((!value || CoroutineSuspends.first == nullptr) &&
  481     assert(Initial && Final && "suspend points cannot be null");
  482     assert(CoroutineSuspends.first == nullptr && "suspend points already set");
  605     assert(isVariableCapture());
  610     assert(isVLATypeCapture());
  682     assert(isCXXThisCaptured() && "this has not been captured");
  697     assert(isCaptured(Var) && "Variable has not been captured");
  704     assert(Known != CaptureMap.end() && "Variable has not been captured");
  923     assert(isa<DeclRefExpr>(VarExpr) || isa<MemberExpr>(VarExpr) ||
  976     assert(isa<DeclRefExpr>(CapturingVarExpr) ||
  982     assert(isa<DeclRefExpr>(CapturingVarExpr) ||
 1022   assert(E);
tools/clang/include/clang/Sema/Sema.h
  355       assert(Old->isExternallyDeclarable() &&
  491       assert((Action == PSK_Push || Action == PSK_Pop) &&
  773       assert(CurPool == nullptr);
  792       assert(ContextToPush && "pushing null context");
  836         assert(isa<ObjCMethodDecl>(DC));
  840       assert(!PushedCodeSynthesisContext);
 1671       assert(DiagID != 0 && "no diagnostic for type diagnoser");
 1985       assert(Kind == NC_ContextIndependentExpr);
 1990       assert(Kind == NC_Type);
 1995       assert(Kind == NC_NonType);
 2000       assert(Kind == NC_TypeTemplate || Kind == NC_FunctionTemplate ||
 5187       assert(!isComputedNoexcept(ComputedEST) &&
 7791       assert(Kind != DeclaringSpecialMember);
 8100     assert(!ExprEvalContexts.empty() &&
 8226       assert(S.VTableUses.empty() &&
 8231       assert(S.PendingInstantiations.empty() &&
 8262       assert(S.PendingLocalImplicitInstantiations.empty() &&
 8283       assert(Infos.size() <= index);
11548       assert(S.DelayedOverridingExceptionSpecChecks.empty() &&
11550       assert(S.DelayedEquivalentExceptionSpecChecks.empty() &&
11552       assert(S.DelayedDllExportClasses.empty() &&
tools/clang/include/clang/Sema/SemaInternal.h
   55   assert(!(D->hasAttr<DLLImportAttr>() && D->hasAttr<DLLExportAttr>()) &&
  256         assert(!Set.DistanceMap.empty());
tools/clang/include/clang/Sema/Template.h
  100       assert(NumRetainedOuterLevels <= Depth && Depth < getNumLevels());
  101       assert(Index < TemplateArgumentLists[getNumLevels() - Depth - 1].size());
  110       assert(Depth < getNumLevels());
  124       assert(NumRetainedOuterLevels <= Depth && Depth < getNumLevels());
  125       assert(Index < TemplateArgumentLists[getNumLevels() - Depth - 1].size());
  141       assert(!NumRetainedOuterLevels &&
  403       assert(PartiallySubstitutedPack && "No partially-substituted pack");
tools/clang/include/clang/Sema/TemplateDeduction.h
   93     assert(HasSFINAEDiagnostic);
  107     assert(HasSFINAEDiagnostic);
tools/clang/include/clang/Serialization/ASTBitCodes.h
  126         assert(!T.getLocalFastQualifiers() &&
 2108         assert(Kind == DeclarationName::Identifier ||
 2115         assert(Kind == DeclarationName::ObjCZeroArgSelector ||
 2122         assert(Kind == DeclarationName::CXXOperatorName);
tools/clang/include/clang/Serialization/ASTReader.h
 1412       assert(Reader == RHS.Reader && Mod == RHS.Mod);
 1432     assert(D);
 2204     assert(ModuleFile.SLocRemap.find(Loc.getOffset()) !=
 2275     assert(ReadingKind == Read_Stmt &&
 2279     assert(!StmtStack.empty() && "Read too many sub-statements!");
 2320     assert(ContextObj && "requested AST context when not loading AST");
tools/clang/include/clang/Serialization/ASTWriter.h
  183       assert(isType() && "Not a type!");
  188       assert(isDecl() && "Not a decl!");
  770       assert(StoredOffset < MyOffset && "invalid offset");
tools/clang/include/clang/Serialization/ContinuousRangeMap.h
   70     assert((Rep.empty() || Rep.back().first < Val.first) &&
  125         assert((A == B || A.first != B.first) &&
tools/clang/include/clang/Serialization/Module.h
   78     assert(!(isOverridden && isOutOfDate) &&
tools/clang/include/clang/StaticAnalyzer/Core/AnalyzerOptions.h
  296     assert(std::is_sorted(AnalyzerConfigCmdFlags.begin(),
  412   assert(K.hasValue() && "User mode is invalid.");
tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporter.h
  223     assert((R.isValid() || Ranges.empty()) && "Invalid range can only be used "
  264     assert(Location.isValid());
  396     assert(errorNode);
  552     assert(!Reports.empty());
tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugReporterVisitors.h
  154     assert(R);
tools/clang/include/clang/StaticAnalyzer/Core/BugReporter/BugType.h
   59     assert(!Ret.empty() && "Checker name is not set properly.");
tools/clang/include/clang/StaticAnalyzer/Core/CheckerManager.h
  164     assert(!ref && "Checker already registered, use getChecker!");
  177     assert(CheckerTags.count(tag) != 0 &&
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/BasicValueFactory.h
   47     assert(NonLoc::isCompoundType(t));
   68     assert(NonLoc::isCompoundType(r->getValueType()));
  142     assert(T->isIntegralOrEnumerationType() || Loc::isLocType(T));
  200     assert(T->isScalarType());
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h
  580     assert(isConversionFromLambda());
  582     assert(BR && "Block converted from lambda must have a block region");
  585     assert(I != BR->referenced_vars_end());
 1244   assert(isa<T>(*this) && "Cloning to unrelated type");
 1254   assert(Copy->getKind() == this->getKind() && "Bad copy");
 1261   assert(RefCount > 0 && "Reference count is already zero.");
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CheckerContext.h
   51     assert(Pred->getState() &&
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/CoreEngine.h
  213       : Eng(E), Block(B), LC(N->getLocationContext()) { assert(B); }
  283     assert(hasNoSinksInFrontier());
  308     assert(checkResults());
  317     assert(checkResults());
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExplodedGraph.h
   92       assert(getFlag() == Flag);
  140     assert(isSink() == IsSink);
  469     assert(N && !static_cast<ExplodedNode*>(N)->isSink());
  489     assert(&S != this);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
  204     assert(currBldrCtx);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/FunctionSummary.h
   69     assert(I != Map.end());
   99     assert(ID < TotalIDs);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/MemRegion.h
   82     assert(!hasSymbolicOffset());
  204     assert(classof(this));
  205     assert(mgr);
  242     assert(classof(this));
  264     assert(cr);
  291     assert(classof(this));
  390     assert(classof(this));
  391     assert(sfc);
  443     assert(classof(this));
  444     assert(sReg);
  483     assert(Ex);
  511     assert(classof(this));
  535     assert(classof(this));
  568     assert(classof(this));
  588     assert(isa<ObjCMethodDecl>(fd) || isa<FunctionDecl>(fd));
  601     assert(isa<ObjCMethodDecl>(FD));
  602     assert(false && "Getting the type of ObjCMethod is not supported yet");
  638     assert(bd);
  639     assert(ac);
  640     assert(lTy->getTypePtr()->isBlockPointerType());
  686     assert(bc);
  687     assert(lc);
  688     assert(isa<GlobalImmutableSpaceRegion>(sreg) ||
  722       assert((R == nullptr) == (I.R == nullptr));
  727       assert((R == nullptr) == (I.R == nullptr));
  773     assert(s && isa<SymbolData>(s));
  774     assert(s->getType()->isAnyPointerType() ||
  777     assert(isa<UnknownSpaceRegion>(sreg) || isa<HeapSpaceRegion>(sreg));
  808     assert(str);
  844     assert(str);
  880     assert(cl);
  881     assert(isa<GlobalInternalSpaceRegion>(sReg) ||
  911     assert(classof(this));
  912     assert(d && d->isCanonicalDecl());
  938     assert(isa<GlobalsSpaceRegion>(sReg) || isa<StackSpaceRegion>(sReg) ||
  980     assert(ThisPointerTy->getPointeeType()->getAsCXXRecordDecl() &&
 1092     assert((!Idx.getAs<nonloc::ConcreteInt>() ||
 1095     assert(!elementType.isNull() && !elementType->isVoidType() &&
 1129     assert(E);
 1130     assert(isa<StackLocalsSpaceRegion>(sReg) ||
 1161     assert(RD);
 1198     assert(DerivedD);
 1202     assert(SReg->getSymbolicBase() &&
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ProgramState.h
  682   assert(Val.getAs<NonLoc>() && "Only NonLocs are supported!");
  695   assert(Val.getAs<NonLoc>() && "Only NonLocs are supported!");
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/RangedConstraintManager.h
   31     assert(from <= to);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SMTConstraintManager.h
  115       assert(!Ty->isRealFloatingType());
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SMTConv.h
   77     assert(!ASTs.empty());
   95     assert(*Solver->getSort(LHS) == *Solver->getSort(RHS) &&
  205     assert(*Solver->getSort(LHS) == *Solver->getSort(RHS) &&
  272         assert(ToBitWidth > 0 && "BitWidth must be positive!");
  527     assert(FromTy == ToTy && "Range values have different types!");
  571     assert(!LTy.isNull() && !RTy.isNull() && "Input type is null!");
  617         assert((Ctx.getTypeSize(LTy) == Ctx.getTypeSize(RTy)) &&
  650     assert(!LTy.isNull() && !RTy.isNull() && "Input type is null!");
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.h
  104     assert(T::isKind(*this));
  353     assert(sym);
  354     assert(!Loc::isLocType(sym->getType()));
  417     assert(data.first.getBaseKind() == LocKind &&
  577     assert(Label);
  601     assert(r);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/Store.h
  320   assert(&newStore.mgr == &mgr);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/StoreRef.h
   40     assert(&mgr == &x.mgr);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymExpr.h
  123     assert(classof(this));
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SymbolManager.h
   47     assert(r);
   48     assert(isValidTypeForSymbol(r->getValueType()));
   92     assert(lctx);
   93     assert(isValidTypeForSymbol(t));
  134     assert(parent);
  135     assert(r);
  136     assert(isValidTypeForSymbol(r->getValueType()));
  173     assert(r);
  214       assert(r);
  215       assert(s);
  216       assert(isValidTypeForSymbol(t));
  217       assert(LCtx);
  218       assert(tag);
  266     assert(In);
  267     assert(isValidTypeForSymbol(From));
  310     assert(classof(this));
  314     assert(isValidTypeForSymbol(t) && !Loc::isLocType(t));
  340     assert(lhs);
  383     assert(rhs);
  426     assert(lhs);
  427     assert(rhs);
tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/WorkList.h
   73     assert(N->getLocation().getKind() != ProgramPoint::PostStmtKind);
tools/clang/include/clang/StaticAnalyzer/Frontend/CheckerRegistry.h
  111       assert((OptionType == "bool" || OptionType == "string" ||
  115       assert((OptionType != "bool" ||
  121       assert((OptionType != "int" || !DefaultValStr.getAsInteger(0, Tmp)) &&
  126       assert((DevelopmentStatus == "alpha" || DevelopmentStatus == "beta" ||
tools/clang/include/clang/Tooling/DependencyScanning/DependencyScanningFilesystem.h
   66     assert(!MaybeStat->isDirectory() && "not a file");
   67     assert(isValid() && "not initialized");
   73     assert(isValid() && "not initialized");
   79     assert(isValid() && "not initialized");
  163     assert(IsInserted && "local cache is updated more than once");
tools/clang/include/clang/Tooling/Refactoring/ASTSelection.h
  111       assert(I == 0 && "Invalid index");
tools/clang/include/clang/Tooling/Refactoring/RefactoringRuleContext.h
   48     assert(AST && "no AST!");
tools/clang/include/clang/Tooling/Refactoring/Rename/SymbolName.h
   35     assert(!Name.empty() && "Invalid symbol name!");
tools/clang/lib/ARCMigrate/ARCMT.cpp
  129     assert(!HasBegunSourceFile && "FinishCapture not called!");
  250   assert(!transforms.empty());
  260   assert(DiagClient);
  363   assert(!transforms.empty());
  396   assert(!outputDir.empty() && "Expected output directory path");
  405   assert(!outputDir.empty());
  533   assert(DiagClient);
  600     assert(file);
tools/clang/lib/ARCMigrate/FileRemapper.cpp
   35   assert(ToFromMappings.empty());
   43   assert(!outputDir.empty());
   57   assert(FromToMappings.empty() &&
  174     assert(I->second.is<llvm::MemoryBuffer *>());
  214   assert(file);
  221   assert(file && newfile);
  238     assert(FromToMappings.find(file) != FromToMappings.end() &&
tools/clang/lib/ARCMigrate/ObjCMT.cpp
  776   assert(!DesignatedEnumType.isNull()
 1436     assert(CFFunctionIBCandidates.empty() &&
 1801       assert(FID.isValid());
 1811       assert(Range.isCharRange());
 1816       assert(Begin.first == End.first);
 1817       assert(Begin.second <= End.second);
 1976     assert(file);
 2185     assert(Entry.File == FE);
tools/clang/lib/ARCMigrate/TransAutoreleasePool.cpp
  132           assert(afterSemi.isValid() &&
tools/clang/lib/ARCMigrate/TransEmptyStatementsAndDealloc.cpp
   50   assert(AfterMacroLoc.isFileID());
tools/clang/lib/ARCMigrate/TransProperties.cpp
  346     assert(!props.empty());
  351       assert(ty == I->PropD->getType().getUnqualifiedType());
  359     assert(!props.empty());
  365       assert(attrs == I->PropD->getPropertyAttributesAsWritten());
tools/clang/lib/ARCMigrate/TransProtectedScope.cpp
  132     assert(DiagI->getID() == diag::err_switch_into_protected_scope);
  147     assert(Diag.getLevel() == DiagnosticsEngine::Note);
  155         assert(info.State != CaseInfo::St_Unchecked);
  169     assert(info.State == CaseInfo::St_Unchecked);
tools/clang/lib/ARCMigrate/TransRetainReleaseDealloc.cpp
  411     assert(E);
tools/clang/lib/ARCMigrate/TransUnbridgedCasts.cpp
  248       assert(Kind == OBC_BridgeTransfer || Kind == OBC_BridgeRetained);
  283     assert(Loc.isMacroID());
  390       assert(subExpr && "no result for pseudo-object of non-void type?");
tools/clang/lib/ARCMigrate/TransformActions.cpp
   69       assert(beginLoc.isValid() && endLoc.isValid());
   77       assert(Begin.isValid() && End.isValid());
  184   assert(!IsInTransaction &&
  190   assert(IsInTransaction && "No transaction started");
  215       assert(act.S);
  279   assert(IsInTransaction && "No transaction started");
  285   assert(IsInTransaction && "Actions only allowed during a transaction");
  295   assert(IsInTransaction && "Actions only allowed during a transaction");
  305   assert(IsInTransaction && "Actions only allowed during a transaction");
  313   assert(IsInTransaction && "Actions only allowed during a transaction");
  323   assert(IsInTransaction && "Actions only allowed during a transaction");
  331   assert(IsInTransaction && "Actions only allowed during a transaction");
  352   assert(IsInTransaction && "Actions only allowed during a transaction");
  361   assert(IsInTransaction && "Actions only allowed during a transaction");
  371   assert(IsInTransaction && "Actions only allowed during a transaction");
  451   assert(S);
  468   assert(comp == Range_Contained);
  682   assert(!static_cast<TransformActionsImpl *>(Impl)->isInTransaction() &&
tools/clang/lib/AST/APValue.cpp
   71   assert(is<TypeInfoLValue>() && "not a type_info lvalue");
   76   assert(is<DynamicAllocLValue>() && "not a dynamic allocation lvalue");
  353     assert(getComplexFloatImag().needsCleanup() ==
  359     assert(getComplexIntImag().needsCleanup() ==
  558         assert(Base.get<const Expr *>() != nullptr &&
  592       assert(E != nullptr && "Expecting non-null Expr");
  661         assert(BI != CD->bases_end());
  734   assert(isLValue() && "Invalid accessor");
  739   assert(isLValue() && "Invalid accessor");
  744   assert(isLValue() && "Invalid accessor");
  749   assert(isLValue() && "Invalid accessor");
  754   assert(isLValue() && hasLValuePath() && "Invalid accessor");
  760   assert(isLValue() && "Invalid accessor");
  765   assert(isLValue() && "Invalid accessor");
  770   assert(isLValue() && "Invalid usage");
  776   assert(isLValue() && "Invalid accessor");
  788   assert(isLValue() && "Invalid accessor");
  799   assert(isMemberPointer() && "Invalid accessor");
  806   assert(isMemberPointer() && "Invalid accessor");
  813   assert(isMemberPointer() && "Invalid accessor");
  820   assert(isAbsent() && "Bad state change");
  827   assert(isAbsent() && "Bad state change");
  834   assert(isAbsent() && "Bad state change");
tools/clang/lib/AST/ASTContext.cpp
  106   assert(D);
  397       assert(CommentAtRedecl != DeclRawComments.end() &&
  413     assert(Redecl);
  438   assert(Comment.isDocumentation() || LangOpts.CommentOpts.ParseAllComments);
  485     assert(D);
  741   assert(!TTP->getTemplateParameters()->getRequiresClause() &&
  759   assert(!Canonical && "Shouldn't be in the map!");
 1062   assert(Source && "lazy initializers but no external source");
 1070   assert(LazyInitializers.empty() &&
 1197   assert((!this->Target || this->Target == &Target) &&
 1199   assert(VoidTy.isNull() && "Context reinitialized?");
 1416   assert(Var->isStaticDataMember() && "Not a static data member");
 1435   assert(Inst->isStaticDataMember() && "Not a static data member");
 1436   assert(Tmpl->isStaticDataMember() && "Not a static data member");
 1444   assert(!TemplateOrInstantiation[Inst] &&
 1460   assert((isa<UsingDecl>(Pattern) ||
 1464   assert((isa<UsingDecl>(Inst) ||
 1468   assert(!InstantiatedFromUsingDecl[Inst] && "pattern already exists");
 1485   assert(!InstantiatedFromUsingShadowDecl[Inst] && "pattern already exists");
 1500   assert(!Inst->getDeclName() && "Instantiated field decl is not unnamed");
 1501   assert(!Tmpl->getDeclName() && "Template field decl is not unnamed");
 1502   assert(!InstantiatedFromUnnamedFieldDecl[Inst] &&
 1535   assert(Method->isCanonicalDecl() && Overridden->isCanonicalDecl());
 1542   assert(D);
 1560   assert(!Import->NextLocalImport && "Import declaration already in the chain");
 1561   assert(!Import->isFromASTFile() && "Non-local import declaration");
 1723   assert((Size == 0 || static_cast<uint64_t>(EltInfo.first.getQuantity()) <=
 1833     assert((Size == 0 || EltInfo.Width <= (uint64_t)(-1) / Size) &&
 1968         assert(getLangOpts().OpenMP && getLangOpts().OpenMPIsDevice &&
 1999         assert(getLangOpts().OpenMP && getLangOpts().OpenMPIsDevice &&
 2138     assert(!A->getDeducedType().isNull() &&
 2187       assert(Align);
 2209   assert(llvm::isPowerOf2_32(Align) && "Alignment must be power of 2");
 2404   assert(RD->isUnion() && "Must be union type");
 2432   assert(!RD->isUnion() && "Must be struct/class type");
 2513   assert(!Ty.isNull() && "Null QualType sent to unique object rep check");
 2621   assert(IFaceD && ImplD && "Passed null params");
 2628   assert(CatD && ImplD && "Passed null params");
 2639   assert(!getObjCMethodRedeclaration(MD) && "MD already has a redeclaration");
 2659   assert(VD && "Passed null params");
 2660   assert(VD->hasAttr<BlocksAttr>() &&
 2671   assert(VD && CopyExpr && "Passed null params");
 2672   assert(VD->hasAttr<BlocksAttr>() &&
 2682     assert(DataSize == TypeLoc::getFullDataSizeForType(T) &&
 2723     assert(eq->getQualifiers() == quals);
 2756   assert(!Quals.hasAddressSpace() &&
 2805   assert(!Quals.hasObjCGCAttr() &&
 2907     assert(TypeLoc::getFullDataSizeForType(Updated) ==
 2934     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 2962     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 2982   assert(!AT && "Shouldn't be in the map!");
 2992   assert((T->isArrayType() || T->isFunctionType()) && "T does not decay");
 3022   assert(!AT && "Shouldn't be in the map!");
 3033   assert(T->isFunctionType() && "block of function types only");
 3053     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3065   assert(getCanonicalType(T) != OverloadTy &&
 3090     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3126     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3157     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3172   assert((EltTy->isDependentType() ||
 3207     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3392   assert((!numElements || numElements->isTypeDependent() ||
 3480     assert(!existing && "Shouldn't be in the map!"); (void) existing;
 3495   assert(vecType->isBuiltinType());
 3513     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3545       assert(!CanonCheck &&
 3565   assert(vecType->isBuiltinType() || vecType->isDependentType());
 3583     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3619       assert(!CanonCheck && "Dependent-sized ext_vector canonical type broken");
 3637   assert(AddrSpaceExpr->isInstantiationDependent());
 3698     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3804     assert(isCanonical &&
 3872     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 3913     assert(!NewIP && "Shouldn't be in the map!");
 3953   assert(NeedsInjectedClassNameType(Decl));
 3955     assert(isa<InjectedClassNameType>(Decl->TypeForDecl));
 3957     assert(PrevDecl->TypeForDecl && "previous declaration has no type");
 3959     assert(isa<InjectedClassNameType>(Decl->TypeForDecl));
 3972   assert(Decl && "Passed null for Decl param");
 3973   assert(!Decl->TypeForDecl && "TypeForDecl present in slow case");
 3978   assert(!isa<TemplateTypeParmDecl>(Decl) &&
 3982     assert(Record->isFirstDecl() && "struct/union has previous declaration");
 3983     assert(!NeedsInjectedClassNameType(Record));
 3986     assert(Enum->isFirstDecl() && "enum has previous declaration");
 4064   assert(Replacement.isCanonical()
 4089     assert(P.getKind() == TemplateArgument::Type &&"Pack contains a non-type");
 4090     assert(P.getAsType().isCanonical() && "Pack contains non-canonical type");
 4138     assert(!TypeCheck && "Template type parameter canonical type broken");
 4155   assert(!Name.getAsDependentTemplateName() &&
 4175   assert(!Template.getAsDependentTemplateName() &&
 4200   assert(!Template.getAsDependentTemplateName() &&
 4215     assert((!IsTypeAlias || hasAnyPackExpansions(Args)) &&
 4238   assert(!Template.getAsDependentTemplateName() &&
 4275   assert(Spec->isDependentType() &&
 4296     assert(!CheckT && "Elaborated canonical type broken");
 4323     assert(!CheckT && "Paren canonical type broken");
 4390   assert((!NNS || NNS->isDependent()) &&
 4488   assert((Pattern->containsUnexpandedParameterPack() ||
 4733     assert(!hasError && "Error when apply protocol qualifier to bound type");
 4850     assert(PrevDecl->TypeForDecl && "previous decl has no TypeForDecl");
 4987   assert((!IsPack || IsDependent) && "only use IsPack for a dependent pack");
 5048     assert(!NewIP && "Shouldn't be in the map!"); (void)NewIP;
 5070   assert(!AutoRRefDeductTy.isNull() && "can't build 'auto &&' pattern");
 5077   assert(Decl);
 5193     assert(quals.empty()); // from the recursive call
 5406     assert(DTN && "Non-dependent template names must refer to template decls.");
 5638   assert(PrettyArrayType && "Not an array type!");
 5719   assert(Domain->isRealFloatingType() && "Unknown domain!");
 5756   assert(T->isCanonicalUnqualified() && "T should be canonicalized");
 5846   assert(!Promotable.isNull());
 5847   assert(Promotable->isPromotableIntegerType());
 5883   assert(Promotable->isUnsignedIntegerType() && PromotableSize <= IntSize);
 5966   assert(!CFConstantStringTagDecl &&
 6344     assert(sz.isPositive() && "BlockExpr - Incomplete param type");
 6389     assert(sz.isPositive() &&
 6456     assert(sz.isPositive() &&
 6758   assert(FD->isBitField() && "not a bitfield - getObjCEncodingForTypeImpl");
 6925         assert((isa<VariableArrayType>(AT) || isa<IncompleteArrayType>(AT)) &&
 7144   assert(RDecl && "Expected non-null RecordDecl");
 7145   assert(!RDecl->isUnion() && "Should not be called for unions");
 7224     assert(CurOffs <= CurLayObj->first);
 7249       assert(!base->isEmpty());
 7673     assert(BuiltinVaListDecl->isImplicit());
 7700   assert(ObjCConstantStringType.isNull() &&
 7712   assert(size > 1 && "set is not overloaded!");
 7721     assert(isa<FunctionTemplateDecl>(D) ||
 7744   assert(NNS && "Missing nested-name-specifier in qualified template name");
 7767   assert((!NNS || NNS->isDependent()) &&
 7790     assert(!CheckQTN && "Dependent type name canonicalization broken");
 7803   assert((!NNS || NNS->isDependent()) &&
 7827     assert(!CheckQTN && "Dependent template name canonicalization broken");
 7906   assert(getLangOpts().ObjC);
 7924     assert(CT->isAnyPointerType() || CT->isBlockPointerType());
 7938   assert(LHS->isCanonicalUnqualified() && RHS->isCanonicalUnqualified());
 7945   assert(FirstVec->isVectorType() && "FirstVec should be a vector type");
 7946   assert(SecondVec->isVectorType() && "SecondVec should be a vector type");
 8087   assert(rhs->isObjCQualifiedIdType() && "One of the LHS/RHS should be id<x>");
 8266   assert(LHS->getInterface() && "LHS must have an interface base");
 8267   assert(RHS->getInterface() && "RHS must have an interface base");
 8505   assert(LHS->getInterface() && "LHS is not an interface type");
 8506   assert(RHS->getInterface() && "RHS is not an interface type");
 8721     assert(!lproto->hasExceptionSpec() && !rproto->hasExceptionSpec() &&
 8785     assert(!proto->hasExceptionSpec() && "C++ shouldn't be here");
 8852   assert(!LHS->getAs<ReferenceType>() && "LHS is a reference type?");
 8853   assert(!RHS->getAs<ReferenceType>() && "RHS is a reference type?");
 8886     assert((GC_L != GC_R) && "unequal qualifier sets had only equal elements");
 9161     assert(LHS != RHS &&
 9173   assert(NewParamInfos.empty() && "param info list not empty");
 9271     assert((GC_L != GC_R) && "unequal qualifier sets had only equal elements");
 9309   assert((T->hasSignedIntegerRepresentation() || T->isSignedFixedPointType()) &&
 9403       assert(!Unsigned && "Can't use both 'S' and 'U' modifiers!");
 9404       assert(!Signed && "Can't use 'S' modifier multiple times!");
 9408       assert(!Signed && "Can't use both 'S' and 'U' modifiers!");
 9409       assert(!Unsigned && "Can't use 'U' modifier multiple times!");
 9413       assert(!IsSpecial && "Can't use 'L' with 'W', 'N', 'Z' or 'O' modifiers");
 9414       assert(HowLong <= 2 && "Can't have LLLL modifier");
 9419       assert(!IsSpecial && "Can't use two 'N', 'W', 'Z' or 'O' modifiers!");
 9420       assert(HowLong == 0 && "Can't use both 'L' and 'N' modifiers!");
 9429       assert(!IsSpecial && "Can't use two 'N', 'W', 'Z' or 'O' modifiers!");
 9430       assert(HowLong == 0 && "Can't use both 'L' and 'W' modifiers!");
 9447       assert(!IsSpecial && "Can't use two 'N', 'W', 'Z' or 'O' modifiers!");
 9448       assert(HowLong == 0 && "Can't use both 'L' and 'Z' modifiers!");
 9467       assert(!IsSpecial && "Can't use two 'N', 'W', 'Z' or 'O' modifiers!");
 9468       assert(HowLong == 0 && "Can't use both 'L' and 'O' modifiers!");
 9486     assert(HowLong == 0 && !Signed && !Unsigned &&
 9491     assert(HowLong == 0 && !Signed && !Unsigned &&
 9496     assert(HowLong == 0 && !Signed && !Unsigned &&
 9501     assert(HowLong < 3 && !Signed && !Unsigned &&
 9511     assert(HowLong == 0 && "Bad modifiers used with 's'!");
 9528     assert(HowLong == 0 && "Bad modifiers used with 'c'!");
 9537     assert(HowLong == 0 && !Signed && !Unsigned && "Bad modifiers for 'b'!");
 9541     assert(HowLong == 0 && !Signed && !Unsigned && "Bad modifiers for 'z'!");
 9545     assert(HowLong == 0 && !Signed && !Unsigned && "Bad modifiers for 'w'!");
 9562     assert(!Type.isNull() && "builtin va list type not initialized!");
 9574     assert(!Type.isNull() && "builtin va list type not initialized!");
 9583     assert(End != Str && "Missing vector size");
 9588     assert(!RequiresICE && "Can't require vector ICE");
 9599     assert(End != Str && "Missing vector size");
 9611     assert(!RequiresICE && "Can't require complex ICE");
 9637     assert(HowLong == 0 && !Signed && !Unsigned && "Bad modifiers for 'K'!");
 9687   assert((!RequiresICE || Type->isIntegralOrEnumerationType()) &&
 9712   assert(!RequiresICE && "Result of intrinsic cannot be required to be an ICE");
 9734   assert((TypeStr[0] != '.' || TypeStr[1] == 0) &&
 9984     assert(getExternalSource() && "It's from an AST file; must have a source.");
10057   assert(VD->isFileVarDecl() && "Expected file scoped var");
10102   assert(FD->isMultiVersion() && "Only valid for multiversioned functions");
10262   assert(LangOpts.CPlusPlus);  // We don't need mangling numbers for plain C.
10271   assert(LangOpts.CPlusPlus); // We don't need mangling numbers for plain C.
10322   assert(I != ParamIndices.end() &&
10330   assert(E && E->getStorageDuration() == SD_Static &&
10568   assert(Ty->isFixedPointType());
10622   assert(Ty->isFixedPointType());
10668   assert(Ty->isFixedPointType());
10709   assert((Ty->isFixedPointType() || Ty->isIntegerType()) &&
10724   assert(Ty->isFixedPointType());
10729   assert(Ty->isFixedPointType());
10734   assert(Ty->isUnsignedFixedPointType() &&
tools/clang/lib/AST/ASTDiagnostic.cpp
  342       assert(Modifier.empty() && Argument.empty() &&
  384       assert(Modifier.empty() && Argument.empty() &&
  398         assert(Modifier.empty() && Argument.empty() &&
  409         assert(Modifier.empty() && Argument.empty() &&
  425       assert(DC && "Should never have a null declaration context");
  443         assert(isa<NamedDecl>(DC) && "Expected a NamedDecl");
  460       assert(At && "Received null Attr object!");
  601       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  612       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  621       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  630       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  642       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  659       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  676       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  693       assert(FlatTree[CurrentNode].Kind == Invalid && "Node is not empty.");
  708       assert((!FromDefault || !ToDefault) && "Both arguments cannot be default.");
  725       assert(FlatTree[CurrentNode].Kind != Invalid &&
  733       assert(FlatTree[CurrentNode].Kind == Template &&
  768       assert(FlatTree[ReadNode].Kind == Template && "Unexpected kind.");
  776       assert(FlatTree[ReadNode].Kind == Type && "Unexpected kind");
  782       assert(FlatTree[ReadNode].Kind == Expression && "Unexpected kind");
  788       assert(FlatTree[ReadNode].Kind == TemplateTemplate && "Unexpected kind.");
  797       assert(FlatTree[ReadNode].Kind == Integer && "Unexpected kind.");
  812       assert(FlatTree[ReadNode].Kind == Declaration && "Unexpected kind.");
  827       assert(FlatTree[ReadNode].Kind == FromDeclarationAndToInteger &&
  843       assert(FlatTree[ReadNode].Kind == FromIntegerAndToDeclaration &&
  963         assert(TST && "InternalIterator is invalid with a null TST.");
  969         assert(TST && "InternalIterator is invalid with a null TST.");
 1005         assert(TST && "InternalIterator is invalid with a null TST.");
 1006         assert(!isEnd() && "Index exceeds number of arguments.");
 1015         assert(TST && "InternalIterator is invalid with a null TST.");
 1062       assert(DesugaredIterator.isValid() &&
 1134       assert(FromArgTST && ToArgTST &&
 1294     assert((FromExpr || ToExpr) && "Both template arguments cannot be empty.");
 1321       assert(FromParamND->getKind() == ToParamND->getKind() &&
 1515         assert((FromValueDecl || FromNullPtr) && IsValidToInt);
 1533         assert(IsValidFromInt && (ToValueDecl || ToNullPtr));
 1595     assert(!IsBold && "Attempting to bold text that is already bold.");
 1603     assert(IsBold && "Attempting to remove bold from unbold text.");
 1616     assert((!FromType.isNull() || !ToType.isNull()) &&
 1668     assert((FromExpr || ToExpr) &&
 1703     assert((FromTD || ToTD) && "Only one template argument may be missing.");
 1738     assert((IsValidFromInt || IsValidToInt) &&
 1852     assert((FromValueDecl || FromNullPtr || ToValueDecl || ToNullPtr) &&
 2050     assert(!IsBold && "Bold is applied to end of string.");
tools/clang/lib/AST/ASTDumper.cpp
   97       assert(isa<CXXRecordDecl>(RedeclWithBadType) &&
tools/clang/lib/AST/ASTImporter.cpp
  686   assert(FromFD->getTemplatedKind() ==
  905   assert(D.isArrayRangeDesignator());
 1729       assert(D && "DC contains a null decl");
 1733         assert(ToDC == ToD->getLexicalDeclContext() && ToDC->containsDecl(ToD));
 1768   assert(From->isCompleteDefinition() && To->getDefinition() == To &&
 2457   assert(LexicalDC->isFunctionOrMethod());
 2650               assert(FoundCXX && "Record type mismatch");
 3005   assert(*RedeclIt == D);
 3097             assert(FoundByLookup->getDescribedFunctionTemplate() &&
 3652   assert(*RedeclIt == D);
 5027   assert(D->getTemplatedDecl() && "Should be called on templates only");
 5129       assert(FoundByLookup->getTemplatedDecl() &&
 5343   assert(!DC->isFunctionOrMethod() &&
 5622       assert(FoundByLookup->getTemplatedDecl() &&
 6926     assert(FromParam && "ParmVarDecl was not imported?");
 7799   assert(F && (isa<FieldDecl>(*F) || isa<IndirectFieldDecl>(*F)) &&
 8035     assert(Err);
 8048   assert(ImportedDecls.count(FromD) != 0 && "Missing call to MapImported?");
 8169     assert(FromNNS->getAsIdentifier() && "NNS should contain identifier.");
 8486   assert(ToID.isValid() && "Unexpected invalid fileID was created.");
 8757     assert(0 && "CompleteDecl called on a Decl that can't be completed");
 8763   assert((Pos == ImportedDecls.end() || Pos->second == To) &&
 8789   assert(InsertRes.second || InsertRes.first->second.Error == Error.Error);
tools/clang/lib/AST/ASTImporterLookupTable.cpp
   81   assert(EraseResult == true && "Trying to remove not contained Decl");
   85   assert(ND);
   94   assert(ND);
tools/clang/lib/AST/ASTStructuralEquivalence.cpp
 1092   assert(D1->isLambda() && D2->isLambda() &&
 1600   assert(Complain && "Not allowed to complain");
 1609   assert(Complain && "Not allowed to complain");
 1715   assert(DeclsToCheck.empty());
 1716   assert(VisitedDecls.empty());
 1725   assert(DeclsToCheck.empty());
 1726   assert(VisitedDecls.empty());
tools/clang/lib/AST/CXXInheritance.cpp
   39   assert(NumDeclsFound == 0 && !DeclsFound &&
  141   assert(isDependentContext());
  399   assert(BaseRecord->getCanonicalDecl() == BaseRecord &&
  408   assert(BaseRecord->getCanonicalDecl() == BaseRecord &&
  777     assert(!I.getType()->isDependentType() &&
  799     assert(!I.getType()->isDependentType() &&
tools/clang/lib/AST/Comment.cpp
  205   assert(!IsFilled);
  372   assert(isParamIndexValid());
  379   assert(isPositionValid());
tools/clang/lib/AST/CommentCommandTraits.cpp
   93   assert((NextID < (1 << CommandInfo::NumCommandIDBits))
tools/clang/lib/AST/CommentLexer.cpp
   72     assert(isHTMLDecimalCharacterReferenceCharacter(Name[i]));
   84     assert(isHTMLHexCharacterReferenceCharacter(C));
   92   assert(CommentState == LCS_InsideCComment);
  141     assert(*BufferPtr == '\r');
  199   assert(Quote == '\"' || Quote == '\'');
  269       assert(BufferPtr + 1 != BufferEnd);
  293   assert(CommentState == LCS_InsideBCPLComment ||
  298     assert(State == LS_Normal);
  301     assert(TokenPtr < CommentEnd);
  349   assert(State == LS_Normal);
  351   assert(TokenPtr < CommentEnd);
  466   assert(Info->IsVerbatimBlockCommand);
  490   assert(BufferPtr < CommentEnd);
  534   assert(State == LS_VerbatimBlockBody);
  550   assert(Info->IsVerbatimLineCommand);
  558   assert(State == LS_VerbatimLineText);
  571   assert(*TokenPtr == '&');
  632   assert(BufferPtr[0] == '<' &&
  653   assert(State == LS_HTMLStartTag);
  715   assert(BufferPtr[0] == '<' && BufferPtr[1] == '/');
  735   assert(BufferPtr != CommentEnd && *BufferPtr == '>');
  759     assert(*BufferPtr == '/');
  833         assert(BufferPtr[0] == '*' && BufferPtr[1] == '/');
  835         assert(BufferPtr <= BufferEnd);
tools/clang/lib/AST/CommentParser.cpp
   58     assert(!isEnd());
   73     assert(!isEnd());
   74     assert(Pos.BufferPtr != Pos.BufferEnd);
   79     assert(!isEnd());
   80     assert(Pos.BufferPtr != Pos.BufferEnd);
   87       assert(!isEnd());
  311   assert(Tok.is(tok::backslash_command) || Tok.is(tok::at_command));
  403   assert(Tok.is(tok::backslash_command) || Tok.is(tok::at_command));
  439   assert(Tok.is(tok::html_start_tag));
  544   assert(Tok.is(tok::html_end_tag));
  599       assert(Info->IsInlineCommand);
  660   assert(Tok.is(tok::verbatim_block_begin));
  707   assert(Tok.is(tok::verbatim_line_name));
tools/clang/lib/AST/CommentSema.cpp
  261   assert(Command->getNumArgs() == 0);
  303   assert(Command->getNumArgs() == 0);
  584   assert(ThisDeclInfo && "should not call this check on a bare comment");
  591     assert(!ThisDeclInfo->ReturnType.isNull() &&
  668   assert(ThisDeclInfo && "should not call this check on a bare comment");
 1017     assert(getBestDecl());
 1116     assert(II && "SimpleTypoCorrector should not return this decl");
 1124   assert(Traits.getCommandInfo(Name)->IsInlineCommand);
tools/clang/lib/AST/ComparisonCategories.cpp
   23   assert(VD && "must have var decl");
   46   assert(hasValidIntValue() && "must have a valid value");
  105   assert(!Ty.isNull() && "type must be non-null");
  141   assert(Info && "info for comparison category not found");
  146   assert(Record);
tools/clang/lib/AST/Decl.cpp
  172   assert(!kind.IgnoreExplicitVisibility &&
  335       assert(!usesTypeVisibility(ND));
  629   assert(D->getDeclContext()->getRedeclContext()->isFileContext() &&
  680     assert(VD && "Expected a VarDecl in this IndirectFieldDecl!");
  683   assert(!isa<FieldDecl>(D) && "Didn't expect a FieldDecl!");
 1042   assert(!explicitSpecSuppressor || !isa<TemplateDecl>(explicitSpecSuppressor));
 1101   assert(!IsMostRecent || ND == ND->getMostRecentDecl());
 1294       assert(cast<VarDecl>(D)->isStaticLocal());
 1467     assert(D->getCachedLinkage() == LV.getLinkage());
 1493   assert(!Old || Old->getCachedLinkage() == D->getCachedLinkage());
 1692   assert(getDeclName() == OldD->getDeclName() && "Declaration name mismatch");
 1850   assert(!TPLists.empty());
 1979   assert(isLegalForVariable(SC));
 2050     assert(D.getASTContext().getLangOpts().CPlusPlus);
 2357   assert(!Init->isValueDependent());
 2408   assert(isInitKnownICE() &&
 2425   assert(!Init->isValueDependent());
 2455   assert(D);
 2620   assert((isa<VarTemplateSpecializationDecl>(this) ||
 2648   assert(getASTContext().getTemplateOrSpecializationInfo(this).isNull() &&
 2696   assert(!hasUnparsedDefaultArg() && "Default argument is not yet parsed!");
 2697   assert(!hasUninstantiatedDefaultArg() &&
 2738   assert(hasUninstantiatedDefaultArg() &&
 2774   assert(T.isNull() || T->isFunctionType());
 2914   assert(getDeclName().getNameKind() == DeclarationName::CXXOperatorName);
 2915   assert(getDeclName().getCXXOverloadedOperator() == OO_New ||
 3094     assert((!PrevDecl || PrevFunTmpl) && "Function/function template mismatch");
 3193   assert(!ParamInfo && "Already has param info!");
 3194   assert(NewParamInfo.size() == getNumParams() && "Parameter count mismatch!");
 3224   assert(isInlined() && "expected to get called on an inlined function!");
 3274   assert(!doesThisDeclarationHaveABody() &&
 3378   assert((doesThisDeclarationHaveABody() || willHaveBody() ||
 3381   assert(isInlined() && "Function must be inline");
 3408   assert(!Context.getLangOpts().CPlusPlus &&
 3482   assert(TemplateOrSpecialization.isNull() &&
 3494   assert(TemplateOrSpecialization.isNull() &&
 3552     assert(getPrimaryTemplate() && "not a generic lambda call operator?");
 3624   assert((TemplateOrSpecialization.isNull() ||
 3627   assert(TSK != TSK_Undeclared &&
 3629   assert((TemplateOrSpecialization.isNull() ||
 3645   assert(TemplateOrSpecialization.isNull());
 3902   assert(hasODRHash());
 3953   assert(isBitField() && "not a bitfield");
 3978     assert(isInvalidDecl() && "valid field has incomplete type");
 4004   assert(RD && "requested index for field of struct with no definition");
 4011   assert(CachedFieldIndex && "failed to find field in parent");
 4025   assert((getParent()->isLambda() || getParent()->isCapturedRecord()) &&
 4027   assert(InitStorage.getInt() == ISK_NoInit &&
 4043   assert((DK != Enum || TK == TTK_Enum) &&
 4070     assert(T->isLinkageValid());
 4072   assert(isLinkageValid());
 4087   assert((!isa<CXXRecordDecl>(this) ||
 4143   assert(!TPLists.empty());
 4160   assert(Scoped || !ScopedUsingClassTag);
 4203   assert(!isCompleteDefinition() && "Cannot redefine enums!");
 4236   assert(MSI && "Not an instantiated member enumeration?");
 4254   assert(!isTemplateInstantiation(getTemplateSpecializationKind()) &&
 4268   assert(!SpecializationInfo && "Member enum is already a specialization");
 4292   assert(classof(static_cast<Decl *>(this)) && "Invalid Kind!");
 4356   assert(!isCompleteDefinition() && "Cannot redefine record!");
 4369   assert(hasExternalLexicalStorage() && Source && "No external storage?");
 4383     assert(isa<FieldDecl>(Decls[i]) || isa<IndirectFieldDecl>(Decls[i]));
 4468   assert(!ParamInfo && "Already has param info!");
 4578   assert(GnuLabelL != IdentL && "Use this only for GNU local labels");
 4844   assert(getNumModuleIdentifiers(Imported) == IdentifierLocs.size());
tools/clang/lib/AST/DeclBase.cpp
   95   assert(!Parent || &Parent->getParentASTContext() == &Ctx);
  115   assert(isFromASTFile() && "Not from AST file?");
  134   assert(!isa<TagDecl>(this) || !cast<TagDecl>(this)->isCompleteDefinition());
  317   assert(
  367   assert(DC && "This decl is not contained in a translation unit!");
  371     assert(DC && "This decl is not contained in a translation unit!");
  814   assert(!HasAttrs && "Decl already contains attrs.");
  817   assert(AttrBlank.empty() && "HasAttrs was wrong?");
  854   assert(HasAttrs && "No attrs to get!");
  939   assert(Access != AS_none &&
 1223         assert(isa<InjectedClassNameType>(Tag->getTypeForDecl()));
 1229     assert(getDeclKind() >= Decl::firstFunction &&
 1278   assert(hasNeedToReconcileExternalVisibleStorage() && LookupPtr);
 1291   assert(hasExternalLexicalStorage() && Source && "No external storage?");
 1442   assert(D->getLexicalDeclContext() == this &&
 1444   assert((D->NextInContextAndBits.getPointer() || D == LastDecl) &&
 1455       assert(I && "decl not found in linked list");
 1485         assert(Pos != Map->end() && "no lookup entry for decl");
 1496   assert(D->getLexicalDeclContext() == this &&
 1498   assert(!D->getNextDeclInContext() && D != LastDecl &&
 1545   assert(this == getPrimaryContext() && "buildLookup called on non-primary DC");
 1610   assert(getDeclKind() != Decl::LinkageSpec &&
 1626     assert(Source && "external visible storage but no external source?");
 1675   assert(getDeclKind() != Decl::LinkageSpec &&
 1809   assert(this == getPrimaryContext() && "expected a primary DC");
 1920   assert(!LookupPtr && "context already has a decls map");
 1921   assert(getPrimaryContext() == this &&
 1961   assert(Parent->isDependentContext()
tools/clang/lib/AST/DeclCXX.cpp
   64   assert(Impl.Decls.isLazy() && "getFromExternalSource for non-lazy set");
   65   assert(Source && "getFromExternalSource with no external source");
  479   assert(hasDefinition() && "ODRHash only for records with definitions");
  653   assert(isLambda() && "not a lambda");
 1327   assert(!D->isImplicit() && !D->isUserProvided());
 1409   assert(!Calls.empty() && "Missing lambda call operator!");
 1410   assert(allLookupResultsAreTheSame(Calls) &&
 1438   assert(allLookupResultsAreTheSame(Invoker) &&
 1462   assert(Field == field_end());
 1480   assert(std::is_partitioned(List->begin(), List->end(),
 1490   assert(isLambda() && "Not a lambda closure type!");
 1657       assert(llvm::find(Convs, ConvDecl) == Convs.end() &&
 1680   assert(TemplateOrInstantiation.isNull() &&
 1682   assert(!isa<ClassTemplatePartialSpecializationDecl>(this));
 1760   assert(!isTemplateInstantiation(this->getTemplateSpecializationKind()) &&
 1811   assert(hasDefinition() && "checking for interface-like without a definition");
 1884         assert(SO->second.size() > 0 &&
 2059   assert(isVirtual() && "this method is expected to be virtual");
 2143   assert(PreventedBy.empty() && "PreventedBy is expected to be empty");
 2261   assert(MD->isCanonicalDecl() && "Method is not canonical!");
 2262   assert(!MD->getParent()->isDependentContext() &&
 2264   assert(MD->isVirtual() && "Method is not virtual!");
 2316   assert(isInstance() && "No 'this' for static methods!");
 2324   assert(isInstance() && "No 'this' for static methods!");
 2474   assert(NameInfo.getName().getNameKind()
 2490   assert(isDelegatingConstructor() && "Not a delegating constructor!");
 2610   assert(NameInfo.getName().getNameKind()
 2642   assert(NameInfo.getName().getNameKind()
 2850   assert(std::find(shadow_begin(), shadow_end(), S) == shadow_end() &&
 2852   assert(S->getUsingDecl() == this);
 2860   assert(std::find(shadow_begin(), shadow_end(), S) != shadow_end() &&
 2862   assert(S->getUsingDecl() == this);
 3013   assert(VD->isImplicit() && "holding var for binding decl not implicit");
tools/clang/lib/AST/DeclFriend.cpp
   42     assert(isa<FunctionDecl>(D) ||
   49     assert(D->getFriendObjectKind() ||
   52     assert(FriendTypeTPLists.empty());
tools/clang/lib/AST/DeclGroup.cpp
   21   assert(NumDecls > 1 && "Invalid DeclGroup");
   29   assert(numdecls > 0);
   30   assert(decls);
tools/clang/lib/AST/DeclObjC.cpp
  529     assert(data().InheritedDesignatedInitializers
  601   assert(!hasDefinition() && "ObjC class already has a definition");
  856   assert(PrevMethod);
  889   assert((!SelLocs.empty() || isImplicit()) &&
 1113       assert(isClassMethod());
 1245   assert(Method->isOverriding());
 1295     assert(!Overridden.empty() &&
 1500   assert(data().ExternallyCompleted && "Class is not externally completed");
 1507   assert(getASTContext().getExternalSource() &&
 1509   assert(hasDefinition() &&
 1764     assert((isa<ObjCInterfaceDecl>(DC) || isa<ObjCImplementationDecl>(DC) ||
 1801     assert(CD->IsClassExtension() && "invalid container for ivar!");
 1910   assert(!Data.getPointer() && "Protocol already has a definition!");
tools/clang/lib/AST/DeclOpenMP.cpp
   50   assert(VL.size() == NumVars &&
   86   assert(VL.size() == NumVars &&
   92   assert(CL.size() == NumClauses &&
  124   assert(CL.size() == NumClauses &&
  203   assert(Clauses.empty() && "Number of clauses should be 0 on initialization");
  213   assert(CL.size() == Clauses.size() &&
  248   assert(hasInit());
tools/clang/lib/AST/DeclPrinter.cpp
  347           assert(Args[I] != nullptr && "Expected non-null Expr");
 1030   assert(Params);
 1582       assert(Shadow->getDeclContext() == ConstructorShadow->getDeclContext());
 1657       assert(OpName && "not an overloaded operator");
 1660       assert(D->getDeclName().isIdentifier());
tools/clang/lib/AST/DeclTemplate.cpp
  256     assert(!findSpecializationImpl(Specializations,
  266     assert(SETraits::getDecl(Existing)->isCanonicalDecl() &&
  368   assert(ThisCommon->Specializations.size() == 0 &&
  444     assert(Existing->isCanonicalDecl() && "Non-canonical specialization?");
  816       assert(getSpecializationKind() == TSK_ExplicitSpecialization ||
  832     assert(inst_from != nullptr);
 1060     assert(Existing->isCanonicalDecl() && "Non-canonical specialization?");
tools/clang/lib/AST/DeclarationName.cpp
  165     assert(OpName && "not an overloaded operator");
tools/clang/lib/AST/Expr.cpp
  100         assert(ME->getBase()->getType()->isRecordType());
  111         assert(BO->getRHS()->isRValue());
  239   assert((Kind == ConstantExpr::RSK_APValue ||
  281   assert(!isa<ConstantExpr>(E));
  317   assert(getStorageKind(Value) == ConstantExprBits.ResultKind &&
  530     assert(!Dependent && "built a DeclRefExpr with dependent template args");
  588   assert(NumTemplateArgs == 0 || HasTemplateKWAndArgsInfo);
  616   assert((getIdentKind() == IK) &&
  774       assert(FT && "We must have a written prototype in this case.");
  804       assert(Params->size() == Args.size());
  820       assert(Params->size() == Args->size());
  918   assert(type->isIntegerType() && "Illegal type in IntegerLiteral");
  919   assert(V.getBitWidth() == C.getIntWidth(type) &&
  941   assert(type->isFixedPointType() && "Illegal type in FixedPointLiteral");
  942   assert(V.getBitWidth() == C.getTypeInfo(type).Width &&
 1020   assert((CharByteWidth & 7) == 0 && "Assumes character size is byte multiple");
 1022   assert((CharByteWidth == 1 || CharByteWidth == 2 || CharByteWidth == 4) &&
 1033   assert(Ctx.getAsConstantArrayType(Ty) &&
 1037   assert((ByteLength % CharByteWidth == 0) &&
 1173       assert(Char <= 0xff &&
 1220   assert((getKind() == StringLiteral::Ascii ||
 1235     assert(TokNo < getNumConcatenated() && "Invalid byte number!");
 1346   assert((NumPreArgs == getNumPreArgs()) && "NumPreArgs overflow!");
 1350   assert((CallExprBits.OffsetToTrailingObjects == OffsetToTrailingObjects) &&
 1373   assert((NumPreArgs == getNumPreArgs()) && "NumPreArgs overflow!");
 1377   assert((CallExprBits.OffsetToTrailingObjects == OffsetToTrailingObjects) &&
 1397   assert(!(reinterpret_cast<uintptr_t>(Mem) % alignof(CallExpr)) &&
 1594   assert(getKind() == Field || getKind() == Identifier);
 1649   assert(!NameInfo.getName() ||
 1722   assert((!NumTemplateArgs || HasTemplateKWAndArgsInfo) &&
 1764     assert(!path_empty() && "Cast kind should have a base path!");
 1768     assert(getType()->isObjCObjectPointerType());
 1769     assert(getSubExpr()->getType()->isPointerType());
 1773     assert(getType()->isObjCObjectPointerType());
 1774     assert(getSubExpr()->getType()->isBlockPointerType());
 1778     assert(getType()->isMemberPointerType());
 1779     assert(getSubExpr()->getType()->isMemberPointerType());
 1787       assert(getType()->isObjCObjectPointerType() ==
 1789       assert(getType()->isBlockPointerType() ==
 1795     assert(getType()->isBlockPointerType());
 1796     assert(getSubExpr()->getType()->isAnyPointerType() &&
 1801     assert(getType()->isBlockPointerType());
 1802     assert(getSubExpr()->getType()->isBlockPointerType());
 1806     assert(getType()->isPointerType());
 1807     assert(getSubExpr()->getType()->isFunctionType());
 1813     assert(getValueKindForType(Ty) == Expr::getValueKindForType(SETy));
 1818     assert(!Ty.isNull() && !SETy.isNull() &&
 1856     assert(!getType()->isBooleanType() && "unheralded conversion to bool");
 1876     assert(path_empty() && "Cast kind should not have a base path!");
 1916       assert((isa<CXXMemberCallExpr>(SubExpr) ||
 1989   assert((Kind != CK_LValueToRValue ||
 2263   assert(!hasArrayFiller() && "Filler already set!");
 2287   assert(isSemanticForm() && "syntactic form never semantically transparent");
 2291     assert(getNumInits() == 1 && "multiple inits in glvalue init list");
 2310   assert(isSyntacticForm() && "only test syntactic form as zero initializer");
 2783   assert(expr->hasPlaceholderType(BuiltinType::BoundMember));
 2791     assert(isa<CXXMethodDecl>(mem->getMemberDecl()));
 2798     assert(type->isFunctionType());
 2802   assert(isa<UnresolvedMemberExpr>(expr) || isa<CXXPseudoDestructorExpr>(expr));
 3134   assert(!isValueDependent() &&
 3170       assert(CE->getNumArgs() == 1 && "trivial ctor with > 1 argument");
 3196     assert(ILE->isSemanticForm() && "InitListExpr must be in semantic form");
 3806     assert((E->getValueKind() == VK_LValue &&
 4144   assert(AssocTypes.size() == AssocExprs.size() &&
 4147   assert(ResultIndex < NumAssocs && "ResultIndex is out-of-bounds!");
 4169   assert(AssocTypes.size() == AssocExprs.size() &&
 4226   assert(Kind == FieldDesignator && "Only valid on a field designator");
 4295   assert(IndexIdx == IndexExprs.size() && "Wrong number of index expressions");
 4355   assert(D.Kind == Designator::ArrayDesignator && "Requires array designator");
 4360   assert(D.Kind == Designator::ArrayRangeDesignator &&
 4366   assert(D.Kind == Designator::ArrayRangeDesignator &&
 4487   assert(syntax && "no syntactic expression!");
 4488   assert(semantics.size() && "no semantic expressions!");
 4496     assert(resultIndex < semantics.size());
 4499     assert(semantics[resultIndex]->getObjectKind() == OK_Ordinary);
 4530       assert(cast<OpaqueValueExpr>(E)->getSourceExpr() != nullptr &&
 4566   assert(args.size() == getNumSubExprs(op) && "wrong number of subexpressions");
 4670       assert (OriginalTy->isArrayType());
tools/clang/lib/AST/ExprCXX.cpp
   69     assert(NotEq->getOpcode() == UO_LNot);
   76     assert(!SkippedNot || BO->getOpcode() == BO_EQ);
   82     assert(!SkippedNot || BO->getOperator() == OO_EqualEqual);
   83     assert(BO->isInfixBinaryOp());
  112     assert(BO->getOpcode() == BO_Cmp);
  117     assert(BO->getOperator() == OO_Spaceship);
  147   assert(isTypeOperand() && "Cannot call getTypeOperand for typeid(expr)");
  154   assert(isTypeOperand() && "Cannot call getTypeOperand for __uuidof(expr)");
  182   assert((Initializer != nullptr || InitializationStyle == NoInit) &&
  310       assert((ICE->getCastKind() == CK_NoOp ||
  423   assert(Args || TemplateKWLoc.isValid());
  438   assert(NumTemplateArgs == 0 || HasTemplateKWAndArgsInfo);
  559   assert(QualifierLoc && "should be created for dependent qualifiers");
  573   assert(NumTemplateArgs == 0 || HasTemplateKWAndArgsInfo);
  624   assert(
  627   assert((CXXOperatorCallExprBits.FPFeatures == FPFeatures.getInt()) &&
  965   assert(getNumArgs() == 1 && "unexpected #args in literal operator call");
  983   assert(LOK != LOK_Template && LOK != LOK_Raw && "not a cooked literal");
 1002   assert(Field->hasInClassInitializer());
 1013   assert((SubExpr->getType()->isRecordType() ||
 1115     assert(Args[I] && "NULL argument in CXXConstructExpr!");
 1145     assert(!Var && "'this' capture cannot have a variable!");
 1153     assert(Var && "capture must have a variable!");
 1156     assert(!Var && "VLA type capture cannot have a variable!");
 1185   assert(CaptureInits.size() == Captures.size() && "Wrong number of arguments");
 1469   assert(NumTemplateArgs == 0 || HasTemplateKWAndArgsInfo);
 1559   assert(NumTemplateArgs == 0 || HasTemplateKWAndArgsInfo);
 1578     assert(T && "qualifier in member expression does not name type");
 1580     assert(Record && "qualifier in member expression does not name record");
 1589     assert(Record && "base of member expression does not name record");
 1781   assert(Converted.size() == NumTemplateArgs);
 1782   assert(!this->ArgsAsWritten && "setTemplateArguments can only be used once");
 1798   assert(!NestedNameSpec ||
 1804   assert((!isValueDependent() || isInstantiationDependent()) &&
tools/clang/lib/AST/ExprClassification.cpp
   38   assert(!TR->isReferenceType() && "Expressions can't have reference type.");
   56   case Cl::CL_LValue: assert(getValueKind() == VK_LValue); break;
   57   case Cl::CL_XValue: assert(getValueKind() == VK_XValue); break;
   67   case Cl::CL_PRValue: assert(getValueKind() == VK_RValue); break;
  422     assert(cast<InitListExpr>(E)->getNumInits() == 1 &&
  539   assert(Ctx.getLangOpts().CPlusPlus &&
  575   assert(Ctx.getLangOpts().CPlusPlus &&
  697   assert(VC.getKind() == Cl::CL_LValue && "Unhandled kind");
tools/clang/lib/AST/ExprConstant.cpp
  199     assert(!isBaseAnAllocSizeCall(Base) &&
  214           assert(I == 0 && "unexpected unsized array designator");
  287       assert(V.isLValue() && "Non-LValue used to make an LValue designator?");
  309       assert(Base && "cannot truncate path for null pointer");
  310       assert(NewLength <= Entries.size() && "not a truncation");
  333       assert(!Invalid && "Calling this makes no sense on invalid designators");
  340       assert(!isMostDerivedAnUnsizedArray() && "Unsized array has no size");
  346       assert(!Invalid);
  387       assert(!Invalid && "invalid designator has no subobject type");
  472         assert(N.ugt(ArraySize) && "bounds check failed for in-bounds index");
  479       assert(ArrayIndex <= ArraySize &&
  562       assert((LB == Temporaries.end() || LB->first.first != Key) &&
  720       assert(isa<CallExpr>(AllocExpr));
  964       assert(CallIndex && "no call index in getCallFrameAndDepth");
 1307       assert(OldStackSize <= Info.CleanupStack.size() &&
 1385   assert(Info.CurrentCall == this && "calls retired out of order");
 1449       assert(v.isComplexFloat() || v.isComplexInt());
 1483         assert(!InvalidBase && "APValues can't handle invalid LValue bases");
 1489       assert(V.isLValue() && "Setting LValue from a non-LValue?");
 1502         assert((isa<MemberExpr>(E) || tryUnwrapAllocSizeCall(E)) &&
 1582         assert(getType(Base)->isPointerType() || getType(Base)->isArrayType());
 1648       assert(V.isMemberPointer());
 1667       assert(!Path.empty());
 1772   assert(Result.isAbsent() && "temporary created multiple times");
 1797   assert(Result.second && "reused a heap alloc index?");
 1965   assert(Base && "no location for a null lvalue");
 2025   assert((Info.checkingPotentialConstantExpression() ||
 2076       assert(V && "evasluation result refers to uninitialised temporary");
 2327   assert(E->isRValue() && "missing lvalue-to-rvalue conv in bool condition");
 2391   assert(FD->isBitField() && "truncateBitfieldValue on non-bitfield");
 2397     assert(Value.isLValue() && "integral value neither int nor lvalue?");
 2632   assert(TruncatedElements >= D.MostDerivedPathLength &&
 2850       assert(isLambdaCallOperator(Frame->Callee) &&
 2931   assert(!isa<SourceLocExpr>(Lit) &&
 2938     assert(Index <= Str.size() && "Index too large");
 2947   assert(CAT && "string literal isn't an array");
 2949   assert(CharType->isIntegerType() && "unexpected character type");
 2967   assert(CAT && "string literal isn't an array");
 2969   assert(CharType->isIntegerType() && "unexpected character type");
 2987   assert(Index < Size);
 3262       assert(CAT && "vla in literal type?");
 3299       assert(I == N - 1 && "extracting subobject of scalar?");
 3304         assert(O->isComplexFloat());
 3386   assert(AK == AK_Read || AK == AK_ReadObjectRepresentation);
 3647         assert(MTE->getStorageDuration() == SD_Static &&
 3680         assert(BaseVal && "got reference to unevaluated temporary");
 3695       assert(BaseVal && "missing value for temporary");
 3756       assert(LVal.Designator.Entries.size() <= 1 &&
 4146     assert(RD && "member pointer access on non-class-type expression");
 4181   assert(BO->getOpcode() == BO_PtrMemD || BO->getOpcode() == BO_PtrMemI);
 4502           assert(ESR != ESR_Succeeded);
 4545           assert(ESR != ESR_Succeeded);
 5018   assert(PathLength >= Designator.MostDerivedPathLength && PathLength <=
 5148   assert(Result.isLValue() &&
 5159     assert(OldClass && NewClass && "unexpected kind of covariant return");
 5213   assert(C && "dynamic_cast target is not void pointer nor class");
 5235       assert(Paths->front().Access != AS_public && "why did the cast fail?");
 5297     assert(SubobjType->isUnionType());
 5349       assert(declaresSameEntity(FD,
 5376         assert(declaresSameEntity(Elt->getType()->getAsCXXRecordDecl(),
 5496     assert(This &&
 5612       assert(Indirect && "fields out of order?");
 5618       assert(FieldIt != RD->field_end() && "missing field?");
 5637       assert(!BaseIt->isVirtual() && "virtual base for literal type");
 5638       assert(Info.Ctx.hasSameType(BaseIt->getType(), BaseType) &&
 5904   assert(BasesLeft == 0 && "NumBases was wrong?");
 6164       assert(!Bytes[Offset.getQuantity() + Index] && "overwriting a byte?");
 6192     assert((size_t)Offset.getQuantity() <= Buffer.size());
 6261       assert(FieldOffsetBits % Info.Ctx.getCharWidth() == 0 &&
 6432       assert(FieldOffsetBits % Info.Ctx.getCharWidth() == 0);
 6450     assert(!RepresentationType.isNull() &&
 6577   assert(CHAR_BIT == 8 && Info.Ctx.getTargetInfo().getCharWidth() == 8 &&
 6579   assert(SourceValue.isLValue() &&
 6626     assert(Info.checkingPotentialConstantExpression());
 6828       assert(0 && "OpaqueValueExpr recursively refers to itself");
 6921         assert(
 6933           assert(MD->isFunctionTemplateSpecialization() &&
 6942           assert(CorrespondingCallOpSpecialization &&
 6983       assert(This && "no 'this' pointer for destructor call");
 7026     assert(!Info.Ctx.getLangOpts().CPlusPlus11 &&
 7028     assert(!E->isArrow() && "missing call to bound member function?");
 7038     assert(!FD->getType()->isReferenceType() && "prvalue reference?");
 7039     assert(BaseTy->castAs<RecordType>()->getDecl()->getCanonicalDecl() ==
 7215       assert(E->getBase()->getType()->isRecordType());
 7231       assert(BaseTy->castAs<RecordType>()->getDecl()->getCanonicalDecl() ==
 7378   assert(E->isGLValue() || E->getType()->isFunctionType() ||
 7530   assert((!Info.getLangOpts().CPlusPlus || E->isFileScope()) &&
 7624   assert(E->getSubExpr()->getType()->isAnyComplexType() &&
 7705   assert(AllocSize && AllocSize->getElemSizeParam().isValid());
 7750   assert(isBaseAnAllocSizeCall(LVal.getLValueBase()) &&
 7888     assert(E->isStringType() && "SourceLocExpr isn't a pointer type?");
 7901   assert(E->isRValue() && E->getType()->hasPointerRepresentation());
 8247     assert(IsRawByte ||
 8347     assert(!N.isSigned() && "memcpy and friends take an unsigned size");
 8481     assert(E->getNumPlacementArgs() == 1);
 8559       assert(CAT && "unexpected type for array initializer");
 8585     assert(!AllocType->isArrayType() &&
 8691   assert(E->isRValue() && E->getType()->isMemberPointerType());
 8715       assert(!(*PathI)->isVirtual() && "memptr cast through vbase");
 8731       assert(!(*PathI)->isVirtual() && "memptr cast through vbase");
 8795   assert(!RD->isUnion() && "Expected non-union class type");
 8884       assert(!(*PathI)->isVirtual() && "record rvalue with virtual base");
 8943       assert(ElementNo < E->getNumInits() && "missing init for base class");
 9045     assert(Info.checkingPotentialConstantExpression());
 9124   assert(NumFields == (size_t)std::distance(E->capture_init_begin(),
 9136     assert(CaptureInitIt != E->capture_init_end());
 9158   assert(E->isRValue() && E->getType()->isRecordType() &&
 9213   assert(E->isRValue() && E->getType()->isRecordType());
 9231       assert(V.size() == E->getType()->castAs<VectorType>()->getNumElements());
 9237       assert(V.isVector());
 9255   assert(E->isRValue() && E->getType()->isVectorType() &&"not a vector rvalue");
 9413       assert(V.isArray() && "expected array");
 9455   assert(E->isRValue() && E->getType()->isArrayType() && "not an array rvalue");
 9462   assert(ILE->isRValue() && ILE->getType()->isArrayType() &&
 9504   assert((!Result.isArray() || Result.getArrayInitializedElts() == 0) &&
 9553   assert(FillerExpr && "no array filler for incomplete init list");
 9652     assert(E->getType()->isIntegralOrEnumerationType() &&
 9654     assert(SI.isSigned() == E->getType()->isSignedIntegerOrEnumerationType() &&
 9656     assert(SI.getBitWidth() == Info.Ctx.getIntWidth(E->getType()) &&
 9666     assert(E->getType()->isIntegralOrEnumerationType() &&
 9668     assert(I.getBitWidth() == Info.Ctx.getIntWidth(E->getType()) &&
 9680     assert(E->getType()->isIntegralOrEnumerationType() &&
 9809     assert(E->getType()->isFixedPointType() && "Invalid evaluation result.");
 9810     assert(V.getWidth() == Info.Ctx.getIntWidth(E->getType()) &&
 9840   assert(E->isRValue() && E->getType()->isIntegralOrEnumerationType());
 9955   assert(!T->isDependentType() && "unexpected dependent type");
10199   assert(E->isRValue() && E->getType()->hasPointerRepresentation());
10235   assert(!LVal.Designator.Invalid);
10297       assert(getAsBaseClass(Entry) && "Expecting cast to a base class");
10512     assert(Type <= 3 && "unexpected type");
10804     assert(IsRawByte ||
10836       assert(BytesRemaining && "BytesRemaining should not be zero: the "
10895       assert(!(StopAtNull && !Char2.getInt()));
11246   assert(E->getLHS()->getType()->isIntegralOrEnumerationType() &&
11260   assert(!LVal.hasLValuePath() && "have designator for integer lvalue");
11302   assert(E->getLHS()->getType()->isIntegralOrEnumerationType() &&
11422       assert(ContinueAfterFailure &&
11433   assert(E->isComparisonOp() && "expected comparison operator");
11434   assert((E->getOpcode() == BO_Cmp ||
11521       assert(IsEquality && "invalid complex comparison");
11539     assert(E->isComparisonOp() && "Invalid binary operator!");
11667     assert(PtrSize <= 64 && "Unexpected pointer width");
11693     assert(IsEquality && "unexpected member pointer operation");
11694     assert(RHSTy->isMemberPointerType() && "invalid comparison");
11731     assert(E->isComparisonOp() && "unexpected nullptr operation");
11732     assert(RHSTy->isNullPtrType() && "missing pointer conversion");
11776   assert((!E->getLHS()->getType()->isIntegralOrEnumerationType() ||
11940     assert(E->isArgumentType());
11983       assert(i < RL.getFieldCount() && "offsetof field in wrong type");
12301   assert(DestType->isFixedPointType() &&
12404   assert(E->isRValue() && E->getType()->isRealFloatingType());
12636   assert(E->isRValue() && E->getType()->isAnyComplexType());
12668     assert(SubExpr->getType()->isIntegerType() &&
12857   assert(!(LHSReal && RHSReal) &&
12905         assert(!RHSReal && "Cannot have two real operands for a complex op!");
13141   assert(E->isRValue() && E->getType()->isAtomicType());
13265   assert(E->isRValue() && E->getType()->isVoidType());
13357   assert(!E->isValueDependent());
13500   assert(!isValueDependent() &&
13509   assert(!isValueDependent() &&
13519   assert(!isValueDependent() &&
13529   assert(!isValueDependent() &&
13539   assert(!isValueDependent() &&
13557   assert(!isValueDependent() &&
13577   assert(!isValueDependent() &&
13598   assert(!isValueDependent() &&
13667   assert(getEvaluatedValue() && !getEvaluatedValue()->isAbsent() &&
13703   assert(!isValueDependent() &&
13713   assert(!isValueDependent() &&
13723   assert(Result && "Could not evaluate expression");
13724   assert(EVResult.Val.isInt() && "Expression did not evaluate to integer");
13731   assert(!isValueDependent() &&
13742   assert(Result && "Could not evaluate expression");
13743   assert(EVResult.Val.isInt() && "Expression did not evaluate to integer");
13749   assert(!isValueDependent() &&
13762   assert(Val.isLValue());
13822   assert(!E->isValueDependent() && "Should not see value dependent exprs!");
14243   assert(!isValueDependent() &&
14259   assert(!isValueDependent() &&
14285   assert(!isValueDependent() &&
14293   assert(!isValueDependent() &&
14298   assert(Ctx.getLangOpts().CPlusPlus);
14328   assert(!isValueDependent() &&
14340     assert(MD && "Don't provide `this` for non-methods.");
14341     assert(!MD->isStatic() && "Don't provide `this` for static methods.");
14425   assert(!E->isValueDependent() &&
14441   assert(Success &&
tools/clang/lib/AST/ExprObjC.cpp
  212   assert((!SelLocs.empty() || isImplicit) &&
  231   assert((!SelLocs.empty() || isImplicit) &&
  250   assert((!SelLocs.empty() || isImplicit) &&
tools/clang/lib/AST/ExternalASTMerger.cpp
  173     assert((&PersistentCtx != &getFromContext()) && (&OtherImporter != this) &&
  234       assert(Parent.CanComplete(ToTag));
  237       assert(Parent.CanComplete(ToNamespace));
  241       assert(Parent.CanComplete(ToContainer));
  304     assert(DidCallback && "Couldn't find a source context matching our DC");
  309   assert(Tag->hasExternalLexicalStorage());
  326   assert(Interface->hasExternalLexicalStorage());
  345   assert(Interface->hasExternalLexicalStorage() ||
  405   assert(&D->getASTContext() == &Target.AST);
  414     assert(&S.getASTContext() != &Target.AST);
  416     assert(!S.getMerger() || &S.getMerger()->Target.AST == &S.getASTContext());
  513     assert(NDOrErr);
  516     assert(ND);
  522     assert(!IsSpecImportFailed);
  539           assert(!(*ImportedDeclOrErr) ||
tools/clang/lib/AST/FormatString.cpp
   95     assert(Amt.getHowSpecified() == OptionalAmount::Constant);
  980   assert(isa<TypedefType>(QT) && "Expected a TypedefType");
tools/clang/lib/AST/FormatStringParsing.h
   87     assert(hasValue());
tools/clang/lib/AST/Interp/ByteCodeExprGen.h
  212     assert(InitFn && "missing initializer");
tools/clang/lib/AST/Interp/Descriptor.cpp
  194   assert(Source && "Missing source");
  204   assert(Source && "Missing source");
  213   assert(Source && "Missing source");
  224   assert(Source && "Missing source");
  233   assert(Source && "Missing source");
  242   assert(Source && "Missing source");
tools/clang/lib/AST/Interp/Descriptor.h
  129     assert(!isUnknownSizeArray() && "Array of unknown size");
tools/clang/lib/AST/Interp/EvalEmitter.cpp
  116       assert(Record && "Missing record descriptor");
  201   assert(It != Locals.end() && "Missing local variable");
  214   assert(It != Locals.end() && "Missing local variable");
  228   assert(It != Locals.end() && "Missing local variable");
  240     assert(It != Locals.end() && "Missing local variable");
tools/clang/lib/AST/Interp/Function.cpp
   30   assert(It != Params.end() && "Invalid parameter offset");
tools/clang/lib/AST/Interp/Interp.cpp
   38   assert(S.Current->getFrameOffset() == S.Stk.size() && "Invalid frame");
   59   assert(S.Current->getFrameOffset() == S.Stk.size() && "Invalid frame");
  128   assert(R && R->isUnion() && "Not a union");
  259   assert(Ptr.isLive() && "Pointer is not live");
  271   assert(Ptr.isLive() && "Pointer is not live");
tools/clang/lib/AST/Interp/InterpFrame.cpp
  156   assert(Offset < Func->getFrameSize() && "Invalid local offset.");
tools/clang/lib/AST/Interp/InterpStack.cpp
   30   assert(Size < ChunkSize - sizeof(StackChunk) && "Object too large");
   50   assert(Chunk && "Stack is empty!");
   56     assert(Ptr && "Offset too large");
   63   assert(Chunk && "Chunk is empty!");
   73     assert(Chunk && "Offset too large");
tools/clang/lib/AST/Interp/Pointer.cpp
   29   assert((Base == RootPtrMark || Base % alignof(void *) == 0) && "wrong base");
  136   assert(Pointee && "Cannot check if null pointer was initialized");
  155   assert(Pointee && "Cannot initialize null pointer");
  172     assert(Base != 0 && "Only composite fields can be initialised");
  179   assert(Base != 0 && "Only composite fields can be initialised");
tools/clang/lib/AST/Interp/Pointer.h
  153       assert(Offset == PastEndMark && "cannot get base of a block");
  156     assert(Offset == Base && "not an inner field");
  163       assert(Offset != 0 && Offset != PastEndMark && "not an array element");
  166     assert(Offset != Base && "not an array element");
  191     assert(Offset != PastEndMark && "invalid offset");
  281     assert(isLive() && "Invalid pointer");
  323     assert(Offset != 0 && "Not a nested pointer");
tools/clang/lib/AST/Interp/Program.cpp
   83   assert(Idx < Globals.size());
tools/clang/lib/AST/Interp/Program.h
   55     assert(Idx < Globals.size());
tools/clang/lib/AST/Interp/Record.cpp
   32   assert(It != FieldMap.end() && "Missing field");
   38   assert(It != BaseMap.end() && "Missing base");
   44   assert(It != VirtualBaseMap.end() && "Missing virtual base");
tools/clang/lib/AST/Interp/Source.h
   35     assert(Ptr != nullptr && RHS.Ptr != nullptr && "Invalid code pointer");
   40     assert(Ptr != nullptr && "Invalid code pointer");
tools/clang/lib/AST/ItaniumCXXABI.cpp
   46   assert(RT && "type of VarDecl is expected to be RecordType.");
   47   assert(RT->getDecl()->isUnion() && "RecordType is expected to be a union.");
  112     assert(!isEqual(Key, getEmptyKey()) && !isEqual(Key, getTombstoneKey()));
  144     assert(Lambda->isLambda());
tools/clang/lib/AST/ItaniumMangle.cpp
  262       assert(getDepth() == saved.getDepth() + 1);
  294         assert(
  354       assert(LinkHead == this &&
  390     assert(!D || (!isa<CXXDestructorDecl>(D) &&
  632   assert(AbiTags && "require AbiTagState");
  969     assert(!AdditionalAbiTags &&
  991   assert(!AdditionalAbiTags &&
  995   assert(Dependent && "Not a dependent template name?");
 1020   assert(numCharacters != 0);
 1315     assert(ND && "mangling empty name without declaration");
 1338       assert(RD->isAnonymousStructOrUnion()
 1346       assert(FD->getIdentifier() && "Data member name isn't an identifier!");
 1365       assert(TD->getDeclContext() == D->getDeclContext() &&
 1367       assert(D->getDeclName().getAsIdentifierInfo() &&
 1370       assert(!AdditionalAbiTags && "Type cannot have additional abi tags");
 1384         assert(!AdditionalAbiTags &&
 1553   assert(isa<NamedDecl>(D) || isa<BlockDecl>(D));
 1606       assert(!AdditionalAbiTags && "Block cannot have additional abi tags");
 1628     assert(!AdditionalAbiTags && "Block cannot have additional abi tags");
 1769   assert(Number > 0 && "Lambda should be mangled as an unnamed class");
 1809     assert(qualifier->getPrefix());
 1834   assert(!isLocalContainerContext(DC));
 1871   assert(Dependent && "Unknown template name kind?");
 1935     assert(Dependent->isIdentifier());
 2061       assert(TD && "no template for template specialization type");
 2823       assert(T->getExceptionSpecType() == EST_Dynamic);
 2896   assert(!FD || FD->getNumParams() == Proto->getNumParams());
 2910         assert(Attr->getType() <= 9 && Attr->getType() >= 0);
 3047   assert(EltType->isBuiltinType() && "Neon vector element not a BuiltinType");
 3087     assert(BitSize == 128 && "Neon vector type not 64 or 128 bits");
 3138   assert(EltType->isBuiltinType() && "Neon vector element not a BuiltinType");
 3143   assert((BitSize == 64 || BitSize == 128) &&
 3419   assert(T->getDeducedType().isNull() &&
 3421   assert(T->getKeyword() != AutoTypeKeyword::GNUAutoType &&
 3523   assert(!lookup->requiresADL());
 3729         assert(Designator.isArrayRangeDesignator() &&
 3897       assert(N == 1 && "unexpected form for list initialization");
 3917       assert(
 4292     assert(isa<ConstantArrayType>(E->getType()));
 4425   assert(parmDepth < FunctionTypeDepth.getDepth());
 4440   assert(!parm->getType()->isArrayType()
 4661   assert(result && "no existing substitution for template name");
 4868   assert(!Substitutions.count(Ptr) && "Substitution already exists!");
 4873   assert(Other->SeqID >= SeqID && "Must be superset of substitutions!");
 4936   assert((isa<FunctionDecl>(D) || isa<VarDecl>(D)) &&
 4938   assert(!isa<CXXConstructorDecl>(D) && !isa<CXXDestructorDecl>(D) &&
 4985   assert(!isa<CXXDestructorDecl>(MD) &&
 5095   assert(ManglingNumber > 0 && "Reference temporary mangling number is zero!");
 5130   assert(!Ty.hasQualifiers() && "RTTI info cannot have top-level qualifiers");
tools/clang/lib/AST/Mangle.cpp
  183   assert(!Proto->isVariadic());
  233   assert(!isa<CXXConstructorDecl>(DC) && !isa<CXXDestructorDecl>(DC));
  240     assert((isa<NamedDecl>(DC) || isa<BlockDecl>(DC)) &&
  245     assert((isa<TranslationUnitDecl>(DC) || isa<NamedDecl>(DC)) &&
  271   assert (CD && "Missing container decl in GetNameForMethod");
tools/clang/lib/AST/MicrosoftCXXABI.cpp
  100     assert(CD != nullptr);
  101     assert(RecordToCopyCtor[RD] == nullptr || RecordToCopyCtor[RD] == CD);
  147     assert(RD->getNumBases() == 1);
  170   assert(IA && "Expected MSInheritanceAttr on the CXXRecordDecl!");
tools/clang/lib/AST/MicrosoftMangle.cpp
  234     assert(RD->isLambda() && "RD must be a lambda!");
  235     assert(!RD->isExternallyVisible() && "RD must not be visible!");
  236     assert(RD->getLambdaManglingNumber() == 0 &&
  598     assert(FieldOffset % getASTContext().getCharWidth() == 0 &&
  865       assert(ND && "mangling empty name without declaration");
  887         assert(RD && "expected variable decl to have a record type");
  901         assert(TD->getDeclContext() == D->getDeclContext() &&
  903         assert(D->getDeclName().getAsIdentifierInfo() &&
 1420   assert(TPL->size() == TemplateArgs.size() &&
 1832   assert(Quals.hasAddressSpace() && "Not valid without address space");
 2259       assert(AT->getKeyword() != AutoTypeKeyword::GNUAutoType &&
 2634   assert(!Quals.hasConst() && !Quals.hasVolatile() && "unexpected qualifier!");
 2646   assert(!Quals.hasConst() && !Quals.hasVolatile() && "unexpected qualifier!");
 2689   assert(ET && "vectors with non-builtin elements are unsupported");
 2902   assert(T->getDeducedType().isNull() && "expecting a dependent type!");
 2913   assert(T->getDeducedType().isNull() && "expecting a dependent type!");
 2947   assert((isa<FunctionDecl>(D) || isa<VarDecl>(D)) &&
 2949   assert(!isa<CXXConstructorDecl>(D) && !isa<CXXDestructorDecl>(D) &&
 3073     assert(Thunk.Method != nullptr &&
 3087   assert(Type == Dtor_Deleting);
 3274     assert(VFTableMangling.endswith("@"));
 3279   assert(VFTableMangling.startswith("??_7") ||
tools/clang/lib/AST/NestedNameSpecifier.cpp
   60   assert(II && "Identifier cannot be NULL");
   61   assert((!Prefix || Prefix->isDependent()) && "Prefix must be dependent");
   74   assert(NS && "Namespace cannot be NULL");
   75   assert((!Prefix ||
   90   assert(Alias && "Namespace alias cannot be NULL");
   91   assert((!Prefix ||
  106   assert(T && "Type cannot be NULL");
  116   assert(II && "Identifier cannot be NULL");
  328     assert(!isa<ElaboratedType>(T) &&
  368   assert(Qualifier && "Expected a non-NULL qualifier");
  621   assert(!Representation && "Already have a nested-name-specifier!?");
tools/clang/lib/AST/ODRHash.cpp
   25   assert(S && "Expecting non-null pointer.");
   30   assert(II && "Expecting non-null pointer.");
  110   assert(NNS && "Expecting non-null pointer.");
  190   assert(TPL && "Expecting non-null pointer.");
  231   assert(I == Bools.rend());
  462   assert(D && "Expecting non-null pointer.");
  468   assert(Record && Record->hasDefinition() &&
  516   assert(Function && "Expecting non-null pointer.");
  598   assert(Enum);
  613       assert(isa<EnumConstantDecl>(SubDecl) && "Unexpected Decl");
  626   assert(D && "Expecting non-null pointer.");
 1108   assert(T && "Expecting non-null pointer.");
tools/clang/lib/AST/OSLog.cpp
  188     assert(E->getNumArgs() >= 1 &&
  194     assert(E->getNumArgs() >= 2 &&
  204   assert(Lit && (Lit->isAscii() || Lit->isUTF8()));
tools/clang/lib/AST/OpenMPClause.cpp
  228     assert(DS->isSingleDecl() && "Only single expression must be captured.");
  293   assert(NumLoop < NumberOfLoops && "out of loops number.");
  302   assert(NumLoop < NumberOfLoops && "out of loops number.");
  307   assert(NumLoop < NumberOfLoops && "out of loops number.");
  312   assert(NumLoop < NumberOfLoops && "out of loops number.");
  317   assert(VL.size() == varlist_size() &&
  342   assert(VL.size() == varlist_size() &&
  348   assert(VL.size() == varlist_size() &&
  375   assert(PrivateCopies.size() == varlist_size() &&
  381   assert(SrcExprs.size() == varlist_size() && "Number of source expressions is "
  388   assert(DstExprs.size() == varlist_size() && "Number of destination "
  395   assert(AssignmentOps.size() == varlist_size() &&
  443   assert(PL.size() == varlist_size() &&
  449   assert(IL.size() == varlist_size() &&
  455   assert(UL.size() == varlist_size() &&
  461   assert(FL.size() == varlist_size() &&
  467   assert(
  537   assert(SrcExprs.size() == varlist_size() && "Number of source expressions is "
  544   assert(DstExprs.size() == varlist_size() && "Number of destination "
  551   assert(AssignmentOps.size() == varlist_size() &&
  578   assert(SrcExprs.size() == varlist_size() && "Number of source expressions is "
  585   assert(DstExprs.size() == varlist_size() && "Number of destination "
  592   assert(AssignmentOps.size() == varlist_size() &&
  620   assert(Privates.size() == varlist_size() &&
  626   assert(
  633   assert(
  640   assert(ReductionOps.size() == varlist_size() && "Number of reduction "
  673   assert(Privates.size() == varlist_size() &&
  679   assert(
  686   assert(
  693   assert(ReductionOps.size() == varlist_size() && "Number of task reduction "
  726   assert(Privates.size() == varlist_size() &&
  732   assert(
  739   assert(
  746   assert(ReductionOps.size() == varlist_size() && "Number of in reduction "
  754   assert(TaskgroupDescriptors.size() == varlist_size() &&
  849   assert((getDependencyKind() == OMPC_DEPEND_sink ||
  859   assert((getDependencyKind() == OMPC_DEPEND_sink ||
  869   assert((getDependencyKind() == OMPC_DEPEND_sink ||
 1051   assert(VL.size() == varlist_size() &&
 1057   assert(VL.size() == varlist_size() &&
 1358     assert(*I && "Expected non-null Stmt");
tools/clang/lib/AST/ParentMap.cpp
   36     assert(OVMode == OV_Transparent && "Should not appear alongside OVEs");
   56     assert(OVMode == OV_Transparent && "Should not appear alongside OVEs");
  128   assert(S);
  129   assert(Parent);
tools/clang/lib/AST/PrintfFormatString.cpp
  433   assert(I == E && "Format string not exhausted");
tools/clang/lib/AST/QualTypeNames.cpp
   65   assert(ArgTDecl != nullptr);
  122   assert(!isa<DependentTemplateSpecializationType>(TypePtr));
  267   assert(Decl);
  436     assert(!QT.hasLocalQualifiers());
tools/clang/lib/AST/RawCommentList.cpp
   42     assert(Comment.size() >= 4);
  166   assert(BeginFileID == EndFileID);
  240   assert(Loc1Info.second <= Loc2Info.second && "Loc1 after Loc2!");
  398     assert(!LocInvalid && "getFormattedText for invalid location");
tools/clang/lib/AST/RecordLayout.cpp
   85           assert(getVBaseClassOffset(PrimaryBase).isZero() &&
   89         assert(getBaseClassOffset(PrimaryBase).isZero() &&
tools/clang/lib/AST/RecordLayoutBuilder.cpp
   80     assert(FieldOffsets.count(FD) &&
  144     assert(FieldOffset % CharWidth == 0 &&
  785     assert(Size % Context.getCharWidth() == 0);
  796     assert(DataSize % Context.getCharWidth() == 0);
  811     assert(!I.getType()->isDependentType() &&
  882   assert(!PrimaryBase && "Should not get here with a primary base!");
  893       assert(InfoSlot->Class == RD && "Wrong class for virtual base info!");
  918       assert(PrimaryVirtualBase && "Didn't have a primary virtual base!");
  951     assert(PrimaryVirtualBaseInfo &&
  975       assert(VirtualBaseInfo.count(BaseDecl) &&
  979       assert(!NonVirtualBaseInfo.count(BaseDecl) &&
 1022       assert(!VisitedVirtualBases.count(PrimaryBase) &&
 1030       assert(PrimaryBaseInfo &&
 1039     assert(DataSize == 0 && "Vtable pointer must be at offset zero!");
 1067     assert(BaseInfo && "Did not find base info for non-virtual base!");
 1079   assert(!Bases.count(Base->Class) && "base offset already exists!");
 1093     assert(Info->PrimaryVirtualBaseInfo->IsVirtual &&
 1097       assert(!VBases.count(Info->PrimaryVirtualBaseInfo->Class) &&
 1133     assert(!Base.getType()->isDependentType() &&
 1149           assert(BaseInfo && "Did not find virtual base info!");
 1166   assert(!Base->Derived && "Trying to lay out a primary virtual base!");
 1172   assert(!VBases.count(Base->Class) && "vbase offset already exists!");
 1232     assert(Allowed && "Base subobject externally placed at overlapping offset");
 1340     assert(Bases.count(BaseDecl) && "Did not find base offset!");
 1347     assert(VBases.count(BaseDecl) && "Did not find base offset!");
 1400   assert(Context.getLangOpts().CPlusPlus &&
 1421   assert(!Type.isNull() && "Did not find a type!");
 1801           assert(
 1862       assert(Allowed && "Externally-placed field cannot be placed here");
 1991     assert(llvm::isPowerOf2_64(NewAlignment.getQuantity()) &&
 1997     assert(llvm::isPowerOf2_64(UnpackedNewAlignment.getQuantity()) &&
 2670       assert(BaseOffset >= Size && "base offset already allocated");
 2677       assert(BaseLayout.getNonVirtualSize() == CharUnits::Zero());
 2895     assert(BaseOffset >= Size && "base offset already allocated");
 2987   assert(RD->getMSVtorDispMode() == MSVtorDispAttr::ForVBaseOverride);
 3033   assert(D && "Cannot get layout of forward declarations!");
 3034   assert(!D->isInvalidDecl() && "Cannot get layout of invalid decl!");
 3035   assert(D->isCompleteDefinition() && "Cannot layout type before complete!");
 3116   assert(RD->getDefinition() && "Cannot get key function for forward decl!");
 3136   assert(Method == Method->getFirstDecl() &&
 3208   assert(Index < RL->getFieldCount() && "Ivar is not inside record layout!");
 3225   assert(D && D->isThisDeclarationADefinition() && "Invalid interface decl!");
 3329       assert(!Base.getType()->isDependentType() &&
 3392       assert(Base.isVirtual() && "Found non-virtual class!");
tools/clang/lib/AST/ScanfFormatString.cpp
  134     assert(Amt.getHowSpecified() == OptionalAmount::Constant);
  565   assert(I == E && "Format string not exhausted");
tools/clang/lib/AST/SelectorLocationsKind.cpp
   26     assert(Index == 0);
   34   assert(Index < NumSelArgs);
tools/clang/lib/AST/Stmt.cpp
  312   assert(CompoundStmtBits.NumStmts == Stmts.size() &&
  358   assert(!Attrs.empty() && "Attrs should not be empty");
  366   assert(NumAttrs > 0 && "NumAttrs should be greater than zero");
  431   assert(isOperand() && "Only Operands can have modifiers.");
  485   assert(!(NumOutputs && NumLabels) && "asm goto cannot have outputs");
  801   assert(NumAsmToks == asmtoks.size());
  802   assert(NumClobbers == clobbers.size());
  804   assert(exprs.size() == NumOutputs + NumInputs);
  805   assert(exprs.size() == constraints.size());
  894   assert(hasVarStorage() &&
  995   assert(hasVarStorage() &&
 1051   assert(hasVarStorage() &&
 1167     assert(!Var && "'this' capture cannot have a variable!");
 1170     assert(Var && "capturing by reference must have a variable!");
 1173     assert(Var && "capturing by copy must have a variable!");
 1174     assert(
 1183     assert(!Var &&
 1195   assert((capturesVariable() || capturesVariableByCopy()) &&
 1218   assert( S && "null captured statement");
 1219   assert(CD && "null captured declaration for captured statement");
 1220   assert(RD && "null record declaration for captured statement");
 1256   assert(CaptureInits.size() == Captures.size() && "wrong number of arguments");
 1301   assert(D && "null CapturedDecl");
tools/clang/lib/AST/StmtCXX.cpp
   68   assert(RangeDecl && "for-range should have a single var decl");
   78   assert(LV && "No loop variable in CXXForRangeStmt");
tools/clang/lib/AST/StmtIterator.cpp
   38   assert(getVAPtr());
   55     assert(inSizeOfTypeVA());
   61   assert(getVAPtr() == nullptr);
   62   assert(inDeclGroup());
  111     assert(VAPtr->SizeExpr);
  115   assert(inDeclGroup());
tools/clang/lib/AST/StmtOpenMP.cpp
   20   assert(Clauses.size() == getNumClauses() &&
   37   assert(!isStandaloneDirective() &&
   45   assert(A.size() == getCollapsedNumber() &&
   51   assert(A.size() == getCollapsedNumber() && "Number of loop private counters "
   58   assert(A.size() == getCollapsedNumber() &&
   64   assert(A.size() == getCollapsedNumber() &&
   70   assert(A.size() == getCollapsedNumber() &&
   76   assert(
   83   assert(A.size() == getCollapsedNumber() &&
   89   assert(A.size() == getCollapsedNumber() &&
tools/clang/lib/AST/StmtPrinter.cpp
  601     assert(F && "Must have a finally block...");
 1789     assert(Args);
tools/clang/lib/AST/StmtProfile.cpp
  218   assert(S && "Requires non-null Stmt pointer");
 1251       assert(D.isArrayRangeDesignator());
 1551       assert(SC == Stmt::ArraySubscriptExprClass);
 1564   assert(!S->isTypeDependent() &&
tools/clang/lib/AST/TemplateBase.cpp
  253   assert(getKind() == TemplateExpansion);
  369   assert(isPackExpansion());
  595   assert(TemplateKWLoc.isValid());
tools/clang/lib/AST/TemplateName.cpp
  166     assert(Decl && "all declarations of template are friends");
  183   assert(!getAsOverloadedTemplate() &&
tools/clang/lib/AST/Type.cpp
  678   assert(getTypeArgsAsWritten().size() == typeArgs.size() &&
 1476   assert(dcTypeParams && "No substitutions to perform");
 1477   assert(dcClassDecl && "No class context");
 1597   assert(typeArgs.size() == typeParams->size());
 2051   assert(isScalarType());
 2070     assert(cast<EnumType>(T)->getDecl()->isComplete());
 2105   assert(!isIncompleteType() && "This doesn't make sense for incomplete types");
 2106   assert(!isDependentType() && "This doesn't make sense for dependent types");
 2399   assert(BaseTy && "NULL element type");
 2456   assert(BaseTy && "NULL element type");
 2495   assert(BaseTy && "NULL element type");
 2710   assert((!NNS || NNS->isDependent()) &&
 2965   assert(getNumParams() == params.size() && "NumParams overflow!");
 2993     assert(hasExtraBitfields() && "missing trailing extra bitfields!");
 3012     assert(epi.ExceptionSpec.NoexceptExpr && "computed noexcept with no expr");
 3013     assert((getExceptionSpecType() == EST_DependentNoexcept) ==
 3047       assert(hasDependentExceptionSpec() && "type should not be canonical");
 3159   assert(!(unsigned(epi.Variadic) & ~1) &&
 3448   assert(!T.getAsDependentTemplateName() &&
 3450   assert((T.getKind() == TemplateName::Template ||
 3633     assert(T->isInstantiationDependentType());
 3736     assert(T->isInstantiationDependentType());
 3812   assert(LV.getLinkage() == T->getLinkage());
 4016   assert(isObjCLifetimeType() &&
tools/clang/lib/AST/TypeLoc.cpp
  166   assert(getFullDataSize() == other.getFullDataSize());
tools/clang/lib/AST/TypePrinter.cpp
 1166     assert(Typedef->getIdentifier() && "Typedef without identifier?");
 1311     assert(OwnedTagDecl->getTypeForDecl() == T->getNamedType().getTypePtr() &&
tools/clang/lib/AST/VTTBuilder.cpp
   46     assert(!SecondaryVirtualPointerIndices.count(Base) &&
tools/clang/lib/AST/VTableBuilder.cpp
  142     assert(OverridersMap.count(std::make_pair(MD, BaseOffset)) &&
  185       assert(SubobjectOffsets.count(std::make_pair(MD->getParent(),
  192       assert(M.second.size() == 1 && "Final overrider is not unique!");
  196       assert(SubobjectLayoutClassOffsets.count(
  204       assert(!Overrider.Method && "Overrider should not exist yet!");
  282   assert(CanDerivedReturnType->getTypeClass() ==
  336   assert(!SubobjectOffsets.count(std::make_pair(RD, SubobjectNumber))
  338   assert(!SubobjectLayoutClassOffsets.count(std::make_pair(RD, SubobjectNumber))
  489   assert(LHS->isVirtual() && "LHS must be virtual!");
  490   assert(RHS->isVirtual() && "LHS must be virtual!");
  631       assert(Layout.getVBaseClassOffset(PrimaryBase).isZero() &&
  640       assert(Layout.getBaseClassOffset(PrimaryBase).isZero() &&
  683     assert(Layout.getBaseClassOffset(PrimaryBase).isZero() &&
  753       assert(!VBaseOffsetOffsets.count(BaseDecl) &&
  999     assert(!Context.getTargetInfo().getCXXABI().isMicrosoft());
 1059   assert(!isBuildingConstructorVTable() &&
 1080   assert(MD->isVirtual() && "Method is not virtual!");
 1298     assert(ReturnAdjustment.isEmpty() &&
 1373       assert(Layout.getVBaseClassOffset(PrimaryBase).isZero() &&
 1387       assert(Layout.getBaseClassOffset(PrimaryBase).isZero() &&
 1447       assert(Layout.getVBaseClassOffset(PrimaryBase).isZero() &&
 1462       assert(Layout.getBaseClassOffset(PrimaryBase).isZero() &&
 1501         assert(MethodInfoMap.count(OverriddenMD) &&
 1508         assert(!MethodInfoMap.count(MD) &&
 1551         assert(!ImplicitVirtualDtor &&
 1573     assert(!MethodInfoMap.count(MD) &&
 1626   assert(Base.getBase()->isDynamicClass() && "class does not have a vtable!");
 1667     assert(MethodVTableIndices.empty());
 2048           assert(I.second.getBaseOffset() == BaseOffset &&
 2109         assert(LHS.Method == nullptr && RHS.Method == nullptr);
 2168       assert(MethodVTableIndices.count(GD));
 2173       assert(MethodVTableIndices.count(MD));
 2204     assert(VTableIndices.size() == 1 && VTableIndices[0] == 0);
 2210     assert((LHS.first != RHS.first || LHS.second == RHS.second) &&
 2234   assert(I != MethodVTableIndices.end() && "Did not find index!");
 2261   assert(I != VirtualBaseClassOffsetOffsets.end() && "Did not find index!");
 2475       assert(TI.Return.isEmpty() &&
 2497     assert((HasRTTIComponent ? Components.size() - 1 : Components.size()) &&
 2500     assert(MethodVFTableLocations.empty());
 2504       assert(MD == MD->getCanonicalDecl());
 2712   assert(!First && "Method not found in the given subobject?");
 2821   assert(VBaseMapEntry != VBaseMap.end());
 2917     assert(!Layout.isPrimaryBaseVirtual() &&
 2991         assert(!MethodInfoMap.count(MD) &&
 3019     assert(!MethodInfoMap.count(MD) &&
 3086       assert(T.Virtual.Microsoft.VtordispOffset < 0);
 3091         assert(T.Virtual.Microsoft.VBOffsetOffset > 0);
 3152         assert(Thunk.Return.isEmpty() &&
 3251   assert(Paths.empty());
 3362       assert(Changed && "no paths were extended to fix ambiguity");
 3428       assert(Offset.getQuantity() == -1);
 3432     assert(Offset.getQuantity() != -1);
 3464     assert(!SpecificPath.empty());
 3556   assert(RD->isDynamicClass());
 3576     assert(VFTableLayouts.count(id) == 0);
 3612     assert(MD->isVirtual());
 3642         assert(VBIndex > LastVBIndex || VFPtrOffset > LastVFPtrOffset);
 3703   assert(VBInfo.VBTableIndices.count(VBase));
 3716   assert(VFPtrLocations.count(RD) && "Couldn't find vfptr locations");
 3726   assert(VFTableLayouts.count(id) && "Couldn't find a VFTable at this offset");
 3732   assert(cast<CXXMethodDecl>(GD.getDecl())->isVirtual() &&
 3735     assert(GD.getDtorType() == Dtor_Deleting);
 3748   assert(I != MethodVFTableLocations.end() && "Did not find index!");
tools/clang/lib/ASTMatchers/ASTMatchFinder.cpp
  590     assert((Matchers.size() < USHRT_MAX) && "Too many matchers.");
tools/clang/lib/ASTMatchers/ASTMatchersInternal.cpp
  145   assert(!InnerMatchers.empty() && "Array must not be empty.");
  146   assert(llvm::all_of(InnerMatchers,
  228   assert(RestrictKind.isBaseOf(DynNode.getNodeKind()));
  352     assert(!Name.empty());
  448   assert(UseUnqualifiedMatch);
  540   assert(matchesNodeFullFast(Node) == matchesNodeFullSlow(Node));
  542     assert(matchesNodeUnqualified(Node) == matchesNodeFullFast(Node));
tools/clang/lib/ASTMatchers/Dynamic/Marshallers.h
  622       assert(Overload0Variadic == O->isVariadic());
  632       assert(Overload0NumArgs == O->getNumArgs());
tools/clang/lib/ASTMatchers/Dynamic/Parser.cpp
  355       assert(NamedValue.isMatcher());
  386   assert(Tokenizer->peekNextToken().Kind == TokenInfo::TK_Period);
  427   assert(NameToken.Kind == TokenInfo::TK_Ident);
  535   assert(CompToken.Kind == TokenInfo::TK_CodeCompletion);
tools/clang/lib/ASTMatchers/Dynamic/Registry.cpp
   64   assert(Constructors.find(MatcherName) == Constructors.end());
tools/clang/lib/ASTMatchers/Dynamic/VariantValue.cpp
  147             assert(!IsExactMatch && "We should not have two exact matches.");
  324   assert(isBoolean());
  339   assert(isDouble());
  354   assert(isUnsigned());
  369   assert(isString());
  384   assert(isMatcher());
tools/clang/lib/Analysis/AnalysisDeclContext.cpp
  191   assert(forcedBlkExprs);
  196   assert(itr != forcedBlkExprs->end());
  343   assert(Manager &&
tools/clang/lib/Analysis/BodyFarm.cpp
  124   assert(BinaryOperator::isLogicalOp(Op) ||
  279   assert(CallbackDecl != nullptr);
  280   assert(CallbackDecl->isLambda());
  282   assert(callOperatorDecl != nullptr);
  411     assert(PDecl);
  446   assert(Deref->isLValue());
  614   assert(OldValueTy == NewValueTy);
tools/clang/lib/Analysis/CFG.cpp
  156   assert(isa<DeclRefExpr>(E1) && isa<DeclRefExpr>(E2));
  160   assert(isa<EnumConstantDecl>(Decl1) && isa<EnumConstantDecl>(Decl2));
  164   assert(isa<EnumDecl>(DC1) && isa<EnumDecl>(DC2));
  256       assert(Scope && "Dereferencing invalid iterator is not allowed");
  257       assert(VarIter != 0 && "Iterator has invalid value of VarIter member");
  262       assert(Scope && "Dereferencing invalid iterator is not allowed");
  263       assert(VarIter != 0 && "Iterator has invalid value of VarIter member");
  275       assert(VarIter != 0 && "Iterator has invalid value of VarIter member");
  335     assert(F != const_iterator() &&
  362     assert(F != const_iterator() &&
  398     assert(isKnown());
  795     assert(!isa<Expr>(S) || cast<Expr>(S)->IgnoreParens() == S);
 1012     assert(Value1.isSigned() == Value2.isSigned());
 1036     assert(B->isLogicalOp());
 1300       assert(cachedEntry->first == stmt);
 1313     assert(!cachedEntry);
 1343   assert((isa<CXXConstructExpr>(E) || isa<CallExpr>(E) ||
 1350     assert(PreviouslyStoredLayer->isStrictlyMoreSpecificThan(Layer) &&
 1443       assert(!CO->getType()->getAsCXXRecordDecl() || CO->isGLValue() ||
 1466   assert(BuildOpts.AddRichCXXConstructors &&
 1468   assert(ConstructionContextMap.count(E) &&
 1480   assert(cfg.get());
 1488   assert(Succ == &cfg->getExit());
 1491   assert(!(BuildOpts.AddImplicitDtors && BuildOpts.AddLifetime) &&
 1602     assert(ConstructionContextMap.empty() &&
 1880   assert(BuildOpts.AddImplicitDtors &&
 2019   assert(!(BuildOpts.AddImplicitDtors && BuildOpts.AddLifetime) &&
 2044   assert(BuildOpts.AddLifetime);
 2422       assert(TrueBlock == FalseBlock);
 2474     assert(B->getOpcode() == BO_LAnd);
 2611     assert(!NoReturn && "noreturn calls with unevaluated args not implemented");
 2612     assert(!AddEHEdge && "EH calls with unevaluated args not implemented");
 2810   assert(DS->isSingleDecl() && "Can handle single declarations only.");
 2962     assert(Then);
 3043   assert(isa<ReturnStmt>(S) || isa<CoreturnStmt>(S));
 3179   assert(Terminator->getTryBlock() && "__try must contain a non-NULL body");
 3192   assert(LabelMap.find(L->getDecl()) == LabelMap.end() &&
 3322     assert(F->getBody());
 3342       assert(Block == Succ);
 3413           assert(DS->isSingleDecl());
 3419           assert(Block == EntryConditionBlock);
 3677     assert(W->getBody());
 3743         assert(DS->isSingleDecl());
 3750         assert(Block == EntryConditionBlock);
 3879     assert(D->getBody());
 4036   assert(Terminator->getBody() && "switch must contain a non-NULL body");
 4045   assert(Terminator->getCond() && "switch condition must be non-NULL");
 4180   assert(SwitchTerminatedBlock);
 4278   assert(Terminator->getTryBlock() && "try must contain a non-NULL body");
 4379     assert(BeginConditionBlock == ConditionBlock &&
 4396     assert(S->getBody());
 4415     assert(Block);
 4598   assert(BuildOpts.AddImplicitDtors && BuildOpts.AddTemporaryDtors);
 4803   assert(Context.TerminatorExpr);
 4860     assert(S && "Expected non-null used-in-clause child.");
 4985       assert(classDecl);
 5414     assert(S != nullptr && "Expecting non-null Stmt");
tools/clang/lib/Analysis/CallGraph.cpp
  156   assert(D);
  175   assert(D);
  233       assert(*CI != Root && "No one can call the root node.");
tools/clang/lib/Analysis/CloneDetection.cpp
   25   assert(Stmt && "Stmt must not be a nullptr");
   26   assert(StartIndex < EndIndex && "Given array should not be empty");
   27   assert(EndIndex <= Stmt->size() && "Given array too big for this Stmt");
   75   assert(D);
   90   assert(D);
   91   assert(D->hasBody());
  392           assert(i != 0);
  520     assert(llvm::all_of(Indexes, [](char c) { return c == 1; }));
  566   assert(Other.Occurences.size() == Occurences.size());
  620     assert(FirstMismatch->FirstCloneInfo.Suggestion);
tools/clang/lib/Analysis/ConstructionContext.cpp
   49   assert(MTE);
   72     assert(ElidedItem.getKind() ==
   75     assert(ElidedCE->isElidable());
   91   assert(!ParentLayer);
  111     assert(!cast<VarDecl>(DS->getSingleDecl())->getType().getCanonicalType()
  119     assert(ParentLayer->isLast());
  121     assert(!RS->getRetValue()->getType().getCanonicalType()
  144     assert(ParentLayer->isLast());
  146     assert(isa<CallExpr>(E) || isa<CXXConstructExpr>(E) ||
  152     assert(ParentLayer->isLast());
  154     assert(!I->getAnyMember()->getType().getCanonicalType()
  172     assert(TopLayer->isLast());
  177     assert(TopLayer->isLast());
  182     assert(TopLayer->isLast());
  193     assert(BTE->getType().getCanonicalType()->getAsCXXRecordDecl()
  204     assert(TopLayer->isLast());
  209     assert(TopLayer->isLast());
tools/clang/lib/Analysis/Consumed.cpp
  194   assert(isConsumableType(QT));
  266   assert(isTestingFunction(FunDecl));
  357     assert(InfoType == IT_State);
  362     assert(InfoType == IT_VarTest);
  367     assert(InfoType == IT_BinTest);
  372     assert(InfoType == IT_BinTest);
  377     assert(InfoType == IT_Var);
  382     assert(InfoType == IT_Tmp);
  387     assert(isVar() || isTmp() || isState());
  400     assert(InfoType == IT_BinTest);
  405     assert(InfoType == IT_BinTest);
  425     assert(InfoType == IT_VarTest || InfoType == IT_BinTest);
  448   assert(PInfo.isVar() || PInfo.isTmp());
  582   assert(!PInfo.isTest());
 1005   assert(CurrBlock && "Block pointer must not be NULL");
 1006   assert(TargetBlock && "TargetBlock pointer must not be NULL");
 1020   assert(Block && "Block pointer must not be NULL");
 1034   assert(Block && "Block pointer must not be NULL");
 1046   assert(Block && "Block pointer must not be NULL");
 1047   assert(StateMapsArray[Block->getBlockID()] && "Block has no block info");
 1058   assert(Block && "Block pointer must not be NULL");
 1066   assert(From && "From block must not be NULL");
 1067   assert(To   && "From block must not be NULL");
 1073   assert(Block && "Block pointer must not be NULL");
tools/clang/lib/Analysis/LiveVariables.cpp
  465     assert(subEx->isLValue());
tools/clang/lib/Analysis/PathDiagnostic.cpp
  220     assert(orig != D.get());
  383   assert(b.hasValue());
  402         assert(*X != *Y && "PathDiagnostics not uniqued!");
  405         assert(compare(**Y, **X) && "Not a total order!");
  465   assert(!LAC.isNull() &&
  604   assert(ME->getMemberLoc().isValid() || ME->getBeginLoc().isValid());
  666         assert(BSrc == &BSrc->getParent()->getEntry() && "CFGBlock has no "
  729   assert(isValid());
  754   assert(isValid());
 1000   assert(callEnter.asLocation().isValid());
 1045   assert(callReturn.asLocation().isValid());
tools/clang/lib/Analysis/ProgramPoint.cpp
  169           assert(isa<DefaultStmt>(Label));
  187     assert(S != nullptr && "Expecting non-null Stmt");
tools/clang/lib/Analysis/ReachableCode.cpp
  117       assert(Current->succ_size() == 2);
  138   assert(Loc.isMacroID());
  349           assert(PP);
tools/clang/lib/Analysis/RetainSummaryManager.cpp
  235   assert(TrackOSObjects &&
  458       assert(ScratchArgs.isEmpty());
  694   assert(Summ && "Unknown call type?");
  974   assert(Summ && "Must have a summary to add annotations to.");
  997   assert(Summ && "Must have a valid summary to add annotations to");
 1114   assert(!ME->isInstanceMessage());
tools/clang/lib/Analysis/ThreadSafety.cpp
  432     assert(*i < VarDefinitions.size());
  529     assert(!Ctx.contains(D));
  681     assert(VDef->isReference());
  960     assert(!Cp.negative() && "Managing object cannot be negative.");
 1133   assert(Info && "BMap contained nullptr?");
 1245   assert(VD && "No ValueDecl passed");
tools/clang/lib/Analysis/ThreadSafetyCommon.cpp
  287         assert(I < Ctx->NumArgs);
  307   assert(SelfVar && "We have no variable for 'this'!");
  652     assert(CurrentLVarMap[It->second].first == VD);
  696   assert(ArgIndex > 0 && ArgIndex < NPreds);
  703     assert(Ph && "Expecting Phi node.");
  735   assert(CurrentBlockInfo && "Not processing a block!");
  777   assert(CurrentBlockInfo && "Not processing a block!");
  797   assert(ArgIndex > 0 && ArgIndex < BB->numPredecessors());
  801     assert(Ph && "Expecting Phi Node.");
  802     assert(Ph->values()[ArgIndex] == nullptr && "Wrong index for back edge.");
  805     assert(E && "Couldn't find local variable for Phi node.");
  861   assert(PredInfo->UnprocessedSuccessors > 0);
tools/clang/lib/Analysis/ThreadSafetyTIL.cpp
  134   assert(Ph && Ph->status() == Phi::PH_Incomplete);
  173   assert(ID > 0);
  199   assert(static_cast<size_t>(ID) < Blocks.size());
  310   assert(static_cast<size_t>(NumBlocks) == Blocks.size());
tools/clang/lib/Analysis/UninitializedValues.cpp
  150     assert(idx.hasValue());
  211   assert(idx.hasValue());
  232       assert(*PO_I == &cfg.getEntry());
  272   assert(enqueuedBlocks[B->getBlockID()] == true);
  554     assert(isUninitialized(v));
  720     assert(S && "Expected non-null used-in-clause child.");
tools/clang/lib/Basic/Builtins.cpp
   34   assert(((ID - Builtin::FirstTSBuiltin) <
   44   assert(TSRecords.empty() && "Already initialized target?");
  119   assert(*WidthPos == ':' &&
  125   assert(*EndPos == ':' && "Vector width specific must end with a ':'");
  131   assert(Fmt && "Not passed a format string");
  132   assert(::strlen(Fmt) == 2 &&
  134   assert(::toupper(Fmt[0]) == Fmt[1] &&
  144   assert(*Like == ':' && "Format specifier must be followed by a ':'");
  147   assert(::strchr(Like, ':') && "Format specifier must end with a ':'");
  169   assert(*CalleePos == '<' &&
  175   assert(CalleeIdx >= 0 && "Callee index is supposed to be positive!");
  185   assert(*EndPos == '>' && "Callback callee specifier must end with a '>'");
tools/clang/lib/Basic/Diagnostic.cpp
  164   assert(Files.empty() && "not first");
  181     assert(Last.Offset <= Offset && "state transitions added out of order");
  212   assert(OnePastIt != StateTransitions.begin() && "missing initial state");
  265         assert(File.ParentOffset == Decomp.second);
  337   assert(Loc.isValid() && "Adding invalid loc point");
  343   assert(Diag < diag::DIAG_UPPER_LIMIT &&
  345   assert((Diags->isBuiltinWarningOrExtension(Diag) ||
  348   assert((L.isInvalid() || SourceMgr) && "No SourceMgr for valid location");
  472   assert(CurDiagID == std::numeric_limits<unsigned>::max() &&
  485   assert(Client && "DiagnosticConsumer not set!");
  498   assert(getClient() && "DiagnosticClient not set!");
  589     assert(NextVal != ArgumentEnd && "Value for integer select modifier was"
  617   assert(ValNo != 0 && "ValNo must be strictly positive!");
  647   assert(*Start == ',' && "Bad plural expression syntax: expected ,");
  650   assert(*Start == ']' && "Bad plural expression syntax: expected )");
  667       assert(*Start == '=' && "Bad plural expression syntax: expected =");
  673       assert((C == '[' || (C >= '0' && C <= '9')) &&
  727     assert(Argument < ArgumentEnd && "Plural expression didn't match.");
  730       assert(ExprEnd != ArgumentEnd && "Plural missing expression end");
  845         assert(DiagStr != DiagEnd && "Mismatched {}'s in diagnostic string!");
  851     assert(isDigit(*DiagStr) && "Invalid format for argument in diagnostic");
  859       assert(*DiagStr == ',' && isDigit(*(DiagStr + 1)) &&
  875         assert(ScanFormat(Pipe + 1, ArgumentEnd, '|') == ArgumentEnd &&
  894       assert(ModifierLen == 0 && "No modifiers for strings yet");
  900       assert(ModifierLen == 0 && "No modifiers for strings yet");
  924         assert(ModifierLen == 0 && "Unknown integer modifier");
  942         assert(ModifierLen == 0 && "Unknown integer modifier");
  950       assert(ModifierLen == 0 && "No modifiers for token kinds yet");
  972       assert(ModifierLen == 0 && "No modifiers for strings yet");
 1090   assert((Info.getLocation().isInvalid() || Info.hasSourceManager()) &&
 1144   assert((NumFreeListEntries == NumCached ||
tools/clang/lib/Basic/DiagnosticIDs.cpp
  161   assert(ID < StaticDiagInfoSize && Offset < StaticDiagInfoSize);
  180       assert(Info.getSeverity() == diag::Severity::Warning &&
  278         assert(DiagID - DIAG_UPPER_LIMIT < DiagInfo.size() &&
  285         assert(DiagID - DIAG_UPPER_LIMIT < DiagInfo.size() &&
  375   assert(CustomDiagInfo && "Invalid CustomDiagInfo");
  403     assert(CustomDiagInfo && "Invalid CustomDiagInfo");
  421   assert(getBuiltinDiagClass(DiagID) != CLASS_NOTE);
  632   assert(Diag.getClient() && "DiagnosticClient not set!");
  712   assert(DiagLevel != DiagnosticIDs::Ignored && "Cannot emit ignored diagnostics!");
  725     assert(CustomDiagInfo && "Invalid CustomDiagInfo");
tools/clang/lib/Basic/FileManager.cpp
   64   assert(statCache && "No stat cache provided?");
  151   assert(!NamedDirEnt.second && "should be newly-created");
  225   assert(!NamedFileEnt.second && "should be newly-created");
  265   assert((openFile || !F) && "undesired open file");
  278     assert((*NewNamedFileEnt.second).get<FileEntry *>() == &UFE &&
  357   assert(DirInfo &&
tools/clang/lib/Basic/IdentifierTable.cpp
  373     assert((nKeys > 1) && "not a multi-keyword selector");
  397     assert(i < getNumArgs() && "getIdentifierInfoForSlot(): illegal index");
  416   assert(!Names.empty() && "must have >= 1 selector slots");
  443     assert(argIndex == 0 && "illegal keyword index");
  477       assert(II && "If the number of arguments is 0 then II is guaranteed to "
  642   assert(Name.startswith("set") && "invalid setter name");
tools/clang/lib/Basic/Module.cpp
  403   assert(VisibleModulesCache.empty() && "cache does not need building");
  486     assert(&K == &Kinds[K.Kind] && "kinds in wrong order");
  614   assert(Loc.isValid() && "setVisible expects a valid import location");
tools/clang/lib/Basic/OpenMPKinds.cpp
   31   assert(Kind <= OMPD_unknown);
   64   assert(Kind <= OMPC_unknown);
  408   assert(DKind <= OMPD_unknown);
  409   assert(CKind <= OMPC_unknown);
 1045   assert(DKind <= OMPD_unknown);
tools/clang/lib/Basic/SourceLocation.cpp
  141   assert(isValid());
  146   assert(isValid());
  151   assert(isValid());
  156   assert(isValid());
  168   assert(isValid());
  173   assert(isValid());
  188   assert(isValid());
  193   assert(isValid());
  198   assert(isValid());
  203   assert(isValid());
  208   assert(isValid());
  213   assert(isValid());
  218   assert(isValid());
  223   assert(isValid());
  228   assert(isValid());
  233   assert(isValid());
  242   assert(isValid());
  247   assert(isValid());
tools/clang/lib/Basic/SourceManager.cpp
   66   assert(Buffer.getPointer());
   87     assert(0 && "Replacing with the same buffer");
  253   assert((Entries.empty() || Entries.back().FileOffset < Offset) &&
  262     assert(!Entries.empty() && Entries.back().IncludeOffset &&
  281   assert(!Entries.empty() && "No #line entries for this FID after all!");
  393   assert(MainFileID.isInvalid() && "expected uninitialized SourceManager");
  425   assert(FileEnt && "Didn't specify a file entry to use?");
  470   assert(!SLocEntryLoaded[Index]);
  489   assert(ExternalSLocEntries && "Don't have an external sloc source");
  571     assert(LoadedID != -1 && "Loading sentinel FileID");
  573     assert(Index < LoadedSLocEntryTable.size() && "FileID out of range");
  574     assert(!SLocEntryLoaded[Index] && "FileID already loaded");
  584   assert(NextLocalOffset + FileSize + 1 > NextLocalOffset &&
  622   assert(getFileID(TokenStart) == getFileID(TokenEnd) &&
  635     assert(LoadedID != -1 && "Loading sentinel FileID");
  637     assert(Index < LoadedSLocEntryTable.size() && "FileID out of range");
  638     assert(!SLocEntryLoaded[Index] && "FileID already loaded");
  644   assert(NextLocalOffset + TokLength + 1 > NextLocalOffset &&
  655   assert(IR && "getOrCreateContentCache() cannot return NULL");
  663   assert(IR && "getOrCreateContentCache() cannot return NULL");
  673   assert(SourceFile->getSize() == NewFile->getSize() &&
  676   assert(FileInfos.count(SourceFile) == 0 &&
  684   assert(isFileOverridden(&File));
  747   assert(SLocOffset < NextLocalOffset && "Bad function choice");
  840     assert(0 && "Invalid SLocOffset or bad function choice");
  887         assert(0 && "binary search missed the entry");
  904       assert(0 && "binary search missed the entry");
  997   assert(Loc.isMacroID() && "Not a macro expansion loc!");
 1051   assert(Loc.isValid() && Loc.isMacroID() && "Expected a valid macro loc");
 1086   assert(Loc.isValid() && Loc.isMacroID() && "Expected a valid macro loc");
 1405   assert(Loc.isValid() && "Can't get file characteristic of invalid loc!");
 1419   assert(LineTable && "Can't have linetable entries without a LineTable!");
 1485     assert(LineTable && "Can't have linetable entries without a LineTable!");
 1577   assert(SourceFile && "Null source file!");
 1578   assert(Line && Col && "Line and column should start from 1!");
 1589   assert(SourceFile && "Null source file!");
 1638   assert(Line && Col && "Line and column should start from 1!");
 1701   assert(FID.isValid());
 1799   assert(SpellLoc.isFileID());
 1857   assert(!MacroArgsCache->empty());
 1943   assert(LHS.isValid() && RHS.isValid() && "Passed invalid source location!");
 1981     assert(LOffs.first == ROffs.first);
 2191   assert(ID.isValid());
tools/clang/lib/Basic/TargetInfo.cpp
  368     assert(MaxPointerWidth == 32 || MaxPointerWidth == 64);
  504   assert(isValidGCCRegisterName(Name) && "Invalid register passed in");
  515       assert(n < Names.size() && "Out of bounds register number!");
  620   assert(*Name == '[' && "Symbolic name did not start with '['");
  760   assert(ShortAccumScale + getShortAccumIBits() + 1 <= ShortAccumWidth);
  761   assert(AccumScale + getAccumIBits() + 1 <= AccumWidth);
  762   assert(LongAccumScale + getLongAccumIBits() + 1 <= LongAccumWidth);
  763   assert(getUnsignedShortAccumScale() + getUnsignedShortAccumIBits() <=
  765   assert(getUnsignedAccumScale() + getUnsignedAccumIBits() <= AccumWidth);
  766   assert(getUnsignedLongAccumScale() + getUnsignedLongAccumIBits() <=
  769   assert(getShortFractScale() + 1 <= ShortFractWidth);
  770   assert(getFractScale() + 1 <= FractWidth);
  771   assert(getLongFractScale() + 1 <= LongFractWidth);
  772   assert(getUnsignedShortFractScale() <= ShortFractWidth);
  773   assert(getUnsignedFractScale() <= FractWidth);
  774   assert(getUnsignedLongFractScale() <= LongFractWidth);
  778   assert(getShortFractScale() == getUnsignedShortFractScale() ||
  780   assert(getFractScale() == getUnsignedFractScale() ||
  782   assert(getLongFractScale() == getUnsignedLongFractScale() ||
  792   assert(getLongFractScale() >= getFractScale() &&
  794   assert(getUnsignedLongFractScale() >= getUnsignedFractScale() &&
  796   assert(LongAccumScale >= AccumScale && AccumScale >= ShortAccumScale);
  797   assert(getUnsignedLongAccumScale() >= getUnsignedAccumScale() &&
  805   assert(getLongAccumIBits() >= getAccumIBits() &&
  807   assert(getUnsignedLongAccumIBits() >= getUnsignedAccumIBits() &&
  812   assert(getShortAccumIBits() >= getUnsignedShortAccumIBits());
  813   assert(getAccumIBits() >= getUnsignedAccumIBits());
  814   assert(getLongAccumIBits() >= getUnsignedLongAccumIBits());
tools/clang/lib/Basic/Targets.cpp
   56   assert(MacroName[0] != '_' && "Identifier should be in the user's namespace");
tools/clang/lib/Basic/Targets/AArch64.cpp
   83   assert(UseBitFieldTypeAlignment && "bitfields affect type alignment");
  539   assert(!getTriple().isOSBinFormatMachO());
tools/clang/lib/Basic/Targets/AMDGPU.cpp
  272   assert(DataLayout->getAllocaAddrSpace() == Private);
  338   assert(HalfFormat == Aux->HalfFormat);
  339   assert(FloatFormat == Aux->FloatFormat);
  340   assert(DoubleFormat == Aux->DoubleFormat);
tools/clang/lib/Basic/Targets/ARM.cpp
   46     assert(!BigEndian && "Windows on ARM does not support big endian");
   57     assert(!BigEndian && "NaCl on ARM does not support big endian");
   90     assert(!BigEndian && "AAPCS16 does not support big-endian");
 1121   assert((Triple.getArch() == llvm::Triple::arm ||
tools/clang/lib/Basic/Targets/NVPTX.cpp
   39   assert((TargetPointerWidth == 32 || TargetPointerWidth == 64) &&
  202         assert(false && "No GPU arch when compiling CUDA device code.");
tools/clang/lib/Basic/Targets/OSTargets.cpp
   70     assert(Maj < 100 && Min < 100 && Rev < 100 && "Invalid version!");
   96     assert(Maj < 10 && Min < 100 && Rev < 100 && "Invalid version!");
  110     assert(Maj < 100 && Min < 100 && Rev < 100 && "Invalid version!");
tools/clang/lib/Basic/Targets/OSTargets.h
  786       assert(Triple.getArch() == llvm::Triple::le32);
tools/clang/lib/Basic/Targets/SPIR.h
   40     assert(getTriple().getOS() == llvm::Triple::UnknownOS &&
   42     assert(getTriple().getEnvironment() == llvm::Triple::UnknownEnvironment &&
tools/clang/lib/CodeGen/Address.h
   30     assert((!alignment.isZero() || pointer == nullptr) &&
   38     assert(isValid());
   67     assert(isValid());
tools/clang/lib/CodeGen/BackendUtil.cpp
  404   assert(CodeModel != ~0u && "invalid code model!");
  416     assert(Action == Backend_EmitAssembly && "Invalid action!");
  432   assert((CodeGenOpts.FloatABI == "soft" || CodeGenOpts.FloatABI == "softfp" ||
  712     assert(!CodeGenOpts.hasProfileCSIRUse() &&
  715     assert(!hasIRInstr &&
 1044     assert(!CodeGenOpts.hasProfileCSIRUse() &&
 1048       assert(PGOOpt->Action != PGOOptions::IRInstr &&
 1644     assert(Old->hasOneUse() &&
 1667       assert(Old->hasOneUse() &&
tools/clang/lib/CodeGen/CGAtomic.cpp
   46       assert(!lvalue.isGlobalReg());
   66         assert(ValueSizeInBits <= AtomicSizeInBits);
   67         assert(ValueAlignInBits <= AtomicAlignInBits);
  118         assert(lvalue.isExtVectorElt());
  147       assert(LVal.isExtVectorElt());
  200       assert(LVal.isSimple());
  345   assert(LVal.isSimple());
 1174     assert(UseOptimizedLibcall || !PostOp);
 1323   assert(Atomics.getValueSizeInBits() <= Atomics.getAtomicSizeInBits());
 1378   assert(LVal.isExtVectorElt());
 1389   assert(IntVal->getType()->isIntegerTy() && "Expected integer value");
 1399       assert(IntVal->getType() == ValTy && "Different integer types.");
 1412     assert(!ResultSlot.isIgnored());
 1492       assert(getEvaluationKind() == TEK_Aggregate);
 1529   assert(LVal.isSimple());
 1714       assert(AtomicLVal.isExtVectorElt());
 1730     assert(NewRVal.isComplex());
 1813     assert(AtomicLVal.isExtVectorElt());
 1819   assert(UpdateRVal.isScalar());
 1919   assert(!rvalue.isAggregate() ||
 1986   assert(!Expected.isAggregate() ||
 1989   assert(!Desired.isAggregate() ||
tools/clang/lib/CodeGen/CGBlocks.cpp
  143         assert(E.CopyKind != BlockCaptureEntityKind::None &&
  450   assert(elementTypes.empty());
  460     assert(CGM.getIntSize() <= GenPtrSize);
  461     assert(CGM.getIntAlign() <= GenPtrAlign);
  462     assert((2 * CGM.getIntSize()).isMultipleOf(GenPtrAlign));
  479         assert(Offset % Align == 0);
  489     assert(CGM.getIntSize() <= CGM.getPointerSize());
  490     assert(CGM.getIntAlign() <= CGM.getPointerAlign());
  491     assert((2 * CGM.getIntSize()).isMultipleOf(CGM.getPointerAlign()));
  552     assert(CGF && CGF->CurFuncDecl && isa<CXXMethodDecl>(CGF->CurFuncDecl) &&
  582       assert(getCaptureFieldType(*CGF, CI) == variable->getType() &&
  712         assert(endAlign >= li->Alignment);
  729   assert(endAlign == getLowBit(blockSize));
  749   assert(endAlign >= maxFieldAlign);
  750   assert(endAlign == getLowBit(blockSize));
  766     assert(endAlign >= li->Alignment);
  781   assert(CGF.HaveInsertPoint());
  831       assert(CGF.CGM.getLangOpts().ObjCAutoRefCount &&
  866     assert(EWC->getNumObjects() != 0);
  876     assert(head && *head);
  891   assert(head && "destroying an empty chain");
  948   assert(blockAddr.isValid() && "block has no address!");
 1071         assert(I != LocalDeclMap.end());
 1319   assert(BlockInfo && "evaluating block ref without block information?");
 1342   assert((!variable->isNonEscapingByref() ||
 1356   assert(Ok && "Trying to replace an already-existing global block!");
 1385   assert(blockInfo.CanBeGlobal);
 1389   assert(!CGM.getAddrOfGlobalBlockIfEmitted(blockInfo.BlockExpression) &&
 1478   assert(BlockInfo && "not emitting prologue of block invocation function?!");
 1509   assert(BlockInfo && "not in a block invocation function!");
 1510   assert(BlockPointer && "no block pointer set!");
 1693     assert(!CI.isByRef());
 1823   assert((StrKind != CaptureStrKind::Merged ||
 1870       assert((F & BLOCK_FIELD_IS_OBJECT) && "unexpected flag value");
 1908   assert((StrKind == CaptureStrKind::CopyHelper ||
 2063       assert(CI.getCopyExpr() && "copy expression for variable is missing");
 2610   assert(var.isEscapingByref() &&
 2812   assert(pair.second && "info was inserted recursively?");
 2955     assert((isa<llvm::Function>(C->stripPointerCasts()) ||
tools/clang/lib/CodeGen/CGBlocks.h
  175       assert(isIndex());
  179       assert(isIndex());
  183       assert(isIndex());
  187       assert(isIndex());
  192       assert(isConstant());
  276     assert(it != Captures.end() && "no entry for variable!");
  282     assert(BlockExpression);
  283     assert(BlockExpression->getBlockDecl() == Block);
tools/clang/lib/CodeGen/CGBuilder.h
  101     assert(Addr->getType()->getPointerElementType() == Ty);
  130     assert(Addr->getType()->getPointerElementType() == getInt1Ty());
  136     assert(Addr->getType()->getPointerElementType() == getInt1Ty());
  246     assert(Addr.getElementType() == TypeCache.Int8Ty);
  252     assert(Addr.getElementType() == TypeCache.Int8Ty);
tools/clang/lib/CodeGen/CGBuiltin.cpp
   71   assert(Context.BuiltinInfo.isLibFunction(BuiltinID));
  100   assert(V->getType() == IntType);
  111   assert(V->getType() == ResultType);
  121   assert(E->getArg(0)->getType()->isPointerType());
  122   assert(CGF.getContext().hasSameUnqualifiedType(T,
  124   assert(CGF.getContext().hasSameUnqualifiedType(T, E->getArg(1)->getType()));
  182   assert(E->getArg(0)->getType()->isPointerType());
  183   assert(CGF.getContext().hasSameUnqualifiedType(T,
  185   assert(CGF.getContext().hasSameUnqualifiedType(T, E->getArg(1)->getType()));
  271   assert(E->getArg(0)->getType()->isPointerType());
  272   assert(CGF.getContext().hasSameUnqualifiedType(
  274   assert(CGF.getContext().hasSameUnqualifiedType(E->getType(),
  276   assert(CGF.getContext().hasSameUnqualifiedType(E->getType(),
  297   assert(E->getArg(0)->getType()->isPointerType());
  310   assert(E->getArg(0)->getType()->isPointerType());
  465   assert(X->getType() == Y->getType() &&
  496   assert(Type->isIntegerType() && "Given type is not an integer.");
  507   assert(Types.size() > 0 && "Empty list of types.");
  586       assert(Iter != SizeArguments.end());
  590       assert(DIter != LocalDeclMap.end());
  604   assert(Ptr->getType()->isPointerTy() &&
 1094   assert((Kind == BCK_CLZPassedZero || Kind == BCK_CTZPassedZero)
 1225   assert(E.getNumArgs() >= 2 &&
 1254         assert(getEvaluationKind(TheExpr->getType()) == TEK_Scalar &&
 1314   assert(isSpecialMixedSignMultiply(Builtin::BI__builtin_mul_overflow, Op1Info,
 1387   assert(Overflow && Result && "Missing overflow or result");
 1494   assert(Record->hasDefinition() &&
 2612     assert((IntTy->getBitWidth() == 32 || IntTy->getBitWidth() == 64) &&
 3115       assert(Str->getCharByteWidth() == 2);
 3590       assert(4 == E->getNumArgs() &&
 3783     assert(NumArgs >= 5 && "Invalid enqueue_kernel signature");
 4154     assert(Error == ASTContext::GE_None && "Should not codegen an error");
 4169         assert(IsConst && "Constant arg isn't actually constant?");
 4188         assert(PTy->canLosslesslyBitCastTo(FTy->getParamType(i)) &&
 4212       assert(V->getType()->canLosslesslyBitCastTo(RetTy) &&
 4275     assert(getContext().getAuxTargetInfo() && "Missing aux target info");
 5120     assert(std::is_sorted(std::begin(IntrinsicMap), std::end(IntrinsicMap)));
 5201   assert(Int && "Generic code assumes a valid intrinsic");
 5217     assert(ArgTy->isVectorTy() && !Ops[j]->getType()->isVectorTy());
 5801   assert(Int && "Expected valid intrinsic number");
 5917   assert((RegisterType->isIntegerTy(32) || RegisterType->isIntegerTy(64))
 5936   assert(!(RegisterType->isIntegerTy(32) && ValueType->isIntegerTy(64))
 6069     assert(E->getNumArgs() == 2 && "__clear_cache takes 2 arguments");
 6345   assert(Error == ASTContext::GE_None && "Should not codegen an error");
 6423       assert(IsConst && "Constant arg isn't actually constant?"); (void)IsConst;
 6623   assert(HasExtraArg);
 6818     assert(MvecLType->isStructTy() &&
 6820     assert(MvecLType->getStructNumElements() == 1 &&
 6823     assert(MvecLTypeInner->isArrayTy() &&
 6825     assert(MvecLTypeInner->getArrayNumElements() == NumVectors &&
 6859     assert(MvecLType->isStructTy() && "Data type for vst2q should be a struct");
 6860     assert(MvecLType->getStructNumElements() == 1 &&
 6863     assert(MvecLTypeInner->isArrayTy() &&
 6865     assert(MvecLTypeInner->getArrayNumElements() == NumVectors &&
 6928   assert(E->getNumArgs() >= 3);
 7107     assert((getContext().getTypeSize(E->getType()) == 32) &&
 7114     assert((getContext().getTypeSize(E->getType()) == 64) &&
 7133     assert((getContext().getTypeSize(E->getType()) == 32) &&
 7141     assert(E->getNumArgs() == 2 && "__clear_cache takes 2 arguments");
 7463   assert(Error == ASTContext::GE_None && "Should not codegen an error");
 7474       assert(IsConst && "Constant arg isn't actually constant?");
 7487     assert(Result && "SISD intrinsic should have been handled");
 8602     assert(Type.getEltType() == NeonTypeFlags::Float64 && quad &&
 8610     assert(Type.getEltType() == NeonTypeFlags::Float32 &&
 9434   assert(BuiltinID == BPF::BI__builtin_preserve_field_info &&
 9465   assert((Ops.size() & (Ops.size() - 1)) == 0 &&
 9708   assert((Ops.size() == 2 || Ops.size() == 4) &&
 9779   assert(Ops.size() == 2);
10054   assert(Value != 0 && "Invalid CPUStr passed to CpuIs");
10171   assert(Error == ASTContext::GE_None && "Should not codegen an error");
10184     assert(IsConst && "Constant arg isn't actually constant?"); (void)IsConst;
10867     assert(llvm::isPowerOf2_32(SubVectors) && "Expected power of 2 subvectors");
10905     assert(llvm::isPowerOf2_32(SubVectors) && "Expected power of 2 subvectors");
11111     assert(NumElts % 16 == 0);
12660     assert(ArgCI &&
12706     assert(ArgCI &&
12735     assert(ArgCI && "Third arg must be constant integer!");
12760     assert(ArgCI && "Third argument must be a compile time constant");
12874     assert(Args.size() == 5 || Args.size() == 6);
13173     assert(IsConstM4 && IsConstM5 && "Constant arg isn't actually constant?");
13219     assert(IsConstM4 && "Constant arg isn't actually constant?");
13249     assert(IsConstM4 && "Constant arg isn't actually constant?");
13923     assert(II.NumResults);
tools/clang/lib/CodeGen/CGCUDANV.cpp
  104     assert(FnTy->getReturnType()->isVoidTy() &&
  231   assert((CGF.CGM.getContext().getAuxTargetInfo() &&
  708     assert(RegisterGlobalsFunc && "Expecting at least dummy function!");
tools/clang/lib/CodeGen/CGCXX.cpp
  191     assert(Entry->getType() == AliasType &&
  250   assert(!CGF.CGM.getTarget().getCXXABI().isMicrosoft() &&
  256   assert(VTable && "BuildVirtualCall = kext vtbl pointer is null");
  278   assert((Qual->getKind() == NestedNameSpecifier::TypeSpec) &&
  284   assert(RT && "BuildAppleKextVirtualCall - Qual type must be record");
  300   assert(DD->isVirtual() && Type != Dtor_Base);
tools/clang/lib/CodeGen/CGCXXABI.cpp
  152   assert(getThisDecl(CGF) && "no 'this' variable for function");
  234   assert(E->getCastKind() == CK_DerivedToBaseMemberPointer ||
tools/clang/lib/CodeGen/CGCall.cpp
  117   assert(proto->hasExtParameterInfos());
  118   assert(paramInfos.size() <= prefixArgs);
  119   assert(proto->getNumParams() + prefixArgs <= totalArgs);
  134   assert(paramInfos.size() <= totalArgs &&
  148     assert(paramInfos.empty() &&
  161   assert(ExtInfos.size() == FPT->getNumParams());
  279   assert(!isa<CXXConstructorDecl>(MD) && "wrong method for constructors!");
  280   assert(!isa<CXXDestructorDecl>(MD) && "wrong method for destructors!");
  440   assert(isa<FunctionType>(FTy));
  530   assert(MD->isVirtual() && "only methods have thunks");
  541   assert(CT == Ctor_CopyingClosure || CT == Ctor_DefaultClosure);
  568   assert(args.size() >= numExtraRequiredArgs);
  678   assert(numPrefixArgs + 1 <= args.size() &&
  703   assert(signature.arg_size() <= args.size());
  716   assert(signature.getRequiredArgs().allowsOptionalArgs());
  743   assert(llvm::all_of(argTypes,
  765   assert(inserted && "Recursively being processed?");
  790   assert(erased && "Not in set?");
  803   assert(paramInfos.empty() || paramInfos.size() == argTypes.size());
  804   assert(!required.allowsOptionalArgs() ||
  913     assert(!RD->hasFlexibleArrayMember() &&
  924         assert(!FD->isBitField() &&
  936         assert(!CXXRD->isDynamicClass() &&
  945         assert(!FD->isBitField() &&
  974   assert(isa<NoExpansion>(Exp.get()));
  996     assert(isa<NoExpansion>(Exp.get()));
 1018   assert(LV.isSimple() &&
 1050     assert(isa<NoExpansion>(Exp.get()));
 1097     assert(isa<NoExpansion>(Exp.get()));
 1099     assert(RV.isScalar() &&
 1389     assert(hasInallocaArg());
 1395     assert(hasSRetArg());
 1402     assert(ArgNo < ArgInfo.size());
 1406     assert(hasPaddingArg(ArgNo));
 1413     assert(ArgNo < ArgInfo.size());
 1439     assert(I != FI.arg_end());
 1486   assert(ArgNo == ArgInfo.size());
 1545   assert(Inserted && "Recursively being processed?");
 1595     assert(ArgStruct);
 1617       assert(NumIRArgs == 0);
 1621       assert(NumIRArgs == 1);
 1636         assert(NumIRArgs == st->getNumElements());
 1640         assert(NumIRArgs == 1);
 1651       assert(ArgTypesIter == ArgTypes.begin() + FirstIRArg + NumIRArgs);
 1658       assert(ArgTypesIter == ArgTypes.begin() + FirstIRArg + NumIRArgs);
 1664   assert(Erased && "Not in set?");
 2075       assert(!Align.isZero());
 2155   assert(ArgNo == FI.arg_size());
 2173   assert((varType->isIntegerTy() || varType->isFloatingPointTy())
 2252   assert(FnArgs.size() == IRFunctionArgs.totalIRArgs());
 2261     assert(ArgStruct.getType() == FI.getArgStruct()->getPointerTo());
 2281   assert(FI.arg_size() == Args.size() &&
 2296     assert(hasScalarEvaluationKind(Ty) ==
 2304       assert(NumIRArgs == 0);
 2313       assert(NumIRArgs == 1);
 2355         assert(NumIRArgs == 1);
 2423           assert(pointeeTy->isPointerType());
 2479         assert(STy->getNumElements() == NumIRArgs);
 2493         assert(NumIRArgs == 1);
 2530       assert(argIndex == FirstIRArg + NumIRArgs);
 2544       assert(FnArgIter == FnArgs.begin() + FirstIRArg + NumIRArgs);
 2553       assert(NumIRArgs == 0);
 2636       assert(prev);
 2639         assert(prev);
 2641       assert(isa<llvm::CallInst>(prev));
 2642       assert(cast<llvm::CallInst>(prev)->getCalledValue() ==
 2703   assert(retainCall->use_empty());
 2741     assert(!SI->isAtomic() && !SI->isVolatile());
 2823     assert(hasAggregateEvaluationKind(RetTy));
 2908       assert(getLangOpts().ObjCAutoRefCount &&
 2986     assert(!requiresReturnValueNullabilityCheck() &&
 3099     assert(cleanup.isValid() &&
 3116   assert(!isProvablyNull(srcAddr.getPointer()) &&
 3150     assert(srcLV.getObjCLifetime() == Qualifiers::OCL_Strong);
 3292     assert(srcRV.isScalar());
 3335   assert(!StackBase);
 3392   assert(RV.isScalar());
 3407   assert((int)ArgTypes.size() == (ArgRange.end() - ArgRange.begin()));
 3430     assert(EmittedArg.getScalarVal() && "We emitted nothing for the arg?");
 3448       assert(getTarget().getTriple().getArch() == llvm::Triple::x86);
 3461     assert((!isa<ObjCIndirectCopyRestoreExpr>(*Arg) ||
 3470     assert(InitialArgSize + 1 == Args.size() &&
 3506       assert(!Dtor->isTrivial());
 3562     assert(getLangOpts().ObjCAutoRefCount);
 3566   assert(type->isReferenceType() == E->isGLValue() &&
 3570     assert(E->getObjectKind() == OK_Ordinary);
 3618     assert(L.isSimple());
 3787   assert(Callee.isOrdinary() || Callee.isVirtual());
 3823     assert(IRFuncTy == TypeFromVal);
 3846     assert(AI->isUsedWithInAlloca() && !AI->isStaticAlloca());
 3887   assert(CallInfo.arg_size() == CallArgs.size() &&
 3905       assert(NumIRArgs == 0);
 3906       assert(getTarget().getTriple().getArch() == llvm::Triple::x86);
 3937       assert(NumIRArgs == 1);
 3961         assert((FirstIRArg >= IRFuncTy->getNumParams() ||
 4028       assert(NumIRArgs == 0);
 4036         assert(NumIRArgs == 1);
 4049           assert(!swiftErrorTemp.isValid() && "multiple swifterror args");
 4116         assert(NumIRArgs == STy->getNumElements());
 4124         assert(NumIRArgs == 1);
 4145         assert(RV.isScalar()); // complex should always just be direct
 4173       assert(IRArgPos == FirstIRArg + NumIRArgs);
 4185       assert(IRArgPos == FirstIRArg + NumIRArgs);
 4213         assert(DeclaredTy->getNumElements() == FullTy->getNumElements());
 4218           assert(*DI == *FI);
 4223     assert(IRFunctionArgs.hasInallocaArg());
 4283   assert(IRCallArgs.size() == IRFuncTy->getNumParams() || IRFuncTy->isVarArg());
 4290       assert(IRCallArgs[i]->getType() == IRFuncTy->getParamType(i));
 4475       assert(CI->getType() == RetAI.getUnpaddedCoerceAndExpandType());
 4487           assert(unpaddedIndex == 0);
tools/clang/lib/CodeGen/CGCall.h
  114       assert(functionPtr && "configuring callee without function pointer");
  115       assert(functionPtr->getType()->isPointerTy());
  116       assert(functionPtr->getType()->getPointerElementType()->isFunctionTy());
  158       assert(isBuiltin());
  162       assert(isBuiltin());
  170       assert(isPseudoDestructor());
  180       assert(isOrdinary());
  184       assert(isOrdinary());
  188       assert(isOrdinary());
  196       assert(isVirtual());
  200       assert(isVirtual());
  204       assert(isVirtual());
  208       assert(isVirtual());
  243       assert(HasLV && !IsUsed);
  247       assert(!HasLV && !IsUsed);
  251       assert(!HasLV);
  303       assert(!(StackBase && other.StackBase) && "can't merge stackbases");
tools/clang/lib/CodeGen/CGClass.cpp
   61   assert(vbaseClass->isCompleteDefinition());
  110   assert(CurFuncDecl && "loading 'this' without a func declaration?");
  111   assert(isa<CXXMethodDecl>(CurFuncDecl));
  159     assert(!Base->isVirtual() && "Should not see virtual bases here!");
  180   assert(PathBegin != PathEnd && "Base path should not be empty!");
  204   assert(This.getElementType() == ConvertType(Derived));
  233   assert(!nonVirtualOffset.isZero() || virtualOffset != nullptr);
  257     assert(nearestVBase && "virtual offset without vbase?");
  273   assert(PathBegin != PathEnd && "Base path should not be empty!");
  381   assert(PathBegin != PathEnd && "Base path should not be empty!");
  456     assert(!CGM.getCXXABI().NeedsVTTParameter(CurGD) &&
  458     assert(!ForVirtualBase && "Can't have same class as virtual base!");
  468     assert(SubVTTIndex != 0 && "Sub-VTT index must be greater than zero!");
  536   assert(BaseInit->isBaseInitializer() &&
  612   assert(MemberInit->isAnyMemberInitializer() &&
  614   assert(MemberInit->getInit() && "Must have initializer!");
  785     assert(NumFields < SSV.size());
  789   assert(NumFields == SSV.size());
  826   assert((CGM.getTarget().getCXXABI().hasConstructorVariants() ||
  840   assert(Definition == Ctor && "emitting wrong constructor body");
 1006       assert(F->getFieldIndex() >= LastAddedFieldIndex + 1 &&
 1049       assert(Field && "No field for member init.");
 1215       assert(Args.size() == 2);
 1287     assert(BaseCtorContinueBB);
 1309     assert(!(*B)->isBaseVirtual());
 1327     assert(!Member->isBaseInitializer());
 1328     assert(Member->isAnyMemberInitializer() &&
 1477     assert((Body || getTarget().getCXXABI().isMicrosoft()) &&
 1494     assert(Body);
 1514       assert(Dtor->isImplicit() && "bodyless dtor not implicit");
 1536   assert(isa<CompoundStmt>(RootS) &&
 1585     assert(Dtor->getOperatorDelete()->isDestroyingOperatorDelete() ==
 1602       assert(ShouldDeleteCondition != nullptr);
 1628       assert(LV.isSimple());
 1748       assert(Dtor->getParent()->isDynamicClass());
 1771   assert((!DD->isTrivial() || DD->hasAttr<DLLExportAttr>()) &&
 1777     assert(DD->getOperatorDelete() &&
 1835   assert(DtorType == Dtor_Base);
 2023   assert(!dtor->isTrivial());
 2056     assert(E->getNumArgs() == 1 && "unexpected argcount for trivial ctor");
 2119     assert(Args.size() == 1 && "trivial default ctor with args");
 2127     assert(Args.size() == 2 && "unexpected argcount for trivial ctor");
 2196     assert(CXXInheritedCtorInitExprArgs.size() >= D->getNumParams() &&
 2204     assert(OuterCtor->getNumParams() == D->getNumParams());
 2205     assert(!OuterCtor->isVariadic() && "should have been inlined");
 2208       assert(getContext().hasSameUnqualifiedType(
 2216         assert(POSParam && "missing pass_object_size value for forwarding");
 2247   assert(Args.size() >= Params.size() && "too few arguments for call");
 2251       assert(!RV.isComplex() && "complex indirect params not supported");
 2335   assert(I != E && "no parameters to constructor");
 2345     assert(I != E && "cannot skip vtt parameter, already done with args");
 2346     assert((*I)->getType()->isPointerType() &&
 2387   assert(Ctor->isDelegatingConstructor());
 2451   assert(D && D->isUsed() && "destructor not marked as used!");
 2898   assert(!Lambda->isGenericLambda() &&
 2921     assert(MD->isFunctionTemplateSpecialization());
 2927     assert(CorrespondingCallOpSpecialization);
tools/clang/lib/CodeGen/CGCleanup.cpp
   60   assert(rv.isAggregate());
  132   assert(StartOfBuffer + Size <= StartOfData);
  203   assert(!empty() && "popping exception stack when not empty");
  205   assert(isa<EHCleanupScope>(*begin()));
  228   assert(getInnermostEHScope() == stable_end());
  236   assert(!empty() && "popping exception stack when not empty");
  266   assert(hasNormalCleanups());
  270   assert(BranchFixups.size() >= MinSize && "fixup stack out of order");
  295   assert(!cleanup.hasActiveFlag() && "cleanup already has active flag?");
  363   assert(Term && "can't transition block without terminator");
  366     assert(Br->isUnconditional());
  379   assert(Block && "resolving a null target block");
  382   assert(EHStack.hasNormalCleanups() &&
  420   assert(Old.isValid());
  482     assert((I % alignof(LifetimeExtendedCleanupHeader) == 0) &&
  507   assert(Scope.isNormalCleanup());
  528   assert(Br->getSuccessor(0) == Entry);
  534   assert(!WasInsertBlock || CGF.Builder.GetInsertPoint() == Entry->end());
  573   assert(CGF.HaveInsertPoint() && "cleanup ended with no insertion point?");
  588     assert(Br->isUnconditional() && Br->getSuccessor(0) == From);
  631       assert(condition->getOperand(0) == CGF.NormalCleanupDest.getPointer());
  632       assert(condition->use_empty());
  637   assert(entry->use_empty());
  645   assert(!EHStack.empty() && "cleanup stack is empty!");
  646   assert(isa<EHCleanupScope>(*EHStack.begin()) && "top not a cleanup!");
  648   assert(Scope.getFixupDepth() <= EHStack.getNumBranchFixups());
  662   assert(Scope.hasEHBranches() == (EHEntry != nullptr));
  689   assert(!Scope.isNormalCleanup() || !HasPrebranchedFallthrough ||
  722     assert(normalEntry && !normalEntry->use_empty());
  732     assert(EHStack.getNumBranchFixups() == 0 ||
  797         assert(!IsActive && "source without fallthrough for active cleanup");
  821         assert(HasEnclosingCleanups);
  833         assert(!BranchThroughDest || !IsActive);
  889         assert(BranchThroughDest);
  895       assert(EHStack.hasNormalCleanups() == HasEnclosingCleanups);
  926         assert(!IsActive);
  933         assert(!FallthroughIsBranchThrough);
  962   assert(EHStack.hasNormalCleanups() || EHStack.getNumBranchFixups() == 0);
 1020   assert(Dest.getScopeDepth().encloses(EHStack.stable_begin())
 1045   assert(Dest.getScopeDepth().encloses(EHStack.stable_begin())
 1099       assert(Scope.isNormalCleanup());
 1130     assert(C.strictlyEncloses(I));
 1148     assert(cleanup.strictlyEncloses(i));
 1209     assert(dominatingIP && "no existing variable and no dominating IP!");
 1230   assert(C != EHStack.stable_end() && "activating bottom of stack?");
 1232   assert(!Scope.isActive() && "double activation");
 1242   assert(C != EHStack.stable_end() && "deactivating bottom of stack?");
 1244   assert(Scope.isActive() && "double deactivation");
tools/clang/lib/CodeGen/CGCleanup.h
  185     assert(CatchBits.NumHandlers == numHandlers && "NumHandlers overflow?");
  197     assert(I < getNumHandlers());
  203     assert(I < getNumHandlers());
  209     assert(I < getNumHandlers());
  302     assert(CleanupBits.CleanupSize == cleanupSize && "cleanup size overflow");
  328     assert(Var.getAlignment().isOne());
  385     assert(I < getNumBranchAfters());
  390     assert(I < getNumBranchAfters());
  453     assert(FilterBits.NumFilters == numFilters && "NumFilters overflow");
  463     assert(i < getNumFilters());
  468     assert(i < getNumFilters());
  575   assert(!empty() && "popping exception stack when not empty");
  583   assert(!empty() && "popping exception stack when not empty");
  591   assert(sp.isValid() && "finding invalid savepoint");
  592   assert(sp.Size <= stable_begin().Size && "finding savepoint after pop");
  598   assert(StartOfData <= ir.Ptr && ir.Ptr <= EndOfBuffer);
tools/clang/lib/CodeGen/CGCoroutine.cpp
  295   assert(isa<CallExpr>(RE) && "unexpected suspend expression type");
  302   assert(getCoroutineSuspendExprReturnType(getContext(), E)->isReferenceType() &&
  312   assert(getCoroutineSuspendExprReturnType(getContext(), E)->isReferenceType() &&
  327     assert(Expr == nullptr && "multilple declref in param move");
  354       assert(PM->isSingleDecl());
  359       assert(Visitor.Expr);
  364       assert(it != LocalDeclMap.end() && "parameter is not found");
  368       assert(copyIt != LocalDeclMap.end() && "parameter copy is not found");
  512         assert(!Cleanup->hasActiveFlag() && "cleanup already has active flag?");
tools/clang/lib/CodeGen/CGDebugInfo.cpp
   75   assert(LexicalBlockStack.empty() &&
  116   assert(!DI->LexicalBlockStack.empty());
  153   assert((DI.getInlinedAt() ==
  244   assert(FD && "Invalid FunctionDecl!");
  335       assert(RD->getDeclContext() == D->getDeclContext() &&
  337       assert(D->getDeclName().getAsIdentifierInfo() &&
  853     assert(Qc.empty() && "Unknown type qualifier for debug info");
  966     assert(RD->isClass());
 1112   assert(Ty->isTypeAlias());
 1260   assert(SizeInBits > 0 && "found named 0-width bitfield");
 1316       assert(!Field->isBitField() && "lambdas don't have bitfield members!");
 1440           assert(MI->second &&
 1480   assert(Args.size() && "Invalid number of arguments!");
 1798         assert(V && "Failed to find template parameter pointer");
 1839       assert(V && "Expression in template argument isn't constant");
 2029   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 2041   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 2042   assert(!D.isNull() && "null type");
 2044   assert(T && "could not create debug info for type");
 2073   assert(!Res->isForwardDecl());
 2148   assert(!Res->isForwardDecl());
 2310   assert(PD);
 2314   assert(Getter->getDeclName().isObjCZeroArgSelector());
 2322   assert(PD);
 2326   assert(Setter->getDeclName().isObjCOneArgSelector());
 2411     assert(StringRef(M->Name).startswith(CGM.getLangOpts().ModuleName) &&
 2897       assert(!DT.isNull() && "Undeduced types shouldn't reach here.");
 2908     assert(T != LastT && "Type unwrapping failed to unwrap!");
 3747   assert(CurInlinedAt && "unbalanced inline scope stack");
 3805   assert(!LexicalBlockStack.empty() && "Region stack mismatch, stack empty!");
 3817   assert(!LexicalBlockStack.empty() && "Region stack mismatch, stack empty!");
 3819   assert(RCount <= LexicalBlockStack.size() && "Region stack mismatch");
 3909   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 3910   assert(!LexicalBlockStack.empty() && "Region stack mismatch, stack empty!");
 4017     assert(std::find(Expr.begin(), Expr.end(), llvm::dwarf::DW_OP_deref) ==
 4048   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4053   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4054   assert(!LexicalBlockStack.empty() && "Region stack mismatch, stack empty!");
 4089   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4090   assert(!LexicalBlockStack.empty() && "Region stack mismatch, stack empty!");
 4160   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4217   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4345     assert(MI->second && "Static data member declaration should still exist");
 4383   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4413     assert(RD->isAnonymousStructOrUnion() &&
 4444   assert(DebugKind >= codegenoptions::LimitedDebugInfo);
 4455     assert(isa<EnumType>(ED->getTypeForDecl()) && "Enum without EnumType?");
 4470       assert (EDTy->getTag() == llvm::dwarf::DW_TAG_enumeration_type);
 4556   assert(UD.shadow_size() &&
 4636   assert(TheCU && "no main compile unit");
 4648     assert(FD->hasBody() && "Functions must have body here");
 4656       assert(I != ParamCache.end() && "Parameters should be already cached");
 4682       assert(It != TypeCache.end());
 4698     assert(P.second);
 4700     assert(Ty->isForwardDecl());
 4703     assert(It != TypeCache.end());
 4704     assert(It->second);
 4711     assert(P.second);
tools/clang/lib/CodeGen/CGDecl.cpp
  134     assert(VD.isLocalVarDecl() &&
  191   assert(D.hasLocalStorage());
  200   assert(!D.isExternallyVisible() && "name shouldn't matter");
  228   assert(Ty->isConstantSizeType() && "VLAs can't be static");
  297     assert(isa<ObjCMethodDecl>(DC) && "unexpected parent code decl");
  697         assert(srcExpr->getValueKind() == VK_XValue);
  900   assert(!Init->isNullValue() && !isa<llvm::UndefValue>(Init) &&
  924   assert((isa<llvm::ConstantStruct>(Init) || isa<llvm::ConstantArray>(Init)) &&
 1013       assert(!STy->isPacked());
 1180       assert(AP.getBitWidth() <= 8);
 1237   assert(!isa<llvm::UndefValue>(constant));
 1270   assert(Ty->isVectorTy());
 1291   assert(Addr->getType()->getPointerAddressSpace() ==
 1303   assert(Addr->getType()->getPointerAddressSpace() ==
 1367     assert(MD && "No Size expression debug node created");
 1377   assert(
 1434         assert(emission.wasEmittedAsGlobal());
 1518         assert(!emission.useLifetimeMarkers());
 1743   assert(emission.Variable && "emission was not valid!");
 1815     assert(!capturedByInit && "constant init contains a capturing block?");
 1914   assert(dtorKind != QualType::DK_none);
 1934       assert(!type->isArrayType());
 1960       assert(!type->isArrayType());
 1979   assert(emission.Variable && "emission was not valid!");
 2005     assert(F && "Could not find function!");
 2045   assert(dtorKind && "cannot push destructor for trivial type");
 2046   assert(needsEHCleanup(dtorKind));
 2055   assert(dtorKind && "cannot push destructor for trivial type");
 2147   assert(!elementType->isArrayType());
 2348   assert((isa<ParmVarDecl>(D) || isa<ImplicitParamDecl>(D)) &&
 2387       assert(getContext().getTargetAddressSpace(SrcLangAS) ==
 2403         assert((DtorKind == QualType::DK_cxx_destructor ||
 2441         assert(lt == Qualifiers::OCL_Strong &&
 2443         assert(qs.hasConst() && "pseudo-strong variable should be const!");
tools/clang/lib/CodeGen/CGDeclCXX.cpp
   29   assert(
   33   assert(!D.getType()->isReferenceType() &&
   91     assert(!D.getTLSKind() && "should have rejected this");
  115     assert(!Record->hasTrivialDestructor());
  220   assert(PerformInit && "cannot have constant initializer which needs "
  302   assert((Kind == GuardKind::TlsGuard || D) && "no guarded variable");
  515       assert(I->second < CXXGlobalInits.size() &&
tools/clang/lib/CodeGen/CGException.cpp
  331   assert(std::strcmp(ObjCXX.PersonalityFn, CXX.PersonalityFn) != 0 &&
  702   assert(EHStack.requiresLandingPad());
  703   assert(!EHStack.empty());
  739   assert(LP);
  752   assert(EHStack.requiresLandingPad());
  806       assert(I.next() == EHStack.end() && "EH filter is not end of EH stack");
  807       assert(!hasCatchAll && "EH filter reached after catch-all");
  821       assert(!hasCatchAll);
  835       assert(handler.Type.Flags == 0 &&
  840         assert(!hasCatchAll);
  854   assert(!(hasCatchAll && hasFilter));
  884   assert((LPadInst->getNumClauses() > 0 || LPadInst->isCleanup()) &&
  898   assert(DispatchBlock);
  942   assert(DispatchBlock);
  997     assert(I < E && "ran off end of handlers!");
 1055   assert(dispatchBlock);
 1061     assert(dispatchBlock == catchScope.getHandler(0).Block);
 1077     assert(i < e && "ran off end of handlers!");
 1081     assert(handler.Type.Flags == 0 &&
 1083     assert(typeValue && "fell into catch-all case!");
 1137   assert(CatchScope.getNumHandlers() == NumHandlers);
 1246     assert(WasmCatchStartBlock);
 1254       assert(BI->isConditional());
 1257     assert(RethrowBlock != WasmCatchStartBlock && RethrowBlock->empty());
 1367   assert((!!beginCatchFn) == (!!endCatchFn) &&
 1369   assert(rethrowFn && "rethrow function is required");
 1516   assert(EHPersonality::get(*this).usesFuncletPads() &&
 1737     assert(ParentRecover->getIntrinsicID() == llvm::Intrinsic::localrecover &&
 1807     assert((isa<ImplicitParamDecl>(VD) || VD->isLocalVarDeclOrParm()) &&
 1843     assert(ParentSEHFn && "No CurSEHParent!");
 1960   assert(!SEHCodeSlotStack.empty() && "emitting EH code outside of __except");
 1969   assert(SEHInfo->getType() == Int8PtrTy);
 1974   assert(!SEHCodeSlotStack.empty() && "emitting EH code outside of __except");
 2004   assert(Except);
 2039   assert(Except && "__try must have __finally xor __except");
tools/clang/lib/CodeGen/CGExpr.cpp
  127   assert(isa<llvm::AllocaInst>(Var.getPointer()));
  422   assert((!M->getExtendingDecl() || !isa<VarDecl>(M->getExtendingDecl()) ||
  481       assert(Adjustments.empty());
  574       assert(LV.isSimple() &&
  596   assert(LV.isSimple());
  763     assert(!AlignVal || (uint64_t)1 << llvm::Log2_64(AlignVal) == AlignVal);
  916   assert(LocalDeclMap.count(PassedSizeDecl) && "Passed size not loadable");
  962   assert(SanOpts.has(SanitizerKind::ArrayBounds) &&
 1040   assert(E->getType()->isPointerType() ||
 1384   assert(type.isCanonical());
 1385   assert(!type->isReferenceType());
 1484     assert(isa<EnumConstantDecl>(value));
 1516   assert(Constant && "not a constant");
 1565       assert(NumBits <= Bitwidth);
 1569       assert(NumPositiveBits <= Bitwidth);
 1698     assert(Value->getType()->isIntegerTy(getContext().getTypeSize(Ty)) &&
 1708     assert(Value->getType()->isIntegerTy(getContext().getTypeSize(Ty)) &&
 1794     assert(!LV.getType()->isFunctionType());
 1816   assert(LV.isBitField() && "Unknown LValue type!");
 1831     assert(static_cast<unsigned>(Info.Offset + Info.Size) <= Info.StorageSize);
 1903   assert((LV.getType()->isIntegerType() || LV.getType()->isPointerType()) &&
 1949     assert(Dst.isBitField() && "Unknown LValue type");
 2000       assert(Dst.getBaseIvarExp() && "BaseIvarExp is NULL");
 2020   assert(Src.isScalar() && "Can't emit an agg store with this method");
 2041     assert(Info.StorageSize > Info.Size && "Invalid bitfield size.");
 2065     assert(Info.Offset == 0);
 2077       assert(Info.Size <= Info.StorageSize);
 2163   assert((Dst.getType()->isIntegerType() || Dst.getType()->isPointerType()) &&
 2167   assert(RegName && "Register LValue is not metadata");
 2310   assert(((*Res == OMPDeclareTargetDeclAttr::MT_Link) ||
 2444   assert(Asm->getLabel().size() < 64-Name.size() &&
 2518   assert(E->isNonOdrUse() != NOUR_Unevaluated &&
 2537       assert(Val && "failed to emit constant expression");
 2585       assert(isa<BlockDecl>(CurCodeDecl));
 2594   assert((ND->isUsed(false) || !isa<VarDecl>(ND) || E->isNonOdrUse() ||
 2688     assert(!T.isNull() && "CodeGenFunction::EmitUnaryOpLValue: Illegal type");
 2710     assert(LV.isSimple() && "real/imag on non-ordinary l-value");
 2716       assert(E->getSubExpr()->getType()->isArithmeticType());
 2757   assert(SL != nullptr && "No StringLiteral name in PredefinedExpr");
 2883       assert(PathComponentsToStrip != INT_MIN);
 2935   assert(Kind.countPopulation() == 1);
 2963   assert(IsFatal || RecoverKind != CheckRecoverableKind::Unrecoverable);
 3009   assert(IsSanitizerScope);
 3010   assert(Checked.size() > 0);
 3011   assert(CheckHandler >= 0 &&
 3040   assert(JointCond);
 3043   assert(SanOpts.has(Checked[0].second));
 3046     assert(RecoverKind == getRecoverableKind(Checked[i].second) &&
 3048     assert(SanOpts.has(Checked[i].second));
 3317   assert(E->getType()->isArrayType() &&
 3332     assert(isa<llvm::ArrayType>(Addr.getElementType()) &&
 3414     assert(isa<llvm::ConstantInt>(idx) &&
 3459       assert(E->getRHS() == E->getIdx() && "index was neither LHS nor RHS");
 3485     assert(LHS.isSimple() && "Can only subscript lvalue vectors here!");
 3568     assert(Array->getType()->isArrayType() &&
 3627         assert(isa<llvm::ArrayType>(Addr.getElementType()) &&
 3739   assert(Idx);
 3770     assert(Array->getType()->isArrayType() &&
 3817     assert(E->getBase()->getType()->isVectorType());
 3821     assert(E->getBase()->getType()->isVectorType() &&
 3845   assert(Base.isExtVectorElt() && "Can only subscript lvalue vec elts here!");
 3899   assert(cast<CXXMethodDecl>(CurCodeDecl)->getParent()->isLambda());
 3900   assert(cast<CXXMethodDecl>(CurCodeDecl)->getParent() == Field->getParent());
 4042         assert(!FieldTBAAInfo.Offset &&
 4187   assert(E->isTransparent() && "non-transparent glvalue init list");
 4208     assert(hasAggregateEvaluationKind(expr->getType()) &&
 4277     assert((lhs || rhs) &&
 4452   assert(OpaqueValueMappingData::shouldBindAsLValue(e));
 4458   assert(OpaqueValueMapping::shouldBindAsLValue(e));
 4466   assert(e->isUnique() && "LValue for a nonunique OVE hasn't been emitted");
 4472   assert(!OpaqueValueMapping::shouldBindAsLValue(e));
 4480   assert(e->isUnique() && "RValue for a nonunique OVE hasn't been emitted");
 4595   assert(functionType->isFunctionType());
 4619   assert(E->getOpcode() == BO_Assign && "unexpected binary l-value");
 4664   assert(E->getCallReturnType(getContext())->isReferenceType() &&
 4677   assert(E->getType()->getAsCXXRecordDecl()->hasTrivialDestructor()
 4715   assert(E->getMethodDecl()->getReturnType()->isReferenceType() &&
 4777   assert(CalleeType->isFunctionPointerType() &&
 4998   assert(Val->getType()->isFPOrFPVectorTy());
 5034         assert(ov != resultExpr &&
tools/clang/lib/CodeGen/CGExprAgg.cpp
  278       assert(LifetimeStartInst->getIntrinsicID() ==
  297   assert(Dest.getPointer() != Src.getAggregatePointer());
  311   assert(src.isAggregate() && "value must be aggregate value!");
  388   assert(Array.isSimple() && "initializer_list array not a simple lvalue");
  393   assert(ArrayType && "std::initializer_list constructed from non-array");
  474   assert(NumInitElements <= NumArrayElements);
  686     assert(isa<CXXDynamicCastExpr>(E) && "CK_Dynamic without a dynamic_cast?");
  752     assert(atomicType->isAtomicType());
  753     assert(CGF.getContext().hasSameUnqualifiedType(valueType,
  767       assert(CGF.getContext().hasSameUnqualifiedType(op->getType(),
  826     assert(CGF.getContext().hasSameUnqualifiedType(E->getSubExpr()->getType(),
  930     assert(Kind == CK_Equal &&
  975   assert(CGF.getContext().hasSameType(E->getLHS()->getType(),
  979   assert(CmpInfo.Record->isTriviallyCopyable() &&
 1002     assert(RV.isComplex());
 1013     assert(K == CompareKind::CK_Equal);
 1141   assert(CGF.getContext().hasSameUnqualifiedType(E->getLHS()->getType(),
 1225   assert(CGF.HaveInsertPoint() && "expression evaluation ended with no IP!");
 1315       assert(LV.isSimple());
 1445       assert(lv.isSimple());
 1488   assert(E->getType()->isRecordType() && "Only support structs/unions here!");
 1513     assert(E->getNumInits() >= CXXRD->getNumBases() &&
 1516       assert(!Base.isVirtual() && "should not see vbases here");
 1550         assert(Field->isUnnamedBitfield() && "Only unnamed bitfields allowed");
 1607       assert(LV.isSimple());
 1627   assert((cleanupDominator || cleanups.empty()) &&
 1852   assert(E && hasAggregateEvaluationKind(E->getType()) &&
 1854   assert((Slot.getAddress().isValid() || Slot.isIgnored()) &&
 1864   assert(hasAggregateEvaluationKind(E->getType()) && "Invalid argument!");
 1917   assert(!Ty->isAnyComplexType() && "Shouldn't happen for complex");
 1925       assert((Record->hasTrivialCopyConstructor() ||
 1966       assert(!TypeInfo.first.isZero());
tools/clang/lib/CodeGen/CGExprCXX.cpp
   40   assert(CE == nullptr || isa<CXXMemberCallExpr>(CE) ||
   42   assert(MD->isInstance() &&
   71     assert(
   98   assert(!ThisTy.isNull());
   99   assert(ThisTy->getAsCXXRecordDecl() == DtorDecl->getParent() &&
  210   assert(isa<CXXMemberCallExpr>(CE) || isa<CXXOperatorCallExpr>(CE));
  220     assert(DevirtualizedMethod);
  270     assert(!RtlArgs);
  271     assert(ReturnValue.isNull() && "Constructor shouldn't have return value");
  344     assert(CE->arg_begin() == CE->arg_end() &&
  346     assert(ReturnValue.isNull() && "Destructor shouldn't have return value");
  466   assert(MD->isInstance() &&
  509     assert(!SplitBeforeSize.isNegative() && "negative store size!");
  515     assert(!SplitAfterSize.isNegative() && "negative store size!");
  568   assert(!Dest.isIgnored() && "Must have a destination!");
  597     assert(getContext().hasSameUnqualifiedType(E->getType(),
  642   assert(isa<CXXConstructExpr>(Exp) &&
  655   assert(!getContext().getAsConstantArrayType(E->getType())
  701   assert(isa<llvm::IntegerType>(numElements->getType()));
  835     assert(numElements->getType() == CGF.SizeTy);
  883           assert(arraySizeMultiplier == typeSizeMultiplier);
  895       assert(arraySizeMultiplier == 1);
  930     assert(sizeWithoutCookie && "didn't set sizeWithoutCookie?");
 1046         assert(OK && "couldn't memset character type?");
 1110       assert(SubILE->getNumInits() == 0 && "explicit inits in array filler?");
 1128   assert(Init && "have trailing elements to initialize but no initializer");
 1176   assert(getContext().hasSameUnqualifiedType(ElementType, Init->getType()) &&
 1350     assert(AI != AE);
 1365   assert(AI == AE && "unexpected usual deallocation function parameter");
 1410       assert(I < NumPlacementArgs && "index out of range");
 1435       assert(!Params.DestroyingDelete &&
 1565     assert(E->getNumPlacementArgs() == 1);
 1605         assert(getContext().hasSameUnqualifiedType(
 1612         assert(allocator->isVariadic() && "can't pass alignment to allocator");
 1682   assert((allocSize == allocSizeWithoutCookie) ==
 1685     assert(E->isArray());
 1755   assert((!NumElements && CookieSize.isZero()) ||
 1808   assert(ParamTypeIt == DeleteFTy->param_type_end() &&
 1871   assert(!OperatorDelete->isDestroyingOperatorDelete());
 1980   assert(allocatedPtr && "ReadArrayCookie didn't set allocated pointer");
 1991     assert(numElements && "no element count for a type with a destructor!");
 2060   assert(ConvertTypeForMem(DeleteTy) == Ptr.getElementType());
 2219   assert(SrcRecordTy->isRecordType() && "source type must be a record type!");
 2246     assert(DestRecordTy->isRecordType() &&
tools/clang/lib/CodeGen/CGExprComplex.cpp
  127     assert(Constant && "not a constant");
  233     assert(E->getType()->isAnyComplexType() && "Expected complex type!");
  239     assert(E->getType()->isAnyComplexType() && "Expected complex type!");
  347   assert(lvalue.isSimple() && "non-simple complex l-value?");
  416   assert(RetAlloca.isValid() && "Expected complex return value");
  585     assert(ResI && "Only one operand may be real!");
  588     assert(Op.LHS.second && Op.RHS.second &&
  604     assert(ResI && "Only one operand may be real!");
  607     assert(Op.LHS.second && Op.RHS.second &&
  751     assert((Op.LHS.second || Op.RHS.second) &&
  763     assert(Op.LHS.second && Op.RHS.second &&
  833       assert(LHSi && "Can have at most one non-complex operand!");
  839     assert(Op.LHS.second && Op.RHS.second &&
  905     assert(
  910     assert(CGF.getContext()
  974   assert(CGF.getContext().hasSameUnqualifiedType(E->getLHS()->getType(),
 1063     assert (Ignore == false && "init list ignored");
 1066     assert (Ignore == false && "init list ignored");
 1077   assert(E->getNumInits() == 0 && "Unexpected number of inits");
 1108   assert(E && getComplexType(E->getType()) &&
 1117   assert(E && getComplexType(E->getType()) &&
 1137   assert(E->getOpcode() == BO_Assign);
tools/clang/lib/CodeGen/CGExprConstant.cpp
  137   assert(BeginOff <= EndOff && "invalid replacement range");
  169   assert((FirstElemToReplace == LastElemToReplace || AllowOverwrite) &&
  231       assert(*LastElemToUpdate - *FirstElemToUpdate < 2 &&
  258         assert(CI->getBitWidth() == CharWidth && "splitAt failed");
  259         assert((!(CI->getValue() & UpdateMask) || AllowOverwrite) &&
  362     assert(Hint > Offset && Hint < Offset + ElemSize && "nothing to split");
  402     assert(!AllowOversized && "oversized array emission not supported");
  463       assert(DesiredOffset >= SizeSoFar && "elements out of order");
  475       assert((SizeSoFar <= DesiredSize || AllowOversized) &&
  783       assert(!Base->isVirtual() && "should not have virtual bases here");
  898     assert(!E->isFileScope() &&
  935     assert(Elements.size() >= NonzeroLength &&
 1036       assert(E->getType()->isUnionType() &&
 1056       assert(CurSize <= TotalSize && "Union size mismatch!");
 1181     assert(CAT && "can't emit array init for non-constant-bound array");
 1285       assert(E->getNumArgs() == 1 && "trivial ctor with > 1 argument");
 1286       assert(E->getConstructor()->isCopyOrMoveConstructor() &&
 1290       assert(CGM.getContext().hasSameUnqualifiedType(Ty, Arg->getType()) &&
 1334   assert(saved.OldPlaceholdersSize == PlaceholderAddresses.size() &&
 1407   assert(C && "couldn't emit constant value non-abstractly?");
 1412   assert(!Abstract && "cannot get current address for abstract constant");
 1433   assert(!PlaceholderAddresses.empty());
 1434   assert(PlaceholderAddresses.back().first == nullptr);
 1435   assert(PlaceholderAddresses.back().second == placeholder);
 1478       assert(IndexValues.size() == Indices.size() && "mismatch");
 1479       assert(Indices.size() == 1 && "didn't pop all indices");
 1482       assert(Locations.size() == PlaceholderAddresses.size() &&
 1490         assert(entry.first->getParent() == nullptr && "not a placeholder!");
 1530       assert(Locations.find(placeholder) == Locations.end() &&
 1536       assert(Indices.size() == IndexValues.size());
 1541             assert(IndexValues[j] &&
 1567   assert(InitializedNonAbstract &&
 1569   assert(!Finalized && "finalizing emitter multiple times");
 1570   assert(global->getInitializer());
 1583   assert((!InitializedNonAbstract || Finalized || Failed) &&
 1585   assert(PlaceholderAddresses.empty() && "unhandled placeholders");
 1630   assert(E && "No initializer to emit");
 1680     assert(innerSize < outerSize && "emitted over-large constant for atomic");
 1813   assert(isa<llvm::IntegerType>(destTy) || isa<llvm::PointerType>(destTy));
 1938   assert(E->isExpressibleAsConstantInitializer() &&
 1951   assert(Emitter.CGF && "Invalid address of label expression outside function");
 2003   assert(E->getStorageDuration() == SD_Static);
 2162   assert(Ok && "CLE has already been emitted!");
 2167   assert(E->isFileScope() && "not a file-scope compound literal expr");
 2318   assert(T->isMemberDataPointerType() &&
tools/clang/lib/CodeGen/CGExprScalar.cpp
  174   assert((isa<UnaryOperator>(Op.E) || isa<BinaryOperator>(Op.E)) &&
  562     assert(CGF.getArrayInitIndex() &&
  853   assert(SrcType.isCanonical() && "EmitScalarConversion strips typedefs");
  861   assert((SrcType->isIntegerType() || isa<llvm::PointerType>(Src->getType())) &&
  867   assert(isa<llvm::PointerType>(Src->getType()));
  874   assert(SrcType->isFloatingType() && "not a conversion from floating point");
  950   assert(Src != Dst);
  951   assert(SrcTy->getScalarSizeInBits() > Dst->getType()->getScalarSizeInBits());
  952   assert(isa<llvm::IntegerType>(SrcTy) && isa<llvm::IntegerType>(DstTy) &&
  996   assert(!DstType->isBooleanType() && "we should not get here with booleans.");
 1036   assert(isa<llvm::IntegerType>(SrcTy) && isa<llvm::IntegerType>(DstTy) &&
 1048   assert(((SrcBits != DstBits) || (SrcSigned != DstSigned)) &&
 1264     assert(SrcType->isIntegerType() && "Not ptr->ptr or int->ptr conversion?");
 1277     assert(isa<llvm::IntegerType>(DstTy) && "not ptr->int?");
 1285     assert(DstType->castAs<ExtVectorType>()->getElementType().getTypePtr() ==
 1312     assert(((SrcElementTy->isIntegerTy() &&
 1372     assert(SrcTy->isFloatingPointTy() && "Unknown real conversion");
 1378     assert(SrcTy->isFloatingPointTy() && DstTy->isFloatingPointTy() &&
 1388       assert(ResTy->isIntegerTy(16) && "Only half FP requires extra conversion");
 1534   assert(CGF.IsSanitizerScope);
 1655   assert(SrcType->isVectorType() &&
 1657   assert(DstType->isVectorType() &&
 1670   assert(SrcTy->isVectorTy() &&
 1672   assert(DstTy->isVectorTy() &&
 1679     assert((SrcEltTy->isFloatingPointTy() ||
 1702     assert(SrcEltTy->isFloatingPointTy() && "Unknown real conversion");
 1708     assert(SrcEltTy->isFloatingPointTy() && DstEltTy->isFloatingPointTy() &&
 1767       assert(llvm::ConstantInt::isValueValidForType(I32Ty,
 1778   assert (Ignore == false && "init list ignored");
 2063     assert(DerivedClassDecl && "BaseToDerived arg isn't a C++ object pointer!");
 2155     assert(CGF.getContext().hasSameUnqualifiedType(E->getType(), DestTy));
 2156     assert(E->isGLValue() && "lvalue-to-rvalue applied to r-value!");
 2181     assert(!DestTy->isBooleanType() && "bool should use PointerToBool");
 2212     assert(E->getType()->isFixedPointType() &&
 2214     assert(DestTy->isBooleanType() && "Expected dest type to be boolean type");
 2219     assert(E->getType()->isFixedPointType() &&
 2221     assert(DestTy->isIntegerType() && "Expected dest type to be an integer");
 2226     assert(E->getType()->isIntegerType() &&
 2228     assert(DestTy->isFixedPointType() &&
 2279     assert((DestTy->isEventT() || DestTy->isQueueT() ||
 2686       assert(i < RL.getFieldCount() && "offsetof field in wrong type");
 3281   assert(!(negMul && negAdd) && "Only one of negMul and negAdd should be set.");
 3315   assert((op.Opcode == BO_Add || op.Opcode == BO_AddAssign ||
 3651     assert(!Checks.empty());
 3734     assert(E->getOpcode() == BO_EQ ||
 3868       assert(CGF.getContext().hasSameUnqualifiedType(CETy,
 3875       assert(CGF.getContext().hasSameUnqualifiedType(CETy, RHSTy) &&
 3893       assert(E->getOpcode() == BO_NE &&
 4244       assert(!RHS && "LHS and RHS types must match");
 4441   assert(E && hasScalarEvaluationKind(E->getType()) &&
 4453   assert(hasScalarEvaluationKind(SrcTy) && hasScalarEvaluationKind(DstTy) &&
 4464   assert(SrcTy->isAnyComplexType() && hasScalarEvaluationKind(DstTy) &&
 4578   assert(GEP->getPointerOperand() == BasePtr &&
 4580   assert(GEP->isInBounds() && "Expected inbounds GEP");
 4597     assert((Opcode == BO_Add || Opcode == BO_Mul) && "Can't eval binop");
 4682   assert((!isa<llvm::Constant>(EvaluatedGEP.TotalOffset) ||
 4758   assert(!Checks.empty() && "Should have produced some checks.");
tools/clang/lib/CodeGen/CGGPUBuiltin.cpp
   33     assert(F->getFunctionType() == VprintfFuncType);
   71   assert(getTarget().getTriple().isNVPTX());
   72   assert(E->getBuiltinCallee() == Builtin::BIprintf);
   73   assert(E->getNumArgs() >= 1); // printf always has at least one arg.
tools/clang/lib/CodeGen/CGLoopInfo.cpp
  418   assert(!!AccGroup == Attrs.IsParallel &&
  759   assert(!Active.empty() && "No active loops to pop");
tools/clang/lib/CodeGen/CGNonTrivialStruct.cpp
  109     assert(!FT.isVolatileQualified() && "volatile field not expected");
  412     assert(Addr.isValid() && "invalid address");
tools/clang/lib/CodeGen/CGObjC.cpp
   70   assert(BoxingMethod->isClassMethod() && "BoxingMethod must be a class method");
  344   assert(E->getType()->isObjCRetainableType());
  478     assert(ID && "null interface should be impossible here");
  544     assert(ObjTy && "Invalid Objective-C class message send");
  546     assert(OID && "Invalid Objective-C class message send");
  590     assert(getLangOpts().ObjCAutoRefCount &&
  718   assert(isa<CompoundStmt>(OMD->getBody()));
  959   assert(OMD && "Invalid call to generate getter (empty method)");
  986   assert(isa<ExprWithCleanups>(getter));
 1300   assert(isa<ExprWithCleanups>(setter));
 1495   assert(OMD && "Invalid call to generate setter (empty method)");
 1567   assert(scope.requiresCleanups() && "nothing to do in .cxx_destruct?");
 2038   assert(addr.getElementType() == value->getType());
 2063   assert(dst.getType() == src.getType());
 2148     assert(call->getCalledValue() == CGM.getObjCEntrypoints().objc_retainBlock);
 2279   assert(addr.getElementType() == value->getType());
 2497   assert(value->getType() == Int8PtrTy);
 2710     assert(type.getObjCLifetime() == Qualifiers::OCL_Weak);
 2852   assert(e->getType()->isBlockPointerType());
 2929   assert(resultExpr);
 2945         assert(!OVMA::shouldBindAsLValue(ov));
 2994     assert(e->getSubExpr()->getType()->hasPointerRepresentation());
 3096   assert(!isa<ExprWithCleanups>(e));
 3498   assert(PID->getSetterCXXAssignment() && "SetterCXXAssignment - null");
 3582   assert(PID->getGetterCXXConstructor() && "getGetterCXXConstructor - null");
 3699   assert(Args.size() == 3 && "Expected 3 argument here!");
tools/clang/lib/CodeGen/CGObjCGNU.cpp
  235     assert(!isRuntime(ObjCRuntime::GNUstep, 2));
  864       assert (CGM.getLangOpts().ObjCRuntime.getVersion() >=
  872       assert (CGM.getLangOpts().ObjCRuntime.getVersion() >=
  882       assert ((CGM.getLangOpts().getGC() == LangOptions::NonGC));
  885       assert (CGM.getLangOpts().ObjCRuntime.getVersion() >=
 1248     assert(ClassSymbol->getName() == SymbolName);
 1277         assert(Ownership != Qualifiers::OCL_Autoreleasing);
 1314       assert(!TheModule.getGlobalVariable(RefName));
 1363       assert(!OldGV);
 1558     assert(InitVar->getName() == ".objc_ctor");
 1860         assert(align < 64);
 1970     assert(classStruct->getName() == SymbolForClass(className));
 2374   assert(OPT && "Invalid @catch type.");
 2376   assert(IDecl && "Invalid @catch type.");
 2406   assert(PT && "Invalid @catch type.");
 2408   assert(IT && "Invalid @catch type.");
 2813     assert(FnPtr && "Can't generate metadata for method that doesn't exist");
 3941     assert((!CGF.ObjCEHValueStack.empty() && CGF.ObjCEHValueStack.back()) &&
 3990   assert(!threadlocal && "EmitObjCGlobalAssign - Threal Local API NYI");
tools/clang/lib/CodeGen/CGObjCMac.cpp
 1758           assert(RV.isScalar() &&
 1766     assert(CGF.Builder.GetInsertBlock() == NullBB);
 1796       assert(result.isAggregate() && "null init of non-aggregate result?");
 2159     assert(CGM.getContext().getCanonicalType(Method->getReturnType()) ==
 2418     assert(!type->isArrayType() && "array variable should not be caught");
 2427       assert(CGM.getContext().getTypeSize(type)
 2522       assert(CArray && "only array with known element size is supported");
 2580       assert(!LastFieldBitfieldOrUnnamed->getIdentifier() &&"Expected unnamed");
 2903   assert(CGM.getLangOpts().getGC() == LangOptions::NonGC);
 2937     assert(!type->isArrayType() && "array variable should not be caught");
 2969   assert(CGM.getLangOpts().getGC() == LangOptions::NonGC);
 2970   assert(!T->isArrayType() && "__block array variable should not be caught");
 3076     assert(Entry->hasPrivateLinkage());
 3488   assert(CGM.getLangOpts().getGC() == LangOptions::NonGC);
 3606     assert(GV->getType()->getElementType() == ObjCTypes.ClassTy &&
 3669     assert(GV->getType()->getElementType() == ObjCTypes.ClassTy &&
 3700   assert(GV->getType()->getElementType() == ObjCTypes.ClassTy &&
 3714   assert(GV->getType()->getElementType() == ObjCTypes.ClassTy &&
 3860   assert(fn && "no definition registered for method");
 4256   assert(!Locals.empty());
 4630           assert(CGF.HaveInsertPoint() && "DeclStmt destroyed insert point?");
 4645       assert(OPT && "Unexpected non-object pointer type in @catch");
 4650       assert(IDecl && "Catch parameter must have Objective-C type!");
 4674       assert(CGF.HaveInsertPoint() && "DeclStmt destroyed insert point?");
 4713       assert(PropagatingExnVar.isValid());
 4770     assert((!CGF.ObjCEHValueStack.empty() && CGF.ObjCEHValueStack.back()) &&
 4807     assert(Size <= 8 && "does not support size > 8");
 4828     assert(Size <= 8 && "does not support size > 8");
 4850   assert(ivarOffset && "EmitObjCIvarAssign - ivarOffset is NULL");
 4854     assert(Size <= 8 && "does not support size > 8");
 4873     assert(Size <= 8 && "does not support size > 8");
 4930     assert(Section.substr(0, 2) == "__" &&
 4934     assert(Section.substr(0, 2) == "__" &&
 5065     assert(ID);
 5219   assert(!fieldType->isArrayType() && "ivar of non-constant array type?");
 5255     assert(CGM.getContext().getTypeSizeInChars(fieldType)
 5272   assert(!IvarsInfo.empty() && "generating bitmap for no data");
 5280     assert(std::is_sorted(IvarsInfo.begin(), IvarsInfo.end()));
 5282   assert(IvarsInfo.back().Offset < InstanceEnd);
 5284   assert(buffer.empty());
 5288     assert(numWords > 0);
 5313     assert(numWords > 0);
 5354       assert(request.Offset + request.SizeInWords * WordSize <= InstanceBegin);
 5375     assert(beginOfScanInWords < endOfScanInWords);
 5547   assert (CD && "Missing container decl in GetNameForMethod");
 6069   assert((!CGM.getTriple().isOSBinFormatMachO() ||
 6091     assert(ID);
 6257   assert(OID && "CGObjCNonFragileABIMac::BuildClassRoTInitializer");
 6402   assert(CI && "CGObjCNonFragileABIMac::GenerateClass - class is 0");
 6641     assert(fn && "no definition for method?");
 6814   assert(OID && "CGObjCNonFragileABIMac::EmitIvarList - null interface");
 6913   assert(PD->hasDefinition() &&
 7170   assert(fn && "CGObjCNonFragileABIMac::EmitMessageSend");
 7282   assert(GV->getLinkage() == L);
 7330       assert(ClassGV->getType() == ObjCTypes.ClassnfABIPtrTy &&
 7418     assert(!isa<llvm::GlobalVariable>(ClassGV) ||
 7519     assert(Size <= 8 && "does not support size > 8");
 7539     assert(Size <= 8 && "does not support size > 8");
 7585     assert(Size <= 8 && "does not support size > 8");
 7606     assert(Size <= 8 && "does not support size > 8");
 7647   assert(PT && "Invalid @catch type.");
 7650   assert(IT && "Invalid @catch type.");
 7708   assert((!Entry || !Entry->hasInitializer()) && "Duplicate EHType definition");
 7744   assert(Entry->getLinkage() == L);
tools/clang/lib/CodeGen/CGOpenCLRuntime.cpp
   34   assert(T->isOpenCLSpecificType() &&
  119   assert(CGM.getLangOpts().OpenCL);
  147   assert(EnqueuedBlockMap.find(E) == EnqueuedBlockMap.end() &&
  149   assert(isa<llvm::Function>(InvokeF) && "Invalid invoke function");
  150   assert(Block->getType()->isPointerTy() && "Invalid block literal type");
  168   assert(EnqueuedBlockMap.find(Block) != EnqueuedBlockMap.end() &&
tools/clang/lib/CodeGen/CGOpenMPRuntime.cpp
  107     assert(ThreadIDVar != nullptr && "No ThreadID in OpenMP region.");
  188     assert(ThreadIDVar != nullptr && "No ThreadID in OpenMP region.");
  988   assert(SharedAddresses.size() == N &&
 1039     assert(!Size && !Sizes[N].second &&
 1055   assert(SharedAddresses.size() > N && "No variable was generated");
 1291       assert(OrigAddr->isDeclaration() && "Expected declaration");
 1443   assert(ThreadIDVar->getType()->isPointerType() &&
 1504   assert(!ThreadIDVar->getType()->isPointerType() &&
 1603   assert(!Elem.second.ServiceInsertPt && "Insert point is set already.");
 1634   assert(CGF.CurFn && "No function in current CodeGenFunction.");
 1688   assert(CGF.CurFn && "No function in current CodeGenFunction.");
 1743   assert(CGF.CurFn && "No function in current CodeGenFunction.");
 1986     assert(KmpRoutineEntryPtrTy != nullptr &&
 2000     assert(KmpRoutineEntryPtrTy != nullptr &&
 2551   assert(RTLFn && "Unable to find OpenMP runtime function");
 2557   assert((IVSize == 32 || IVSize == 64) &&
 2583   assert((IVSize == 32 || IVSize == 64) &&
 2605   assert((IVSize == 32 || IVSize == 64) &&
 2622   assert((IVSize == 32 || IVSize == 64) &&
 2654   assert(Loc.isValid() && "Source location is expected to be always valid.");
 2657   assert(PLoc.isValid() && "Source location is expected to be always valid.");
 2710   assert(!CGM.getLangOpts().OpenMPUseTLS ||
 3141     assert(Elem.second->getType()->getPointerElementType() == Ty &&
 3350   assert(CopyprivateVars.size() == SrcExprs.size() &&
 3530     assert(!Chunked && "chunk was specified but schedule kind not known");
 3572   assert(Schedule != OMP_sch_static_chunked && "cannot be chunked here");
 3633   assert(Ordered ||
 3666   assert(!Values.Ordered);
 3667   assert(Schedule == OMP_sch_static || Schedule == OMP_sch_static_chunked ||
 3680     assert((Schedule == OMP_sch_static || Schedule == OMP_ord_static ||
 3686     assert((Schedule == OMP_sch_static_chunked ||
 3714   assert(isOpenMPWorksharingDirective(DKind) &&
 3889   assert(CGM.getLangOpts().OpenMPIsDevice && "Initialization of entries is "
 3915     assert(Entry.isValid() && "Entry not initialized!");
 3961   assert(CGM.getLangOpts().OpenMPIsDevice && "Initialization of entries is "
 3975     assert(Entry.isValid() && Entry.getFlags() == Flags &&
 3977     assert((!Entry.getAddress() || Entry.getAddress() == Addr) &&
 3992       assert(Entry.isValid() && Entry.getFlags() == Flags &&
 3994       assert((!Entry.getAddress() || Entry.getAddress() == Addr) &&
 4153     assert(std::get<0>(E) && "All ordered entries must exist!");
 4196         assert(((CGM.getLangOpts().OpenMPIsDevice && !CE->getAddress()) ||
 4791           assert(isa<ImplicitParamDecl>(OriginalVD) &&
 4925   assert(!Privates.empty());
 5013     assert((D.getDirectiveKind() == OMPD_task ||
 6378     assert(CancelRegion == OMPD_taskgroup);
 6465   assert(!ParentName.empty() && "Invalid target region parent name!");
 6604   assert(!CGF.getLangOpts().OpenMPIsDevice &&
 6608   assert(isOpenMPTargetExecutionDirective(DirectiveKind) &&
 6821   assert(!CGF.getLangOpts().OpenMPIsDevice &&
 6825   assert(isOpenMPTargetExecutionDirective(DirectiveKind) &&
 7197         assert(ATy && "Expecting array type if not a pointer type.");
 7213       assert(!OAE->getLength() && OAE->getColonLoc().isValid() &&
 7604         assert((Next == CE ||
 7622           assert(!PartialStruct.Base.isValid() && "The base element is set.");
 7623           assert(Next == CE &&
 7625           assert(!IsPointer &&
 7757     assert(Cap.capturesVariable() && "Expected capture by reference only!");
 7838     assert(!RD->isUnion() && "Unexpected union.");
 7937     assert(CurDir.is<const OMPExecutableDirective *>() &&
 7968         assert(!L.second.empty() && "Not expecting empty list of components!");
 8030         assert(!L.Components.empty() &&
 8043           assert(CurBasePointers.size() > CurrentBasePointersIdx &&
 8048           assert(RelevantVD &&
 8096     assert(CurDir.is<const OMPDeclareMapperDecl *>() &&
 8139         assert(!L.Components.empty() &&
 8200       assert(It != Captures.end() && "Found lambda capture without field.");
 8234       assert(BasePtr && "Unable to find base lambda address.");
 8243       assert(TgtIdx != -1 && "Unable to find parent lambda.");
 8260     assert(!Cap->capturesVariableArrayType() &&
 8285     assert(CurDir.is<const OMPExecutableDirective *>() &&
 8290         assert(L.first == VD &&
 8292         assert(!L.second.empty() &&
 8333           assert((CI != CE || SI != SE) &&
 8436     assert(CurDir.is<const OMPExecutableDirective *>() &&
 8458         assert(!PartialStruct.Base.isValid() &&
 8503       assert(CI.capturesVariable() && "Expected captured reference.");
 9169   assert(OutlinedFn && "Invalid outlined function!");
 9196     assert(OutlinedFnID && "Invalid outlined function ID!");
 9254       assert(NumThreads && "Thread limit expression should be available along "
 9364       assert(!CurBasePointers.empty() &&
 9366       assert(CurBasePointers.size() == CurPointers.size() &&
 9647   assert(VD->getType().isConstant(CGM.getContext()) &&
 9706       assert(!VarSize.isZero() && "Expected non-zero size of the variable");
 9725     assert(((*Res == OMPDeclareTargetDeclAttr::MT_Link) ||
 9767       assert((*Res == OMPDeclareTargetDeclAttr::MT_Link ||
 9778   assert(isOpenMPTargetExecutionDirective(D.getDirectiveKind()) &&
 9882     assert((HasEmittedTargetRegion ||
10009     assert(Info.isValid() && "Invalid data environment closing arguments.");
10080   assert((isa<OMPTargetEnterDataDirective>(D) ||
10337         assert(NumElts && "Non-zero simdlen/cdtsize expected");
10459   assert(!Sizes.empty() && "Unable to determine NDS and WDS.");
10462   assert(std::all_of(Sizes.begin(), Sizes.end(),
10617       assert(ISA == 'n' && "Expected ISA either 's' or 'n'.");
10645       assert(ISA == 'n' && "Expected ISA either 's' or 'n'.");
10794     assert(CallArgs.size() == DoacrossFinArgs);
10887     assert(CounterVal);
10902     assert(C->getDependencyKind() == OMPC_DEPEND_sink);
10911   assert(Loc.isValid() && "Outlined function call location must be valid.");
10955     assert(CallArgs.size() == CleanupArgs &&
10993   assert(AA->getAllocator() &&
11317   assert(Options.SimpleReduction && "Only simple reduction is expected.");
tools/clang/lib/CodeGen/CGOpenMPRuntime.h
  477         assert(!Addr.pointsToAliveValue() && "Address has been set before!");
  534         assert(!ID && "ID has been set before!");
tools/clang/lib/CodeGen/CGOpenMPRuntimeNVPTX.cpp
  348           assert(!VD->getType()->isVariablyModifiedType() &&
  427     assert(!GlobalizedRD &&
  593     assert(GlobalizedRD &&
  894   assert(isOpenMPWorksharingDirective(D.getDirectiveKind()) &&
  908   assert(supportsSPMDExecutionMode(Ctx, D) && "Expected SPMD mode directive.");
 1863   assert(!ParentName.empty() && "Invalid target region parent name!");
 1899     assert(requiresFullRuntime() && "Expected full runtime.");
 2000   assert(isOpenMPTeamsDirective(D.getDirectiveKind()) &&
 2025   assert(isOpenMPTeamsDirective(D.getDirectiveKind()) &&
 2052     assert(!TeamAndReductions.first &&
 2082           assert(Pair.getFirst()->isCanonicalDecl() &&
 2201       assert(GlobalizedRecords.back().Records.size() < 2 &&
 2219         assert(KernelStaticGlobalized &&
 2258       assert(KernelStaticGlobalized && "Global address must be set already.");
 2329         assert(I->getSecond().IsInSPMDModeFlag &&
 2332           assert(SecIt->second.IsOnePerTeam &&
 2425         assert(GlobalizedRecords.back().RegionCounter > 0 &&
 2533     assert(WFn && "Wrapper function does not exist!");
 2813   assert(!CGF.getContext().getTypeSizeInChars(CastTy).isZero() &&
 2815   assert(!CGF.getContext().getTypeSizeInChars(ValTy).isZero() &&
 2846   assert(Size.getQuantity() <= 8 &&
 4270     assert(!TeamsReduction && !ParallelReduction &&
 4277   assert((TeamsReduction || ParallelReduction) &&
 4350     assert(TeamsReduction && "expected teams reduction.");
 4481   assert(NativeParam != TargetParam &&
 4661   assert(D && "Expected function or captured|block decl.");
 4662   assert(FunctionGlobalizedDecls.count(CGF.CurFn) == 0 &&
 4664   assert((!TeamAndReductions.first || TeamAndReductions.first == D) &&
 4702     assert(VD->isCanonicalDecl() && "Expected canonical declaration");
 4714       assert(VD->isCanonicalDecl() && "Expected canonical declaration");
 4847   assert(isOpenMPTargetExecutionDirective(D.getDirectiveKind()) &&
 4885       assert(It != Captures.end() && "Found lambda capture without field.");
tools/clang/lib/CodeGen/CGRecordLayout.h
  186     assert(FieldInfo.count(FD) && "Invalid field for record!");
  191     assert(NonVirtualBases.count(RD) && "Invalid non-virtual base!");
  198     assert(CompleteObjectVirtualBases.count(base) && "Invalid virtual base!");
  205     assert(FD->isBitField() && "Invalid call for non-bit-field decl!");
  208     assert(it != BitFields.end() && "Unable to find bitfield info");
tools/clang/lib/CodeGen/CGRecordLayoutBuilder.cpp
  127     assert(!NumBytes.isZero() && "Empty byte arrays aren't allowed.");
  596       assert(Prior->Kind == MemberInfo::Field &&
  602         assert(Prior->FD->hasAttr<NoUniqueAddressAttr>() &&
  657     assert(Offset >= Size);
  750       assert(Builder.Packed == BaseBuilder.Packed &&
  787   assert(TypeSizeInBits == getDataLayout().getTypeAllocSizeInBits(Ty) &&
  796     assert(AlignedNonVirtualTypeSizeInBits ==
  818       assert(AST_RL.getFieldOffset(i) == SL->getElementOffsetInBits(FieldNo) &&
  839         assert(static_cast<unsigned>(Info.Offset + Info.Size) ==
  843         assert(Info.Offset == 0 &&
  845       assert(Info.StorageSize <= SL->getSizeInBits() &&
  848       assert(Info.StorageSize ==
  852     assert(Info.Size > 0 && "Empty bitfield!");
  853     assert(static_cast<unsigned>(Info.Offset) + Info.Size <= Info.StorageSize &&
tools/clang/lib/CodeGen/CGStmt.cpp
   45   assert(S && "Null statement?");
   62       assert(!isa<DeclStmt>(*S) && "Unexpected DeclStmt!");
  110     assert(incoming && "expression emission must have an insertion point");
  115     assert(outgoing && "expression emission cleared block!");
  396   assert((!GetLast || (GetLast && ExprResult)) &&
  548     assert(!Dest.getScopeDepth().isValid() && "already emitted label!");
  570   assert(!Labels.empty());
  577     assert(CGF.LabelMap.count(*i));
  579     assert(dest.getScopeDepth().isValid());
  580     assert(innermostScope.encloses(dest.getScopeDepth()));
 1061     assert(ReturnLocation.isValid() && "No valid return location");
 1148   assert(!BreakContinueStack.empty() && "break stmt not in a loop or switch!");
 1160   assert(!BreakContinueStack.empty() && "continue stmt not in a loop!");
 1175   assert(S.getRHS() && "Expected RHS value in CaseStmt");
 1345   assert(DefaultBlock->empty() &&
 1448           assert(FoundCase && "Didn't find case but returned fallthrough?");
 1463       assert(!HadSkippedDecl && "fallthrough after skipping decl");
 1720     assert(SwitchWeights->size() == 1 + SwitchInsn->getNumCases() &&
 1767       assert(OutCons &&
 1771       assert(result && "Could not resolve symbolic name"); (void)result;
 1803   assert(Target.isValidGCCRegisterName(Register));
 1975     assert(IsValid && "Failed to parse output constraint");
 1986     assert(IsValid && "Failed to parse input constraint"); (void)IsValid;
 2064         assert(InputNo != S.getNumInputs() && "Didn't find matching input!");
 2182           assert(OutputTy->isFloatingPointTy() && "Unexpected output type");
 2293   assert(RegResults.size() == ResultRegTypes.size());
 2294   assert(RegResults.size() == ResultTruncRegTypes.size());
 2295   assert(RegResults.size() == ResultRegDests.size());
 2298   assert(ResultTypeRequiresCast.size() <= ResultRegDests.size());
 2399   assert(CapturedStmtInfo &&
 2404   assert(CD->hasBody() && "missing CapturedDecl body");
tools/clang/lib/CodeGen/CGStmtOpenMP.cpp
   65     assert(S.hasAssociatedStmt() &&
   71         assert(VD == VD->getCanonicalDecl() &&
  153         assert(isa<CXXForRangeStmt>(Body) &&
  224           assert(VD == VD->getCanonicalDecl() &&
  325       assert(CurCap->capturesVariable() && "Expected capture by reference.");
  392   assert(CD->hasBody() && "missing CapturedDecl body");
  436       assert(I->capturesVariableArrayType());
  524         assert(ArgLVal.getType()->isPointerType());
  534       assert(!FD->getType()->isAnyPointerType() &&
  545       assert(I->capturesThis());
  558   assert(
  808             assert(!CE && "Expected non-constant firstprivate.");
  862         assert(IsRegistered &&
  891         assert(IsRegistered && "private var already registered as private");
  923           assert(CapturedStmtInfo->lookup(VD) &&
 1016           assert(IsRegistered &&
 1150     assert(IsRegistered && "private var already registered as private");
 1379       assert(isa<CXXForRangeStmt>(Body) &&
 1540       assert((Alignment == 0 || Alignment.isPowerOf2()) &&
 1622     assert(!E->getType().getNonReferenceType()->isRecordType() &&
 1664         assert(IsRegistered && "linear var already registered as private");
 1773   assert(isOpenMPSimdDirective(S.getDirectiveKind()) &&
 1981   assert((Ordered ||
 2289   assert(Fn && Addr && "Target device function emission failed.");
 3615     assert(!S.getAssociatedStmt() &&
 3643   assert(CGF.hasScalarEvaluationKind(DestType) &&
 3645   assert(!Val.isAggregate() && "Must be a scalar or complex.");
 3655   assert(CGF.getEvaluationKind(DestType) == TEK_Complex &&
 3667     assert(Val.isComplex() && "Must be a scalar or complex.");
 3713   assert(V->isLValue() && "V of 'omp atomic read' is not lvalue");
 3714   assert(X->isLValue() && "X of 'omp atomic read' is not lvalue");
 3737   assert(X->isLValue() && "X of 'omp atomic write' is not lvalue");
 3869   assert(isa<BinaryOperator>(UE->IgnoreImpCasts()) &&
 3878   assert(X->isLValue() && "X of 'omp atomic update' is not lvalue");
 3925   assert(X->isLValue() && "X of 'omp atomic capture' is not lvalue");
 3926   assert(V->isLValue() && "V of 'omp atomic capture' is not lvalue");
 3937     assert(isa<BinaryOperator>(UE->IgnoreImpCasts()) &&
 4117   assert(isOpenMPTargetExecutionDirective(S.getDirectiveKind()));
 4160   assert(CGF.CurFuncDecl && "No parent declaration for target region!");
 4217   assert(Fn && Addr && "Target device function emission failed.");
 4303   assert(Fn && Addr && "Target device function emission failed.");
 4349   assert(Fn && Addr && "Target device function emission failed.");
 4395   assert(Fn && Addr && "Target device function emission failed.");
 4537   assert(Fn && Addr && "Target device function emission failed.");
 4589   assert(Fn && Addr && "Target device function emission failed.");
 4624   assert(Kind == OMPD_for || Kind == OMPD_section || Kind == OMPD_sections ||
 4652       assert(isa<CXXThisExpr>(ME->getBase()) &&
 4688     assert(IsRegistered && "firstprivate var already registered as private");
 4865   assert(Fn && Addr && "Target device function emission failed.");
 4905   assert(Fn && Addr && "Target device function emission failed.");
 4944   assert(Fn && Addr && "Target device function emission failed.");
 4965   assert(isOpenMPTaskLoopDirective(S.getDirectiveKind()));
tools/clang/lib/CodeGen/CGVTT.cpp
   27     assert(VTable.getBaseOffset().isZero() &&
   72       assert(AddressPoint.AddressPointIndex != 0 &&
  106   assert(RD->getNumVBases() && "Only classes with virtual bases need a VTT");
  149   assert(I != SubVTTIndicies.end() && "Did not find index!");
  176   assert(I != SecondaryVirtualPointerIndices.end() && "Did not find index!");
tools/clang/lib/CodeGen/CGVTables.cpp
  164   assert(FnInfo.isVariadic());
  176   assert(!BaseFn->isDeclaration() && "cannot clone undefined variadic method");
  207   assert(ThisStore != EntryBB->end() &&
  238   assert(!CurGD.getDecl() && "CurGD was already set!");
  294   assert(isa<CXXMethodDecl>(CurGD.getDecl()) &&
  343   assert(CallFnInfo.getRegParm() == CurFnInfo->getRegParm() &&
  346   assert(isa<CXXDestructorDecl>(MD) || // ignore dtor return types
  349   assert(CallFnInfo.arg_size() == CurFnInfo->arg_size());
  351     assert(similar(CallFnInfo.arg_begin()[i].info,
  410     assert(ThisAI.isInAlloca() && "this is passed directly or inalloca");
  524     assert(OldThunkFn->isDeclaration() && "Shouldn't replace non-declaration");
  808   assert(!VTable->isDeclaration() && "Shouldn't set properties on declaration");
  843         assert((def || CodeGenOpts.OptimizationLevel > 0 ||
  944   assert(RD->isDynamicClass() && "Non-dynamic classes have no VTable.");
 1003   assert(savedSize == DeferredVTables.size() &&
tools/clang/lib/CodeGen/CGValue.h
   59     assert(isScalar() && "Not a scalar!");
   71     assert(isAggregate() && "Not an aggregate!");
   76     assert(isAggregate() && "Not an aggregate!");
  229     assert((!Alignment.isZero() || Type->isIncompleteType()) &&
  237     assert(this->Alignment == Alignment.getQuantity() &&
  323     assert(isSimple());
  328     assert(isSimple());
  337   llvm::Value *getVectorPointer() const { assert(isVectorElt()); return V; }
  338   llvm::Value *getVectorIdx() const { assert(isVectorElt()); return VectorIdx; }
  345     assert(isExtVectorElt());
  349     assert(isExtVectorElt());
  357   llvm::Value *getBitFieldPointer() const { assert(isBitField()); return V; }
  359     assert(isBitField());
  364   llvm::Value *getGlobalReg() const { assert(isGlobalReg()); return V; }
  373     assert(address.getPointer()->getType()->isPointerTy());
tools/clang/lib/CodeGen/CodeGenABITypes.cpp
   68   assert(FD != nullptr && "Expected a non-null function declaration!");
tools/clang/lib/CodeGen/CodeGenAction.cpp
  148       assert(!Context && "initialized multiple times");
  605   assert(D.getSeverity() == llvm::DS_Error);
  646   assert(D.getSeverity() == llvm::DS_Remark ||
  696     assert(D.isAnalysis() && "Unknown remark type");
  759     assert(CurLinkModule);
 1027     assert(Err.getColumnNo() >= 0);
tools/clang/lib/CodeGen/CodeGenFunction.cpp
   93   assert(LifetimeExtendedCleanupStack.empty() && "failed to emit a cleanup");
  248     assert(!CurBB->getTerminator() && "Unexpected terminated block.");
  296   assert(BreakContinueStack.empty() &&
  360   assert(EHStack.empty() &&
  645   assert(!CurFn &&
  659   assert(CurFn->isDeclaration() && "Function already has body?");
 1763     assert(isa<ConstantArrayType>(arrayType));
 1764     assert(cast<ConstantArrayType>(arrayType)->getSize().getZExtValue()
 1774     assert((!llvmArrayType || arrayType) &&
 1812   assert(vla && "type was not a variable array type!");
 1825     assert(vlaSize && "no size for VLA!");
 1826     assert(vlaSize->getType() == SizeTy);
 1843   assert(vla && "type was not a variable array type!");
 1850   assert(VlaSize && "no size for VLA!");
 1851   assert(VlaSize->getType() == SizeTy);
 1856   assert(type->isVariablyModifiedType() &&
 1864     assert(type->isVariablyModifiedType());
 2012   assert(Init.hasValue() && "Invalid DeclRefExpr initializer!");
 2029   assert(HaveInsertPoint());
 2087   assert(D->hasAttr<AnnotateAttr>() && "no annotate attribute");
 2098   assert(D->hasAttr<AnnotateAttr>() && "no annotate attribute");
 2121   assert(!CGF->IsSanitizerScope);
 2289   assert((getContext().getTargetInfo().getTriple().getArch() ==
 2308       assert(&RO == Options.end() - 1 &&
 2343   assert(Assumption && isa<llvm::CallInst>(Assumption) &&
 2349   assert(&(Builder.GetInsertBlock()->back()) == Assumption &&
tools/clang/lib/CodeGen/CodeGenFunction.h
  630     assert(!DominatingValue<Address>::needsSaving(ActiveFlag) &&
  754       assert(PerformCleanup && "Already forced cleanup");
  785       assert(PerformCleanup && "adding label to dead scope?");
  832       assert(SavedLocals.empty() && "Did not restored original addresses.");
  918       assert(PerformCleanup && "adding private to dead scope");
 1011       assert(CGF.OutermostConditional != this);
 1017       assert(CGF.OutermostConditional != nullptr);
 1034     assert(isInConditionalBranch());
 1112       assert(shouldBindAsLValue(ov));
 1120       assert(!shouldBindAsLValue(ov));
 1137       assert(OpaqueValue && "no data to unbind!");
 1179         assert(OV->getSourceExpr() && "wrong form of OpaqueValueMapping used "
 1285         assert(CGF.getOMPCancelDestination(Kind).isValid());
 1286         assert(CGF.HaveInsertPoint());
 1287         assert(!Stack.back().HasBeenEmitted);
 1312         assert(CGF.getOMPCancelDestination(Stack.back().Kind).isValid());
 2363     assert(it != LocalDeclMap.end() &&
 2446     assert(CXXThisValue && "no 'this' value for this function");
 2456     assert(CXXStructorImplicitParamValue && "no VTT value for this function");
 2736       assert(useLifetimeMarkers());
 2786       assert(!addr.getAlignment().isZero());
 2794       assert(!isIndirect());
 2799       assert(isIndirect());
 3546       assert(isReference());
 3552       assert(!isReference());
 4168     assert(!LocalDeclMap.count(VD) && "Decl already exists in LocalDeclMap!");
 4255     assert((ParamsToSkip == 0 || CallArgTypeInfo) &&
 4266         assert(Arg != ArgRange.end() && "Running over edge of argument list!");
 4267         assert((isGenericMethod ||
 4283     assert((Arg == ArgRange.end() || !CallArgTypeInfo ||
tools/clang/lib/CodeGen/CodeGenModule.cpp
  208     assert(getLangOpts().OpenMPIsDevice &&
  243         assert(CE->getOpcode() == llvm::Instruction::BitCast ||
  323       assert(FTy);
  586     assert(PLevel < 3 && "Invalid PIC Level");
  922   assert(D.getTLSKind() && "setting TLS mode on non-TLS var!");
  964         assert(LHS.startswith("+") && RHS.startswith("+") &&
 1001     assert(II && "Attempt to mangle unnamed decl.");
 1045     assert(OtherGD.getCanonicalDecl()
 1081       assert(OrigCtorType == Ctor_Base || OrigCtorType == Ctor_Complete);
 1266   assert(((FD && CGF) || (!FD && !CGF)) &&
 1525     assert(!F->hasFnAttribute(llvm::Attribute::AlwaysInline) &&
 1812     assert(!F->arg_empty() &&
 1886   assert(!GV->isDeclaration() &&
 1892   assert(!GV->isDeclaration() &&
 2087     assert(DeferredVTables.empty());
 2114     assert(GV);
 2137       assert(DeferredVTables.empty() && DeferredDeclsToEmit.empty());
 2148   assert((OpportunisticVTables.empty() || shouldOpportunisticallyEmitVTables())
 2152     assert(getVTables().isVTableExternal(RD) &&
 2225   assert(D->hasAttr<AnnotateAttr>() && "no annotate attribute");
 2372   assert(Init && "failed to initialize as constant");
 2385   assert(AA && "No alias?");
 2455       assert((isa<FunctionDecl>(Global) || isa<VarDecl>(Global)) &&
 2494     assert(VD->isFileVarDecl() && "Cannot emit local var decl as global.");
 2507             assert(((*Res == OMPDeclareTargetDeclAttr::MT_Link) ||
 2554     assert(!MayBeEmittedEagerly(Global));
 2747   assert(getLangOpts().OpenMP && getLangOpts().OpenMPIsDevice &&
 2874             assert(Func && "This should have just been created");
 2912   assert(FD && "Not a FunctionDecl?");
 2914   assert(DD && "Not a cpu_dispatch Function?");
 3066   assert(isa<llvm::GlobalValue>(Resolver) &&
 3203   assert(F->getName() == MangledName && "name was uniqued!");
 3258     assert(F->getType()->getElementType() == Ty);
 3579   assert(getContext().getTargetAddressSpace(ExpectedAS) ==
 3627     assert(GV->isDeclaration() && "Declaration has wrong type!");
 3666   assert(D->hasGlobalStorage() && "Not a global variable");
 3694   assert(!D->getInit() && "Cannot emit definite definitions here!");
 3725     assert(AddrSpace == LangAS::opencl_global ||
 3909     assert(!ASTTy->isIncompleteType() && "Unexpected incomplete type");
 4243   assert(Linkage == GVA_StrongExternal);
 4437   assert(AA && "Not an alias?");
 4482     assert(Entry->isDeclaration());
 4518   assert(IFA && "Not an ifunc?");
 4555     assert(Entry->isDeclaration());
 4846   assert(!E->getType()->isPointerType() && "Strings are always arrays");
 4874   assert(ElemTy->getPrimitiveSizeInBits() == 32);
 4899     assert(CGM.supportsCOMDAT() && "Only COFF uses weak string literals");
 5004   assert((E->getStorageDuration() == SD_Static ||
 5466     assert(isa<TypeDecl>(D) && "Unsupported decl kind");
 5706   assert(Uuid.size() == 36);
 5708     if (i == 8 || i == 13 || i == 18 || i == 23) assert(Uuid[i] == '-');
 5709     else                                         assert(isHexDigit(Uuid[i]));
 5864   assert(TD != nullptr);
tools/clang/lib/CodeGen/CodeGenModule.h
  578     assert(OpenCLRuntime != nullptr);
  584     assert(OpenMPRuntime != nullptr);
  590     assert(CUDARuntime != nullptr);
  595     assert(ObjCData != nullptr);
tools/clang/lib/CodeGen/CodeGenPGO.cpp
  454     assert(!BreakContinueStack.empty() && "break not in a loop or switch!");
  462     assert(!BreakContinueStack.empty() && "continue stmt not in a loop!");
  724   assert(Type && "Hash is invalid: unexpected type 0");
  725   assert(unsigned(Type) < TooBig && "Hash is invalid: too many types");
  813   assert(Walker.NextCounter > 0 && "no entry counter mapped for decl");
 1005   assert(Scale && "scale by 0?");
 1007   assert(Scaled <= UINT32_MAX && "overflow 32-bits");
 1053   assert(CondCount.hasValue() && "missing expected loop condition count");
tools/clang/lib/CodeGen/CodeGenTBAA.cpp
  359   assert(!Info.isIncomplete() && "Access to an object of an incomplete type!");
  376     assert(!Info.Offset && "Nonzero offset for an access with no base type!");
tools/clang/lib/CodeGen/CodeGenTypes.cpp
  312   assert(QFT.isCanonical());
  570     assert(A->getIndexTypeCVRQualifiers() == 0 &&
  579     assert(A->getIndexTypeCVRQualifiers() == 0 &&
  681       assert(valueSize < atomicSize);
  697   assert(ResultType && "Didn't convert a type?");
  741   assert(InsertResult && "Recursively compiling a struct?");
  757   assert(EraseResult && "struct not in RecordsBeingLaidOut set?");
  788   assert(Layout && "Unable to find record layout information for type");
  793   assert((T->isAnyPointerType() || T->isBlockPointerType()) && "Invalid type");
tools/clang/lib/CodeGen/ConstantEmitter.h
  155     assert(!InitializedNonAbstract);
tools/clang/lib/CodeGen/ConstantInitBuilder.cpp
   22   assert(Data && "dereferencing null future");
   31   assert(Data && "abandoning null future");
   39   assert(Data && "installing null future");
   44     assert(builder.Buffer.size() == 1);
   53   assert(Buffer.empty() && "buffer not current empty");
   61   assert(!builder->Frozen);
   62   assert(builder->Buffer.size() == 1);
   63   assert(builder->Buffer[0] != nullptr);
  170     assert(indices.empty());
  174   assert(position >= Begin);
  204   assert(cacheEnd <= end);
  215     assert(cacheEnd == 0);
  216     assert(Parent && "Begin != 0 for root builder");
  228       assert(element != nullptr &&
  248   assert((Begin < buffer.size() ||
  271     assert(ty->isPacked() == Packed);
tools/clang/lib/CodeGen/CoverageMappingGen.cpp
   70     assert(LocStart && "Region has no start location");
   77     assert(Loc.isValid() && "Setting an invalid end location");
   82     assert(LocEnd && "Region has no end location");
  290       assert(SM.isWrittenInSameFile(LocStart, LocEnd) &&
  311       assert(Region.hasEndLoc() && "incomplete region");
  314       assert(SM.getFileID(LocStart).isValid() && "region in invalid file");
  326       assert(SM.isWrittenInSameFile(LocStart, LocEnd) &&
  338       assert(SR.isInSourceOrder() && "region start and end out of order");
  365       assert(ExpandedFileID && "expansion in uncovered file");
  368       assert(SM.isWrittenInSameFile(ParentLoc, LocEnd) &&
  373       assert(SR.isInSourceOrder() && "region start and end out of order");
  402         assert(Start.isValid() &&
  408         assert(End.isValid() &&
  568     assert(RegionStack.size() >= ParentIndex && "parent not in stack");
  586             assert(SM.isWrittenInSameFile(NestedLoc, EndLoc));
  600             assert(SM.isWrittenInSameFile(StartLoc, NestedLoc));
  621         assert(SM.isWrittenInSameFile(Region.getBeginLoc(), EndLoc));
  622         assert(SpellingRegion(SM, Region).isInSourceOrder());
  638         assert(!ParentOfDeferredRegion && "Consecutive deferred regions");
  649     assert(!ParentOfDeferredRegion && "Deferred region with no parent");
  654     assert(!RegionStack.empty() && "statement has no region");
  764           assert(SpellingRegion(SM, SourceRegions.back()).isInSourceOrder());
  822     assert(SpellingRegion(SM, StartLoc, EndLoc).isInSourceOrder());
  849     assert(!DeferredRegion && "Deferred region never completed");
  871     assert(!DeferredRegion && "Deferred region never completed");
  889     assert(RegionStack.empty() && "Regions entered but never exited");
  925     assert(!BreakContinueStack.empty() && "break not in a loop or switch!");
  934     assert(!BreakContinueStack.empty() && "continue stmt not in a loop!");
 1473   assert(CounterMap);
tools/clang/lib/CodeGen/EHScopeStack.h
  396     assert(hasNormalCleanups() && "adding fixup in scope without cleanups");
  403     assert(I < getNumBranchFixups());
tools/clang/lib/CodeGen/ItaniumCXXABI.cpp
  296     assert(!Args.empty() && "expected the arglist to not be empty!");
  698     assert(VirtualFn && "Virtual fuction pointer not created!");
  699     assert((!ShouldEmitCFICheck || !ShouldEmitVFEInfo || CheckResult) &&
  789   assert(MemPtr->getType() == CGM.PtrDiffTy);
  834   assert(E->getCastKind() == CK_DerivedToBaseMemberPointer ||
  889   assert(E->getCastKind() == CK_DerivedToBaseMemberPointer ||
  962   assert(MD->isInstance() && "Member function must not be static!");
 1121     assert(MemPtr->getType() == CGM.PtrDiffTy);
 1503   assert(CGM.getTarget().getCXXABI().hasConstructorVariants());
 1556   assert(isa<CXXConstructorDecl>(MD) || isa<CXXDestructorDecl>(MD));
 1719   assert((Base.getBase()->getNumVBases() || NearestVBase != nullptr) &&
 1742   assert(VPtrOffset.isZero() && "Itanium ABI only supports zero vptr offsets");
 1821   assert((CE != nullptr) ^ (D != nullptr));
 1822   assert(CE == nullptr || CE->arg_begin() == CE->arg_end());
 1823   assert(DtorType == Dtor_Deleting || DtorType == Dtor_Complete);
 1878       assert(BRD && "no class for base specifier");
 1897     assert(BRD && "no class for base specifier");
 1998   assert(requiresArrayCookie(expr));
 2008   assert(CookieSize == getArrayCookieSizeImpl(ElementType));
 2083   assert(requiresArrayCookie(expr));
 2359   assert((TLS || CGF.getTypes().getCodeGenOpts().CXAAtExit) &&
 2478   assert(!VD->isStaticLocal() && "static local VarDecls don't need wrappers!");
 3235     assert(isa<ObjCInterfaceType>(Ty));
 3339     assert(!OldGV->hasAvailableExternallyLinkage() &&
 3554   assert(isa<BuiltinType>(T) || isa<ObjCInterfaceType>(T));
 3876   assert(Linkage == llvm::GlobalValue::WeakODRLinkage);
 3941     assert(Entry->getType() == Aliasee->getType() &&
 4212   assert(isa<RecordType>(CatchType) && "unexpected catch type!");
 4363     assert(CGF.CGM.getLangOpts().CPlusPlus);
tools/clang/lib/CodeGen/MicrosoftCXXABI.cpp
   82     assert(Args.size() >= 2 &&
  305     assert(GD.getDtorType() == Dtor_Deleting &&
  584     assert(VBTableOffset % 4 == 0 && "should be byte offset into table of i32s");
  915   assert(PolymorphicBase && "polymorphic class has no apparent vfptr?");
 1115   assert(IsMostDerivedClass &&
 1138   assert(IsMostDerivedClass &&
 1180     assert(I != VBaseMap.end());
 1390     assert(Adjustment.isPositive());
 1433     assert(StaticOffset.isPositive());
 1453   assert(isa<CXXConstructorDecl>(MD) || isa<CXXDestructorDecl>(MD));
 1503       assert(Adjustment.isPositive());
 1526     assert(getStructorImplicitParamDecl(CGF) &&
 1535     assert(getStructorImplicitParamDecl(CGF) &&
 1547   assert(Type == Ctor_Complete || Type == Ctor_Base);
 1585     assert(Type != CXXDtorType::Dtor_Deleting &&
 1691     assert(Base.getBase()->getNumVBases() &&
 1715   assert(VFTable && "Couldn't find a vftable for the given base?");
 1908   assert((CE != nullptr) ^ (D != nullptr));
 1909   assert(CE == nullptr || CE->arg_begin() == CE->arg_end());
 1910   assert(DtorType == Dtor_Deleting || DtorType == Dtor_Complete);
 1968   assert(!isa<CXXConstructorDecl>(MD) && !isa<CXXDestructorDecl>(MD) &&
 1987   assert(ThunkFn->getName() == ThunkName && "name was uniqued!");
 2058   assert(!CGM.getModule().getNamedGlobal(Name) &&
 2082   assert(RD->getNumVBases() && ObjectWithVPtr->getNumVBases() &&
 2100     assert(!Offset.isNegative());
 2110     assert(Offsets[VBIndex] == nullptr && "The same vbindex seen twice?");
 2114   assert(Offsets.size() ==
 2138     assert(TA.Virtual.Microsoft.VtordispOffset < 0);
 2156       assert(TA.Virtual.Microsoft.VBPtrOffset > 0);
 2157       assert(TA.Virtual.Microsoft.VBOffsetOffset >= 0);
 2189     assert(RA.Virtual.Microsoft.VBIndex > 0);
 2239   assert(requiresArrayCookie(expr));
 2432     assert(GV->hasWeakLinkage() || GV->hasLinkOnceLinkage());
 2466     assert(GuardNum > 0);
 2513   assert(GuardVar->getLinkage() == GV->getLinkage() &&
 2635   assert(fields.empty());
 2664   assert(Res->getType() == ConvertMemberPointerType(MPT));
 2759     assert(DerivedToBasePath.size() == MemberPointerPath.size());
 2771   assert(MD->isInstance() && "Member function must not be static!");
 2887   assert(!fields.empty());
 2926     assert(Val->getType()->isIntegerTy());
 3036   assert(MPT->isMemberDataPointer());
 3082   assert(E->getCastKind() == CK_DerivedToBaseMemberPointer ||
 3119     assert(Src->getType() == DstNull->getType());
 3302   assert(CK == CK_DerivedToBaseMemberPointer ||
 3327   assert(MPT->isMemberFunctionPointer());
 3886   assert(CT == Ctor_CopyingClosure || CT == Ctor_DefaultClosure);
 3968     assert(PD->hasDefaultArg() && "ctor closure lacks default args");
 4004   assert(!T->isReferenceType());
 4086   assert(!T->isReferenceType());
tools/clang/lib/CodeGen/ModuleBuilder.cpp
   90       assert(DeferredInlineMemberFuncDefs.empty() ||
  131       assert(!M && "Replacing existing Module?");
  192       assert(D->doesThisDeclarationHaveABody());
tools/clang/lib/CodeGen/ObjectFilePCHContainerOperations.cpp
  164     assert(!Ctx && "initialized multiple times");
  238     assert(M && VMContext && Builder);
  270     assert(Buffer->IsComplete && "serialization did not complete");
tools/clang/lib/CodeGen/SwiftCallingConv.cpp
   32   assert(first != second);
  173   assert(bitfield->isBitField());
  194   assert(type && "didn't provide type for typed data");
  200   assert(type && "didn't provide type for typed data");
  201   assert(getTypeStoreSize(CGM, type) == end - begin);
  207     assert(componentTys.size() >= 1);
  213       assert(componentSize < end - begin);
  243       assert(eltSize == getTypeStoreSize(CGM, eltTy));
  248       assert(begin == end);
  260   assert((!type ||
  263   assert(!type || begin.isMultipleOf(getNaturalAlignment(CGM, type)));
  324     assert(eltSize == getTypeStoreSize(CGM, eltTy));
  329     assert(begin == end);
  346     assert(index == 0 || begin >= Entries[index - 1].End);
  352     assert(Entries[index].Type == nullptr);
  406   assert(isPowerOf2(unitSize.getQuantity()));
  486   assert(Entries.empty());
  521         assert(unitSize <= chunkSize);
  543   assert(Finished && "haven't yet finished lowering");
  552   assert(Finished && "haven't yet finished lowering");
  568       assert(!paddingSize.isNegative());
  584     assert(entry.End <= lastEnd);
  610   assert(Finished && "haven't yet finished lowering");
  651   assert(size >= CGM.getDataLayout().getABITypeAlignment(type));
  683   assert(numElts > 1 && "illegal vector length");
  715   assert(numElts != 1);
  721   assert(candidateNumElts <= numElts && candidateNumElts * 2 > numElts);
  736     assert(candidateNumElts == 1U << logCandidateNumElts);
  737     assert(candidateNumElts <= numElts);
  738     assert(candidateSize == eltSize * candidateNumElts);
tools/clang/lib/CodeGen/TargetInfo.cpp
  123       assert(type->isVectorTy() || type->isFloatingPointTy());
  178       assert(!UD->field_empty() && "sema created an empty transparent union");
  377   assert(Addr1.getType() == Addr2.getType());
  439   assert(!CGM.getLangOpts().OpenCL &&
  621     assert(!AI.getPaddingType() &&
  623     assert(
  636     assert((AI.isDirect() || AI.isExtend()) &&
  639     assert(!AI.getInReg() &&
  641     assert(!AI.getPaddingType() &&
  643     assert(!AI.getDirectOffset() &&
  645     assert(!AI.getCoerceToType() &&
 1851   assert(StackOffset.isMultipleOf(FieldAlign) && "unaligned inalloca struct");
 1873     assert(Info.getIndirectByVal());
 1892   assert(IsWin32StructABI && "inalloca only supported on win32");
 1955   assert(Triple.getArch() == llvm::Triple::x86);
 2539   assert((Accum != Memory && Accum != ComplexX87) &&
 2778     assert((Hi != SSEUp || Lo == SSE) && "Invalid SSEUp array classification.");
 2810         assert(!I.isVirtual() && !I.getType()->isDependentType() &&
 2876         assert(!i->isUnnamedBitfield());
 2884           assert(EB_Hi == EB_Lo && "Invalid classification, type > 16 bytes.");
 3022   assert((Size == 128 || Size == 256 || Size == 512) && "Invalid type found!");
 3072         assert(!I.isVirtual() && !I.getType()->isDependentType() &&
 3235   assert(TySizeInBytes != SourceOffset && "Empty field?");
 3259   assert(HiStart != 0 && HiStart <= 8 && "Invalid x86-64 argument pair!");
 3274       assert((Lo->isIntegerTy() || Lo->isPointerTy())
 3283   assert(TD.getStructLayout(Result)->getElementOffset(1) == 8 &&
 3296   assert((Hi != Memory || Lo == Memory) && "Invalid memory classification.");
 3297   assert((Hi != SSEUp || Lo == SSE) && "Invalid SSEUp classification.");
 3306     assert((Hi == SSE || Hi == Integer || Hi == X87Up) &&
 3353     assert(Hi == ComplexX87 && "Unexpected ComplexX87 classification.");
 3388     assert(Lo == SSE && "Unexpected SSEUp classification.");
 3428   assert((Hi != Memory || Lo == Memory) && "Invalid memory classification.");
 3429   assert((Hi != SSEUp || Lo == SSE) && "Invalid SSEUp classification.");
 3440     assert((Hi == SSE || Hi == Integer || Hi == X87Up) &&
 3531     assert(Lo == SSE && "Unexpected SSEUp classification");
 3549   assert(RT && "classifyRegCallStructType only valid with struct types");
 3795     assert(AI.isDirect() && "Unexpected ABI info for mixed regs");
 3799     assert(ST->getNumElements() == 2 && "Unexpected ABI info for mixed regs");
 3802     assert((TyLo->isFPOrFPVectorTy() ^ TyHi->isFPOrFPVectorTy()) &&
 3849     assert(neededSSE == 2 && "Invalid number of needed registers!");
 4255     assert(RegAddr.getElementType() == CGF.Int8Ty);
 5435     assert(!IsIndirect && "Homogeneous aggregates should be passed directly");
 5817   assert(getRuntimeCC() == llvm::CallingConv::C);
 5844   assert(Base && "Base class should be set for homogeneous aggregate");
 5921       assert(Base && Members <= 4 && "unexpected homogeneous aggregate");
 5951     assert(getABIKind() != ARMABIInfo::AAPCS16_VFP && "unexpected byval");
 6711   assert((UnpaddedSize <= PaddedSize) && "Invalid argument size.");
 6740   assert(PaddedSize.getQuantity() == 8);
 6873       assert(Size == 32 || Size == 64);
 7061   assert(!(TySize % 8) && "Size of structure must be multiple of 8.");
 7733     assert(!RD->hasFlexibleArrayMember());
 7827   assert(NumRegsLeft <= MaxNumRegsForArgsRet && "register estimate underflow");
 7985       assert(Min <= Max && "Min must be less than or equal Max");
 7990       assert(Max == 0 && "Max must be zero");
 8005       assert((Max == 0 || Min <= Max) && "Min must be less than or equal Max");
 8012       assert(Max == 0 && "Max must be zero");
 8055   assert(!CGM.getLangOpts().OpenCL &&
 8064   assert(AddrSpace == LangAS::Default || isTargetAddressSpace(AddrSpace));
 8218       assert(ToSize >= Size && "Cannot remove elements");
 8771   assert( (E.Str.empty() || E.State == Recursive) &&
 8773   assert(!StubEnc.empty() && "Passing an empty string to addIncomplete()");
 8788   assert(I != Map.end() && "Entry not present");
 8790   assert( (E.State == Incomplete ||
 8819     assert(E.State==Recursive && E.Str.size() == Str.size() &&
 8826   assert(E.Str.empty() && "Entry already present");
 9364     assert(CurOff.isZero() && "Unexpected offset for first field");
 9515   assert(ArgGPRsLeft <= NumArgGPRs && "Arg GPR tracking underflow");
 9789     assert(Triple.isOSBinFormatELF() && "PPC64 LE non-ELF not supported!");
tools/clang/lib/CodeGen/VarBypassDetector.cpp
  158       assert(Scopes[To].first < To);
  163       assert(Scopes[From].first < From);
tools/clang/lib/CrossTU/CrossTranslationUnit.cpp
  210   assert(DC && "Declaration Context must not be null");
  233   assert(D && "D is missing, bad call to this function!");
  234   assert(!hasBodyOrInit(D) &&
  246   assert(&Unit->getFileManager() ==
  500   assert(hasBodyOrInit(D) && "Decls to be imported should have body or init.");
  502   assert(&D->getASTContext() == &Unit->getASTContext() &&
  525   assert(hasBodyOrInit(ToDecl) && "Imported Decl should have body or init.");
  561     assert(ImportedFileIDs.find(ToID) == ImportedFileIDs.end() &&
tools/clang/lib/DirectoryWatcher/linux/DirectoryWatcher-linux.cpp
   62     assert(Result != -1);
tools/clang/lib/Driver/Action.cpp
   59   assert((OffloadingDeviceKind == OKind || OffloadingDeviceKind == OFK_None) &&
   61   assert(!ActiveOffloadKindMask && "Setting a device kind in a host action??");
   74   assert(OffloadingDeviceKind == OFK_None &&
  112   assert(!((ActiveOffloadKindMask & OFK_Cuda) &&
  226   assert(!getInputs().empty() && "No dependencies for offload action??");
  241   assert(getInputs().size() == DevToolChains.size() + (HostTC ? 1 : 0) &&
  269   assert(hasHostDependence() && "Host dependence does not exist!");
  270   assert(!getInputs().empty() && "No dependencies for offload action??");
  283   assert(hasSingleDeviceDependence(DoNotConsiderHostActions) &&
  328   assert(isa<PrecompileJobAction>((Action*)this) && "invalid action kind");
  388   assert((Kind == VerifyDebugInfoJobClass || Kind == VerifyPCHJobClass) &&
tools/clang/lib/Driver/Compilation.cpp
  184     assert(Res && "Error string set with 0 result code!");
tools/clang/lib/Driver/Driver.cpp
  566     assert(A);
  701               assert(HostTC && "Host toolchain should be always defined.");
  827       assert(!CfgFileName.empty());
 1155   assert(llvm::Triple(llvm::sys::getProcessTriple()).isOSDarwin() &&
 1786       assert(Suffix.front() == '/');
 2093     assert(!Args.hasArg(options::OPT_x) && "-x and /TC or /TP is not allowed");
 2166         assert(InputTypeArg && "InputType set w/o InputTypeArg");
 2217       assert(A->getNumValues() == 1 && "The /U option has one value.");
 2372         assert(!GpuArchList.empty() &&
 2456       assert(CudaDeviceActions.size() == GpuArchList.size() &&
 2458       assert(ToolChains.size() == 1 &&
 2467       assert(AssociatedOffloadKind == Action::OFK_Cuda ||
 2484       assert(HostTC && "No toolchain for host compilation.");
 2575       assert(CudaDeviceActions.size() == GpuArchList.size() &&
 2577       assert(!CompileHostOnly &&
 2614           assert(AssembleAction->getType() == types::TY_Object);
 2615           assert(AssembleAction->getInputs().size() == 1);
 2618           assert(BackendAction->getType() == types::TY_PP_Asm);
 2656       assert(CurPhase < phases::Backend && "Generating single CUDA "
 2695       assert(((CurPhase == phases::Link && Relocatable) ||
 2698       assert(!CompileHostOnly &&
 2809       assert(OpenMPDeviceActions.size() == ToolChains.size() &&
 2815         assert(ToolChains.size() == DeviceLinkerInputs.size() &&
 2875         assert(ToolChains.size() == OpenMPDeviceActions.size() &&
 2882           assert(isa<CompileJobAction>(A));
 2897       assert(OpenMPDeviceActions.size() == ToolChains.size() &&
 2913       assert(ToolChains.size() == DeviceLinkerInputs.size() &&
 3019     assert(HostAction && "Invalid host action!");
 3090     assert(HostAction && "Invalid host action!");
 3102       assert(RetCode != DeviceActionBuilder::ABRT_Ignore_Host &&
 3143       assert(HostAction == AL.back() && "Host action not in the list??");
 3313         assert(ClangClPch);
 3420         assert(Phase == PL.back() && "linking must be final compilation step.");
 3431         assert(Phase == PL.back() && "merging must be final compilation step.");
 3546       assert(OutputTy != types::TY_INVALID &&
 3553     assert(OutputTy != types::TY_INVALID &&
 3811     assert(ElementNum <= ActionInfo.size() && "Invalid number of elements.");
 3954     assert(BaseAction && "Invalid base action.");
 4221       assert(UI.DependentOffloadKind != Action::OFK_None &&
 4263     assert(CachedResults.find(ActionTC) != CachedResults.end() &&
 4374     assert(AtTopLevel && isa<PreprocessJobAction>(JA));
 4487     assert(Suffix && "All types used for output should have a suffix.");
tools/clang/lib/Driver/InputInfo.h
   84     assert(isFilename() && "Invalid accessor.");
   88     assert(isInputArg() && "Invalid accessor.");
tools/clang/lib/Driver/Job.cpp
  195     assert((FlagRef.startswith("-F") || FlagRef.startswith("-I")) &&
  206   assert(NumArgs == 2 && "Not expecting more than two arguments");
  329     assert(Environment.back() == nullptr &&
tools/clang/lib/Driver/Multilib.cpp
   85   assert(GCCSuffix.empty() || (StringRef(GCCSuffix).front() == '/'));
  104     assert(StringRef(Flag).front() == '+' || StringRef(Flag).front() == '-');
  240   assert(Indicator == '+' || Indicator == '-');
  281   assert(false && "More than one multilib with the same priority");
tools/clang/lib/Driver/SanitizerArgs.cpp
  349           assert(NoRTTIArg->getOption().matches(options::OPT_fno_rtti) &&
  846   assert(!(RecoverableKinds & TrappingKinds) &&
 1065   assert((A->getOption().matches(options::OPT_fsanitize_EQ) ||
 1093   assert(A->getOption().matches(options::OPT_fsanitize_coverage) ||
 1144   assert(A->getOption().matches(options::OPT_fsanitize_EQ)
 1158   assert(!Sanitizers.empty() && "arg didn't provide expected value");
tools/clang/lib/Driver/Tool.cpp
   30   assert(Outputs.size() == 1 && "Expected only one output by default!");
tools/clang/lib/Driver/ToolChain.cpp
  872   assert(!Args.hasArg(options::OPT_nostdlibxx) &&
tools/clang/lib/Driver/ToolChains/AIX.cpp
   41   assert((Output.isFilename() || Output.isNothing()) && "Invalid output.");
tools/clang/lib/Driver/ToolChains/AMDGPU.h
   51     assert(opt != OptionsDefault.end() && "No Default for Option");
tools/clang/lib/Driver/ToolChains/AVR.cpp
  127     assert(!CPU.empty() && "CPU name must be known in order to link stdlibs");
tools/clang/lib/Driver/ToolChains/Ananas.cpp
   83     assert(Output.isNothing() && "Invalid output.");
  105     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/Arch/ARM.cpp
  274   assert(ABI != FloatABI::Invalid && "must select an ABI");
tools/clang/lib/Driver/ToolChains/Arch/Mips.cpp
  187   assert(ABI != mips::FloatABI::Invalid && "must select an ABI");
tools/clang/lib/Driver/ToolChains/Arch/RISCV.cpp
  454   assert((Triple.getArch() == llvm::Triple::riscv32 ||
tools/clang/lib/Driver/ToolChains/Clang.cpp
  403   assert(A.getOption().matches(options::OPT_gN_Group) &&
  558     assert(A->getOption().matches(options::OPT_O) && "Must have a -O flag");
  704     assert(!CSPGOGenerateArg);
  709     assert(!PGOGenerateArg);
  915   assert(A && "Expected non-nullptr argument.");
 1336     assert(ABI == arm::FloatABI::Hard && "Invalid float abi!");
 1588     assert(ABI == mips::FloatABI::Hard && "Invalid float abi!");
 1767     assert(FloatABI == ppc::FloatABI::Hard && "Invalid float abi!");
 1799     assert(FloatABI == sparc::FloatABI::Hard && "Invalid float abi!");
 3384   assert(Inputs.size() >= 1 && "Must have at least one input.");
 3484         assert(CTC && "Expected valid CUDA Toolchain.");
 3554     assert(JA.getType() == types::TY_Plist && "Invalid output type.");
 3586     assert((isa<CompileJobAction>(JA) || isa<BackendJobAction>(JA)) &&
 3618       assert(JA.getType() == types::TY_PP_Asm && "Unexpected output type!");
 3746       assert(Output.isNothing() && "Input output.");
 3827   assert(FunctionAlignment <= 31 && "function alignment will be truncated!");
 3938       assert(A->getOption().matches(options::OPT_freg_struct_return));
 3960   assert(FPKeepKindStr && "unknown FramePointerKind");
 4489       assert(A->getOption().matches(options::OPT_fvisibility_ms_compat));
 5359     assert(Tgts && Tgts->getNumValues() &&
 5517     assert(Output.isNothing() && "Invalid output.");
 5706     assert(runtimeArg->getOption().matches(options::OPT_fgnu_runtime));
 6071   assert(Inputs.size() == 1 && "Unexpected number of inputs.");
 6123     assert(!SourceAction->getInputs().empty() && "unexpected root action!");
 6253   assert(Output.isFilename() && "Unexpected lipo output.");
 6265   assert(Input.isFilename() && "Invalid input.");
 6280   assert(isa<OffloadBundlingJobAction>(JA) && "Expecting bundling job!");
 6294   assert(JA.getInputs().size() == Inputs.size() &&
 6312         assert(CurTC == nullptr && "Expected one dependence!");
 6343         assert(CurTC == nullptr && "Expected one dependence!");
 6374   assert(Inputs.size() == 1 && "Expecting to unbundle a single file!");
 6438   assert(Output.isFilename() && "Invalid output.");
 6444     assert(I.isFilename() && "Invalid input.");
tools/clang/lib/Driver/ToolChains/CloudABI.cpp
   62     assert(Output.isNothing() && "Invalid output.");
   77     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/CommonArgs.cpp
   79     assert(Name.startswith("m") && "Invalid feature name.");
 1307   assert(HIPTC->getTriple().getArch() == llvm::Triple::amdgcn &&
 1468     assert(Name[0] == '-' || Name[0] == '+');
 1477     assert(LastI != LastOpt.end());
tools/clang/lib/Driver/ToolChains/Cuda.cpp
  329   assert(TC.getTriple().isNVPTX() && "Wrong platform");
  337     assert(!GPUArchName.empty() && "Must have an architecture passed in.");
  343   assert(gpu_arch != CudaArch::UNKNOWN &&
  454   assert(TC.getTriple().isNVPTX() && "Wrong platform");
  467     assert(A->getInputs().size() == 1 &&
  470     assert(gpu_arch_str &&
  501   assert(TC.getTriple().isNVPTX() && "Wrong platform");
  507   assert(!JA.isHostOffloading(Action::OFK_OpenMP) &&
  514     assert(Output.isNothing() && "Invalid output.");
  523   assert(!GPUArch.empty() && "At least one GPU Arch required for ptxas.");
  608   assert(!GpuArch.empty() && "Must have an explicit GPU arch.");
  609   assert((DeviceOffloadingKind == Action::OFK_OpenMP ||
  753     assert(!Arch.empty() && "Must have an explicit GPU arch.");
tools/clang/lib/Driver/ToolChains/Darwin.cpp
   91   assert(Inputs.size() == 1 && "Unexpected number of inputs.");
   97     assert(!SourceAction->getInputs().empty() && "unexpected root action!");
  139   assert(Output.isFilename() && "Unexpected lipo output.");
  143   assert(Input.isFilename() && "Invalid input.");
  433   assert(Output.getType() == types::TY_Image && "Invalid linker output type.");
  669   assert(Output.isFilename() && "Unexpected lipo output.");
  675     assert(II.isFilename() && "Unexpected lipo input.");
  693   assert(Inputs.size() == 1 && "Unable to handle multiple inputs.");
  695   assert(Input.isFilename() && "Unexpected dsymutil input.");
  714   assert(Inputs.size() == 1 && "Unable to handle multiple inputs.");
  716   assert(Input.isFilename() && "Unexpected verify input");
  779     assert(isTargetMacOS() && "unexpected darwin target");
 1034     assert(DarwinLibName.endswith(".dylib") && "must be a dynamic library");
 1283     assert(Kind == TargetArg && "Unexpected kind!");
 1299     assert(Kind != TargetArg && Kind != OSVersionArg && "Invalid kind");
 1327       assert(Argument && "OS version argument not yet inferred");
 1381     assert(Kind == InferredFromSDK && "can infer SDK info only");
 1385     assert(IsValid && "invalid SDK version");
 1747   assert(OSTarget && "Unable to infer Darwin variant");
 2367       assert(it != ie && "unexpected argument translation");
 2369       assert(A->getOption().getID() == options::OPT_static &&
 2437   assert(TargetInitialized && "Target not initialized!");
 2474     assert(isTargetMacOS() && "unexpected target");
tools/clang/lib/Driver/ToolChains/Darwin.h
  344     assert(!TargetInitialized && "Target already initialized!");
  354     assert(TargetInitialized && "Target not initialized!");
  360     assert(TargetInitialized && "Target not initialized!");
  366     assert(TargetInitialized && "Target not initialized!");
  371     assert(TargetInitialized && "Target not initialized!");
  376     assert(TargetInitialized && "Target not initialized!");
  381     assert(TargetInitialized && "Target not initialized!");
  386     assert(TargetInitialized && "Target not initialized!");
  391     assert(TargetInitialized && "Target not initialized!");
  396     assert(TargetInitialized && "Target not initialized!");
  401     assert(TargetInitialized && "Target not initialized!");
  408     assert(TargetInitialized && "Target not initialized!");
  414     assert(isTargetIOSBased() && "Unexpected call for non iOS target!");
  419     assert(isTargetMacOS() && "Unexpected call for non OS X target!");
tools/clang/lib/Driver/ToolChains/DragonFly.cpp
   89     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/FreeBSD.cpp
  224     assert(Output.isNothing() && "Invalid output.");
  263     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/Fuchsia.cpp
  110     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/Gnu.cpp
  136     assert(Output.isNothing() && "Unexpected output");
  514     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/HIP.cpp
  235   assert(getToolChain().getTriple().getArch() == llvm::Triple::amdgcn &&
  239   assert(StringRef(SubArchName).startswith("gfx") && "Unsupported sub arch");
  274   assert(!GpuArch.empty() && "Must have an explicit GPU arch.");
  276   assert(DeviceOffloadingKind == Action::OFK_HIP &&
  411   assert(getTriple().getArch() == llvm::Triple::amdgcn);
tools/clang/lib/Driver/ToolChains/Hexagon.cpp
  147     assert(Output.isNothing() && "Unexpected output");
  499   assert(A->getNumValues() != 0);
tools/clang/lib/Driver/ToolChains/MSVC.cpp
  315   assert((Output.isFilename() || Output.isNothing()) && "invalid output");
  709   assert(Inputs.size() == 1);
  711   assert(II.getType() == types::TY_C || II.getType() == types::TY_CXX);
  719   assert(Output.getType() == types::TY_Object);
 1374   assert(A->getOption().matches(options::OPT__SLASH_O));
 1469   assert(A->getOption().matches(options::OPT_D));
tools/clang/lib/Driver/ToolChains/Minix.cpp
   54     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/MipsLinux.cpp
  111   assert((GetCXXStdlibType(Args) == ToolChain::CST_Libcxx) &&
tools/clang/lib/Driver/ToolChains/Myriad.cpp
   30   assert(Inputs.size() == 1);
   32   assert(II.getType() == types::TY_C || II.getType() == types::TY_CXX ||
   39     assert(Output.getType() == types::TY_PP_Asm); // Require preprocessed asm.
   91   assert(Inputs.size() == 1);
   93   assert(II.getType() == types::TY_PP_Asm); // Require preprocessed asm input.
   94   assert(Output.getType() == types::TY_Object);
tools/clang/lib/Driver/ToolChains/NetBSD.cpp
  228     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/OpenBSD.cpp
  147     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/PS4CPU.cpp
   58   assert(Inputs.size() == 1 && "Unexpected number of inputs.");
   60   assert(Input.isFilename() && "Invalid input.");
  120     assert(Output.isNothing() && "Invalid output.");
  190     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/RISCVToolchain.cpp
  105     assert(!Inputs.empty() && "Must have at least one input.");
tools/clang/lib/Driver/ToolChains/Solaris.cpp
   81     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/ToolChains/WebAssembly.cpp
   99   assert(Triple.isArch32Bit() != Triple.isArch64Bit());
tools/clang/lib/Driver/ToolChains/XCore.cpp
   69     assert(Output.isNothing() && "Invalid output.");
tools/clang/lib/Driver/Types.cpp
   39   assert(id > 0 && id - 1 < numTypes && "Invalid Type ID.");
   49   assert((llvm::is_contained(getInfo(Id).Phases, phases::Preprocess) !=
  297   assert(0 < P.size() && "Not enough phases in list");
  298   assert(P.size() <= phases::MaxNumberOfPhases && "Too many phases in list");
tools/clang/lib/Edit/Commit.cpp
   27   assert(Loc.isFileID());
   39   assert(Loc.isFileID());
  325   assert(!text.empty());
tools/clang/lib/Edit/EditedSource.cpp
   37   assert(SourceMgr.isMacroArgExpansion(Loc));
  340   assert(len && text.empty());
  357   assert(begin < buffer.size() && end < buffer.size() && "Invalid range!");
  368     assert((end + 1 != buffer.size() || buffer.data()[end + 1] == 0) &&
  386   assert(offs.getFID().isValid());
  389   assert(Loc.isFileID());
  398     assert(len);
  428     assert(offs >= CurEnd);
  456   assert(BeginOffs.getFID() == EndOffs.getFID());
  457   assert(BeginOffs <= EndOffs);
  460   assert(BLoc.isFileID());
tools/clang/lib/Edit/RewriteObjCFoundationAPI.cpp
  111   assert(IFace && Receiver);
tools/clang/lib/Format/BreakableToken.cpp
  187   assert((Token.is(TT_BlockComment) || Token.is(TT_LineComment)) &&
  241   assert(Tok.TokenText.startswith(Prefix) && Tok.TokenText.endswith(Postfix));
  340   assert(Tok.is(TT_BlockComment) &&
  344   assert(TokenText.startswith("/*") && TokenText.endswith("*/"));
  589   assert(LocalIndentAtLineBreak >= Prefix.size());
  629   assert(Tokens[LineIndex - 1] == Tokens[LineIndex] &&
  727   assert(Tok.is(TT_LineComment) &&
  735     assert((TokenText.startswith("//") || TokenText.startswith("#")) &&
  751       assert((TokenText.startswith("//") || TokenText.startswith("#")) &&
  840   assert(IndentAtLineBreak >= Prefix[LineIndex].size());
  942     assert(Prefix[LineIndex] == (OriginalPrefix[LineIndex] + " ").str() &&
tools/clang/lib/Format/ContinuationIndenter.cpp
  280   assert(&Previous == Current.Previous);
  511   assert(!State.Stack.empty());
  527       assert(EndColumn >= StartColumn);
 1084   assert(State.Stack.size());
 1845   assert(Token->getLineCount() > 0);
 1922       assert(Split.first != 0);
 2037       assert(NewRemainingTokenColumns < RemainingTokenColumns);
 2158           assert(Penalty >= NewBreakPenalty);
tools/clang/lib/Format/Encoding.h
   98   assert(Text[0] == '\\');
tools/clang/lib/Format/Format.cpp
  594       assert(Index == Seq.size());
 1148   assert(Style);
 1150   assert(Language != FormatStyle::LK_None);
 1225   assert(Style.Language != LK_None &&
 1227   assert(
 1291             assert(false);
 1649         assert(false && "Fixes must not conflict!");
 1683     assert(Style.Language == FormatStyle::LK_Cpp);
 1968     assert(false);
 2137     assert(false);
 2336     assert(Matched && "Header insertion replacement must have replacement text "
tools/clang/lib/Format/FormatToken.cpp
  147   assert(End->TotalLength >= Begin->TotalLength);
  249       assert(i < MustBreakBeforeItem.size());
tools/clang/lib/Format/FormatTokenLexer.cpp
   49   assert(Tokens.empty());
   50   assert(FirstInLineIndex == 0);
tools/clang/lib/Format/NamespaceEndCommentsFixer.cpp
   32   assert(NamespaceTok &&
   40     assert(Tok && Tok->is(tok::l_paren) && "expected an opening parenthesis");
   90   assert(hasEndComment(RBraceTok));
  142   assert(hasEndComment(RBraceTok));
  162   assert(StartLineIndex < AnnotatedLines.size());
tools/clang/lib/Format/SortJavaScriptImports.cpp
  199       assert(false);
tools/clang/lib/Format/TokenAnalyzer.cpp
   73   assert(UnwrappedLines.rbegin()->empty());
  115   assert(!UnwrappedLines.empty());
tools/clang/lib/Format/TokenAnnotator.cpp
 2160   assert(Line.MightBeFunctionDecl);
 2286       assert(IndentLevel > 0);
 3555       assert(Tok == Line.Last);
tools/clang/lib/Format/TokenAnnotator.h
   48     assert(!Line.Tokens.empty());
  101     assert(MightBeFunctionDecl);
tools/clang/lib/Format/UnwrappedLineFormatter.cpp
  145   assert(StartLineIndex < AnnotatedLines.size());
  684     assert(!A.Last->Next);
  685     assert(!B.First->Previous);
  837     assert(!DryRun);
 1067   assert(!Lines.empty());
tools/clang/lib/Format/UnwrappedLineParser.cpp
  102     assert(!eof());
  157     assert(Parser.Line->Tokens.empty());
  206     assert(Position >= 0);
  292       assert(PPLevelBranchIndex.size() == PPLevelBranchCount.size());
  293       assert(PPLevelBranchIndex.back() <= PPLevelBranchCount.back());
  403   assert(Tok->Tok.is(tok::l_brace));
  535   assert(FormatTok->isOneOf(tok::l_brace, TT_MacroBlockBegin) &&
  661   assert(FormatTok->Tok.is(tok::hash) && "'#' expected");
  711   assert(PPBranchLevel >= 0 && PPBranchLevel <= (int)PPLevelBranchIndex.size());
  724   assert(PPBranchLevel < (int)PPLevelBranchIndex.size());
  733   assert(PPBranchLevel < (int)PPLevelBranchIndex.size());
  974   assert(!FormatTok->is(tok::l_brace));
 1418   assert(FormatTok->is(tok::l_square));
 1527   assert(FormatTok->is(Keywords.kw_function) ||
 1572   assert(FormatTok->BlockKind != BK_Unknown);
 1675   assert(FormatTok->Tok.is(tok::l_paren) && "'(' expected.");
 1727     assert(FormatTok->Tok.is(tok::l_square) && "'[' expected.");
 1765   assert(FormatTok->Tok.is(tok::kw_if) && "'if' expected");
 1807   assert(FormatTok->isOneOf(tok::kw_try, tok::kw___try) && "'try' expected");
 1876   assert(FormatTok->isOneOf(tok::kw_namespace, TT_NamespaceMacro) &&
 1910   assert(FormatTok->is(tok::kw_new) && "'new' expected");
 1935   assert(FormatTok->isOneOf(tok::kw_for, tok::kw_while, TT_ForEachMacro) &&
 1957   assert(FormatTok->Tok.is(tok::kw_do) && "'do' expected");
 2013   assert(FormatTok->Tok.is(tok::kw_case) && "'case' expected");
 2022   assert(FormatTok->Tok.is(tok::kw_switch) && "'switch' expected");
 2249   assert(FormatTok->Tok.isOneOf(tok::l_paren, tok::identifier) &&
 2269   assert(FormatTok->Tok.is(tok::less) && "'<' expected.");
 2305   assert(FormatTok->Tok.getObjCKeywordID() == tok::objc_interface ||
 2330         assert(NumOpenAngles > 0 && "'>' makes NumOpenAngles negative");
 2362   assert(FormatTok->Tok.getObjCKeywordID() == tok::objc_protocol);
 2393   assert(IsImport || FormatTok->is(tok::kw_export));
 2703     assert(FormatTok);
 2712       assert((LevelDifference >= 0 ||
tools/clang/lib/Format/UsingDeclarationsSorter.cpp
   88   assert(UsingTok && UsingTok->is(tok::kw_using) && "Expecting a using token");
tools/clang/lib/Format/WhitespaceManager.cpp
  116     assert(PreviousOriginalWhitespaceEndOffset <=
  294     assert(Shift >= 0);
  464       assert(Shift >= 0);
  704     assert(Shift >= 0);
  739       assert(C.ContinuesPPDirective);
  752       assert(Changes[i - 1].OriginalWhitespaceRange.getBegin() !=
  786     assert(false);
tools/clang/lib/Frontend/ASTConsumers.cpp
  150   assert((DumpDecls || Deserialize || DumpLookups) && "nothing to dump");
tools/clang/lib/Frontend/ASTMerge.cpp
   90   assert(AdaptedAction && "ASTMergeAction needs an action to adapt");
tools/clang/lib/Frontend/ASTUnit.cpp
  279   assert(getDiagnostics().getClient() && Ctx &&
  626     assert((StoredDiags || StandaloneDiags) &&
  736   assert(FileMgr);
  749   assert(Diags.get() && "no DiagnosticsEngine was provided");
 1106     assert(VFS == &FileMgr->getVirtualFileSystem() &&
 1111     assert(Preamble &&
 1152   assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
 1154   assert(Clang->getFrontendOpts().Inputs[0].getKind().getFormat() ==
 1157   assert(Clang->getFrontendOpts().Inputs[0].getKind().getLanguage() !=
 1352   assert(!Preamble && "No Preamble should be stored at that point");
 1406   assert(Preamble && "Preamble wasn't built");
 1430   assert(Preamble && "Should only be called when preamble was built");
 1448   assert(CI.hasInvocation() && "missing invocation");
 1521   assert(CI && "A CompilerInvocation is required");
 1585   assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
 1587   assert(Clang->getFrontendOpts().Inputs[0].getKind().getFormat() ==
 1590   assert(Clang->getFrontendOpts().Inputs[0].getKind().getLanguage() !=
 1665   assert(VFS && "VFS is null");
 1742   assert(Diags.get() && "no DiagnosticsEngine was provided");
 1832     assert(FileMgr && "FileMgr is null on Reparse call");
 2166   assert(IncludeBriefComments == this->IncludeBriefCommentsInCodeCompletion);
 2211   assert(Clang->getFrontendOpts().Inputs.size() == 1 &&
 2213   assert(Clang->getFrontendOpts().Inputs[0].getKind().getFormat() ==
 2216   assert(Clang->getFrontendOpts().Inputs[0].getKind().getLanguage() !=
 2265     assert(Preamble &&
 2412   assert(D);
 2428   assert(SM.isLocalSourceLocation(FileLoc));
 2458     assert(Ctx->getExternalSource() && "No external source!");
 2700   assert(acquired && "Concurrent access to ASTUnit!");
tools/clang/lib/Frontend/ChainedIncludesSource.cpp
  116   assert(!includes.empty() && "No '-chain-include' in options!");
  174       assert(!SerialBufs.empty());
  200     assert(Buffer->IsComplete && "serialization did not complete");
  208   assert(!SerialBufs.empty());
tools/clang/lib/Frontend/CompilerInstance.cpp
   68   assert(OutputFiles.empty() && "Still output files in flight?");
  142   assert(ModuleCache.get() == &Reader->getModuleManager().getModuleCache() &&
  316   assert(VFS && "FileManager has no VFS?");
  711   assert((!CreateMissingDirectories || UseTemporary) &&
  806   assert(!NonSeekStream);
  834     assert(SourceMgr.getMainFileID().isValid() &&
  892   assert(SourceMgr.getMainFileID().isValid() &&
  900   assert(hasDiagnostics() && "Diagnostics engine is not initialized!");
  901   assert(!getFrontendOpts().ShowHelp && "Client must handle '-help'!");
  902   assert(!getFrontendOpts().ShowVersion && "Client must handle '-version'!");
 1104   assert(ImportingInstance.getInvocation().getModuleHash() ==
 1365     assert(LatestDef.isUndefined() &&
 1401   assert(!TimestampFile.empty());
 1772       assert(Module && "missing module file");
 1808         assert(getDiagnostics().hasErrorOccurred() &&
tools/clang/lib/Frontend/CompilerInvocation.cpp
  135     assert(A->getOption().matches(options::OPT_O));
 1278       assert(A->getOption().matches(OPT_freg_struct_return));
 2571         assert(!Opts.ObjCWeak);
tools/clang/lib/Frontend/DependencyFile.cpp
  292   assert(OutputFormat == DependencyOutputFormat::Make);
tools/clang/lib/Frontend/DiagnosticRenderer.cpp
   93   assert(Loc.hasManager() || Loc.isInvalid());
  266   assert(SM->getFileID(Loc) == MacroFileID);
  485   assert(Loc.isMacroID() && "Must be a macro expansion!");
  529   assert(Loc.isValid() && "must have a valid source location here");
  554     assert(L.isValid() && "must have a valid source location here");
tools/clang/lib/Frontend/FrontendAction.cpp
  540   assert(!Instance && "Already processing a source file!");
  541   assert(!Input.isEmpty() && "Unexpected empty filename!");
  606       assert(ASTModule && "module file does not define its own module");
  622     assert(!usesPreprocessorOnly() && "this case was handled above");
  623     assert(hasASTFileSupport() &&
  688     assert(hasIRSupport() &&
  785       assert(BufferID.isValid() && "couldn't creaate module buffer ID");
  843       assert(hasPCHSupport() && "This action does not have PCH support!");
  894     assert((!CI.getLangOpts().Modules || CI.getModuleManager()) &&
tools/clang/lib/Frontend/FrontendActions.cpp
  930     assert(CI.getDiagnostics().hasErrorOccurred() &&
tools/clang/lib/Frontend/InitHeaderSearch.cpp
  134   assert(!Path.isTriviallyEmpty() && "can't handle empty path here");
  489       assert(CurEntry.isHeaderMap() && "Not a headermap or normal dir?");
  506         assert(FirstDir != i && "Didn't find dupe?");
  520           assert(CurEntry.isHeaderMap() && "Not a headermap or normal dir?");
  611         assert(SearchList[i].isHeaderMap() && "Unknown DirectoryLookup");
tools/clang/lib/Frontend/InitPreprocessor.cpp
  108   assert(Sem == (const llvm::fltSemantics*)&llvm::APFloat::IEEEquad());
  777   assert(TI.getCharWidth() == 8 && "Only support 8-bit char so far");
tools/clang/lib/Frontend/InterfaceStubFunctionsConsumer.cpp
  297     assert(Format == "experimental-ifs-v1" && "Unexpected IFS Format.");
tools/clang/lib/Frontend/PrecompiledPreamble.cpp
  117   assert(IsInserted && "File has already been added");
  124   assert(WasPresent && "File was not tracked");
  242   assert(VFS && "VFS is null");
  400     assert(false && "Calling getSize() on invalid PrecompiledPreamble. "
  410     assert(Result <= std::numeric_limits<std::size_t>::max() &&
  423   assert(
  530   assert(this->Storage.getKind() != PCHStorage::Kind::Empty);
  594   assert(FilePath && "TempPCHFile doesn't have a FilePath. Had it been moved?");
  641   assert(getKind() == Kind::TempFile);
  652   assert(getKind() == Kind::InMemory);
  707   assert(VFS);
  749     assert(Storage.getKind() == PCHStorage::Kind::InMemory);
tools/clang/lib/Frontend/PrintPreprocessedOutput.cpp
  342     assert(!TokenText.empty());
  862     assert(Opts.ShowMacros && "Not yet implemented!");
tools/clang/lib/Frontend/Rewrite/FrontendActions.cpp
  216     assert(File && "missing file for loaded module?");
  224     assert(MF && "missing module file for loaded module?");
  231     assert(OS && "loaded module file after finishing rewrite action?");
tools/clang/lib/Frontend/Rewrite/InclusionRewriter.cpp
   67     assert(Tok.getKind() == tok::annot_module_begin);
  170   assert(P.second && "Unexpected revisitation of the same include directive");
  179   assert(LastInclusionLocation.isValid() &&
  205     assert(P.second && "Unexpected revisitation of the same include directive");
  215   assert(P.second && "Unexpected revisitation of the same if directive");
  224   assert(P.second && "Unexpected revisitation of the same elif directive");
  283   assert(!Invalid);
  384   assert(!Invalid && "Attempting to process invalid inclusion");
  403   assert(SM.getLineNumber(FileId, NextToWrite) == 1);
tools/clang/lib/Frontend/Rewrite/RewriteMacros.cpp
   49   assert(CurTok < RawTokens.size() && "Overran eof!");
tools/clang/lib/Frontend/Rewrite/RewriteModernObjC.cpp
  255       assert(Old != nullptr && New != nullptr && "Expected non-null Stmt's");
  927     assert((*startBuf == '@') && "bogus @synthesize location");
  929     assert((*semiBuf == ';') && "@synthesize: can't find ';'");
  940   assert(IMD && OID && "Synthesized ivars must be attached to @implementation");
 1154   assert(PDecl->isThisDeclarationADefinition());
 1334   assert((IMD || CID) && "Unknown implementation type");
 1680   assert(!Stmts.empty() && "ObjCForCollectionStmt - Statement stack empty");
 1681   assert(isa<ObjCForCollectionStmt>(Stmts.back()) &&
 1683   assert(!ObjCBcLabelNo.empty() &&
 1836     assert(semiBuf && "Can't find ';'");
 1863   assert((*startBuf == '@') && "bogus @synchronized location");
 1890   assert (*LBraceLocBuf == '{');
 1894   assert((*SM->getCharacterData(startRBraceLoc) == '}') &&
 1947   assert((*startBuf == '@') && "bogus @try location");
 1970           assert((*startBuf == '@') && "bogus @catch location");
 2038   assert((*startBuf == '@') && "bogus @throw location");
 2049   assert((*wBuf == 'w') && "@throw: can't find 'w'");
 2055   assert((*semiBuf == ';') && "@throw: can't find ';'");
 2077   assert(SelGetUidFunctionDecl && "Can't find sel_registerName() decl");
 2138   assert(angle == 0 && "scanToNextArgument - bad protocol type syntax");
 2202     assert(funcType && "missing function type");
 2407   assert(!argT.isNull() && "Can't find 'id' type");
 2424   assert(!argT.isNull() && "Can't find 'id' type");
 2427   assert(!argT.isNull() && "Can't find 'SEL' type");
 2457   assert(!argT.isNull() && "Can't find 'id' type");
 2460   assert(!argT.isNull() && "Can't find 'SEL' type");
 2493   assert(!argT.isNull() && "Can't find 'id' type");
 2496   assert(!argT.isNull() && "Can't find 'SEL' type");
 2552   assert (Exp != nullptr && "Expected non-null ObjCStringLiteral");
 3158     assert(CurMethodDef && "SynthMsgSendStretCallExpr - CurMethodDef is null");
 3228     assert(MsgSendFlavor && "MsgSendFlavor is NULL!");
 3327     assert(MsgSendFlavor && "MsgSendFlavor is NULL!");
 3646         assert(false && "class not allowed as an ivar type");
 3828   assert(!RetQT.isNull() && "GetGroupRecordTypeForObjCIvarBitfield struct type is NULL");
 3876   assert(CDecl && "Class missing in SynthesizeObjCInternalStruct");
 3877   assert(CDecl->getName() != "" &&
 4005       assert(false &&
 4014       assert(false &&
 4023   assert(BlockByRefDeclNo.count(VD) &&
 4060     assert(FT && "SynthesizeBlockFunc: No function proto");
 4583     assert(false && "RewriteBlockClass: Bad type");
 4585   assert(CPT && "RewriteBlockClass: Bad type");
 4587   assert(FT && "RewriteBlockClass: Bad type");
 4774   assert((*startArgList == '(') && "Rewriter fuzzy parser confused");
 4779   assert((DeclLoc.isValid()) && "Invalid DeclLoc");
 4807     assert(BPT && "BlockPointerTypeTakeAnyBlockArguments(): not a block pointer type");
 4825     assert(BPT && "BlockPointerTypeTakeAnyBlockArguments(): not a block pointer type");
 4844   assert((*argPtr == '(') && "Rewriter fuzzy parser confused");
 4858   assert((*argPtr == ')') && "Rewriter fuzzy parser confused");
 5053     assert(CurMethodDef && "RewriteByRefVar - CurMethodDef is null");
 5120     assert((*commaBuf == ',') && "RewriteByRefVar: can't find ','");
 5149     assert((*separatorBuf == separator) &&
 5349       assert(RD && "SynthBlockInitExpr(): Can't find RecordDecl");
 5360             assert (CI.isByRef() &&
 5390     assert (!GlobalConstructionExp &&
 5593             assert(!BlockByRefDeclNo.count(ND) &&
 5616     assert(!Stmts.empty() && "Statement stack is empty");
 5617     assert ((isa<SwitchStmt>(Stmts.back()) || isa<WhileStmt>(Stmts.back()) ||
 7003     assert(false &&
 7455       assert(iFaceDecl && "RewriteObjCIvarRefExpr - iFaceDecl is null");
 7460       assert(clsDeclared && "RewriteObjCIvarRefExpr(): Can't find class");
tools/clang/lib/Frontend/Rewrite/RewriteObjC.cpp
  206       assert(Old != nullptr && New != nullptr && "Expected non-null Stmt's");
  774   assert((*startBuf == '@') && "bogus @synthesize location");
  776   assert((*semiBuf == ';') && "@synthesize: can't find ';'");
  986   assert(PDecl->isThisDeclarationADefinition());
 1166   assert((IMD || CID) && "Unknown ImplementationDecl");
 1474   assert(!Stmts.empty() && "ObjCForCollectionStmt - Statement stack empty");
 1475   assert(isa<ObjCForCollectionStmt>(Stmts.back()) &&
 1477   assert(!ObjCBcLabelNo.empty() &&
 1627     assert(semiBuf && "Can't find ';'");
 1647   assert((*startBuf == '@') && "bogus @synchronized location");
 1673   assert((*startBuf == '}') && "bogus @synchronized block");
 1694   assert(syncExpr != nullptr && "Expected non-null Expr");
 1748     assert((*semiBuf == ';') && "RewriteTryReturnStmts: can't find ';'");
 1770     assert((*semiBuf == ';') && "RewriteSyncReturnStmts: can't find ';'");
 1788   assert((*startBuf == '@') && "bogus @try location");
 1804   assert((*startBuf == '}') && "bogus @try block");
 1835     assert((*startBuf == '@') && "bogus @catch location");
 1844       assert(*SM->getCharacterData(Catch->getRParenLoc()) == ')' &&
 1846       assert((*bodyBuf == '{') && "bogus @catch body location");
 1872       assert((*rParenBuf == ')') && "bogus @catch paren location");
 1873       assert((*bodyBuf == '{') && "bogus @catch body location");
 1885     assert(*SM->getCharacterData(bodyLoc) == '}' &&
 1905     assert((*startBuf == '@') && "bogus @finally start");
 1912     assert(*SM->getCharacterData(startLoc) == '{' &&
 1914     assert(*SM->getCharacterData(endLoc) == '}' &&
 1956   assert((*startBuf == '@') && "bogus @throw location");
 1967   assert((*wBuf == 'w') && "@throw: can't find 'w'");
 1971   assert((*semiBuf == ';') && "@throw: can't find ';'");
 1992   assert(SelGetUidFunctionDecl && "Can't find sel_registerName() decl");
 2054   assert(angle == 0 && "scanToNextArgument - bad protocol type syntax");
 2118     assert(funcType && "missing function type");
 2316   assert(!argT.isNull() && "Can't find 'id' type");
 2333   assert(!argT.isNull() && "Can't find 'id' type");
 2336   assert(!argT.isNull() && "Can't find 'SEL' type");
 2355   assert(!argT.isNull() && "Can't build 'struct objc_super *' type");
 2358   assert(!argT.isNull() && "Can't find 'SEL' type");
 2374   assert(!argT.isNull() && "Can't find 'id' type");
 2377   assert(!argT.isNull() && "Can't find 'SEL' type");
 2398   assert(!argT.isNull() && "Can't build 'struct objc_super *' type");
 2401   assert(!argT.isNull() && "Can't find 'SEL' type");
 2418   assert(!argT.isNull() && "Can't find 'id' type");
 2421   assert(!argT.isNull() && "Can't find 'SEL' type");
 2477   assert(Exp != nullptr && "Expected non-null ObjCStringLiteral");
 2655     assert(MsgSendFlavor && "MsgSendFlavor is NULL!");
 2753     assert(MsgSendFlavor && "MsgSendFlavor is NULL!");
 3087   assert(CDecl && "Class missing in SynthesizeObjCInternalStruct");
 3088   assert(CDecl->getName() != "" &&
 3119     assert((cursor && endBuf)
 3237   assert(BlockByRefDeclNo.count(VD) &&
 3270     assert(FT && "SynthesizeBlockFunc: No function proto");
 3751     assert(false && "RewriteBlockClass: Bad type");
 3753   assert(CPT && "RewriteBlockClass: Bad type");
 3755   assert(FT && "RewriteBlockClass: Bad type");
 3928   assert((*startArgList == '(') && "Rewriter fuzzy parser confused");
 3933   assert((DeclLoc.isValid()) && "Invalid DeclLoc");
 3961     assert(BPT && "BlockPointerTypeTakeAnyBlockArguments(): not a block pointer type");
 3979     assert(BPT && "BlockPointerTypeTakeAnyBlockArguments(): not a block pointer type");
 3998   assert((*argPtr == '(') && "Rewriter fuzzy parser confused");
 4012   assert((*argPtr == ')') && "Rewriter fuzzy parser confused");
 4210     assert(CurMethodDef && "RewriteByRefVar - CurMethodDef is null");
 4304     assert((*semiBuf == ';') && "RewriteByRefVar: can't find ';'");
 4486       assert(RD && "SynthBlockInitExpr(): Can't find RecordDecl");
 4497             assert (CI.isByRef() &&
 4695             assert(!BlockByRefDeclNo.count(ND) &&
 4718     assert(!Stmts.empty() && "Statement stack is empty");
 4719     assert ((isa<SwitchStmt>(Stmts.back()) || isa<WhileStmt>(Stmts.back()) ||
 5808       assert(iFaceDecl && "RewriteObjCIvarRefExpr - iFaceDecl is null");
 5813       assert(clsDeclared && "RewriteObjCIvarRefExpr(): Can't find class");
 5822       assert(RD && "RewriteObjCIvarRefExpr(): Can't find RecordDecl");
 5842     assert(!IV->isFreeIvar() && "Cannot have a free standing ivar outside a method");
 5853       assert(clsDeclared && "RewriteObjCIvarRefExpr(): Can't find class");
 5862       assert(RD && "RewriteObjCIvarRefExpr(): Can't find RecordDecl");
tools/clang/lib/Frontend/SerializedDiagnosticPrinter.cpp
   39     assert(Abbrevs.find(recordID) == Abbrevs.end()
   45     assert(Abbrevs.find(recordID) != Abbrevs.end() &&
  604   assert(Info.hasSourceManager() && LangOpts &&
tools/clang/lib/Frontend/TestModuleFileExtension.cpp
  117   assert(Metadata.BlockName == BlockName && "Wrong block name");
tools/clang/lib/Frontend/TextDiagnostic.cpp
  100   assert(i && "i must not be null");
  101   assert(*i<SourceLine.size() && "must point to a valid index");
  104     assert(0 < TabStop && TabStop <= DiagnosticOptions::MaxTabStop &&
  108     assert(0 < NumSpaces && NumSpaces <= TabStop
  131     assert(llvm::conversionOK == res);
  132     assert(0 < begin-original_begin
  261     assert(m_byteToColumn.size()==SourceLine.size()+1);
  262     assert(0 < m_byteToColumn.size() && 0 < m_columnToByte.size());
  263     assert(m_byteToColumn.size()
  265     assert(static_cast<unsigned>(m_byteToColumn.back()+1)
  274     assert(0<=n && n<static_cast<int>(m_byteToColumn.size()));
  280     assert(0 <= N && N < static_cast<int>(m_byteToColumn.size()));
  290     assert(0<=n && n<static_cast<int>(m_columnToByte.size()));
  296     assert(0 <= N && N < static_cast<int>(m_byteToColumn.size() - 1));
  303     assert(0 < N && N < static_cast<int>(m_byteToColumn.size()));
  335   assert(CaretLine.end() ==
  382   assert((static_cast<int>(CaretStart) > map.columns() ||
  386   assert((static_cast<int>(CaretEnd) > map.columns() ||
  435       assert(map.byteToColumn(NewStart) != -1);
  457       assert(map.byteToColumn(NewEnd) != -1);
  477   assert(CaretStart!=(unsigned)-1 && CaretEnd!=(unsigned)-1 &&
  479   assert(SourceStart <= SourceEnd);
  480   assert(CaretStart <= CaretEnd);
  488   assert(FrontColumnsRemoved+ColumnsKept+BackColumnsRemoved > Columns);
  548   assert(Start < Str.size() && "Invalid start position!");
  661   assert(TextNormal && "Text highlighted at end of diagnostic message.");
  755     assert(Normal && "Formatting should have returned to normal");
 1027   assert(StartColNo <= EndColNo && "Invalid range!");
 1049       assert(StartLineNo != EndLineNo && "trying to highlight whitespace");
 1054   assert(StartColNo <= map.getSourceLine().size() && "Invalid range!");
 1055   assert(EndColNo <= map.getSourceLine().size() && "Invalid range!");
 1061   assert(StartColNo <= EndColNo && "Invalid range!");
 1097         assert(HintByteOffset < static_cast<unsigned>(map.bytes())+1);
 1141   assert(Loc.isValid() && "must have a valid source location here");
 1142   assert(Loc.isFileID() && "must have a file location here");
tools/clang/lib/Frontend/TextDiagnosticPrinter.cpp
  100         assert(DiagOpts.ShowCategories == 2 && "Invalid ShowCategories value");
  147   assert(DiagOpts && "Unexpected diagnostic without options set");
  148   assert(Info.hasSourceManager() &&
  150   assert(TextDiag && "Unexpected diagnostic outside source file processing");
tools/clang/lib/Frontend/VerifyDiagnosticConsumer.cpp
  213         assert(isLetter(*P) && "-verify prefix must start with a letter");
  653   assert(!ActiveSourceFiles && "Incomplete parsing of source files!");
  654   assert(!CurrentPreprocessor && "CurrentPreprocessor should be invalid!");
  657   assert(!Diags.ownsClient() &&
  680   assert((!PP || CurrentPreprocessor == PP) && "Preprocessor changed!");
  685   assert(ActiveSourceFiles && "No active source files!");
 1130       assert(RegexMatchLength != StringRef::npos);
tools/clang/lib/Index/CommentToXML.cpp
  283     assert(C->getNumArgs() == 1);
  289     assert(C->getNumArgs() == 1);
  295     assert(C->getNumArgs() == 1);
  627     assert(C->getNumArgs() == 1);
  633     assert(C->getNumArgs() == 1);
  639     assert(C->getNumArgs() == 1);
tools/clang/lib/Index/FileIndexRecord.cpp
   22   assert(D->isCanonicalDecl() &&
tools/clang/lib/Index/IndexBody.cpp
   42     assert(StmtStack.back() == S);
   60     assert(!StmtStack.empty() && E == StmtStack.back());
tools/clang/lib/Index/IndexDecl.cpp
  533     assert(D->getPropertyImplementation() == ObjCPropertyImplDecl::Synthesize);
tools/clang/lib/Index/IndexSymbol.cpp
   53   assert(D);
   85   assert(D);
tools/clang/lib/Index/IndexTypeSourceInfo.cpp
   31       assert(Parent);
   35       assert(Parent);
tools/clang/lib/Index/IndexingAction.cpp
   71     assert(this->DataConsumer != nullptr);
   72     assert(this->PP != nullptr);
  112     assert(this->DataConsumer != nullptr);
  137   assert(DataConsumer != nullptr);
tools/clang/lib/Index/IndexingContext.cpp
  297       assert(D->isCanonicalDecl());
  395     assert(!isTemplateImplicitInstantiation(D));
tools/clang/lib/Index/USRGeneration.cpp
  118     assert(EmittedDeclName && "EmitDeclName can not fail for UsingDecls");
  543   assert(Buf.size() > 0);
tools/clang/lib/Lex/DependencyDirectivesSourceMinimizer.cpp
  111   assert(CurPtr >= Input.data() && "invalid buffer ptr");
  123   assert(First <= Current);
  147   assert(First[0] == '"');
  148   assert(First[-1] == 'R');
  199   assert(*First == '\'' || *First == '"' || *First == '<');
  231   assert(isVerticalWhitespace(*First));
  233   assert(Len && "expected newline");
  266   assert(First <= Last);
  277   assert(isHorizontalWhitespace(LastNonSpace[0]));
  282   assert(First[0] == '/' && First[1] == '/');
  288   assert(First[0] == '/' && First[1] == '*');
  305   assert(*Cur == '\'' && "expected quotation character");
  326     assert(First <= End);
  450     assert(First <= End);
  526   assert(isIdentifierBody(*First) && "invalid identifer");
  577   assert(*First == '(');
  801   assert(First != End);
  804   assert(First <= End);
  810     assert(First <= End);
tools/clang/lib/Lex/HeaderMap.cpp
  129   assert(FileBuffer->getBufferSize() >=
  216   assert(llvm::isPowerOf2_32(NumBuckets) && "Expected power of 2");
tools/clang/lib/Lex/HeaderSearch.cpp
   64       assert(External && "We must have an external source if we have a "
  315   assert(isHeaderMap() && "Unknown DirectoryLookup");
  385   assert(isHeaderMap() && "Unknown directory lookup");
  434   assert(llvm::sys::path::extension(DirName) == ".framework" &&
  648   assert(!Str.empty());
  801           assert(First && "only first includer can have no file");
  905       assert(IsInHeaderMap && "MappedName should come from a header map");
 1027   assert(ContextFileEnt && "No context file?");
 1139   assert(OtherHFI.External && "expected to merge external HFI");
 1508       assert(Dir && "parent must exist");
 1527   assert(File && "expected FileEntry");
 1703   assert(HSOpts->ImplicitModuleMaps &&
tools/clang/lib/Lex/Lexer.cpp
   85   assert(BufEnd[0] == 0 &&
  164   assert(PP && "Cannot reset token mode without a preprocessor");
  204   assert(L->BufferEnd[0] == 0 && "Buffer is not nul terminated!");
  272   assert(Tok.needsCleaning() && "getSpellingSlow called on simple token");
  314   assert(Length < Tok.getLength() &&
  367   assert((int)Tok.getLength() >= 0 && "Token character range is bogus!");
  400   assert((int)Tok.getLength() >= 0 && "Token character range is bogus!");
  509   assert(Loc.isFileID());
  568   assert(FileLocInfo.first == BeginFileLocInfo.first &&
  804   assert(loc.isValid() && loc.isMacroID() && "Expected a valid macro loc");
  826   assert(loc.isValid() && loc.isMacroID() && "Expected a valid macro loc");
  853   assert(Begin.isFileID() && End.isFileID());
  903   assert(Begin.isMacroID() && End.isMacroID());
  978   assert(Loc.isMacroID() && "Only reasonable to call this on macros");
 1024   assert(Loc.isMacroID() && "Only reasonable to call this on macros");
 1052   assert(isVerticalWhitespace(Str[0]));
 1105   assert(FileLoc.isMacroID() && "Must be a macro expansion");
 1128   assert(Loc >= BufferStart && Loc <= BufferEnd &&
 1139   assert(PP && "This doesn't work on raw lexers");
 1450   assert(isAllowedIDChar(C, LangOpts));
 1680       assert(*CurPtr == 0 && "Completion character must be 0");
 1815   assert(getLangOpts().CPlusPlus);
 2400   assert(Spelling[0] == '/' && Spelling[1] == '/' && "Not line comment?");
 2415   assert(CurPtr[0] == '\n' || CurPtr[0] == '\r');
 2656   assert(ParsingPreprocessorDirective && ParsingFilename == false &&
 2689       assert(CurPtr[-1] == Char && "Trigraphs for newline?");
 2699       assert(Tmp.is(tok::eod) && "Unexpected token!");
 2786   assert(!LexingRawMode && "How can we expand a macro from a skipping buffer?");
 2871       assert(CurPtr != BufferEnd && "Didn't find end of line");
 2936   assert(CurPtr[-1] == '<' && CurPtr[0] == '#' && "Not a placeholder!");
 3163   assert((returnedToken || !isRawLex) && "Raw lex must succeed");
 3946     assert(Result.is(tok::eof) && "Preprocessor did not set tok:eof");
tools/clang/lib/Lex/LiteralSupport.cpp
  235   assert(Res && "Unexpected conversion failure");
  247     assert(*I == 'u' || *I == 'U');
  255     assert(I + NumHexDigits <= E);
  260       assert(Value != -1U);
  395   assert((CharByteWidth == 1 || CharByteWidth == 2 || CharByteWidth == 4) &&
  399   assert((UcnLen== 4 || UcnLen== 8) && "only ucn length of 4 or 8 supported");
  429   assert(CharByteWidth == 1 && "UTF-8 encoding is only for 1 byte characters");
  534   assert(!isPreprocessingNumberBody(*ThisTokEnd) && "didn't maximally munch?");
  651         assert(s + 1 < ThisTokEnd && "didn't maximally munch?");
  695           assert(s <= ThisTokEnd && "didn't maximally munch?");
  745     assert(isFract || isAccum);
  753   assert((radix == 8 || radix == 10) && "Unexpected radix");
  846   assert(s[0] == '0' && "Invalid method call");
  854     assert(s < ThisTokEnd && "didn't maximally munch?");
  925     assert(s < ThisTokEnd && "didn't maximally munch?");
 1019     assert(C < radix && "NumericLiteralParser ctor should have rejected this");
 1062   assert(radix == 16 || radix == 10);
 1135     assert(C < radix && "NumericLiteralParser ctor should have rejected this");
 1233   assert(begin[0] == '\'' && "Invalid token lexed");
 1248   assert(end != begin && "Invalid token lexed");
 1254   assert(PP.getTargetInfo().getCharWidth() == 8 &&
 1256   assert(PP.getTargetInfo().getIntWidth() <= 64 &&
 1259   assert(PP.getTargetInfo().getWCharWidth() <= 64 &&
 1473   assert(!StringToks.empty() && "expected at least one token");
 1475   assert(StringToks[0].getLength() >= 2 && "literal token is invalid!");
 1489     assert(StringToks[i].getLength() >= 2 && "literal token is invalid!");
 1517   assert((CharByteWidth & 7) == 0 && "Assumes character size is byte multiple");
 1619       assert(ThisTokEnd >= ThisTokBuf && "malformed raw string literal");
 1700           assert(CharByteWidth == 1 && "Unexpected char width");
 1719       assert(CharByteWidth == 1 && "Unexpected char width");
 1833   assert(SpellingPtr[0] != 'L' && SpellingPtr[0] != 'u' &&
 1838     assert(SpellingPtr[1] == '"' && "Should be a raw string literal!");
 1843       assert(SpellingPtr < SpellingEnd && "Missing ( for raw string literal");
 1851   assert(SpellingPtr[0] == '"' && "Should be a string literal!");
 1856     assert(SpellingPtr < SpellingEnd && "Didn't find byte offset!");
 1883     assert(!HadError && "This method isn't valid on erroneous strings");
tools/clang/lib/Lex/MacroArgs.cpp
   27   assert(MI->isFunctionLike() &&
  120   assert(Arg < getNumMacroArguments() && "Invalid arg #");
  128     assert(Result < Start+NumUnexpArgTokens && "Invalid arg #");
  132   assert(Result < Start+NumUnexpArgTokens && "Invalid arg #");
  163   assert(Arg < getNumMacroArguments() && "Invalid argument number!");
tools/clang/lib/Lex/MacroInfo.cpp
   39   assert(!IsDefinitionLengthCached);
   49   assert(macroStart.isValid() && macroEnd.isValid());
   50   assert((macroStart.isFileID() || firstToken.is(tok::comment)) &&
   52   assert((macroEnd.isFileID() || lastToken.is(tok::comment)) &&
   58   assert(startInfo.first == endInfo.first &&
   60   assert(startInfo.second <= endInfo.second);
  204   assert(L.isValid() && "SourceLocation is invalid.");
tools/clang/lib/Lex/ModuleMap.cpp
  113     assert(Unresolved.Wildcard && "Invalid unresolved export");
  329   assert((!this->Target || this->Target == &Target) &&
  410   assert(Dir && "file in no directory");
  458     assert(IsPrivate && "inconsistent headers and roles");
  591   assert(!Headers.count(File) && "already have a module for this header");
  836   assert(LangOpts.CurrentModule == Name && "module name mismatch");
  837   assert(!Modules[Name] && "redefining existing module");
  855   assert(MainFile && "no input file for module interface");
  863   assert(LangOpts.CurrentModule == Name && "module name mismatch");
  864   assert(!Modules[Name] && "redefining existing module");
  888   assert(Mod->IsFramework && "Can only infer linking for framework modules");
  889   assert(!Mod->isSubFramework() &&
 1234     assert(InferredModuleAllowedBy.count(M) && "missing inferred module map");
 1241   assert(M->IsInferred && "module not inferred");
 1802   assert(Tok.is(MMToken::ExplicitKeyword) || Tok.is(MMToken::ModuleKeyword) ||
 1890       assert(ModuleMapFile != Map.getModuleMapFileForUniquing(TopLevelModule) &&
 2107   assert(Tok.is(MMToken::ExternKeyword));
 2192   assert(Tok.is(MMToken::RequiresKeyword));
 2460   assert(Tok.is(MMToken::ExportKeyword));
 2503   assert(Tok.is(MMToken::ExportAsKeyword));
 2540   assert(Tok.is(MMToken::UseKeyword));
 2557   assert(Tok.is(MMToken::LinkKeyword));
 2589   assert(Tok.is(MMToken::ConfigMacros));
 2659   assert(Tok.is(MMToken::Conflict));
 2698   assert(Tok.is(MMToken::Star));
 2968   assert(Target && "Missing target information");
 2981   assert(Target && "Missing target information");
 2985   assert((!Offset || *Offset <= Buffer->getBufferSize()) &&
 3001     assert(Loc.first == ID && "stopped in a different file?");
tools/clang/lib/Lex/PPCaching.cpp
   26   assert(LexLevel == 0 && "cannot use lookahead while lexing");
   33   assert(!BacktrackPositions.empty()
   41   assert(!BacktrackPositions.empty()
   53   assert(LexLevel == 1 &&
   87   assert(LexLevel == 0 &&
   91     assert(CurLexerKind == CLK_CachingLexer && "Unexpected lexer kind");
   99   assert(CurLexerKind != CLK_CachingLexer && "already in caching lex mode");
  106   assert(CachedLexPos + N > CachedTokens.size() && "Confused caching.");
  117   assert(Tok.isAnnotation() && "Expected annotation token");
  118   assert(CachedLexPos != 0 && "Expected to have some cached tokens");
  119   assert(CachedTokens[CachedLexPos-1].getLastLoc() == Tok.getAnnotationEndLoc()
  127       assert((BacktrackPositions.empty() || BacktrackPositions.back() <= i) &&
  158   assert(CachedLexPos != 0 && "Expected to have some cached tokens");
tools/clang/lib/Lex/PPConditionalDirectiveRecord.cpp
   59   assert(low != CondDirectiveLocs.end());
   69   assert(CondDirectiveLocs.empty() ||
  113   assert(!CondDirectiveStack.empty());
tools/clang/lib/Lex/PPDirectives.cpp
   89     assert(Tmp.isNot(tok::eof) && "EOF seen while discarding directive tokens");
  395   assert(CurLexerBufferOffset >= HashFileOffset.second &&
  400   assert(BytesToSkip >= LengthDiff && "lexer is after the skipped range?");
  418   assert(!CurTokenLexer && CurPPLexer && "Lexing a macro, not a file?");
  534         assert(!InCond && "Can't be skipping if not in a conditional!");
  589           assert(CurPPLexer->LexingRawMode && "We have to be skipping here!");
  652   assert(M && "no module to include");
 1191     assert(Literal.isAscii() && "Didn't allow wide strings in");
 1341     assert(Literal.isAscii() && "Didn't allow wide strings in");
 1501   assert(!Buffer.empty() && "Can't have tokens with empty spellings!");
 1822   assert(!File.hasValue() && "expected missing file");
 1827     assert(SlashPos != StringRef::npos &&
 1832     assert(CacheEntry.Directory && "Found framework should be in cache");
 2004     assert((Imported == nullptr || Imported == SuggestedModule.getModule()) &&
 2023         assert(CurLexer && "#include but no current lexer set!");
 2139     assert(M && "no module to import");
 2168   assert(FID.isValid() && "Expected valid file ID");
 2198     assert(!CurLexerSubmodule && "should not have marked this as a module yet");
 2212   assert(!IsImportDecl && "failed to diagnose missing module for import decl");
 2237     assert(CurPPLexer && "#include_next directive in macro?");
 2304     assert(TmpTok.isNot(tok::eof) && "Didn't find end of -imacros!");
 2582               assert(NumTokens >= 3 && "Must have seen at least __VA_OPT__( "
 2672       assert(Tok.is(tok::eod) && "Must be at End Of preprocessing Directive");
 2756       assert(!OtherMI->isWarnIfUnused());
 2788   assert(!MI->isUsed());
 2885       assert(isIfndef && "#ifdef shouldn't reach here");
 2993   assert(!CondInfo.WasSkipping && !CurPPLexer->LexingRawMode &&
tools/clang/lib/Lex/PPExpressions.cpp
  288     assert(Literal.isIntegerLiteral() && "Unknown ppnumber");
  381       assert(Result.Val.getBitWidth() == Val.getBitWidth() &&
  621     assert(PeekPrec <= ThisPrec && "Recursion didn't work!");
tools/clang/lib/Lex/PPLexerChange.cpp
   40   assert(IsFileLexer(IncludeMacroStack[0]) &&
   71   assert(!CurTokenLexer && "Cannot #include a file inside a macro!");
  161       assert(IsReinject && "new tokens in the middle of cached stream");
  268   assert(Mod.getUmbrellaHeader() && "Module must use umbrella header");
  307   assert(!CurTokenLexer &&
  409       assert(CurLexer && "Got EOF but no current lexer set!");
  434       assert(PredefinesFileID.isValid() &&
  490   assert(CurLexer && "Got EOF but no current lexer set!");
  547   assert(CurTokenLexer && !CurPPLexer &&
  568   assert(!IncludeMacroStack.empty() && "Ran out of stack entries to load");
  585   assert(CurTokenLexer && !CurPPLexer &&
  624     assert(FoundLexer && "Can't get end of line without an active lexer");
  641   assert(!FoundLexer && "Lexer should return EOD before EOF in PP mode");
  724     assert(ForPragma && "non-pragma module enter/leave mismatch");
  781       assert(MD && "broken macro directive chain");
tools/clang/lib/Lex/PPMacroExpansion.cpp
   69   assert(MD && "MacroDirective should be non-zero!");
   70   assert(!MD->getPrevious() && "Already attached to a MacroDirective history.");
  105   assert(II && MD);
  114     assert(OldMD->getMacroInfo()->isBuiltinMacro() &&
  116     assert(!OldMD->getPrevious() && "builtin should only have a single entry");
  181   assert(Info.ActiveModuleMacrosGeneration !=
  203     assert(LeafMM->getNumOverridingMacros() == 0 && "leaf macro overridden");
  766   assert(Tok.is(tok::l_paren) && "Error computing l-paren-ness?");
  782     assert(Tok.isOneOf(tok::l_paren, tok::comma) &&
 1025   assert(tokLexer);
 1050   assert(!MacroExpandingLexersStack.empty());
 1052   assert(tokIndex < MacroExpandedTokens.size());
 1153     assert(Tok.is(tok::identifier));
 1257     assert(PP.getCurrentLexer() && "#include_next directive in macro?");
 1445   assert(II && "Can't be a macro without id info!");
tools/clang/lib/Lex/Pragma.cpp
   89   assert(!Handlers.lookup(Handler->getName()) &&
   95   assert(Handlers.lookup(Handler->getName()) &&
  141     assert(Collect && "did not collect tokens");
  142     assert(!Tokens.empty() && "collected unexpected number of tokens");
  273     assert(StrVal[1] == '"' && StrVal[StrVal.size() - 1] == '"' &&
  279       assert(NumDChars < (StrVal.size() - 5) / 2 &&
  283     assert(StrVal[StrVal.size() - 2 - NumDChars] == ')');
  290     assert(StrVal[0] == '"' && StrVal[StrVal.size()-1] == '"' &&
  410   assert(CurPPLexer && "No current lexer?");
  582   assert(StrVal[0] == '"' && StrVal[StrVal.size()-1] == '"' &&
  839       assert(Tok.getKind() != tok::eof && "missing EOD before EOF");
  846   assert(CurLexer->getBuffer().begin() <= Start &&
  876     assert(CurLexer && "no lexer for #pragma hdrstop processing");
  900       assert(InsertNS != nullptr && "Cannot have a pragma namespace and pragma"
  911   assert(!InsertNS->FindHandler(Handler->getName()) &&
  927     assert(Existing && "Namespace containing handler does not exist!");
  930     assert(NS && "Invalid namespace, registered as a regular pragma handler!");
tools/clang/lib/Lex/PreprocessingRecord.cpp
   79   assert(FID.isValid());
  104       assert(0 && "Out-of bounds loaded preprocessed entity");
  107     assert(ExternalSource && "No external source to load from");
  127     assert(0 && "Out-of bounds local preprocessed entity");
  138   assert(Range.isValid());
  139   assert(!SourceMgr.isBeforeInTranslationUnit(Range.getEnd(),Range.getBegin()));
  171   assert(!SourceMgr.isBeforeInTranslationUnit(Range.getEnd(),Range.getBegin()));
  253   assert(Entity);
  257     assert((PreprocessedEntities.empty() ||
  315   assert(!ExternalSource &&
  353     assert(Index < LoadedPreprocessedEntities.size() &&
  361   assert(Index < PreprocessedEntities.size() &&
  369   assert(Index < LoadedPreprocessedEntities.size() &&
  371   assert(ExternalSource && "No external source to load from");
  433   assert(Range.isValid());
tools/clang/lib/Lex/Preprocessor.cpp
  169   assert(BacktrackPositions.empty() && "EnableBacktrack/Backtrack imbalance!");
  196   assert((!this->Target || this->Target == &Target) &&
  200   assert((!this->AuxTarget || this->AuxTarget == AuxTarget) &&
  389   assert(File);
  390   assert(CompleteLine && CompleteColumn && "Starts from 1:1");
  391   assert(!CodeCompletionFile && "Already set");
  535   assert(NumEnteredSourceFiles == 0 && "Cannot reenter the main file!");
  559   assert(SB && "Cannot create predefined source buffer");
  561   assert(FID.isValid() && "Could not create FileID for predefines?");
  593   assert(PCHThroughHeaderFileID.isInvalid() &&
  599   assert(PCHThroughHeaderFileID.isValid() &&
  670     assert(CurPPLexer &&
  698   assert(!Identifier.getRawIdentifier().empty() && "No raw identifier data!");
  735   assert(Ident__exception_code && Ident__exception_info);
  736   assert(Ident___exception_code && Ident___exception_info);
  749   assert(Identifier.getIdentifierInfo() &&
  763   assert(II.isFutureCompatKeyword() && "diagnostic should not be needed");
  779   assert(II.isOutOfDate() && "not out of date");
  792   assert(Identifier.getIdentifierInfo() &&
  825     assert(MI && "macro definition with no macro info?");
 1328   assert(Literal.isAscii() && "Didn't allow wide strings in");
 1344   assert(Tok.is(tok::numeric_constant));
 1362   assert(Handler && "NULL comment handler");
 1363   assert(llvm::find(CommentHandlers, Handler) == CommentHandlers.end() &&
 1371   assert(Pos != CommentHandlers.end() && "Comment handler not registered");
tools/clang/lib/Lex/PreprocessorLexer.cpp
   33   assert(ParsingFilename == false && "reentered LexIncludeFilename");
tools/clang/lib/Lex/TokenConcatenation.cpp
  195     assert(Tok.isOneOf(tok::annot_module_include, tok::annot_module_begin,
tools/clang/lib/Lex/TokenLexer.cpp
   64     assert(Tokens[0].getLocation().isValid());
   65     assert((Tokens[0].getLocation().isFileID() || Tokens[0].is(tok::comment)) &&
   67     assert(ExpandLocStart.isValid());
   97   assert(!isReinject || disableMacroExpansion);
  203       assert(CurTokenIdx != 0 &&
  267       assert(Tokens[I + 1].is(tok::l_paren) &&
  343             assert(VCtx.getNumberOfTokensPriorToVAOpt() > 0 &&
  371       assert((ArgNo != -1 || VCtx.isVAOptToken(Tokens[I + 1])) &&
  411     assert((!NonEmptyPasteBefore || PasteBefore || VCtx.isInVAOpt()) &&
  501           assert(VCtx.isInVAOpt() && "should only happen inside a __VA_OPT__");
  576     assert(PasteBefore);
  578       assert(ResultToks.back().is(tok::hashhash));
  602     assert(!OwnsTokens && "This would leak if we already own the token list");
  735   assert(CurIdx > 0 && "## can not be the first token within tokens");
  736   assert((TokenStream[CurIdx].is(tok::hashhash) ||
  763     assert(!IsAtEnd() && "No token on the RHS of a paste operator!");
  819       assert(ResultTokLoc.isFileID() &&
  954   assert(Macro && "Token streams can't paste comments");
  966   assert(ExpandLocStart.isValid() && MacroExpansionStart.isValid() &&
  968   assert(loc.isValid() && loc.isFileID());
  971   assert(SM.isInSLocAddrSpace(loc, MacroDefStart, MacroDefLength) &&
  992   assert(begin_tokens < end_tokens);
tools/clang/lib/Parse/ParseCXXInlineMethods.cpp
   28   assert(D.isFunctionDeclarator() && "This isn't a function declarator!");
   29   assert(Tok.isOneOf(tok::l_brace, tok::colon, tok::kw_try, tok::equal) &&
  186   assert(Tok.isOneOf(tok::l_brace, tok::equal) &&
  332       assert(Tok.is(tok::equal) && "Default argument not starting with '='");
  355           assert(Toks->size() >= 3 && "expected a token in default arg");
  372       assert(Param->hasInheritedDefaultArg());
  375       assert (!OldParam->hasUnparsedDefaultArg());
  495   assert(!LM.Toks.empty() && "Empty body!");
  510   assert(Tok.isOneOf(tok::l_brace, tok::colon, tok::kw_try)
  547   assert((Actions.getDiagnostics().hasErrorOccurred() ||
  871       assert(kind == tok::l_brace && "Must be left paren or brace here.");
  949   assert(Tok.is(tok::question));
tools/clang/lib/Parse/ParseDecl.cpp
  150   assert(Tok.is(tok::kw___attribute) && "Not a GNU attribute list!");
  293   assert(Tok.is(tok::identifier) && "expected an identifier");
  438   assert(Tok.is(tok::l_paren) && "Attribute arg list not starting with '('");
  488   assert(Tok.is(tok::l_paren) && "Attribute arg list not starting with '('");
  667   assert(getLangOpts().DeclSpecKeyword && "__declspec keyword is not enabled");
  668   assert(Tok.is(tok::kw___declspec) && "Not a declspec!");
 1303       assert(Keyword == Ident_defined_in && "Invalid clause keyword!");
 1460   assert(LAs.parseSoon() &&
 1567   assert(Tok.is(tok::l_paren) && "Attribute arg list not starting with '('");
 1631   assert(Tok.is(tok::l_square) && NextToken().is(tok::l_square));
 1647     assert(Tok.is(tok::r_square) && "isCXX11AttributeSpecifier lied");
 1662   assert((Tok.is(tok::l_square) && NextToken().is(tok::l_square)) ||
 2436       assert(!Exprs.empty() && Exprs.size()-1 == CommaLocs.size() &&
 2562   assert(Tok.is(tok::identifier) && "should have identifier");
 2577   assert(!DS.hasTypeSpecifier() && "Type specifier checked above");
 2846   assert(Tok.isOneOf(tok::kw_alignas, tok::kw__Alignas) &&
 2884   assert(DS.hasTagDefinition() && "shouldn't call this");
 2988   assert(!LangOpts.FixedPoint);
 3181         assert(Tok.is(tok::annot_template_id) &&
 3321             assert(false && "Not a left paren?");
 3352         assert(TypeRep);
 3996       assert(PrevSpec && "Method did not return previous specifier!");
 3997       assert(DiagID);
 4067     assert(!AnonRecord && "Did not expect anonymous struct or union here");
 4129   assert(!getLangOpts().CPlusPlus && "C++ declarations not supported");
 4520     assert(TemplateInfo.TemplateParams && "no template parameters");
 4559     assert(TUK == Sema::TUK_Definition && "can only skip a definition");
 4752   assert(EnumConstantDecls.size() == EnumAvailabilityDiags.size());
 5439       assert(PrevSpec && "Method did not return previous specifier!");
 5867     assert(!getLangOpts().CPlusPlus &&
 5869     assert(Tok.getIdentifierInfo() && "Not an identifier?");
 5994   assert(D.isPastIdentifier() &&
 6037   assert(Tok.is(tok::l_square));
 6117   assert(!D.isPastIdentifier() && "Should be called before passing identifier");
 6234   assert(getCurScope()->isFunctionPrototypeScope() &&
 6237   assert(D.isPastIdentifier() && "Should not call before identifier!");
 6852   assert(Tok.is(tok::l_square) && "Missing opening bracket");
 6853   assert(!D.mayOmitIdentifier() && "Declarator cannot omit identifier");
 6944   assert(Tok.is(tok::kw_typeof) && "Not a typeof specifier");
 7010   assert(Tok.is(tok::kw__Atomic) && NextToken().is(tok::l_paren) &&
tools/clang/lib/Parse/ParseDeclCXX.cpp
   61   assert(Tok.is(tok::kw_namespace) && "Not a namespace!");
  265   assert(!ImplicitUsingDirectiveDecl &&
  281   assert(Tok.is(tok::equal) && "Not equal token");
  334   assert(isTokenStringLiteral() && "Not a string literal!");
  417   assert(Tok.is(tok::kw_export));
  465   assert(Tok.is(tok::kw_using) && "Not using token");
  520   assert(Tok.is(tok::kw_namespace) && "Not 'namespace' token");
  864   assert(Tok.isOneOf(tok::kw_static_assert, tok::kw__Static_assert) &&
  934   assert(Tok.isOneOf(tok::kw_decltype, tok::annot_decltype)
  995             assert(Tok.is(tok::semi));
 1022   assert(!Result.isInvalid());
 1059   assert(Tok.is(tok::kw___underlying_type) &&
 1147       assert(Tok.is(tok::annot_typename) && "template-id -> type failed");
 1405     assert(TagTokKind == tok::kw_union && "Not a class specifier");
 1517       assert(Tok.is(tok::kw__Atomic));
 1852         assert((TUK == Sema::TUK_Definition || TUK == Sema::TUK_Friend) &&
 1944       assert(TUK == Sema::TUK_Reference || TUK == Sema::TUK_Friend);
 1952     assert(Tok.is(tok::l_brace) ||
 2035   assert(Tok.is(tok::colon) && "Not a base clause");
 2312     assert(DeclaratorInfo.isPastIdentifier() &&
 2543     assert(!TemplateInfo.TemplateParams &&
 2958   assert(Tok.isOneOf(tok::equal, tok::l_brace)
 3001     assert(isCXX11FinalKeyword() && "not a class definition");
 3040   assert(Tok.is(tok::l_brace));
 3104     assert(NewAS != AS_none);
 3164   assert((TagType == DeclSpec::TST_struct ||
 3221     assert((Specifier == VirtSpecifiers::VS_Final ||
 3306   assert(Tok.is(tok::l_brace));
 3382   assert(Tok.is(tok::kw_namespace));
 3424   assert(Tok.is(tok::colon) &&
 3518       assert(Tok.is(tok::annot_typename) && "template-id -> type failed");
 3647     assert(DynamicExceptions.size() == DynamicExceptionRanges.size() &&
 3729   assert(Tok.is(tok::kw_throw) && "expected throw");
 3786   assert(Tok.is(tok::arrow) && "expected arrow");
 3801   assert((NonNestedClass || !ClassStack.empty()) &&
 3822   assert(!ClassStack.empty() && "Mismatched push/pop for class parsing");
 3834   assert(!ClassStack.empty() && "Missing top-level class?");
 3848   assert(getCurScope()->isClassScope() && "Nested class outside of class scope?");
 3960   assert(Tok.is(tok::l_paren) && "Not a C++11 attribute argument list");
 4051   assert(Tok.is(tok::l_square) && NextToken().is(tok::l_square) &&
 4153   assert(standardAttributesAllowed());
 4191       assert(Tok.is(tok::kw_alignas) && "not an attribute specifier");
 4205   assert(Tok.is(tok::identifier) && "Not a Microsoft attribute list");
 4207   assert(UuidIdent->getName() == "uuid" && "Not a Microsoft attribute list");
 4298   assert(Tok.is(tok::l_square) && "Not a Microsoft attribute list");
tools/clang/lib/Parse/ParseExpr.cpp
  201   assert(Actions.ExprEvalContexts.back().Context ==
  376           assert(FILoc.isFileID());
  853     assert(!Res.isUnset() &&
  863     assert(Tok.isNot(tok::kw_decltype) && Tok.isNot(tok::kw___super));
 1149       assert(Res.isInvalid());
 1728         assert((ArgExprs.size() == 0 ||
 1895   assert(OpTok.isOneOf(tok::kw_typeof, tok::kw_sizeof, tok::kw___alignof,
 1981   assert(Tok.isOneOf(tok::kw_sizeof, tok::kw___alignof, tok::kw_alignof,
 2378   assert(Tok.is(tok::l_paren) && "Not a paren expr!");
 2431         assert(CodeDC && !CodeDC->isFileContext() &&
 2463       assert(tokenKind == tok::kw___bridge_retain);
 2694   assert(Tok.is(tok::l_brace) && "Not a compound literal!");
 2712   assert(isTokenStringLiteral() && "Not a string literal!");
 2743   assert(Tok.is(tok::kw__Generic) && "_Generic keyword expected");
 2843     assert(isFoldOperator(Kind) && "missing fold-operator");
 2847   assert(Tok.is(tok::ellipsis) && "not a fold-expression");
 3009   assert(Tok.is(tok::caret) && "block literal starts with ^");
 3198   assert(Tok.is(tok::kw___builtin_available) ||
tools/clang/lib/Parse/ParseExprCXX.cpp
  150   assert(getLangOpts().CPlusPlus &&
  154     assert(!LastII && "want last identifier but have already annotated scope");
  155     assert(!MayBePseudoDestructor && "unexpected annot_cxxscope");
  351       assert(Tok.is(tok::coloncolon) && "NextToken() not working properly!");
  449       assert(Tok.isOneOf(tok::coloncolon, tok::colon) &&
  584     assert(SS.isEmpty() &&
  679   assert(!Result.isUnset() && "Typo correction suggested a keyword replacement "
  743   assert(getLangOpts().CPlusPlus11
  821   assert(Tok.is(tok::l_square) && "Lambda expressions begin with '['.");
 1089           assert(DiagLoc.isValid() && "no location for diagnostic");
 1145   assert(MutableLoc.isInvalid());
 1146   assert(ConstexprLoc.isInvalid());
 1197     assert(PrevSpec == nullptr && DiagID == 0 &&
 1554   assert(Tok.is(tok::kw_typeid) && "Not 'typeid'!");
 1621   assert(Tok.is(tok::kw___uuidof) && "Not '__uuidof'!");
 1696     assert(Tok.is(tok::coloncolon) &&"ParseOptionalCXXScopeSpecifier fail");
 1704     assert(Tok.is(tok::coloncolon) &&"ParseOptionalCXXScopeSpecifier fail");
 1711   assert(Tok.is(tok::tilde) && "ParseOptionalCXXScopeSpecifier fail");
 1763   assert(Tok.is(tok::kw_throw) && "Not throw!");
 1790   assert(Tok.is(tok::kw_co_yield) && "Not co_yield!");
 1806   assert(Tok.is(tok::kw_this) && "Not 'this'!");
 1829   assert((Tok.is(tok::l_paren) ||
 1877     assert((Exprs.size() == 0 || Exprs.size()-1 == CommaLocs.size())&&
 1979     assert(FRI && "should not parse a for range declaration here");
 2252   assert(Tok.is(tok::less) && "Expected '<' to finish parsing a template-id");
 2443   assert(Tok.is(tok::kw_operator) && "Expected 'operator' keyword");
 2942   assert(Tok.is(tok::kw_new) && "expected 'new' token");
 3150   assert(Tok.is(tok::kw_delete) && "Expected 'delete' keyword");
 3407   assert(getLangOpts().CPlusPlus && "Should only be called for C++!");
 3408   assert(ExprType == CastExpr && "Compound literals are not ambiguous!");
 3409   assert(isTypeIdInParens() && "Not a type-id!");
 3500     assert(Tok.is(tok::eof) && Tok.getEofData() == AttrEnd.getEofData());
 3515     assert(ParseAs == CastExpr);
 3529   assert(ParseAs == SimpleExpr);
 3541     assert(Tok.getEofData() == AttrEnd.getEofData());
 3548   assert(Tok.is(tok::eof) && Tok.getEofData() == AttrEnd.getEofData());
tools/clang/lib/Parse/ParseInit.cpp
  172     assert(Tok.is(tok::colon) && "MayBeDesignationStart not working properly!");
  208     assert(Tok.is(tok::l_square) && "Unexpected token!");
  376   assert(!Desig.empty() && "Designator is empty?");
tools/clang/lib/Parse/ParseObjc.cpp
  111     assert(!Params);
  214   assert(Tok.isObjCAtKeyword(tok::objc_interface) &&
  276     assert(LAngleLoc.isInvalid() && "Cannot have already parsed protocols");
  424   assert(Tok.is(tok::less) && "Not at the beginning of a type parameter list");
  842   assert(Tok.getKind() == tok::l_paren);
  984   assert(Tok.isOneOf(tok::minus, tok::plus) && "expected +/-");
 1140   assert(Context == DeclaratorContext::ObjCParameterContext ||
 1236   assert(context == DeclaratorContext::ObjCParameterContext ||
 1238   assert((paramAttrs != nullptr) ==
 1241   assert(Tok.is(tok::l_paren) && "expected (");
 1523   assert(Tok.is(tok::less) && "expected <");
 1561   assert(Tok.is(tok::less) && "Protocol qualifiers start with '<'");
 1562   assert(getLangOpts().ObjC && "Protocol qualifiers only exist in Objective-C");
 1599   assert(Tok.is(tok::less) && "Not at the start of type args or protocols");
 1777   assert(Tok.is(tok::less));
 1825   assert(Tok.is(tok::less));
 1903   assert(Tok.is(tok::l_brace) && "expected {");
 2016   assert(Tok.isObjCAtKeyword(tok::objc_protocol) &&
 2098   assert(Tok.isObjCAtKeyword(tok::objc_implementation) &&
 2205   assert(ObjCImpDecl);
 2226   assert(Tok.isObjCAtKeyword(tok::objc_end) &&
 2248   assert(LateParsedObjCMethods.empty());
 2252   assert(!Finished);
 2279   assert(Tok.isObjCAtKeyword(tok::objc_compatibility_alias) &&
 2307   assert(Tok.isObjCAtKeyword(tok::objc_synthesize) &&
 2361   assert(Tok.isObjCAtKeyword(tok::objc_dynamic) &&
 2573       assert(Tok.isObjCAtKeyword(tok::objc_finally) && "Lookahead confused?");
 2718   assert (CurParsedObjCImpl
 2967   assert(Tok.is(tok::l_square) && getLangOpts().ObjC &&
 3011   assert(Tok.is(tok::l_square) && "'[' expected");
 3516   assert(Tok.isObjCAtKeyword(tok::objc_encode) && "Not an @encode expression!");
 3641   assert(!LM.Toks.empty() && "ParseLexedObjCMethodDef - Empty body!");
 3658   assert(Tok.isOneOf(tok::l_brace, tok::kw_try, tok::colon) &&
tools/clang/lib/Parse/ParseOpenMP.cpp
  459       assert(!Exprs.empty() && Exprs.size() - 1 == CommaLocs.size() &&
  806   assert(ScoreKind == OMPDeclareVariantAttr::ScoreSpecified &&
 1250   assert(Tok.is(tok::annot_pragma_openmp) && "Not an OpenMP directive!");
 1410         assert(TagType == DeclSpec::TST_unspecified);
 1426     assert(DKind == OMPD_declare_variant &&
 1450         assert(TagType == DeclSpec::TST_unspecified);
 1582   assert(Tok.is(tok::annot_pragma_openmp) && "Not an OpenMP directive!");
 2356     assert(Kind == OMPC_if);
tools/clang/lib/Parse/ParsePragma.cpp
  498   assert(Tok.is(tok::annot_pragma_unused));
  505   assert(Tok.is(tok::annot_pragma_vis));
  521   assert(Tok.is(tok::annot_pragma_pack));
  541   assert(Tok.is(tok::annot_pragma_msstruct));
  549   assert(Tok.is(tok::annot_pragma_align));
  560   assert(Tok.is(tok::annot_pragma_dump));
  568   assert(Tok.is(tok::annot_pragma_weak));
  576   assert(Tok.is(tok::annot_pragma_weakalias));
  590   assert(Tok.is(tok::annot_pragma_redefine_extname));
  603   assert(Tok.is(tok::annot_pragma_fp_contract));
  626   assert(Tok.is(tok::annot_pragma_fenv_access));
  651   assert(Tok.is(tok::annot_pragma_captured));
  685   assert(Tok.is(tok::annot_pragma_opencl_extension));
  724   assert(Tok.is(tok::annot_pragma_ms_pointers_to_members));
  733   assert(Tok.is(tok::annot_pragma_ms_vtordisp));
  743   assert(Tok.is(tok::annot_pragma_ms_pragma));
  750   assert(Tok.isAnyIdentifier());
 1019   assert(Tok.is(tok::annot_pragma_loop_hint));
 1052   assert(!Toks.empty() &&
 1400   assert(Tok.is(tok::annot_pragma_attribute) &&
 1410   assert((Info->Action == PragmaAttributeInfo::Push ||
 1981   assert(RParenLoc.isValid() && "Valid '#pragma unused' must have ')'");
 1982   assert(!Identifiers.empty() && "Valid '#pragma unused' must have arguments");
 2752   assert(Tok.is(tok::annot_pragma_fp));
tools/clang/lib/Parse/ParseStmt.cpp
  109   assert((Attrs.empty() || Res.isInvalid() || Res.isUsable()) &&
  470   assert(Tok.is(tok::kw___try) && "Expected '__try'");
  598   assert(Tok.is(tok::identifier) && Tok.getIdentifierInfo() &&
  608   assert(Tok.is(tok::colon) && "Not a label!");
  668   assert((MissingCase || Tok.is(tok::kw_case)) && "Not a case stmt!");
  816   assert(Tok.is(tok::kw_default) && "Not a default stmt!");
  889   assert(Tok.is(tok::l_brace) && "Not a compount stmt!");
 1203   assert(Tok.is(tok::kw_if) && "Not an if stmt!");
 1351   assert(Tok.is(tok::kw_switch) && "Not a switch stmt!");
 1436   assert(Tok.is(tok::kw_while) && "Not a while stmt!");
 1505   assert(Tok.is(tok::kw_do) && "Not a do stmt!");
 1573   assert(Tok.is(tok::identifier));
 1614   assert(Tok.is(tok::kw_for) && "Not a for stmt!");
 1953   assert(Tok.is(tok::kw_goto) && "Not a goto stmt!");
 2009   assert((Tok.is(tok::kw_return) || Tok.is(tok::kw_co_return)) &&
 2077   assert(Tok.is(tok::l_brace));
 2110   assert(Tok.is(tok::kw_try) && "Expected 'try'");
 2142   assert(SkipFunctionBodies &&
 2187   assert(Tok.is(tok::kw_try) && "Expected 'try'");
 2277   assert(Tok.is(tok::kw_catch) && "Expected 'catch'");
tools/clang/lib/Parse/ParseStmtAsm.cpp
   53     assert(AsmToks.size() == AsmTokOffsets.size());
  105     assert(FirstOrigToken && "not using original tokens?");
  108     assert(FirstOrigToken[NumConsumedToks].getLocation() ==
  142   assert(!std::less<const char *>()(Str.begin(), AsmString.begin()) &&
  152   assert(*FirstTokOffset == FirstCharOffset);
  267       assert(LineIndex < LineToks.size() - 2); // we added two extra tokens
  285   assert(Tok.is(EndOfStream));
  301   assert(!AsmToks.empty() && "Didn't expect an empty AsmToks!");
  338     assert(!SpellingInvalid && "spelling was invalid after correct parse?");
  348   assert(TokOffsets.size() == AsmToks.size());
  564   assert(!LBraceLocs.empty() && "Should have at least one location here");
  690   assert(Tok.is(tok::kw_asm) && "Not an asm stmt");
  793   assert(Names.size() == Constraints.size() &&
tools/clang/lib/Parse/ParseTemplate.cpp
   66   assert(Tok.isOneOf(tok::kw_export, tok::kw_template) &&
  180   assert(TemplateInfo.Kind != ParsedTemplateInfo::NonTemplate &&
  226     assert(!AnonRecord &&
  342   assert(TemplateInfo.Kind != ParsedTemplateInfo::NonTemplate &&
  344   assert(Tok.is(tok::kw_concept) &&
  616   assert(Tok.isOneOf(tok::kw_class, tok::kw_typename) &&
  679   assert(Tok.is(tok::kw_template) && "Expected 'template' keyword");
  844   assert(EllipsisLoc.isValid());
 1040   assert(Tok.is(tok::less) && "Must have already parsed the template-name");
 1110   assert(getLangOpts().CPlusPlus && "Can only annotate template-ids in C++");
 1111   assert(Template && Tok.is(tok::less) &&
 1205   assert(Tok.is(tok::annot_template_id) && "Requires template-id tokens");
 1208   assert((TemplateId->Kind == TNK_Type_template ||
 1494   assert(!LPT.Toks.empty() && "Empty body!");
 1503   assert(Tok.isOneOf(tok::l_brace, tok::colon, tok::kw_try) &&
 1526       assert((!isa<FunctionTemplateDecl>(LPT.D) ||
 1588   assert(Tok.is(tok::less) && "not at a potential angle bracket");
tools/clang/lib/Parse/ParseTentative.cpp
  148   assert(TPR == TPResult::True || TPR == TPResult::False);
  254     assert(TPR == TPResult::False);
  415       assert(resolved() && "can't continue after tentative parsing bails out");
  431     assert(CanBeExpression + CanBeCondition + CanBeInitStatement +
  478   assert(Tok.is(tok::l_paren) && "Expected '('");
  570   assert(Tok.is(tok::l_paren) && "Expected '('");
  606   assert(TPR == TPResult::True || TPR == TPResult::False);
  825   assert(Tok.is(tok::kw_operator));
 1358       assert(Tok.isNot(tok::identifier) &&
 1522     assert(Tok.is(tok::annot_typename));
 1600           assert(Tok.isNot(tok::annot_cxxscope) ||
 1789   assert(Tok.is(tok::kw_typeof) && "Expected 'typeof'!");
 1792   assert(Tok.is(tok::l_paren) && "Expected '('");
 1804   assert(Tok.is(tok::less) && "Expected '<' for qualifier list");
tools/clang/lib/Parse/Parser.cpp
  378   assert(getCurScope() && "Scope imbalance!");
  440   assert(TemplateIds.empty() && "Still alive TemplateIdAnnotations around?");
  447   assert(getCurScope() == nullptr && "A scope is already active?");
  961   assert(Declarator.isFunctionDeclarator() && "Isn't a function declarator");
 1014       assert(DeclSpec::isDeclRep(TKind));
 1262     assert(getLangOpts().CPlusPlus && "Only C++ function definitions have '='");
 1496   assert(Tok.is(tok::kw_asm) && "Not an asm!");
 1535   assert(tok.is(tok::annot_template_id) && "Expected template-id token");
 1568   assert(Tok.is(tok::identifier) || Tok.is(tok::annot_cxxscope));
 1732   assert(Tok.isNot(tok::identifier));
 1765   assert((Tok.is(tok::identifier) || Tok.is(tok::coloncolon) ||
 1994   assert(getLangOpts().CPlusPlus &&
 1996   assert((Tok.is(tok::identifier) || Tok.is(tok::coloncolon) ||
 2040   assert(Tok.is(tok::code_completion));
 2097   assert((Tok.is(tok::kw___if_exists) || Tok.is(tok::kw___if_not_exists)) &&
 2212   assert(
 2299   assert((AtLoc.isInvalid() ? Tok.isOneOf(tok::kw_import, tok::identifier)
 2473   assert(!P.Tok.is(Close) && "Should have consumed closing delimiter");
tools/clang/lib/Rewrite/DeltaTree.cpp
   96       assert(i < NumValuesUsed && "Invalid value #");
  101       assert(i < NumValuesUsed && "Invalid value #");
  146       assert(i < getNumValuesUsed()+1 && "Invalid child");
  151       assert(i < getNumValuesUsed()+1 && "Invalid child");
  220     assert(InsertRes && "No result location specified");
  299   assert(isFull() && "Why split a non-full node?");
  396   assert(getRoot(RHS.Root)->getNumValuesUsed() == 0 &&
  456   assert(Delta && "Adding a noop?");
tools/clang/lib/Rewrite/HTMLRewrite.cpp
   38   assert(SM.getFileID(E) == FID && "B/E not in the same file!");
  114   assert (C <= FileEnd);
  235   assert (C <= FileEnd);
  246     assert (FilePos <= LineEndPos);
  247     assert (C < FileEnd);
  618     assert(SM.getFileID(LLoc.getEnd()) == FID &&
tools/clang/lib/Rewrite/RewriteRope.cpp
  169       assert(i < getNumPieces() && "Invalid piece ID");
  176       assert(!PrevLeaf && !NextLeaf && "Already in ordering");
  290       assert(SlotOffs == Offset && "Split didn't occur before insertion!");
  344   assert(PieceOffs == Offset && "Split didn't occur before erase!");
  380   assert(getPiece(StartPiece).size() > NumBytes);
  423       assert(i < NumChildren && "invalid child #");
  428       assert(i < NumChildren && "invalid child #");
  634   assert(Offset <= size() && "Invalid offset to split!");
  648   assert(Offset <= size() && "Invalid offset to insert!");
  657   assert(Offset+NumBytes <= size() && "Invalid offset to erase!");
  726   assert(RHS.empty() && "Can't copy non-empty tree yet");
  776   assert(Len && "Zero length RopePiece is invalid!");
tools/clang/lib/Rewrite/Rewriter.cpp
   67   assert(RealOffset+Size <= Buffer.size() && "Invalid location");
  233   assert(Loc.isValid() && "Invalid location");
tools/clang/lib/Rewrite/TokenRewriter.cpp
   65   assert(MapIt != TokenAtLoc.end() && "iterator not in rewriter?");
   77   assert(InsertSuccess && "Token location already in rewriter!");
tools/clang/lib/Sema/AnalysisBasedWarnings.cpp
  842     assert(Use.getKind() == UninitUse::Sometimes);
 1044       assert(Found);
 1055       assert(ReachableBlocks.empty() && "ReachableBlocks already filled");
 1084       assert(!ReachableBlocks.empty() && "ReachableBlocks empty");
 1320   assert(S);
 1395         assert(Base && "A profile always has a base or property.");
 1762     assert((POK == POK_VarAccess || POK == POK_VarDereference) &&
 2049   assert(Body);
tools/clang/lib/Sema/CodeCompleteConsumer.cpp
  286   assert(NumChunks <= 0xffff);
  287   assert(NumAnnotations <= 0xffff);
tools/clang/lib/Sema/DeclSpec.cpp
   31   assert(TemplateId && "NULL template-id annotation?");
   39   assert(TemplateId && "NULL template-id annotation?");
   53   assert(Range == Builder.getSourceRange() &&
   66   assert(Range == Builder.getSourceRange() &&
   79   assert(Range == Builder.getSourceRange() &&
   92   assert(Range == Builder.getSourceRange() &&
  102   assert(Range == Builder.getSourceRange() &&
  114   assert(Range == Builder.getSourceRange() &&
  176   assert(!(MethodQualifiers && MethodQualifiers->getTypeQualifiers() & DeclSpec::TQ_atomic) &&
  219   assert(I.Fun.ExceptionSpecType == ESpecType && "bitfield overflow");
  268     assert(ESpecType == EST_None && NumExceptions == 0 &&
  284   assert(!hasName() && "declarator given multiple names!");
  397   assert(getContext() == DeclaratorContext::MemberContext);
  632         assert(!isInvalid && "auto SCS -> TST recovery failed");
  647   assert((unsigned)SC == StorageClassSpec && "SCS constants overflow bitfield");
  716   assert(isTypeRep(T) && "T does not store a type");
  717   assert(Rep && "no type provided!");
  738   assert(isExprRep(T) && "T does not store an expr");
  739   assert(Rep && "no expression provided!");
  769   assert(isDeclRep(T) && "T does not store a decl");
  791   assert(!isDeclRep(T) && !isTypeRep(T) && !isExprRep(T) &&
  974   assert((ExplicitSpec.getKind() == ExplicitSpecKind::ResolvedTrue ||
 1353   assert(!TypeSpecOwned || isDeclRep((TST) TypeSpecType));
tools/clang/lib/Sema/DelayedDiagnostic.cpp
   32   assert(!Locs.empty());
tools/clang/lib/Sema/IdentifierResolver.cpp
  123       assert(S->getParent() && "No TUScope?");
  210   assert(D && "null param passed");
  217   assert(Ptr && "Didn't find this decl on its identifier's chain!");
  220     assert(D == Ptr && "Didn't find this decl on its identifier's chain!");
  418   assert(!isDeclPtr(InfoPtr) && "Decl with wrong id ?");
tools/clang/lib/Sema/JumpDiagnostics.cpp
  119       assert(Scopes[B].ParentScope < B);
  122       assert(Scopes[A].ParentScope < A);
  632       if (CHECK_PERMISSIVE(!LabelAndGotoScopes.count(SC)))
  674     assert(!IsAsmGoto &&"only indirect goto can get here");
  690       if (CHECK_PERMISSIVE(!LabelAndGotoScopes.count(IG)))
  711     if (CHECK_PERMISSIVE(!LabelAndGotoScopes.count(TheLabel->getStmt())))
  820   if (CHECK_PERMISSIVE(ToScopes.empty()))
  831   if (CHECK_PERMISSIVE(JumpScope == TargetScope))
  872   if (CHECK_PERMISSIVE(!LabelAndGotoScopes.count(From)))
  874   if (CHECK_PERMISSIVE(!LabelAndGotoScopes.count(To)))
tools/clang/lib/Sema/ParsedAttr.cpp
   58   assert(size >= sizeof(ParsedAttr));
   59   assert((size % sizeof(void*)) == 0);
tools/clang/lib/Sema/Scope.cpp
  108   assert((FlagsToSet & ~(BreakScope | ContinueScope)) == 0 &&
  111     assert((Flags & BreakScope) == 0 && "Already set");
  115     assert((Flags & ContinueScope) == 0 && "Already set");
  182   assert(Flags == 0 && "Unknown scope flags");
tools/clang/lib/Sema/ScopeInfo.cpp
  126     assert(PropE->isSuperReceiver());
  141   assert(isa<VarDecl>(Property));
  151   assert(Msg && Prop);
tools/clang/lib/Sema/Sema.cpp
  437   assert(E && "Cannot use with NULL ptr");
  522   assert((VK == VK_RValue || Kind == CK_Dependent || !E->isRValue()) &&
  744       assert(FD->getMostRecentDecl()->isInlined() &&
  749       assert(cast<VarDecl>(VD)->getMostRecentDecl()->isInline() &&
  933   assert(LateParsedInstantiations.empty() &&
  951   assert(DelayedDiagnostics.getCurrentPool() == nullptr
  991   assert(DelayedOverridingExceptionSpecChecks.empty());
  992   assert(DelayedEquivalentExceptionSpecChecks.empty());
  995   assert(DelayedDllExportClasses.empty());
  996   assert(DelayedDllExportMemberFunctions.empty());
 1239   assert(ParsingInitForAutoVars.empty() &&
 1472     assert(Fn && "Must have a function to attach the deferred diag to.");
 1500     assert((!PartialDiagId || ShowCallStack) &&
 1514     assert(!S.DeviceCallGraph.count(OrigCallee));
 1531     assert(!IsKnownEmitted(S, C.Callee) &&
 1739   assert(!FunctionScopes.empty() && "mismatched push/pop!");
 1774   assert(!CurFunction->CompoundScopes.empty() && "mismatched push/pop");
 1808     assert(!CodeSynthesisContexts.empty());
 1834         assert(!CodeSynthesisContexts.empty());
 1859     assert(!CodeSynthesisContexts.empty());
tools/clang/lib/Sema/SemaAccess.cpp
  210     assert(HasInstanceContext);
  280   assert(Derived->getCanonicalDecl() == Derived);
  281   assert(Target->getCanonicalDecl() == Target);
  307         assert(T->isDependentType() && "non-dependent base wasn't a record?");
  334   assert(!Friend->isDependentContext() &&
  564   assert(isa<FunctionDecl>(Friend) && "unknown friend decl kind");
  617     assert(I < CurPath.size());
  660         assert(T->isDependentType() && "non-dependent base wasn't a record?");
  676     assert(CurPath.empty());
  712   assert(InstanceContext == nullptr ||
  714   assert(NamingClass->getCanonicalDecl() == NamingClass);
  732   assert(NamingClass->getCanonicalDecl() == NamingClass &&
  736   assert(Access == AS_private || Access == AS_protected);
  756       assert(Access == AS_protected);
  817       assert(Target.isInstanceMember());
  937   assert(isDerived && "derived class not actually derived from base");
  942   assert(FinalAccess != AS_none && "forbidden access after declaring class");
  957       assert(PathAccess != AS_none);
 1001   assert((!BestPath || BestPath->Access != AS_public) &&
 1023   assert(Target.isMemberAccess());
 1060     assert(InstanceContext && "diagnosing dependent access");
 1095   assert(entity.isMemberAccess());
 1188   assert(path.Access != AS_public);
 1195     assert(accessSoFar != AS_none && accessSoFar != AS_private);
 1224       assert(baseAccess == AS_private);
 1225       assert(constrainingBase == i);
 1320   assert(UnprivilegedAccess != AS_public && "public access not weeded out");
 1376   assert(Entity.getDeclaringClass() != NamingClass);
 1384   assert(Path->Access <= UnprivilegedAccess &&
 1395   assert(EC.isDependent() && "delaying non-dependent access");
 1397   assert(DC->isDependentContext() && "delaying non-dependent access");
 1413   assert(Entity.getAccess() != AS_public && "called for public access!");
 1769   assert(isa<CXXMethodDecl>(target->getAsFunction()));
 1859   assert(getLangOpts().AccessControl
 1861   assert(R.getNamingClass() && "performing access check without naming class");
tools/clang/lib/Sema/SemaAttr.cpp
  355   assert(Kind == PragmaPackDiagnoseKind::ChangedStateAtExit && "invalid kind");
  789           assert(Entry.Attribute && "Expected an attribute");
  813       assert(Attribute && "Expected an attribute");
  814       assert(Attribute->isPragmaClangAttribute() &&
  838   assert(PragmaAttributeCurrentTargetDecl && "Expected an active declaration");
tools/clang/lib/Sema/SemaCUDA.cpp
   28   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
   33   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  164   assert(Callee && "Callee must be valid.");
  249   assert(Target1 != Sema::CFT_Global);
  250   assert(Target2 != Sema::CFT_Global);
  497     assert(!VD->isStaticLocal() || VD->hasAttr<CUDASharedAttr>());
  558   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  607   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  635   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  660   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  661   assert(Callee && "Callee may not be null.");
  702       assert(Caller && "WrongSide calls require a non-null caller");
  733   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
  750   assert(getLangOpts().CUDA && "Should only be called during CUDA compilation");
tools/clang/lib/Sema/SemaCXXScopeSpec.cpp
  122             assert(!isSFINAEContext() &&
  153     assert(Tag && "Non-tag type in nested-name-specifier");
  180   assert(getLangOpts().CPlusPlus && "Only callable in C++");
  181   assert(NNS->isDependent() && "Only dependent nested-name-specifier allowed");
  201   assert(DC && "given null context");
  371   assert(!Found.isAmbiguous() && "Cannot handle ambiguities here yet");
  395     assert(!SS.isSet() && "ObjectType and scope specifier cannot coexist");
  504     assert(!SS.isSet() && "ObjectType and scope specifier cannot coexist");
  852   assert(DS.getTypeSpecType() == DeclSpec::TST_decltype);
  911     assert(DTN->getQualifier() == SS.getScopeRep());
 1021   assert(SS.isSet() && "Parser passed invalid CXXScopeSpec.");
 1070   assert(SS.isSet() && "Parser passed invalid CXXScopeSpec.");
 1097   assert(SS.isSet() && "Parser passed invalid CXXScopeSpec.");
 1100   assert(!SS.isInvalid() && computeDeclContext(SS, true) &&
tools/clang/lib/Sema/SemaCast.cpp
  142       assert(Self.getLangOpts().allowsNonTrivialObjCLifetimeQualifiers());
  241   assert(!D.isInvalidType());
  338   assert(!D.isInvalidType());
  400   assert(sequence.Failed() && "initialization succeeded on second try?");
  603     assert((SrcType->isAnyPointerType() || SrcType->isMemberPointerType() ||
  606     assert((DestType->isAnyPointerType() || DestType->isMemberPointerType() ||
  740     assert(DestPointer && "Reference to void is not possible");
  800   assert((DestPointer || DestReference) &&
  802   assert((DestRecord || DestPointee->isVoidType()) &&
  804   assert(SrcRecord && "Bad source pointee slipped through.");
  838   assert(SrcDecl && "Definition missing");
  932       assert(BaseRD && "Base type should be a valid unqualified class type");
  957   assert((VirtualBase || NonZeroOffset) &&
 1584     assert(StillOkay);
 2033     assert(FixedExpr.isUsable() && "Invalid result fixing overloaded expr");
 2121     assert(!IsLValueCast);
 2202     assert(srcIsPtr && "One type must be a pointer");
 2219     assert(destIsPtr && "One type must be a pointer");
 2251     assert(SrcType->isPointerType() && DestType->isPointerType());
 2401   assert(Self.getLangOpts().CPlusPlus);
 2440     assert(Kind == CK_Dependent);
 2581   assert(!Self.getLangOpts().CPlusPlus);
 2612     assert(SrcExpr.isUsable());
 2619   assert(!SrcType->isPlaceholderType());
 2911   assert(LPLoc.isValid() && "List-initialization shouldn't get here.");
tools/clang/lib/Sema/SemaChecking.cpp
 1043   assert(ParamTy->getPointeeType()->isObjectType() &&
 1096     assert(TheCall->getNumArgs() == 1 &&
 1601     assert(!shift && "cannot shift float types!");
 1604     assert(!shift && "cannot shift float types!");
 1607     assert(!shift && "cannot shift float types!");
 1730   assert((BuiltinID == ARM::BI__builtin_arm_ldrex ||
 1803     assert(MaxWidth == 64 && "Diagnostic unexpectedly inaccurate");
 1960   assert(BuiltinID == BPF::BI__builtin_preserve_field_info &&
 2779       assert(CPU.startswith("hexagon") && "Unexpected CPU name");
 4209   assert((FDecl || Proto) && "Need a function declaration or prototype");
 4864         assert(Form != Load);
 5001   assert(Fn && "builtin call without direct callee!");
 5334     assert(Res.getFoundDecl());
 5397   assert((BuiltinID == Builtin::BI__builtin_nontemporal_store ||
 5794         assert(
 6493   assert(false && "Unhandled ARM MTE intrinsic");
 6514   assert((IsARMBuiltin || IsAArch64Builtin) && "Unexpected ARM builtin.");
 6644     assert(hasUncoveredArg() && "no uncovered argument");
 6656     assert(NewFirstUncoveredArg >= 0 && "Outside range");
 6707     assert(AddendIsRight && BinOpKind == BO_Sub &&
 6715     assert(BitWidth <= std::numeric_limits<unsigned>::max() / 2 &&
 6805   assert(Offset.isSigned() && "invalid offset");
 7169     assert(ArgIdx < Args.size() && "ArgIdx outside bounds");
 7490       assert((unsigned)notCoveredArg < NumDataArgs);
 7500   assert(hasUncoveredArg() && DiagnosticExprs.size() > 0 &&
 7791       assert(AT.isValid());
 8577     assert(FirstDataArg + FS.getArgIndex() < CheckedVarArgs.size() &&
 8787   assert(T && "String literal not of constant array type!");
 8850   assert(T && "String literal not of constant array type!");
 9580   assert(BId != 0);
10079     assert(T->isCanonicalUnqualified());
10113     assert(BT->isInteger());
10124     assert(T->isCanonicalUnqualified());
10136     assert(BT->isInteger());
10194   assert(result.isLValue() || result.isAddrLabelDiff());
10471   assert(value.isComplexFloat());
10567     assert(Value.getBitWidth() == PromotedMin.getBitWidth() &&
10570       assert(Value.isUnsigned() && "discontiguous range for signed compare");
10847     assert(!RHS->getType()->hasSignedIntegerRepresentation() &&
10882     assert(unsignedRange.NonNegative && "unsigned range includes negative?");
10899   assert(Bitfield->isBitField());
11213   assert(isa<CompoundAssignOperator>(E) &&
12314         assert(ParamIter != FD->param_end());
13600   assert(owner.Variable && owner.Loc.isValid());
13636   assert(capturer);
13637   assert(owner.Variable && owner.Loc.isValid());
13845     assert(msg->getReceiverKind() == ObjCMessageExpr::SuperInstance);
14062   assert(!CurrentInstantiationScope); // Ensured by caller
14308         assert(Result);
14704   assert(TopME && "We did not compute a topmost MemberExpr!");
14770     assert(FD && "We did not find a packed FieldDecl!");
tools/clang/lib/Sema/SemaCodeComplete.cpp
  514     assert(false && "unhandled unary op");
 1056   assert(!ShadowMaps.empty() && "Must enter into a results scope");
 1353   assert(R.Kind != Result::RK_Declaration &&
 1604         assert(ThisType->isPointerType());
 2310       assert(!ReturnType.isNull());
 3010       assert(isa<TemplateTemplateParmDecl>(*P));
 3206   assert(Kind == RK_Macro);
 3286   assert(Kind == RK_Declaration && "Missed a result kind?");
 3297       assert(SeenTypedChunk && "optional parameter before name");
 3394           assert(isa<TemplateTemplateParmDecl>(Param));
 4264   assert(!T.isNull());
 4779         assert(ObjCPtr && "Non-NULL pointer guaranteed above!");
tools/clang/lib/Sema/SemaCoroutine.cpp
  106   assert(RD && "specialization of class template is not a class?");
  149   assert(StdExp && "Should already be diagnosed");
  260   assert(!Operators.isAmbiguous() && "Operator lookup cannot be ambiguous");
  269   assert(CoawaitOp);
  299   assert(BuiltInDecl && "failed to find builtin declaration");
  303   assert(DeclRef.isUsable() && "Builtin reference cannot fail");
  308   assert(!Call.isInvalid() && "Call to builtin cannot fail!");
  481   assert(isa<FunctionDecl>(CurContext) && "not in a function scope");
  528     assert(Move != Moves.end() &&
  578   assert(isa<FunctionDecl>(S.CurContext) && "not in a function scope");
  581   assert(ScopeInfo && "missing function scope for function");
  604   assert(ScopeInfo->CoroutinePromise);
  903   assert(Std && "Should already be diagnosed");
  940   assert(PointeeRD && "PromiseType must be a CxxRecordDecl type");
  959   assert(Fn && Fn->isCoroutine() && "not a coroutine");
  961     assert(FD->isInvalidDecl() &&
  978     assert(Fn->FirstCoroutineStmtLoc.isValid() &&
 1007     assert(PromiseRecordDecl && "Type should have already been checked");
 1013   assert(this->IsValid && "coroutine already invalid");
 1021   assert(this->IsValid && "coroutine already invalid");
 1022   assert(!this->IsPromiseDependentType &&
 1074   assert(!IsPromiseDependentType &&
 1119   assert(!IsPromiseDependentType &&
 1301   assert(!IsPromiseDependentType &&
 1352   assert(!IsPromiseDependentType &&
 1416   assert(!IsPromiseDependentType &&
 1418   assert(this->ReturnValue && "ReturnValue must be already formed");
 1421   assert(!GroType->isDependentType() &&
 1425   assert(!FnRetType->isDependentType() &&
 1525   assert(isa<FunctionDecl>(CurContext) && "not in a function scope");
 1529   assert(ScopeInfo->CoroutineParameterMoves.empty() &&
tools/clang/lib/Sema/SemaDecl.cpp
  465   assert(IIDecl && "Didn't find decl");
  558   assert(getLangOpts().MSVCCompat && "shouldn't be called in non-MSVC mode");
  762     assert(SS && SS->isInvalid() &&
  856   assert(NextToken.isNot(tok::coloncolon) &&
 1196   assert(getLangOpts().CPlusPlus && "ADL-only call in C?");
 1290   assert(getContainingDC(DC) == CurContext &&
 1297   assert(CurContext && "DeclContext imbalance!");
 1300   assert(CurContext && "Popped translation unit!");
 1310   assert(CurContext && "skipping definition of undefined tag");
 1341   assert(!S->getEntity() && "scope already has entity");
 1346   assert(Ancestor->getEntity() == CurContext && "ancestor context mismatch");
 1354   assert(S->getEntity() == CurContext && "Context imbalance!");
 1375   assert(CurContext == FD->getLexicalParent() &&
 1393   assert(CurContext && "DeclContext imbalance!");
 1395   assert(CurContext && "Popped translation unit!");
 1636   assert(D);
 1885   assert((S->getFlags() & (Scope::DeclScope | Scope::TemplateParamScope)) &&
 1889     assert(TmpD && "This decl didn't get pushed??");
 1891     assert(isa<NamedDecl>(TmpD) && "Decl isn't NamedDecl?");
 2296           assert(EnumScope->isDeclScope(ED));
 2752     assert(CIAttr->isConstinit() && "should not diagnose this for attribute");
 3090   assert(A->getNumParams() == B->getNumParams());
 3127   assert((NamedDC->InEnclosingNamespaceSetOf(SemaDC) ||
 3573       assert(OldQTypeForComparison.isCanonical());
 3623       assert(!OldProto->hasExceptionSpec() && "Exception spec in C");
 3817   assert(!S.Context.hasSameType(New->getType(), Old->getType()));
 4338   assert(TagFromDeclSpec->isThisDeclarationADefinition());
 4664   assert(PrevDecl && "Expected a non-null Decl");
 4723         assert(Chaining.size() >= 2);
 4757   assert(StorageClassSpec != DeclSpec::SCS_typedef &&
 4777   assert(Record->hasInClassInitializer());
 4903         assert(FD->getAccess() != AS_none);
 5002   assert(TInfo && "couldn't build declarator info for anonymous struct/union");
 5091   assert(Record && "expected a record!");
 5096   assert(TInfo && "couldn't build declarator info for anonymous struct");
 6123   assert(S.ParsingInitForAutoVars.count(&ND) == 0);
 6143         assert(VD->isThisDeclarationADefinition() &&
 6753       assert((Invalid ||
 6967   assert(!NewVD->hasAttr<DLLImportAttr>() ||
 7422   assert(S.getLangOpts().CPlusPlus && "only C++ has extern \"C\"");
 7481   assert(Prev && "should have found a previous declaration to diagnose");
 7675       assert(!getLangOpts().ObjCAutoRefCount);
 7987   assert(!Prev.isAmbiguous() &&
 8197     assert(DC->isRecord() &&
 8449   assert((PT->isArrayType() || PT->isRecordType()) && "Unexpected type.");
 8455   assert(VisitStack.back() && "First decl null?");
 8460       assert(!HistoryStack.empty());
 8477       assert((FieldTy->isArrayType() || FieldTy->isRecordType()) &&
 8570   assert(R->isFunctionType());
 8955         assert(Param->getDeclContext() != NewFD && "Was set before ?");
 9016     assert(R->isFunctionNoProtoType() && NewFD->getNumParams() == 0 &&
 9094     assert((NewFD->isInvalidDecl() || !D.isRedeclaration() ||
 9156         assert((isFunctionTemplateSpecialization ||
 9193       assert(HasExplicitTemplateArgs &&
 9248     assert((NewFD->isInvalidDecl() || !D.isRedeclaration() ||
 9667   assert(TA && "MultiVersion Candidate requires a target attribute");
 9883   assert(MVType != MultiVersionKind::None &&
10238   assert(!NewFD->getReturnType()->isVariablyModifiedType() &&
10363       assert(NewTemplateDecl && "Template/non-template mismatch");
10382         assert(OldTemplateDecl->isMemberSpecialization());
10387           assert(OldFD->getCanonicalDecl() == OldFD);
10405     assert((Previous.empty() ||
10613   assert(T->isFunctionType() && "function decl is not of function type");
10661   assert(FD->getNumParams() == nparams);
10733   assert(T->isFunctionType() && "function decl is not of function type");
11115   assert((!VDecl || !VDecl->isInitCapture()) &&
11121   assert(Deduced && "deduceVarTypeFromInitializer for non-deduced type");
11125     assert(VDecl && "no init for init capture deduction?");
11148     assert(VDecl && "non-auto type for init capture deduction?");
11256   assert(VDecl->isLinkageValid());
11281   assert((InitType.hasNonTrivialToPrimitiveDefaultInitializeCUnion() ||
11527   assert((QT.hasNonTrivialToPrimitiveDefaultInitializeCUnion() ||
11566     assert(!isa<FieldDecl>(RealDecl) && "field init shouldn't get here");
11974     assert(DirectInit && "Call-style initializer must be direct init.");
12574   assert(VD->isStaticLocal());
12734       assert(VD->isStaticLocal());
13063   assert(S->isFunctionPrototypeScope());
13064   assert(S->getFunctionPrototypeDepth() >= 1);
13267   assert(getCurFunctionDecl() == nullptr && "Function parsing confused");
13268   assert(D.isFunctionDeclarator() && "Not a function declarator!");
13384           assert(!D->isThisDeclarationADefinition() &&
13542     assert(inTemplateInstantiation() &&
13583       assert(!isa<ParmVarDecl>(NonParmDecl) &&
13618     assert(!FD->hasAttr<DLLExportAttr>());
13923     assert((FD == getCurFunctionDecl() || getCurLambda()->CallOperator == FD) &&
13926     assert(MD == getCurMethodDecl() && "Method parsing confused");
13944       assert(isDesignated && InitMethod);
13986   assert(!getCurFunction()->ObjCShouldCallSuper &&
14055     assert(ExprCleanupObjects.size() ==
14058     assert(!Cleanup.exprNeedsCleanups() && "Unaccounted cleanups in function");
14059     assert(MaybeODRUseExprs.empty() &&
14172   assert(!Error && "Error setting up implicit decl!");
14349   assert(D.getIdentifier() && "Wrong callback for declspec without declarator");
14350   assert(!T.isNull() && "GetTypeForDeclarator() returned null type");
14353     assert(D.isInvalidType() && "no declarator info for valid type");
14710   assert((Name != nullptr || TUK == TUK_Definition) &&
14712   assert(TemplateParameterLists.size() == 0 || TUK != TUK_Reference);
14808     assert(!getLangOpts().CPlusPlus && "not meant for C++ usage");
15026     assert(SS.isEmpty());
15062       assert(TUK == TUK_Friend);
15447       assert(ED->isComplete() && "enum with type should be complete");
15658   assert(isa<ObjCContainerDecl>(IDecl) &&
15661   assert(getContainingDC(OCD) == CurContext &&
15700   assert(InjectedClassName->isInjectedClassName() &&
15712     assert(Tag->isInvalidDecl() && "We should already have completed it");
15739   assert(DC == CurContext && "Mismatch of container contexts");
16178   assert(FD);
16179   assert(getLangOpts().CPlusPlus && "valid check only for C++");
16304       assert(EnclosingContext && "Implementation has no class interface!");
16404   assert(EnclosingDecl && "missing record or interface decl");
16683                 assert(SO->second.size() > 0 &&
16806       assert(IMPDecl && "ActOnFields - missing ObjCImplementationDecl");
16856   assert((T->isIntegralType(Context) || T->isEnumeralType()) &&
16873   assert((T->isIntegralType(Context) ||
17143     assert((getLangOpts().CPlusPlus || !isa<TagDecl>(PrevDecl)) &&
17301     assert(Vec->size() > 1 && "ECDVector should have at least 2 elements.");
17320   assert(ED->isClosedFlag() && "looking for value in non-flag or open enum");
17321   assert(ED->isCompleteDefinition() && "expected enum definition");
17489       assert(NumPositiveBits <= BestWidth &&
tools/clang/lib/Sema/SemaDeclAttr.cpp
  326   assert(isFunctionOrMethodOrBlock(D));
  846   assert(AI.isArgExpr(AttrArgNo) && "Expected expression argument");
 1029     assert(E->getType()->getPointeeCXXRecordDecl() == ClassType &&
 2461   assert(checkAttributeAtMostNumArgs(S, AL, 3) &&
 2838   assert(ParmTSI && "no type source info for attribute argument");
 3357   assert(FD && "Expected a function declaration!");
 3764   assert(D->hasAttrs() && "no attributes on decl");
 3803   assert(RD->hasDefinition() && "RD has no definition!");
 4730   assert(!ValArg.isInvalid() &&
 4814   assert(MatchingCTypeLoc && "no type source info for attribute argument");
 5284     assert(QT->isDependentType() &&
 6325   assert(cast<VarDecl>(D)->getStorageDuration() == SD_Automatic &&
 6370     assert(!isa<ParmVarDecl>(VD) && "should be diagnosed automatically");
 6477       assert(AL.isTypeAttr() && "Non-type attribute not handled");
 7334   assert(isa<FunctionDecl>(ND) || isa<VarDecl>(ND));
 7491     assert(Reason && "didn't set reason?");
 7609   assert(K != AR_Available && "Expected an unavailable declaration here!");
 7991           assert(SelectorSlotNames.size() == Locs.size());
 8030   assert(DD.Kind == DelayedDiagnostic::Availability &&
 8042   assert(DelayedDiagnostics.getCurrentPool());
 8100   assert(curPool && "re-emitting in undelayed context not supported");
 8467   assert(Body && "Need a body here!");
tools/clang/lib/Sema/SemaDeclCXX.cpp
  132         assert(E && "pseudo-object binding without source expression?");
  210   assert(EST == EST_Dynamic && "EST case not considered earlier.");
  211   assert(ComputedEST != EST_None &&
  631       assert(NewParam->hasDefaultArg());
  689   assert(D.isDecompositionDeclarator());
 1008   assert(RD && "specialization of class template is not a class?");
 1346     assert(Bindings.size() != NumFields);
 1494   assert(Context.hasSameType(New->getType(), Old->getType()) &&
 1756   assert(Body &&
 2199       assert(RD->getNumVBases() == 0 && "constexpr ctor with virtual bases");
 2321   assert(getLangOpts().CPlusPlus && "No class names in C!");
 2348   assert(getLangOpts().CPlusPlus && "No class names in C!");
 2490   assert(BaseDecl && "Record type has no declaration");
 2492   assert(BaseDecl && "Base type is not incomplete, but has no definition");
 2494   assert(CXXBaseDecl && "Base type is not a C++ type");
 2704       assert(found);
 2712         assert(Bases[idx]->isVirtual());
 2804   assert(BasePathArray.empty() && "Base path array must be empty!");
 2805   assert(Paths.isRecordingPaths() && "Must record paths!");
 2887     assert(StillOkay && "Can only be used with a derived-to-base conversion");
 2953   assert(Access != AS_none && "Invalid kind for syntactic access specifier!");
 3109         assert(Field->getAccess() != AS_none);
 3110         assert(Bases.find(Base) == Bases.end());
 3130     assert(BaseField->getAccess() != AS_private);
 3162   assert(isa<CXXRecordDecl>(CurContext));
 3163   assert(!DS.isFriendSpecified());
 3262         assert(!Failed && "Making a constexpr member const shouldn't fail");
 3271         assert(DS.getStorageClassSpec() == DeclSpec::SCS_mutable &&
 3408         assert(LastAccessSpec && "differing access with no access specifier");
 3431   assert((Name || isInstField) && "No identifier for non-field ?");
 3874   assert((isa<MSPropertyDecl>(D) || FD->getInClassInitStyle() != ICIS_NoInit) &&
 4222   assert((DirectMember || IndirectMember) &&
 4324   assert(cast<CXXConstructExpr>(DelegationInit.get())->getConstructor() &&
 4672   assert((ImplicitInitKind == IIK_Default || ImplicitInitKind == IIK_Inherit) &&
 4924   assert(Initializer->isDelegatingInitializer());
 5088         assert(ClassDecl->hasFlexibleArrayMember() &&
 5226       assert(IdealIndex < NumIdealInits &&
 5250     assert(BaseClass && "neither field nor base");
 5343       assert(Init->isDelegatingInitializer());
 5405     assert(Dtor && "No dtor found for FieldClassDecl!");
 5441     assert(Dtor && "No dtor found for BaseClassDecl!");
 5473     assert(Dtor && "No dtor found for BaseClassDecl!");
 5755   assert(ClassAttr->getKind() == attr::DLLExport);
 6013           assert(!getDLLAttr(FD) &&
 6595         assert(DNominatedBase == DConstructedBase);
 6654     assert(CSM == Sema::CXXDefaultConstructor);
 6795   assert(CD->getInheritedConstructor() &&
 6840   assert(FD->isExplicitlyDefaulted() && "not explicitly-defaulted");
 6843   assert(DefKind && "not a defaultable function");
 6856   assert(MD->isExplicitlyDefaulted() && CSM != CXXInvalid &&
 6969     assert(CSM == CXXCopyAssignment && "unexpected non-ref argument");
 7040       assert(!ShouldDeleteForTypeMismatch && "deleted non-first decl");
 7051   assert(DCK != DefaultedComparisonKind::None && "not a defaulted comparison");
 7060   assert(RD && "defaulted comparison is not defaulted in a class");
 7075     assert(!MD->isStatic() && "comparison function cannot be a static member");
 7092     assert(FD->getFriendObjectKind() && "expected a friend declaration");
 7238     assert(CSM == Sema::CXXDefaultConstructor);
 7641   assert(!RD->isDependentType() && "do deletion after instantiation");
 7690       assert(UserDeclaredMove);
 7702       assert(UserDeclaredMove);
 7754     assert(ICI || CSM == getSpecialMember(MD));
 7885       assert(SMOR.getKind() ==
 8048   assert(!MD->isUserProvided() && CSM != CXXInvalid && "not special enough");
 8162       assert(BS.isVirtual());
 8212     assert(Name.getNameKind() == DeclarationName::Identifier);
 8755           assert(!This.isInvalid() && "couldn't form 'this' expr in dtor?");
 9071   assert(Conversion && "Expected to receive a conversion function declaration");
 9151   assert(GuidedTemplateDecl && "missing template decl for deduction guide");
 9221     assert(TSI && "deduction guide has valid type but invalid return type?");
 9269   assert(*IsInline != PrevNS->isInline());
 9460   assert(Namespc && "Invalid parameter, expected NamespaceDecl");
 9518         assert(!Name.empty());
 9533   assert(getLangOpts().CPlusPlus &&
 9551   assert(Info->Kind == Kind);
 9552   assert(Info->Record);
 9604     assert(VD && "should not be null!");
 9646   assert(getLangOpts().CPlusPlus &&
 9835   assert(!SS.isInvalid() && "Invalid CXXScopeSpec.");
 9836   assert(NamespcName && "Invalid NamespcName.");
 9837   assert(IdentLoc.isValid() && "Invalid NamespceName location.");
 9842   assert(S->getFlags() & Scope::DeclScope && "Invalid Scope.");
 9872     assert(NS && "expected namespace decl");
 9932   assert(S->getFlags() & Scope::DeclScope && "Invalid Scope.");
10204     assert(!isa<UsingShadowDecl>(Target) && "nested shadow declaration");
10397   assert(!SS.isInvalid() && "Invalid CXXScopeSpec.");
10399   assert(IdentLoc.isValid() && "Invalid TargetName location.");
10435     assert(IsInstantiation && "no scope in non-instantiation");
10652   assert(isa<UnresolvedUsingValueDecl>(InstantiatedFrom) ||
10665   assert(!UD->hasTypename() && "expecting a constructor name");
10668   assert(SourceType &&
10968   assert((S->getFlags() & Scope::DeclScope) &&
11002   assert(Name.Kind == UnqualifiedIdKind::IK_Identifier &&
11135   assert(!R.isAmbiguous() && !R.empty());
11438   assert(ClassDecl->needsImplicitDefaultConstructor() &&
11495   assert((Constructor->isDefaulted() && Constructor->isDefaultConstructor() &&
11503   assert(ClassDecl && "DefineImplicitDefaultConstructor - invalid constructor");
11612   assert(!BaseCtor->isDeleted() && "should not use deleted constructor");
11633   assert(Constructor->getInheritedConstructor() &&
11716   assert(ClassDecl->needsImplicitDestructor());
11779   assert((Destructor->isDefaulted() &&
11787   assert(ClassDecl && "DefineImplicitDestructor - invalid destructor");
11864   assert(getLangOpts().CPlusPlus11 &&
11904     assert(E && "Expression construction must not fail.");
12069   assert(MemCpyRef.isUsable() && "Builtin reference cannot fail");
12077   assert(!Call.isInvalid() && "Call to __builtin_memcpy cannot fail!");
12326   assert(ClassDecl->needsImplicitCopyAssignment());
12402   assert(CopyOp->isImplicit());
12421     assert(UserDeclaredOperation);
12432     assert(UserDeclaredOperation);
12445   assert((CopyAssignOperator->isDefaulted() &&
12586       assert(ClassDecl->hasFlexibleArrayMember() &&
12637     assert(!Body.isInvalid() && "Compound statement creation cannot fail");
12648   assert(ClassDecl->needsImplicitMoveAssignment());
12729   assert(!Class->isDependentContext() && "should not define dependent move");
12810   assert((MoveAssignOperator->isDefaulted() &&
12954       assert(ClassDecl->hasFlexibleArrayMember() &&
12969     assert(!From.build(*this, Loc)->isLValue() && // could be xvalue or prvalue
13009     assert(!Body.isInvalid() && "Compound statement creation cannot fail");
13024   assert(ClassDecl->needsImplicitCopyConstructor());
13111   assert((CopyConstructor->isDefaulted() &&
13120   assert(ClassDecl && "DefineImplicitCopyConstructor - invalid constructor");
13159   assert(ClassDecl->needsImplicitMoveConstructor());
13243   assert((MoveConstructor->isDefaulted() &&
13252   assert(ClassDecl && "DefineImplicitMoveConstructor - invalid constructor");
13290   assert(!Conv->getReturnType()->isUndeducedType());
13329   assert(FunctionRef && "Can't refer to __invoke function?");
13348   assert(!Conv->getParent()->isGenericLambda());
13490   assert(declaresSameEntity(
13507   assert(Field->hasInClassInitializer());
13531     assert((getLangOpts().Modules || (!Lookup.empty() && Lookup.size() <= 2)) &&
13535       assert(isa<CXXRecordDecl>(Lookup[0]) &&
13542       assert(Pattern && "We must have set the Pattern!");
13647   assert(Proto && "Constructor without a prototype?");
13842   assert(FnDecl && FnDecl->isOverloadedOperator() &&
13928       assert(CanBeBinaryOperator &&
14404     assert(!S->isDeclScope(PrevDecl));
14455   assert(AssertExpr != nullptr && "Expected non-null condition");
14524   assert(TSInfo && "NULL TypeSourceInfo for friend type declaration");
14685   assert(SS.isNotEmpty() && "valid templated tag with no SS and no direct?");
14731   assert(DS.isFriendSpecified());
14732   assert(DS.getStorageClassSpec() == DeclSpec::SCS_unspecified);
14822   assert(DS.isFriendSpecified());
14823   assert(DS.getStorageClassSpec() == DeclSpec::SCS_unspecified);
14863   assert(NameInfo.getName());
15024     assert(isa<CXXRecordDecl>(DC) && "friend declaration not in class?");
15071   assert(ND->getLexicalDeclContext() == CurContext);
15548   assert(D.getDeclSpec().getStorageClassSpec() != DeclSpec::SCS_typedef &&
15680       assert(TSK != TSK_ExplicitInstantiationDefinition &&
15763       assert(OI->second.size() > 0 && "no final overrider");
15890         assert(FNTarget && "Ctor cycle through bodiless function");
16091     assert((NoexceptExpr->isTypeDependent() ||
tools/clang/lib/Sema/SemaDeclObjC.cpp
   60     assert(resultClass && "unexpected object type!");
   85         assert(receiverClass && "method not associated with a class!");
  363   assert((getCurMethodDecl() == nullptr) && "Methodparsing confused");
  529   assert(ProtoRefs);
  629       assert(!SuperClassDecl && "Failed to set SuperClassType?");
  983   assert(ClassName && "Missing class identifier");
 1214   assert(ProtocolName && "Missing protocol identifier");
 1423     assert(numProtocolsResolved == identifiers.size() && "Unresolved protocols");
 1515     assert(protocols.size() == identifierLocs.size());
 1614     assert(numTypeDeclsResolved == identifiers.size() && "Unresolved type decl");
 1737   assert(numTypeDeclsResolved == identifiers.size() && "Not all types?");
 2113   assert(ImpDecl && "missing implementation decl");
 2135   assert(ivars && "missing @implementation ivars");
 2172     assert (ImplIvar && "missing implementation ivar");
 2173     assert (ClsIvar && "missing class ivar");
 2486   assert(implFamily == OMF_None || declFamily == OMF_None);
 2683   assert (IDecl && "CheckProtocolMethodDefs - IDecl is null");
 2827       assert(CDecl->getInstanceMethod(I->getSelector(), true/*AllowHidden*/) &&
 2853       assert(CDecl->getClassMethod(I->getSelector(), true/*AllowHidden*/) &&
 3189   assert(lt && rt && lt != rt);
 3248     assert(ri != right->param_end() && "Param mismatch");
 3387   assert(ExternalSource && "We need an external AST source");
 3447   assert(BoundInterface && "unexpected object type!");
 3896   assert(AtEnd.isValid() && "Invalid location for '@end'");
 4395         assert(PrevI != overridden->param_end() && "Param mismatch");
 4500   assert(SemaRef.getASTContext().getTargetInfo().getTriple().getArch() ==
 4691             assert(ObjCMethod->parameters().size() ==
 5029       assert(IvarD);
tools/clang/lib/Sema/SemaExceptionSpec.cpp
  424     assert(OldProto->getNoexceptExpr() != nullptr && "Expected non-null Expr");
  535   assert(!isUnresolvedExceptionSpec(OldEST) &&
  772   assert(!isUnresolvedExceptionSpec(SuperEST) &&
  813   assert(SuperEST == EST_Dynamic && SubEST == EST_Dynamic &&
  884   assert(Target->getNumParams() == Source->getNumParams() &&
 1002         assert(Op->getOpcode() == BO_PtrMemD || Op->getOpcode() == BO_PtrMemI);
tools/clang/lib/Sema/SemaExpr.cpp
  100   assert(Decl->isDeleted());
  387   assert((nullPos == 0 || nullPos == 1) && "invalid null position on sentinel");
  449   assert(!Ty.isNull() && "DefaultFunctionArrayConversion - missing type");
  568   assert(!T.isNull() && "r-value conversion on typeless expression?");
  697   assert(!Ty.isNull() && "UsualUnaryConversions - missing type");
  740   assert(!Ty.isNull() && "DefaultArgumentPromotion - missing type");
  963     assert(IntTy->isComplexIntegerType());
 1041   assert(IntTy->isComplexIntegerType());
 1074     assert(order < 0 && "illegal float comparison");
 1089   assert(RHSFloat);
 1107   assert(LHSType->isFloatingType() && RHSType->isFloatingType() &&
 1233   assert(RHSComplexInt);
 1252   assert(BTy && "Expected a builtin type.");
 1299   assert((LHSTy->isFixedPointType() || RHSTy->isFixedPointType()) &&
 1301   assert((LHSTy->isFixedPointOrIntegerType() ||
 1427   assert(NumAssocs == ArgExprs.size());
 1453   assert(NumAssocs == Exprs.size());
 1605   assert(Args.size() <= 2 && "too many arguments for literal operator");
 1637   assert(!StringToks.empty() && "Must have at least one string!");
 2000     assert(!ExplicitTemplateArgs &&
 2165   assert(!(IsAddressOfOperand && HasTrailingLParen) &&
 2290     assert((!CCC || CCC->IsAddressOfOperand == IsAddressOfOperand) &&
 2326     assert(!R.empty() &&
 2344   assert(!R.empty() || ADL);
 2397       assert(R.getAsSingle<VarTemplateDecl>() &&
 2567   assert(CurMethod && CurMethod->isInstanceMethod() &&
 2571   assert(IFace && "should not reference ivar from this context");
 2744     assert(QType->isRecordType() && "lookup done with non-record type");
 2780     assert(isa<UsingShadowDecl>(FoundDecl));
 2787       assert(IsDerivedFrom(FromLoc, FromRecordType, URecordType));
 2900   assert(R.isSingleResult() && "Expected only a single result");
 2949   assert(D && "Cannot refer to a NULL declaration");
 2950   assert(!isa<FunctionTemplateDecl>(D) &&
 3035       assert(getLangOpts().CPlusPlus &&
 3194   assert(success);
 3364   assert(E && "Invalid expression");
 3615       assert(Context.getTypeSize(Ty) == ResultVal.getBitWidth() &&
 3729   assert(E && "ActOnParenExpr() missing expr");
 3746   assert((T->isVoidType() || !T->isIncompleteType()) &&
 3825   assert(!ExprTy->isReferenceType());
 3864   assert(!ExprTy->isReferenceType());
 4041   assert(T->isVariablyModifiedType());
 4042   assert(CSI != nullptr);
 4311   assert(op->getType()->isObjCObjectPointerType());
 4770   assert(VK == VK_RValue || LangOpts.CPlusPlus ||
 4915     assert(!Init->getNumObjects() &&
 5082     assert((Call->getNumArgs() == NumParams) &&
 5196       assert(Param && "can't use default arguments without a known callee");
 5533   assert(NamingClass && "Must have naming class even for implicit access");
 5872     assert(UsesADL == ADLCallKind::NotADL &&
 5954     assert(isa<FunctionNoProtoType>(FuncT) && "Unknown FunctionType!");
 6036   assert(Ty && "ActOnCompoundLiteral(): missing type");
 6037   assert(InitExpr && "ActOnCompoundLiteral(): missing expression");
 6242   assert(E.get()->getType()->isBlockPointerType());
 6243   assert(E.get()->isRValue());
 6264     assert(type->isPointerType());
 6486     assert(eltType->isScalarType());
 6507   assert(destTy->isVectorType() || srcTy->isVectorType());
 6534   assert(destTy->isVectorType() || srcTy->isVectorType());
 6563   assert(VectorTy->isVectorType() && "Not a vector type!");
 6587   assert(DestElemTy->isFloatingType() ||
 6616   assert(DestTy->isExtVectorType() && "Not an extended vector type!");
 6652   assert(!D.isInvalidType() && (CastExpr != nullptr) &&
 6726   assert((isa<ParenListExpr>(E) || isa<ParenExpr>(E)) &&
 6747   assert(Ty->isVectorType() && "Expected vector type");
 7205   assert(CV);
 7238   assert(CondTy);
 7257   assert(CV && RV);
 7898   assert(LHSType.isCanonical() && "LHS not canonicalized!");
 7899   assert(RHSType.isCanonical() && "RHS not canonicalized!");
 7953     assert(rhptee->isFunctionType());
 7962     assert(lhptee->isFunctionType());
 8037   assert(LHSType.isCanonical() && "LHS not canonicalized!");
 8038   assert(RHSType.isCanonical() && "RHS not canonicalized!");
 8088   assert(LHSType.isCanonical() && "LHS was not canonicalized!");
 8089   assert(RHSType.isCanonical() && "RHS was not canonicalized!");
 8548   assert((ConvertRHS || !Diagnose) && "can't indicate whether we diagnosed");
 8826   assert(VecTy && "Expression E must be a vector");
 8931   assert(!isa<ExtVectorType>(VT) &&
 9020   assert(LHSVecType || RHSVecType);
 9354   assert(LHS->getType()->isAnyPointerType());
 9355   assert(RHS->getType()->isAnyPointerType());
 9370   assert(Pointer->getType()->isAnyPointerType());
 9388   assert(ResType->isAnyPointerType() && !ResType->isDependentType());
 9573   assert(LHSExpr->getType()->isAnyPointerType());
 9574   assert(RHSExpr->getType()->isAnyPointerType());
 9631   assert(PExp->getType()->isAnyPointerType());
 9921     assert(RHSVecTy);
10075   assert(LHSType->isPointerType() || RHSType->isPointerType() ||
10227   assert(LiteralKind != Sema::LK_Block);
10542     assert(IntType->isArithmeticType());
10562   assert(Type->isArithmeticType() || Type->isEnumeralType());
10571   assert(!Type.isNull() && "composite type for <=> has not been set");
10602   assert(Type->isArithmeticType() || Type->isEnumeralType());
10705     assert(getLangOpts().CPlusPlus);
10706     assert(Context.hasSameType(LHS.get()->getType(), RHS.get()->getType()));
10709     assert(!CompositeTy->isReferenceType());
11102     assert(TypeSize == Context.getTypeSize(Context.LongLongTy) &&
11119   assert(TypeSize == Context.getTypeSize(Context.CharTy) &&
11156     assert(RHS.get()->getType()->hasFloatingRepresentation());
11456   assert(E->isLValue() && E->getType().isConstQualified());
11468   assert(var->hasLocalStorage() && "capture added 'const' to non-local?");
11537           assert(DiagnosticEmitted && "Expected diagnostic not emitted.");
11682   assert(Ty->isRecordType() && "lvalue was not record?");
11703   assert(!E->hasPlaceholderType(BuiltinType::PseudoObject));
11878   assert(!LHSExpr->hasPlaceholderType(BuiltinType::PseudoObject));
12129   assert(!ResType.isNull() && "no type for increment/decrement expression");
12290         assert(cast<UnaryOperator>(E)->getOpcode() == UO_AddrOf);
12323   assert(!OrigOp.get()->getType()->isPlaceholderType());
12742   assert((isVector(ResultTy, Context.HalfTy) ||
12745   assert(isVector(LHS.get()->getType(), Context.HalfTy) &&
12945     assert(ResultTy.isNull() || ResultTy->getAsCXXRecordDecl());
13018   assert(isVector(RHS.get()->getType(), Context.HalfTy) ==
13122   assert(Bop->getOpcode() == BO_LAnd);
13283   assert(LHSExpr && "ActOnBinOp(): missing left expression");
13284   assert(RHSExpr && "ActOnBinOp(): missing right expression");
13643     assert(!Input.get()->getType()->isDependentType() &&
13788   assert(SubStmt && isa<CompoundStmt>(SubStmt) && "Invalid action invocation!");
13793   assert(!Cleanup.exprNeedsCleanups() &&
14004         assert(isa<FieldDecl>(FI));
14041   assert((CondExpr && LHSExpr && RHSExpr) && "Missing type argument(s)");
14112   assert(ParamInfo.getIdentifier() == nullptr &&
14114   assert(ParamInfo.getContext() == DeclaratorContext::BlockLiteralContext);
14134   assert(T->isFunctionType() &&
14248   assert(!Cleanup.exprNeedsCleanups() &&
14811   assert(ConvHints.isNull() || Hint.isNull());
15060   assert(isUnevaluatedContext() &&
15397   assert(Func && "No function?");
16146               assert(RSI->OpenMPLevel == OuterRSI->OpenMPLevel &&
16681   assert(MaybeODRUseExprs.empty() &&
16687   assert((!E || isa<DeclRefExpr>(E) || isa<MemberExpr>(E) ||
16716   assert(!isa<VarTemplatePartialSpecializationDecl>(Var) &&
16806     assert((!E || isa<FunctionParmPackExpr>(E)) &&
16847         assert(E && "Capture variable should be used in an expression.");
17361       assert(E->getObjectKind() == OK_Ordinary);
17380       assert(E->getValueKind() == VK_RValue);
17381       assert(E->getObjectKind() == OK_Ordinary);
17390       assert(E->getValueKind() == VK_RValue);
17455       assert(E->getObjectKind() == OK_Ordinary);
17481       assert(E->getValueKind() == VK_RValue);
17482       assert(E->getObjectKind() == OK_Ordinary);
17520     assert(isa<CXXMemberCallExpr>(E) || isa<CXXOperatorCallExpr>(E));
17546   assert(E->getObjectKind() == OK_Ordinary);
17627     assert(Method->getReturnType() == S.Context.UnknownAnyTy);
17641     assert(E->getValueKind() == VK_RValue);
17642     assert(E->getObjectKind() == OK_Ordinary);
17655     assert(E->getValueKind() == VK_RValue);
17656     assert(E->getObjectKind() == OK_Ordinary);
17658     assert(isa<BlockPointerType>(E->getType()));
17802   assert(!arg->hasPlaceholderType());
17978   assert((Kind == tok::kw___objc_yes || Kind == tok::kw___objc_no) &&
tools/clang/lib/Sema/SemaExprCXX.cpp
   64     assert(NNS->getAsIdentifier() == &Name && "not a constructor name");
   87   assert(CurClass && &II == CurClass->getIdentifier() &&
  226     assert((isDependent || !SearchType->isIncompleteType()) &&
  389   assert(DS.getTypeSpecType() == DeclSpec::TST_decltype &&
  408   assert(Name.getKind() == UnqualifiedIdKind::IK_LiteralOperatorId);
  707   assert((Kind == tok::kw_true || Kind == tok::kw_false) &&
 1037     assert(CurLSI && "While computing 'this' capture-type for a generic "
 1039     assert(isGenericLambdaCallOperatorSpecialization(CurLSI->CallOperator) &&
 1044     assert(CurDC == getLambdaAwareParentOfDeclContext(CurLSI->CallOperator));
 1093     assert(isa<CXXRecordDecl>(DC) &&
 1152   assert((!ByCopy || Explicit) && "cannot implicitly capture *this by value");
 1230   assert((!ByCopy ||
 1339   assert((!ListInitialization ||
 1450     assert(FD->getNumParams() == 1 &&
 1686             assert(IntWidth && "Builtin type of size 0?");
 1732     assert(isa<InitListExpr>(Init) &&
 1785     assert(Initializer && "Have parens but no initializer.");
 1790     assert((!Initializer || isa<ImplicitValueInitExpr>(Initializer) ||
 1799     assert(initStyle == CXXNewExpr::CallInit && "paren init for non-call init");
 1915       assert(Context.getTargetInfo().getIntWidth() && "Builtin type of size 0?");
 2433     assert(!R.empty() && "implicitly declared allocation functions not found");
 2434     assert(!R.isAmbiguous() && "global allocation functions are ambiguous");
 2805       assert(StdBadAlloc && "Must have std::bad_alloc declared");
 2867   assert(Result.FD && "operator delete missing from global scope?");
 3051   assert(DE && "Expected delete-expression");
 3065   assert(E != nullptr && "Expected a valid initializer expression");
 3106   assert(Field != nullptr && "This should be called only for members");
 3122   assert(Field != nullptr && "Analysis requires a valid class member.");
 3140   assert(ME != nullptr && "Expected a member expression");
 3452   assert(!R.empty() && "implicitly declared allocation functions not found");
 3453   assert(!R.isAmbiguous() && "global allocation functions are ambiguous");
 3488     assert(R.getNamingClass() == nullptr &&
 3548   assert(OperatorNewOrDelete && "should be found");
 3565   assert(Callee && Callee->getCastKind() == CK_BuiltinFnToFnPtr &&
 3763     assert(!From->getType()->isPointerType() && "Arg can't have pointer type!");
 3814       assert(FD && "no conversion function for user-defined conversion seq");
 3877     assert(Diagnosed && "failed to diagnose bad conversion"); (void)Diagnosed;
 3905     assert(!ToType->isReferenceType());
 3962     assert(From->getObjectKind() != OK_ObjCProperty);
 3964     assert(!FromRes.isInvalid() && "Can't perform deduced conversion?!");
 4018       assert(FromType->castAs<EnumType>()->getDecl()->isFixed() &&
 4188         assert(From->getType()->isIntegerType());
 4200       assert(FromComplex);
 4219         assert(ToType->isIntegerType());
 4232     assert(Qualifiers::isAddressSpaceSupersetOf(AddrSpaceL, AddrSpaceR) &&
 4248     assert ((ConvTy == Sema::Compatible) &&
 4328     assert(Context.hasSameType(
 4504   assert(!T->isDependentType() && "Cannot evaluate traits of dependent type");
 4937     assert(!Args.empty());
 5072   assert(!LhsT->isDependentType() && !RhsT->isDependentType() &&
 5102     assert(Self.Context.hasSameUnqualifiedType(LhsT, RhsT)
 5294   assert(!T->isDependentType() && "Cannot evaluate traits of dependent type");
 5410   assert(!LHS.get()->getType()->isPlaceholderType() &&
 5902       assert(!LTy.isNull() && "failed to find composite pointer type for "
 5904       assert(Context.hasSameType(LTy, RTy) && "bad composite pointer type");
 5962       assert(!LTy.isNull() && "failed to find composite pointer type for "
 6057     assert(!S.getLangOpts().CPlusPlus17 &&
 6078     assert(EST2 == EST_Dynamic && "other cases should already be handled");
 6113   assert(getLangOpts().CPlusPlus && "This function assumes C++");
 6154   assert(!T1->isNullPtrType() && !T2->isNullPtrType() &&
 6361   assert(!isa<CXXBindTemporaryExpr>(E) && "Double-bound temporary?");
 6396       assert(FTy && "call to value not of function type?");
 6527   assert(SubExpr && "subexpression can't be null!");
 6532   assert(ExprCleanupObjects.size() >= FirstCleanup);
 6533   assert(Cleanup.exprNeedsCleanups() ||
 6549   assert(SubStmt && "sub-statement can't be null!");
 6572   assert(ExprEvalContexts.back().ExprContext ==
 7023   assert((FirstTypeName.getKind() == UnqualifiedIdKind::IK_TemplateId ||
 7026   assert((SecondTypeName.getKind() == UnqualifiedIdKind::IK_TemplateId ||
 7432   assert(DefVD);
 7458   assert(!S.isUnevaluatedContext());
 7459   assert(S.CurContext->isDependentContext());
 7464   assert(
 7891     assert(State.Consumer && "Cannot transform a cleared TypoExpr");
 7914         assert(!NE.isUnset() &&
 7940     assert(TyposResolved == 0 && "Corrected typo but got same Expr back?");
tools/clang/lib/Sema/SemaExprMember.cpp
   90   assert(!R.empty() && (*R.begin())->isCXXClassMember());
  133   assert(!AbstractInstanceResult);
  500       assert(BaseExpr && "cannot happen with implicit member accesses");
  507   assert(BaseType->isDependentType() ||
  558     assert(BaseType->isDependentType());
  677     assert(DC && "Cannot handle non-computable dependent contexts in lookup");
  708           assert(!TC.isKeyword() &&
  815     assert(baseVariable->getType()->isRecordType());
  822     assert(!baseObjectExpr && "anonymous struct/union is static data member?");
  833   assert((baseVariable || baseObjectExpr) &&
  915   assert((!IsArrow || Base->isRValue()) && "-> base must be a pointer rvalue");
  972     assert(BaseType->isPointerType());
 1074   assert(R.isSingleResult());
 1094       assert((!TemplateArgs || isa<VarTemplateDecl>(MemberDecl)) &&
 1153   assert(!isa<FunctionDecl>(MemberDecl) && "member function not C++ method?");
 1250   assert(BaseExpr.get() && "no base expression");
 1258   assert(!BaseType->isDependentType());
 1364         assert(!ClassDeclared);
 1375         assert(ClassDeclared && "cannot query interface");
 1393     assert(ClassDeclared);
 1486     assert(S.Context.hasSameUnqualifiedType(BaseType,
 1796     assert(!MemberQuals.hasAddressSpace());
 1839   assert(!R.empty() && !R.isAmbiguous());
 1847   assert(!ThisTy.isNull() && "didn't correctly pre-flight capture of 'this'");
tools/clang/lib/Sema/SemaExprObjC.cpp
   68     assert(CAT && "String literal not of constant array type!");
  534             assert((SL->isAscii() || SL->isUTF8()) &&
  769   assert(!LangOpts.isSubscriptPointerArithmetic());
  773   assert((!BaseExpr->isTypeDependent() && !IndexExpr->isTypeDependent()) &&
 1308   assert(Method && "Must have a method");
 1387       assert(ReceiverType->isObjCClassType() && "expected a Class self");
 1395         assert(MD->isClassMethod() && "expected a class method");
 1664     assert(argExpr && "CheckMessageArgumentTypes(): missing expression");
 2476     assert(SuperLoc.isInvalid() && "Message to super with dependent type");
 2491   assert(Class && "We don't know which class we're messaging?");
 2680   assert((Receiver || SuperLoc.isValid()) && "If the Receiver is null, the "
 2719       assert(SuperLoc.isInvalid() && "Message to super with dependent type");
 3000       assert(isDesignated && InitMethod);
 3727     assert(CreateRule != ACC_bottom && "This cast should already be accepted.");
 3768     assert(CreateRule != ACC_bottom && "This cast should already be accepted.");
 4310   assert(!e->hasPlaceholderType(BuiltinType::ARCUnbridgedCast));
 4333   assert(classifyTypeForARCConversion(castExpr->getType()) == ACTC_retainable);
 4342   assert(e->hasPlaceholderType(BuiltinType::ARCUnbridgedCast));
 4348     assert(uo->getOpcode() == UO_Extension);
 4354     assert(!gse->isResultDependent());
 4374     assert(isa<ImplicitCastExpr>(e) && "bad form of unbridged cast!");
tools/clang/lib/Sema/SemaFixItUtils.cpp
  169   assert(T.isScalarType() && "use scalar types only");
tools/clang/lib/Sema/SemaInit.cpp
  154       assert(UO->getOpcode() == UO_Extension);
  176       assert(UO->getOpcode() == UO_Extension);
  531     assert(O == OR_Success && "Inconsistent overload resolution");
  621       assert(Init < ILE->getNumInits() && "should have been expanded");
  649         assert((Init < NumInits || VerifyOnly) &&
  653       assert(!VerifyOnly && "should not fill with no-init in verify-only mode");
  740   assert((ILE->getType() != SemaRef.Context.VoidTy) &&
 1013   assert(FieldIt != ParentRD->field_end() &&
 1265     assert(DeclType->isAggregateType() &&
 1333     assert(SemaRef.Context.hasSameType(expr->getType(), ElemType) &&
 1408     assert((ElemType->isRecordType() || ElemType->isVectorType() ||
 1459       assert(Copy.isInvalid() &&
 1473   assert(Index == 0 && "Index in explicit init list must be zero");
 2272     assert(isa<FieldDecl>(*PI));
 2376       assert(isa<InitListExpr>(Init) &&
 2578           assert(StructuredList->getNumInits() == 1
 2803     assert(D->isArrayRangeDesignator() && "Need array-range designator");
 3233     assert(CT && "Unexpected type");
 3354   assert(getParent() != this);
 3728   assert(Syntactic->getNumInits() == 1 &&
 3785     assert(Entity.getType()->isObjCRetainableType() &&
 3992   assert(((!IsListInit && !IsInitListCopy) ||
 4031   assert(DestRecordType && "Constructor initialization requires record type");
 4103     assert(S.Context.hasSameUnqualifiedType(ConvType, DestType) &&
 4476   assert(!S.CompareReferenceRelationship(
 4618     assert(!isa<CXXConstructorDecl>(Function) &&
 5011   assert((!InitList || InitList->getNumInits() == 0) &&
 5088   assert(Kind.getKind() == InitializationKind::IK_Default);
 5131   assert(!DestType->isReferenceType() && "References are handled elsewhere");
 5133   assert((DestType->isRecordType() || SourceType->isRecordType()) &&
 5389   assert(src->isRValue());
 5809   assert(S.getLangOpts().CPlusPlus);
 5835   assert(Args.size() >= 1 && "Zero-argument case handled above");
 6257   assert(S.getLangOpts().CPlusPlus11);
 6379     assert(Constructor->getParent() && "No parent class for constructor.");
 7145       assert(RD->isAggregate() && "aggregate init on non-aggregate");
 7815     assert(Kind.getKind() == InitializationKind::IK_Copy ||
 7898     assert(Args.size() == 1);
 8003       assert(CurInit.get()->isRValue() && "not a temporary");
 8144       assert(CurInit.get()->isRValue() && "cannot convert glvalue to atomic");
 8239       assert(Args.size() == 1 && "expected a single argument for list init");
 8392       assert(!ArrayLoopCommonExprs.empty() &&
 8483       assert(Step->Type->isSamplerT() &&
 8561       assert((Step->Type->isEventT() || Step->Type->isQueueT() ||
 8684   assert(DiagnoseInitList.HadError() &&
 8716       assert(Kind.getKind() == InitializationKind::IK_Value ||
 8720       assert(Diagnosed && "couldn't find uninitialized reference to diagnose");
 8952       assert(Args.size() > 1 && "Expected multiple initializers!");
 8989       assert(Args.size() == 1 &&
 9137     assert(Ovl == OR_Success && "Inconsistent overload resolution");
 9588   assert(InitE && "No initialization expression");
 9606   assert(InitE && "No initialization expression?");
 9628       assert(LastStep->Kind ==
 9673   assert(DeducedTST && "not a deduced template specialization type");
tools/clang/lib/Sema/SemaLambda.cpp
   74   assert(
  124     assert(CurScopeIndex);
  130   assert(CurScopeIndex < (FunctionScopes.size() - 1));
  186   assert(((IndexOfCaptureReadyLambda != (FunctionScopes.size() - 1)) ||
  471     assert(MCtx && "Retrieving mangle numbering context failed!");
  524   assert(LSI && "Expected a lambda scope");
  525   assert(LSI->NumExplicitTemplateParams == 0 &&
  527   assert(LSI->TemplateParams.empty() &&
  530   assert(!TParams.empty() &&
  676     assert(returnType->isIntegralOrUnscopedEnumerationType());
  677     assert(retValue->getType()->isIntegralOrUnscopedEnumerationType());
  693   assert(CSI.HasImplicitReturnType);
  695   assert(CSI.ReturnType.isNull() || !CSI.ReturnType->isUndeducedType());
  696   assert((!isa<LambdaScopeInfo>(CSI) || !getLangOpts().CPlusPlus14) &&
  734   assert(!CSI.ReturnType.isNull() && "We should have a tentative return type.");
  740     assert(isa<BlockScopeInfo>(CSI));
  796     assert(!DeductType.isNull() && "can't build reference to auto");
  878   assert(Var->isInitCapture() && "init capture flag should be set");
  888   assert(LSI && "LambdaScopeInfo should be on stack!");
  895     assert(TemplateParamScope &&
  898     assert(TemplateParamScope->getParent());
  936     assert(ParamInfo.isFunctionDeclarator() &&
  950     assert(MethodTyInfo && "no type from lambda-declarator");
 1070     assert(C->Id && "missing identifier for capture");
 1117       assert(C->InitKind == LambdaCaptureInitKind::NoInit &&
 1268   assert(InvokerExtInfo.RefQualifier == RQ_None &&
 1506     assert(Cap.isVariableCapture() && "unknown kind of capture");
 1694       assert(!From.isBlockCapture() && "Cannot capture __block variables");
 1753           assert(From.isVariableCapture() && "unknown kind of capture");
tools/clang/lib/Sema/SemaLookup.cpp
  109       assert(InnermostFileDC && InnermostFileDC->isFileContext());
  231     assert(!Redeclaration && "cannot do redeclaration operator lookup");
  270     assert(Redeclaration && "should only be used for redecl lookup");
  328   assert(ResultKind != NotFound || Decls.size() == 0);
  329   assert(ResultKind != Found || Decls.size() == 1);
  330   assert(ResultKind != FoundOverloaded || Decls.size() > 1 ||
  333   assert(ResultKind != FoundUnresolvedValue || sanityCheckUnresolved());
  334   assert(ResultKind != Ambiguous || Decls.size() > 1 ||
  337   assert((Paths != nullptr) == (ResultKind == Ambiguous &&
  383     assert(isa<TypeDecl>(DUnderlying) && isa<TypeDecl>(EUnderlying));
  480     assert(ResultKind == NotFound ||
  731       assert(GenTypeMaxCnt % ArgTypes[A].size() == 0 &&
 1074     assert(ConvProto && "Nonsensical conversion function template type");
 1104   assert(NS && NS->isFileContext() && "CppNamespaceLookup() requires namespace!");
 1217   assert(getLangOpts().CPlusPlus && "Can perform only C++ lookup");
 1483           assert(Ctx->isFileContext() &&
 1658   assert(isa<CXXRecordDecl>(D->getDeclContext()) &&
 1681   assert(D->isHidden() && "should not call this: not in slow case");
 1684   assert(DeclModule && "hidden decl has no owning module");
 1805     assert(D->isExternallyDeclarable() &&
 1838   assert(!LookupResult::isVisible(SemaRef, D) && "not in slow case");
 1859   assert(!isVisible(D) && "not in slow case");
 2053   assert(StartDC->isFileContext() && "start context is not a file context");
 2154         assert(isa<TagDecl>(D) && "Non-function must be a tag decl");
 2195   assert(LookupCtx && "Sema::LookupQualifiedName requires a lookup context");
 2201   assert((!isa<TagDecl>(LookupCtx) ||
 2537   assert(Result.isAmbiguous() && "Lookup result must be ambiguous");
 3052   assert(!Operators.isAmbiguous() && "Operator lookup cannot be ambiguous");
 3063   assert(CanDeclareSpecialMemberFunction(RD) &&
 3067     assert((SM == CXXCopyAssignment || SM == CXXMoveAssignment) &&
 3070     assert((SM != CXXDefaultConstructor && SM != CXXDestructor) &&
 3104     assert(DD && "record without a destructor");
 3203     assert(SM == CXXDefaultConstructor &&
 3245       assert(isa<UsingDecl>(Cand.getDecl()) &&
 3288   assert(!(Quals & ~(Qualifiers::Const | Qualifiers::Volatile)) &&
 3330   assert(!(Quals & ~(Qualifiers::Const | Qualifiers::Volatile)) &&
 3332   assert(!(ThisQuals & ~(Qualifiers::Const | Qualifiers::Volatile)) &&
 3348   assert(!(ThisQuals & ~(Qualifiers::Const | Qualifiers::Volatile)) &&
 3383   assert(R.getResultKind() != LookupResult::Ambiguous &&
 3942     assert(!IncludeDependentBases && "Unsupported flag for lookupInScope");
 4081     assert(S && "Not in a function?");
 4499   assert(Start && "Building a context chain from a null context");
 5307   assert(Owner && "definition of hidden declaration is not in a module");
 5333   assert(!Modules.empty());
 5455     assert(Decl && "import required but no declaration to import");
 5479   assert(TCC && "createDelayedTypo requires a valid TypoCorrectionConsumer");
 5492   assert(Entry != DelayedTypos.end() &&
tools/clang/lib/Sema/SemaModule.cpp
   65     assert(getLangOpts().CPlusPlusModules && getLangOpts().ModulesTS &&
   75   assert(GlobalModule && "module creation should not fail");
   95   assert((getLangOpts().ModulesTS || getLangOpts().CPlusPlusModules) &&
  126   assert(ModuleScopes.size() <= 1 && "expected to be at global module scope");
  202     assert(Mod && "module creation should not fail");
  289   assert(PrivateModuleFragment && "module creation should not fail");
  472   assert(!ModuleScopes.empty() && ModuleScopes.back().Module == Mod &&
  482     assert(File != getSourceManager().getMainFileID() &&
tools/clang/lib/Sema/SemaObjCProperty.cpp
   74   assert(propertyLifetime != Qualifiers::OCL_None);
   89       assert(propertyLifetime == Qualifiers::OCL_ExplicitNone);
  746       assert(ivarType->isObjCARCImplicitlyUnretainedType());
  836   assert(isa<ObjCProtocolDecl>(Property->getDeclContext()) &&
 1074     assert(IDecl &&
 1206         assert(!getLangOpts().ObjCAutoRefCount);
 1281           assert(lifetime && "no lifetime for property?");
 1393   assert (property && "ActOnPropertyImplDecl - property declaration missing");
 2266   assert(IFD->hasDesignatedInitializers());
tools/clang/lib/Sema/SemaOpenMP.cpp
  220     assert(!isStackEmpty() && "no current directive");
  244     assert(Level < getStackSize() && "no such stack element");
  285     assert(isClauseParsingMode() && "Must be in clause parsing mode.");
  310     assert(!IgnoredStackElements &&
  320     assert(!IgnoredStackElements &&
  322     assert(!Stack.back().first.empty() &&
  355     assert(isOpenMPLoopDirective(getCurrentDirective()) &&
  361     assert(isOpenMPLoopDirective(getCurrentDirective()) &&
  367     assert(isOpenMPLoopDirective(getCurrentDirective()) &&
  382     assert(!IgnoredStackElements &&
  385     assert(!isa<CapturingScopeInfo>(CurFnScope));
  390     assert(!IgnoredStackElements &&
  393       assert(Stack.back().first.empty());
  462     assert(getTopOfStack().Directive == OMPD_taskgroup &&
  522     assert(!isStackEmpty() && "No directive at specified level.");
  795     assert(!isStackEmpty());
  801     assert(Parent && isOpenMPWorksharingDirective(Parent->Directive));
  829     assert(*OMPDeclareTargetDeclAttr::isDeclareTargetDeclaration(
  843     assert(isOpenMPTargetExecutionDirective(getCurrentDirective()) &&
  889     assert(FD);
 1013   assert(!isStackEmpty() && "Data sharing attributes stack is empty");
 1018     assert(NewDE && "Unexpected nullptr expr to be added into aligned map");
 1022   assert(It->second && "Unexpected nullptr expr in the aligned map");
 1027   assert(!isStackEmpty() && "Data-sharing attributes stack is empty");
 1036   assert(!isStackEmpty() && "Data-sharing attributes stack is empty");
 1048   assert(Parent && "Data-sharing attributes stack is empty");
 1058   assert(Parent && "Data-sharing attributes stack is empty");
 1077     assert(Data.Attributes == OMPC_unknown || (A == Data.Attributes) ||
 1134   assert(!isStackEmpty() && "Data-sharing attributes stack is empty");
 1135   assert(
 1139   assert(ReductionData.ReductionRange.isInvalid() &&
 1157   assert(!isStackEmpty() && "Data-sharing attributes stack is empty");
 1158   assert(
 1162   assert(ReductionData.ReductionRange.isInvalid() &&
 1181   assert(!isStackEmpty() && "Data-sharing attributes stack is empty.");
 1192     assert(I->TaskgroupReductionRef && "taskgroup reduction reference "
 1206   assert(!isStackEmpty() && "Data-sharing attributes stack is empty.");
 1217     assert(I->TaskgroupReductionRef && "taskgroup reduction reference "
 1554   assert(S.LangOpts.OpenMP && S.LangOpts.OpenMPIsDevice &&
 1571   assert(LangOpts.OpenMP && LangOpts.OpenMPIsDevice &&
 1597   assert(LangOpts.OpenMP && !LangOpts.OpenMPIsDevice &&
 1620   assert(LangOpts.OpenMP && LangOpts.OpenMPIsDevice &&
 1622   assert(Callee && "Callee may not be null.");
 1630     assert(CallerS != FunctionEmissionStatus::CUDADiscarded &&
 1663   assert(LangOpts.OpenMP && !LangOpts.OpenMPIsDevice &&
 1665   assert(Callee && "Callee may not be null.");
 1673     assert(
 1705   assert(getLangOpts().OpenMP && getLangOpts().OpenMPIsDevice &&
 1721   assert(LangOpts.OpenMP && "OpenMP is not allowed");
 1809           assert(EI != EE && "Invalid map expression!");
 1877   assert(getLangOpts().OpenMP);
 1894   assert(LangOpts.OpenMP && "OpenMP is not allowed");
 1983   assert(LangOpts.OpenMP && "OpenMP must be enabled.");
 1989   assert(LangOpts.OpenMP && "OpenMP must be enabled.");
 1997   assert(LangOpts.OpenMP && "OpenMP is not allowed");
 2033   assert(LangOpts.OpenMP && "OpenMP is not allowed");
 2071   assert(LangOpts.OpenMP && "OpenMP is not allowed");
 2083   assert(LangOpts.OpenMP && "Expected OpenMP compilation mode.");
 2599   assert(Clauses.size() <= 1 && "Expected at most one clause.");
 3507   assert(CaptureExpr);
 4133   assert(!S.CurContext->isDependentContext() &&
 4250     assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 4339     assert(ClausesWithImplicit.empty() &&
 4348     assert(ClausesWithImplicit.empty() &&
 4377     assert(ClausesWithImplicit.empty() &&
 4379     assert(AStmt == nullptr &&
 4384     assert(ClausesWithImplicit.empty() &&
 4386     assert(AStmt == nullptr &&
 4391     assert(ClausesWithImplicit.empty() &&
 4393     assert(AStmt == nullptr &&
 4402     assert(AStmt == nullptr &&
 4436     assert(ClausesWithImplicit.empty() &&
 4438     assert(AStmt == nullptr && "No associated statement allowed for 'omp "
 4443     assert(AStmt == nullptr &&
 4714   assert(Aligneds.size() == Alignments.size());
 4715   assert(Linears.size() == LinModifiers.size());
 4716   assert(Linears.size() == Steps.size());
 5200   assert(LangOpts.OpenMP && "Expected OpenMP mode.");
 5425     assert(!LB && !UB && !Step);
 5437   assert(LCDecl == nullptr && LB == nullptr && LCRef == nullptr &&
 5460   assert(LCDecl != nullptr && LB != nullptr && UB == nullptr &&
 5476   assert(LCDecl != nullptr && LB != nullptr && Step == nullptr);
 5617     assert(CurLCDecl && "Expected loop dependency.");
 5621     assert(CurLCDecl && "Expected loop dependency.");
 6184         assert(NewSize == 64 && "incorrect loop var size");
 6413     assert((OOK == OO_Plus || OOK == OO_Minus) &&
 6466   assert(getLangOpts().OpenMP && "OpenMP is not active.");
 6467   assert(Init && "Expected loop in canonical form.");
 6585   assert(((For && For->getBody()) || (CXXFor && CXXFor->getBody())) &&
 6625     assert(isOpenMPLoopDirective(DKind) && "DSA for non-loop vars");
 6956       assert(isa<CXXForRangeStmt>(CurStmt) &&
 6983       assert(isa<CXXForRangeStmt>(CurStmt) &&
 7213       assert(CD->getNumParams() >= 4 &&
 7385     assert(DistCond.isUsable() && "distribute cond expr was not built");
 7389     assert(DistInc.isUsable() && "distribute inc expr was not built");
 7394     assert(DistInc.isUsable() && "distribute inc expr was not built");
 7651   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7661   assert((CurContext->isDependentContext() || B.builtAll()) &&
 7690   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7700   assert((CurContext->isDependentContext() || B.builtAll()) &&
 7725   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7736   assert((CurContext->isDependentContext() || B.builtAll()) &&
 7765   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7802   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7818   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7848   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7861   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 7938   assert((CurContext->isDependentContext() || B.builtAll()) &&
 8008   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 8082   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 8094   assert(Clauses.size() <= 1 && "Extra clauses in flush directive");
 8167     assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 8894       assert(I != CS->body_end() && "Not found statement");
 8980   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9020   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9255   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9266   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9291   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9302   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9340   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9351   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9376   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9387   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9425   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9455   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9480   assert(isa<CapturedStmt>(AStmt) && "Captured statement expected");
 9491   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9534   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9578   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9634   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9690   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9745   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9801   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9849   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9911   assert((CurContext->isDependentContext() || B.builtAll()) &&
 9973   assert((CurContext->isDependentContext() || B.builtAll()) &&
10051   assert((CurContext->isDependentContext() || B.builtAll()) &&
10094   assert((CurContext->isDependentContext() || B.builtAll()) &&
10150   assert((CurContext->isDependentContext() || B.builtAll()) &&
10208   assert((CurContext->isDependentContext() || B.builtAll()) &&
11484     assert(Argument.size() == NumberOfElements &&
11494     assert(Argument.size() == 1 && ArgumentLoc.size() == 1);
12018     assert(RefExpr && "NULL expr in OpenMP private clause.");
12184     assert(RefExpr && "NULL expr in OpenMP firstprivate clause.");
12460     assert(RefExpr && "NULL expr in OpenMP lastprivate clause.");
12616     assert(RefExpr && "NULL expr in OpenMP lastprivate clause.");
12728   assert(!LookupResult::isVisible(SemaRef, D) && "not in slow case");
13149     assert(RefExpr && "nullptr expr in OpenMP reduction clause.");
13630       assert(TaskgroupDescriptor && "Taskgroup descriptor must be defined.");
13806     assert(RefExpr && "NULL expr in OpenMP linear clause.");
14037     assert(RefExpr && "NULL expr in OpenMP linear clause.");
14115     assert(RefExpr && "NULL expr in OpenMP copyin clause.");
14209     assert(RefExpr && "NULL expr in OpenMP linear clause.");
14297     assert(VD || isOpenMPCapturedDecl(D));
14356     assert(RefExpr && "NULL expr in OpenMP shared clause.");
14547   assert(OASE && "Expecting array section if not an array subscript.");
14599   assert(OASE && "Expecting array section if not an array subscript.");
14790       assert(!NoDiagnose && "Array sections cannot be implicitly mapped.");
14880   assert(VD && E);
14888   assert(!CurComponents.empty() && "Map clause expression with no components!");
14889   assert(CurComponents.back().getAssociatedDeclaration() == VD &&
14903         assert(!StackComponents.empty() &&
14905         assert(StackComponents.back().getAssociatedDeclaration() == VD &&
14979               assert(CKind == OMPC_to || CKind == OMPC_from);
15028             assert(CI != CE && SI != SE);
15053               assert(It != End &&
15066             assert(CKind == OMPC_to || CKind == OMPC_from);
15125     assert(Type->getAsArrayTypeUnsafe() && "Expect to get a valid array type");
15148       assert(DMD && "Expect valid OMPDeclareMapperDecl during instantiation.");
15264   assert((CKind == OMPC_map || CKind == OMPC_to || CKind == OMPC_from) &&
15289     assert(RE && "Null expr in omp to/from/map clause");
15295       assert(
15340     assert(!CurComponents.empty() &&
15366     assert(CurDeclaration && "Null decl on map clause.");
15367     assert(
15374     assert((VD || FD) && "Only variables or fields are expected here!");
15414     assert(I != CurComponents.end() && "Null decl on map clause.");
15525     assert(Count < OMPMapClause::NumberOfModifiers &&
15548   assert(ParsedType.isUsable());
15819   assert(ParsedType.isUsable() && "Expect usable parsed mapper type");
15822   assert(!MapperType.isNull() && "Expect valid mapper type");
16169   assert(DeclareTargetNestingLevel > 0 &&
16214   assert((isa<VarDecl>(ND) || isa<FunctionDecl>(ND) ||
16391     assert(RefExpr && "NULL expr in OpenMP use_device_ptr clause.");
16473     assert(RefExpr && "NULL expr in OpenMP is_device_ptr clause.");
16534     assert((isa<DeclRefExpr>(SimpleRefExpr) ||
16583     assert(RefExpr && "NULL expr in OpenMP private clause.");
tools/clang/lib/Sema/SemaOverload.cpp
  306   assert(Ctx.getLangOpts().CPlusPlus && "narrowing check outside C++");
  346       assert(Initializer && "Unknown conversion expression");
  391         assert(ConstantValue.isFloat());
  417     assert(FromType->isIntegralOrUnscopedEnumerationType());
  418     assert(ToType->isIntegralOrUnscopedEnumerationType());
  898       assert(E->hasPlaceholderType(BuiltinType::ARCUnbridgedCast));
 1049       assert(Old.getLookupKind() == LookupUsingDeclName);
 1251     assert((OldTarget != CFT_InvalidTarget) && "Unexpected invalid target.");
 1564   assert(QualType(FromFn, 0).isCanonical());
 1681         assert(isa<UnaryOperator>(From->IgnoreParens()) &&
 1683         assert(cast<UnaryOperator>(From->IgnoreParens())->getOpcode()
 1690         assert(cast<UnaryOperator>(From->IgnoreParens())->getOpcode() ==
 1699       assert(S.Context.hasSameType(
 2219   assert((FromPtr->getTypeClass() == Type::Pointer ||
 2965         assert(getLangOpts().MSVCCompat &&
 3053     assert(From->isNullPointerConstant(Context,
 3061   assert(ToPtrType && "No member pointer cast has a target type "
 3068   assert(FromClass->isRecordType() && "Pointer into non-class.");
 3069   assert(ToClass->isRecordType() && "Pointer into non-class.");
 3075   assert(DerivationOkay &&
 3338   assert(AllowExplicit || !AllowObjCConversionOnExplicit);
 4380   assert(!OrigT1->isReferenceType() &&
 4382   assert(!OrigT2->isReferenceType() && "T2 cannot be a reference type");
 4469   assert(T2->isRecordType() && "Can only find conversions of record types.");
 4568     assert(ICS.UserDefined.After.ReferenceBinding &&
 4598   assert(DeclType->isReferenceType() && "Reference init needs a reference");
 5070     assert(!Result.isEllipsis() &&
 5191     assert(FromClassification.isLValue());
 5194   assert(FromType->isRecordType());
 5484   assert(S.getLangOpts().CPlusPlus11 &&
 5629   assert(T->isIntegralOrEnumerationType() && "unexpected converted const type");
 5926     assert((!ConvTemplate || getLangOpts().CPlusPlus14) &&
 6090   assert(Proto && "Functions without a prototype cannot be overloaded");
 6091   assert(!Function->getDescribedFunctionTemplate() &&
 6324       assert(argExpr && "SelectBestMethod(): missing expression");
 6397     assert(!isa<CXXConstructorDecl>(Method) &&
 6399     assert(!Method->isStatic() && "Shouldn't have `this` for static methods!");
 6408       assert((MissingImplicitThis || MD->isStatic() ||
 6614         assert(cast<CXXMethodDecl>(FD)->isStatic());
 6645     assert(isa<CXXMethodDecl>(TD->getTemplatedDecl()) &&
 6677   assert(Proto && "Methods without a prototype cannot be overloaded");
 6678   assert(!isa<CXXConstructorDecl>(Method) &&
 6863   assert(Specialization && "Missing member function template specialization?");
 6864   assert(isa<CXXMethodDecl>(Specialization) &&
 6930   assert(Specialization && "Missing function template specialization?");
 7048   assert(!Conversion->getDescribedFunctionTemplate() &&
 7236   assert(isa<CXXConversionDecl>(FunctionTemplate->getTemplatedDecl()) &&
 7262   assert(Specialization && "Missing function template specialization?");
 7396     assert(!isa<CXXMethodDecl>(FD) &&
 7513       assert(ParamTys[ArgIdx] == Context.BoolTy &&
 7713   assert(PointerTy && "type was not a member pointer type!");
 7975     assert(ArithmeticTypes.size() <= ArithmeticTypesCap &&
 9271     assert(FirstDiff.first != Cand1CPUSpec->cpus_end() &&
 9316   assert(Cand2.Conversions.size() == NumArgs && "Overload candidate mismatch");
 9457     assert(Cand2IsInherited);
 9737       assert(Ctor->isCopyConstructor() &&
 9754       assert(isa<CXXConversionDecl>(Meth) && "expected conversion");
 9871   assert(OverloadedExpr->getType() == Context.OverloadTy);
 9918   assert(Conv.isBad());
 9919   assert(Cand->Function && "for now, candidate must be a function");
 9943     assert(FromExpr && "overload set argument came from implicit argument?");
10016     assert(CVR && "unexpected qualifiers mismatch");
10163     assert((Cand->FailureKind == ovl_fail_too_few_arguments) ||
10167     assert((Cand->FailureKind == ovl_fail_too_many_arguments) ||
10178   assert(isa<FunctionDecl>(D) &&
10251     assert(ParamD && "no parameter found for incomplete deduction result");
10260     assert(ParamD && "no parameter found for incomplete deduction result");
10271     assert(ParamD && "no parameter found for bad qualifiers deduction result");
10281     assert(S.Context.hasSameType(Param, NonCanonParam));
10296     assert(ParamD && "no parameter found for inconsistent deduction result");
10331     assert(ParamD && "no parameter found for invalid explicit arguments");
10582   assert(ES.getExpr() && "null expression should be handled before");
10708     assert(!Available);
10752   assert(Cand->Conversions.size() <= 2 && "builtin operator is not binary");
10854     assert(L->Viable == R->Viable);
10900         assert(L->Conversions.size() == R->Conversions.size());
10959   assert(!Cand->Viable);
10973     assert(ConvIdx != ConvCount && "no bad conversion in candidate");
11010     assert(ConvCount <= 3);
11123       assert(Cand->Viable &&
11240     assert(Cand->Specialization &&
11464     assert(S.isSameOrCompatibleFunctionType(
11551     assert(Ret || Matches.empty());
11610     assert(Matches.empty());
11662     assert(Matches.size() > 1);
11706   assert(AddressOfExpr->getType() == Context.OverloadTy);
11723     assert(Fn);
11786   assert(E->getType() == Context.OverloadTy && "SrcExpr must be an overload");
11870     assert(Specialization && "no specialization and no error?");
11906   assert(SrcExpr.get()->getType() == Context.OverloadTy);
11990       assert(!KnownValid && "Explicit template arguments?");
12012   assert(!KnownValid && "unhandled case in overloaded call candidate");
12043       assert(!(*I)->getDeclContext()->isRecord());
12044       assert(isa<UsingShadowDecl>(*I) ||
12046       assert((*I)->getUnderlyingDecl()->isFunctionOrFunctionTemplate());
12211     assert(SemaRef.IsBuildingRecoveryCallExpr == false);
12273   assert(!R.empty() && "lookup results empty despite recovery");
12316     assert(!ULE->getQualifier() && "qualified name with ADL");
12328     assert(getLangOpts().CPlusPlus && "ADL enabled in C");
12536   assert(Op != OO_None && "Invalid opcode for overloaded unary operator");
12771   assert(Args[0]->getObjectKind() != OK_ObjCProperty);
12992             assert(ChosenOp == OO_EqualEqual && "unexpected operator name");
12995             assert(ChosenOp == OO_Spaceship && "unexpected operator name");
13015           assert(ChosenOp == Op && "unexpected operator name");
13081       assert(Result.isInvalid() &&
13308   assert(MemExprE->getType() == Context.BoundMemberTy ||
13317     assert(op->getType() == Context.BoundMemberTy);
13318     assert(op->getOpcode() == BO_PtrMemD || op->getOpcode() == BO_PtrMemI);
13502   assert(Method && "Member call to something that isn't a method?");
13598   assert(Object.get()->getType()->isRecordType() &&
13733     assert(Conv == Best->FoundDecl.getDecl() &&
13870   assert(Base->getType()->isRecordType() &&
14148     assert(Context.hasSameType(ICE->getSubExpr()->getType(),
14151     assert(ICE->path_empty() && "fixing up hierarchy conversion?");
14187     assert(UnOp->getOpcode() == UO_AddrOf &&
14202         assert(isa<DeclRefExpr>(SubExpr)
14204         assert(cast<DeclRefExpr>(SubExpr)->getQualifier()
tools/clang/lib/Sema/SemaPseudoObject.cpp
   74       assert(refExpr->getBaseExpr());
   75       assert(refExpr->getKeyExpr());
   85       assert(refExpr->getBaseExpr());
   94       assert(refExpr->getBase());
   95       assert(refExpr->getIdx());
  128         assert(uop->getOpcode() == UO_Extension);
  139         assert(!gse->isResultDependent());
  164         assert(!ce->isConditionDependent());
  207       assert(ResultIndex == PseudoObjectExpr::NoResult);
  230       assert(ResultIndex == PseudoObjectExpr::NoResult);
  242       assert(!ty->isIncompleteType());
  243       assert(!ty->isDependentType());
  387   assert(ResultIndex == PseudoObjectExpr::NoResult);
  401     assert(index < Semantics.size() &&
  434   assert(BinaryOperator::isAssignmentOp(opcode));
  499   assert(UnaryOperator::isIncrementDecrementOp(opcode));
  584   assert(PRE->isClassReceiver() && "Invalid expression");
  618       assert(setter && "both setter and getter are null - cannot happen");
  709   assert(InstanceReceiver == nullptr);
  745     assert(InstanceReceiver || RefExpr->isSuperReceiver());
  793       assert(op && "successful assignment left argument invalid?");
  896   assert(BinaryOperator::isAssignmentOp(opcode));
  964     assert(RefExpr->isImplicitProperty());
 1004   assert(BinaryOperator::isAssignmentOp(opcode));
 1028   assert(InstanceBase == nullptr);
 1395   assert(InstanceBase);
 1463                       assert(Idx <= CallArgs.size());
 1567   assert(UnaryOperator::isIncrementDecrementOp(opcode));
 1672     assert(syntax->hasPlaceholderType(BuiltinType::PseudoObject));
tools/clang/lib/Sema/SemaStmt.cpp
  144       assert(Op->isRelationalOp());
  477   assert((LHSVal.isInvalid() || LHSVal.get()) && "missing LHS value");
  478   assert((DotDotDotLoc.isInvalid() ? RHSVal.isUnset()
  729   assert((Cond.isInvalid() || CondExpr) && "switch with no condition");
  736     assert(CondExpr->getType()->isIntegralOrEnumerationType() &&
  851   assert(SS == getCurFunction()->SwitchStack.back().getPointer() &&
  972       assert(!HasConstantCond ||
 1339   assert(Cond && "ActOnDoStmt(): missing expression");
 2110   assert(DS && "first part of for range not a decl stmt");
 2580     assert(!BeginExpr.isInvalid() && !EndExpr.isInvalid() &&
 3168         assert(!ResultType.isNull());
 3269     assert(AT && "lost auto type from lambda return type");
 3311   assert(!FnRetType.isNull());
 3322     assert(CurLambda && "unknown kind of captured scope");
 3471     assert(AT->isDeduced() && "should have deduced to dependent type");
 3753     assert(RetValExp || HasDependentReturnType);
 4082   assert(!Handlers.empty() &&
 4154   assert(TryBlock && Handler);
 4191   assert(FilterExpr && Block);
 4211   assert(Block);
 4270   assert(NumParams > 0 && "CapturedStmt requires context parameter");
 4302       assert(Cap.isVariableCapture() && "unknown kind of capture");
 4362       assert(!ContextIsFound &&
 4383   assert(ContextIsFound && "no null type for '__context' parameter");
tools/clang/lib/Sema/SemaStmtAsm.cpp
   60   assert(ExprUnderCast &&
  256   assert(AsmString->isAscii());
  260     assert(Literal->isAscii());
  343     assert(Literal->isAscii());
  440     assert(Literal->isAscii());
  491       assert(I != E && "Invalid operand number should have been caught in "
  560     assert(TiedTo < InputMatchedToOutput.size() && "TiedTo value out of range");
tools/clang/lib/Sema/SemaStmtAttr.cpp
  125     assert(OptionLoc && OptionLoc->Ident &&
  145       assert(ValueExpr && "Attribute must have a valid value expression.");
  155       assert(StateLoc && StateLoc->Ident && "Loop hint must have an argument");
  239     assert(Category < sizeof(HintAttrs) / sizeof(HintAttrs[0]));
tools/clang/lib/Sema/SemaTemplate.cpp
  136   assert(getLangOpts().CPlusPlus && "No template names in C!");
  229       assert(D && "unambiguous result is not a template name");
  254       assert(isa<ClassTemplateDecl>(TD) || isa<TemplateTemplateParmDecl>(TD) ||
  345     assert(!SS.isSet() && "ObjectType and scope specifier cannot coexist");
  348     assert((IsDependent || !ObjectType->isIncompleteType() ||
  738   assert(isa<TagDecl>(Instantiation) || isa<FunctionDecl>(Instantiation) ||
  782       assert(isa<TagDecl>(Instantiation) && "Must be a TagDecl!");
  800       assert(isa<VarDecl>(Instantiation) && "Must be a VarDecl!");
  831   assert(PrevDecl->isTemplateParameter() && "Not a template parameter");
  857   assert(Kind == Template &&
  859   assert(getAsTemplate().get().containsUnexpandedParameterPack() &&
  928   assert(TInfo && "template argument with no location");
  986   assert(S->isTemplateParamScope() &&
 1020     assert(DefaultTInfo && "expected source information for type");
 1180   assert(S->isTemplateParamScope() &&
 1258   assert(S->isTemplateParamScope() &&
 1358   assert(TemplateParams && TemplateParams->size() > 0 &&
 1360   assert(TUK != TUK_Reference && "Can only declare or define class templates");
 1368   assert(Kind != TTK_Enum && "can't build template of enumerated type");
 1553           assert(Tmpl && "original definition of a class template is not a "
 1647   assert(T->isDependentType() && "Class template type is not dependent?");
 1812     assert(FPTL && "no prototype for constructor declaration");
 1898     assert(NewParam->getDepth() == 0 && "unexpected template param depth");
 2276         assert(!NewTypeParm->hasDefaultArgument() &&
 2320         assert(!NewNonTypeParm->hasDefaultArgument() &&
 2363         assert(!NewTemplateParm->hasDefaultArgument() &&
 3040     assert(Converted.size() == 2 &&
 3046     assert(Index >= 0 && "the index used with __type_pack_element should be of "
 3340         assert(ICNT.isCanonical());
 3377     assert(isa<RecordType>(CanonType) &&
 3394   assert(TNK == TNK_Undeclared_template && "not an undeclared template name");
 3398   assert(ATN && "not an assumed template name");
 3415   assert(ATN && "not an assumed template name");
 3609     assert(Id && "templated class must have an identifier");
 3837   assert(D.getName().getKind() == UnqualifiedIdKind::IK_TemplateId &&
 4039   assert(Template && "A variable template id without template?");
 4186   assert(Decl && "No variable template specialization?");
 4228   assert(NamedConcept && "A concept template id without a template?");
 4282   assert(!R.isAmbiguous() && "ambiguous lookup when building templateid");
 4334   assert(TemplateArgs || TemplateKWLoc.isValid());
 5331       assert(!getExpandedPackSize(*Param) &&
 5730   assert(ArgInfo && "invalid TypeSourceInfo");
 5959         assert(FirstOpKind == UO_Deref);
 6306     assert((isa<FieldDecl>(DRE->getDecl()) ||
 6386   assert(!ParamType.hasQualifiers() &&
 6468       assert(ParamType->isNullPtrType());
 6475       assert(ParamType->isIntegralOrEnumerationType());
 6479       assert(ParamType->isMemberPointerType());
 6498       assert(ParamType->isPointerType() || ParamType->isReferenceType() ||
 6530       assert((VD || !ParamType->isReferenceType()) &&
 6532       assert((!VD || !ParamType->isNullPtrType()) &&
 6788     assert(ParamType->getPointeeType()->isIncompleteOrObjectType() &&
 6805     assert(ParamRefType->getPointeeType()->isIncompleteOrObjectType() &&
 6856   assert(ParamType->isMemberPointerType() && "Only pointers to members remain");
 6879     assert(Name.isDependent() && "Non-dependent template isn't a declaration?");
 6902     assert(isa<FunctionTemplateDecl>(Template) &&
 6963   assert(Arg.getKind() == TemplateArgument::Declaration &&
 7011       assert(!RefExpr.isInvalid() &&
 7068   assert(Arg.getKind() == TemplateArgument::Integral &&
 7678   assert(TUK != TUK_Reference && "References are not specializations");
 7764     assert(TUK == TUK_Friend && "should have a 'template<>' for this decl");
 7770   assert(Kind != TTK_Enum && "Invalid enum tag in class template spec!");
 8123   assert(PrevDiagLoc.isValid() &&
 8162     assert(
 8188       assert((PrevTSK == TSK_ImplicitInstantiation ||
 8514   assert(SpecInfo && "Function template specialization info missing?");
 8576       assert(
 8629   assert(!isa<TemplateDecl>(Member) && "Only for non-template members");
 8731   assert(MSInfo && "Member specialization info missing?");
 8759         assert(InstantiationFunction->getCanonicalDecl() ==
 8928   assert(A && "dllExportImportClassTemplateSpecialization called "
 8933   assert(S.DelayedDllExportClasses.empty() &&
 8960   assert(Kind != TTK_Enum &&
 9219       assert(Def == Specialization &&
 9262   assert(!IsDependent && "explicit instantiation of dependent name not yet handled");
 9268   assert(!Tag->isEnum() && "shouldn't see enumerations here");
 9310     assert(MSInfo && "No member specialization information?");
 9593             assert(!NonTemplateMatch && "Multiple NonTemplateMatches");
 9768   assert(Name && "Expected a name in a dependent tag");
 9869     assert(DTN && "dependent template has non-dependent name?");
 9870     assert(DTN->getQualifier() == SS.getScopeRep());
 9979     assert(QualifierLoc.getNestedNameSpecifier()->isDependent());
tools/clang/lib/Sema/SemaTemplateDeduction.cpp
  300     assert(!X.wasDeducedFromArrayBound());
  379   assert(NTTP->getDepth() == Info.getDeducedDepth() &&
  548   assert(Arg.isCanonical() && "Argument type must be canonical");
  739     assert(!Packs.empty() && "Pack expansion without unexpanded packs?");
 1368     assert(TemplateTypeParm->getDepth() == Info.getDeducedDepth() &&
 1370     assert(Arg != S.Context.OverloadTy && "Unresolved overloaded function");
 1639       assert(NTTP->getDepth() == Info.getDeducedDepth() &&
 1704         assert(NTTP->getDepth() == Info.getDeducedDepth() &&
 1741       assert(isa<TemplateSpecializationType>(Param) &&
 1837           assert(Base.getType()->isRecordType() &&
 2247   assert(ArgIdx == Args.size() - 1 && "Pack not at the end of argument list?");
 2541       assert(InnerArg.getKind() != TemplateArgument::Pack &&
 2657       assert(isa<ClassTemplatePartialSpecializationDecl>(Template) ||
 3052   assert(Proto && "Function template does not have a prototype?");
 3371   assert(Specialization->getPrimaryTemplate()->getCanonicalDecl() ==
 4182     assert(!A->isReferenceType() && "Reference types were handled above");
 4314       assert(isa<TemplateTypeParmType>(Replacement) &&
 4434     assert(!Result.isNull() && "substituting DependentTy can't fail");
 4487   assert(!FuncParam.isNull() &&
 4503       assert(!Result.isNull() && "substituting DependentTy can't fail");
 4574     assert((bool)InitList == OriginalArg.DecomposedParam &&
 4633   assert(FD->getReturnType()->isUndeducedType());
 4659     assert(!CallOp->getReturnType()->isUndeducedType() &&
 4668       assert(FD->getReturnType()->getAs<BlockPointerType>());
 4724   assert(Proto1 && Proto2 && "Function templates must have prototypes");
 4988   assert(BestTemplate && "Not a function template specialization?");
 4992     assert(Challenger && "Not a function template specialization?");
 5148   assert(PS1->getSpecializedTemplate() == PS2->getSpecializedTemplate() &&
 5229         assert(Arg.pack_size() == 1 && Arg.pack_begin()->isPackExpansion());
tools/clang/lib/Sema/SemaTemplateInstantiate.cpp
   85       assert(Spec->getSpecializedTemplate() && "No variable template?");
  130       assert(Spec->getSpecializedTemplate() && "No class template?");
  148         assert(Function->getPrimaryTemplate() && "No function template?");
  288   assert(
  400     assert(NonInstantiationEntries > 0);
  407   assert(CodeSynthesisContexts.size() >=
  445   assert(SemaRef.NonInstantiationEntries <=
  758       assert(Active->DeductionInfo && "Missing deduction info pointer");
  891       assert(NewDecls.size() == 1 &&
 1037   assert(S.ArgumentPackSubstitutionIndex >= 0);
 1038   assert(S.ArgumentPackSubstitutionIndex < (int)Arg.pack_size());
 1062         assert(Arg.getKind() == TemplateArgument::Pack &&
 1068       assert(!Template.isNull() && Template.getAsTemplateDecl() &&
 1103         assert(Arg.getKind() == TemplateArgument::Pack &&
 1201         assert(Arg.getKind() == TemplateArgument::Pack &&
 1215       assert(!Template.isNull() && "Null template template argument");
 1216       assert(!Template.getAsQualifiedTemplateName() &&
 1267       assert(Arg.pack_size() == 1 && Arg.pack_begin()->isPackExpansion() &&
 1271     assert(Arg.getKind() == TemplateArgument::Expression &&
 1277     assert(Arg.getKind() == TemplateArgument::Pack &&
 1363     assert(!type.isNull() && "type substitution failed for param type");
 1364     assert(!type->isDependentType() && "param type still dependent");
 1443   assert(Found && "no instantiation for parameter pack");
 1492   assert(!cast<FunctionDecl>(E->getParam()->getDeclContext())->
 1543       assert(Arg.getKind() == TemplateArgument::Pack &&
 1561     assert(Arg.getKind() == TemplateArgument::Type &&
 1652   assert(!CodeSynthesisContexts.empty() &&
 1669   assert(!CodeSynthesisContexts.empty() &&
 1699   assert(!CodeSynthesisContexts.empty() &&
 1744   assert(!CodeSynthesisContexts.empty() &&
 1784   assert(ESI.Type != EST_Uninstantiated);
 1922   assert(!CodeSynthesisContexts.empty() &&
 2111   assert(!Inst.isAlreadyInstantiating() && "should have been caught by caller");
 2192           assert(MSInfo && "no spec info for member enum specialization");
 2232     assert(CurrentInstantiationScope == Instantiator.getStartingScope());
 2399   assert(Instantiation->getInClassInitStyle() ==
 2444   assert((!Init || !isa<ParenListExpr>(Init)) && "call-style init in class");
 2662   assert(
 2678         assert(MSInfo && "No member specialization information?");
 2722         assert(MSInfo && "No member specialization information?");
 2765       assert(MSInfo && "No member specialization information?");
 2791       assert(Pattern && "Missing instantiated-from-template information");
 2827       assert(MSInfo && "No member specialization information?");
 2844       assert(Pattern && "Missing instantiated-from-template information");
 3039   assert(isa<LabelDecl>(D) && "declaration not instantiated in this scope");
 3052       assert(Current->LocalDecls.find(D) == Current->LocalDecls.end() &&
 3060     assert(Stored.get<Decl *>() == Inst && "Already instantiated this local");
 3076     assert(Current->LocalDecls.find(D) == Current->LocalDecls.end() &&
 3090   assert((!PartiallySubstitutedPack || PartiallySubstitutedPack == Pack) &&
 3092   assert((!PartiallySubstitutedPack
tools/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
   47   assert((NewDecl->getFriendObjectKind() ||
  114   assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
  618     assert(!TmplAttr->isPackExpansion());
  756       assert(!newTag->hasNameForLinkage());
 1122   assert(ND && "friend decl must be a decl or a type!");
 1186       assert(!D->getIntegerType()->isDependentType()
 1442   assert(!(isFriend && Owner->isDependentContext()));
 1520   assert(D->getTemplatedDecl()->isStaticDataMember() &&
 1581   assert(D->isStaticDataMember() &&
 1588   assert(!Found.empty() && "Instantiation found nothing?");
 1591   assert(InstVarTemplate && "Instantiation did not find a variable template?");
 1630   assert(InstTemplate &&
 1863     assert(D->getDeclContext()->isFileContext());
 1933     assert(isFriend && "non-friend has dependent specialization info?");
 2252     assert(isFriend && "non-friend has dependent specialization info?");
 2404   assert(D->getTypeForDecl()->isTemplateTypeParmType());
 2871     assert(!RetainExpansion &&
 2985     assert(isa<DeclRefExpr>(Var) && "threadprivate arg is not a DeclRefExpr");
 3002     assert(isa<DeclRefExpr>(Var) && "allocate arg is not a DeclRefExpr");
 3249   assert(ClassTemplate->getDeclContext()->isRecord() &&
 3382   assert(VarTemplate &&
 3816   assert(OldTInfo && "substituting function without type source info");
 3817   assert(Params.empty() && "parameter vector is non-empty at start");
 3923       assert(FParamIdx < Function->getNumParams());
 4043       assert(FunTmpl->getTemplatedDecl() == Tmpl &&
 4054   assert(Proto && "Function template without prototype?");
 4078       assert(NewProto && "Template instantiation without function prototype?");
 4153   assert(S.Context.getTargetInfo().getCXXABI().isMicrosoft() &&
 4203   assert(PatternDecl && "instantiating a non-template");
 4225       assert(!Recursive);
 4279     assert(LPTIter != LateParsedTemplateMap.end() &&
 4286   assert((Pattern || PatternDecl->isDefaulted() ||
 4457   assert(PatternDecl->isThisDeclarationADefinition() &&
 4710   assert(PatternDecl && "no pattern for templated variable");
 4720     assert(!TemplateSpecializationType::anyDependentTemplateArguments(
 4770     assert(Var->isStaticDataMember() && PatternDecl->isStaticDataMember() &&
 4953       assert(ShouldExpand && "Partial instantiation of base initializer?");
 5188   assert(Instance->isStaticDataMember());
 5343         assert(PackIdx != -1 &&
 5386     assert(isa<LabelDecl>(D));
 5389     assert(Inst && "Failed to instantiate label??");
 5458           assert(SubstRecord && "class template id not a class type?");
 5503         assert(Tag && "type of non-dependent record is not a RecordType");
 5574         assert(Spec->getTemplateSpecializationKind() ==
 5632     assert((Var->isStaticDataMember() ||
tools/clang/lib/Sema/SemaTemplateVariadic.cpp
  393   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  407   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  423   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  460   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  474   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  487   assert(!Unexpanded.empty() && "Unable to find unexpanded parameter packs");
  813         assert((!Result || *Result == Size) && "inconsistent pack sizes");
  828     assert((!Result || *Result == Size) && "inconsistent pack sizes");
  910         assert(!ParamTy.isNull() && "Couldn't parse type?");
 1029   assert(Argument.isPackExpansion());
 1085   assert(Arg.containsUnexpandedParameterPack());
 1190     assert(Pack && "fold expression with neither LHS nor RHS");
tools/clang/lib/Sema/SemaType.cpp
  216       assert(idx <= declarator.getNumTypeObjects());
  305       assert(FoundLoc != LocsForMacros.end() &&
  331       assert(hasSavedAttrs);
  376   assert(attr.getKind() == ParsedAttr::AT_ObjCOwnership);
  392   assert(i <= declarator.getNumTypeObjects());
  678   assert(!state.getDeclarator().getAttributes().empty() &&
  770   assert(state.getCurrentChunkIndex() == declarator.getNumTypeObjects() - 1);
  942         assert(anyPackExpansions && "Too many arguments?");
  980         assert(anyPackExpansions && "Too many arguments?");
 1166     assert(TypeArgInfo && "No type source info?");
 1198       assert(OTPTL.getNumProtocols() == Protocols.size());
 1213     assert(ObjCObjectTL.getNumTypeArgs() == ActualTypeArgInfos.size());
 1225     assert(ObjCObjectTL.getNumProtocols() == Protocols.size());
 1284       assert(DS.getTypeSpecSign() == DeclSpec::TSS_unsigned &&
 1298       assert(DS.getTypeSpecSign() == DeclSpec::TSS_unsigned &&
 1307       assert(DS.getTypeSpecSign() == DeclSpec::TSS_unspecified &&
 1312       assert(DS.getTypeSpecSign() == DeclSpec::TSS_unspecified &&
 1317       assert(DS.getTypeSpecSign() == DeclSpec::TSS_unspecified &&
 1528     assert(DS.getTypeSpecWidth() == 0 && DS.getTypeSpecComplex() == 0 &&
 1542     assert(DS.getTypeSpecWidth() == 0 && DS.getTypeSpecComplex() == 0 &&
 1556     assert(!Result.isNull() && "Didn't get a type for typeof?");
 1565     assert(E && "Didn't get an expression for typeof?");
 1576     assert(E && "Didn't get an expression for decltype?");
 1587     assert(!Result.isNull() && "Didn't get a type for __underlying_type?");
 1616     assert(!Result.isNull() && "Didn't get a type for _Atomic?");
 1668     assert(typeSize > 0 && "type size for vector must be greater than 0 bits");
 1756   assert(!Result.isNull() && "This function should not return a null type");
 1908   assert(implicitLifetime && "didn't infer any lifetime!");
 2009   assert(!T->isObjCObjectType() && "Should build ObjCObjectPointerType");
 2035   assert(Context.getCanonicalType(T) != Context.OverloadTy &&
 2492   assert(EPI.ExtParameterInfos && "shouldn't get here without param infos");
 2984         assert(LSI && "No LambdaScopeInfo on the stack!");
 3126         assert(isa<DeducedTemplateSpecializationType>(Deduced) &&
 3220   assert(!T.isNull() && "This function should not return a null type");
 3229   assert(FTI.isAmbiguous && "no direct-initializer / function ambiguity");
 3326   assert(Paren.Kind == DeclaratorChunk::Paren &&
 3446   assert(D.getTypeObject(ChunkIndex).Kind == DeclaratorChunk::Function);
 3493       assert(D.isFunctionDeclarator());
 3803   assert(PointerLoc.isValid());
 3839   assert(PointerLoc.isValid());
 4811           assert(!ParamTy.isNull() && "Couldn't parse type?");
 5078   assert(!T.isNull() && "T must not be null after this point");
 5082     assert(FnTy && "Why oh why is there not a FunctionProtoType here?");
 5134         assert(Chunk.Kind == DeclaratorChunk::Function);
 5273   assert(!T.isNull() && "T must not be null at the end of this function");
 5392     assert(chunk.Kind == DeclaratorChunk::Array ||
 5480         assert(TL.getRAngleLoc() == OldTL.castAs<TemplateSpecializationTypeLoc>().getRAngleLoc());
 5485       assert(DS.getTypeSpecType() == DeclSpec::TST_typeofExpr);
 5490       assert(DS.getTypeSpecType() == DeclSpec::TST_typeofType);
 5493       assert(DS.getRepAsType());
 5500       assert(DS.getTypeSpecType() == DeclSpec::TST_underlyingType);
 5503       assert(DS.getRepAsType());
 5540       assert(DS.getTypeSpecType() == TST_typename);
 5543       assert(TInfo);
 5548       assert(DS.getTypeSpecType() == TST_typename);
 5551       assert(TInfo);
 5567         assert(TInfo);
 5615       assert(Chunk.Kind == DeclaratorChunk::BlockPointer);
 5619       assert(Chunk.Kind == DeclaratorChunk::Pointer);
 5623       assert(Chunk.Kind == DeclaratorChunk::Pointer);
 5627       assert(Chunk.Kind == DeclaratorChunk::MemberPointer);
 5638         assert(isa<DependentNameType>(ClsTy) && "Unexpected TypeLoc");
 5672       assert(Chunk.Kind == DeclaratorChunk::Reference);
 5678       assert(Chunk.Kind == DeclaratorChunk::Reference);
 5679       assert(!Chunk.Ref.LValueRef);
 5683       assert(Chunk.Kind == DeclaratorChunk::Array);
 5689       assert(Chunk.Kind == DeclaratorChunk::Function);
 5703       assert(Chunk.Kind == DeclaratorChunk::Paren);
 5708       assert(Chunk.Kind == DeclaratorChunk::Pipe);
 5821     assert(TL.getFullDataSize() == CurrTL.getFullDataSize());
 5838   assert(LocT->getTypeClass() != T->getTypeClass() &&
 5853   assert(D.getIdentifier() == nullptr &&
 6689       assert(attr.getAttributeSpellingListIndex() == 0 &&
 6791   assert(!Attr.isInvalid());
 7748             assert(Var->getTemplateSpecializationKind() ==
 7908   assert(D && "missing definition for pattern of instantiated definition");
 8089         assert(MSI && "Missing member specialization information?");
 8185   assert(!T->isDependentType() && "type should not be dependent");
 8252     assert(Dtor && "class has literal fields and bases but no dtor?");
 8298   assert(!E->hasPlaceholderType() && "unexpected placeholder");
 8383   assert(!E->hasPlaceholderType() && "unexpected placeholder");
 8416         assert(ED && "EnumType has no EnumDecl");
 8421         assert(!Underlying.isNull());
tools/clang/lib/Sema/TreeTransform.h
  459     assert(New.size() == 1 &&
 2307       assert(Member->getType()->isRecordType() &&
 3230     assert(!Lookup.empty() && "No __builtin_shufflevector?");
 3520     assert(NewArgs.empty() &&
 3548       assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
 3737         assert(!TL.getType().hasLocalQualifiers() &&
 3851     assert(Template && "qualified template name must refer to a template");
 4153       assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
 4474   assert(!getDerived().AlreadyTransformed(T));
 4740     assert(isa<AdjustedType>(MPT->getPointeeType()));
 5163       assert(OldParm->getFunctionScopeIndex() == i);
 5176         assert(Unexpanded.size() > 0 && "Could not find parameter packs!");
 5361         assert(parm->getFunctionScopeIndex() == i);
 5480   assert(ESI.Type != EST_Uninstantiated && ESI.Type != EST_Unevaluated);
 5515       assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
 6517       assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
 7183   assert(FD && ScopeInfo && !ScopeInfo->CoroutinePromise &&
 7213   assert(isa<Expr>(InitSuspend.get()) && isa<Expr>(FinalSuspend.get()));
 7224   assert(ReturnObject && "the return object is expected to be valid");
 7240       assert(!Promise->getType()->isDependentType() &&
 7242       assert(!S->getFallthroughHandler() && !S->getExceptionHandler() &&
 7271     assert(S->getAllocate() && S->getDeallocate() &&
 7283     assert(S->getResultDecl() && "ResultDecl must already be built");
 9509   assert((!E->getSourceExpr() || getDerived().AlreadyTransformed(E->getType())) &&
10038     assert(D.isArrayRangeDesignator() && "New kind of designator?");
10240     assert(E->getNumArgs() >= 1 && "Object call is missing arguments");
11196   assert(E->getQualifierLoc());
11602     assert(C->capturesVariable() && "unexpected kind of lambda capture");
11728     assert(C->capturesVariable() && "unexpected kind of lambda capture");
11729     assert(!E->isInitCapture(C) && "implicit init-capture?");
12158   assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
12338       assert(!Unexpanded.empty() && "Pack expansion without parameter packs?");
12553   assert(E->getReceiverKind() == ObjCMessageExpr::Instance &&
12790       assert(blockScope->CaptureMap.count(newCapture));
12792     assert(oldBlock->capturesCXXThis() == blockScope->isCXXThisCaptured());
13042   assert(D && "no decl found");
13071         assert(getSema().Context.hasSameType(ThisT, T) &&
13076     assert(Using->hasTypename() &&
13080     assert(++Using->shadow_begin() == Using->shadow_end());
13083     assert(isa<UnresolvedUsingTypenameDecl>(D) &&
tools/clang/lib/Sema/TypeLocBuilder.cpp
   45   assert(NewCapacity > Capacity);
   65   assert(TLast == LastTy &&
   70   assert(LocalAlignment <= BufferMaxAlignment && "Unexpected alignment");
   97           assert(LocalSize % 8 == 4);
  103         assert(Padding == 4);
  108           assert(LocalSize % 8 == 4);
  131           assert(LocalSize % 8 == 4);
  137         assert(Padding == 4);
  142           assert(LocalSize % 8 == 4);
  154     assert(LocalSize == 0);
  159   assert(Capacity - Index == TypeLoc::getFullDataSizeForType(T) &&
tools/clang/lib/Sema/TypeLocBuilder.h
  103     assert(T == LastTy && "type doesn't match last type pushed!");
  116     assert(T == LastTy && "type doesn't match last type pushed!");
  140     assert(LastTy == T && "type doesn't match last type pushed!");
tools/clang/lib/Serialization/ASTCommon.h
   60   assert(!T.hasLocalQualifiers());
tools/clang/lib/Serialization/ASTReader.cpp
  548   assert(!ModuleName.empty() && "diagnostic options read before module name");
  551   assert(M && "missing module");
  566   assert(ModuleMgr.size() >= 1 && "what ASTFile is this then");
  899   assert(n >= 2 && d[n-1] == '\0');
  973   assert(Bits == 0 && "Extra bits in the identifier?");
  984     assert((II->hasRevertedBuiltin() ||
  988   assert(II->isExtensionToken() == ExtensionToken &&
  993   assert(II->isCPlusPlusOperatorKeyword() == CPlusPlusOperatorKeyword &&
 1148   assert(Offset != 0);
 1176   assert(!isa<TranslationUnitDecl>(DC) &&
 1198   assert(Offset != 0);
 1285     assert(FID >= 0 && "Serialized line entries for non-local file.");
 1291     assert(NumEntries && "no line entries for file ID");
 1387   assert(OriginalDir != CurrDir &&
 1394   assert(path::is_absolute(OriginalDir));
 1535       assert(F->FileSortedDecls && "FILE_SORTED_DECLS not encountered yet ?");
 1616     assert(SourceMgr.getMainFileID().isValid() && "missing main file");
 1804   assert(I != M.PreprocessedEntityRemap.end()
 1898   assert((End - d) % 4 == 0 &&
 1933   assert(NumCurrentElementsDeserializing > 0 &&"Missing deserialization guard");
 2166         assert(Macro && "missing definition for overridden macro");
 2234     assert(static_cast<InputFileRecordTypes>(Maybe.get()) == INPUT_FILE &&
 2241   assert(Record[0] == ID && "Bogus stored ID or offset");
 2255   assert(Entry.Kind == llvm::BitstreamEntry::Record &&
 2260     assert(static_cast<InputFileRecordTypes>(Maybe.get()) == INPUT_FILE_HASH &&
 2876       assert(!F.ModuleName.empty() &&
 3390       assert((F.SLocEntryBaseOffset & (1U << 31U)) == 0);
 3480       assert(Blob.size() % sizeof(PPEntityOffset) == 0);
 3512       assert(Blob.size() % sizeof(PPSkippedRange) == 0);
 3776   assert(!F.ModuleOffsetMap.empty() && "no module offset map to read");
 3872   assert(!F.ModuleName.empty() &&
 3904     assert(M->Name == F.ModuleName && "found module with different name");
 3909       assert(ModMap && "found module is missing module map file");
 3910       assert((ImportedBy || F.Kind == MK_ImplicitModule) &&
 3993   assert(Owner->NameVisibility != Module::Hidden && "nothing to make visible?");
 4036       assert(HiddenNamesMap.find(Mod) == HiddenNamesMap.end() &&
 4085     assert(!Result.first);
 4484   assert(M && "Missing module file");
 4798   assert(ContextObj && "no context to initialize");
 4870           assert(Tag && "Invalid sigjmp_buf type in AST file");
 4906           assert(Tag && "Invalid ucontext_t type in AST file");
 4917     assert(CUDASpecialDeclRefs.size() == 1 && "More decl refs than expected!");
 5840   assert(I != GlobalPreprocessedEntityMap.end() &&
 5867   assert(I != GlobalSkippedRangeMap.end() &&
 5871   assert(LocalIndex < M->NumPreprocessedSkippedRanges);
 5875   assert(Range.isValid());
 6037   assert(SLocMapI != GlobalSLocOffsetMap.end() &&
 6089   assert(!SourceMgr.isBeforeInTranslationUnit(Range.getEnd(),Range.getBegin()));
 6182       assert(Idx + Size * 2 <= Record.size() &&
 6216       assert(Record[1] == 0 &&
 6219       assert(Idx < Record.size() &&
 6235       assert(F.OriginalSourceFileID.isValid());
 6253       assert(Idx < Record.size() &&
 6257       assert(IDAndOffset.first.isValid() && "invalid FileID for transition");
 6258       assert(IDAndOffset.second == 0 && "not a start location for a FileID");
 6276     assert(Idx < Record.size() &&
 6304   assert(I != GlobalTypeMap.end() && "Corrupted global type map");
 6316   assert(ContextObj && "reading type with no AST context");
 6539     assert(Idx == Record.size());
 7259   assert(ContextObj && "reading type with no AST context");
 7493     assert(!T.isNull() && "Unknown predefined type");
 7498   assert(Index < TypesLoaded.size() && "Type index out-of-range");
 7530   assert(I != F.TypeRemap.end() && "Invalid index into type index remap");
 7628         assert(II && "non-identifier name in C?");
 7688   assert(ContextObj && "reading base specifiers with no AST context");
 7739   assert(I != F.DeclRemap.end() && "Invalid index into decl index remap");
 7758   assert(I != GlobalDeclMap.end() && "Corrupted global declaration map");
 7838   assert(ContextObj && "reading decl with no AST context");
 7854     assert(0 && "declaration ID out-of-range for AST file");
 7869     assert(0 && "declaration ID out-of-range for AST file");
 7889   assert(I != GlobalDeclMap.end() && "Corrupted global declaration map");
 7926   assert(NumCurrentElementsDeserializing == 0 &&
 7938     assert(LexicalDecls.size() % 2 == 0 && "expected an even number of entries");
 7956         assert(D->getKind() == K && "wrong kind for lexical decl");
 8052   assert(DC->hasExternalVisibleStorage() && DC == DC->getPrimaryContext() &&
 8081   assert(It != Lookups.end() &&
 8111   assert(ImplD && Consumer);
 8298     assert(FPPragmaOptions.size() == 1 && "Wrong number of FP_PRAGMA_OPTIONS");
 8310   assert(SemaObj && "no Sema to update");
 8315     assert(SemaDeclRefs.size() % 3 == 0);
 8348       assert(PragmaPackStack.front().Value == SemaObj->PackStack.DefaultValue &&
 8361       assert(*PragmaPackCurrentValue == SemaObj->PackStack.DefaultValue &&
 8798     assert(F && "No module");
 8817   assert(ID && "Non-zero identifier ID required");
 8818   assert(ID <= IdentifiersLoaded.size() && "identifier ID out of range");
 8885     assert(I != GlobalIdentifierMap.end() && "Corrupted global identifier map");
 8921   assert(I != M.IdentifierRemap.end()
 8940     assert(I != GlobalMacroMap.end() && "Corrupted global macro map");
 8962   assert(I != M.MacroRemap.end() && "Invalid index into macro index remap");
 8977   assert(I != M.SubmoduleRemap.end()
 8985     assert(GlobalID == 0 && "Unhandled global submodule ID");
 9014     assert(IndexFromEnd && "got reference to unknown module file");
 9032   assert(I != PCHModules.end() && "emitting reference to unknown file");
 9077     assert(I != GlobalSelectorMap.end() && "Corrupted global selector map");
 9109   assert(I != M.SelectorRemap.end()
 9400   assert(NumInitializers && "wrote ctor initializers but have no inits");
 9725   assert((*CurrSwitchCaseStmts)[ID] == nullptr &&
 9732   assert((*CurrSwitchCaseStmts)[ID] != nullptr && "No SwitchCase with this ID");
 9818   assert(NumUserInputs <= NumInputs);
 9952   assert(PendingFakeDefinitionData.empty() &&
 9969           assert((R == D) ==
10210     assert(S);
10217     assert(D);
10231         assert(TPL);
10259       assert(FirstDD && SecondDD && "Definitions without DefinitionData");
10373       assert(!FirstTemplate == !SecondTemplate &&
10398         assert(FirstTemplateHashes.size() == SecondTemplateHashes.size() &&
10425           assert(FirstDecl->getKind() == SecondDecl->getKind() &&
10436             assert((!FirstNameEmpty || !SecondNameEmpty) &&
10472             assert(HasFirstDefaultArgument && HasSecondDefaultArgument &&
10504             assert(HasFirstDefaultArgument && HasSecondDefaultArgument &&
10537             assert(HasFirstDefaultArgument && HasSecondDefaultArgument &&
10595         assert(D && "valid Decl required");
10711       assert(FirstDiffType == SecondDiffType);
10805         assert((FirstStr || SecondStr) && "Both messages cannot be empty");
10859         assert(getContext().hasSameType(FirstField->getType(),
11438           assert(ComputeQualTypeODRHash(FirstFriendType) !=
11836       assert(FirstFunction->param_size() == SecondFunction->param_size() &&
11845         assert(getContext().hasSameType(FirstParam->getType(),
11919         assert(ComputeSubDeclODRHash(FirstParam) ==
11939     assert(Diagnosed && "Unable to emit ODR diagnostic.");
11972         assert(isa<EnumConstantDecl>(D) && "Unexpected Decl kind");
12127     assert(Diagnosed && "Unable to emit ODR diagnostic.");
12137   assert(NumCurrentElementsDeserializing &&
12473   assert(C && "Unknown OMPClause type");
tools/clang/lib/Serialization/ASTReaderDecl.cpp
  105       assert(LocalOffset < Loc.Offset && "offset point after current record");
  970         assert(Reader.getContext().getLangOpts().Modules &&
 1351   assert(FD->ChainingSize >= 2 && "Anonymous chaining must be >= 2");
 1449     assert(scopeDepth == 0);
 1681   assert(Data.Definition && "Data.Definition should be already set!");
 1723   assert(D->DefinitionData &&
 1734     assert(Reader.Lookups.find(MergeDD.Definition) == Reader.Lookups.end() &&
 1743     assert(!DD.IsLambda && !MergeDD.IsLambda && "faked up lambda definition?");
 2032       assert(RTD->getKind() == D->getKind() &&
 2500     assert(DCanon->getGlobalID() == Redecl.getFirstID() &&
 2722   assert(New && "Unable to decode attribute?");
 2743   assert(!DeclsLoaded[Index] && "Decl loaded twice?");
 2794   assert(I != GlobalDeclMap.end() && "Corrupted global declaration map");
 2805   assert(I != GlobalBitOffsetsMap.end() && "Corrupted global bit offsets map");
 2937   assert(X->getDeclName() == Y->getDeclName() && "Declaration name mismatch!");
 3003       assert(TAX && TAY && "Multiversion Function without target attribute");
 3390   assert(D);
 3521   assert(FromTP->size() == ToTP->size() && "merged mismatched templates?");
 3539   assert(D && Previous);
 3576   assert(D && Latest);
 3892   assert(D && "Unknown declaration reading AST file");
 3911   assert(Record.getIdx() == Record.size());
 3936   assert(Consumer);
 3999         assert(MaybeRecCode.get() == DECL_UPDATES &&
 4021   assert((PendingLazySpecializationIDs.empty() || isa<ClassTemplateDecl>(D) ||
 4064   assert(M && "imported decl from no module file");
 4081     assert(MaybeRecCode.get() == LOCAL_REDECLARATIONS &&
 4248       assert(MD && "couldn't read decl from update record");
 4359       assert(Record.getIdx() == Record.size() && "lazy body must be last");
 4524       assert(Attrs.size() == 1);
tools/clang/lib/Serialization/ASTReaderStmt.cpp
  151   assert(Record.getIdx() == NumStmtFields && "Incorrect statement field count");
  212   assert(NumAttrs == S->AttributedStmtBits.NumAttrs);
  213   assert(NumAttrs == Attrs.size());
  455   assert(Record.peekInt() == S->NumParams);
  530   assert(Record.getIdx() == NumExprFields &&
  625   assert((NumConcatenated == E->getNumConcatenated()) &&
  627   assert((Length == E->getLength()) && "Wrong Length!");
  628   assert((CharByteWidth == E->getCharByteWidth()) && "Wrong character width!");
  635   assert((CharByteWidth ==
  667   assert((NumExprs == E->getNumExprs()) && "Wrong NumExprs!");
  684   assert(E->getNumComponents() == Record.peekInt());
  686   assert(E->getNumExpressions() == Record.peekInt());
  774   assert((NumArgs == E->getNumArgs()) && "Wrong NumArgs!");
  855   assert(NumBaseSpecs == E->path_size());
  965   assert(NumSubExprs == E->getNumSubExprs() && "Wrong number of subexprs");
 1114   assert(NumAssocs == E->getNumAssocs() && "Wrong NumAssocs!");
 1135   assert(numSemanticExprs + 1 == E->PseudoObjectExprBits.NumSubExprs);
 1178   assert(NumElements == E->getNumElements() && "Wrong number of elements");
 1189   assert(NumElements == E->getNumElements() && "Wrong number of elements");
 1191   assert(HasPackExpansions == E->HasPackExpansions &&"Pack expansion mismatch");
 1277   assert(Record.peekInt() == E->getNumArgs());
 1302   assert(Kind == E->getReceiverKind());
 1351   assert(Record.peekInt() == S->getNumCatchStmts());
 1403   assert(Record.peekInt() == S->getNumHandlers() && "NumStmtFields is wrong ?");
 1454   assert((NumArgs == E->getNumArgs()) && "Wrong NumArgs!");
 1486   assert(NumCaptures == E->NumCaptures);(void)NumCaptures;
 1625   assert((IsArray == E->isArray()) && "Wrong IsArray!");
 1626   assert((HasInit == E->hasInitializer()) && "Wrong HasInit!");
 1627   assert((NumPlacementArgs == E->getNumPlacementArgs()) &&
 1629   assert((IsParenTypeId == E->isParenTypeId()) && "Wrong IsParenTypeId!");
 1682   assert(NumObjects == E->getNumObjects());
 1699   assert((HasTemplateKWAndArgsInfo == E->hasTemplateKWAndArgsInfo()) &&
 1701   assert(
 1710   assert((NumTemplateArgs == E->getNumTemplateArgs()) &&
 1742   assert(Record.peekInt() == E->arg_size() &&
 1757   assert((E->getNumDecls() == NumResults) && "Wrong NumResults!");
 1758   assert((E->hasTemplateKWAndArgsInfo() == HasTemplateKWAndArgsInfo) &&
 1766     assert((E->getNumTemplateArgs() == NumTemplateArgs) &&
 1860     assert(E->Length == NumPartialArgs);
 2489       assert(StmtEntries.find(Record[0]) != StmtEntries.end() &&
 3554     assert(Record.getIdx() == Record.size() &&
 3559   assert(StmtStack.size() > PrevNumStmts && "Read too many sub-stmts!");
 3560   assert(StmtStack.size() == PrevNumStmts + 1 && "Extra expressions on stack!");
tools/clang/lib/Serialization/ASTWriter.cpp
  341   assert(!T->isCanonicalUnqualified() && "Invalid typedef ?");
  390   assert(!T->isBeingDefined() &&
 1362   assert(Filename && "No file name to adjust?");
 1482   assert((!WritingModule || isysroot.empty()) &&
 1806     assert(&SourceMgr.getSLocEntry(FileID::get(I)) == SLoc);
 2081           assert((Value >> 2) == ModID && "overflow in header module info");
 2093       assert(Out.tell() - Start == DataLen && "Wrong data length");
 2299     assert(&SourceMgr.getSLocEntry(FID) == SLoc);
 2328         assert(Content->OrigEntry == Content->ContentsEntry &&
 2332         assert(InputFileIDs[Content->OrigEntry] != 0 && "Missed file entry");
 2506     assert(!IsModule);
 2622       assert(0 && "Loaded MacroInfo entered MacroInfosToEmit ?");
 2777     assert(PreprocessedEntityOffsets.size() == NumPreprocessingRecords);
 2838   assert((ID || !Mod) &&
 2962       assert(SubmoduleIDs[Mod->Parent] && "Submodule parent not written?");
 3094   assert((NextSubmoduleID - FirstSubmoduleID ==
 3125     assert(Flags == EncodeDiagStateFlags(State) &&
 3163     assert(!Loc.isInvalid() && "start loc for valid FileID is invalid");
 3199   assert(Idx.getIndex() >= FirstTypeID && "Re-writing a type from a prior AST");
 3378     assert((Start >> 32) == 0 && "Selector key offset too large");
 3409     assert(InstanceBits < 4);
 3416     assert(FactoryBits < 4);
 3433     assert(Out.tell() - Start == DataLen && "Data length is wrong");
 3689     assert((uint16_t)DataLen == DataLen && (uint16_t)KeyLen == KeyLen);
 3726     assert((Bits & 0xffff) == Bits && "ObjCOrBuiltinID too big for ASTReader.");
 3802       assert(II && "NULL identifier in identifier table");
 3846     assert(IdentifierOffsets[I] && "Missing identifier offset?");
 3911     assert(Writer.hasChain() &&
 3948     assert(uint16_t(DataLen) == DataLen &&
 3972       assert(Name.getOperatorKind() < NUM_OVERLOADED_OPERATORS &&
 3994     assert(Out.tell() - Start == DataLen && "Data length is wrong");
 4018   assert(!ConstDC->hasLazyLocalLexicalLookups() &&
 4024   assert(DC == DC->getPrimaryContext() && "only primary DC has lookup table");
 4075       assert(isa<CXXRecordDecl>(DC) &&
 4081       assert(isa<CXXRecordDecl>(DC) &&
 4134     assert(ConstructorNameSet.empty() && "Failed to find all of the visible "
 4137     assert(ConversionNameSet.empty() && "Failed to find all of the visible "
 4235         assert(Result.empty() && "Cannot have a constructor or conversion "
 4421       assert(getDeclID(*Cat) != 0 && "Bogus category");
 4602   assert(Context && "should have context when outputting path");
 4659   assert(ID && "Unknown selector");
 4685   assert(WritingAST && "can't determine lang opts when not writing AST");
 4756       assert(D->isCanonicalDecl() && "predefined decl is not canonical");
 4841   assert(SemaRef.PendingLocalImplicitInstantiations.empty() &&
 5052           assert(BaseID < std::numeric_limits<uint32_t>::max() && "base id too high");
 5200       assert(SubmoduleIDs.find(I->getImportedModule()) != SubmoduleIDs.end());
 5279         assert(Update.getDecl() && "no decl to add?");
 5541   assert(MacroIDs.find(MI) != MacroIDs.end() && "Macro not emitted!");
 5638   assert(Context);
 5642     assert(!T.getLocalFastQualifiers());
 5647         assert(0 && "New type seen after serializing all the types to emit!");
 5661   assert(Context);
 5665     assert(!T.getLocalFastQualifiers());
 5668     assert(I != TypeIdxs.end() && "Type not emitted!");
 5678   assert(WritingAST && "Cannot request a declaration ID before AST writing");
 5689   assert(!(reinterpret_cast<uintptr_t>(D) & 0x01) && "Invalid decl pointer");
 5693       assert(0 && "New decl seen after serializing all the decls to emit!");
 5715   assert(DeclIDs.find(D) != DeclIDs.end() && "Declaration not emitted!");
 5720   assert(ID);
 5721   assert(D);
 5739   assert(SM.isLocalSourceLocation(FileLoc));
 5745   assert(SM.getSLocEntry(FID).isFile());
 5804   assert(needsAnonymousDeclarationNumber(D) &&
 5817     assert(It != AnonymousDeclarationNumbers.end() &&
 6070   assert(TemplateParams && "No TemplateParams!");
 6089   assert(TemplateArgs && "No TemplateArgs!");
 6097   assert(ASTTemplArgList && "No ASTTemplArgList!");
 6255   assert(Reader && "Cannot remove chain");
 6256   assert((!Chain || Chain == Reader) && "Cannot replace chain");
 6257   assert(FirstDeclID == NextDeclID &&
 6317   assert(MacroDefinitions.find(MD) == MacroDefinitions.end());
 6322   assert(SubmoduleIDs.find(Mod) == SubmoduleIDs.end());
 6328   assert(D->isCompleteDefinition());
 6329   assert(!WritingAST && "Already writing the AST!");
 6336       assert(isTemplateInstantiation(RD->getTemplateSpecializationKind()) &&
 6355   assert(DC->isLookupContext() &&
 6375   assert(DC == DC->getPrimaryContext() && "added to non-primary context");
 6376   assert(!getDefinitiveDeclContext(DC) && "DeclContext not definitive!");
 6377   assert(!WritingAST && "Already writing the AST!");
 6390   assert(D->isImplicit());
 6401   assert(RD->isCompleteDefinition());
 6402   assert(!WritingAST && "Already writing the AST!");
 6408   assert(!DoneWritingDeclsAndTypes && "Already done writing updates!");
 6423   assert(!WritingAST && "Already writing the AST!");
 6435   assert(!WritingAST && "Already writing the AST!");
 6436   assert(Delete && "Not given an operator delete");
 6445   assert(!WritingAST && "Already writing the AST!");
 6455   assert(!WritingAST && "Already writing the AST!");
 6464   assert(!WritingAST && "Already writing the AST!");
 6473   assert(!WritingAST && "Already writing the AST!");
 6489   assert(!WritingAST && "Already writing the AST!");
 6498   assert(!WritingAST && "Already writing the AST!");
 6509   assert(!WritingAST && "Already writing the AST!");
 6513   assert(IFD->getDefinition() && "Category on a class without a definition?");
 6520   assert(!WritingAST && "Already writing the AST!");
 6534   assert(!WritingAST && "Already writing the AST!");
 6543   assert(!WritingAST && "Already writing the AST!");
 6553   assert(!WritingAST && "Already writing the AST!");
 6563   assert(!WritingAST && "Already writing the AST!");
 6564   assert(D->isHidden() && "expected a hidden declaration");
 6571   assert(!WritingAST && "Already writing the AST!");
 6579   assert(!WritingAST && "Already writing the AST!");
 6591   assert(!WritingAST && "Already writing the AST!");
 6603   assert(!WritingAST && "Already writing the AST!");
tools/clang/lib/Serialization/ASTWriterDecl.cpp
  212         assert(!Common->LazySpecializations);
  232         assert(D->isCanonicalDecl() && "non-canonical decl in set");
  683     assert(Context.getObjCMethodRedeclaration(D));
 1070   assert(!D->isARCPseudoStrong()); // can be true of ImplicitParamDecl
 1096   assert(!D->getTSCSpec() && "PARM_VAR_DECL can't use TLS");
 1097   assert(!D->isThisDeclarationADemotedDefinition()
 1099   assert(D->getAccess() == AS_none && "PARM_VAR_DECL can't be public/private");
 1100   assert(!D->isExceptionVariable() && "PARM_VAR_DECL can't be exception var");
 1101   assert(D->getPreviousDecl() == nullptr && "PARM_VAR_DECL can't be redecl");
 1102   assert(!D->isStaticDataMember() &&
 1704   assert(IsLocalDecl(D) && "expected a local declaration");
 1726     assert(isRedeclarableDeclKind(DAsT->getKind()) &&
 2352   assert(!D->isFromASTFile() && "should not be emitting imported decl");
 2359   assert(ID >= FirstDeclID && "invalid decl ID");
 2398   assert(FD->doesThisDeclarationHaveABody());
tools/clang/lib/Serialization/ASTWriterStmt.cpp
   45       assert(Code != serialization::STMT_NULL_PTR &&
  903       assert(D.isArrayRangeDesignator() && "Unknown designator");
 2375   assert(SwitchCaseIDs.find(S) == SwitchCaseIDs.end() &&
 2383   assert(SwitchCaseIDs.find(S) != SwitchCaseIDs.end() &&
 2412   assert(!ParentStmts.count(S) && "There is a Stmt cycle!");
 2441   assert(Writer->SubStmtEntries.empty() && "unexpected entries in sub-stmt map");
 2442   assert(Writer->ParentStmts.empty() && "unexpected entries in parent stmt map");
 2447     assert(N == StmtsToEmit.size() && "record modified while being written!");
 2467     assert(N == StmtsToEmit.size() && "record modified while being written!");
tools/clang/lib/Serialization/GeneratePCH.cpp
   55       assert(hasErrors && "emitting module but current module doesn't exist");
   61   assert(SemaPtr && "No Sema?");
tools/clang/lib/Serialization/GlobalModuleIndex.cpp
  222       assert(Idx == Record.size() && "More module info?");
tools/clang/lib/Serialization/InMemoryModuleCache.cpp
   28   assert(Insertion.second && "Already has a PCM");
   36   assert(!PCM.IsFinal && "Trying to override finalized PCM?");
   37   assert(!PCM.Buffer && "Trying to override tentative PCM?");
   61   assert(I != PCMs.end() && "PCM to remove is unknown...");
   64   assert(PCM.Buffer && "PCM to remove is scheduled to be built...");
   75   assert(I != PCMs.end() && "PCM to finalize is unknown...");
   78   assert(PCM.Buffer && "Trying to finalize a dropped PCM...");
tools/clang/lib/Serialization/ModuleManager.cpp
  295   assert(State->NextState == nullptr && "Visited state is in list?");
  373     assert(VisitOrder.size() == N && "Visitation order is wrong?");
  401     assert(State->VisitNumber[CurrentModule->Index] == VisitNumber - 1);
tools/clang/lib/StaticAnalyzer/Checkers/ArrayBoundCheckerV2.cpp
  173     assert(state_withinLowerBound);
  217       assert(!state_withinUpperBound);
  222     assert(state_withinUpperBound);
tools/clang/lib/StaticAnalyzer/Checkers/BasicObjCFoundationChecks.cpp
  177           assert(Arg == 1);
  188           assert(Arg == 1);
  622   assert(Class);
  897     assert(ElemDecl->getInit() == nullptr);
tools/clang/lib/StaticAnalyzer/Checkers/BoolAssignmentChecker.cpp
  117   assert(stateGE == state);
  153   assert(stateLE == state);
tools/clang/lib/StaticAnalyzer/Checkers/BuiltinFunctionChecker.cpp
   47     assert (Call.getNumArgs() > 0);
   72     assert (Call.getNumArgs() > 0);
   97     assert(state && "The region should not have any previous constraints");
tools/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp
  294       assert(CurrentFunctionDescription);
  305   assert(stateNonNull);
  352       assert(CurrentFunctionDescription);
  353       assert(CurrentFunctionDescription[0] != '\0');
  492   assert(stateFalse);
  558   assert(stateFalse);
  706     assert(stateOkay);
  716   assert(!strLength.isUndef() && "Attempt to set an undefined string length");
  804         assert(CurrentFunctionDescription);
  852       assert(CurrentFunctionDescription);
  935   assert(ER->getValueType() == C.getASTContext().CharTy &&
 1472   assert(!result.isUnknown() && "Should have conjured a value by now");
 1684       assert(!amountCopied.isUndef());
 1719   assert(state);
 1756       assert(!finalStrLength.isUndef());
 1801   assert(state);
 1868   assert(state);
 1958   assert(StNotSameBuf);
 2079     assert(SearchStrVal.isUnknown());
 2300     assert(StrVal.isValid() && "Initializer string is unknown or undefined");
tools/clang/lib/StaticAnalyzer/Checkers/CStringSyntaxChecker.cpp
  171       assert(isa<EnumConstantDecl>(LenArgDRE->getDecl()));
tools/clang/lib/StaticAnalyzer/Checkers/CallAndMessageChecker.cpp
  120       assert(Msg.isSetter() && "Getters have no args");
  210       assert(RD && "Referred record has no definition");
  416         assert(isa<BlockDecl>(D));
  483       assert(BT && "Unknown message kind.");
tools/clang/lib/StaticAnalyzer/Checkers/CastSizeChecker.cpp
   60   assert(Last && "empty structs should already be handled");
tools/clang/lib/StaticAnalyzer/Checkers/CheckObjCDealloc.cpp
   85   assert(*PD);
  192   assert(Mgr.getLangOpts().getGC() != LangOptions::GCOnly);
  193   assert(!Mgr.getLangOpts().ObjCAutoRefCount);
  565     assert(PropDecl->getSetterKind() == ObjCPropertyDecl::Copy ||
  599   assert(!LCtx->inTopFrame() || State->get<UnreleasedIvarMap>().isEmpty());
  677   assert(PropDecl->getSetterKind() == ObjCPropertyDecl::Weak ||
  826       assert(ShadowedPropDecl->isReadOnly());
  837   assert(Value);
  855   assert(Instance);
  856   assert(Value);
  870     assert(UnreleasedRegion);
  983   assert(SelfDecl && "No self in -dealloc?");
 1040   assert(PropImpl->getPropertyIvarDecl());
tools/clang/lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp
  298   assert(vdInc && (vdInc == vdLHS || vdInc == vdRHS));
  587   assert(ArgSuffix.first >= 0 && "Unsupported function");
  760   assert(ArgIndex != UNKNOWN_CALL && "Unsupported function");
tools/clang/lib/StaticAnalyzer/Checkers/DirectIvarAssignment.cpp
  147     assert(Body);
tools/clang/lib/StaticAnalyzer/Checkers/DivZeroChecker.cpp
   83     assert(stateZero);
tools/clang/lib/StaticAnalyzer/Checkers/DynamicTypePropagation.cpp
  133   assert(Region);
  134   assert(MD);
  347   assert(ToR);
  383       assert(MostInformativeCandidate->isSpecialized());
  398   assert(SuperOfTo);
  471   assert(StaticUpperBound->isSpecialized() ||
  473   assert(!Current || (*Current)->isSpecialized());
tools/clang/lib/StaticAnalyzer/Checkers/GCDAntipatternChecker.cpp
  187   assert(SW);
tools/clang/lib/StaticAnalyzer/Checkers/GTestChecker.cpp
  132   assert(Call->getNumArgs() >= 1 && Call->getNumArgs() <= 2);
  161   assert(Call->getNumArgs() == 1);
tools/clang/lib/StaticAnalyzer/Checkers/GenericTaintChecker.cpp
  723   assert(E);
tools/clang/lib/StaticAnalyzer/Checkers/InnerPointerChecker.cpp
  214         assert(C.wasInlined || !Set.contains(Sym));
tools/clang/lib/StaticAnalyzer/Checkers/IteratorChecker.cpp
 1569   assert ((Op == OO_Plus || Op == OO_PlusEqual ||
 2049   assert(comparison.getAs<DefinedSVal>() &&
 2057     assert(isa<SymIntExpr>(CompSym) &&
 2059     assert(BinaryOperator::isComparisonOp(
 2109   assert(T->isSignedIntegerOrEnumerationType());
 2362   assert(comparison.getAs<DefinedSVal>() &&
tools/clang/lib/StaticAnalyzer/Checkers/IvarInvalidationChecker.cpp
  244   assert(!isa<ObjCImplementationDecl>(D));
  349     assert(PD &&"Do we synthesize ivars for something other than properties?");
  534   assert(FirstIvarDecl);
tools/clang/lib/StaticAnalyzer/Checkers/LocalizationChecker.cpp
  123     assert(NonLocalizedString);
  812   assert(!SelectorName.empty());
 1080     assert(Body);
tools/clang/lib/StaticAnalyzer/Checkers/MIGChecker.cpp
  147   assert(LC && "Unknown location context");
tools/clang/lib/StaticAnalyzer/Checkers/MPI-Checker/MPIBugReporter.cpp
   96   assert(Req && "The region must be tracked and alive, given that we've "
tools/clang/lib/StaticAnalyzer/Checkers/MPI-Checker/MPIFunctionClassifier.cpp
   33   assert(IdentInfo_MPI_Send);
   39   assert(IdentInfo_MPI_Isend);
   44   assert(IdentInfo_MPI_Ssend);
   50   assert(IdentInfo_MPI_Issend);
   55   assert(IdentInfo_MPI_Bsend);
   61   assert(IdentInfo_MPI_Ibsend);
   66   assert(IdentInfo_MPI_Rsend);
   71   assert(IdentInfo_MPI_Irsend);
   76   assert(IdentInfo_MPI_Recv);
   82   assert(IdentInfo_MPI_Irecv);
   91   assert(IdentInfo_MPI_Scatter);
   98   assert(IdentInfo_MPI_Iscatter);
  104   assert(IdentInfo_MPI_Gather);
  111   assert(IdentInfo_MPI_Igather);
  117   assert(IdentInfo_MPI_Allgather);
  124   assert(IdentInfo_MPI_Iallgather);
  130   assert(IdentInfo_MPI_Bcast);
  137   assert(IdentInfo_MPI_Ibcast);
  143   assert(IdentInfo_MPI_Reduce);
  150   assert(IdentInfo_MPI_Ireduce);
  156   assert(IdentInfo_MPI_Allreduce);
  163   assert(IdentInfo_MPI_Iallreduce);
  169   assert(IdentInfo_MPI_Alltoall);
  176   assert(IdentInfo_MPI_Ialltoall);
  182   assert(IdentInfo_MPI_Comm_rank);
  186   assert(IdentInfo_MPI_Comm_size);
  190   assert(IdentInfo_MPI_Wait);
  194   assert(IdentInfo_MPI_Waitall);
  199   assert(IdentInfo_MPI_Barrier);
tools/clang/lib/StaticAnalyzer/Checkers/MacOSKeychainAPIChecker.cpp
  442     assert(State);
  637   assert(funDecl && "We do not support indirect function calls as of now.");
  642   assert(Idx != InvalidIdx && "This should be a call to an allocator.");
tools/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
  145     assert(family != AF_None);
  722     assert(!IsReleased ||
 1253   assert(Arg);
 1291   assert(FalseState);
 1548     assert(State);
 1572   assert(Sym);
 1620     assert(*Ret && "We should not store the null return symbol");
 1954   assert(RS);
 2202   assert(MR && "Only MemRegion based symbols can have offset free errors");
 2205   assert((Offset.isValid() &&
 2452   assert(!PrtIsNull);
 2562   assert(RS && "cannot leak an untracked symbol");
 2574   assert(N);
 2637     assert(state->get<ReallocPairs>() ==
 2639     assert(state->get<FreeReturnValue>() ==
 2802   assert(Sym);
 2849   assert(Sym);
 2915           assert(I.getData().Kind == OAR_FreeOnFailure);
 2929   assert(Call);
 3280             assert(!ReleaseDestructorLC &&
 3308         assert((!FailedReallocSymbol || FailedReallocSymbol == sym) &&
 3317     assert(FailedReallocSymbol && "No symbol to look for.");
 3331     assert(!StackHint);
 3335   assert(StackHint);
 3340     assert(RSCurr->getAllocationFamily() == AF_InnerBuffer);
tools/clang/lib/StaticAnalyzer/Checkers/MoveChecker.cpp
  352   assert(!C.isDifferent() && "No transitions should have been made by now");
  494   assert(!C.isDifferent() && "Should not have made transitions on this path!");
tools/clang/lib/StaticAnalyzer/Checkers/NSAutoreleasePoolChecker.cpp
   66     assert(0);
tools/clang/lib/StaticAnalyzer/Checkers/NonNullParamChecker.cpp
  103     assert(!haveRefTypeParam || DV->getAs<Loc>());
  125       assert(++CSV->begin() == CSV->end());
tools/clang/lib/StaticAnalyzer/Checkers/NullabilityChecker.cpp
  457     assert(Region && "Non-symbolic region is tracked.");
  511   assert(E);
  803     assert(SelfRegion);
 1042   assert(Init && "ObjC local under ARC without initializer");
tools/clang/lib/StaticAnalyzer/Checkers/NumberObjectConversionChecker.cpp
  103   assert(Conv);
  113   assert(Obj);
  136     assert(ObjT.getCanonicalType()->isPointerType());
tools/clang/lib/StaticAnalyzer/Checkers/OSObjectCStyleCast.cpp
   42   assert(CE);
tools/clang/lib/StaticAnalyzer/Checkers/ObjCAutoreleaseWriteChecker.cpp
  124     assert(MarkedStmt);
tools/clang/lib/StaticAnalyzer/Checkers/ObjCContainersASTChecker.cpp
  128     assert(ArgNum == 1 || ArgNum == 2);
tools/clang/lib/StaticAnalyzer/Checkers/ObjCMissingSuperCallChecker.cpp
  108     assert(Descriptor.ArgumentCount <= 1); // No multi-argument selectors yet.
tools/clang/lib/StaticAnalyzer/Checkers/ObjCSuperDeallocChecker.cpp
  120   assert(ReceiverSymbol && "No receiver symbol at call to [super dealloc]?");
tools/clang/lib/StaticAnalyzer/Checkers/PaddingChecker.cpp
   92     assert(llvm::isPowerOf2_64(RL.getAlignment().getQuantity()));
  105       assert(!DiffPad.isNegative() && "DiffPad should not be negative");
  253       assert(llvm::isPowerOf2_64(RetVal.Align.getQuantity()));
tools/clang/lib/StaticAnalyzer/Checkers/PointerArithChecker.cpp
  107   assert(Region);
  121   assert(Region);
tools/clang/lib/StaticAnalyzer/Checkers/PointerIterationChecker.cpp
   41   assert(MarkedStmt);
tools/clang/lib/StaticAnalyzer/Checkers/PointerSortingChecker.cpp
   41   assert(MarkedStmt);
tools/clang/lib/StaticAnalyzer/Checkers/PthreadLockChecker.cpp
  164   assert(lstate->isUntouchedAndPossiblyDestroyed() ||
  268     assert(lockFail && lockSucc);
  274     assert(lockSucc);
  278     assert((semantics == XNUSemantics) && "Unknown locking semantics");
tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker/RetainCountChecker.cpp
   38   assert(Sym != nullptr);
  600     assert(AssumeZeroReturn == AssumeNonZeroReturn);
  692       assert(Ex);
  804           assert(V.getCount() > 0);
 1001       assert(cnt > 0);
 1044   assert(T);
 1382     assert(!LCtx->inTopFrame());
tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker/RetainCountChecker.h
  115     assert(getKind() == k && "not enough bits for the kind");
  116     assert(getObjKind() == o && "not enough bits for the object kind");
  117     assert(getIvarAccessHistory() == IvarAccess && "not enough bits");
  205     assert(getIvarAccessHistory() == IvarAccessHistory::None);
  211     assert(getIvarAccessHistory() == IvarAccessHistory::AccessedDirectly);
tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker/RetainCountDiagnostics.cpp
  103     assert(!PrevV.hasSameState(CurrV) && "The state should have changed.");
  107       assert(CurrV.getCombinedCounts() == 0);
  123         assert(PrevV.getAutoreleaseCount() < CurrV.getAutoreleaseCount());
  236     assert(isa<ObjCMessageExpr>(S));
  273     assert(CurrV.getObjKind() == ObjKind::ObjC);
  287     assert(CurrV.isNotOwned());
  445     assert(CurrT->getCount() == 0);
  705   assert(N && "Could not find allocation node");
  758   assert(RV);
  890   assert(Location.isValid() && UniqueingDecl && UniqueingLocation.isValid());
tools/clang/lib/StaticAnalyzer/Checkers/RetainCountChecker/RetainCountDiagnostics.h
   94     assert(Location.isValid());
tools/clang/lib/StaticAnalyzer/Checkers/RunLoopAutoreleaseLeakChecker.cpp
   86   assert(D->hasBody());
   92   assert(ME);
  102   assert(RLR && "Run loop launch not found");
  103   assert(ME != RLR);
tools/clang/lib/StaticAnalyzer/Checkers/StackAddrEscapeChecker.cpp
  114   assert(R && "MemRegion should not be null");
tools/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp
  112       assert(Kind == ComparesToArgument);
  113       assert(Args.size() == 1);
  116       assert(BinaryOperator::isComparisonOp(Op) &&
  122       assert(Kind == ComparesToArgument);
  123       assert(Args.size() == 1);
  128       assert(Kind != ComparesToArgument);
  175       assert(!T->isVoidType() &&
  177       assert(T.isCanonical() &&
  180       assert(T->isIntegralOrEnumerationType() &&
  255       assert(Min <= Max);
  289       assert(MinusInf <= Left);
  297       assert(Right <= PlusInf);
  306       assert(Min <= Max);
  423     assert(ActualT.isCanonical());
  437   assert(CE);
tools/clang/lib/StaticAnalyzer/Checkers/Taint.cpp
   93   assert(NewState);
  116   assert(NewState);
tools/clang/lib/StaticAnalyzer/Checkers/UndefBranchChecker.cpp
   85       assert (!N->pred_empty());
tools/clang/lib/StaticAnalyzer/Checkers/UndefResultChecker.cpp
   71   assert(LHS && RHS && "Values unknown, inconsistent state");
tools/clang/lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedObject.h
  119     assert(FR);
  338   assert(!contains(FN.getRegion()) &&
tools/clang/lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedObjectChecker.cpp
   84     assert(!T.isNull());
   85     assert(T->getAsCXXRecordDecl());
  246   assert((PointeeR || !isDereferencableType(FR->getDecl()->getType())) &&
  278   assert(R->getValueType()->isRecordType() &&
  378   assert(R->getValueType()->isUnionType() &&
  536   assert(Parent && "The record's definition must be avaible if an uninitialized"
  569     assert(FirstAccess);
  575     assert(FirstGuard);
  591     assert(CXXParent->captures_begin());
tools/clang/lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedPointee.cpp
  143   assert((isDereferencableType(FR->getDecl()->getType()) ||
  202   assert((isPrimitiveType(PointeeT) || isDereferencableType(PointeeT)) &&
  228   assert(V.getAsRegion() && "V must have an underlying region!");
tools/clang/lib/StaticAnalyzer/Checkers/UnixAPIChecker.cpp
  387   assert(trueState);
  423   assert(trueState);
tools/clang/lib/StaticAnalyzer/Checkers/VLASizeChecker.cpp
  178   assert(state);
tools/clang/lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
   80   assert(K.hasValue() && "User mode is invalid.");
   92   assert(K.hasValue() && "IPA Mode is invalid.");
  112   assert(K.hasValue() && "Invalid c++ member function inlining mode.");
  120   assert(!CheckerName.empty() &&
  161   assert(Ret &&
  182   assert(!HasFailed &&
tools/clang/lib/StaticAnalyzer/Core/BugReporter.cpp
  141     assert(CurrentNode && "Already reached the root!");
  172     assert(Path && LC);
  177     assert(LCM.count(Path) &&
  483   assert(D);
  515     assert(ThisCallLocation && "Outermost call has an invalid location");
  604       assert(isa<BlockDecl>(D));
  699   assert(S && "Cannot have null Stmt for PathDiagnosticLocation");
  834     assert(B->getOpcode() == BO_LOr);
 1013   assert(Src->succ_size() == 2);
 1157       assert(C.getActivePath().size() == 1 &&
 1162       assert(C.isInLocCtxMap(&C.getActivePath()) &&
 1169       assert(!C.isInLocCtxMap(&Call->path) &&
 1180       assert(C.CallStack.back().first == Call);
 1186   assert(C.getCurrLocationContext() == C.getLocationContextForActivePath() &&
 1197     assert(!C.isInLocCtxMap(&Call->path) &&
 1757   assert(LC);
 1961     assert(FID.isValid());
 2005     assert(!EndNotes->second.empty());
 2057       assert(stillHasNotes);
 2141   assert(Location.isValid());
 2339   assert(ErrorNode && "Cannot create a location with a null node.");
 2394   assert(StrBugTypes.empty() &&
 2489     assert(I->isValid() &&
 2507     assert(NewNode &&
 2514   assert(!RemainingNodes.empty() && "No error node found in the trimmed graph");
 2519   assert(TrimmedGraph->num_roots() == 1);
 2533       assert(PriorityEntry->second <= Priority);
 2555   assert(PriorityMap.find(OrigN) != PriorityMap.end() &&
 2633     assert(Loc.isMacroID());
 2672         assert(InstantiationLoc.isFileID());
 2723           assert(!LastPiece &&
 2725           assert(Piece->getKind() == PathDiagnosticPiece::Kind::Event &&
 2758     assert(R && "No original report found for sliced graph.");
 2759     assert(R->isValid() && "Report selected by trimmed graph marked invalid.");
 2804   assert(!bugReports.empty());
 2824   assert(ValidSourceLoc);
 2851       assert((E->isSink() || E->getLocation().getTag()) &&
 2889   assert(EQ.getReports().size() > 0);
 2949       assert(!WI.N->succ_empty());
 3138   assert(AnalysisManager::isInCodeFile(CallLoc, SMgr) &&
 3163   assert(LastP);
 3208   assert(!bugReports.empty());
tools/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp
  188   assert(CondVarExpr);
  619   assert(N->getLocationAs<CallExitBegin>());
  721   assert(RegionOfInterest->isSubRegionOf(MatchedRegion));
 1029     assert(RetE && "Tracking a return value for a void function");
 1133     assert(Options.ShouldAvoidSuppressingNullArgumentPaths);
 1234     assert(VR->getDecl()->isStaticLocal() && "non-static stackless VarRegion");
 1238   assert(VR->getDecl()->hasLocalStorage());
 1430           assert(isa<ImplicitParamDecl>(VR->getDecl()));
 1568     assert(!isUnderconstrained(N));
 1610   assert(N->getState()->isNull(V).isConstrainedTrue() &&
 1645     assert(Succ->getState()->isNull(V).isConstrainedTrue());
 1869       assert(isa<ObjCMessageExpr>(GetterMessageSend->IgnoreParenCasts()));
 2225     assert(BO->isLogicalOp() &&
 2242   assert(Cond);
 2243   assert(srcBlk->succ_size() == 2);
 2788     assert(ParamDecl && "Formal parameter has no decl?");
tools/clang/lib/StaticAnalyzer/Core/CallEvent.cpp
   74   assert(E);
  211   assert(B);
  219   assert(Idx < Sz);
  247   assert(PVD && "Unexpected Decl kind!");
  254   assert(VR->getStackFrame() == SFC);
  349   assert(D && "Cannot get a program point without a statement or decl");
  463   assert(D);
  492   assert(D);
  518     assert(ParamDecl && "Formal parameter has no decl?");
  699     assert(ParentRecord);
  719   assert(ThisVal.isUnknownOrUndef() || ThisVal.getAs<Loc>());
  746   assert(!RegionType.isNull() && "DynamicTypeInfo should always be a pointer.");
  759     assert(!RD->isDerivedFrom(MD->getParent()) && "Couldn't find known method");
  987   assert(getOriginExpr()->getReceiverKind() == ObjCMessageExpr::SuperInstance);
  989   assert(SelfVal.isValid() && "Calling super but not in ObjC method");
 1020   assert(Data && "Lazy lookup not yet performed.");
 1021   assert(getMessageKind() != OCM_Message && "Explicit message send.");
 1064         assert(getMessageKind() == K);
 1071     assert(getMessageKind() == OCM_Message);
 1085     assert(POE && "Property access without PseudoObjectExpr?");
 1105   assert(IDecl);
 1191   assert(E);
 1213         assert(isa<AllocaRegion>(Receiver) &&
 1384   assert(CallerCtx && "This should not be used for top-level stack frames");
 1393     assert(isa<CXXConstructExpr>(CallSite) &&
 1409   assert((E.getAs<CFGImplicitDtor>() || E.getAs<CFGTemporaryDtor>()) &&
tools/clang/lib/StaticAnalyzer/Core/CheckerHelpers.cpp
   93     assert(PD->isSingleDecl() && "We process decls one by one");
tools/clang/lib/StaticAnalyzer/Core/CheckerManager.cpp
   58     assert(Event.second.HasDispatcher &&
   78   assert(D);
   93   assert(checkers);
  100   assert(D && D->hasBody());
  620   assert((Call != nullptr ||
  676       assert(!(evaluated && anyEvaluated)
  891   assert(S);
tools/clang/lib/StaticAnalyzer/Core/CoreEngine.cpp
   87     assert(Entry->empty() && "Entry block must be empty.");
   89     assert(Entry->succ_size() == 1 && "Entry block must have 1 successor.");
  111     assert(IsNew);
  167       assert(false && "BlockExit location never occur in forward analysis.");
  179       assert(Pred->hasSinglePred() &&
  186       assert(Loc.getAs<PostStmt>() ||
  240     assert(L.getLocationContext()->getCFG()->getExit().empty() &&
  364         assert(B->succ_size() == 1);
  401         assert(cast<GCCAsmStmt>(Term)->isAsmGoto() && "Encountered GCCAsmStmt without labels");
  412   assert(B->succ_size() == 1 &&
  426   assert(B->succ_size() == 2);
  438   assert(B->succ_size() == 2);
  449   assert(B->succ_size() == 2);
  460   assert(B);
  461   assert(!B->empty());
  505     assert(IsNew);
  515   assert(Block);
  516   assert(!N->isSink());
  685   assert(Src->succ_rbegin() != Src->succ_rend());
tools/clang/lib/StaticAnalyzer/Core/DynamicType.cpp
   82   assert(State);
  100     assert((CastToTy->isAnyPointerType() || CastToTy->isReferenceType()) &&
  117   assert(State);
tools/clang/lib/StaticAnalyzer/Core/Environment.cpp
  229   assert(LCtx);
  254       assert(S != nullptr && "Expected non-null Stmt");
tools/clang/lib/StaticAnalyzer/Core/ExplodedGraph.cpp
  160   assert(node->pred_size() == 1 || node->succ_size() == 1);
  178   assert(ReclaimCounter > 0);
  207   assert(!V->isSink());
  213   assert(!getFlag());
  216   assert(Storage.is<ExplodedNode *>());
  218   assert(Storage.is<ExplodedNode *>());
  222   assert(!getFlag());
  227     assert(Storage.is<ExplodedNode *>());
  243     assert(!getFlag());
  244     assert(Storage.is<ExplodedNodeVector *>());
  311   assert(LC->getAnalysisDeclContext()->isBodyAutosynthesized());
  313   assert(ParentLC && "We don't start analysis from autosynthesized code");
  317     assert(ParentLC && "We don't start analysis from autosynthesized code");
tools/clang/lib/StaticAnalyzer/Core/ExprEngine.cpp
  285       assert(state && "'self' cannot be null");
  300           assert(state && "'this' cannot be null");
  331     assert(!InitValWithAdjustments.getAs<Loc>() ||
  467   assert(!State->get<ObjectsUnderConstruction>(Key) ||
  486   assert(State->contains<ObjectsUnderConstruction>(Key));
  504   assert(State->contains<ObjectsUnderConstruction>(Key));
  520     assert(LC && "ToLC must be a parent of FromLC!");
  694   assert((K == ProgramPoint::PreStmtPurgeDeadSymbolsKind ||
  697   assert(LC && "Must pass the current (or expiring) LocationContext");
  701     assert(DiagnosticStmt && "Required for clearing a LocationContext");
  711     assert(K == ProgramPoint::PostStmtPurgeDeadSymbolsKind &&
  753     assert(StateMgr.haveEqualEnvironments(CheckerState, Pred->getState()) &&
  756     assert(StateMgr.haveEqualStores(CheckerState, Pred->getState()) &&
  885     assert(BMI->isBaseInitializer() || BMI->isDelegatingInitializer());
 1106   assert(CleanDtorState.size() <= 1);
 1203   assert(!isa<Expr>(S) || S == cast<Expr>(S)->IgnoreParens());
 1482             assert(Child);
 1795         assert(SE->getType() == getContext().VoidTy
 1849   assert(CalleeSF && CallerSF);
 2063   assert(B->getTerminator().isStmtBranch() &&
 2081     assert(LastStmt == Condition || LastStmt == getRightmostLeaf(Condition));
 2093   assert((!Condition || !isa<CXXBindTemporaryExpr>(Condition)) &&
 2284       assert(LC && "ToLC must be a parent of FromLC!");
 2290           assert(I.first.getItem().getKind() ==
 2312   assert(areAllObjectsFullyConstructed(Pred->getState(),
 2366     assert(V1.getBitWidth() == getContext().getIntWidth(CondE->getType()));
 2430     assert(Ex->isGLValue() || VD->getType()->isVoidType());
 2476     assert(!Ex->isGLValue());
 2613           assert(M->getType()->isArrayType());
 2847   assert(!location.getAs<NonLoc>() && "location cannot be a NonLoc.");
 2848   assert(NodeEx);
 2849   assert(BoundEx);
 2978     assert(!X.getAs<NonLoc>());  // Should be an Lval, or unknown, undef.
tools/clang/lib/StaticAnalyzer/Core/ExprEngineC.cpp
  113     assert (B->isCompoundAssignmentOp());
  231         assert(CI->getVariable() == capturedR->getDecl());
  264     assert(!CastE->getType()->isLValueReferenceType());
  267     assert(!CastE->getType()->isRValueReferenceType());
  563     assert(isa<InitListExpr>(Init));
  604       assert(DS->isSingleDecl());
  655   assert(B->getOpcode() == BO_LAnd ||
  674     assert(P.getAs<PreStmt>()|| P.getAs<PreStmtPurgeDeadSymbols>());
  702     assert(Term->isLogicalOp());
  703     assert(SrcBlock->succ_size() == 2);
  712     assert(!SrcBlock->empty());
  770   assert(NumInitElements <= 1);
  786   assert(L && R);
  810   assert(SrcBlock && "missing function entry");
  852     assert(IV.getBitWidth() == getContext().getTypeSize(OOE->getType()));
  853     assert(OOE->getType()->castAs<BuiltinType>()->isInteger());
  854     assert(IV.isSigned() == OOE->getType()->isSignedIntegerType());
  881         assert(T->isVariableArrayType() && "Unknown non-constant-sized type.");
  953       assert (U->getType() == Ex->getType());
  995       assert(!U->isGLValue());
 1006       assert (!U->isGLValue());
 1064   assert (U->isIncrementDecrementOp());
 1080     assert(LCtx == (*I)->getLocationContext());
 1143           assert(state);
tools/clang/lib/StaticAnalyzer/Core/ExprEngineCXX.cpp
   46     assert(Ctor->getDecl()->isTrivial());
   47     assert(Ctor->getDecl()->isCopyOrMoveConstructor());
   52     assert(cast<CXXMethodDecl>(Call.getDecl())->isTrivial());
   53     assert(cast<CXXMethodDecl>(Call.getDecl())->getOverloadedOperator() ==
   60   assert(ThisRD);
   80     assert(V.isUnknownOrUndef());
  140       assert(Init->isAnyMemberInitializer());
  203           assert(!isa<BlockInvocationContext>(CallerLCtx));
  223         assert(RetE && "Void returns should not have a construction context");
  233       assert(AMgr.getAnalyzerOptions().ShouldElideConstructors);
  286           assert(MTE->getStorageDuration() != SD_FullExpression);
  379       assert(!V.isUnknown());
  423   assert(C || getCurrentCFGElement().getAs<CFGStmt>());
  437     assert(
  491     assert(DstPrepare.size() <= 1);
  574       assert(!DstEvaluated.empty() &&
  608   assert(S && "A destructor without a trigger!");
  613   assert(RecordDecl && "Only CXXRecordDecls should have destructors");
  839       assert(Bldr.getResults().size() == 1);
  912       assert(InitExpr && "Capture missing initialization expression");
tools/clang/lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp
   47   assert(Entry->empty());
   48   assert(Entry->succ_size() == 1);
  188   assert(RuntimeCallee);
  433   assert(D);
  441     assert(BR && "If we have the block definition we should have its region");
  490   assert(ReplayState == CallE && "Backtracked to the wrong call.");
  539       assert(cast<VarRegion>(VV.castAs<loc::MemRegionVal>().getRegion())
  631     assert(RTC->getStmt() == Call.getOriginExpr());
  637     assert(TargetR);
  723     assert(ADC->getCFGBuildOptions().AddInitializers && "No CFG initializers");
  762     assert(ADC->getCFGBuildOptions().AddImplicitDtors && "No CFG destructors");
  960       assert(!MayInline.hasValue() || MayInline.getValue());
 1057   assert(BifurReg);
tools/clang/lib/StaticAnalyzer/Core/ExprEngineObjC.cpp
   67         assert(Loc::isLocType(T));
  122     assert(elemD->getInit() == nullptr);
  204         assert((Pred || HasTag) && "Should have cached out already!");
  224         assert((Pred || HasTag) && "Should have cached out already!");
tools/clang/lib/StaticAnalyzer/Core/HTMLDiagnostics.cpp
  182   assert(!path.empty());
  747   assert(&Pos.getManager() == &SM && "SourceManagers are different!");
  885       assert(L.isFileID());
tools/clang/lib/StaticAnalyzer/Core/LoopWidening.cpp
   48   assert(isa<ForStmt>(LoopStmt) || isa<WhileStmt>(LoopStmt) ||
   74     assert(VD);
tools/clang/lib/StaticAnalyzer/Core/MemRegion.cpp
  517   assert(Str != nullptr && "Expecting non-null StringLiteral");
  522   assert(Str != nullptr && "Expecting non-null ObjCStringLiteral");
  593   assert(canPrintPretty() && "This region cannot be printed pretty.");
  628   assert(canPrintPrettyAsExpr());
  742   assert(STC);
  755   assert(STC);
  774     assert(K == MemRegion::GlobalInternalSpaceRegionKind);
  778   assert(K == MemRegion::StaticGlobalSpaceRegionKind);
  897         assert(D->isStaticLocal());
  953       assert(STC);
  981     assert(STC);
 1047   assert(SFC);
 1078     assert(isValidBaseClass(RD, cast<TypedValueRegion>(Super), IsVirtual));
 1086       assert(Super && !isa<MemSpaceRegion>(Super));
 1103   assert(PT);
 1116   assert(STC);
 1124   assert(STC);
 1275   assert(superR && "super region cannot be NULL");
 1282   assert(Child && "Child must not be null");
 1310       assert(Offset == 0 && !SymbolicOffsetBase);
 1429       assert(R);
 1529     assert(VR);
 1530     assert(OriginalVR);
 1592   assert(MR);
tools/clang/lib/StaticAnalyzer/Core/PlistDiagnostics.cpp
  214   assert(!Message.empty());
  237     assert(!fixit.isNull());
  239     assert(!fixit.InsertFromRange.isValid() && "Not implemented yet!");
  240     assert(!fixit.BeforePreviousInsertions && "Not implemented yet!");
  303   assert(P.getFixits().size() == 0 &&
  373   assert(P.getFixits().size() == 0 &&
  388   assert(P.getFixits().size() == 0 &&
  478   assert(P.getFixits().size() == 0 &&
  520   assert(IndentLevel == InputIndentLevel);
  528   assert(std::is_partitioned(Path.begin(), Path.end(),
  985     assert(II &&
 1073   assert(II && "Failed to acquire the IndetifierInfo for the macro!");
 1144         assert(TheTok.isNot(tok::eof) &&
 1163       assert(UnexpArgII == __VA_ARGS__II);
 1169   assert(TheTok.is(tok::r_paren) &&
 1180   assert(It->is(tok::l_paren) && "This token should be '('!");
 1187     assert(It->isNot(tok::eof) &&
 1189     assert(It != End &&
 1227       assert(II);
tools/clang/lib/StaticAnalyzer/Core/PrettyStackTraceLocationContext.h
   32     assert(LCtx);
tools/clang/lib/StaticAnalyzer/Core/ProgramState.cpp
   35   assert(state->refCount > 0);
  225   assert(!LV.getAs<loc::MemRegionVal>() && "Use invalidateRegion instead.");
tools/clang/lib/StaticAnalyzer/Core/RangeConstraintManager.cpp
   64   assert(!isEmpty());
  206       assert(newRanges.begin()->To().isMinSignedValue() &&
  208       assert(!from.isMinSignedValue() && "Ranges should not overlap");
tools/clang/lib/StaticAnalyzer/Core/RangedConstraintManager.cpp
   51     assert(BinaryOperator::isComparisonOp(Op));
  123   assert(BinaryOperator::isComparisonOp(Op) &&
tools/clang/lib/StaticAnalyzer/Core/RegionStore.cpp
   56     assert(r && Base && "Must have known regions.");
   57     assert(getConcreteOffsetRegion() == Base && "Failed to store base region");
   63     assert(r && "Must have known regions.");
   64     assert(getOffset() == offset && "Failed to store offset");
   65     assert((r == r->getBaseRegion() || isa<ObjCIvarRegion>(r) ||
   76     assert(!hasSymbolicOffset());
   81     assert(hasSymbolicOffset());
  456     assert(!(B.getDefaultBinding(R) || B.getDirectBinding(R)) &&
  754       assert(!Cluster.isEmpty() && "Empty clusters should be removed");
  800   assert(R == R->getBaseRegion() && "Should only be called for base regions");
  823   assert(K.hasSymbolicOffset() && "Not implemented for concrete offset keys");
  838   assert(K.hasSymbolicOffset() && "Not implemented for concrete offset keys");
  883     assert(ExtentInt.isNonNegative() || ExtentInt.isUnsigned());
 1252   assert(SymbolManager::canSymbolicate(T) || V.isUnknown());
 1448   assert(!L.getAs<UnknownVal>() && "location unknown");
 1449   assert(!L.getAs<UndefinedVal>() && "location undefined");
 1477     assert(!T.isNull() && "Unable to auto-detect binding type!");
 1478     assert(!T->isVoidType() && "Attempting to dereference a void pointer!");
 2035       assert(!V->getAs<nonloc::LazyCompoundVal>());
 2120   assert(Ctx.getAsConstantArrayType(R->getValueType()) &&
 2196   assert((!isa<CXXThisRegion>(R) || !B.lookup(R)) &&
 2224     assert(!SymbolManager::canSymbolicate(T) && "This type is representable");
 2377   assert(T->isStructureOrClassType());
 2432     assert((CRD->isAggregate() || (Ctx.getLangOpts().ObjC && VI == VE)) &&
 2437       assert(!B.isVirtual() && "Aggregates cannot have virtual base classes!");
 2443       assert(BTy->isStructureOrClassType() && "Base classes must be classes!");
 2446       assert(BRD && "Base classes must be C++ classes!");
tools/clang/lib/StaticAnalyzer/Core/SValBuilder.cpp
   72   assert(lhs);
   73   assert(!Loc::isLocType(type));
   80   assert(rhs);
   81   assert(!Loc::isLocType(type));
   87   assert(lhs && rhs);
   88   assert(!Loc::isLocType(type));
   94   assert(operand);
   95   assert(!Loc::isLocType(toTy));
  195   assert(Loc::isLocType(T));
  196   assert(SymbolManager::canSymbolicate(T));
  209   assert(SymbolManager::canSymbolicate(type) && "Invalid metadata symbol type");
  240   assert(!DD || isa<CXXMethodDecl>(DD) || isa<FieldDecl>(DD));
  427     assert(op == BO_Add);
  579     assert(Loc::isLocType(castTy));
  597     assert(castTy->isIntegralOrEnumerationType());
  641     assert(Loc::isLocType(originalTy) || originalTy->isFunctionType() ||
tools/clang/lib/StaticAnalyzer/Core/SVals.cpp
  271   assert(BinaryOperator::isComparisonOp(Op) || Op == BO_Sub);
  374       assert(false && "Pretty-printed not implemented for this NonLoc.");
tools/clang/lib/StaticAnalyzer/Core/SarifDiagnostics.cpp
   86   assert(Iter != End && "Expected there to be a non-root path component.");
  246   assert(Iter != RuleMapping.end() && "Rule ID is not in the array index map?");
tools/clang/lib/StaticAnalyzer/Core/SimpleConstraintManager.cpp
   61     assert(Sym);
   72     assert(Sym);
   98   assert(From.isUnsigned() == To.isUnsigned() &&
  105     assert(Sym);
tools/clang/lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp
   69   assert(Val.getAs<Loc>() || Val.getAs<NonLoc>());
  336   assert(T->isSignedIntegerOrEnumerationType() &&
  348   assert(!AT.isUnsigned() &&
  380   assert(SymTy == RSym->getType() &&
  382   assert(APSIntType(LInt) == BV.getAPSIntType(SymTy) &&
  384   assert(APSIntType(RInt) == BV.getAPSIntType(SymTy) &&
  482   assert(!SingleTy.isNull() && "We should have figured out the type by now!");
  539       assert(rhs.getSubKind() == nonloc::PointerToMemberKind &&
  701             assert(resultTy->isBooleanType() ||
  703             assert(symIntExpr->getType()->isBooleanType() ||
  737               assert(newRHS && "Invalid operation despite common type!");
  902       assert(!ResultVal.getAs<Loc>() && "Loc-Loc ops should not produce Locs");
  910     assert(rhs.getAs<loc::MemRegionVal>() || rhs.getAs<loc::GotoLabel>());
  961     assert(LeftMR && "MemRegionValKind SVal doesn't have a region!");
 1123   assert(!BinaryOperator::isComparisonOp(op) &&
 1140       assert(leftI.isUnsigned());
 1178       assert(op == BO_Add || op == BO_Sub);
 1185       assert(op == BO_Add || op == BO_Sub);
 1293           assert(Loc::isLocType(Sym->getType()));
tools/clang/lib/StaticAnalyzer/Core/Store.cpp
   70   assert(!T.isNull());
  282   assert(BaseDecl && "not a C++ object?");
  324   assert(!TargetType.isNull());
  530   assert(BaseIdxI.isSigned());
tools/clang/lib/StaticAnalyzer/Core/SymbolManager.cpp
  128   assert(!itr.empty() && "attempting to iterate on an 'end' iterator");
  134   assert(!itr.empty() && "attempting to dereference an 'end' iterator");
  387   assert(LI != TheLiving.end() && "The primary symbol is not live.");
tools/clang/lib/StaticAnalyzer/Core/WorkList.cpp
   49     assert(!Stack.empty());
  115       assert(!Queue.empty());
tools/clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp
  127               assert(!Hint.InsertFromRange.isValid() && "Not implemented yet!");
  128               assert(!Hint.BeforePreviousInsertions && "Not implemented yet!");
  326         assert(Mode == (AM_Syntax | AM_Path) && "Unexpected mode!");
  428       assert(RecVisitorMode == AM_Syntax || Mgr->shouldInlineCall() == false);
  436       assert(RecVisitorMode == AM_Syntax || Mgr->shouldInlineCall() == false);
  444       assert(RecVisitorMode == AM_Syntax || Mgr->shouldInlineCall() == false);
tools/clang/lib/StaticAnalyzer/Frontend/CheckerRegistry.cpp
   63   assert(std::is_sorted(Collection.begin(), Collection.end(),
  291     assert(CheckerIt != Checkers.end() && CheckerIt->FullName == Entry.first &&
  296     assert(DependencyIt != Checkers.end() &&
  366   assert(It != Collection.end() &&
tools/clang/lib/Tooling/ASTDiff/ASTDiff.cpp
   74     assert(&*Tree == &T2 && "Invalid tree.");
  203     assert(!N.ASTNode.getNodeKind().isNone() &&
  217     assert(MyId.isValid() && "Expecting to only traverse valid nodes.");
  222     assert(N.RightMostDescendant >= 0 &&
  504     assert(Id > 0 && Id <= getSize() && "Invalid subtree node index.");
  511     assert(Id > 0 && Id <= getSize() && "Invalid subtree node index.");
  531       assert(I == Tree.PostorderIds[getIdInRoot(SI)] - getPostorderOffset() &&
  547       assert(K >= 0 && "K should be non-negative");
  619             assert(DiffImpl.isMatchingPossible(Id1, Id2) &&
  657     assert(Id1 > 0 && Id2 > 0 && "Expecting offsets greater than 0.");
  811   assert(Denominator >= 0 && "Expected non-negative denominator.");
tools/clang/lib/Tooling/CompilationDatabase.cpp
  335   assert(strcmp(*(End - 1), "-c") == 0);
tools/clang/lib/Tooling/Core/Diagnostic.cpp
   27   assert(Loc.isValid() && Loc.isFileID());
tools/clang/lib/Tooling/Core/Lookup.cpp
   79   assert(FromIter == FromNamespaces.end() && UseIter == UseNamespaces.end());
  129   assert(QName.startswith("::"));
  130   assert(QName.endswith(Spelling));
  188   assert(ReplacementString.startswith("::") &&
tools/clang/lib/Tooling/Core/Replacement.cpp
   83   assert(RewriteSucceeded);
  204       assert(PrevEnd == R.getOffset() &&
  270     assert(R.getLength() == 0);
tools/clang/lib/Tooling/DependencyScanning/DependencyScanningFilesystem.cpp
   61   assert(MinimizedFileContents.data()[MinimizedFileContents.size()] == '\0' &&
   96   assert(Stat.isDirectory() && "not a directory!");
tools/clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp
   55     assert(!CWD.empty() && "empty CWD");
tools/clang/lib/Tooling/GuessTargetAndModeCompilationDatabase.cpp
   21     assert(this->Base != nullptr);
tools/clang/lib/Tooling/Inclusions/HeaderIncludes.cpp
  307   assert(IncludeName == trimInclude(IncludeName));
  323   assert(CatOffset != CategoryEndOffsets.end());
  334   assert(InsertOffset <= Code.size());
  347   assert(IncludeName == trimInclude(IncludeName));
tools/clang/lib/Tooling/InterpolatingCompilationDatabase.cpp
  349     assert(!empty() && "need at least one candidate!");
  472     assert(!Idx.empty());
tools/clang/lib/Tooling/JSONCompilationDatabase.cpp
  156   assert(Syntax == JSONCommandLineSyntax::Gnu);
tools/clang/lib/Tooling/Refactoring/ASTSelection.cpp
   55     assert(SelectionStack.size() == 1 && "stack was not popped");
  185   assert(SelectionRange.isValid() &&
  191   assert(Context.getSourceManager().getFileID(SelectionRange.getEnd()) ==
  240   assert(Kind != SourceSelectionKind::None && "invalid predicate!");
  292   assert(S && "non statement selection!");
tools/clang/lib/Tooling/Refactoring/AtomicChange.cpp
  202   assert(FE && "Cannot create AtomicChange with invalid location.");
tools/clang/lib/Tooling/Refactoring/Extract/Extract.cpp
  101   assert(ParentDecl && "missing parent");
tools/clang/lib/Tooling/Refactoring/Rename/RenamingAction.cpp
  139   assert(!USRs.empty());
  151     assert(NewName.getNamePieces().size() == Ranges.size() &&
  249     assert(USRList.size() == NewNames.size());
tools/clang/lib/Tooling/Refactoring/Rename/SymbolOccurrences.cpp
   20   assert(Locations.size() == NamePieces.size() &&
   22   assert(!Locations.empty() && "no locations");
tools/clang/lib/Tooling/Refactoring/Rename/USRLocFinder.cpp
   68       assert(NameRanges.size() == 1 &&
  306       assert(EndLoc.isValid() &&
tools/clang/lib/Tooling/RefactoringCallbacks.cpp
   98       assert(false);
  117       assert(false);
  137         assert(false);
  148         assert(false);
tools/clang/lib/Tooling/Syntax/BuildTree.cpp
   61     assert(!Tokens.empty());
   62     assert(Tokens.back().kind() == tok::eof);
   77     assert(First.isValid());
   78     assert(Last.isValid());
   79     assert(First == Last ||
  102       assert(!A.tokenBuffer().expandedTokens().empty());
  103       assert(A.tokenBuffer().expandedTokens().back().kind() == tok::eof);
  113       assert(!Range.empty());
  115       assert(It != Trees.end() && "no node found");
  116       assert(It->first == Range.begin() && "no child with the specified range");
  117       assert((std::next(It) == Trees.end() ||
  127       assert(!NodeTokens.empty());
  128       assert(Node->firstChild() == nullptr && "node already has children");
  132       assert(BeginChildren != Trees.end() &&
  136       assert((EndChildren == Trees.end() ||
  151       assert(Trees.size() == 1);
  213     assert(llvm::isa<TranslationUnitDecl>(D->getDeclContext()) &&
  215     assert(!D->isImplicit());
  267   assert(It != Tokens.end());
  268   assert(It->location() == L);
tools/clang/lib/Tooling/Syntax/Tokens.cpp
   41   assert(Location.isValid());
   46   assert(!T.isAnnotation());
   52   assert(!Invalid);
   57   assert(location().isFileID() && "must be a spelled token");
   69   assert(F.file() == L.file() && "tokens from different files");
   70   assert(F.endOffset() <= L.beginOffset() && "wrong order of tokens");
   80   assert(File.isValid());
   81   assert(BeginOffset <= EndOffset);
   86   assert(BeginLoc.isValid());
   87   assert(BeginLoc.isFileID());
   94   assert(BeginLoc.isValid());
   95   assert(BeginLoc.isFileID());
   96   assert(EndLoc.isValid());
   97   assert(EndLoc.isFileID());
   98   assert(SM.getFileID(BeginLoc) == SM.getFileID(EndLoc));
   99   assert(SM.getFileOffset(BeginLoc) <= SM.getFileOffset(EndLoc));
  117   assert(Begin <= Text.size());
  118   assert(End <= Text.size());
  124   assert(Expanded);
  125   assert(ExpandedTokens.data() <= Expanded &&
  130   assert(FileIt != Files.end() && "no file for an expanded token");
  159   assert(It != Files.end());
  211   assert(Spelled);
  212   assert(Spelled->location().isFileID() && "not a spelled token");
  214   assert(FileIt != Files.end() && "file not tracked by token buffer");
  217   assert(File.SpelledTokens.data() <= Spelled &&
  238   assert(FileIt != Files.end() && "file not tracked by token buffer");
  366     assert(!Result.ExpandedTokens.empty());
  367     assert(Result.ExpandedTokens.back().kind() == tok::eof);
  374     assert(SM.getMainFileID() ==
  405       assert(File.SpelledTokens[NextSpelled[FID]].location() == L &&
  418     assert(FID == SM.getFileID(SpelledRange.getEnd()));
  473     assert(!HitMapping && "recursive macro expansion?");
  489     assert(L.isFileID());
tools/clang/lib/Tooling/Syntax/Tree.cpp
   29   assert(It.second && "duplicate FileID");
   34   assert(Tok != nullptr);
   48   assert(Child->Parent == nullptr);
   49   assert(Child->NextSibling == nullptr);
   50   assert(Child->role() == NodeRole::Detached);
   51   assert(Role != NodeRole::Detached);
   70   assert(!Tokens.empty());
tools/clang/lib/Tooling/Tooling.cpp
  108         assert(Actions.size() > 1);
  109         assert(
  146   assert(!CC1Args.empty() && "Must at least contain the program name!");
  531       assert(!CommandLine.empty());
  642   assert(ASTs.size() == 1);
tools/clang/lib/Tooling/Transformer/RewriteRule.cpp
  123     assert(hasValidKind(Cases[I].Matcher) &&
  142   assert(Ms.size() == 1 && "Cases must have compatible matchers.");
  149   assert(Root != NodesMap.end() && "Transformation failed: missing root node.");
tools/clang/tools/arcmt-test/arcmt-test.cpp
   92     assert(Ctx);
   99     assert(Ctx);
  180   assert(!transforms.empty());
  225   assert(!resultFiles.empty());
tools/clang/tools/c-index-test/c-index-test.c
  232     assert(*num_unsaved_files < (int)(sizeof(arg_indices)/sizeof(int)));
  243   assert(*unsaved_files);
  279     assert(contents);
  299     assert(filename);
  354   assert(*unsaved_files);
  753   assert(0 && "unknown display type"); /* no llvm_unreachable in C. */
 1034       assert(num_overridden <= 50);
 1529     assert(TArg.kind == CXType_Invalid);
 2350   assert(*filename);
 2797   assert(NumLocations > 0 && "Unable to count locations?");
 2800   assert(Locations);
 3091   assert(NumLocations > 0 && "Unable to count locations?");
 3094   assert(Locations);
 3200   assert(NumFilenames > 0 && "Unable to count filenames?");
 3202   assert(Filenames);
 3286   assert(p);
 3288   assert(p->filenames);
 3306   assert(p && file);
 3310   assert(p->num_files + 1 < MAX_IMPORTED_ASTFILES);
 3421   assert(node);
 3472   assert(0 && "Garbage entity kind");
 3484   assert(0 && "Garbage entity kind");
 3496   assert(0 && "Garbage language kind");
 3706     assert(!info->isContainer);
 4025     assert(tmp);
 4207   assert(cursors);
 4282   assert(tmp);
tools/clang/tools/c-index-test/core_main.cpp
  161     assert(PP);
  313   assert(Mod);
  328   assert(argv[1] == StringRef("core"));
tools/clang/tools/clang-extdef-mapping/ClangExtDefMapGen.cpp
   83   assert(!LookupName->empty() && "Lookup name should be non-empty.");
tools/clang/tools/clang-import-test/clang-import-test.cpp
  108     assert(LocData >= Buffer->getBufferStart() &&
  113     assert(LineBegin >= Buffer->getBufferStart());
  176     assert(Id != TY_INVALID);
tools/clang/tools/clang-offload-bundler/ClangOffloadBundler.cpp
  289       assert(BundlesInfo.find(Triple) == BundlesInfo.end() &&
  307     assert(CurBundleInfo != BundlesInfo.end() && "Invalid reader info!");
  312     assert(CurBundleInfo != BundlesInfo.end() && "Invalid reader info!");
  445     assert(HostInputIndex != ~0u && "Host input index not defined.");
  458     assert(NumberOfProcessedInputs <= NumberOfInputs &&
  460     assert(HostInputIndex != ~0u && "Host input index not defined.");
  562     assert(FC[ReadChars] == '\n' && "The bundle should end with a new line.");
  685   assert(HostInputIndex != ~0u && "Host input index undefined??");
  692   assert(FH);
  730   assert(FH);
  757     assert(!CurTriple.empty());
tools/clang/tools/clang-offload-wrapper/ClangOffloadWrapper.cpp
  296     assert(Desc && "no binary descriptor");
tools/clang/tools/clang-refactor/ClangRefactor.cpp
  298     assert(Selection && "selection not supported!");
  392     assert(SelectedSubcommand && MatchingRule && Consumer);
  412       assert(SelectedSubcommand->getSelection() &&
tools/clang/tools/clang-refactor/TestSupport.cpp
   59       assert(Start.isValid() && End.isValid() && "unexpected invalid range");
  210         assert(CanonicalResult && "missing canonical result");
  349         assert(false && "regex should have produced a number");
  366         assert(false && "regex should have produced a number");
tools/clang/tools/clang-refactor/ToolRefactoringResultConsumer.h
   25     assert(!Diags && "Diags has been set");
   31     assert(Diags && "Diags unset");
   36     assert(Diags && "no diags");
tools/clang/tools/diagtool/DiagnosticNames.cpp
   58   assert(Result && "diagnostic not found; table may be out of date");
tools/clang/tools/diagtool/TreeView.cpp
  108     assert(NonRootGroupIDs.size() < AllGroups.size());
tools/clang/tools/driver/cc1as_main.cpp
  354   assert(MRI && "Unable to create target register info!");
  359   assert(MAI && "Unable to create target asm info!");
  390     assert(Opts.RelocationModel == "dynamic-no-pic" &&
  462     assert(Opts.OutputType == AssemblerInvocation::FT_Obj &&
tools/clang/tools/extra/clang-change-namespace/ChangeNamespace.cpp
  294   assert(!SymbolSplitted.empty());
  300     assert(!NsSplitted.empty());
  593     assert(Var);
  597     assert(Context && "Empty decl context.");
  610     assert(EnumConstDecl);
  612     assert(Context && "Empty decl context.");
  625     assert(Func);
  627     assert(Context && "Empty decl context.");
  632     assert(Call != nullptr && "Expecting callback for CallExpr.");
  637     assert(Func != nullptr);
  650     assert(Context && "Empty decl context.");
  663   assert(Lex.get() &&
  688   assert(Start.isValid() && "Can't find l_brace for namespace.");
  707     assert(LocAfterNs.isValid() &&
  758   assert(!NsDecl->decls_empty());
  793   assert(Consumed && "Expect OldNS to start with OldNamespace.");
  842         assert(StringRef(AliasQualifiedName).endswith("::" + AliasName));
  931   assert(DeclCtx && "Empty decl context.");
  944   assert(UsingDeclaration->shadow_size() > 0);
tools/clang/tools/extra/clang-doc/BitcodeWriter.cpp
  123       assert(Inits.size() == BlockIdCount);
  126       assert(BlockIdNameMap.size() == BlockIdCount);
  189       assert(Inits.size() == RecordIdCount);
  192         assert((Init.second.Name.size() + 1) <= BitCodeConstants::RecordSize);
  194       assert(RecordIdNameMap.size() == RecordIdCount);
  244   assert(RecordIdNameMap[RID] && "Unknown RecordId.");
  245   assert(Abbrevs.find(RID) == Abbrevs.end() && "Abbreviation already added.");
  250   assert(RecordIdNameMap[RID] && "Unknown RecordId.");
  251   assert(Abbrevs.find(RID) != Abbrevs.end() && "Unknown abbreviation.");
  272   assert(BlockIdName.data() && BlockIdName.size() && "Unknown BlockId.");
  284   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  294   assert(RecordIdNameMap[ID] && "Unknown abbreviation.");
  304   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  305   assert(RecordIdNameMap[ID].Abbrev == &SymbolIDAbbrev &&
  309   assert(Sym.size() == 20);
  316   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  317   assert(RecordIdNameMap[ID].Abbrev == &StringAbbrev &&
  321   assert(Str.size() < (1U << BitCodeConstants::StringLengthSize));
  327   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  328   assert(RecordIdNameMap[ID].Abbrev == &LocationAbbrev &&
  334   assert(Loc.Filename.size() < (1U << BitCodeConstants::StringLengthSize));
  341   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  342   assert(RecordIdNameMap[ID].Abbrev == &BoolAbbrev && "Abbrev type mismatch.");
  350   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  351   assert(RecordIdNameMap[ID].Abbrev == &IntAbbrev && "Abbrev type mismatch.");
  360   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  361   assert(RecordIdNameMap[ID].Abbrev == &IntAbbrev && "Abbrev type mismatch.");
  364   assert(Val < (1U << BitCodeConstants::IntSize));
  370   assert(RecordIdNameMap[ID] && "Unknown RecordId.");
  383     assert(Block.second.size() < (1U << BitCodeConstants::SubblockIDSize));
  391   assert(RIDs.size() < (1U << BitCodeConstants::SubblockIDSize));
tools/clang/tools/extra/clang-doc/Representation.cpp
  122   assert(mergeable(Other));
  132   assert(mergeable(Other));
  154   assert(mergeable(Other));
  166   assert(mergeable(Other));
  176   assert(mergeable(Other));
  195   assert(mergeable(Other));
  204   assert(mergeable(Other));
tools/clang/tools/extra/clang-include-fixer/IncludeFixer.cpp
   42     assert(!Compiler->hasSema() && "CI already has Sema");
   88   assert(Invocation->getFrontendOpts().Inputs.size() == 1);
  344   assert(!Query.empty() && "Empty query!");
tools/clang/tools/extra/clang-include-fixer/YamlSymbolIndex.cpp
   40     assert(Directory.size() <= PathStorage.size());
tools/clang/tools/extra/clang-include-fixer/find-all-symbols/FindAllSymbols.cpp
   54     assert(llvm::isa<NamedDecl>(Context) &&
   90     assert(llvm::isa<RecordDecl>(ND) &&
  250     assert(false && "Must match a NamedDecl!");
tools/clang/tools/extra/clang-include-fixer/find-all-symbols/HeaderMapCollector.cpp
   17   assert(RegexHeaderMappingTable);
   35     assert(Entry.first.isValid(Dummy) && "Regex should never be invalid!");
tools/clang/tools/extra/clang-include-fixer/tool/ClangIncludeFixer.cpp
  276     assert(options.getSourcePathList().size() == 1 &&
  302     assert(!HeaderInfos.empty());
  395   assert(!Contexts.empty());
  440     assert(FixerReplacements.size() == 1);
tools/clang/tools/extra/clang-move/HelperDeclRefGraph.cpp
   39   assert(Caller);
   40   assert(Callee);
  117     assert(DC);
  127     assert(DC);
tools/clang/tools/extra/clang-move/Move.cpp
  163     assert(FD);
  181     assert(VD);
  217     assert(ED);
  422       assert(It < CurrentNamespaces.rend());
  461   assert(RG);
  879     assert(Reporter);
tools/clang/tools/extra/clang-query/tool/ClangQuery.cpp
  113     assert(Status == 0 && "Unexpected status returned");
tools/clang/tools/extra/clang-reorder-fields/ReorderFieldsAction.cpp
   59   assert(Definition && "Definition is null");
   77   assert(NewFieldsOrder.size() == NameToIndex.size());
  126   assert(Definition && "Definition is null");
  162   assert(CtorDecl && "Constructor declaration is null");
  169   assert(CtorDecl->isThisDeclarationADefinition() && "Not a definition");
  203     assert(LHS && RHS);
  209   assert(OldWrittenInitializersOrder.size() ==
  226   assert(InitListEx && "Init list expression is null");
tools/clang/tools/extra/clang-tidy/ClangTidyCheck.cpp
   17   assert(Context != nullptr);
   18   assert(!CheckName.empty());
tools/clang/tools/extra/clang-tidy/ClangTidyDiagnosticConsumer.cpp
   62     assert(Error.Message.Message.empty() && "Overwriting a diagnostic message");
   73     assert(Loc.isValid());
   79       assert(Range.getBegin().isValid() && Range.getEnd().isValid() &&
   81       assert(Range.getBegin().isFileID() && Range.getEnd().isFileID() &&
   93         assert(false && "Fix conflicts with existing fix!");
  108     assert(!Error.Message.Message.empty() && "Message has not been set");
  162   assert(Loc.isValid());
  216   assert(CheckFilter != nullptr);
  221   assert(WarningAsErrorFilter != nullptr);
  389     assert(!Errors.empty() &&
  518       assert(false); // This one is not passed around.
  687     assert(OpenIntervals == 0 && "Amount of begin/end points doesn't match");
tools/clang/tools/extra/clang-tidy/ClangTidyOptions.cpp
  229   assert(FS && "FS must be set.");
  274   assert(!Directory.empty());
tools/clang/tools/extra/clang-tidy/ClangTidyProfiling.cpp
   58   assert(Storage.hasValue() && "We should have a filename.");
tools/clang/tools/extra/clang-tidy/abseil/DurationAdditionCheck.cpp
   57     assert(Call == Binop->getRHS()->IgnoreParenImpCasts() &&
tools/clang/tools/extra/clang-tidy/abseil/DurationFactoryScaleCheck.cpp
   48   assert(FloatLit != nullptr && "Neither IntLit nor FloatLit set");
  219     assert(Remainder && "No remainder found");
tools/clang/tools/extra/clang-tidy/abseil/FasterStrsplitDelimiterCheck.cpp
   26   assert(Literal->getLength() == 1 &&
   28   assert(Literal->getCharByteWidth() == 1 &&
tools/clang/tools/extra/clang-tidy/abseil/StrCatAppendCheck.cpp
   77   assert(Op != nullptr && Call != nullptr && "Matcher does not work as expected");
tools/clang/tools/extra/clang-tidy/abseil/StringFindStartswithCheck.cpp
   66   assert(ComparisonExpr != nullptr);
   68   assert(Needle != nullptr);
   71   assert(Haystack != nullptr);
tools/clang/tools/extra/clang-tidy/abseil/TimeSubtractionCheck.cpp
   99     assert(Scale && "Unknow scale encountered");
tools/clang/tools/extra/clang-tidy/android/CloexecOpenCheck.cpp
   36   assert(FD->param_size() > 1);
tools/clang/tools/extra/clang-tidy/bugprone/ArgumentCommentCheck.cpp
   94       assert(CommentLoc.first == BeginLoc.first);
  175   assert(looksLikeExpectMethod(Expect));
tools/clang/tools/extra/clang-tidy/bugprone/BranchCloneCheck.cpp
   75     assert(Then && "An IfStmt must have a `then` branch!");
   78     assert(Else && "We only look for `if` statements with an `else` branch!");
tools/clang/tools/extra/clang-tidy/bugprone/FoldInitTypeCheck.cpp
  124   assert(InitType != nullptr);
  125   assert(IterValueType != nullptr);
  128   assert(CallNode != nullptr);
tools/clang/tools/extra/clang-tidy/bugprone/ForwardDeclarationNamespaceCheck.cpp
   64     assert(Decl && "Decl is neither record_decl nor friend decl!");
   94   assert(ParentDecl1->getDeclKind() == Decl::Namespace &&
   96   assert(ParentDecl2->getDeclKind() == Decl::Namespace &&
tools/clang/tools/extra/clang-tidy/bugprone/MisplacedOperatorInStrlenInAllocCheck.cpp
   77   assert(Alloc && "Matched node bound by 'Alloc' shoud be either 'CallExpr'"
tools/clang/tools/extra/clang-tidy/bugprone/ParentVirtualCallCheck.cpp
   34            assert(BaseDecl);
   54     assert(RecordDeclType && "TypePtr is not a pointer to CXXRecordDecl!");
   99   assert(Member);
  107   assert(ThisTypePtr);
  110   assert(ThisType);
  113   assert(CastToTypePtr);
  116   assert(CastToType);
  135   assert(Member->getQualifierLoc().getSourceRange().getBegin().isValid());
tools/clang/tools/extra/clang-tidy/bugprone/StringConstructorCheck.cpp
  116   assert(E && "missing constructor expression");
tools/clang/tools/extra/clang-tidy/bugprone/SuspiciousMissingCommaCheck.cpp
  100   assert(InitializerList && ConcatenatedLiteral);
tools/clang/tools/extra/clang-tidy/bugprone/SuspiciousStringCompareCheck.cpp
  172   assert(Decl != nullptr && Call != nullptr);
tools/clang/tools/extra/clang-tidy/bugprone/TooSmallLoopVariableCheck.cpp
  101   assert(IntExprType->isIntegerType());
tools/clang/tools/extra/clang-tidy/bugprone/VirtualNearMissCheck.cpp
  232   assert(DerivedMD);
  237   assert(DerivedRD);
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/NarrowingConversionsCheck.cpp
  140   assert(T.isInteger() && "Unexpected builtin type");
  355   assert(!Lhs.isInstantiationDependent() && !Rhs.isInstantiationDependent() &&
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/NoMallocCheck.cpp
   73   assert(Call && "Unhandled binding in the Matcher");
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/OwningMemoryCheck.cpp
  189   assert(CheckExecuted &&
  333     assert(BadOwnerParameter &&
  375     assert(DeclaredOwnerMember &&
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/ProTypeMemberInitCheck.cpp
  115     assert((Where != nullptr || Placement == InitializerPlacement::New) &&
  140     assert(!Initializers.empty() && "No initializers to insert");
  307     assert(Record->hasDefaultConstructor() &&
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/SlicingCheck.cpp
  104   assert(BaseDecl != nullptr);
  105   assert(DerivedDecl != nullptr);
  106   assert(Call != nullptr);
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/SpecialMemberFunctionsCheck.cpp
   84   assert(!SMFS.empty() &&
  177     assert(RequireThree);
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/SpecialMemberFunctionsCheck.h
   86     assert(Val != getEmptyKey() && "Cannot hash the empty key!");
   87     assert(Val != getTombstoneKey() && "Cannot hash the tombstone key!");
tools/clang/tools/extra/clang-tidy/fuchsia/MultipleInheritanceCheck.cpp
   32   assert(Node->getIdentifier());
   42   assert(Node->getIdentifier());
tools/clang/tools/extra/clang-tidy/fuchsia/OverloadedOperatorCheck.cpp
   37   assert(D && "No FunctionDecl captured!");
tools/clang/tools/extra/clang-tidy/google/UpgradeGoogletestCaseCheck.cpp
  330     assert(Result.Nodes.getNodeAs<TypeAliasDecl>("test-case") != nullptr);
tools/clang/tools/extra/clang-tidy/hicpp/ExceptionBaseclassCheck.cpp
   46   assert(BadThrow && "Did not match the throw expression");
tools/clang/tools/extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
  130   assert(CaseCount > 0 && "Switch statement with supposedly one default "
  145   assert(!Result.Nodes.getNodeAs<DeclRefExpr>("enum-condition") &&
  154   assert(CaseCount > 0 && "Switch statement without any case found. This case "
tools/clang/tools/extra/clang-tidy/hicpp/SignedBitwiseCheck.cpp
   67   assert(SignedOperand &&
tools/clang/tools/extra/clang-tidy/llvm/PreferIsaOrDynCastInConditionalsCheck.cpp
  101     assert(LHS && "LHS is null");
  102     assert(RHS && "RHS is null");
  103     assert(Arg && "Arg is null");
  104     assert(Func && "Func is null");
tools/clang/tools/extra/clang-tidy/misc/DefinitionsInHeadersCheck.cpp
   86   assert(ND);
tools/clang/tools/extra/clang-tidy/misc/NonPrivateMemberVariablesInClassesCheck.cpp
   83   assert(Field && "We should have the field we are going to complain about");
tools/clang/tools/extra/clang-tidy/misc/RedundantExpressionCheck.cpp
  143   assert(APSInt::compareValues(ValueLHS, ValueRHS) <= 0 &&
  163   assert(APSInt::compareValues(ValueLHS, ValueRHS) <= 0 &&
  207   assert(APSInt::compareValues(ValueLHS, ValueRHS) <= 0 &&
  579   assert(areSidesBinaryConstExpressions(BinOp, AstCtx) &&
  599   assert(BinOpLhs->getOpcode() == BinOpRhs->getOpcode() &&
 1039     assert(ShiftingConst && "Expr* 'ShiftingConst' is nullptr!");
 1046     assert(AndConst && "Expr* 'AndCont' is nullptr!");
tools/clang/tools/extra/clang-tidy/modernize/LoopConvertCheck.cpp
  538     assert(!AliasVarType.isNull() && "Type in VarDecl is null");
  735       assert(isa<PointerType>(CanonicalInitVarType) &&
  787     assert(BeginCall && "Bad Callback. No begin call expression");
  823     assert(Loop && "Bad Callback. No for statement");
tools/clang/tools/extra/clang-tidy/modernize/LoopConvertUtils.cpp
  395       assert(OpCall->getNumArgs() == 2);
  554       assert(Call->getNumArgs() == 1 &&
  877   assert(Context != nullptr && "Expected an ASTContext");
tools/clang/tools/extra/clang-tidy/modernize/RawStringLiteralCheck.cpp
   39   assert(QuotePos != StringRef::npos);
tools/clang/tools/extra/clang-tidy/modernize/UseEmplaceCheck.cpp
  125   assert((CtorCall || MakeCall) && "No push_back parameter matched");
tools/clang/tools/extra/clang-tidy/modernize/UseNoexceptCheck.cpp
   90   assert(FnTy && "FunctionProtoType is null.");
tools/clang/tools/extra/clang-tidy/modernize/UseNullptrCheck.cpp
   79   assert(Loc.isMacroID());
   98     assert(CastLoc.isFileID());
  310     assert(Loc.isMacroID() && "Only reasonble to call this on macros");
  415     assert(MacroLoc.isFileID());
  485   assert(NullCast && "Bad Callback. No node provided");
tools/clang/tools/extra/clang-tidy/modernize/UseOverrideCheck.cpp
   91   assert(Method != nullptr);
tools/clang/tools/extra/clang-tidy/modernize/UseTrailingReturnTypeCheck.cpp
  108   assert(!Loc.isMacroID() &&
  294       assert(I <= size_t(std::numeric_limits<int>::max()) &&
  310   assert(!ReturnTypeRange.getBegin().isMacroID() &&
  312   assert(!ReturnTypeRange.getEnd().isMacroID() &&
  353     assert(TOffset >= ReturnTypeBeginOffset &&
  390   assert(PP && "Expected registerPPCallbacks() to have been called before so "
  395   assert(F && "Matcher is expected to find only FunctionDecls");
tools/clang/tools/extra/clang-tidy/modernize/UseUncaughtExceptionsCheck.cpp
   69     assert(U && "Null pointer, no node provided");
tools/clang/tools/extra/clang-tidy/modernize/UseUsingCheck.cpp
   34   assert(StartLoc.isFileID() && "StartLoc must not be in a macro");
tools/clang/tools/extra/clang-tidy/objc/ForbiddenSubclassingCheck.cpp
   73   assert(SubClass != nullptr);
   76   assert(SuperClass != nullptr);
tools/clang/tools/extra/clang-tidy/objc/PropertyDeclarationCheck.cpp
   90   assert(Start != llvm::StringRef::npos && Start + 1 < PropertyName.size());
  115   assert(MatchedDecl->getName().size() > 0);
tools/clang/tools/extra/clang-tidy/openmp/ExceptionEscapeCheck.cpp
   64   assert(Directive && "Expected to match some OpenMP Executable directive.");
   67   assert(StructuredBlock && "Expected to get some OpenMP Structured Block.");
tools/clang/tools/extra/clang-tidy/openmp/UseDefaultNoneCheck.cpp
   43   assert(Directive != nullptr && "Expected to match some directive.");
tools/clang/tools/extra/clang-tidy/performance/InefficientVectorOperationCheck.cpp
  198   assert(AppendCall && "no append call expression");
tools/clang/tools/extra/clang-tidy/performance/NoexceptMoveConstructorCheck.cpp
   56       assert(Decl->getNumParams() > 0);
tools/clang/tools/extra/clang-tidy/performance/TypePromotionInMathFnCheck.cpp
  160   assert(Call != nullptr);
tools/clang/tools/extra/clang-tidy/portability/SIMDIntrinsicsCheck.cpp
  112   assert(Call != nullptr);
tools/clang/tools/extra/clang-tidy/readability/BracesAroundStatementsCheck.cpp
   28   assert(!Invalid && "Expected a valid token.");
   39   assert(Loc.isValid());
   60   assert(Loc.isValid());
   80     assert(Loc.isValid());
  254   assert(StartLoc.isValid());
  255   assert(EndLoc.isValid());
tools/clang/tools/extra/clang-tidy/readability/ConvertMemberFunctionsToStatic.cpp
  109   assert(TSI);
  111   assert(FTL);
tools/clang/tools/extra/clang-tidy/readability/IdentifierNamingCheck.cpp
   46     assert(Val != getEmptyKey() && "Cannot hash the empty key!");
   47     assert(Val != getTombstoneKey() && "Cannot hash the tombstone key!");
  398   assert(D && D->getIdentifier() && !D->getName().empty() && !D->isImplicit() &&
tools/clang/tools/extra/clang-tidy/readability/IsolateDeclarationCheck.cpp
   38   assert(Indirections >= 0 && "Indirections must be non-negative");
  234   assert(Snippets.size() > 2 && "Not enough snippets to create isolated decls");
tools/clang/tools/extra/clang-tidy/readability/SimplifyBooleanExprCheck.cpp
  623   assert(Compound->size() >= 2);
tools/clang/tools/extra/clang-tidy/readability/UppercaseLiteralSuffixCheck.cpp
  135   assert(!Invalid && "Failed to retrieve the source text.");
  164   assert(!ReplacementDsc.OldSuffix.empty() &&
tools/clang/tools/extra/clang-tidy/utils/ExceptionAnalyzer.cpp
   17   assert(ExceptionType != nullptr && "Only valid types are accepted");
tools/clang/tools/extra/clang-tidy/utils/LexerUtils.cpp
   74   assert(Range.isValid() && "Invalid Range for relexing provided");
tools/clang/tools/extra/clang-tidy/utils/TransformerClangTidyCheck.cpp
   35     assert(llvm::all_of(Rule->Cases, hasExplanation) &&
   44   assert(llvm::all_of(Rule->Cases, hasExplanation) &&
   74   assert(Rule && "check() should not fire if Rule is None");
tools/clang/tools/extra/clangd/AST.cpp
   98   assert(!StringRef(QName).startswith("::"));
tools/clang/tools/extra/clangd/ClangdLSPServer.cpp
  321       assert(Server);
  342         assert(false && "must reply to all calls!");
  349       assert(Server && "moved-from!");
  352         assert(false && "must reply to each call only once!");
  694       assert(R->ShowMessage ||
 1297   assert(false && "unhandled trigger character");
tools/clang/tools/extra/clangd/CodeComplete.cpp
  208     assert(IdentifierResult);
  262       assert(ASTCtx);
  361     assert(bool(C.SemaResult) == bool(SemaCCS));
  686     assert(this->ResultsCallback);
  811     assert(!OpenParLoc.isInvalid());
  827     assert(CurrentArg <= (unsigned)std::numeric_limits<int>::max() &&
  842       assert(CCS && "Expected the CodeCompletionString to be non-null");
  939         assert(Chunk.Optional &&
  974         assert(!ReturnType && "Unexpected CK_ResultType");
  984         assert(Chunk.Optional &&
 1250       assert(!SpecFuzzyFind->Result.valid());
 1261       assert(Recorder && "Recorder is not set");
 1326     assert(!Opts.Limit || Output.Completions.size() <= Opts.Limit);
 1537         assert(IdentifierResult);
 1710   assert(Offset <= Content.size());
tools/clang/tools/extra/clangd/CodeCompletionStrings.cpp
   39       assert(C.Optional &&
   86   assert(!Ctx.getSourceManager().isLoadedSourceLocation(RC->getBeginLoc()));
  156       assert(Chunk.Optional);      
tools/clang/tools/extra/clangd/Compiler.cpp
   75   assert(VFS && "VFS is null");
   76   assert(!CI->getPreprocessorOpts().RetainRemappedFileBuffers &&
tools/clang/tools/extra/clangd/Context.h
  113     assert(Val && "Key does not exist");
tools/clang/tools/extra/clangd/Diagnostics.cpp
   80   assert(R.isCharRange());
  534     assert(!Info.getFixItHints().empty() &&
  622       assert(false && "Adding a note without main diagnostic");
tools/clang/tools/extra/clangd/FS.cpp
   19   assert(llvm::sys::path::is_absolute(MainFilePath));
tools/clang/tools/extra/clangd/FSProvider.cpp
   49       assert(this->Wrapped);
tools/clang/tools/extra/clangd/FindTarget.cpp
  160       assert(Pat != D);
  386   assert(!(Mask & (DeclRelation::TemplatePattern |
  511       assert(!Ref->Qualifier.hasQualifier() && "qualifier already set");
  584     assert(Out);
  723   assert(S);
  728   assert(D);
tools/clang/tools/extra/clangd/Format.cpp
   90   assert(From.begin() >= Code.begin() && From.end() <= Code.end());
  216       assert(ReplacementSplit >= 0 &&
tools/clang/tools/extra/clangd/Function.h
   92     assert(Listeners.empty());
tools/clang/tools/extra/clangd/FuzzyMatch.cpp
  156   assert(Text.size() == Roles.size());
  281   assert(LowPat[P] == LowWord[W]);
  304   assert(S <= PerfectBonus);
tools/clang/tools/extra/clangd/GlobalCompilationDatabase.cpp
  160   assert(llvm::sys::path::is_absolute(Request.FileName) &&
  204   assert(Result.CDB && "Trying to broadcast an invalid CDB!");
  210     assert(*CompileCommandsDir == Result.PI.SourceRoot &&
tools/clang/tools/extra/clangd/Headers.cpp
   51         assert(SM.getBufferName(HashLoc).startswith("<") &&
  178   assert(InsertedHeader.valid());
  192   assert(InsertedHeader.valid());
tools/clang/tools/extra/clangd/IncludeFixer.cpp
  336     assert(SemaPtr && "Sema must have been set.");
  385   assert(LastUnresolvedName.hasValue());
tools/clang/tools/extra/clangd/Logger.cpp
   24   assert(!L);
tools/clang/tools/extra/clangd/ParsedAST.cpp
  129     assert(PP.getPPCallbacks() != ExistingCallbacks &&
  180       assert(HashTok.getKind() == tok::hash);
  224   assert(CI);
  500   assert(this->Clang);
  501   assert(this->Action);
tools/clang/tools/extra/clangd/Preamble.cpp
   52     assert(SourceMgr && LangOpts &&
  120   assert(!CI.getFrontendOpts().SkipFunctionBodies);
tools/clang/tools/extra/clangd/Protocol.cpp
   34   assert(llvm::sys::path::is_absolute(AbsPath) && "the path is relative");
  807   assert(!CI.label.empty() && "completion item label is required");
  850   assert((PI.labelOffsets.hasValue() || !PI.labelString.empty()) &&
  864   assert(!SI.label.empty() && "signature information label is required");
  881   assert(SH.activeSignature >= 0 &&
  883   assert(SH.activeParameter >= 0 &&
tools/clang/tools/extra/clangd/Protocol.h
 1255     assert(Style.empty() && "style modifiers for this type are not supported");
tools/clang/tools/extra/clangd/Quality.h
  173     assert(Heap.size() <= N);
  174     assert(std::is_heap(Heap.begin(), Heap.end(), Greater));
  181     assert(Heap.size() <= N);
tools/clang/tools/extra/clangd/QueryDriverDatabase.cpp
  186   assert(!Globs.empty() && "Globs cannot be empty!");
  193   assert(Reg.isValid(RegTexts.front()) &&
  207     assert(this->Base);
  277   assert(Base && "Null base to SystemIncludeExtractor");
tools/clang/tools/extra/clangd/Selection.cpp
   66     assert(Begin <= End);
  166     assert(V.Stack.size() == 1 && "Unpaired push/pop?");
  167     assert(V.Stack.top() == &V.Nodes.front());
  360       assert(&N == &Nodes.back());
  395     assert(Range && "We should be able to get the File Range");
  416     assert(Amount >= 0);
tools/clang/tools/extra/clangd/SemanticHighlighting.cpp
  406   assert(std::is_sorted(New.begin(), New.end()) &&
  408   assert(std::is_sorted(Old.begin(), Old.end()) &&
tools/clang/tools/extra/clangd/SourceCode.cpp
   71     assert((UTF8Length >= 2 && UTF8Length <= 4) &&
  364   assert(isValidFileRange(Mgr, R));
  383   assert(SM.getLocForEndOfFile(IncludedFile).isFileID());
  395   assert(Offset < Buf.size());
  522       assert(SM.isWrittenInSameFile(FileRange.getBegin(), FileRange.getEnd()));
  531       assert(SM.isWrittenInSameFile(ExpansionRangeForBegin.getBegin(),
  568   assert(isValidFileRange(SM, R));
  571   assert(!Invalid);
 1088       assert(Enclosing.back() == Event.Payload);
 1105     assert(ER.EnclosingNamespace.empty());
tools/clang/tools/extra/clangd/TUScheduler.cpp
  107     assert(findByKey(K) == LRU.end());
  292     assert(this->Worker);
  307     assert(Worker && "Handle was moved from");
  312     assert(Worker && "Handle was moved from");
  364   assert(Done && "handle was not destroyed");
  365   assert(Requests.empty() && "unprocessed requests when destroying ASTWorker");
  580   assert(!RunSync && "Running synchronously, but queue is non-empty!");
  623     assert(!Done && "stop() called twice");
  633     assert(!Done && "running a task after stop()");
  641     assert(!Done && "running a task after stop()");
  746   assert(!Requests.empty() && "skipped the whole queue");
  761   assert(!Requests.empty());
tools/clang/tools/extra/clangd/Threading.h
   66     assert(Type == Finite);
tools/clang/tools/extra/clangd/Trace.cpp
  194   assert(!T && "Resetting global tracer is not allowed.");
tools/clang/tools/extra/clangd/URI.cpp
  142   assert(!Scheme.empty());
  143   assert((Authority.empty() || Body.startswith("/")) &&
tools/clang/tools/extra/clangd/XRefs.cpp
   61   assert(D);
  382     assert(D->isCanonicalDecl() && "expect D to be a canonical declaration");
  519   assert(Params);
tools/clang/tools/extra/clangd/index/Background.cpp
   75         assert(false && "Failed to resolve URI");
  149   assert(ThreadPoolSize > 0 && "Thread pool size can't be zero.");
  150   assert(this->IndexStorageFactory && "Storage factory can not be null!");
  420   assert(Index.Symbols && Index.Refs && Index.Sources &&
  492     assert(!TUForFile.empty() && "File without a TU!");
tools/clang/tools/extra/clangd/index/BackgroundIndexLoader.cpp
   89   assert(LS.Digest != FileDigest{{0}} && "Digest is empty?");
  128     assert(llvm::sys::path::is_absolute(MainFile));
tools/clang/tools/extra/clangd/index/BackgroundQueue.cpp
   52       assert(NumActiveTasks > 0 && "before decrementing");
tools/clang/tools/extra/clangd/index/BackgroundRebuild.cpp
   86   assert(Loading);
   91     assert(Loading);
tools/clang/tools/extra/clangd/index/CanonicalIncludes.cpp
   34   assert(!Header.empty());
  762   assert(llvm::all_of(SystemHeaderMap->keys(), [](llvm::StringRef Path) {
  768   assert(llvm::find_if(SystemHeaderMap->keys(), [](llvm::StringRef Path) {
tools/clang/tools/extra/clangd/index/FileIndex.cpp
  143         assert(Sym.References == 0 &&
  169         assert(Sym.References == 0 &&
tools/clang/tools/extra/clangd/index/IndexAction.cpp
   73       assert(Digest && Node.Digest == *Digest &&
  114     assert(!I.second && "File inserted for the first time on skip.");
  115     assert(I.first->getKeyData() == I.first->getValue().URI.data() &&
  184         assert(Node.getKeyData() == Node.getValue().URI.data());
tools/clang/tools/extra/clangd/index/MemIndex.cpp
   31   assert(!StringRef(Req.Query).contains("::") &&
tools/clang/tools/extra/clangd/index/Merge.cpp
  166   assert(L.ID == R.ID);
  173   assert(L.Definition.FileURI && R.Definition.FileURI);
tools/clang/tools/extra/clangd/index/Serialization.cpp
  187     assert(!Sorted.empty() && "table not finalized");
  188     assert(Index.count({S.data(), S.size()}) && "string not interned");
  520   assert(Data.Symbols && "An index file without symbols makes no sense!");
tools/clang/tools/extra/clangd/index/Symbol.h
  159     assert(!S.data()[S.size()] && "Visited StringRef must be null-terminated");
tools/clang/tools/extra/clangd/index/SymbolCollector.cpp
  251   assert(ASTCtx && PP.get() && "ASTContext and Preprocessor must be set.");
  252   assert(CompletionAllocator && CompletionTUInfo);
  253   assert(ASTNode.OrigD);
  349   assert(PP.get());
  472     assert(PP);
  575   assert(Loc.isValid() && "Invalid source location for NamedDecl");
  588   assert(ASTCtx && PP.get() && "ASTContext and Preprocessor must be set.");
tools/clang/tools/extra/clangd/index/SymbolID.cpp
   28   assert(Raw.size() == RawSize);
tools/clang/tools/extra/clangd/index/SymbolLocation.h
   77   assert(L.FileURI && R.FileURI);
   82   assert(L.FileURI && R.FileURI);
tools/clang/tools/extra/clangd/index/YAMLSerialization.cpp
  142     assert(IO.getContext() &&
tools/clang/tools/extra/clangd/index/dex/Dex.cpp
  165   assert(!StringRef(Req.Query).contains("::") &&
  303   assert(ParsedURI &&
tools/clang/tools/extra/clangd/index/dex/Iterator.cpp
   29     assert(!Children.empty() && "AND iterator should have at least one child.");
   51     assert(!reachedEnd() && "AND iterator can't advance() at the end.");
   58     assert(!reachedEnd() && "AND iterator can't advanceTo() at the end.");
   66     assert(!reachedEnd() && "AND iterator can't consume() at the end.");
  138     assert(!Children.empty() && "OR iterator should have at least one child.");
  151     assert(!reachedEnd() && "OR iterator can't advance() at the end.");
  160     assert(!reachedEnd() && "OR iterator can't advanceTo() at the end.");
  169     assert(!reachedEnd() && "OR iterator can't peek() at the end.");
  182     assert(!reachedEnd() && "OR iterator can't consume() at the end.");
  225     assert(!reachedEnd() && "TRUE iterator can't advance() at the end.");
  230     assert(!reachedEnd() && "TRUE iterator can't advanceTo() at the end.");
  235     assert(!reachedEnd() && "TRUE iterator can't peek() at the end.");
  240     assert(!reachedEnd() && "TRUE iterator can't consume() at the end.");
  261   void advance() override { assert(false); }
  262   void advanceTo(DocID ID) override { assert(false); }
  264     assert(false);
  268     assert(false);
  329     assert(!reachedEnd() && "LimitIterator can't consume() at the end.");
tools/clang/tools/extra/clangd/index/dex/PostingList.cpp
   38     assert(!reachedEnd() &&
   47     assert(!reachedEnd() &&
   59     assert(!reachedEnd() && "Posting List iterator can't peek() at the end.");
   64     assert(!reachedEnd() &&
  133   assert(Delta != 0 && "0 is not a valid PostingList delta.");
  169   assert(!Documents.empty() && "Can't encode empty sequence.");
  193     assert(Length <= 5 && "Malformed VByte encoding sequence.");
tools/clang/tools/extra/clangd/refactor/Rename.cpp
  145   assert(CanonicalRenameDecl && "RenameDecl must be not null");
tools/clang/tools/extra/clangd/refactor/Tweak.cpp
   40     assert(E.instantiate()->id() == E.getName() &&
   42     assert(Seen.try_emplace(E.getName()).second && "duplicate check id");
tools/clang/tools/extra/clangd/refactor/tweaks/AnnotateHighlightings.cpp
   62     assert(Token.R.start.line == Token.R.end.line &&
tools/clang/tools/extra/clangd/refactor/tweaks/DefineInline.cpp
  245     assert(PrevDecl && "Found specialization without template decl");
tools/clang/tools/extra/clangd/refactor/tweaks/ExpandMacro.cpp
   54     assert(T.location().isFileID());
   67   assert(Cursor.isFileID());
  115     assert(Replacement.back() == ' ');
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractFunction.cpp
  237   assert(EnclosingFunc->hasBody() &&
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractVariable.cpp
  229         assert(E && "callee and args should be Exprs!");
  295     assert(!Op.SelectedOperands.empty() && "got only operator on one side!");
tools/clang/tools/extra/clangd/refactor/tweaks/RemoveUsingNamespace.cpp
  168       assert(Loc.isFileID());
tools/clang/tools/extra/clangd/unittests/ClangdTests.cpp
  122     assert(Matches.size() == 1 && "Exactly one match expected");
tools/clang/tools/extra/clangd/unittests/CodeCompleteTests.cpp
  105     assert(!Opts.Index && "both Index and IndexSymbols given!");
  123     assert(!Opts.Index && "both Index and IndexSymbols given!");
  158     assert(!Opts.Index && "both Index and IndexSymbols given!");
 2182   assert(!Results.empty());
tools/clang/tools/extra/clangd/unittests/DraftStoreTests.cpp
   27   assert(Start);
   28   assert(End);
tools/clang/tools/extra/clangd/unittests/ExpectedTypeTest.cpp
   31     assert(!AST && "AST built twice");
tools/clang/tools/extra/clangd/unittests/FindTargetTests.cpp
  551       assert(Pos.isValid());
  554       assert(Pos.isFileID());
  561         assert(NextCodeChar <= Offset);
tools/clang/tools/extra/clangd/unittests/HeadersTests.cpp
   42     assert(static_cast<bool>(Cmd));
tools/clang/tools/extra/clangd/unittests/RenameTests.cpp
  186       assert(Case.ErrorMessage && "Error message must be set!");
tools/clang/tools/extra/clangd/unittests/SelectionTests.cpp
   49   assert(FileRange && "We should be able to get the File Range");
tools/clang/tools/extra/clangd/unittests/SemanticHighlightingTests.cpp
   77   assert(std::is_sorted(
   88     assert(StartOffset <= EndOffset);
   89     assert(NextChar <= StartOffset);
tools/clang/tools/extra/clangd/unittests/SymbolCollectorTests.cpp
  124     assert(AST.hasValue());
tools/clang/tools/extra/clangd/unittests/SyncAPI.cpp
   29     assert(!Target.hasValue());
   41     assert(!Future.valid() && "conversion to callback called multiple times");
   51     assert(Future.valid() && "conversion to callback was not called");
   52     assert(!Target->hasValue());
tools/clang/tools/extra/clangd/unittests/TUSchedulerTests.cpp
  106                            assert(File == OrigFile);
  275                         assert(bool(Pre));
tools/clang/tools/extra/clangd/unittests/TestFS.cpp
   83   assert(llvm::sys::path::is_relative(File) && "FileName should be relative");
tools/clang/tools/extra/clangd/unittests/TestTU.cpp
   66   assert(CI && "Failed to build compilation invocation.");
  106       assert(false && "QName is not unique");
  113     assert(false && "No symbol with QName");
  126     assert(!LookupRes.empty() && "Lookup failed");
  127     assert(LookupRes.size() == 1 && "Lookup returned multiple results");
  154     assert(Visitor.Decls.size() == 1);
tools/clang/tools/extra/clangd/unittests/TweakTesting.cpp
   56     assert(A.ranges().size() == 0 &&
  153   assert(!Cases.empty() && "No markings in MarkedCode?");
tools/clang/tools/extra/modularize/ModularizeUtilities.cpp
  288     assert(Dir && "parent must exist");
tools/clang/tools/extra/modularize/PreprocessorTracker.cpp
  815     assert((HeaderStack.size() == 0) && "Header stack should be empty.");
tools/clang/tools/extra/tool-template/ToolTemplate.cpp
   66     assert(D);
tools/clang/tools/extra/unittests/clang-doc/BitcodeTest.cpp
   50   assert(Infos);
tools/clang/tools/extra/unittests/clang-doc/ClangDocTest.cpp
   18   assert(I->IT == InfoType::IT_namespace);
   23   assert(I->IT == InfoType::IT_record);
   28   assert(I->IT == InfoType::IT_function);
   33   assert(I->IT == InfoType::IT_enum);
tools/clang/tools/extra/unittests/clang-doc/HTMLGeneratorTest.cpp
   57   assert(G);
   62   assert(!Err);
  168   assert(G);
  173   assert(!Err);
  285   assert(G);
  290   assert(!Err);
  332   assert(G);
  337   assert(!Err);
  417   assert(G);
  422   assert(!Err);
tools/clang/tools/extra/unittests/clang-doc/MDGeneratorTest.cpp
   39   assert(G);
   43   assert(!Err);
  102   assert(G);
  106   assert(!Err);
  165   assert(G);
  169   assert(!Err);
  193   assert(G);
  197   assert(!Err);
  324   assert(G);
  328   assert(!Err);
tools/clang/tools/extra/unittests/clang-doc/MergeTest.cpp
   73   assert(Actual);
  148   assert(Actual);
  223   assert(Actual);
  264   assert(Actual);
tools/clang/tools/extra/unittests/clang-doc/YAMLGeneratorTest.cpp
   42   assert(G);
   46   assert(!Err);
  106   assert(G);
  110   assert(!Err);
  192   assert(G);
  196   assert(!Err);
  240   assert(G);
  244   assert(!Err);
  378   assert(G);
  382   assert(!Err);
tools/clang/tools/extra/unittests/clang-include-fixer/IncludeFixerTest.cpp
  103   assert(FixerContexts.size() == 1);
tools/clang/tools/extra/unittests/clang-tidy/GoogleModuleTest.cpp
   76     assert(Errors.size() == 1);
   77     assert(
tools/clang/tools/extra/unittests/clang-tidy/NamespaceAliaserTest.cpp
   34     assert(Call != nullptr && "Did not find node \"foo\"");
tools/clang/tools/extra/unittests/clang-tidy/UsingInserterTest.cpp
   36     assert(Call != nullptr && "Did not find node \"foo\"");
tools/clang/tools/libclang/CIndex.cpp
   75   assert(CIdx);
  110   assert(R1.isValid() && "First range is invalid?");
  111   assert(R2.isValid() && "Second range is invalid?");
  125   assert(R.isValid() && "First range is invalid?");
  126   assert(L.isValid() && "Second range is invalid?");
  196       assert(0 && "Invalid declaration cursor");
  270   assert(Begin.first == End.first);
  333   assert(!Decls.empty());
  358     assert(CompRes == RangeOverlap);
 2601     assert(D.isArrayRangeDesignator() && "Unknown designator kind");
 3347   assert((TU && Result == CXError_Success) ||
 3576   assert((TU && Result == CXError_Success) ||
 3958   assert(CS && "invalid compound statement");
 4196   assert(!isNotUsableTU(CTUnit) &&
 4210   assert(!isNotUsableTU(CTUnit) &&
 4503       assert(OID && "getCursorSpelling(): Missing protocol decl");
 4512       assert(Type && "Missing type decl");
 4519       assert(Template && "Missing template decl");
 4526       assert(NS && "Missing namespace decl");
 4533       assert(Field && "Missing member decl");
 4540       assert(Label && "Missing label");
 4563       assert(Var && "Missing variable decl");
 4858   assert(false && "Invalid CXPrintingPolicyProperty");
 4950   assert(false && "Invalid CXPrintingPolicyProperty");
 5947   assert(TU);
 6540   assert(getCursorDecl(C) && "CXCursor has null decl");
 6889     assert(Idx < NumTokens);
 6893     assert(Idx < NumTokens);
 6946     assert(PostChildrenInfos.empty());
 7056   assert(MoreTokens());
 7057   assert(isFunctionMacroToken(NextToken()) &&
 7396     assert(Idx < NumTokens);
 7400     assert(Idx < NumTokens);
 7473     assert(Tok.getLocation() ==
 7523       assert(TokIdx <= LastIdx);
tools/clang/tools/libclang/CIndexDiagnostic.h
   41     assert(i < getNumDiagnostics());
tools/clang/tools/libclang/CIndexHigh.cpp
  135   assert(Loc.isMacroID());
  215   assert(clang_isDeclaration(declCursor.kind));
  383   assert(TU && File && Visitor.visit);
tools/clang/tools/libclang/CXCursor.cpp
   35   assert(K >= CXCursor_FirstInvalid && K <= CXCursor_LastInvalid);
   41   assert(A && "Invalid arguments!");
   92   assert(A && Parent && TU && "Invalid arguments!");
  100   assert(D && TU && "Invalid arguments!");
  129   assert(S && TU && "Invalid arguments!");
  741   assert(Super && TU && "Invalid arguments!");
  749   assert(C.kind == CXCursor_ObjCSuperClassRef);
  757   assert(Proto && TU && "Invalid arguments!");
  765   assert(C.kind == CXCursor_ObjCProtocolRef);
  776   assert(TU && "Invalid arguments!");
  784   assert(C.kind == CXCursor_ObjCClassRef);
  791   assert(Type && TU && "Invalid arguments!");
  799   assert(C.kind == CXCursor_TypeRef);
  807   assert(Template && TU && "Invalid arguments!");
  815   assert(C.kind == CXCursor_TemplateRef);
  824   assert(NS && (isa<NamespaceDecl>(NS) || isa<NamespaceAliasDecl>(NS)) && TU &&
  833   assert(C.kind == CXCursor_NamespaceRef);
  841   assert(Var && TU && "Invalid arguments!");
  849   assert(C.kind == CXCursor_VariableRef);
  857   assert(Field && TU && "Invalid arguments!");
  865   assert(C.kind == CXCursor_MemberRef);
  877   assert(C.kind == CXCursor_CXXBaseSpecifier);
  892   assert(C.kind == CXCursor_PreprocessingDirective);
  906   assert(C.kind == CXCursor_MacroDefinition);
  919   assert(Loc.isValid());
  948   assert(C.kind == CXCursor_InclusionDirective);
  955   assert(Label && TU && "Invalid arguments!");
  963   assert(C.kind == CXCursor_LabelRef);
  970   assert(E && TU && "Invalid arguments!");
  983   assert(D && TU && "Invalid arguments!");
  996   assert(Name.getAsOverloadedTemplate() && TU && "Invalid arguments!");
 1008   assert(C.kind == CXCursor_OverloadedDeclRef);
 1052   assert(clang_isDeclaration(cursor.kind));
 1157   assert(clang_isDeclaration(C.kind));
 1335     assert(0 && "Unable to retrieve TemplateArgument");
 1340     assert(0 && "Passed template argument is not Integral");
 1352     assert(0 && "Unable to retrieve TemplateArgument");
 1357     assert(0 && "Passed template argument is not Integral");
 1521   assert(cxcursor::getCursorTU(backRefCursor) == TU);
 1535   assert(Vec->size() > 1);
 1552   assert(Vec && TU);
tools/clang/tools/libclang/CXCursor.h
  174     assert(isPseudo());
  178     assert(!isPseudo());
  182     assert(isPseudo());
  188     assert(C.kind == CXCursor_MacroExpansion);
tools/clang/tools/libclang/CXIndexDataConsumer.cpp
  421   assert(D);
 1032   assert(D);
tools/clang/tools/libclang/CXIndexDataConsumer.h
  228     assert(C.kind == CXCursor_IBOutletCollectionAttr);
  267     assert (ref_cnt > 0 && "Reference count is already zero.");
tools/clang/tools/libclang/CXLoadedDiagnostic.cpp
   72   assert(severity == static_cast<unsigned>(severityAsLevel) &&
  132   assert(Range < Ranges.size());
  142   assert(FixIt < FixIts.size());
  167   assert((V & 0x1) == 1);
tools/clang/tools/libclang/CXStoredDiagnostic.cpp
   87   assert(Diag.getLocation().isValid());
tools/clang/tools/libclang/CXType.cpp
  178   assert(!Type.isNull());
tools/clang/tools/libclang/Indexing.cpp
  176     assert(FE);
  203     assert(FE);
  213     assert(RegionLoc.isFileID());
tools/clang/unittests/AST/ASTImporterFixtures.cpp
   26   assert(ToAST);
   67   assert(ToAST);
   74   assert(&ToAST->getASTContext() == &Importer->getToContext());
  110   assert(ToTU);
  135   assert(It != FromTUs.end());
  150   assert(!ToAST);
  156   assert(ImportedII && "Declaration with the given identifier "
  163   assert(FoundDecls.size() == 1);
  168   assert(Imported);
  175   assert(llvm::find_if(FromTUs, [FileName](const TU &E) {
  189   assert(!ToAST);
  197   assert(SharedStatePtr);
  206   assert(SharedStatePtr);
  216   assert(SharedStatePtr);
  225     assert(Tu.Unit);
tools/clang/unittests/AST/ASTImporterTest.cpp
  201         assert(Found != CodeSamples.end() && "Wrong file for import!");
tools/clang/unittests/AST/ASTPrint.h
   27   assert(S != nullptr && "Expected non-null Stmt");
tools/clang/unittests/AST/CommentTextTest.cpp
   35     assert(CommentStartOffset != llvm::StringRef::npos);
tools/clang/unittests/AST/DeclMatcher.h
   36     assert(Node);
tools/clang/unittests/AST/DeclTest.cpp
   76   assert(Ctx.getTargetInfo().getDataLayout().getGlobalPrefix() &&
tools/clang/unittests/AST/RecursiveASTVisitorTest.cpp
   29     assert(this->Process);
tools/clang/unittests/AST/SourceLocationTest.cpp
  296     assert(!T.isNull());
  321     assert(!T.isNull());
  677     assert(!T.isNull());
tools/clang/unittests/Analysis/CFGDominatorTree.cpp
  182     assert(Index < cfg->size());
tools/clang/unittests/CodeGen/IRMatchers.h
   96     assert(MatchStack.size() > Offset);
  241     assert(!MetaMatcher && "Only one metadata matcher may be specified");
  424   assert(MC.size() == 0);
  446   assert(MC.size() == 0);
tools/clang/unittests/CodeGen/TBAAMetadataTest.cpp
   83     assert(FuncPtr != M->end());
   89     assert(FuncPtr == M->end());
   93     assert(Func.begin() != Func.end());
   96     assert(BBPtr == Func.end());
tools/clang/unittests/CrossTU/CrossTranslationUnitTest.cpp
   43     assert(FD && FD->getName() == "f");
tools/clang/unittests/DirectoryWatcher/DirectoryWatcherTest.cpp
   47     assert(!UniqDirRes);
   55     assert(!CreateDirRes);
  377     assert(!error);
tools/clang/unittests/Frontend/FrontendActionTest.cpp
  223       assert(Error.empty());
  226       assert(Note.empty());
tools/clang/unittests/Lex/HeaderMapTest.cpp
   68     assert(SI + S.size() + 1 <= sizeof(File.Bytes));
   75     assert(!(File.Header.NumBuckets & (File.Header.NumBuckets - 1)));
tools/clang/unittests/Lex/HeaderSearchTest.cpp
   43     assert(DE);
tools/clang/unittests/Rename/RenameAliasTest.cpp
  197   assert(!Param.OldName.empty());
  198   assert(!Param.NewName.empty());
tools/clang/unittests/Rename/RenameEnumTest.cpp
  149   assert(!Param.OldName.empty());
  150   assert(!Param.NewName.empty());
tools/clang/unittests/Rename/RenameMemberTest.cpp
  161   assert(!Param.OldName.empty());
  162   assert(!Param.NewName.empty());
tools/clang/unittests/Sema/CodeCompleteTest.cpp
  124       assert(PtrDiffType->empty() || *PtrDiffType == Results.PtrDiffType);
tools/clang/unittests/StaticAnalyzer/Reusables.h
   26   assert(Matches.size() <= 1 && "Ambiguous match!");
   27   assert(Matches.size() >= 1 && "Match not found!");
   29   assert(Node && "Type mismatch!");
tools/clang/unittests/StaticAnalyzer/StoreTest.cpp
   32     assert(VDX0 && VDY0 && VDZ0 && VDX1 && VDY1);
tools/clang/unittests/StaticAnalyzer/SymbolReaperTest.cpp
   22     assert(FD && VD);
tools/clang/unittests/Tooling/CommentHandlerTest.cpp
   37     assert(&PP == this->PP && "Preprocessor changed!");
tools/clang/unittests/Tooling/ExecutionTest.cpp
   40     assert(Context != nullptr);
   62     assert(Context != nullptr);
tools/clang/unittests/Tooling/HeaderIncludesTest.cpp
   25     assert(Header.startswith("\"") || Header.startswith("<"));
   36     assert(Header.startswith("\"") || Header.startswith("<"));
tools/clang/unittests/Tooling/LexicallyOrderedRecursiveASTVisitorTest.cpp
   75   assert(TraversalStack.back() == D);
tools/clang/unittests/Tooling/RangeSelectorTest.cpp
   44   assert(ASTUnit != nullptr && "AST construction failed");
   47   assert(!Context.getDiagnostics().hasErrorOccurred() && "Compilation error");
   51   assert(Matches.size() != 0 && "no matches found");
   52   assert(Matches.size() == 1 && "too many matches");
  137   assert(E != nullptr);
  153   assert(E != nullptr);
tools/clang/unittests/Tooling/RefactoringTest.cpp
  597       assert(!EC);
  605     assert(!EC);
  612     assert(File);
  616     assert(Found == Path);
  624     assert(!Path.empty());
 1099       assert(DefaultLoc.isValid() && "Default location must be valid.");
tools/clang/unittests/Tooling/RewriterTestContext.h
   60     assert(Entry);
   70     assert(!EC);
   77     assert(File);
   81     assert(Found == Path);
   89     assert(Result.isValid());
  103     assert(!Path.empty());
tools/clang/unittests/Tooling/Syntax/TokensTest.cpp
   98         assert(!Collector && "expected only a single call to BeginSourceFile");
  103         assert(Collector && "BeginSourceFileAction was never called");
  125     assert(CI);
tools/clang/unittests/Tooling/Syntax/TreeTest.cpp
   39         assert(this->Tokens);
   84     assert(CI);
tools/clang/unittests/libclang/TestUtils.h
   60     assert(OS.good());
tools/clang/utils/TableGen/ClangASTNodesEmitter.cpp
   50     assert(Root && "root node not yet derived!");
  132     assert (Last && "Got a first node but not a last node for a range!");
  145   assert(Root == nullptr && "already computed tree");
tools/clang/utils/TableGen/ClangAttrEmitter.cpp
   61     assert(V != "GCC" && V != "Clang" &&
  814       assert(!uniques.empty());
  946       assert(!uniques.empty());
 1536   assert(!SpellingList.empty() && "Spelling list is empty!");
 1559   assert(!SpellingList.empty() &&
 1579   assert(!Spellings.empty() && "An empty list of spellings was provided");
 1606   assert(Spellings.size() < 15 &&
 1696     assert(MetaSubject && "Missing subject");
 1725     assert(isSubRule() && "Not a sub-rule");
 1779       assert(IsRule && "not a rule!");
 1984     assert(It != SubjectsToRules.end() &&
 2254     assert(!Supers.empty() && "Forgot to specify a superclass for the attr");
 2460       assert(!SemanticToSyntacticMap.empty() && "Empty semantic mapping list");
 2638       assert(result && "failed to classify on root"); (void) result;
 2700         assert((i == Classes.begin()) == ((*i)->SuperClass == nullptr) &&
 3485     assert(!Subjects.empty() && "Missing subjects");
 3775         assert(Matches && "Unsupported spelling variety found");
tools/clang/utils/TableGen/ClangDiagnosticsEmitter.cpp
  142   assert(!LHS->getLoc().empty() && !RHS->getLoc().empty());
  153   assert(!LHS->DiagsInGroup.empty() && !RHS->DiagsInGroup.empty());
  169     assert(R->getValueAsDef("Class")->getName() != "CLASS_NOTE" &&
  188         assert(GI.ExplicitDef == Group);
  243       assert(DI != DE && "We only care about groups with multiple uses!");
  637     assert(EvaluatingRecord && "not evaluating a record?");
  962     assert(P->Options.size() == P->OptionPrefixes.size());
 1053         assert(!Text.empty() && "malformed %select");
 1069         assert(!Text.empty());
 1074         assert(!Text.empty() && "malformed %select");
 1086       assert(NameSize != size_t(-1) && "failed to find the end of the name");
 1087       assert(NameSize != 0 && "empty name?");
 1099           assert(!Text.empty() && isdigit(Text[0]) &&
 1261       assert(I != DiagsInGroup.end());
 1266       assert(I != DiagsInGroup.end() && "pedantic group not defined");
 1332         assert(RI != DiagsInGroup.end() && "Referenced without existing?");
 1341           assert(RI != DiagsInGroup.end() && "Referenced without existing?");
tools/clang/utils/TableGen/ClangOptionDocEmitter.cpp
  206   assert(Depth < 8 && "groups nested too deeply");
  322   assert(!SphinxOptionIDs.empty() && "no flags for option");
tools/clang/utils/TableGen/ClangSACheckersEmitter.cpp
   40   assert(!R->getValueAsString("PackageName").empty());
   49   assert(!R->getValueAsString("CheckerName").empty());
   62   assert(B->getNumBits() <= sizeof(uint64_t) * 8 && "BitInits' too long!");
tools/clang/utils/TableGen/MveEmitter.cpp
  201     assert(!isa<PointerType>(Pointee) && "Pointer to pointer not supported");
  490     assert(!Predecessor);
  612         assert(Arg->hasIntegerConstantValue());
  751         assert(!V->varnameUsed());
tools/clang/utils/TableGen/NeonEmitter.cpp
  225     assert(isVector());
  399     assert(hasImmediate());
  401     assert(Idx > 0 && "Can't return an immediate!");
  410     assert(hasSplat());
  412     assert(Idx > 0 && "Can't return a splat!");
  647     assert(isInteger() && isSigned());
  683     assert(Addend != 0 && "Float8 doesn't exist!");
  715     assert(Name.startswith("int"));
  756   assert(Name.startswith("_t") && "Malformed typedef!");
  818   assert(ElementBitwidth != ~0U && "Bad element bitwidth!");
  858     assert(!Poly && "'u' can't be used with poly types!");
 1250     assert(Variables.find(Name) != Variables.end());
 1355     assert(Variables.find(Name) != Variables.end());
 1391     assert(N.endswith("_n"));
 1484   assert(RetVar.getType() == Types[0]);
 1507   assert(!Lines.empty() && "Empty def?");
 1564     assert(DI->getNumArgs() == 3 && "Can only handle unary and binary ops!");
 1903   assert(Arg && "Neither ArgName nor Arg?!");
 2285       assert(Def->getImmediateIdx() > 0);
 2521   assert(Defs.empty() && "Some requirements were not satisfied!");
 2628   assert(Defs.empty() && "Some requirements were not satisfied!");
tools/dsymutil/CompileUnit.h
   36     assert(I);
   38     assert(Old.getType() == DIEValue::isInteger);
   43     assert(I);
tools/dsymutil/DeclContext.cpp
  146               assert(FoundFileName && "Must get file name from line table");
  189     assert(Inserted && "Failed to insert DeclContext");
  198   assert(ContextIter != Contexts.end());
tools/dsymutil/DwarfLinker.cpp
  125   assert(RefValue.isFormClass(DWARFFormValue::FC_Reference));
  562   assert(NextValidReloc == 0 ||
  687   assert(LowPc.hasValue() && "low_pc attribute is not an address.");
 1067     assert(Ref > InputDIE.getOffset());
 1124       assert(OpOffset < Op.getEndOffset());
 1126       assert(ULEBsize <= 16);
 1153       assert(RealSize == ULEBsize && "padding failed");
 1396   assert((NextValidReloc == 0 ||
 1413     assert(ValidReloc.Offset - BaseOffset < Data.size());
 1414     assert(ValidReloc.Offset - BaseOffset + ValidReloc.Size <= Data.size());
 1422     assert(ValidReloc.Size <= sizeof(Buf));
 1440   assert(isObjCSelector(Name.getString()) && "not an objc selector");
 1514   assert(!(Die && Info.Clone) && "Can't supply a DIE and a cloned DIE");
 1523   assert(Die->getTag() == InputDIE.getTag());
tools/dsymutil/MachOUtils.cpp
  463   assert(OutFile.tell() == HeaderSize);
  468     assert(OutFile.tell() == HeaderSize + sizeof(UUIDCmd));
  479   assert(SymtabCmd.cmd && "No symbol table.");
  521   assert(OutFile.tell() == LoadCommandSize + HeaderSize);
  523   assert(OutFile.tell() == SymtabStart);
  528     assert(OutFile.tell() == StringStart);
  544   assert(OutFile.tell() == StringStart + NewStringsSize);
  548   assert(OutFile.tell() == DwarfSegmentStart);
tools/gold/gold-plugin.cpp
  676   assert(options::thinlto_object_suffix_replace.empty() ||
  715   assert(InputFileSyms.size() == F.syms.size());
  831   assert(PrefixReplace.empty() || PrefixReplace.find(";") != StringRef::npos);
  975   assert(options::thinlto_index_only);
 1021     assert(ObjFilename.second);
tools/llc/llc.cpp
  462   assert(Target && "Could not allocate target machine!");
  470   assert(M && "Should have exited if we didn't have a module!");
  582       assert(MMIWP && "Forgot to create MMIWP?");
tools/lld/COFF/Chunks.cpp
  418   assert(child->assocChildren == nullptr &&
  595   assert(isCodeView());
  710   assert(config->machine == ARMNT);
  715   assert(config->machine == ARMNT);
  730   assert(config->machine == ARM64);
  735   assert(config->machine == ARM64);
  761   assert(std::unique(begin, begin + cnt) == begin + cnt &&
  871   assert(isPowerOf2_32(c->getAlignment()));
  873   assert(p2Align < array_lengthof(instances));
  881   assert(!finalized && "should only finalize once");
tools/lld/COFF/Chunks.h
   72     assert(llvm::isPowerOf2_32(align) && "alignment is not a power of 2");
   74     assert(p2Align <= Log2MaxSectionAlignment &&
   90     assert(rva == v && "RVA truncated");
  261     assert(relocsSize == newRelocs.size() && "reloc size truncation");
tools/lld/COFF/DebugTypes.cpp
  121   assert(source->kind == TpiSource::UsingPCH);
  127   assert(source->kind == TpiSource::UsingPDB);
  186   assert(it != TypeServerSource::instances.end());
tools/lld/COFF/Driver.cpp
  149   assert(config->machine != IMAGE_FILE_MACHINE_UNKNOWN);
  539   assert(config->subsystem != IMAGE_SUBSYSTEM_UNKNOWN &&
  705   assert(arg->getOption().getID() == OPT_lldmap);
tools/lld/COFF/MarkLive.cpp
   59     assert(sc->live && "We mark as live when pushing onto the worklist!");
tools/lld/COFF/PDB.cpp
  315   assert(canUseDebugH(debugH));
  496   assert(precompIndexMap.isPrecompiledTypeMap);
  501   assert(precomp.getStartTypeIndex() == TypeIndex::FirstNonSimpleIndex);
  502   assert(precomp.getTypesCount() <= precompIndexMap.tpiMap.size());
  674     assert(refs.size() == 1);
  675     assert(refs.front().Count == 1);
  687       assert(indices.size() == 2);
  702   assert(size >= 4 && "record too short");
  703   assert(size <= MaxRecordLength && "record too long");
  704   assert(alignedMem.size() >= size && "didn't preallocate enough");
  731   assert(symbolOpensScope(sym.kind()));
  943   assert(debugChunk.getOutputSectionIdx() == 0 &&
 1003       assert(!cVStrTab.valid() &&
 1009       assert(!checksums.valid() &&
 1019       assert(!inlineeLines.valid() &&
 1263   assert(os && "all publics should be in final image");
 1460   assert(!sec->chunks.empty());
 1745         assert(!cVStrTab.valid() &&
 1751         assert(!checksums.valid() &&
 1773         assert(!lines.header() &&
tools/lld/COFF/Symbols.cpp
   69     assert(nameSize == nameStr.size() && "name length truncated");
  107   assert(symSize == sizeof(coff_symbol32));
  120   assert(machine == ARMNT);
tools/lld/COFF/Symbols.h
  447   assert(static_cast<Symbol *>(static_cast<T *>(nullptr)) == nullptr &&
tools/lld/COFF/Writer.cpp
  323     assert(!config->debug || name.size() <= COFF::NameSize ||
  576     assert(addressesChanged);
  619     assert(buildId);
 1076   assert(str.size() > COFF::NameSize);
 1418       assert(b->getRVA() >= sc->getRVA());
 1768     assert(buildId && "BuildId is not set!");
 1858     assert(sa && sb && "Non-section chunks in CRT section!");
tools/lld/Common/Args.cpp
   25   assert(optLevelLTO < 3);
tools/lld/Common/ErrorHandler.cpp
  139     assert(m.size() == 2 || m.size() == 3);
tools/lld/ELF/ARMErrataFix.cpp
  197   assert((sourceAddr & 0xfff) == 0xffe);
tools/lld/ELF/Arch/AMDGPU.cpp
   48   assert(!objectFiles.empty());
tools/lld/ELF/Arch/Hexagon.cpp
   60   assert(!objectFiles.empty());
tools/lld/ELF/Arch/MipsArchTree.cpp
   67   assert(!files.empty() && "expected non-empty file list");
tools/lld/ELF/Arch/PPC64.cpp
  159   assert(config->tocOptimize);
  181   assert(!d->isGnuIFunc());
tools/lld/ELF/Arch/RISCV.cpp
  109   assert(!objectFiles.empty());
tools/lld/ELF/Arch/X86.cpp
  377     assert(type == R_386_TLS_GOTIE);
tools/lld/ELF/Arch/X86_64.cpp
  204     assert(type == R_X86_64_GOTPC32_TLSDESC);
  244     assert(type == R_X86_64_GOTPC32_TLSDESC);
  426   assert(type == R_X86_64_REX_GOTPCRELX);
  512     assert(!config->isPic);
  530   assert(modRm == 0x25);
tools/lld/ELF/Driver.cpp
 1044   assert(config->versionDefinitions.empty());
tools/lld/ELF/ICF.cpp
  309   assert(a->getParent() && b->getParent());
  325   assert(ra.size() == rb.size());
tools/lld/ELF/InputFiles.cpp
  880     assert(isUInt<31>(target->numRelocations));
tools/lld/ELF/InputFiles.h
   82     assert(fileKind == ObjKind || fileKind == BinaryKind);
   91     assert(fileKind == BinaryKind || fileKind == ObjKind ||
tools/lld/ELF/InputSection.cpp
  237   assert(flags & SHF_COMPRESSED);
  277   assert(link);
  278   assert(flags & SHF_LINK_ORDER);
  895     assert(rel.expr == R_ABS);
  922   assert(flags & SHF_ALLOC);
 1249   assert((size % entSize) == 0);
 1275   assert(pieces.empty());
tools/lld/ELF/InputSection.h
  146     assert(!areRelocsRela);
  153     assert(areRelocsRela);
  199     assert(s % sizeof(T) == 0);
tools/lld/ELF/LinkerScript.cpp
   53   assert(os && "input section has no output section assigned");
  281   assert(!ctx);
  691         assert(isa<MergeInputSection>(s) ||
  745   assert(ctx->outSec == s->getParent());
tools/lld/ELF/OutputSections.cpp
  240   assert(isLive());
  342   assert(config->relocatable);
  435   assert(x.startswith(".ctors") || x.startswith(".dtors"));
  436   assert(y.startswith(".ctors") || y.startswith(".dtors"));
  446   assert(sectionCommands.size() == 1);
tools/lld/ELF/Relocations.cpp
  122   assert(0 <= expr && (int)expr < 64 &&
  414   assert(absVal && relE);
  830     assert(undef.locs.size() == 1);
  919     assert(pieces[i].inputOff <= off && "Relocation not in any piece");
tools/lld/ELF/ScriptLexer.cpp
  295   assert(!mbs.empty() && pos > 0);
tools/lld/ELF/ScriptParser.cpp
  932   assert(op == "=" || op == "+=");
tools/lld/ELF/Symbols.cpp
   66     assert(isec != &InputSection::discarded);
  130     assert(sym.isUsedInRegularObj && "lazy symbol reached writer");
  166   assert(ppc64BranchltIndex != 0xffff);
  183   assert(ppc64BranchltIndex != 0xffff);
  520   assert(other->isDefined() || other->isCommon());
tools/lld/ELF/SyntheticSections.cpp
  335   assert(buf.size() == hashSize);
  461   assert(!this->size); // Not finalized.
 1095   assert(sym.pltIndex == entries.size());
 1139   assert(sym.pltIndex == entries.size());
 2056   assert(this->type != SHT_DYNSYM || !b->isLocal());
 3033   assert(alignment == ms->alignment || !(ms->flags & SHF_STRINGS));
 3321     assert(isec->getParent() != nullptr);
 3340   assert(size == offset + 8);
 3432   assert(sym.ppc64BranchltIndex == 0xffff);
 3449     assert(sym->getVA());
tools/lld/ELF/SyntheticSections.h
  879     assert((hash >> 31) == 0);
 1144   assert(isLive());
tools/lld/ELF/Thunks.cpp
  298     assert(!dest.isPreemptible);
  899   assert((rel.type == R_PPC_REL24 || rel.type == R_PPC_PLTREL24) &&
  905   assert(type == R_PPC64_REL24 && "unexpected relocation type for thunk");
tools/lld/ELF/Writer.cpp
 1355     assert(sec->sectionCommands.size() == 1);
 1643   assert(!b.isLocal());
tools/lld/include/lld/Core/File.h
   88     assert(_ordinal != UINT64_MAX);
tools/lld/include/lld/Core/LinkingContext.h
   70     assert(!symbolName.empty() && "Empty symbol cannot be a dead strip root");
tools/lld/include/lld/Core/Simple.h
  129     assert(_target);
  204     assert(target && "trying to create reference to nothing");
  249     assert(!name.empty() && "UndefinedAtoms must have a name");
tools/lld/lib/Core/Error.cpp
   57     assert(ev >= 0);
   58     assert(ev < (int)_messages.size());
tools/lld/lib/Core/Resolver.cpp
  249       assert(!file->hasOrdinal());
  374     assert(symAtom);
tools/lld/lib/Core/SymbolTable.cpp
   40     assert(atom.merge() != DefinedAtom::mergeByContent);
   46     assert(atom.name().empty());
  109   assert(first != DefinedAtom::mergeByContent);
  110   assert(second != DefinedAtom::mergeByContent);
  116   assert(!name.empty());
  282     assert(atom != nullptr);
tools/lld/lib/ReaderWriter/MachO/ArchHandler.cpp
   62   assert((reloc.type & 0xFFF0) == 0);
  143   assert(atom->contentType() == DefinedAtom::typeCFI);
  159       assert(ref->kindArch() == kindArch() && "unexpected Reference arch");
tools/lld/lib/ReaderWriter/MachO/ArchHandler_arm.cpp
  340   assert(stubAtom.contentType() == DefinedAtom::typeStub);
  371   assert((displacement <= 33554428) && (displacement > (-33554432))
  380       assert(((instruction & 0xF0000000) == 0xE0000000)
  382       assert(((instruction & 0xFF000000) == 0xEB000000)
  427   assert((displacement <= 16777214) && (displacement > (-16777216))
  443     assert(targetIsThumb && "no pc-rel thumb branch instruction that "
  479   assert(isThumbMovw(instruction) || isThumbMovt(instruction));
  488   assert(isArmMovw(instruction) || isArmMovt(instruction));
  495   assert(isThumbMovw(instr) || isThumbMovt(instr));
  504   assert(isArmMovw(instr) || isArmMovt(instr));
  911   assert(ref.kindArch() == Reference::KindArch::ARM);
  927     assert(thumbMode);
  934     assert(thumbMode);
  941     assert(thumbMode);
  946     assert(thumbMode);
  953     assert(thumbMode);
  959    assert(!thumbMode);
  965     assert(!thumbMode);
  972     assert(!thumbMode);
  977     assert(!thumbMode);
  984     assert(!thumbMode);
 1074   assert(ref.kindArch() == Reference::KindArch::ARM);
 1092     assert(thumbMode);
 1103     assert(thumbMode);
 1111     assert(thumbMode);
 1119     assert(thumbMode);
 1124     assert(thumbMode);
 1130     assert(!thumbMode);
 1140     assert(!thumbMode);
 1148     assert(!thumbMode);
 1156     assert(!thumbMode);
 1161     assert(!thumbMode);
 1191   assert(ref.kindArch() == Reference::KindArch::ARM);
 1407     assert(ref->kindArch() == Reference::KindArch::ARM);
 1454     assert(sizeof(bytes) == size());
 1499     assert(sizeof(bytes) == size());
tools/lld/lib/ReaderWriter/MachO/ArchHandler_arm64.cpp
   46     assert(ref.kindArch() == Reference::KindArch::AArch64);
   68     assert(ref->kindNamespace() == Reference::KindNamespace::mach_o);
   69     assert(ref->kindArch() == Reference::KindArch::AArch64);
  318   assert(ref.kindArch() == Reference::KindArch::AArch64);
  325   assert(ref.kindArch() == Reference::KindArch::AArch64);
  336   assert((displacement <= 134217727) && (displacement > (-134217728)) &&
  343   assert((displacement <= 0x100000000LL) && (displacement > (-0x100000000LL)) &&
  345   assert(((instruction & 0x9F000000) == 0x90000000) &&
  372   assert(((offset & 0xFFFFF000) == 0) && "imm12 offset out of range");
  591   assert(ref.kindArch() == Reference::KindArch::AArch64);
  618     assert(((displacement & 0x1) == 0) &&
  624     assert(((displacement & 0x3) == 0) &&
  630     assert(((displacement & 0x7) == 0) &&
  636     assert(((displacement & 0xF) == 0) &&
  642     assert(((instruction & 0xFFC00000) == 0xF9400000) &&
  679     assert(value64 < 0xffffffU && "offset in __eh_frame too large");
  697   assert(ref.kindArch() == Reference::KindArch::AArch64);
  781   assert(ref.kindArch() == Reference::KindArch::AArch64);
  822     assert(ref.addend() == 0);
  827     assert(ref.addend() == 0);
  832     assert(ref.addend() == 0);
  837     assert(ref.addend() == 0);
  862     assert(ref.addend() == 0);
  867     assert(ref.addend() == 0);
tools/lld/lib/ReaderWriter/MachO/ArchHandler_x86.cpp
  445   assert(ref.kindArch() == Reference::KindArch::x86);
  488   assert(ref.kindArch() == Reference::KindArch::x86);
  561   assert(ref.kindArch() == Reference::KindArch::x86);
tools/lld/lib/ReaderWriter/MachO/ArchHandler_x86_64.cpp
   45     assert(ref.kindArch() == Reference::KindArch::x86_64);
   62     assert(ref.kindNamespace() == Reference::KindNamespace::mach_o);
   63     assert(ref.kindArch() == Reference::KindArch::x86_64);
   68     assert(ref->kindNamespace() == Reference::KindNamespace::mach_o);
   69     assert(ref->kindArch() == Reference::KindArch::x86_64);
   70     assert(ref->kindValue() == ripRel32Tlv);
   76     assert(ref->kindNamespace() == Reference::KindNamespace::mach_o);
   77     assert(ref->kindArch() == Reference::KindArch::x86_64);
   81       assert(targetNowGOT && "target must be GOT");
  343   assert(ref.kindArch() == Reference::KindArch::x86_64);
  350   assert(ref.kindArch() == Reference::KindArch::x86_64);
  460       assert(*addend == 0 && "TLV-init has non-zero addend?");
  579   assert(ref.kindArch() == Reference::KindArch::x86_64);
  621     assert(loc[-2] == 0x8B);
  645     assert(val < 0xffffffU && "offset in __eh_frame too large");
  663   assert(ref.kindArch() == Reference::KindArch::x86_64);
  774   assert(ref.kindArch() == Reference::KindArch::x86_64);
tools/lld/lib/ReaderWriter/MachO/CompactUnwindPass.cpp
  305     assert(personalities.size() <= 4);
  404         assert(ref->addend() == 0 && "unexpected offset into function");
  408         assert(ref->addend() == 0 && "unexpected offset into personality fn");
  412         assert(ref->addend() == 0 && "unexpected offset into LSDA atom");
  558     assert(personalityIdx < 4 && "too many personality functions");
  575   assert(ctx.needsCompactUnwindPass());
tools/lld/lib/ReaderWriter/MachO/File.h
   44     assert(sectionOffset+contentSize <= inSection->content.size());
   66     assert(sectionOffset+contentSize <= inSection->content.size());
  147     assert(offsetInSect < section.content.size());
  353       assert(!entry->second.atom && "Duplicate shared library export");
  364       assert(dylib.file);
tools/lld/lib/ReaderWriter/MachO/GOTPass.cpp
  109         assert(target != nullptr);
  148       assert(defTarget->scope() != DefinedAtom::scopeTranslationUnit);
  178   assert(ctx.needsGOTPass());
tools/lld/lib/ReaderWriter/MachO/LayoutPass.cpp
   46       assert(compareAtoms(*i, *j, customSorter));
   47       assert(!compareAtoms(*j, *i, customSorter));
  277     assert(targetFollowOnAtomsIter != _followOnNexts.end());
  300     assert(targetFollowOnAtomsIter != _followOnNexts.end());
tools/lld/lib/ReaderWriter/MachO/MachOLinkingContext.cpp
  142   assert(arch != arch_unknown);
  151   assert(arch != arch_unknown);
  293   assert(arch != arch_unknown);
  303   assert(arch != arch_unknown);
  810   assert(_sectCreateFile && "sectcreate file does not exist.");
  940   assert(objFile);
 1066       assert((_objcConstraint == objc_unknown ||
 1078       assert((_objcConstraint == objc_unknown ||
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryUtils.h
   40     assert(min <= byteCount);
   73   assert((uint64_t)loc % alignof(T) == 0 && "invalid pointer alignment");
   79   assert((uint64_t)loc % alignof(T) == 0 && "invalid pointer alignment");
   85   assert((uint64_t)loc % alignof(T) == 0 && "invalid pointer alignment");
  122   assert((newBits & mask) == newBits);
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileBinaryWriter.cpp
 1016   assert(lc == &_buffer[_endOfLoadCommands]);
 1028     assert(offset >= _endOfLoadCommands);
 1297     assert(entry.otherOffset != 0);
 1300     assert(entry.otherOffset != 0);
 1377         assert(nodeSize < 256);
 1386         assert(nodeSize < 256);
 1397       assert(nodeSize < 256);
 1406       assert(nodeSize < 256);
 1417   assert(_children.size() < 256);
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileFromAtoms.cpp
  364     assert(seperatorIndex != StringRef::npos);
  659     assert(pos != _atomToAddress.end());
  687         assert(ai.atom->begin() == ai.atom->end() &&
  857     assert(dyn_cast_or_null<lld::mach_o::DwarfDebugInfo>(atomFile.debugInfo())
 1299     assert(pos != _atomToSymbolIndex.end());
 1311     assert(pos != _atomToAddress.end());
 1351       assert(addr != badAddress && "Missing mach header symbol");
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileToAtoms.cpp
  558     assert(symbolIndex >= numStabs && "Searched for stab via atomBySymbol?");
  613     assert(inAtom && "r_address in range, should have found atom");
 1235       assert(ref->kindValue() == refKind &&
 1246       assert(!addend && "EHFrame reference cannot have addend");
 1268   assert(cie && cie->contentType() == DefinedAtom::typeCFI &&
 1340     assert(atom->contentType() == DefinedAtom::typeCFI);
 1577       assert((sym.scope & N_EXT) && "only expect external symbols here");
tools/lld/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp
  332       assert(info != nullptr);
  334       assert(file != nullptr);
  371     assert(info != nullptr);
  373     assert(file != nullptr);
  763   assert(info != nullptr);
  764   assert(info->_normalizeMachOFile == nullptr);
tools/lld/lib/ReaderWriter/MachO/ShimPass.cpp
   57         assert(target != nullptr);
   94     assert(shim != nullptr);
  103       assert(pos->second != nullptr);
tools/lld/lib/ReaderWriter/MachO/StubsPass.cpp
  229         assert(target != nullptr);
  239           assert(defTarget->scope() != DefinedAtom::scopeTranslationUnit);
  277     assert(I != mergedFile.sharedLibrary().end() &&
  315         assert(ref->target() == target);
tools/lld/lib/ReaderWriter/MachO/TLVPass.cpp
   89         assert(target != nullptr);
  135   assert(ctx.needsTLVPass());
tools/lld/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp
  114     assert(!atom.name().empty());
  261     assert(ctxt != nullptr);
  263     assert(info->_registry);
  273     assert(ctxt != nullptr);
  275     assert(info->_registry);
  530     assert(io.outputting() && "AtomRange only used when outputting");
  531     assert(index < seq.size() && "Out of range access");
  694     assert(info != nullptr);
  708     assert(info != nullptr);
  758       assert(info != nullptr);
  839       assert(info != nullptr);
  860       assert(info != nullptr);
  861       assert(info->_file != nullptr);
  901       assert(index < _references.size());
  914       assert(target && "trying to create reference to nothing");
  948       assert(info != nullptr);
  950       assert(f);
  951       assert(f->_rnb);
 1010       assert(info != nullptr);
 1026       assert(info != nullptr);
 1027       assert(info->_file != nullptr);
 1076       assert(info != nullptr);
 1095       assert(info != nullptr);
 1096       assert(info->_file != nullptr);
 1152       assert(info != nullptr);
 1168       assert(info != nullptr);
 1169       assert(info->_file != nullptr);
 1193       assert(info != nullptr);
 1195       assert(f);
 1196       assert(f->_rnb);
 1283   assert(info != nullptr);
 1370     assert(createdFiles.size() == 1);
tools/lld/wasm/Driver.cpp
  511     assert(WasmSym::initMemoryFlag);
tools/lld/wasm/InputChunks.cpp
  167   assert(!hasFunctionIndex());
  174   assert(!hasTableIndex());
tools/lld/wasm/InputChunks.h
  138       assert(compressedSize);
  164     assert(!config->compressRelocations);
  207     assert(section.Type == llvm::wasm::WASM_SEC_CUSTOM);
tools/lld/wasm/InputEvent.h
   40     assert(!hasEventIndex());
tools/lld/wasm/InputFiles.cpp
   93     assert(typeIsUsed[reloc.Index]);
  224   assert(std::is_sorted(relocs.begin(), relocs.end(),
  228   assert(std::is_sorted(
  291       assert(!codeSection);
  294       assert(!dataSection);
  424     assert(sym.isBindingLocal());
tools/lld/wasm/InputGlobal.h
   34     assert(!hasGlobalIndex());
tools/lld/wasm/OutputSections.cpp
  139   assert((!config->isPic || segments.size() <= 1) &&
  241   assert(offset);
tools/lld/wasm/Relocations.cpp
   36   assert(sym->isUndefined());
   37   assert(!sym->isWeak());
tools/lld/wasm/SymbolTable.cpp
  199   assert(!find(name));
  225   assert(!find(name));
  233   assert(!find(name));
  434   assert(flags & WASM_SYMBOL_UNDEFINED);
  479   assert(flags & WASM_SYMBOL_UNDEFINED);
  501   assert(flags & WASM_SYMBOL_UNDEFINED);
  589     assert(*variant->getSignature() == *sig);
  650       assert(!isa<FunctionSymbol>(sym));
tools/lld/wasm/Symbols.cpp
  128   assert(!isDiscarded());
  139   assert(outputSymbolIndex != INVALID_INDEX);
  146   assert(outputSymbolIndex == INVALID_INDEX);
  152   assert(gotIndex == INVALID_INDEX);
  202   assert(functionIndex != INVALID_INDEX);
  208   assert(functionIndex == INVALID_INDEX);
  221   assert(tableIndex != INVALID_INDEX);
  240   assert(tableIndex == INVALID_INDEX);
  265   assert(!segment);
  282   assert(globalIndex != INVALID_INDEX);
  288   assert(globalIndex == INVALID_INDEX);
  307   assert(eventIndex != INVALID_INDEX);
  313   assert(eventIndex == INVALID_INDEX);
  331   assert(section->outputSec && section->outputSec->sectionSym);
tools/lld/wasm/Symbols.h
  117     assert(gotIndex != INVALID_INDEX);
  524   assert(static_cast<Symbol *>(static_cast<T *>(nullptr)) == nullptr &&
tools/lld/wasm/SyntheticSections.cpp
   95   assert(isSealed);
  105   assert(!isSealed);
  114   assert(!isSealed);
  253   assert(!isSealed);
  279       assert(isa<UndefinedData>(sym));
  294   assert(!isSealed);
  362     assert(sym->getTableIndex() == tableIndex);
  392       assert(sym->isDefined() || sym->isUndefined());
  468       assert(isec->getComdatName() == comdat);
  575   assert(sec->sectionIndex != UINT32_MAX);
tools/lld/wasm/SyntheticSections.h
   45     assert(offset);
  109     assert(isSealed);
  113     assert(isSealed);
  117     assert(isSealed);
  178     assert(isSealed);
tools/lld/wasm/Writer.cpp
  185     assert(s->isNeeded());
  531         assert(g == WasmSym::stackPointer || g == WasmSym::tlsBase);
  717   assert(WasmSym::initMemoryFlag);
  943       assert(sym->isLive());
tools/lldb/include/lldb/Breakpoint/Breakpoint.h
  627     assert(m_hit_count > 0);
tools/lldb/include/lldb/Core/Debugger.h
  150     assert(m_command_interpreter_up.get());
tools/lldb/include/lldb/Core/LoadedModuleInfoList.h
   82       assert(datum < e_num);
tools/lldb/include/lldb/Core/Opcode.h
  187       assert(length < sizeof(m_data.inst.bytes));
tools/lldb/include/lldb/Core/RichManglingContext.h
   65     assert(m_provider != None && "Initialize a provider first");
   99     assert(parser.hasValue());
  100     assert(llvm::any_isa<ParserT *>(parser));
tools/lldb/include/lldb/Core/StreamFile.h
   38   StreamFile(std::shared_ptr<File> file) : m_file_sp(file) { assert(file); };
tools/lldb/include/lldb/Core/ValueObjectDynamicValue.h
   76     assert(m_owning_valobj_sp.get() == nullptr);
tools/lldb/include/lldb/DataFormatters/FormattersHelpers.h
   86       assert(false && "new pointer size is unknown");
tools/lldb/include/lldb/Interpreter/OptionValue.h
  313     assert(m_callback == nullptr);
tools/lldb/include/lldb/Interpreter/Options.h
  311     assert(m_did_finalize);
tools/lldb/include/lldb/Symbol/ClangASTImporter.h
  290           assert(m_delegate.m_std_handler == &m_handler);
  303       assert(m_new_decl_listener == nullptr && "Already attached a listener?");
tools/lldb/include/lldb/Target/ABI.h
  143     assert(m_mc_register_info_up && "ABI must have MCRegisterInfo");
tools/lldb/include/lldb/Target/Process.h
  313       assert(m_running_utility_function > 0 &&
tools/lldb/include/lldb/Utility/Args.h
  355     assert(m_has_args);
  363     assert(m_has_args);
  373     assert(m_has_args);
  382     assert(m_has_args);
tools/lldb/include/lldb/Utility/ProcessInfo.h
  186     assert(idx < m_infos.size());
tools/lldb/include/lldb/Utility/Reproducer.h
  127     assert(m_version.empty());
  177     assert(m_record);
tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h
  202     assert(idx != 0 && "Cannot get object for sentinel");
  305     assert(result == 0);
  316     assert(HasData(sizeof(T)));
  686       assert(!m_result_recorded);
tools/lldb/include/lldb/Utility/StructuredData.h
  189       assert(idx < GetSize());
tools/lldb/source/API/SBAddress.cpp
  197   assert(m_opaque_up.get());
tools/lldb/source/API/SBBreakpointOptionCommon.cpp
   66         assert(bp_sp);
tools/lldb/source/API/SBCommandInterpreter.cpp
  550   assert(m_opaque_ptr);
  654       assert(command_name_str.empty());
tools/lldb/source/API/SBDebugger.cpp
 1208   assert(m_opaque_sp.get());
tools/lldb/source/API/SBListener.cpp
  151       assert(timeout_secs != 0); // Take this out after all calls with timeout
tools/lldb/source/API/SBMemoryRegionInfoList.cpp
  139   assert(m_opaque_up.get());
tools/lldb/source/API/SBStructuredData.cpp
  139   assert(dict);
  143   assert(key_arr);
tools/lldb/source/API/SBSymbolContext.cpp
  182   assert(m_opaque_up.get());
tools/lldb/source/API/SBSymbolContextList.cpp
  104   assert(m_opaque_up.get());
tools/lldb/source/API/SBType.cpp
  104   assert(m_opaque_sp.get());
tools/lldb/source/Breakpoint/Breakpoint.cpp
  862   assert(s != nullptr);
tools/lldb/source/Breakpoint/BreakpointLocationList.cpp
  256   assert (idx < m_locations.size());
  294   assert(m_new_location_recorder == nullptr);
tools/lldb/source/Breakpoint/BreakpointResolver.cpp
  273       assert(!blocks_with_breakpoints.count(first->block));
tools/lldb/source/Breakpoint/BreakpointResolverAddress.cpp
  125   assert(m_breakpoint != nullptr);
tools/lldb/source/Breakpoint/BreakpointResolverFileLine.cpp
  205   assert(m_breakpoint != nullptr);
tools/lldb/source/Breakpoint/BreakpointResolverFileRegex.cpp
  100   assert(m_breakpoint != nullptr);
  147   assert(m_breakpoint != nullptr);
tools/lldb/source/Breakpoint/BreakpointResolverName.cpp
  260   assert(m_breakpoint != nullptr);
tools/lldb/source/Breakpoint/BreakpointResolverScripted.cpp
  111   assert(m_breakpoint != nullptr);
  128   assert(m_breakpoint != nullptr);
tools/lldb/source/Breakpoint/StoppointLocation.cpp
   30   assert(m_hit_count > 0);
tools/lldb/source/Breakpoint/Watchpoint.cpp
  189   assert(description_level >= lldb::eDescriptionLevelBrief &&
tools/lldb/source/Commands/CommandCompletions.cpp
  171   assert(!PartialItem.contains(path::get_separator()));
tools/lldb/source/Commands/CommandObjectCommands.cpp
  690       assert(!sub_command.empty());
tools/lldb/source/Commands/CommandObjectExpression.cpp
  332   assert(original_code_size >= code.size());
  342   assert(cursor_pos >= raw_start);
tools/lldb/source/Commands/CommandObjectMemory.cpp
  876     assert(output_stream_p);
tools/lldb/source/Commands/CommandObjectMultiword.cpp
   72     assert((&GetCommandInterpreter() == &cmd_obj->GetCommandInterpreter()) &&
tools/lldb/source/Commands/CommandObjectReproducer.cpp
  246     assert(loader);
tools/lldb/source/Commands/CommandObjectSource.cpp
  151       assert(file_spec.GetFilename().AsCString());
  165         assert(module && cu);
  185         assert(module_file_name);
  216     assert(module);
  218       assert(file_spec.GetFilename().AsCString());
  256             assert(lldb_private::FileSpec::Equal(cu_file_spec, line_entry.file,
  317     assert(module_list.GetSize() > 0);
  513       assert(module);
tools/lldb/source/Commands/CommandObjectTarget.cpp
 2393       assert(option_idx == 0 && "We only have one option.");
tools/lldb/source/Commands/CommandObjectThread.cpp
  642       assert(frame != nullptr);
tools/lldb/source/Core/Address.cpp
  147       assert(module_sp);
  254       assert(section_sp->ContainsFileAddress(file_addr));
  908   assert(target != nullptr);
tools/lldb/source/Core/Debugger.cpp
  512   assert(g_debugger_list_ptr == nullptr &&
  520   assert(g_debugger_list_ptr &&
  724   assert(default_platform_sp);
  728   assert(m_dummy_target_sp.get() && "Couldn't construct dummy target?");
  825   assert(file_sp && file_sp->IsValid());
  834   assert(file_sp && file_sp->IsValid());
  839   assert(file_sp && file_sp->IsValid());
 1191   assert(log_stream_sp);
 1302     assert(process_sp);
tools/lldb/source/Core/Disassembler.cpp
  891       assert(value.empty() == false);
  892       assert(key.empty() == false);
  895         assert(value.size() == 1);
  903         assert(value.size() == 1);
tools/lldb/source/Core/DumpDataExtractor.cpp
  533         assert(item_bit_size == 0 && item_bit_offset == 0);
tools/lldb/source/Core/DynamicLoader.cpp
  131   assert(sections && "SectionList missing from unloaded module.");
tools/lldb/source/Core/Mangled.cpp
  204     assert(demangled_cstr &&
  206     assert(demangled_cstr[demangled_size - 1] == '\0' &&
  232   assert(m_mangled);
tools/lldb/source/Core/Module.cpp
  265     assert(pos != end);
tools/lldb/source/Core/PluginManager.cpp
   84   assert(plugin_map.find(plugin_file_spec) == plugin_map.end());
  227     assert((bool)name);
  356     assert((bool)name);
  441     assert((bool)name);
  526     assert((bool)name);
  606     assert((bool)name);
  690     assert((bool)name);
  771     assert((bool)name);
  853     assert((bool)name);
  953     assert((bool)name);
 1042     assert((bool)name);
 1179     assert((bool)name);
 1276     assert((bool)name);
 1392     assert((bool)name);
 1492   assert((bool)name);
 1547   assert(none_instance != nullptr);
 1587     assert((bool)name);
 1689     assert((bool)name);
 1769     assert((bool)name);
 1849     assert((bool)name);
 1929     assert((bool)name);
 2013     assert((bool)name);
 2112     assert((bool)name);
 2212     assert((bool)name);
tools/lldb/source/Core/RichManglingContext.cpp
   26     assert(m_provider == PluginCxxLanguage);
   31   assert(new_provider != None && "Only reset to a valid provider");
   61   assert(m_provider != None && "Initialize a provider first");
   78   assert(m_provider != None && "Initialize a provider first");
   93     assert(res_size == m_ipd_buf_size &&
  102   assert(ipd_res[res_size - 1] == '\0' &&
  120   assert(m_provider != None && "Initialize a provider first");
  138   assert(m_provider != None && "Initialize a provider first");
  156   assert(m_provider != None && "Initialize a provider first");
tools/lldb/source/Core/SourceManager.cpp
  566     assert(start_line_offset <= end_line_offset);
  658       assert("Not implemented yet" && false);
  663     assert("Not implemented yet" && false);
tools/lldb/source/Core/ValueObject.cpp
  258       assert(!need_compare_checksums ||
 2513       assert(!bracket_expr.empty());
tools/lldb/source/Core/ValueObjectMemory.cpp
   52   assert(m_type_sp.get() != nullptr);
   79   assert(m_compiler_type.GetTypeSystem());
   80   assert(m_compiler_type.GetOpaqueQualType());
tools/lldb/source/Core/ValueObjectRegister.cpp
   43   assert(reg_ctx);
  118   assert(reg_ctx);
  236   assert(reg_ctx_sp.get());
  251   assert(reg_ctx);
tools/lldb/source/Core/ValueObjectVariable.cpp
   60   assert(m_variable_sp.get() != nullptr);
tools/lldb/source/DataFormatters/StringPrinter.cpp
  418   assert(options.GetStream() && "need a Stream to print the string to");
  518   assert(options.GetStream() && "need a Stream to print the string to");
  617   assert(options.GetStream() && "need a Stream to print the string to");
  635   assert(options.GetStream() && "need a Stream to print the string to");
  644   assert(options.GetStream() && "need a Stream to print the string to");
tools/lldb/source/DataFormatters/ValueObjectPrinter.cpp
   53   assert(m_orig_valobj && "cannot print a NULL ValueObject");
   54   assert(m_stream && "cannot print to a NULL Stream");
tools/lldb/source/Expression/DWARFExpression.cpp
 2710   assert(false && "Not supported location list type");
tools/lldb/source/Expression/Expression.cpp
   21   assert(m_target_wp.lock());
   29   assert(m_target_wp.lock());
tools/lldb/source/Expression/FunctionCaller.cpp
   48   assert(m_jit_process_wp.lock());
tools/lldb/source/Expression/IRInterpreter.cpp
 1557           assert(Success &&
 1566           assert(!error.Fail() &&
tools/lldb/source/Expression/REPL.cpp
  492     assert(matches.GetSize() == 1);
  546       assert(command_name_str.empty());
tools/lldb/source/Host/common/Editline.cpp
  882   assert(!results.empty());
tools/lldb/source/Host/common/FileSystem.cpp
  441   assert(file->IsValid());
tools/lldb/source/Host/common/Host.cpp
  174   assert(info->pid <= UINT32_MAX);
  655   assert(Options.empty());
tools/lldb/source/Host/common/MainLoop.cpp
   66   assert(signo < NSIG);
  155   assert(ret == 0);
  267   assert(m_read_fds.size() == 0);
  268   assert(m_signals.size() == 0);
  324   assert(ret == 0 && "sigaction failed");
  338   assert(ret == 0 && "pthread_sigmask failed");
  349   assert(erased);
  357   assert(it != m_signals.end());
  366   assert(ret == 0);
tools/lldb/source/Host/common/MonitoringProcessLauncher.cpp
   47   assert(!resolved_info.GetFlags().Test(eLaunchFlagLaunchInTTY));
   55     assert(launch_info.GetMonitorProcessCallback());
tools/lldb/source/Host/common/NativeProcessProtocol.cpp
   30   assert(registered);
  162     assert(thread && "thread list should not have a NULL thread!");
  203     assert(thread && "thread list should not have a NULL thread!");
  249     assert(thread && "thread list should not have a NULL thread!");
  288     assert(thread && "thread list should not have a NULL thread!");
  383   assert(it->second.ref_count > 0);
tools/lldb/source/Host/common/NativeRegisterContext.cpp
  221   assert(reg_info);
  413   assert(kind < kNumRegisterKinds);
tools/lldb/source/Host/common/SocketAddress.cpp
  111   assert(0 && "Unsupported address family");
tools/lldb/source/Host/posix/ConnectionFileDescriptorPosix.cpp
  619           assert(bytes_read == 1);
tools/lldb/source/Initialization/SystemLifetimeManager.cpp
   22   assert(!m_initialized &&
   31     assert(!m_initializer && "Attempting to call "
tools/lldb/source/Interpreter/CommandInterpreter.cpp
 2044   assert(!m_skip_lldbinit_files);
tools/lldb/source/Interpreter/CommandObject.cpp
  144   assert(!m_exe_ctx.GetTargetPtr());
  145   assert(!m_exe_ctx.GetProcessPtr());
  146   assert(!m_exe_ctx.GetThreadPtr());
  147   assert(!m_exe_ctx.GetFramePtr());
  908   assert(arg_type < eArgTypeLastArg &&
  915   assert(arg_type < eArgTypeLastArg &&
  929   assert(m_flags.AnySet(eCommandRequiresTarget | eCommandProcessMustBePaused |
tools/lldb/source/Interpreter/OptionValueDictionary.cpp
  229   assert(!temp.empty());
tools/lldb/source/Interpreter/OptionValueProperties.cpp
   54     assert(property.IsValid());
  559       assert(option_value);
tools/lldb/source/Interpreter/Options.cpp
  317       assert(start < final_end);
  318       assert(start + sub_len <= final_end);
  850   assert(m_did_finalize);
  925     assert(pos != original.end());
tools/lldb/source/Plugins/ABI/SysV-arc/ABISysV_arc.cpp
  240   assert(!prototype.isFunctionVarArg());
  241   assert(prototype.getFunctionNumParams() == args.size());
tools/lldb/source/Plugins/ABI/SysV-hexagon/ABISysV_hexagon.cpp
 1120   assert(prototype.getFunctionNumParams() == args.size());
tools/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp
 1071   assert(reg_info->name != nullptr && "unnamed register?");
tools/lldb/source/Plugins/ABI/Windows-x86_64/ABIWindows_x86_64.cpp
 1768   assert(reg_info->name != nullptr && "unnamed register?");
tools/lldb/source/Plugins/Disassembler/llvm/DisassemblerLLVMC.cpp
 1011   assert(m_instr_info_up && m_reg_info_up && m_subtarget_info_up &&
tools/lldb/source/Plugins/DynamicLoader/Hexagon-DYLD/DynamicLoaderHexagonDYLD.cpp
   48   assert(proc != nullptr);
   51   assert(module.get() != nullptr);
   54   assert(exe != nullptr);
   57   assert(symtab != nullptr);
   61     assert(sym != nullptr);
  222   assert(sections && "SectionList missing from loaded module.");
  253   assert(sections && "SectionList missing from unloaded module.");
  297     assert(target.GetBreakpointByID(m_dyld_bid)
tools/lldb/source/Plugins/DynamicLoader/Hexagon-DYLD/HexagonDYLDRendezvous.cpp
  130     assert(m_previous.state == eConsistent);
  136   assert(m_current.state == eConsistent);
  152   assert(m_previous.state == eAdd);
  181   assert(m_previous.state == eDelete);
tools/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
  446     assert(sizeof(buf) >= count_v13);
tools/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DYLDRendezvous.cpp
  372   assert(m_previous.state == eAdd);
  399   assert(m_previous.state == eDelete);
tools/lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp
  263   assert(baton && "null baton");
  384   assert(baton && "null baton");
tools/lldb/source/Plugins/DynamicLoader/Windows-DYLD/DynamicLoaderWindowsDYLD.cpp
  221   assert(first_insn->DoesBranch() && !second_insn->DoesBranch());
tools/lldb/source/Plugins/ExpressionParser/Clang/ASTUtils.h
   26     assert(m_Source && "Can't wrap nullptr ExternalASTSource");
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.cpp
  658         assert(copied_decl->getDeclContext()->containsDecl(copied_decl));
  661         assert(!decl_context_non_const->containsDecl(copied_decl));
  684   assert(m_ast_context);
  814   assert(m_ast_context);
 2089   assert(type && "Type for variable must be valid!");
 2113   assert(type && "Type for variable must be valid!");
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionDeclMap.cpp
  125   assert(m_parser_vars);
  162   assert(m_parser_vars.get());
  211   assert(&target == m_target->GetScratchClangASTContext());
  212   assert((TypeSystem *)&source == parser_type.GetTypeSystem());
  213   assert(source.getASTContext() == m_ast_context);
  243   assert(m_parser_vars.get());
  355   assert(m_struct_vars.get());
  356   assert(m_parser_vars.get());
  442   assert(m_struct_vars.get());
  460   assert(m_struct_vars.get());
  477   assert(m_struct_vars.get());
  629   assert(m_parser_vars.get());
  688   assert(m_ast_context);
  777   assert(m_ast_context);
 1616   assert(m_parser_vars.get());
 1654   assert(entity);
 1716   assert(m_parser_vars.get());
 1894   assert(m_parser_vars.get());
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionParser.cpp
  427   assert(m_compiler->hasTarget());
  750     assert(false && "Unknown completion result type?");
 1007     assert(m_compiler->getASTContext().getExternalSource() &&
 1009     assert(m_compiler->getSema().getExternalSource() &&
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangFunctionCaller.cpp
   56   assert(m_jit_process_wp.lock());
tools/lldb/source/Plugins/ExpressionParser/Clang/ClangUserExpression.cpp
  726   assert(abs_pos <= code.size() && "Absolute position outside code string?");
tools/lldb/source/Plugins/ExpressionParser/Clang/CppModuleConfiguration.h
   36       assert(m_valid && "Called Get() on an invalid SetOncePath?");
tools/lldb/source/Plugins/ExpressionParser/Clang/IRDynamicChecks.cpp
  427     assert(target_object);
  428     assert(selector);
tools/lldb/source/Plugins/Instruction/ARM/EmulationStateARM.cpp
  230   assert(dwarf_reg_num != LLDB_INVALID_REGNUM);
  249   assert(dwarf_reg_num != LLDB_INVALID_REGNUM);
tools/lldb/source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.cpp
   88   assert(target);
  148   assert(m_reg_info.get());
  151   assert(m_insn_info.get());
  158   assert(m_asm_info.get() && m_subtype_info.get());
  162   assert(m_context.get());
  165   assert(m_disasm.get());
  175   assert(m_alt_subtype_info.get());
  179   assert(m_alt_disasm.get());
tools/lldb/source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.cpp
   88   assert(target);
  152   assert(m_reg_info.get());
  155   assert(m_insn_info.get());
  162   assert(m_asm_info.get() && m_subtype_info.get());
  166   assert(m_context.get());
  169   assert(m_disasm.get());
tools/lldb/source/Plugins/InstrumentationRuntime/ASan/ASanRuntime.cpp
  241   assert(baton && "null baton");
tools/lldb/source/Plugins/InstrumentationRuntime/MainThreadChecker/MainThreadCheckerRuntime.cpp
  154   assert(baton && "null baton");
tools/lldb/source/Plugins/InstrumentationRuntime/TSan/TSanRuntime.cpp
  797   assert(baton && "null baton");
tools/lldb/source/Plugins/InstrumentationRuntime/UBSan/UBSanRuntime.cpp
  208   assert(baton && "null baton");
tools/lldb/source/Plugins/JITLoader/GDB/JITLoaderGDB.cpp
  392       assert(false && "Unknown jit action");
tools/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusLanguage.cpp
   89   assert(left_right_chars.size() == 2);
tools/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.cpp
  100   assert(HasMoreTokens());
  314   assert(counter >= 0);
  606   assert(range.begin_index < range.end_index);
  607   assert(range.begin_index < m_tokens.size());
  608   assert(range.end_index <= m_tokens.size());
tools/lldb/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.h
   75       assert(end >= begin);
tools/lldb/source/Plugins/Language/ClangCommon/ClangHighlighter.cpp
  236     assert(false && "We couldn't find the user line in the input file?");
tools/lldb/source/Plugins/Language/ObjC/Cocoa.cpp
  764   assert(encodedBits.unused == 0);
tools/lldb/source/Plugins/Language/ObjC/NSSet.cpp
  487       assert(false && "pointer size is not 4 nor 8 - get out of here ASAP");
  654       assert(false && "pointer size is not 4 nor 8 - get out of here ASAP");
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp
   98   assert(m_process == process);
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV1.cpp
  172   assert(strformatsize < (int)sizeof(buf->contents));
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
  441   assert(m_process != nullptr);
  450     assert(process == m_process);
  452     assert(in_value.GetTargetSP().get() == m_process->CalculateTarget().get());
  888   assert(len < (int)sizeof(check_function_code));
 1032       assert(&m_parent == &rhs.m_parent);
 1759       assert(num_class_infos <= num_classes);
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp
 1037       assert(objc_runtime != nullptr);
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTypeEncodingParser.cpp
   47   assert(next == '"');
tools/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.cpp
  173     assert(objc_runtime != nullptr);
tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptExpressionOpts.cpp
   98   assert(m_process_ptr && "no available lldb process");
  138     assert(target_machine &&
  161   assert(process);
  169   assert(m_ir_passes);
  181   assert(process);
  184   assert(EarlyPasses);
tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptRuntime.cpp
   95     assert(valid);
  399   assert(ctx.reg_ctx && ctx.process);
 1192   assert(group);
 1330         assert(*alloc->address.get() == alloc_addr);
 2313   assert(type >= Element::RS_TYPE_NONE && type <= Element::RS_TYPE_FONT &&
 2368   assert(alloc->data_ptr.isValid() && alloc->element.type.isValid() &&
 2424   assert(alloc->data_ptr.isValid() && alloc->element.type.isValid() &&
 2644   assert(alloc->data_ptr.isValid() && alloc->element.type.isValid() &&
 2681   assert((sizeof(AllocationDetails::FileHeader) + element_header_size) <
 2964   assert(m_module);
 3199   assert(type >= Element::RS_TYPE_NONE && type <= Element::RS_TYPE_FONT &&
 3632       assert(x <= UINT32_MAX && y <= UINT32_MAX && z <= UINT32_MAX);
 3656   assert(baton &&
 3668   assert(thread_ptr && "Null thread pointer");
 3689     assert(breakpoint_sp != nullptr &&
 3885   assert(IsRenderScriptModule(resolved.CalculateSymbolContextModule()));
 4144       assert(match_type_list.IsValid());
 4607     assert(output_stream_p != nullptr);
 4926 void RenderScriptRuntime::Initiate() { assert(!m_initiated); }
tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptScriptGroup.cpp
   51     assert(runtime);
  108     assert(runtime);
tools/lldb/source/Plugins/LanguageRuntime/RenderScript/RenderScriptRuntime/RenderScriptx86ABIFixups.cpp
   91   assert(call_inst && "no CallInst");
   93   assert(orig && "CallInst has no called function");
  106   assert(!orig_type->getReturnType()->isVoidTy() &&
  110   assert(return_type_ptr_type &&
  121   assert(params.size() == num_params + 1);
  158     assert(new_func_type &&
  163     assert(func && "cannot resolve function in RenderScriptRuntime");
tools/lldb/source/Plugins/ObjectFile/Breakpad/BreakpadRecords.cpp
  115   assert(success);
tools/lldb/source/Plugins/ObjectFile/ELF/ELFHeader.cpp
  181     assert(false && "architecture not supported");
tools/lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
  131     assert(false && "unexpected relocation type");
  340   assert(data_sp);
  526           assert(vendor == llvm::Triple::UnknownVendor);
  532           assert(spec_ostype == ostype);
  814   assert(dynsym_section_sp->GetObjectFile() == this);
  917   assert(dynsym->GetObjectFile() == this);
 1332     assert(spec_ostype == ostype);
 2283   assert(symtab_hdr->sh_type == SHT_SYMTAB ||
 2291     assert(symtab->GetObjectFile() == this);
 2292     assert(strtab->GetObjectFile() == this);
 2322   assert(dynsym->GetObjectFile() == this);
 2477   assert(rel_hdr->sh_type == SHT_RELA || rel_hdr->sh_type == SHT_REL);
 2583         assert(false && "unexpected relocation type");
 2629         assert(false && "unexpected relocation type");
 2640   assert(rel_hdr->sh_type == SHT_RELA || rel_hdr->sh_type == SHT_REL);
 2752         assert(reloc_header);
tools/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
 1752       assert(segment_sp.get());
 3658       assert(m_dysymtab.ilocalsym == 0);
 3716       assert(sym_idx < num_syms);
tools/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp
  135     assert(m_register_info_up->GetNumRegisters() > 0);
  136     assert(m_register_info_up->GetNumRegisterSets() > 0);
tools/lldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp
  237     assert(bp_site);
tools/lldb/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
 1204   assert(m_developer_directory.empty() == false);
tools/lldb/source/Plugins/Platform/MacOSX/PlatformRemoteDarwinDevice.cpp
  357   assert(m_device_support_directory.empty() == false);
  387   assert(m_device_support_directory_for_os_version.empty() == false);
tools/lldb/source/Plugins/Process/Linux/NativeProcessLinux.cpp
  232   assert(wpid == pid);
  294     assert(status.Success());
  300   assert(m_sigchld_handle && status.Success());
  566   assert(info.si_signo == SIGTRAP && "Unexpected child signal!");
  605     assert(m_threads.size() == 1);
  977     assert(pc_it != baton.m_register_values.end() &&
 1040       assert(thread && "thread list should not contain NULL threads");
 1057     assert(thread && "thread list should not contain NULL threads");
 1250     assert((proc_entry_info.GetRange().GetRangeBase() >= prev_base_address) &&
 1553     assert(thread && "thread list should not contain NULL threads");
 1587   assert(!HasThreadNoLock(thread_id) &&
tools/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux.cpp
   87   assert(register_to_write_info_p &&
tools/lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_x86_64.cpp
  269     assert((HostInfo::GetArchitecture().GetAddressByteSize() == 8) &&
  351     assert(false && "Unhandled target architecture.");
  401     assert(false && "Unhandled target architecture.");
  527   assert((reg_info->byte_offset - m_fctrl_offset_in_userarea) < sizeof(FPR));
  544     assert(false && "Unhandled data size.");
  571   assert(reg_info && "reg_info is null");
  635       assert((reg_info->byte_offset - m_fctrl_offset_in_userarea) <
  653         assert(false && "Unhandled data size.");
  730     assert(false && "how do we save the floating point registers?");
tools/lldb/source/Plugins/Process/POSIX/CrashReason.cpp
   43   assert(info.si_signo == SIGSEGV);
   67   assert(info.si_signo == SIGILL);
   92   assert(info.si_signo == SIGFPE);
  117   assert(info.si_signo == SIGBUS);
  328   assert(false && "unexpected signal");
tools/lldb/source/Plugins/Process/POSIX/ProcessMessage.h
  107     assert(GetKind() == eExitMessage || GetKind() == eLimboMessage);
  112     assert(GetKind() == eSignalMessage || GetKind() == eCrashMessage ||
  118     assert(GetKind() == eSignalMessage);
  123     assert(GetKind() == eCrashMessage);
  128     assert(GetKind() == eCrashMessage);
  133     assert(GetKind() == eWatchpointMessage || GetKind() == eTraceMessage);
  138     assert(GetKind() == eNewThreadMessage);
tools/lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.cpp
   63   assert(!m_finalized);
  278       assert(reg_info.dynamic_size_dwarf_len > 0);
  285       assert(ret_val == reg_info.dynamic_size_dwarf_len);
  404   assert(!m_finalized);
  407   assert(reg_info.name);
  429   assert(set < m_sets.size());
  430   assert(set < m_set_reg_nums.size());
  431   assert(set < m_set_names.size());
  445     assert(m_sets.size() == m_set_reg_nums.size());
  463     assert(!pos->second.empty());
  513     assert(!pos->second.empty());
tools/lldb/source/Plugins/Process/Utility/InstructionUtils.h
   23   assert(msbit < 64 && lsbit <= msbit);
   31   assert(msbit < 32 && lsbit <= msbit);
   48   assert(msbit < 32 && lsbit < 32 && msbit >= lsbit);
   62   assert(amt < 32 && "Invalid rotate amount");
   68   assert(amt < 32 && "Invalid rotate amount");
tools/lldb/source/Plugins/Process/Utility/NativeRegisterContextRegisterInfo.cpp
   20   assert(register_info_interface && "null register_info_interface");
tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm.cpp
  938   assert(k_num_register_infos == k_num_registers);
  944   assert(k_num_register_infos == k_num_registers);
tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_arm64.cpp
  121   assert(k_num_register_infos == k_num_registers);
  127   assert(k_num_register_infos == k_num_registers);
tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_i386.cpp
  421   assert(k_num_register_infos == k_num_registers);
  427   assert(k_num_register_infos == k_num_registers);
tools/lldb/source/Plugins/Process/Utility/RegisterContextDarwin_x86_64.cpp
  483   assert(k_num_register_infos == k_num_registers);
  489   assert(k_num_register_infos == k_num_registers);
tools/lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_i386.cpp
   72     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_mips64.cpp
  110   assert(m_target_arch.GetCore() == ArchSpec::eCore_mips64);
tools/lldb/source/Plugins/Process/Utility/RegisterContextFreeBSD_x86_64.cpp
  107     assert(false && "Unhandled target architecture.");
  117     assert(!GetSharedRegisterInfoVector().empty() &&
  124     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_i386.cpp
  116     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_mips.cpp
  118     assert(false && "Unhandled target architecture.");
  132       assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_mips64.cpp
  122     assert(false && "Unhandled target architecture.");
  142     assert(false && "Unhandled target architecture.");
  158     assert(false && "Unhandled target architecture.");
  179     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_s390x.cpp
   25     assert(false && "Unhandled target architecture.");
   35     assert(false && "Unhandled target architecture.");
   45     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextLinux_x86_64.cpp
  120     assert(false && "Unhandled target architecture.");
  128     assert(!GetPrivateRegisterInfoVector().empty() &&
  136     assert(false && "Unhandled target architecture.");
  148     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextMemory.cpp
   32   assert(num_regs > 0);
tools/lldb/source/Plugins/Process/Utility/RegisterContextNetBSD_x86_64.cpp
   92     assert(false && "Unhandled target architecture.");
  104     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextOpenBSD_i386.cpp
   69     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextOpenBSD_x86_64.cpp
   73     assert(false && "Unhandled target architecture.");
   85     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_arm.cpp
  104     assert(false && "Unhandled target architecture.");
  118   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  123   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  169       assert(false && "Unhandled target architecture.");
  177   assert(reg < m_reg_info.num_registers && "Invalid register offset.");
  202   assert(kind < lldb::kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_arm64.cpp
  124     assert(false && "Unhandled target architecture.");
  138   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  143   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  191       assert(false && "Unhandled target architecture.");
  199   assert(reg < m_reg_info.num_registers && "Invalid register offset.");
  224   assert(kind < lldb::kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_mips64.cpp
   57   assert(m_num_registers ==
   70   assert(reg < m_num_registers && "Invalid register number.");
   75   assert(reg < m_num_registers && "Invalid register number.");
  148   assert(reg < m_num_registers && "Invalid register offset.");
  175   assert(kind < kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp
  106   assert(reg < k_num_registers_powerpc && "Invalid register number.");
  111   assert(reg < k_num_registers_powerpc && "Invalid register number.");
  157   assert(reg < k_num_registers_powerpc && "Invalid register offset.");
  184   assert(kind < kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_ppc64le.cpp
  124   assert(reg < k_num_registers_ppc64le && "Invalid register number.");
  129   assert(reg < k_num_registers_ppc64le && "Invalid register number.");
  175   assert(reg < k_num_registers_ppc64le && "Invalid register offset.");
  202   assert(kind < kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_s390x.cpp
   96     assert(false && "Unhandled target architecture.");
  124   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  129   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  134   assert(reg < m_reg_info.num_registers && "Invalid register offset.");
  158       assert(false && "Unhandled target architecture.");
  182   assert(kind < kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_x86.cpp
  363     assert(false && "Unhandled target architecture.");
  389   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  394   assert(reg < m_reg_info.num_registers && "Invalid register number.");
  447       assert(false && "Unhandled target architecture.");
  455   assert(reg < m_reg_info.num_registers && "Invalid register offset.");
  519   assert(kind < kNumRegisterKinds);
tools/lldb/source/Plugins/Process/Utility/RegisterContextWindows_i386.cpp
   74   assert(target_arch.GetMachine() == llvm::Triple::x86);
tools/lldb/source/Plugins/Process/Utility/RegisterContextWindows_x86_64.cpp
  137   assert(target_arch.GetMachine() == llvm::Triple::x86_64);
tools/lldb/source/Plugins/Process/Utility/RegisterInfoPOSIX_arm.cpp
   57     assert(false && "Unhandled target architecture.");
   69     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterInfoPOSIX_arm64.cpp
   63     assert(false && "Unhandled target architecture.");
   76     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/RegisterInfoPOSIX_ppc64le.cpp
   29     assert(false && "Unhandled target architecture.");
   41     assert(false && "Unhandled target architecture.");
tools/lldb/source/Plugins/Process/Utility/UnwindLLDB.cpp
  115   assert(m_frames.size() != 0 &&
  298   assert(m_frames.size() == 1 && "No. of cursor frames are not 1");
tools/lldb/source/Plugins/Process/Utility/UnwindMacOSXFrameBackchain.cpp
   91   assert(reg_ctx);
  183   assert(reg_ctx);
tools/lldb/source/Plugins/Process/elf-core/ProcessElfCore.cpp
  379   assert(zero_fill_size <= size);
  531       assert(thread_data.gpregset.GetByteSize() > 0);
  781       assert(thread_data.gpregset.GetByteSize() > 0);
  859   assert(segment_header.p_type == llvm::ELF::PT_NOTE);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_arm.cpp
   35   assert(0);
   40   assert(0);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_arm64.cpp
   36   assert(0);
   41   assert(0);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_mips64.cpp
   42   assert(0);
   47   assert(0);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_powerpc.cpp
   51   assert(0);
   56   assert(0);
   61   assert(0);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_s390x.cpp
   43   assert(0);
   48   assert(0);
tools/lldb/source/Plugins/Process/elf-core/RegisterContextPOSIXCore_x86_64.cpp
   48   assert(0);
   53   assert(0);
tools/lldb/source/Plugins/Process/elf-core/ThreadElfCore.cpp
  186       assert(false && "Architecture or OS not supported");
  259     assert(!abi.empty() && "ABI is not set");
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
  745       assert(content_length <= m_bytes.size());
  746       assert(total_length <= m_bytes.size());
  747       assert(content_length <= total_length);
  840         assert(checksum_idx < m_bytes.size());
 1196           assert(num_bytes > 0 && port_cstr[num_bytes - 1] == '\0');
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
 1238                 assert(pointer_byte_size == m_host_arch.GetAddressByteSize());
 1241                 assert(byte_order == m_host_arch.GetByteOrder());
 1285               assert(pointer_byte_size == m_host_arch.GetAddressByteSize());
 1288               assert(byte_order == m_host_arch.GetByteOrder());
 1294             assert(pointer_byte_size == m_host_arch.GetAddressByteSize());
 1297             assert(byte_order == m_host_arch.GetByteOrder());
 1325     assert(packet_len < (int)sizeof(packet));
 1372     assert(packet_len < (int)sizeof(packet));
 1394     assert(packet_len < (int)sizeof(packet));
 1418       assert(packet_len < (int)sizeof(packet));
 1460     assert(packet_len < (int)sizeof(packet));
 1686     assert(packet_len < (int)sizeof(packet));
 1850   assert(packet_len < (int)sizeof(packet));
 1868   assert(packet_len < (int)sizeof(packet));
 1987     assert(packet_len < (int)sizeof(packet));
 2085           assert(pointer_byte_size == m_process_arch.GetAddressByteSize());
 2093         assert(triple.getObjectFormat() != llvm::Triple::UnknownObjectFormat);
 2094         assert(triple.getObjectFormat() != llvm::Triple::Wasm);
 2095         assert(triple.getObjectFormat() != llvm::Triple::XCOFF);
 2116           assert(pointer_byte_size == m_process_arch.GetAddressByteSize());
 2119           assert(byte_order == m_process_arch.GetByteOrder());
 2238     assert(packet_len < (int)sizeof(packet));
 2265     assert(packet_len < (int)sizeof(packet));
 2291   assert(packet_len < (int)sizeof(packet));
 2588   assert(packet_len + 1 < (int)sizeof(packet));
 2624   assert(packet_len + 1 < (int)sizeof(packet));
 2663     assert(packet_len < (int)sizeof(packet));
 2695   assert(packet_len + 1 < (int)sizeof(packet));
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationReplayServer.cpp
   55   assert(!data.empty() && "Empty packet?");
  146         assert(false && "Encountered unexpected packet during replay");
  152         assert(m_packet_history.back().type ==
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServer.cpp
   99   assert(packet_len < (int)sizeof(packet));
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp
  231     assert(!m_debugged_process_up && "lldb-server creating debugged "
  331   assert(process && "process cannot be NULL");
  345   assert(process && "process cannot be NULL");
  790   assert(process && "process cannot be NULL");
  814   assert(process && "process cannot be NULL");
  840   assert(process && "process cannot be NULL");
 2187     assert(false && "unsupported $H variant - shouldn't get here");
 2330     assert(kind == 'm');
 2899   assert((m_saved_registers_map.find(save_id) == m_saved_registers_map.end()) &&
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerPlatform.cpp
  134     assert(ok);
tools/lldb/source/Plugins/Process/gdb-remote/GDBRemoteRegisterContext.cpp
  259     assert(m_reg_data.GetByteSize() >=
  313   assert(m_reg_data.GetByteSize() >=
tools/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
  494     assert(packet_len < (int)sizeof(packet));
  584             assert(dwarf_opcode_len > 0);
  592             assert(dwarf_opcode_len == ret_val);
  599         assert(reg_info.byte_size != 0);
 2740   assert(packet_len + 1 < (int)sizeof(packet));
 3095   assert(bp_site != nullptr);
 3219   assert(bp_site != nullptr);
 3272   assert(wp);
 3277   assert(watch_read || watch_write);
 4423             assert(dwarf_opcode_len > 0);
 4430             assert(dwarf_opcode_len == ret_val);
 4466         assert(reg_info.byte_size != 0);
tools/lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp
  324   assert(gdb_reg_ctx);
  331   assert(gdb_reg_ctx);
tools/lldb/source/Plugins/Process/minidump/ProcessMinidump.cpp
   98     assert(!value_is_offset);
   99     assert(value == m_base);
  103     assert(m_sections_up->GetNumSections(0) == 1);
tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
  470     assert(PyLong_Check(m_py_obj) &&
  978     assert(!PyErr_Occurred());
  994   assert(PyErr_Occurred());
 1109     assert(m_py_obj);
 1113     assert(m_py_obj);
 1136     assert(m_py_obj);
 1151     assert(m_py_obj.IsValid());
 1415   assert(!PyErr_Occurred());
tools/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.h
  129   assert(obj);
  130   assert(!PyErr_Occurred());
  132   assert(thing.IsValid());
  147   assert(obj);
  148   assert(!PyErr_Occurred());
  150   assert(thing.IsValid());
  366     assert(!PyErr_Occurred());
tools/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
 1103   assert(py_return.IsValid());
tools/lldb/source/Plugins/SymbolFile/Breakpad/SymbolFileBreakpad.cpp
   48     assert(lhs.m_obj == rhs.m_obj);
   53     assert(lhs.m_next_line == rhs.m_next_line);
   91   assert(sect.GetName() == m_section_type);
   97   assert(m_current_line < m_section_text.size());
  206   assert(Record::classify(*It) == Record::Func);
  369     assert(record.hasValue());
  505   assert(init_record.hasValue() && init_record->Size.hasValue() &&
  548   assert(record.hasValue() &&
  690   assert(base != LLDB_INVALID_ADDRESS &&
  710   assert(Record::classify(*It) == Record::Func);
tools/lldb/source/Plugins/SymbolFile/DWARF/DIERef.h
   34     assert(this->dwo_num() == dwo_num && "Dwo number out of range?");
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
  637     assert((!type_sp && !clang_type) &&
 1154     assert(type_sp.get());
 1488   assert(tag_decl_kind != -1);
 1649       assert(!dwarf->GetForwardDeclClangTypeToDie().count(
 1942   assert(clang_type);
 2181     assert(false && "not a forward clang type decl!");
 2429       assert(func_type == nullptr || func_type != DIE_IS_BEING_PARSED);
 2922               assert(ivar_decl != nullptr);
 3025         assert(base_class_clang_type);
 3160             assert(param_var_decl);
 3471   assert(0 && "Shouldn't call GetContainingFunctionWithAbstractOrigin on "
 3488   assert(IsSubroutine(function));
 3491     assert(!IsSubroutine(context) || context == function);
 3501   assert(die.Tag() == DW_TAG_lexical_block);
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFBaseDIE.cpp
  151   assert(IsValid());
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDIE.cpp
   38     assert(!m_worklist.empty() && "Incrementing end iterator?");
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugArangeSet.cpp
   37   assert(data.ValidOffset(*offset_ptr));
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp
   87     assert(*unit_sp);
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.cpp
  352                   assert(lo_pc >= cu->GetBaseAddress());
  381     assert(lowest_range_pc >= cu->GetBaseAddress());
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFFormValue.cpp
   45       assert(m_unit);
  119       assert(m_unit);
  248     assert(unit); // Unit must be valid for DW_FORM_ref_addr objects or we will
  409     assert(m_unit); // Unit must be valid for DW_FORM_ref_addr objects or we
  447     assert(m_unit); // Unit must be valid for DW_FORM_ref forms that are compile
  498   assert(m_unit);
  499   assert(m_form == DW_FORM_GNU_addr_index || m_form == DW_FORM_addrx ||
  518     assert(m_unit); // Unit must be valid for DW_FORM_ref forms that are compile
tools/lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp
  170       assert(m_die_array.empty() && "Compile unit DIE already added");
  794   assert(debug_info.ValidOffset(*offset_ptr));
tools/lldb/source/Plugins/SymbolFile/DWARF/ManualDWARFIndex.cpp
   91   assert(
tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
  140     assert(option_value);
  924   assert(sc.comp_unit);
 1118           assert(subprogram_low_pc == LLDB_INVALID_ADDRESS);
 1443     assert(compiler_type);
 2046     assert(sc.module_sp);
 2142   assert(sc.module_sp);
 2195   assert(die && die.Tag() == DW_TAG_subprogram);
 2252   assert((name_type_mask & eFunctionNameTypeAuto) == 0);
 2560       assert(scope);
 2803   assert(cu_tag == DW_TAG_compile_unit || cu_tag == DW_TAG_partial_unit);
 3276                 assert(func_low_pc != LLDB_INVALID_ADDRESS);
tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
   82       assert(comp_unit_info->first_symbol_index != UINT32_MAX);
 1271           assert(m_compile_unit_infos[cu_idx].compile_unit_sp.get() ==
tools/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDwo.cpp
   52   assert(GetCompileUnit() == &dwarf_cu &&
tools/lldb/source/Plugins/SymbolFile/NativePDB/DWARFLocationExpression.cpp
  101     assert(false && "Type is not integral!");
  200   assert(section > 0);
  201   assert(module);
  208         assert(section_list);
tools/lldb/source/Plugins/SymbolFile/NativePDB/PdbSymUid.cpp
  118   assert(kind() == PdbSymUidKind::Compiland);
  126   assert(kind() == PdbSymUidKind::CompilandSym);
  135   assert(kind() == PdbSymUidKind::GlobalSym ||
  145   assert(kind() == PdbSymUidKind::Type);
  154   assert(kind() == PdbSymUidKind::FieldListMember);
tools/lldb/source/Plugins/SymbolFile/NativePDB/PdbUtil.cpp
   52   assert(IsTagRecord(type) && "type is not a tag record!");
tools/lldb/source/Plugins/SymbolFile/NativePDB/PdbUtil.h
   54     assert(m_kind == Struct || m_kind == Class);
   59     assert(m_kind == Enum);
   64     assert(m_kind == Union);
tools/lldb/source/Plugins/SymbolFile/NativePDB/UdtRecordCompleter.cpp
  191   assert(method_list_type.kind() == LF_METHODLIST);
tools/lldb/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp
  360     assert(false && "Unknown calling convention");
  384     assert(udt);
  423       assert(clang_type.IsValid());
  427       assert(record_decl);
  474     assert(enum_type);
  512       assert(enum_decl);
  542     assert(type_def);
  566       assert(typedef_decl);
  656     assert(array_type);
  692     assert(builtin_type);
  719     assert(pointer_type);
  730       assert(class_parent_type);
  736       assert(pointer_ast_type);
  886     assert(data);
  889     assert(decl_context);
  920     assert(func);
  923     assert(decl_context);
 1114   assert(set);
tools/lldb/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp
  389   assert(pdb_symbol && parent_block);
  698   assert(decl_context);
  756       assert(pdb_func);
  838           assert(line && "Couldn't get all line entries!\n");
  874                 assert(pdb_func);
 1048           assert(sc.comp_unit);
 1596     assert(udt);
tools/lldb/source/Plugins/UnwindAssembly/InstEmulation/UnwindAssemblyInstEmulation.cpp
  154             assert(it != saved_unwind_states.begin() &&
  437     assert(context.info_type ==
  601         assert(
  612         assert(false && "unhandled case, add code to handle this!");
  624       assert(cfa_reg_num != LLDB_INVALID_REGNUM);
  637       assert(cfa_reg_num != LLDB_INVALID_REGNUM);
tools/lldb/source/Symbol/Block.cpp
  394       assert(sc.module_sp);
tools/lldb/source/Symbol/ClangASTContext.cpp
  648   assert(m_ast_up);
  666   assert(s == nullptr || &s->getASTContext() == m_ast_up.get());
  688   assert(m_ast_up);
  693   assert(!m_ast_up);
 1029   assert(ast != nullptr);
 1354   assert(ast != nullptr);
 1758   assert(ast != nullptr);
 1759   assert(name && name[0]);
 1838       assert(namespace_decl == translation_unit_decl->getAnonymousNamespace());
 1850         assert(namespace_decl ==
 1853         assert(false && "GetUniqueNamespaceDeclaration called with no name and "
 2127   assert(ast != nullptr);
 2161     assert(ast != nullptr);
 4542         assert(record_decl);
 4631         assert(record_decl);
 5542       assert(record_decl);
 5585       assert(objc_class_type);
 6043       assert(objc_class_type);
 6613       assert(record_decl);
 6673             assert(base_class_clang_type_bit_size % 8 == 0);
 6698           assert(field_idx < record_layout.getFieldCount());
 6730       assert(objc_class_type);
 7162         assert(record_decl);
 7254         assert(objc_class_type);
 7434         assert(record_decl);
 7484         assert(objc_class_type);
 8722     assert(objc_class_type);
 9021       assert(record_decl);
 9055           assert(field_bit_offset % 8 == 0);
 9117         assert(field_idx < record_layout.getFieldCount());
 9172       assert(enum_decl);
 9390   assert(enum_decl);
 9657       assert(objc_class_type);
tools/lldb/source/Symbol/ClangASTImporter.cpp
  294       assert(to_context_md->m_origins[decl].ctx == m_src_ctx);
  626     assert(0 && "CompleteDecl called on a Decl that can't be completed");
  862   assert(decl);
tools/lldb/source/Symbol/CompileUnit.cpp
   29   assert(module_sp);
   42   assert(module_sp);
  187     assert(sc.module_sp);
tools/lldb/source/Symbol/CxxModuleHandler.cpp
  251       assert(false && "templateArgsAreSupported not updated?");
tools/lldb/source/Symbol/DWARFCallFrameInfo.cpp
   42   assert(addr_size == 4 || addr_size == 8);
   84     assert(addr_size != 0);
  131     assert(eh_ptr_enc);
  550   assert(!(m_type == EH && 0 == cie_offset) && cie_offset != UINT32_MAX);
  570   assert(cie != nullptr);
tools/lldb/source/Symbol/Function.cpp
  177   assert(resolved && "Did not resolve lazy callee");
  195   assert(comp_unit != nullptr);
tools/lldb/source/Symbol/LineTable.cpp
   64   assert(sequence != nullptr);
   96   assert(sequence != nullptr);
  129     assert(prev_pos->is_terminal_entry);
  507       assert(prev_file_addr != LLDB_INVALID_ADDRESS);
tools/lldb/source/Symbol/LocateSymbolFile.cpp
   57       assert(got_spec);
  358         assert(num_specs <= 1 &&
tools/lldb/source/Symbol/ObjectFile.cpp
  492   assert(section);
tools/lldb/source/Symbol/PostfixExpression.cpp
  209   assert(m_stack_depth >= 1);
  217   assert(reg_num != LLDB_INVALID_REGNUM);
tools/lldb/source/Symbol/SymbolFile.cpp
  177   assert(idx < num_compile_units);
  185   assert((*m_compile_units)[idx] == nullptr);
tools/lldb/source/Symbol/Symtab.cpp
  426       assert(i < m_symbols.size());
  537     assert(symbols.size() == addr_cache.size());
 1030   assert((name_type_mask & eFunctionNameTypeAuto) == 0);
tools/lldb/source/Symbol/Type.cpp
  623   assert(encoding_type != this);
tools/lldb/source/Symbol/TypeList.cpp
   69   assert(i < GetSize() && "Accessing past the end of a TypeList");
tools/lldb/source/Symbol/TypeSystem.cpp
  224   assert(!error); // Check the success value when assertions are enabled
  293   assert(!error); // Check the success value when assertions are enabled
tools/lldb/source/Target/ABI.cpp
  133     assert(expr_variable_sp);
  229   assert(info_up);
tools/lldb/source/Target/ExecutionContext.cpp
  227   assert(m_target_sp);
  232   assert(m_process_sp);
  237   assert(m_thread_sp);
  242   assert(m_frame_sp);
tools/lldb/source/Target/Memory.cpp
  199             assert((curr_addr % cache_line_byte_size) == 0);
  226         assert((curr_addr % cache_line_byte_size) == 0);
  254   assert(byte_size > chunk_size);
tools/lldb/source/Target/Platform.cpp
 1909   assert(bp_site);
tools/lldb/source/Target/Process.cpp
  537   assert(m_unix_signals_sp && "null m_unix_signals_sp after initialization");
 1534     assert(runtime->GetLanguageType() == Language::GetPrimaryLanguage(language));
 1732           assert(bp_addr <= intersect_addr && intersect_addr < bp_addr + size);
 1733           assert(bp_addr < intersect_addr + intersect_size &&
 1735           assert(opcode_offset + intersect_size <= bp_site->GetByteSize());
 1756   assert(bp_site != nullptr);
 1832   assert(bp_site != nullptr);
 1849       assert(break_op_size <= sizeof(curr_break_op));
 1877           assert(break_op_size < sizeof(verify_opcode));
 1995     assert(sizeof(terminator) >= type_width && "Attempting to validate a "
 2203     assert(intersects);
 2204     assert(addr <= intersect_addr && intersect_addr < addr + size);
 2205     assert(addr < intersect_addr + intersect_size &&
 2207     assert(opcode_offset + intersect_size <= bp->GetByteSize());
 2698     assert(m_process->GetID() != LLDB_INVALID_PROCESS_ID);
 2896   assert(platform_sp);
 3318   assert(signals_sp && "null signals_sp");
 3323   assert(m_unix_signals_sp && "null m_unix_signals_sp");
 3535   assert(private_state_thread->IsJoinable());
 3563   assert(signal == eBroadcastInternalStateControlStop ||
tools/lldb/source/Target/SectionLoadHistory.cpp
   64       assert(stop_id != eStopIDNow);
  100   assert(section_load_list != nullptr);
tools/lldb/source/Target/StackFrame.cpp
 1849   assert(GetStackID() ==
 1861   assert(GetStackID() ==
 1864   assert(GetThread() == curr_frame.GetThread());
 1869   assert(!m_sc.target_sp || !curr_frame.m_sc.target_sp ||
 1871   assert(!m_sc.module_sp || !curr_frame.m_sc.module_sp ||
 1873   assert(m_sc.comp_unit == nullptr || curr_frame.m_sc.comp_unit == nullptr ||
 1875   assert(m_sc.function == nullptr || curr_frame.m_sc.function == nullptr ||
tools/lldb/source/Target/StackFrameList.cpp
  222   assert(m_thread.IsValid() && "Expected valid thread");
  223   assert(m_frames.size() <= end_idx && "Expected there to be frames to fill");
  358   assert(!m_frames.empty() && "Cannot synthesize frames in an empty stack");
  499     assert(unwind_frame_sp);
  698       assert(!m_thread.IsValid() && "A valid thread has no frames.");
tools/lldb/source/Target/StopInfo.cpp
  254     assert(m_should_stop_is_valid);
  680     assert(m_should_stop_is_valid);
  720                 assert(stored_stop_info_sp.get() == this);
tools/lldb/source/Target/Target.cpp
 2425   assert(!error); // Check the success value when assertions are enabled.
 2901       assert(m_process_sp);
 3712   assert(option_value);
 3721   assert(option_value);
 3730   assert(option_value);
 3739   assert(option_value);
 3748   assert(option_value);
tools/lldb/source/Target/Thread.cpp
  128   assert(option_value);
  255   assert(m_destroy_called);
 1018       assert(!m_plan_stack.empty());
 1808   assert(thread_format);
tools/lldb/source/Target/ThreadList.cpp
   74   assert(m_expression_tid_stack.back() == tid);
  563       assert(thread_sp->GetCurrentPlan()->RunState() != eStateSuspended);
tools/lldb/source/Target/ThreadPlan.cpp
  107       assert(reg_ctx);
tools/lldb/source/Target/ThreadPlanTracer.cpp
  216       assert(reg_num < m_register_values.size());
tools/lldb/source/Utility/Args.cpp
  263   assert(!m_argv.empty());
  273   assert(!m_argv.empty());
  291   assert(m_argv.size() == m_entries.size() + 1);
  292   assert(m_argv.back() == nullptr);
  304   assert(m_argv.size() == m_entries.size() + 1);
  305   assert(m_argv.back() == nullptr);
  321   assert(m_argv.size() == m_entries.size() + 1);
  322   assert(m_argv.back() == nullptr);
  332   assert(m_argv.size() == m_entries.size() + 1);
  333   assert(m_argv.back() == nullptr);
  610     assert(false && "Unhandled quote character");
tools/lldb/source/Utility/Broadcaster.cpp
  208     assert(!m_hijacking_masks.empty());
tools/lldb/source/Utility/CompletionRequest.cpp
   19   assert(raw_cursor_pos <= command_line.size() && "Out of bounds cursor?");
tools/lldb/source/Utility/DataBufferLLVM.cpp
   23   assert(Buffer != nullptr &&
tools/lldb/source/Utility/DataEncoder.cpp
   72         assert(m_start >= data_bytes);
tools/lldb/source/Utility/DataExtractor.cpp
  115     assert(byte_order == eByteOrderLittle);
  137   assert(addr_size == 4 || addr_size == 8);
  150   assert(addr_size == 4 || addr_size == 8);
  164   assert(m_addr_size == 4 || m_addr_size == 8);
  177   assert(m_addr_size == 4 || m_addr_size == 8);
  212         assert(m_start >= data_bytes);
  255   assert(m_addr_size == 4 || m_addr_size == 8);
  673   assert(m_addr_size == 4 || m_addr_size == 8);
  678   assert(m_addr_size == 4 || m_addr_size == 8);
  689   assert(m_addr_size == 4 || m_addr_size == 8);
  699       assert(length == 1 || length == 2 || length == 4 || length == 8 ||
  729     assert(ValidOffsetForDataOfSize(src_offset, src_len));
  730   assert(src_len > 0);
  731   assert(m_byte_order == eByteOrderBig || m_byte_order == eByteOrderLittle);
  734   assert(dst_void_ptr != nullptr);
  735   assert(dst_len > 0);
  736   assert(dst_byte_order == eByteOrderBig || dst_byte_order == eByteOrderLittle);
  739   assert(dst_byte_order == m_byte_order || dst_len == 1 || dst_len == 2 ||
tools/lldb/source/Utility/FileSpec.cpp
  525   assert(
tools/lldb/source/Utility/Log.cpp
  190   assert(iter.second == true);
  196   assert(iter != g_channel_map->end());
tools/lldb/source/Utility/RegisterValue.cpp
  271     assert(buffer.length <= kMaxRegisterByteSize);
  496     assert(rhs.buffer.length <= kMaxRegisterByteSize);
  755     assert(length <= sizeof(buffer.bytes) &&
tools/lldb/source/Utility/Reproducer.cpp
  162   assert(!m_done);
  172   assert(!m_done);
  229   assert(m_loaded);
tools/lldb/source/Utility/ReproducerInstrumentation.cpp
   20   assert(idx != 0 && "Cannot add object for sentinel");
   69   assert(m_replayers.find(RunID) == m_replayers.end());
   77   assert(id != 0 && "Forgot to add function to registry?");
   82   assert(m_ids.count(id) != 0 && "ID not in registry");
   87   assert(m_ids.count(id) != 0 && "ID not in registry");
  118   assert(m_result_recorded && "Did you forget LLDB_RECORD_RESULT?");
tools/lldb/source/Utility/StringLexer.cpp
   68   assert(m_position >= s);
tools/lldb/source/Utility/TildeExpressionResolver.cpp
   36   assert(!llvm::any_of(Expr, [](char c) { return path::is_separator(c); }));
   37   assert(Expr.empty() || Expr[0] == '~');
   46   assert(!llvm::any_of(Expr, [](char c) { return path::is_separator(c); }));
   47   assert(Expr.empty() || Expr[0] == '~');
tools/lldb/source/Utility/Timer.cpp
   91   assert(stack.back() == this);
tools/lldb/source/Utility/VASprintf.cpp
   47     assert(size_t(length) < buf.size());
tools/lldb/tools/lldb-instr/Instrument.cpp
  106   assert(!Values.empty());
tools/lldb/tools/lldb-server/lldb-gdbserver.cpp
  158   assert(!attach_target.empty() && "attach_target cannot be empty");
tools/lldb/tools/lldb-test/lldb-test.cpp
  410     assert(Line != 0);
  438     assert(RE.IsValid());
  460   assert(!Regex);
  461   assert(!File.empty());
  462   assert(Line != 0);
  546     assert(RE.IsValid());
  833     assert(S);
tools/lldb/tools/lldb-vscode/IOStream.cpp
  127     assert(bytes_read >= 0 && (size_t)bytes_read <= length);
tools/lldb/unittests/TestingSupport/Host/NativeProcessTestUtils.h
   75     assert(BytesRead <= Size);
tools/lldb/unittests/TestingSupport/MockTildeExpressionResolver.cpp
   23   assert(UserDirectories.find(User) == UserDirectories.end());
   33   assert(UserDirectories.find(User) != UserDirectories.end());
   41   assert(!llvm::any_of(
   43   assert(Expr.empty() || Expr[0] == '~');
   64   assert(!llvm::any_of(
   66   assert(Expr.empty() || Expr[0] == '~');
tools/lldb/unittests/TestingSupport/TestUtilities.cpp
   31   assert(Info);
tools/lldb/unittests/tools/lldb-server/tests/MessageObjects.cpp
  303   assert(PcInfo);
tools/lldb/unittests/tools/lldb-server/tests/TestBase.cpp
   18   assert(test_info);
tools/lldb/unittests/tools/lldb-server/tests/TestClient.cpp
  174   assert(m_stop_reply);
  208   assert(m_pc_register != LLDB_INVALID_REGNUM);
  248   assert(m_process_info.hasValue());
tools/lldb/unittests/tools/lldb-server/tests/TestClient.h
   64     assert(m_stop_reply);
tools/lldb/utils/TableGen/LLDBPropertyDefEmitter.cpp
   51   assert((hasDefaultUnsignedValue || hasDefaultEnumValue ||
   57   assert(!(hasDefaultUnsignedValue && hasDefaultEnumValue) &&
   61   assert(!(Property->getValueAsString("Type") == "Boolean" &&
   66   assert(!(Property->getValueAsString("Type") == "String" &&
   71   assert(
tools/lli/RemoteJITUtils.h
   32     assert(Dst && "Attempt to read into null.");
   50     assert(Src && "Attempt to append from null.");
tools/lli/lli.cpp
  829       assert(EMIdx != 0 && "ExtraModule should have index > 0");
  839       assert(EAIdx != 0 && "ExtraArchive should have index > 0");
tools/llvm-ar/llvm-ar.cpp
  787         assert(AddAfter || AddBefore);
  833   assert(unsigned(InsertPos) <= Ret.size());
  841     assert(Operation == QuickAppend);
  979   assert(EC == errc::no_such_file_or_directory);
tools/llvm-c-test/attributes.c
   36         assert(Attrs);
   71               assert(Attrs);
tools/llvm-c-test/calc.c
   35   assert(0 && "unknown operation");
tools/llvm-cfi-verify/lib/FileAnalysis.cpp
  165   assert(InstrKV != Instructions.end() && "Address doesn't exist.");
  275   assert(Symbolizer != nullptr && "Symbolizer is invalid.");
  308   assert(Graph.OrphanedNodes.empty() && "Orphaned nodes should be empty.");
  317   assert(RegisterNumbers.size() && "Zero register operands on indirect CF.");
  473   assert(Symbolizer && "Symbolizer is uninitialised.");
tools/llvm-cfi-verify/lib/GraphBuilder.cpp
  116   assert(SearchLengthForUndef > 0 &&
  232     assert(ParentMetaPtr && "CFCrossRefs returned nullptr.");
tools/llvm-config/llvm-config.cpp
   94   assert(AC && "Invalid component name!");
  252   assert(!DyLibComponents.empty());
  451         assert(Lib.endswith(SharedExt) && "DyLib is missing suffix");
tools/llvm-cov/CoverageExporterJson.cpp
  212       assert(ObjA != nullptr && "Value A was not an Object");
  213       assert(ObjB != nullptr && "Value B was not an Object");
tools/llvm-cov/CoverageSummaryInfo.h
   35     assert(Covered <= NumRegions && "Covered regions over-counted");
   56     assert(Covered <= NumRegions && "Covered regions over-counted");
   76     assert(Covered <= NumLines && "Covered lines over-counted");
   97     assert(Covered <= NumLines && "Covered lines over-counted");
  137     assert(Executed <= NumFunctions && "Covered functions over-counted");
tools/llvm-cov/SourceCoverageView.cpp
   33   assert(!Extension.empty() && "The file extension may not be empty");
tools/llvm-cov/SourceCoverageViewHTML.cpp
  407   assert(Opts.hasOutputDirectory() && "No output directory for index file");
tools/llvm-cov/SourceCoverageViewText.cpp
   86   assert(ViewDepth != 0 && "Cannot render divider at top level");
tools/llvm-diff/DiffConsumer.cpp
   41   assert(!Numbering.empty() && "asked for numbering but numbering was no-op");
  172     assert(format[percent] == '%');
tools/llvm-diff/DifferenceEngine.cpp
   64     assert(!empty());
  177     assert(!Result && "structural differences second time around?");
  197       assert(LI != LE && RI != R->end());
  534   assert(TentativeValues.empty());
  596       assert(LI != LE && RI != RE);
  606       assert(LI != LE);
  612       assert(RI != RE);
  622     assert(RI != RE);
tools/llvm-dwarfdump/Statistics.cpp
  270         assert(BytesInScope);
  323     assert(GlobalStats.ScopeBytesCovered <=
tools/llvm-dwp/DWPStringPool.h
   20       assert(Val != getEmptyKey() && "Cannot hash the empty key!");
   21       assert(Val != getTombstoneKey() && "Cannot hash the tombstone key!");
   42     assert(strlen(Str) + 1 == Length && "Ensure length hint is correct");
tools/llvm-dwp/llvm-dwp.cpp
  311       assert(S != IndexEntries.begin()[Buckets[H] - 1].first &&
tools/llvm-exegesis/lib/Analysis.cpp
  135   assert(!Point.Key.Instructions.empty());
  179   assert(Disasm_ && "cannot create MCDisassembler. missing call to "
  222     assert(!Point.Key.Instructions.empty());
  301   assert(!Clusters.empty());
  342   assert(ClusterId == Clustering.getClusterIdForPoint(PointId));
  351   assert(!Clustering.getPoints().empty());
  365   assert(ClusterCenterPoint.size() == SchedClassPoint.size() &&
tools/llvm-exegesis/lib/Assembler.cpp
  292   assert(ObjectFileHolder.getBinary() && "cannot create object file");
  314   assert(isAligned(kFunctionAlignment, FunctionAddress) &&
tools/llvm-exegesis/lib/BenchmarkResult.cpp
   46     assert(Map.size() == InstrInfo.getNumOpcodes() && "Size prediction failed");
   57     assert(Map.size() == RegInfo.getNumRegs() && "Size prediction failed");
  145     assert(!String.empty());
  418   assert(Key == BM.Key);
tools/llvm-exegesis/lib/BenchmarkResult.h
  101     assert(NumValues);
tools/llvm-exegesis/lib/BenchmarkRunner.cpp
  145   assert(InstrBenchmark.NumRepetitions > 0 && "invalid NumRepetitions");
tools/llvm-exegesis/lib/Clustering.cpp
   63     assert(P < Points_.size());
   78         assert(P < Points_.size());
  193     assert(Opcode < NumOpcodes && "NumOpcodes is incorrect (too small)");
  199   assert(OpcodeToPoints.size() == NumOpcodes && "sanity check");
  200   assert(NumOpcodesSeen <= NumOpcodes &&
  202   assert(NumOpcodesSeen <= Points_.size() &&
  222     assert(CurrentCluster.PointIndices.size() == PointsOfOpcode.size());
  224   assert(Clusters_.size() == NumOpcodesSeen);
  254   assert(ClusterIdForPoint_.size() == Points_.size() && "size mismatch");
  280       assert(CID.isValid() &&
  293       assert(std::distance(it, OldCluster.PointIndices.end()) > 0 &&
  308     assert(UnstableCluster.PointIndices.size() > 1 &&
  310     assert(UnstableCluster.PointIndices.size() >= ClusterIDs.size() &&
  347   assert(Representative.size() == Point.size() &&
tools/llvm-exegesis/lib/Clustering.h
   62       assert(isValid());
   97     assert(!Id.isUndef() && "unlabeled cluster");
tools/llvm-exegesis/lib/CodeTemplate.cpp
   71   assert(isEnumValue(Bit) && "Bit must be a power of two");
tools/llvm-exegesis/lib/Latency.cpp
   89   assert(isEnumValue(ExecutionModeBit) && "Bit must be a power of two");
  113     assert(!SelfAliasing.empty() && !SelfAliasing.hasImplicitAliasing() &&
  175   assert((Mode == InstructionBenchmark::Latency ||
tools/llvm-exegesis/lib/LlvmState.cpp
   28   assert(TheTarget && "unknown target for host");
tools/llvm-exegesis/lib/MCInstrDescView.cpp
   21   assert(Index >= 0 && "Index must be set");
   26   assert(!TiedOperands.empty());
   31   assert(TiedOperands.size() <= 2 &&
   40   assert(Index >= 0 && "Index must be set");
   71   assert(isTied() && "Operand must be tied to get the tied index");
   72   assert(TiedToIndex >= 0 && "TiedToIndex must be set");
   77   assert(isVariable() && "Operand must be variable to get the Variable index");
   78   assert(VariableIndex >= 0 && "VariableIndex must be set");
   83   assert(ImplicitReg);
   88   assert(Tracker);
   93   assert(Info);
  172   assert(PrimaryOperandIndex < Operands.size());
  190   assert(A.size() == B.size() && B.size() == Forbidden.size());
tools/llvm-exegesis/lib/RegisterAliasing.h
  108   assert(A.size() == B.size());
tools/llvm-exegesis/lib/SchedClassResolution.cpp
  153     assert(MinimalPressure < SecondToMinimalPressure);
  215   assert((SCDesc == nullptr || !SCDesc->isVariant()) &&
  265     assert(NumMeasurements == 1 && "Latency is a single measure.");
  305     assert(NumMeasurements == 1 && "Inverse Throughput is a single measure.");
tools/llvm-exegesis/lib/SnippetGenerator.cpp
  180   assert(!Container.empty() &&
  187   assert(ROV.Op);
  191       assert(AssignedValue.isReg() && AssignedValue.getReg() == ROV.Reg);
  196     assert(ROV.Op->isImplicitReg());
  197     assert(ROV.Reg == ROV.Op->getImplicitReg());
  202   assert(Vector.any());
  211   assert(!AliasingConfigurations.empty());
  212   assert(!AliasingConfigurations.hasImplicitAliasing());
tools/llvm-exegesis/lib/Target.cpp
  100     assert(Op.isReg());
  102     assert(AllowedRegs.size() == ForbiddenRegs.size());
  119   assert(std::is_sorted(
  138   assert(Found->PCI && "Missing counters");
tools/llvm-exegesis/lib/Uops.cpp
  116   assert(I * MemStep < BenchmarkRunner::ScratchSpace::kSize &&
  129     assert(Var);
  131     assert(Op.isReg());
  197       assert(PossibleRegisters.any() && "No register left to choose from");
  210       assert(PossibleRegisters.any() && "No register left to choose from");
tools/llvm-exegesis/lib/X86/Target.cpp
  182   assert(Op.isExplicit() && "invalid memory pattern");
  192   assert(Instr.Operands.size() == 6 && "invalid LEA");
  193   assert(X86II::getMemoryOperandNo(Instr.Description->TSFlags) == 1 &&
  327           assert(PossibleDestRegsNow.set_bits().begin() !=
  460   assert((RegBitWidth & 7) == 0 && "RegBitWidth must be a multiple of 8 bits");
  503   assert(Constant_.getBitWidth() <= Bytes * 8 &&
  633   assert(!isInvalidMemoryInstr(IT.Instr) &&
  636   assert(MemOpIdx >= 0 && "invalid memory operand index");
tools/llvm-ifs/llvm-ifs.cpp
  477       assert(Symbol.Name == SI->second.Name && "Symbol Names Must Match.");
tools/llvm-isel-fuzzer/llvm-isel-fuzzer.cpp
  161   assert(TM && "Could not allocate target machine!");
tools/llvm-jitlink/llvm-jitlink.cpp
  251         assert(SegBlocks.count(Seg) && "No allocation for segment");
  256         assert(SegBlocks.count(Seg) && "No allocation for segment");
  527   assert(!InputFiles.empty() && "InputFiles can not be empty");
  767   assert(EntryPoint.getAddress() && "Entry point address should not be null");
tools/llvm-link/llvm-link.cpp
  167     assert(I != ModuleMap.end());
tools/llvm-lipo/llvm-lipo.cpp
   40   assert(E);
  464   assert(!VerifyArchList.empty() &&
  466   assert(InputBinaries.size() == 1 && "Incorrect number of input binaries");
  518   assert(InputBinaries.size() == 1 && "Incorrect number of input binaries");
  537       assert(Binary->isMachO() && "expected MachO binary");
  549   assert(!ThinArchType.empty() && "The architecture type should be non-empty");
  550   assert(InputBinaries.size() == 1 && "Incorrect number of input binaries");
  551   assert(!OutputFileName.empty() && "Thin expects a single output file");
  729   assert(InputBinaries.size() >= 1 && "Incorrect number of input binaries");
  730   assert(!OutputFileName.empty() && "Create expects a single output file");
  773   assert(InputBinaries.size() == 1 && "Incorrect number of input binaries");
  774   assert(!OutputFileName.empty() && "Replace expects a single output file");
tools/llvm-lto/llvm-lto.cpp
  401       assert(S);
  421   assert(!OutputFilename.empty());
  433   assert(ThinLTOPrefixReplace.empty() ||
tools/llvm-mc/llvm-mc.cpp
  352   assert(MRI && "Unable to create target register info!");
  356   assert(MAI && "Unable to create target asm info!");
  475     assert(FileType == OFT_ObjectFile && "Invalid file type!");
  512     assert(IP && "Expected assembly output");
tools/llvm-mca/Views/BottleneckAnalysis.cpp
  108   assert(Event.Reason != HWPressureEvent::INVALID &&
  152   assert(FromIID < ToIID && "Graph should be acyclic!");
  155   assert(DE.Type != DependencyEdge::DT_INVALID && "Unexpected invalid edge!");
  164     assert(DE.Type == DependencyEdge::DT_RESOURCE &&
  380       assert(Dep.Type == DependencyEdge::DT_RESOURCE &&
  549   assert(Event.Reason != HWPressureEvent::INVALID &&
tools/llvm-mca/Views/BottleneckAnalysis.h
  147     assert(IPI.find(IID) != IPI.end() && "Instruction is not tracked!");
  153     assert(IPI.find(IID) != IPI.end() && "Instruction is not tracked!");
  159     assert(IPI.find(IID) != IPI.end() && "Instruction is not tracked!");
tools/llvm-mca/Views/RegisterFileStatistics.cpp
   63   assert(Inst.getDefs().size() == 1 && "Expected a single definition!");
   64   assert(Inst.getUses().size() == 1 && "Expected a single register use!");
  118     assert(STI.getSchedModel().hasExtraProcessorInfo() &&
  122     assert(I <= PI.NumRegisterFiles && "Unexpected register file index!");
tools/llvm-mca/Views/ResourcePressureView.cpp
   59     assert(Resource2VecIndex.find(RR.first) != Resource2VecIndex.end());
tools/llvm-mca/Views/RetireControlUnitStatistics.cpp
   40     assert(EntriesInUse >= ReleasedEntries && "Invalid internal state!");
tools/llvm-mca/Views/SchedulerStatistics.cpp
   64       assert(Usage[LQResourceID].SlotsInUse);
   68       assert(Usage[SQResourceID].SlotsInUse);
  124   assert(NumCycles && "Unexpected number of cycles!");
tools/llvm-mca/Views/TimelineView.cpp
   27   assert(Iterations && "Invalid number of iterations specified!");
   71     assert(TVEntry.CycleDispatched >= 0 && "Invalid TVEntry found!");
   76     assert(CycleDispatched <= TVEntry.CycleReady &&
  235   assert(Entry.CycleDispatched >= 0 && "Invalid TimelineViewEntry!");
tools/llvm-mca/llvm-mca.cpp
  354   assert(MRI && "Unable to create target register info!");
  359   assert(MAI && "Unable to create target asm info!");
tools/llvm-nm/llvm-nm.cpp
  905   assert(Binding != ELF::STB_WEAK && "STB_WEAK not tested in calling function");
tools/llvm-objcopy/Buffer.cpp
   52   assert(Buf && "allocate() not called before commit()!");
tools/llvm-objcopy/COFF/COFFObjcopy.cpp
  223   assert(Obj && "Unable to deserialize COFF object");
tools/llvm-objcopy/COFF/Object.h
   71     assert(In.size() == sizeof(Opaque));
tools/llvm-objcopy/COFF/Reader.cpp
  109     assert(AuxData.size() == SymSize * SymRef.getNumberOfAuxSymbols());
tools/llvm-objcopy/ELF/Object.cpp
  158   assert(!Fail);
  175   assert(X == 0);
  180   assert((S.size() & 1) == 0);
  192   assert(Line.size());
  204   assert(Iter == Line.end());
  259   assert(!Line.empty());
  272   assert(!Line.empty());
  310   assert(Data.size() == Sec->Size);
  328     assert(SegOffset <= 0xFFFFU);
  337   assert(Addr <= 0xFFFFFU);
  344   assert(Addr <= 0xFFFFFFFFU);
  367   assert(Sec.Size == Sec.StrTabBuilder.getSize());
  386   assert(Sec.Size == Sec.StrTabBuilder.getSize());
  463   assert((HexData.size() & 1) == 0);
  633   assert(ShndxType == SYMBOL_ABS || ShndxType == SYMBOL_COMMON ||
  944   assert(!SecToApplyRel || !ToRemove(SecToApplyRel));
 1215       assert(Obj->Entry <= 0xFFFFFU);
 1789     assert(Seg.FileSize == Seg.getContents().size() &&
 1892   assert(std::is_sorted(std::begin(Segments), std::end(Segments),
 2242   assert(Offset == TotalSize);
tools/llvm-objcopy/ELF/Object.h
  633     assert(Size > 0);
tools/llvm-objcopy/MachO/MachOLayoutBuilder.cpp
   61   assert(MLC.load_command_data.cmd == MachO::LC_DYSYMTAB);
   64   assert(std::is_sorted(O.SymTable.Symbols.begin(), O.SymTable.Symbols.end(),
  134       assert(LC.Sections.empty() && "__LINKEDIT segment has sections");
tools/llvm-objcopy/MachO/MachOReader.cpp
  109     assert(S.NReloc == S.Relocations.size() &&
  178   assert(nlist.n_strx < StrTable.size() &&
tools/llvm-objcopy/MachO/MachOWriter.cpp
   54       assert((DyLdInfoCommand.rebase_size == O.Rebases.Opcodes.size()) &&
   59       assert((DyLdInfoCommand.bind_size == O.Binds.Opcodes.size()) &&
   64       assert((DyLdInfoCommand.weak_bind_size == O.WeakBinds.Opcodes.size()) &&
   70       assert((DyLdInfoCommand.lazy_bind_size == O.LazyBinds.Opcodes.size()) &&
   76       assert((DyLdInfoCommand.export_size == O.Exports.Trie.size()) &&
  190       assert(sizeof(MachO::load_command) + LC.Payload.size() ==
  207   assert(Sec.Segname.size() <= sizeof(Temp.segname) && "too long segment name");
  208   assert(Sec.Sectname.size() <= sizeof(Temp.sectname) &&
  235       assert(Sec.Offset && "Section offset can not be zero");
  236       assert((Sec.Size == Sec.Content.size()) && "Incorrect section size");
  311   assert((DyLdInfoCommand.rebase_size == O.Rebases.Opcodes.size()) &&
  323   assert((DyLdInfoCommand.bind_size == O.Binds.Opcodes.size()) &&
  335   assert((DyLdInfoCommand.weak_bind_size == O.WeakBinds.Opcodes.size()) &&
  347   assert((DyLdInfoCommand.lazy_bind_size == O.LazyBinds.Opcodes.size()) &&
  359   assert((DyLdInfoCommand.export_size == O.Exports.Trie.size()) &&
  373   assert((DySymTabCommand.nindirectsyms == O.IndirectSymTable.Symbols.size()) &&
  386   assert((LinkEditDataCommand.datasize == O.DataInCode.Data.size()) &&
  398   assert((LinkEditDataCommand.datasize == O.FunctionStarts.Data.size()) &&
tools/llvm-objcopy/MachO/Object.cpp
    9   assert(Index < Symbols.size() && "invalid symbol index");
tools/llvm-objcopy/llvm-objcopy.cpp
   63   assert(E);
   73   assert(EC);
   78   assert(E);
   88   assert(E);
tools/llvm-objdump/COFFDump.cpp
   94   assert(UCs.size() >= getNumUsedSlots(UCs[0]));
tools/llvm-objdump/MachODump.cpp
 7666             assert(IsThumb && "ARM mode should have been dealt with above");
 7971   assert(Kind == 2 && "kind for a regular 2nd level index should be 2");
 7994   assert(Kind == 3 && "kind for a compressed 2nd level index should be 3");
tools/llvm-objdump/llvm-objdump.cpp
  424   assert(E);
  891   assert(Obj->isELF());
  933   assert(Obj->isELF());
tools/llvm-opt-fuzzer/llvm-opt-fuzzer.cpp
   55   assert(Mutator &&
  105   assert(TM && "Should have been created during fuzzer initialization");
  147   assert(!Err && "Should have been checked during fuzzer initialization");
  226   assert(TM && "Could not allocate target machine!");
tools/llvm-pdbutil/BytesOutputStyle.cpp
  294   assert(StreamIdx == StreamTPI || StreamIdx == StreamIPI);
  295   assert(!Indices.empty());
  440   assert(!EC);
tools/llvm-pdbutil/DumpOutputStyle.cpp
  458     assert(opts::dump::DumpModi.getNumOccurrences() == 1);
 1406       assert(LocalHashes.size() == GlobalHashes.size());
 1427   assert(StreamIdx == StreamTPI || StreamIdx == StreamIPI);
 1435   assert(!File.isObj());
tools/llvm-pdbutil/ExplainOutputStyle.cpp
   96   assert(FileOffset >= BlockStart);
  181     assert(pdbBlockOffset() > sizeof(SuperBlock));
  202   assert(isPdbFpmBlock());
  205   assert((Fpm == MainFpm) || (Fpm == AltFpm));
  237   assert(Iter != StreamBlocks.end());
  246   assert(Stream <= Streams.size());
  299   assert(Header != nullptr);
  365   assert(Prev.offset() == 0);
  408   assert(Header != nullptr);
  437   assert(Header != nullptr);
tools/llvm-pdbutil/FormatUtil.cpp
   25   assert(MaxLen >= 3);
   35   assert(MaxLen >= 3);
   46   assert(MaxLen >= 3);
   57   assert(MaxLen >= RequiredExtraChars);
   68   assert(MaxLen >= RequiredExtraChars);
tools/llvm-pdbutil/InputFile.cpp
  166   assert(File && File->isPdb());
  204   assert(File && File->isPdb() && DebugStream);
  302   assert(isPdb());
  307   assert(isPdb());
  312   assert(isObj());
  317   assert(isObj());
  322   assert(isUnknown());
  327   assert(isUnknown());
  336   assert(isUnknown());
  374     assert(isPdb() && pdb().hasPDBIpiStream());
  392   assert(isObj());
  393   assert(Kind == kTypes);
  394   assert(!Types);
  457   assert(!isEnd());
  461   assert(!isEnd());
  466   assert(Value.File && !isEnd());
  481   assert(SectionIter.hasValue());
  484   assert(!isEnd());
  503     assert(Index <= Count);
  507   assert(SectionIter.hasValue());
tools/llvm-pdbutil/LinePrinter.cpp
  145   assert(!Blocks.empty());
  227     assert(FoundRun.ByteLen >= RunOffset);
  253     assert(!Blocks.empty());
tools/llvm-pdbutil/PrettyClassDefinitionDumper.cpp
   30   assert(opts::pretty::ClassFormat !=
tools/llvm-pdbutil/PrettyClassLayoutGraphicalDumper.cpp
  109   assert(CurrentItem != nullptr);
  171   assert(CurrentItem != nullptr);
tools/llvm-pdbutil/PrettyTypeDumper.cpp
  276   assert(opts::pretty::Enums);
  292   assert(opts::pretty::Typedefs);
  349   assert(opts::pretty::Classes);
tools/llvm-pdbutil/PrettyVariableDumper.cpp
  114   assert(ElementType);
  122   assert(ElementType);
  201   assert(PointeeType);
tools/llvm-pdbutil/llvm-pdbutil.cpp
  908   assert(opts::pretty::SymbolOrder != opts::pretty::SymbolSortMode::None);
  921   assert(opts::pretty::SymbolOrder != opts::pretty::SymbolSortMode::None);
tools/llvm-profdata/llvm-profdata.cpp
  336     assert(Mid > 0 && "Expected more than one context");
  874     assert(Func.Counts.size() > 0 && "function missing entry counter");
tools/llvm-rc/ResourceFileWriter.cpp
   53   assert(1 <= MaxBits && MaxBits <= 32);
  108   assert(StripSuccess && "Strings should be enclosed in quotes.");
  170       assert(Ch <= 0x7F && "We didn't allow identifiers to be non-ASCII");
  414   assert(Length > 0);
  491       assert(EmplaceResult.second && "Could not create a bundle");
 1178   assert(Def);
 1281     assert(Iter != StringTableData.BundleData.end());
 1389   assert((HasStrings || HasInts) && "VALUE must have at least one argument");
 1419     assert(ValueLength % 2 == 0);
tools/llvm-rc/ResourceFileWriter.h
   48     assert(FS && "Output stream needs to be provided to the serializator");
tools/llvm-rc/ResourceScriptParser.cpp
  100   assert(!isEof());
  105   assert(!isEof());
  110   assert(!isEof());
  291   assert(MinCount <= MaxCount);
  323   assert(!FlagDesc.empty());
  324   assert(FlagDesc.size() == FlagValues.size());
  474   assert(isNextTokenKind(Kind::BlockBegin) &&
  677     assert(IsMenuItem);
  808   assert(DialogType != OptStmtType::BasicStmt);
tools/llvm-rc/ResourceScriptStmt.h
  154     assert(IsInt);
  159     assert(!IsInt);
tools/llvm-rc/ResourceScriptToken.cpp
   48   assert(TokenKind == Kind::Int);
   53   assert(IsSuccess);
  269     assert(false && "Cannot consume an invalid token.");
  280   assert(!streamEof());
  287   assert(!streamEof());
  294   assert(!streamEof());
  299   assert(!streamEof());
  304   assert(!streamEof());
  309   assert(!streamEof());
  349   assert(Token.kind() == Kind::Identifier);
tools/llvm-readobj/ARMWinEHPrinter.cpp
  269   assert((~RegisterMask & (1 << 13)) && "sp must not be set");
  270   assert((~RegisterMask & (1 << (Prologue ? 15 : 14))) && "pc must not be set");
  371   assert(!Prologue && "may not be used in prologue");
  387   assert(!Prologue && "may not be used in prologue");
  782   assert((!Prologue || Offset == 0) && "prologue should always use offset 0");
  923   assert(RF.Flag() == RuntimeFunctionFlag::RFF_Unpacked &&
 1014   assert((RF.Flag() == RuntimeFunctionFlag::RFF_Packed ||
tools/llvm-readobj/COFFDumper.cpp
  298   assert(SectionContents.data() < RelocPtr &&
  323   assert(SectionContents.begin() < Block.begin() &&
tools/llvm-readobj/ELFDumper.cpp
  453     assert (&W.getOStream() == &llvm::fouts());
tools/llvm-readobj/WasmDumper.cpp
  250   assert(WasmObj && "createWasmDumper called with non-wasm object");
tools/llvm-readobj/Win64EHDumper.cpp
  180   assert(UC.size() >= getNumUsedSlots(UC[0]));
tools/llvm-readobj/XCOFFDumper.cpp
  216   assert(!Obj.is64Bit() && "32-bit interface called on 64-bit object file.");
  242   assert(!Obj.is64Bit() && "32-bit interface called on 64-bit object file.");
  297     assert(false && "This StorageClass for the symbol is not yet implemented.");
tools/llvm-readobj/llvm-readobj.cpp
  375   assert(Err);
  384   assert(Err);
tools/llvm-reduce/deltas/Delta.cpp
   94   assert(Targets >= 0);
tools/llvm-rtdyld/llvm-rtdyld.cpp
  360   assert(LoadObjects || !UseDebugObj);
  828       assert(I != Result->end() &&
tools/llvm-stress/llvm-stress.cpp
  145     assert(Val <= max() && "Random value out of range");
  205     assert(PT->size());
  577         assert(VSize < DestSize && "Different int types with the same size?");
tools/llvm-xray/trie-node.h
   56   assert(Left.FuncId == Right.FuncId);
tools/llvm-xray/xray-account.cpp
  237   assert(!Timings.empty());
tools/llvm-xray/xray-color-helper.cpp
  182   assert(!ColorMap.empty() && "ColorMap must not be empty!");
  183   assert(!BoundMap.empty() && "BoundMap must not be empty!");
tools/llvm-xray/xray-graph.cpp
  230         assert(ThreadStack.size() != 0);
  283   assert(!G.edges().empty());
  286     assert(!A.Timings.empty());
tools/llvm-xray/xray-registry.cpp
   26   assert(Commands->count(SC) == 0 &&
   28   assert(Command && "Attempting to register an empty std::function<Error()>");
   34   assert(It != Commands->end() &&
tools/lto/lto.cpp
  515   assert(index < unwrap(cg)->getProducedBinaries().size() && "Index overflow");
  526   assert(index < unwrap(cg)->getProducedBinaryFiles().size() &&
tools/obj2yaml/coff2yaml.cpp
  128     assert(Magic == COFF::DEBUG_SECTION_MAGIC && "Invalid .debug$S section!");
  178     assert(NewYAMLSection.Alignment <= 8192);
  296         assert(Symbol.getNumberOfAuxSymbols() == 1 &&
  305         assert(Symbol.getNumberOfAuxSymbols() == 1 &&
  314         assert(Symbol.getNumberOfAuxSymbols() == 1 &&
  329         assert(Symbol.getNumberOfAuxSymbols() == 1 &&
  338         assert(Symbol.getNumberOfAuxSymbols() == 1 &&
tools/obj2yaml/dwarf2yaml.cpp
  130       assert(EntryData.isValidOffset(offset) && "Invalid DIE Offset");
tools/obj2yaml/elf2yaml.cpp
   97   assert(&Sections[SecIndex] == Sec);
  944   assert(Shdr->sh_type == ELF::SHT_MIPS_ABIFLAGS &&
tools/opt/Debugify.cpp
  117       assert(LastInst && "Expected basic block with a terminator");
  122       assert(InsertPt != BB.end() && "Expected to find an insertion point");
  158   assert(NMD->getNumOperands() == 2 &&
  224   assert(NMD->getNumOperands() == 2 &&
  269       assert(Var <= OriginalNumVars && "Unexpected name for DILocalVariable");
tools/opt/opt.cpp
  868     assert(Out);
  907     assert(Out);
tools/polly/include/polly/ScopInfo.h
  296     assert(Dim < getNumberOfDimensions() && "Invalid dimension");
  306     assert(Dim < getNumberOfDimensions() && "Invalid dimension");
  747     assert(!isRead());
  748     assert(isAnyPHIKind());
  759     assert(isAnyPHIKind());
  885     assert(isWrite() && "Only write statement store values");
  942     assert(!getOriginalScopArrayInfo() /* not yet initialized */ ||
 1396     assert(!isCopyStmt() &&
 1436       assert(!ArrayAccess && "More then one array access for instruction");
 1451     assert(ArrayAccess && "No array access found for instruction!");
 1459     assert((isRegionStmt() && R->contains(Inst)) ||
 1480     assert(isBlockStmt() || R->getExit() == PHI->getParent());
 1494         assert(!lookupValueReadOf(Val) && "input accesses must be unique; a "
 2072       assert(!ValueDefAccs.count(Access->getAccessValue()) &&
 2077       assert(!PHIReadAccs.count(PHI) &&
tools/polly/include/polly/Support/GICHelper.h
  302     assert(IslCtx);
  303     assert(isl_ctx_get_max_operations(IslCtx) == 0 && "Incorrect nesting");
  319     assert(isl_ctx_get_max_operations(IslCtx) > 0 && "Incorrect nesting");
  320     assert(isl_options_get_on_error(IslCtx) == ISL_ON_ERROR_CONTINUE &&
  375     assert(IslCtx);
  376     assert(isl_ctx_get_max_operations(IslCtx) == 0 &&
tools/polly/include/polly/Support/ScopHelper.h
   86   explicit MemAccInst(llvm::Instruction &I) : I(&I) { assert(isa(I)); }
   87   explicit MemAccInst(llvm::Instruction *I) : I(I) { assert(isa(I)); }
  117     assert(V);
  161     assert(I && "Unexpected nullptr!");
tools/polly/include/polly/Support/VirtualInstruction.h
  188     assert(this->User == that.User);
  193     assert(this->User == that.User);
  246     assert(Stmt && Inst);
tools/polly/lib/Analysis/DependenceInfo.cpp
  159           assert(StmtScheduleMap &&
  596   assert(isl_union_map_is_equal(RED_SIN, TC_RED) &&
  657     assert(!StmtScat.is_null() &&
  778   assert(hasValidDependences() && "No valid dependences available");
  812   assert(ReductionDependences.count(MA) == 0 &&
  932     assert(It.second && "Invalid SCoP object!");
  940     assert((It.first && It.second) && "Invalid Scop or Dependence object!\n");
tools/polly/lib/Analysis/PolyhedralInfo.cpp
  101   assert((SI) && "ScopInfoWrapperPass is required by PolyhedralInfo pass!\n");
  128   assert(CurrDim >= 0 && "Loop in region should have at least depth one");
  136       assert(
tools/polly/lib/Analysis/ScopBuilder.cpp
  171     assert(idx == 0);
  234   assert(NumDimsS >= Dim + 1);
  312     assert(OldL->getParentLoop() == NewL->getParentLoop());
  316     assert(OldDepth + 1 == NewDepth);
  319     assert(NewL->getParentLoop() == OldL ||
  323     assert(OldDepth > NewDepth);
  326     assert(NumDim >= Diff);
  395   assert(Condition && "No condition for switch");
  415   assert(ConditionSets[0] == nullptr && "Default condition set was set");
  458     assert(Opcode == Instruction::And || Opcode == Instruction::Or);
  481     assert(ICond &&
  532   assert(ConsequenceCondSet);
  569   assert(isa<BranchInst>(TI) && "Terminator was neither branch nor switch.");
  577   assert(Condition && "No condition for Terminator");
  609     assert(Domain);
  650   assert(Domain && "Cannot propagate a nullptr");
  726   assert(LoopDepth >= 0 && "Loop in region should have at least depth one");
  729   assert(scop->isDomainDefined(HeaderBB));
  751     assert(BI && "Only branch instructions allowed in loop latches");
  769     assert(LatchLoopDepth >= LoopDepth);
  940     assert(RN->isSubRegion() || TI->getNumSuccessors() == ConditionSets.size());
 1011     assert(Domain && "Cannot propagate a nullptr");
 1119   assert(!isa<PHINode>(Inst));
 1153   assert(N >= 0);
 1154   assert(USet);
 1155   assert(!USet.is_empty());
 1176   assert(LoopStack.size() == 1 && LoopStack.back().L == L);
 1257   assert(LoopStack.rbegin() != LoopStack.rend());
 1282     assert(std::next(LoopData) != LoopStack.rend());
 1335   assert(Ty && "Ty expected to be initialized");
 1561     assert(Dom && "Cannot propagate a nullptr.");
 1689   assert(BasePointer && "Could not find base pointer");
 1732   assert(LengthVal);
 1748   assert(DestPtrVal);
 1751   assert(DestAccFunc);
 1761   assert(DestPtrSCEV);
 1773   assert(SrcPtrVal);
 1776   assert(SrcAccFunc);
 1783   assert(SrcPtrSCEV);
 1854   assert(BasePointer && "Could not find base pointer");
 2212   assert(
 2215   assert(Stmt->represents(&BB));
 2229       assert(Stmt && "Cannot build access function in non-existing statement");
 2323   assert(Size != 0);
 2458       assert(SAI && "memory access into a Fortran array does not "
 2605     assert(Acc->getAccessInstruction() == PHI);
 2614   assert(Acc);
 2745     assert(LI && scop->contains(LI));
 2883   assert(!AccessRelation.is_empty());
 3275   assert((!MaxPMA || MaxPMA.dim(isl::dim::out)) &&
 3531   assert(PhysUse.getKind() == VirtUse.getKind());
 3577       assert(VirtDef.getKind() == VirtualUse::Synthesizable ||
 3625       assert(!List.empty());
tools/polly/lib/Analysis/ScopDetection.cpp
  379   assert(ValidRegions.size() <= DetectionContextMap.size() &&
  396     assert(!Assert && "Verification of detected scop failed");
  663   assert(SI && "Terminator was neither branch nor switch");
 1837   assert(isMaxRegionInScop(R) && "Expect R is a valid region.");
tools/polly/lib/Analysis/ScopDetectionDiagnostic.cpp
  624     assert(V && "Diagnostic info does not match found LLVM-IR anymore.");
tools/polly/lib/Analysis/ScopInfo.cpp
  297   assert(FAD && "got invalid Fortran array descriptor");
  299     assert(this->FAD == FAD &&
  304   assert(DimensionSizesPw.size() > 0 && !DimensionSizesPw[0]);
  305   assert(!this->FAD);
  402   assert(!Id.is_null() && "Output dimension didn't have an ID");
  522     assert(ElemBytes % ArrayElemSize == 0 &&
  704   assert(isMemoryIntrinsic());
  705   assert(Subscripts.size() == 2 && Sizes.size() == 1);
  763   assert(Min.sle(Max) && "Minimum expected to be less or equal than max");
  840   assert(AccessRelation.is_null() && "AccessRelation already built");
 1064   assert(NewAccess);
 1071   assert(OriginalDomainSpace.has_equal_tuples(NewDomainSpace));
 1081     assert(StmtDomain.is_subset(NewDomain) &&
 1086   assert(NewAccessSpace.has_tuple_id(isl::dim::set) &&
 1090   assert(SAI && "Must set a ScopArrayInfo");
 1096     assert(EqClass &&
 1104   assert(NewAccessSpace.dim(isl::dim::set) == Dims &&
 1139   assert(NewDomain.is_subset(Domain) &&
 1152     assert(!ValueWrites.lookup(AccessVal));
 1157     assert(!ValueReads.lookup(AccessVal));
 1162     assert(!PHIWrites.lookup(PHI));
 1167     assert(!PHIReads.lookup(PHI));
 1298     assert(Found && "Expected access data not found");
 1303     assert(Found && "Expected access data not found");
 1308     assert(Found && "Expected access data not found");
 1313     assert(Found && "Expected access data not found");
 1341     assert(MAIt != MemAccs.end());
 1492   assert(Parameters.count(Parameter));
 1493   assert(!ParameterIds.count(Parameter));
 1576       assert(!Id.is_null() &&
 1821   assert((BasePtr || BaseName) &&
 1823   assert(!(BasePtr && BaseName) && "BaseName is redundant.");
 1866   assert(SAI && "No ScopArrayInfo available for this base pointer");
 1873   assert(AssumedContext && "Assumed context not yet built");
 1928   assert(AssumedContext && "Assumed context not yet built");
 2121   assert((Set.is_params() || BB) &&
 2371   assert(BB && "Unexpected nullptr!");
 2376     assert(!InstStmtMap.count(Inst) &&
 2384   assert(R && "Unexpected nullptr!");
 2389     assert(!InstStmtMap.count(Inst) &&
 2399       assert(!InstStmtMap.count(&Inst) &&
 2411   assert(Domain.is_subset(TargetDomain) &&
 2413   assert(Domain.is_subset(SourceDomain) &&
 2471     assert(OuterLoop);
 2486   assert(SAI && "can only use after access relations have been constructed");
 2512   assert(SAI->isValueKind());
 2522   assert(SAI->isValueKind());
 2530   assert(SAI->isPHIKind() || SAI->isExitPHIKind());
 2540   assert(SAI->isPHIKind() || SAI->isExitPHIKind());
 2548   assert(contains(Inst) && "The concept of escaping makes only sense for "
 2631   assert(Stats.NumLoops == ScopStats.NumAffineLoops + ScopStats.NumBoxedLoops);
 2745     assert(Inserted && "Building Scop for the same region twice!");
tools/polly/lib/CodeGen/BlockGenerators.cpp
   87   assert(IP != Builder.GetInsertBlock()->end() &&
  143     assert(!BBMap.count(Old));
  148     assert(!GlobalMap.count(Old));
  205     assert(!GlobalMap.count(Old) &&
  210   assert(New && "Unexpected scalar dependence in region!");
  230       assert(!isa<StoreInst>(NewInst) &&
  288   assert(
  418   assert(Stmt.isBlockStmt() &&
  470   assert(!Access.isLatestArrayKind() && "Trying to get alloca for array kind");
  476   assert(!Array->isArrayKind() && "Trying to get alloca for array kind");
  567     assert(!StmtDom.is_subset(AccDom).is_false() &&
  573     assert((!isa<Instruction>(Address) ||
  590   assert(!USchedule.is_empty());
  673   assert(Schedule.is_empty().is_false() &&
  760   assert(Stmt.isBlockStmt() &&
  775             assert(MA->getIncoming().size() >= 1 &&
  779             assert(std::all_of(MA->getIncoming().begin(),
  791           assert((!isa<Instruction>(Val) ||
  795           assert((!isa<Instruction>(Address) ||
  964     assert((!isa<Instruction>(OriginalValue) ||
 1015   assert(Schedule && "No statement domain provided");
 1041   assert(PointerTy && "PointerType expected");
 1166   assert(isa<CastInst>(Inst) && "Can not generate vector code for instruction");
 1365   assert(Stmt.isBlockStmt() &&
 1452   assert(Common && R->contains(Common));
 1458   assert(Stmt.isRegionStmt() &&
 1511       assert(RegionMaps.count(BBCopyIDom));
 1549   assert(ExitDomBBCopy &&
 1649     assert(RegionMaps.count(NewIncomingBlockStart));
 1650     assert(RegionMaps.count(NewIncomingBlockEnd));
 1671     assert(!Incoming.empty() &&
 1692   assert(Stmt.getRegion() &&
 1721           assert(NewVal && "The exit scalar must be determined before");
 1724           assert((!isa<Instruction>(NewVal) ||
 1728           assert((!isa<Instruction>(Address) ||
 1745     assert(!BBCopyEnd);
 1746     assert(Stmt.represents(IncomingBB) &&
 1752   assert(RegionMaps.count(BBCopyStart) &&
 1781   assert(OpCopy && "Incoming PHI value was not copied properly");
tools/polly/lib/CodeGen/CodeGeneration.cpp
  201   assert(!R->isTopLevelRegion() && "Top level regions are not supported");
  206   assert(R->isSimple());
  208   assert(EnteringBB);
  257     assert(ExitingBlock);
  259     assert(MergeBlock);
  263     assert(ExitingBB);
tools/polly/lib/CodeGen/CodegenCleanup.cpp
   45     assert(!FPM);
tools/polly/lib/CodeGen/IRBuilder.cpp
   77     assert(Array->getBasePtr() && "Base pointer must be present");
  106   assert(Id->getOperand(0) == Id && "Expected Id to be a self-reference");
  107   assert(Id->getNumOperands() == 1 && "Unexpected extra operands in Id");
  119   assert(!ParallelLoops.empty() && "Expected a parallel loop to pop");
  137     assert(!ParallelLoops.empty() && "Expected a parallel loop to annotate");
  238   assert(OtherAliasScopeListMap.count(BasePtr) &&
tools/polly/lib/CodeGen/IslAst.cpp
  290   assert(Id && "Post order visit assumes annotated for nodes");
  292   assert(Payload && "Post order visit assumes annotated for nodes");
  295   assert(!Payload->Build && "Build environment already set");
  324   assert(isl_ast_node_get_type(Node) == isl_ast_node_mark);
  336   assert(!isl_ast_node_get_annotation(Node) && "Node already annotated");
  475   assert(Ast);
tools/polly/lib/CodeGen/IslExprBuilder.cpp
   86   assert(Type == isl_ast_expr_op && "Expected isl_ast_expr of type operation");
  135   assert(ResultStruct->getType()->isStructTy());
  165   assert(isa<IntegerType>(T1) && isa<IntegerType>(T2));
  174   assert(isl_ast_expr_get_op_type(Expr) == isl_ast_op_minus &&
  179   assert(MaxType->isIntegerTy() &&
  193   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  195   assert(isl_ast_expr_get_op_n_arg(Expr) >= 2 &&
  235   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  237   assert(isl_ast_expr_get_op_type(Expr) == isl_ast_op_access &&
  239   assert(isl_ast_expr_get_op_n_arg(Expr) >= 1 &&
  263   assert(SAI && "No ScopArrayInfo found for this isl_id.");
  270   assert(Base->getType()->isPointerTy() && "Access base should be a pointer");
  290     assert(NextIndex->getType()->isIntegerTy() &&
  344   assert(Addr && "Could not create op access address");
  353   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  355   assert(isl_ast_expr_get_op_n_arg(Expr) == 2 &&
  456   assert(isl_ast_expr_get_op_type(Expr) == isl_ast_op_select &&
  483   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  522   assert(OpType >= isl_ast_op_eq && OpType <= isl_ast_op_gt &&
  524   assert(isl_ast_op_eq + 4 == isl_ast_op_gt &&
  543   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  551   assert((OpType == isl_ast_op_and || OpType == isl_ast_op_or) &&
  591   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  602   assert((OpType == isl_ast_op_and_then || OpType == isl_ast_op_or_else) &&
  649   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  695   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  697   assert(isl_ast_expr_get_op_n_arg(Expr) == 1 && "Address of should be unary.");
  700   assert(isl_ast_expr_get_type(Op) == isl_ast_expr_op &&
  702   assert(isl_ast_expr_get_op_type(Op) == isl_ast_op_access &&
  713   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_id &&
  721   assert(IDToValue.count(Id) && "Identifier not found");
  730   assert(V && "Unknown parameter id found");
  747   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_int &&
tools/polly/lib/CodeGen/IslNodeBuilder.cpp
  114   assert(isl_ast_expr_get_type(Cond.get()) == isl_ast_expr_op &&
  132   assert(isl_ast_expr_get_type(Arg0.get()) == isl_ast_expr_id &&
  137   assert(isl_ast_expr_get_type(Iterator.get()) == isl_ast_expr_id &&
  142   assert(UBID.get() == IteratorID.get() &&
  167   assert(isl_ast_node_get_type(For.get()) == isl_ast_node_for);
  238     assert(Stmt->isCopyStmt());
  460   assert(Schedule && "For statement annotation does not contain its schedule");
  504   assert(isl_ast_node_get_type(Node.get()) == isl_ast_node_for);
  839   assert(Build && "Could not obtain isl_ast_build from user node");
  858     assert(MA->isAffine() &&
  873       assert(isl_set_is_subset(SchedDom, AccDom) &&
  875       assert(isl_set_is_subset(Dom, AccDom) &&
  906   assert(isl_ast_expr_get_type(Expr) == isl_ast_expr_op &&
  908   assert(isl_ast_expr_get_op_type(Expr) == isl_ast_op_call &&
  943   assert(Stmt->size() == 2);
  946   assert((*ReadAccess)->isRead() && (*WriteAccess)->isMustWrite());
  947   assert((*ReadAccess)->getElementType() == (*WriteAccess)->getElementType() &&
  949   assert((*ReadAccess)->isArrayKind() && (*WriteAccess)->isArrayKind());
  960   assert(OutsideLoopIterations.find(L) == OutsideLoopIterations.end() &&
 1136   assert(GlobalDescriptor && "invalid global descriptor given");
 1153   assert(endType && "expected type of end to be integral");
 1172     assert(ParametricPwAff && "parametric pw_aff corresponding "
 1179     assert(Id && "pw_aff is not parametric");
 1188     assert(FinalValue && "unable to build Fortran array "
 1328   assert(MA->isArrayKind() && MA->isRead());
 1386     assert(PreloadVal->getType() == MAAccInst->getType());
 1415         assert(BasePtr->getType() == PreloadVal->getType());
 1449     assert(SAI->getNumberOfDimensions() > 0 && SAI->getDimensionSize(0) &&
 1565   assert(Builder.GetInsertBlock()->end() != Builder.GetInsertPoint() &&
tools/polly/lib/CodeGen/LoopGenerators.cpp
   91   assert(LB->getType() == UB->getType() && "Types of loop bounds do not match");
   93   assert(LoopIVType && "UB is not integer?");
tools/polly/lib/CodeGen/PerfMonitor.cpp
  171   assert(FinalStartBB && "Expected FinalStartBB to be initialized by "
  173   assert(ReturnFromFinal && "Expected ReturnFromFinal to be initialized by "
tools/polly/lib/CodeGen/RuntimeDebugBuilder.cpp
  132         assert(Ty->getIntegerBitWidth() &&
  205         assert(Ty->getIntegerBitWidth() == 64 &&
tools/polly/lib/CodeGen/Utils.cpp
   34   assert(Prev && Succ);
   98   assert(EnteringBB && "Must be a simple region");
  118   assert(ExitingBB && "Must be a simple region");
tools/polly/lib/Exchange/JSONExporter.cpp
  290     assert(Schedule.hasValue() &&
  366     assert(Statement);
  390       assert(JsonMemoryAccess);
tools/polly/lib/External/isl/imath/gmp_compat.c
   67   CHECK(mp_rat_init(x));
   72   CHECK(mp_rat_mul(multiplier, multiplicand, product));
   77   CHECK(mp_rat_copy(op, rop));
   82   CHECK(mp_int_abs(op, rop));
   87   CHECK(mp_int_add(op1, op2, rop));
  112   CHECK(mp_int_init(x));
  117   CHECK(mp_int_mul(op1, op2, rop));
  122   CHECK(mp_int_neg(op, rop));
  127   CHECK(mp_int_set_value(rop, op));
  132   CHECK(mp_int_copy(op, rop));
  137   CHECK(mp_int_sub(op1, op2, rop));
  157   CHECK(mp_rat_set_uvalue(rop, op1, op2));
  162   CHECK(mp_int_set_uvalue(rop, op));
  177   CHECK(mp_rat_reduce(op));
  192   CHECK(mp_int_mul(op1, op2, temp));
  193   CHECK(mp_int_add(rop, temp, rop));
  200   CHECK(mp_int_div(n, d, q, NULL));
  219   CHECK(mp_int_init(r));
  220   CHECK(mp_int_div(n, d, NULL, r));
  234   CHECK(mp_int_mul(op1, op2, temp));
  235   CHECK(mp_int_sub(rop, temp, rop));
  244   CHECK(mp_int_init_uvalue(temp, op2));
  246   CHECK(mp_int_add(op1, temp, rop));
  256   CHECK(mp_int_init_uvalue(temp, d));
  258   CHECK(mp_int_div(n, temp, q, NULL));
  267   CHECK(mp_int_init_uvalue(temp, op2));
  269   CHECK(mp_int_mul(op1, temp, rop));
  282     CHECK(mp_int_set_value(rop, 1));
  287   CHECK(mp_int_init_uvalue(temp, exp));
  288   CHECK(mp_int_expt_full(base, temp, rop));
  296   CHECK(mp_int_init_uvalue(temp, op2));
  298   CHECK(mp_int_sub(op1, temp, rop));
  319   CHECK(mp_int_gcd(op1, op2, rop));
  338   CHECK(mp_int_to_string(op, r, str, len));
  369   CHECK(mp_rat_to_string(op, r, str, len));
  454   CHECK(res == MP_RANGE ? MP_OK : MP_RANGE);
  474   CHECK(res == MP_RANGE ? MP_OK : MP_RANGE);
  503   CHECK(mp_int_lcm(op1, op2, rop));
  504   CHECK(mp_int_abs(rop, rop));
  513     CHECK(mp_int_mul_pow2(op1, op2, rop));
  565   CHECK(mp_int_init(r));
  572   CHECK(mp_int_div(n, d, q, r));
  579       CHECK(mp_int_add_value(q, 1, q));
  585         CHECK(mp_int_set_value(q, 1));
  597   CHECK(mp_int_init(r));
  604   CHECK(mp_int_div(n, d, q, r));
  611       CHECK(mp_int_sub_value(q, 1, q));
  617         CHECK(mp_int_set_value(q, -1));
  634   CHECK(mp_int_init(q));
  635   CHECK(mp_int_init(temp));
  637   CHECK(mp_int_init_copy(orig_d, d));
  638   CHECK(mp_int_init_copy(orig_n, n));
  657   CHECK(mp_int_div(n, d, q, NULL));
  669   CHECK(mp_int_init_uvalue(temp, d));
  670   CHECK(mp_int_init(r));
  672   CHECK(mp_int_init_copy(orig_n, n));
  677   CHECK(mp_int_to_uint(r, &rl));
  698   assert(nails  == 0 && "Do not support non-full words");
  699   assert(endian == 1 || endian == 0 || endian == -1);
  700   assert(order == 1 || order == -1);
  712   assert(num_used_bytes > 0);
  724   assert(num_missing_bytes < size);
  780   assert(nails  == 0 && "Do not support non-full words");
  781   assert(endian == 1 || endian == 0 || endian == -1);
  782   assert(order == 1 || order == -1);
  844   CHECK((res > 0) == MP_OK);
tools/polly/lib/External/isl/imath/imath.c
  385   CHECK(z != NULL);
  410   CHECK(z != NULL && old != NULL);
  481   NRCHECK(z != NULL);
  489   CHECK(a != NULL && c != NULL);
  525   NRCHECK(z != NULL);
  536   CHECK(a != NULL && c != NULL);
  549   CHECK(a != NULL && c != NULL);
  564   CHECK(a != NULL && b != NULL && c != NULL);
  639   CHECK(a != NULL && b != NULL && c != NULL);
  711   CHECK(a != NULL && b != NULL && c != NULL);
  776   CHECK(a != NULL && c != NULL && p2 >= 0);
  792   CHECK(a != NULL && c != NULL);
  838   CHECK(a != NULL && b != NULL && q != r);
  981   CHECK(a != NULL && p2 >= 0 && q != r);
  998   CHECK(c != NULL);
 1030   CHECK(c != NULL);
 1062   CHECK(a != NULL && b != NULL && c != NULL);
 1096   CHECK(a != NULL && b != NULL);
 1120   NRCHECK(a != NULL && b != NULL);
 1127   NRCHECK(z != NULL);
 1142   CHECK(z != NULL);
 1156   CHECK(z != NULL);
 1171   CHECK(a != NULL && b != NULL && c != NULL && m != NULL);
 1232   CHECK(a && b && m && c);
 1264   CHECK(m != NULL && c != NULL && m != c);
 1275   CHECK(a != NULL && m != NULL && c != NULL);
 1318   CHECK(a != NULL && b != NULL && c != NULL);
 1397   CHECK(a != NULL && b != NULL && c != NULL &&
 1503   CHECK(a != NULL && b != NULL && c != NULL);
 1540   CHECK(z != NULL);
 1555   CHECK(a != NULL && c != NULL && b > 0);
 1620   CHECK(z != NULL);
 1650   CHECK(z != NULL);
 1678   CHECK(z != NULL && str != NULL && limit >= 2);
 1732   CHECK(z != NULL);
 1756   CHECK(z != NULL && str != NULL);
 1816   CHECK(z != NULL);
 1841   CHECK(z != NULL && buf != NULL);
 1857   CHECK(z != NULL && buf != NULL && len > 0);
 1909   CHECK(z != NULL && buf != NULL);
 1919   CHECK(z != NULL && buf != NULL && len > 0);
 1972   assert(out != NULL); /* for debugging */
 1999   assert(new != NULL); /* for debugging */
 2146   assert(size_a >= size_b);
 2167   assert(w == 0);
 2240     assert(carry == 0);
 2244     assert(carry == 0);
 2317     assert(carry == 0);
 2321     assert(carry == 0);
 2381     assert(w == 0);
 2606   assert(UPPER_HALF(w) != 0); /* no borrow out should be possible */
 2783       assert(MP_SIGN(TEMP(0)) == MP_ZPOS);
 2787       assert(MP_SIGN(TEMP(0)) == MP_ZPOS);
 2868   assert(n > 1);
 2869   assert(m >= 0);
 2964         assert(qhat > 0);
 2969       assert(s_ucmp(&t, &r) <=  0 && "The mathematics failed us.");
 3022   assert(r >= MP_MIN_RADIX && r <= MP_MAX_RADIX);
 3054   assert(v >= 0);
tools/polly/lib/External/isl/imath/imrat.c
  148   NRCHECK(r != NULL);
tools/polly/lib/External/isl/isl_test.c
   69 	assert(map);
   98 	assert(pwqp);
  107 	assert(pwaff);
  409 	assert(map);
  414 	assert(map);
  435 	assert(isl_map_is_equal(map, map2));
  443 	assert(isl_map_is_equal(map, map2));
  465 	assert(filename);
  467 	assert(input);
  506 	assert(!bounded);
  953 	assert(bset && bset->n_div == 1);
  976 	assert(bset && bset->n_div == 1);
  999 	assert(bset && bset->n_div == 1);
 1022 	assert(isl_basic_set_is_empty(bset));
 1043 	assert(bset && bset->n_div == 0);
 1064 	assert(bset && bset->n_div == 1);
 1146 	assert(!isl_basic_set_is_empty(bset));
 1202 	assert(filename);
 1204 	assert(input);
 1213 	assert(isl_basic_set_is_equal(bset1, bset2) == 1);
 1237 	assert(filename);
 1239 	assert(input);
 1246 	assert(isl_basic_set_is_equal(bset1, bset2) == 1);
 1429 	assert(filename);
 1431 	assert(input);
 1441 	assert(isl_basic_set_is_equal(bset1, bset2) == 1);
 1533 	assert(filename);
 1535 	assert(input);
 1544 	assert(isl_basic_set_is_equal(bset1, bset2) == 1);
 1795 	assert(bset1 && bset1->n_div == 0);
 2351 	assert(exact);
 2361 	assert(exact);
 2368 	assert(isl_map_is_equal(map, map2));
 2379 	assert(isl_map_is_equal(map, map2));
 2390 	assert(exact);
 2397 	assert(isl_map_is_equal(map, map2));
 2411 	assert(exact);
 2424 	assert(exact);
 2437 	assert(exact);
 2447 	assert(isl_map_is_equal(map, map2));
 2453 	assert(exact);
 2455 	assert(isl_map_is_equal(map, map2));
 2478 	assert(exact);
 2487 	assert(exact);
 2497 	assert(exact);
 2503 	assert(isl_map_is_equal(map, map2));
 2514 	assert(exact);
 2520 	assert(!exact);
 2523 	assert(isl_map_is_equal(map, map2));
 2533 	assert(exact);
 2535 	assert(isl_map_is_equal(map, map2));
 2542 	assert(exact);
 2544 	assert(isl_map_is_equal(map, map2));
 2570 	assert(map);
 2678 	assert(!isl_set_is_empty(set));
 2702 	assert(isl_map_is_equal(map, map2));
 2926 	assert(map_is_equal(mm.must, str));
 2928 	assert(map_is_equal(mm.may, str));
 2955 	assert(map_is_equal(mm.must, str));
 2957 	assert(map_is_equal(mm.may, str));
 2985 	assert(map_is_equal(mm.may, str));
 2987 	assert(map_is_equal(mm.must, str));
 3015 	assert(map_is_equal(mm.may, str));
 3017 	assert(map_is_equal(mm.must, str));
 3045 	assert(map_is_equal(mm.may, str));
 3047 	assert(map_is_equal(mm.must, str));
 3072 	assert(map_is_equal(mm.must, str));
 3074 	assert(map_is_equal(mm.may, str));
 3224 	assert(isl_pw_qpolynomial_is_zero(pwqp1));
 3254 	assert(isl_pw_qpolynomial_is_zero(pwqp1));
 3265 	assert(isl_pw_qpolynomial_is_zero(pwqp1));
 3274 	assert(isl_pw_qpolynomial_is_zero(pwqp1));
 9406 	assert(options);
tools/polly/lib/External/ppcg/gpu.c
   82 	assert(array->refs);
  354 	assert(prog->array);
  548 		assert(v);
 1054 		assert(pos >= 0);
 5490 	assert(access);
 5798 	assert(prog);
tools/polly/lib/Support/GICHelper.cpp
   56   assert(isl_val_is_int(Val) && "Only integers can be converted to APInt");
tools/polly/lib/Support/ISLTools.cpp
   55   assert(FromSpace1.is_set());
   56   assert(FromSpace2.is_set());
  142   assert(!Result || Result.get_space().has_equal_tuples(ExpectedSpace));
  155   assert(!Result || Result.get_space().has_equal_tuples(ExpectedSpace));
  208   assert(Pos < NumDims && "Dimension index must be in range");
  229   assert(Pos < NumDims && "Dimension index must be in range");
  397   assert(InclStart && InclEnd);
  412   assert(InclStart && InclEnd);
  427   assert(InclStart && InclEnd);
  517   assert(!Max || !Min); // Cannot return min and max at the same time.
  740     assert(OpenPos != std::string::npos);
  742     assert(ClosePos != std::string::npos);
  752   assert(!First);
tools/polly/lib/Support/RegisterPasses.cpp
  463   assert(!DumpBefore && "This option is not implemented");
  464   assert(DumpBeforeFile.empty() && "This option is not implemented");
  469   assert(!PollyViewer && "This option is not implemented");
  470   assert(!PollyOnlyViewer && "This option is not implemented");
  471   assert(!PollyPrinter && "This option is not implemented");
  472   assert(!PollyOnlyPrinter && "This option is not implemented");
  473   assert(!EnablePolyhedralInfo && "This option is not implemented");
  474   assert(!EnableDeLICM && "This option is not implemented");
  475   assert(!EnableSimplify && "This option is not implemented");
  478   assert(!DeadCodeElim && "This option is not implemented");
  479   assert(!EnablePruneUnprofitable && "This option is not implemented");
  489   assert(!ExportJScop && "This option is not implemented");
  511   assert(!DumpAfter && "This option is not implemented");
  512   assert(DumpAfterFile.empty() && "This option is not implemented");
tools/polly/lib/Support/SCEVAffinator.cpp
  287     assert(isl_set_dim(OutOfBoundsDom, isl_dim_set) == 0 &&
  388   assert(Expr->isAffine() && "Only affine AddRecurrences allowed");
  394     assert(S->contains(Expr->getLoop()) &&
  468   assert(isa<SCEVConstant>(Divisor) &&
  497   assert(SDiv->getOpcode() == Instruction::SDiv && "Assumed SDiv instruction!");
  503   assert(isa<SCEVConstant>(DivisorSCEV) &&
  514   assert(SRem->getOpcode() == Instruction::SRem && "Assumed SRem instruction!");
  520   assert(isa<ConstantInt>(Divisor) &&
tools/polly/lib/Support/SCEVValidator.cpp
   54     assert(Type != SCEVType::PARAM && "Did you forget to pass the parameter");
  263     assert(Recurrence.isConstant() && "Expected 'Recurrence' to be constant");
  353     assert(I->getOpcode() == Instruction::Call && "Call instruction expected");
  408     assert(SDiv->getOpcode() == Instruction::SDiv &&
  417     assert(SRem->getOpcode() == Instruction::SRem &&
  707   assert(Result.isValid() && "Requested parameters for an invalid SCEV!");
tools/polly/lib/Support/ScopHelper.cpp
   94   assert(R->getEnteringBlock() == EnteringBB);
  145   assert(ExitingBB == R->getExitingBlock());
  158   assert(R && !R->isTopLevelRegion());
  159   assert(!RI || RI == R->getRegionInfo());
  160   assert((!RI || DT) &&
  165   assert(R->isSimple());
  174   assert(Old && SplitPt);
  273     assert(!Inst->mayThrow() && !Inst->mayReadOrWriteMemory() &&
  278       assert(SE.isSCEVable(Op->getType()));
tools/polly/lib/Support/VirtualInstruction.cpp
   42         assert(IncomingMA->getStatement() == UserStmt);
   54   assert(!isa<StoreInst>(Val) && "a StoreInst cannot be used");
  192   assert(MA->isOriginalValueKind());
  304       assert(VUse.getMemoryAccess());
tools/polly/lib/Transform/DeLICM.cpp
  244     assert(Occupied || Unused);
  245     assert(Known);
  246     assert(Written);
  252     assert(Occupied.is_disjoint(Unused));
  255     assert(!Known.domain().is_subset(Universe).is_false());
  256     assert(!Written.domain().is_subset(Universe).is_false());
  296     assert(!isConflicting(*this, That));
  297     assert(Unused && That.Occupied);
  298     assert(
  301     assert(!Occupied && "This function does not implement "
  334     assert(Existing.Unused);
  335     assert(Proposed.Occupied);
  341       assert(ExistingUniverse.is_equal(ProposedUniverse) &&
  552     assert(SAI);
  584       assert(MA);
  615     assert(SAI->isValueKind());
  628     assert(DefMA);
  665     assert(SAI->isValueKind());
  668     assert(DefMA->isValueKind());
  669     assert(DefMA->isMustWrite());
  776       assert(isl_union_map_n_map(NewAccRel.get()) == 1);
  813       assert(!Incoming.empty());
  829     assert(Result.is_single_valued() &&
  844     assert(PHIRead->isPHIKind());
  845     assert(PHIRead->isRead());
 1003     assert(TargetStoreMA->isLatestArrayKind());
 1004     assert(TargetStoreMA->isMustWrite());
 1205       assert(isl_ctx_last_error(IslCtx.get()) == isl_error_quota &&
 1222     assert(Zone.isUsable() && OriginalZone.isUsable());
 1323         assert(isCompatibleAccess(MA));
 1405     assert(Impl->getScop() == &S);
tools/polly/lib/Transform/FlattenAlgo.cpp
  179   assert(Dims >= 2);
  261   assert(scheduleScatterDims(Schedule) >= 2);
tools/polly/lib/Transform/ForwardOpTree.cpp
  192     assert(!ValInst.is_single_valued().is_false());
  295       assert(isl_ctx_last_error(IslCtx.get()) == isl_error_quota);
  420       assert(!DoIt);
  425       assert(!DoIt);
  430       assert(DoIt);
  441     assert(!isNormalized(ExpectedVal).is_false() &&
  518     assert(Access);
  652         assert(!DoIt);
  657         assert(!DoIt);
  662         assert(DoIt);
  797     assert(RA->isLatestScalarKind());
  812     assert(Assessment != FD_DidForwardTree && Assessment != FD_DidForwardLeaf);
  818     assert(((Execution == FD_DidForwardTree) ||
  953     assert(Impl->getScop() == &S);
tools/polly/lib/Transform/MaximalStaticExpansion.cpp
  334     assert(isl_union_map_n_map(MapDependences.get()) == 1 &&
  378     assert(isDimBoundedByConstant(CurrentStmtDomain, i) &&
  381     assert(!UpperBound.is_null() && UpperBound.is_pos() &&
  384     assert(UpperBound.le(isl::val(CurrentAccessMap.get_ctx(),
  451       assert(AllWrites.size() == 1 || SAI->isValueKind());
tools/polly/lib/Transform/ScheduleOptimizer.cpp
  307   assert(OutDimsNum <= Dims &&
  384   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band);
  400   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band);
  404   assert(DimToVectorize < ScheduleDimensions);
  468   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band);
  469   assert(isl_schedule_node_n_children(Node.get()) == 1);
  559   assert(DstPos < Map.dim(DimType) && SrcPos < Map.dim(DimType));
  688   assert(OutDimNum > 2 && "In case of the matrix multiplication the loop nest "
  810   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band &&
  835   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band);
  899   assert(TTI && "The target transform info should be provided.");
  908   assert(ElementSize > 0 && "The element size of the matrix multiplication "
 1002   assert(ElementSize > 0 && "The element size of the matrix multiplication "
 1012   assert(Mc > 0 && Nc > 0 && Kc > 0 &&
 1256   assert(isl_schedule_node_get_type(Node.get()) == isl_schedule_node_band);
 1260   assert(isl_union_set_n_set(Domain.get()) == 1);
 1278   assert(TTI && "The target transform info should be provided.");
 1282   assert(DimOutNum > 2 && "In case of the matrix multiplication the loop nest "
 1377   assert(OldSchedule && "Only IslScheduleOptimizer can insert extension nodes "
tools/polly/lib/Transform/ScheduleTreeTransform.cpp
   32     assert(!Node.is_null());
   35       assert(isl_schedule_node_n_children(Node.get()) == 1);
   38       assert(isl_schedule_node_n_children(Node.get()) == 1);
   41       assert(isl_schedule_node_n_children(Node.get()) >= 2);
   45       assert(isl_schedule_node_n_children(Node.get()) >= 2);
   47       assert(isl_schedule_node_n_children(Node.get()) == 0);
   50       assert(isl_schedule_node_n_children(Node.get()) == 1);
   53       assert(isl_schedule_node_n_children(Node.get()) == 1);
   56       assert(isl_schedule_node_n_children(Node.get()) == 1);
  296     assert(Extensions && Extensions.is_empty());
  355       assert(ExtDims >= BandDims);
  451     assert(Pos == ASTBuildOptions.size() &&
  468   assert(!Schedule.is_null());
tools/polly/lib/Transform/ScopInliner.cpp
   55     assert(SCC.size() == 1 && "found empty SCC");
   89       assert(M && "Function has illegal module");
tools/polly/lib/Transform/Simplify.cpp
  231         assert(V);
  398         assert(V);
  492     assert(NumStmtsBefore >= S->getSize());
  629     assert(!isModified());
  671     assert(&S == this->S &&
tools/polly/lib/Transform/ZoneAlgo.cpp
  391   assert(MA->isLatestArrayKind());
  392   assert(MA->isRead());
  447   assert(MA->isLatestArrayKind());
  448   assert(MA->isWrite());
  544   assert(SAI->isPHIKind());
  576   assert(!Result.is_single_valued().is_false());
  577   assert(!Result.is_injective().is_false());
  627   assert(!Result || Result.domain().is_equal(Domain) == isl_bool_true);
  682     assert(DefDomain.dim(isl::dim::set) <= TargetDomain.dim(isl::dim::set));
  892   assert(MA->isRead());
 1039         assert(Incoming.size() == 1 && "The incoming value must be "
 1059       assert(!PHIMap.is_single_valued().is_false());
 1079   assert(!NormalizeMap || isNormalized(NormalizeMap));
tools/polly/unittests/DeLICM/DeLICMTest.cpp
   41     assert(!Occupied);
   46     assert(!Known);
   61     assert(Occupied);
   70   assert(Occupied);
   71   assert(Undef);
   72   assert(Known);
tools/sanstats/sanstats.cpp
  147     assert(Begin <= End);
tools/verify-uselistorder/verify-uselistorder.cpp
  114   assert(!Vector.empty());
unittests/ADT/APIntTest.cpp
 2682     assert(1 < Width && Width < 32);
 2754     assert(V0.getBitWidth() == V1.getBitWidth() && "Must have same bitwidth");
unittests/ADT/ArrayRefTest.cpp
   70     void operator=(const NonAssignable &RHS) { assert(RHS.Ptr != nullptr); }
unittests/ADT/DenseMapTest.cpp
   23   assert(i < 8192 && "Only support 8192 dummy keys.");
   28   assert(i < 8192 && "Only support 8192 dummy keys.");
unittests/ADT/FallibleIteratorTest.cpp
   51     assert(Idx != C.size() && "Walking off end of (mock) collection");
   61     assert(Idx != 0 && "Walking off start of (mock) collection");
   71     assert(&LHS.C == &RHS.C && "Comparing iterators across collectionss.");
unittests/ADT/PriorityWorklistTest.cpp
  138     assert(i != 0 && "Saw a null value!");
unittests/ADT/TestGraph.h
   32     assert(Idx < N && "Invalid node index!");
   44       assert(N <= sizeof(BitVector)*CHAR_BIT && "Graph too big!");
  199       assert(false && "Incrementing end iterator!");
  217       assert(false && "Dereferencing end iterator!");
unittests/Analysis/AliasAnalysisTest.cpp
  224     assert(M && "Failed to build the module!");
unittests/Analysis/BasicAliasAnalysisTest.cpp
   57     assert(F);
unittests/Analysis/CFGTest.cpp
   62     assert(ExclusionSet.empty());
unittests/Analysis/CGSCCPassManagerTest.cpp
 1169         assert(H3F.getName() == "h3" && "Wrong called function!");
 1179         assert(&NewC != &C && "Should get a new SCC due to update!");
 1217         assert(H3F.getName() == "h3" && "Wrong called function!");
 1225         assert(&NewC != &C && "Should get a new SCC due to update!");
unittests/Analysis/DomTreeUpdaterTest.cpp
   27   assert(M && "Bad LLVM IR?");
unittests/Analysis/IVDescriptorsTest.cpp
   79         assert(Header->getName() == "for.body");
   83         assert(Inst_i->getName() == "i");
   95         assert(Inst_inc->getName() == "inc");
unittests/Analysis/LoopInfoTest.cpp
   83     assert(Header->getName() == "for.cond");
  133     assert(Header->getName() == "for.cond");
  268         assert(Header->getName() == "for.body");
  326         assert(Header->getName() == "for.body");
  384         assert(Header->getName() == "for.body");
  442         assert(Header->getName() == "for.body");
  500         assert(Header->getName() == "for.body");
  559         assert(Header->getName() == "for.body");
  617         assert(Header->getName() == "for.body");
  672         assert(Header->getName() == "for.body");
  730         assert(Header->getName() == "for.body");
  789         assert(Header->getName() == "for.body");
  848         assert(Header->getName() == "for.body");
  908         assert(Header->getName() == "for.body");
  968         assert(Header->getName() == "for.body");
 1020         assert(Header->getName() == "for.body");
 1077         assert(Header->getName() == "for.body");
 1146         assert(Header->getName() == "for.outer");
 1172         assert(Header->getName() == "for.inner");
 1238         assert(Header->getName() == "for.body");
 1302     assert(Header && "No header");
 1348         assert(Header && "No header");
 1392     assert(Header->getName() == "for.cond");
 1435     assert(Header->getName() == "for.cond");
unittests/Analysis/MemorySSATest.cpp
   62     assert(F);
unittests/Analysis/ScalarEvolutionTest.cpp
  282   assert(M && "Could not parse module?");
  283   assert(!verifyModule(*M) && "Must have been well formed!");
  530   assert(M && "Could not parse module?");
  531   assert(!verifyModule(*M) && "Must have been well formed!");
 1474     assert(M && "Could not parse module?");
 1475     assert(!verifyModule(*M) && "Must have been well formed!");
 1517     assert(M && "Could not parse module?");
 1518     assert(!verifyModule(*M) && "Must have been well formed!");
 1597     assert(M && "Could not parse module?");
 1598     assert(!verifyModule(*M) && "Must have been well formed!");
 1652     assert(M && "Could not parse module?");
 1653     assert(!verifyModule(*M) && "Must have been well formed!");
 1727       assert(Diff == ExtDiff && "Integer overflow");
 1773     assert(M && "Could not parse module?");
 1774     assert(!verifyModule(*M) && "Must have been well formed!");
 1814     assert(M && "Could not parse module?");
 1815     assert(!verifyModule(*M) && "Must have been well formed!");
 1867     assert(M && "Could not parse module?");
 1868     assert(!verifyModule(*M) && "Must have been well formed!");
unittests/Analysis/ValueTrackingTest.cpp
  491   assert(M && "Bad assembly?");
  494   assert(F && "Bad assembly?");
unittests/DebugInfo/CodeView/RandomAccessVisitorTest.cpp
   77     assert(Indices.size() == RawRecords.size());
   78     assert(Indices.size() == VisitedRecords.size());
unittests/DebugInfo/CodeView/TypeHashingTest.cpp
   52   assert(!Hashes.empty());
unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp
   51     assert(Context != nullptr && "test state is not valid");
unittests/DebugInfo/DWARF/DwarfGenerator.cpp
  118   assert(Form == DW_FORM_flag_present);
  317     assert(Include.getAsCString() && "expected a string form for include dir");
  323     assert(File.Name.getAsCString() && "expected a string form for file name");
  341     assert(Include.getAsCString() && "expected a string form for include dir");
  350     assert(File.Name.getAsCString() && "expected a string form for file name");
  506     assert(Length != -1U);
unittests/DebugInfo/DWARF/DwarfGenerator.h
  181     assert(Version >= 2 && Version <= 5 && "unsupported version");
unittests/DebugInfo/DWARF/DwarfUtils.cpp
   38   assert((AddrSize == 4 || AddrSize == 8) &&
unittests/ExecutionEngine/JITLink/JITLinkTestCommon.cpp
  128   assert(!MemMgr && "Memory manager already set");
unittests/ExecutionEngine/MCJIT/MCJITTestBase.h
  305     assert(M != 0 && "a non-null Module must be provided to create MCJIT");
  318     assert(TheJIT.get() != NULL && "error creating MCJIT with EngineBuilder");
unittests/ExecutionEngine/Orc/CoreAPIsTest.cpp
  844         assert(BarDiscarded && "Bar should have been discarded by this point");
unittests/ExecutionEngine/Orc/LegacyRTDyldObjectLinkingLayerTest.cpp
  137         assert(I != Resolvers.end() && "Missing resolver");
unittests/ExecutionEngine/Orc/OrcTestCommon.h
  217     assert(addModuleImpl &&
  223     assert(removeModuleImpl &&
  229     assert(findSymbolImpl &&
  236     assert(findSymbolInImpl &&
unittests/ExecutionEngine/Orc/RTDyldObjectLinkingLayerTest.cpp
  119       assert(Foo && "Expected function Foo not found");
unittests/FuzzMutate/OperationsTest.cpp
   67   assert(M && !verifyModule(*M, &errs()));
unittests/FuzzMutate/RandomIRBuilderTest.cpp
   41   assert(M && !verifyModule(*M, &errs()));
unittests/FuzzMutate/ReservoirSamplerTest.cpp
   55     assert(Items.size() == 10 && "Our chi-squared values assume 10 items");
unittests/FuzzMutate/StrategiesTest.cpp
   62   assert(M && !verifyModule(*M, &errs()));
unittests/IR/CFGBuilder.cpp
   33   assert(F);
  109   assert(NameToBlock.count(A.From) != 0 && "No block to disconnect (From)");
  110   assert(NameToBlock.count(A.To) != 0 && "No block to disconnect (To)");
  125     assert(Connected);
unittests/IR/ConstantRangeTest.cpp
  474         assert(!HaveInterrupt3 && "Should have at most three ranges");
  513           assert(Lower1.isNullValue() && Upper3.isMaxValue());
 2151     assert((CR.isEmptySet() || !AllNegative || !AllNonNegative) &&
unittests/IR/DominatorTreeTest.cpp
   42   assert(M && "Bad assembly?");
  304         assert(TI->getNumSuccessors() == 3 && "Switch has three successors");
  307         assert(Edge_BB0_BB2.getEnd() == BB2 &&
  311         assert(Edge_BB0_BB1_a.getEnd() == BB1 && "BB1 is the 2nd successor");
  314         assert(Edge_BB0_BB1_b.getEnd() == BB1 && "BB1 is the 3rd successor");
unittests/IR/MetadataTest.cpp
 1815   assert(!IsLocalToUnit && IsDefinition && !IsOptimized &&
unittests/Linker/LinkModulesTest.cpp
  253   assert(Src);
  333   assert(Foo);
  341   assert(Bar);
unittests/Support/AlignmentTest.cpp
  235     assert(I >= 1);
unittests/Support/ManagedStatic.cpp
   68     assert(Ms1.isConstructed());
unittests/Support/ReplaceFileTest.cpp
   57   assert(Buffer);
   65   assert(!EC);
unittests/Support/SpecialCaseListTest.cpp
   29     assert(SCL);
   30     assert(Error == "");
unittests/Support/VirtualFileSystemTest.cpp
  145     assert(!EC);
unittests/Support/raw_ostream_test.cpp
   33   assert(BytesLeftInBuffer < 256 && "Invalid buffer count!");
unittests/Target/WebAssembly/WebAssemblyExceptionInfoTest.cpp
   35   assert(TheTarget);
unittests/Transforms/Scalar/LoopPassManagerTest.cpp
 1384     assert(L.empty() && "Can only delete leaf loops with this routine!");
unittests/Transforms/Utils/CloningTest.cpp
  424         assert(Header->getName() == "for.outer");
unittests/Transforms/Utils/CodeExtractorTest.cpp
  271   assert(M && "Could not parse module?");
unittests/Transforms/Utils/IntegerDivisionTest.cpp
   31   assert(F->arg_size() == 2);
   61   assert(F->arg_size() == 2);
   91   assert(F->arg_size() == 2);
  121   assert(F->arg_size() == 2);
  152   assert(F->arg_size() == 2);
  182   assert(F->arg_size() == 2);
  212   assert(F->arg_size() == 2);
  242   assert(F->arg_size() == 2);
unittests/Transforms/Utils/LocalTest.cpp
  784       assert(DVI->getVariable()->getName() == "2");
unittests/tools/llvm-exegesis/Common/AssemblerUtils.h
   37     assert(ET);
utils/FileCheck/FileCheck.cpp
  340       assert(DiagItr->InputStartLine < DiagItr->InputEndLine &&
utils/PerfectShuffle/PerfectShuffle.cpp
  115     assert(TheOperators.back() == this);
  137         assert(SrcElt == 8 && "Bad src elt!");
  152     assert(0 && "bad zero cost operation");
  394     assert(OpNum < 16 && "Too few bits to encode operation!");
utils/TableGen/AsmMatcherEmitter.cpp
  256     assert(isUserClass() && RHS.isUserClass() && "Unexpected class!");
  319       assert(RHS.Kind == Token);
  325       assert(RHS.isRegisterClass());
  329       assert(RHS.isUserClass());
  565     assert(!DefRec.is<const CodeGenInstAlias *>());
  782     assert(Def->isSubClassOf("Predicate") && "Invalid predicate type!");
  928   assert(!AsmOperands[0].Token.empty());
 1013       assert(i != String.size() && "Invalid quoted character");
 1033       assert(EndPos != StringRef::npos &&
 1335     assert(CI && "Missing singleton register class info!");
 1384       assert(isa<UnsetInit>(PMName) && "Unexpected PredicateMethod field!");
 1393       assert(isa<UnsetInit>(RMName) && "Unexpected RenderMethod field!");
 1423       assert(isa<UnsetInit>(DMName) && "Unexpected DefaultMethod field!");
 1581         assert(Op.Class && Op.Class->Registers.size() == 1 &&
 1688     assert(Rec->isSubClassOf("Operand") && "Unexpected operand!");
 1800       assert(AsmOperands[SrcOperand+AI].SubOpIdx == (int)AI &&
 1928   assert(ID < Table.size());
 2103           assert(HasOptionalOperands);
 2125           assert(HasOptionalOperands);
 2157         assert(OpInfo.MINumOperands == 1 && "Not a singular MCOperand");
 2163         assert((i > TiedOp || TiedOp == (uint8_t)-1) &&
 2264     assert(TiedOperandsEnumMap.size() <= 254 &&
 2310     assert(ConversionTable[Row].size() % 2 == 0 && "bad conversion row!");
 2328       assert(TiedOpndEnum != TiedOperandsEnumMap.end() &&
 2405       assert(!CI.DiagnosticType.empty() &&
 3378       assert(I != Info.SubtargetFeatures.end() && "Didn't import predicate?");
utils/TableGen/AsmWriterEmitter.cpp
  367           assert(NumOps <= Inst.Operands.size() &&
  435     assert(NumBits <= BitsLeft && "consistency error");
  632     assert(OpIdx >= 0 && OpIdx < 0xFE && "Idx out of range");
  633     assert(PrintMethodIdx >= -1 && PrintMethodIdx < 0xFF &&
  699         assert(isOpMapped(Name) && "Unmapped operand!");
  960         assert(!Ops.empty() && "AssemblerCondString cannot be empty");
  963           assert(!Op.empty() && "Empty operator");
utils/TableGen/CodeEmitterGen.cpp
  109     assert(!CGI.Operands.isFlatOperandNotEmitted(OpIdx) &&
  595       assert(I != SubtargetFeatures.end() && "Didn't import predicate?");
utils/TableGen/CodeGenDAGPatterns.cpp
   87   assert(isValueTypeByHwMode(true) &&
  172   assert(empty());
  365   assert(!Out.empty() && "cannot pick from an empty set");
  470   assert(Small.hasDefault() && Big.hasDefault());
  573     assert(!V.empty() && !E.empty());
  744   assert(Legal.isDefaultOnly() && "Default-mode only expected");
  815   assert(LegalCache.isDefaultOnly() && "Default-mode only expected");
  852   assert(
 1306   assert(hasPredCode() && "Don't have any predicate code!");
 1644   assert(RC && "Unknown operand type");
 1717   assert(NumResults <= 1 &&
 1719   assert(ResNo == 0 && "Only handles single result nodes so far");
 1768     assert(LI && "Invalid Fragment");
 1775       assert(Op && "Invalid Fragment");
 1937         assert(NewChild && "Couldn't find formal argument!");
 1938         assert((Child->getPredicateCalls().empty() ||
 1985         assert((Child->getPredicateCalls().empty() ||
 2105     assert(ResNo == 0 && "Regoperand ref only has one result!");
 2115     assert(ResNo == 0 && "Regclass ref only has one result!");
 2130     assert(ResNo == 0 && "FIXME: PatFrag with multiple results?");
 2136     assert(ResNo == 0 && "Registers only produce one result!");
 2144     assert(ResNo == 0 && "SubRegisterIndices only produce one result!");
 2149     assert(ResNo == 0 && "This node only has one result!");
 2168     assert(ResNo == 0 && "This node only has one result!");
 2174     assert(ResNo == 0 && "FIXME: ComplexPattern with multiple results?");
 2180     assert(ResNo == 0 && "Regclass can only have one result!");
 2348       assert(Types.size() == 1 && "Invalid IntInit");
 2405       assert(getChild(i+1)->getNumTypes() == 1 && "Unhandled case");
 2460       assert(getChild(0)->getNumTypes() == 1 && "FIXME: Unhandled");
 2584   assert(getOperator()->isSubClassOf("SDNodeXForm") && "Unknown node type!");
 2769     assert(New->getNumTypes() == 1 && "FIXME: Unhandled");
 2873     assert(Result->getName().empty());
 2958           assert(Node->getNumTypes() == 1 &&
 2971           assert(N1->getNumTypes() == 1 && N2->getNumTypes() == 1 &&
 3195   assert(!SDNodes.empty() && "No SDNodes parsed?");
 3211     assert(P.getNumTrees() == 1 && "This ctor can only produce one tree!");
 3273     assert(Slot->getNumChildren() == 0 && "can't be a use with children!");
 3564     assert(DI && "non-dag in an instruction Pattern list?!");
 3604   assert(!DAGInsts.count(CGI.TheDef) && "Instruction already parsed!");
 3649   assert(I.getArgList().empty() && "Args list should still be empty here!");
 3753     assert(ResNodes[i]->getNumTypes() == 1 && "FIXME: Unhandled");
 4436   assert(N->getNumChildren()==2 &&"Associative but doesn't have 2 children!");
 4537     assert((N->getNumChildren()>=2 || isCommIntrinsic) &&
 4556       assert(NC >= 3 &&
 4611     assert(!Variants.empty() && "Must create at least original variant!");
utils/TableGen/CodeGenDAGPatterns.h
  119       assert(Pos != Capacity);
  128       assert(Pos != Capacity);
  219     assert(isMachineValueType());
  235     assert(isPointer());
  270     assert(VTS.isValueTypeByHwMode(AllowEmpty));
  433     assert(Scope != 0 &&
  514     assert(!Result.empty() && "Isn't an immediate pattern!");
  723   Init *getLeafValue() const { assert(isLeaf()); return Val; }
  724   Record *getOperator() const { assert(!isLeaf()); return Operator; }
  752     assert(PredicateCalls.empty() && "Overwriting non-empty predicate list!");
  756     assert(!Call.Fn.isAlwaysTrue() && "Empty predicate string!");
  757     assert(!is_contained(PredicateCalls, Call) && "predicate applied recursively");
  761     assert((Scope != 0) == Fn.usesOperands());
  921     assert(Trees.size() == 1 && "Doesn't have exactly one pattern!");
  938     assert(i < Args.size() && "Argument reference out of range!");
 1037     assert(RN < Results.size());
 1042     assert(ON < Operands.size());
 1047     assert(RN < ImpResults.size());
 1064     assert(R->isSubClassOf("Predicate") &&
 1090     assert(!Def == !P.Def && "Inconsistency between Def and IsHwMode");
 1186     assert(F != SDNodes.end() && "Unknown node!");
 1194     assert(F != SDNodeXForms.end() && "Invalid transform!");
 1206     assert(F != ComplexPatterns.end() && "Unknown addressing mode!");
 1236     assert(F != DefaultOperands.end() &&"Isn't an analyzed default operand!");
 1243     assert(F != PatternFragments.end() && "Invalid pattern fragment request!");
 1273     assert(F != Instructions.end() && "Unknown instruction!");
utils/TableGen/CodeGenHwModes.cpp
   74     assert(P.second);
   83   assert(F != ModeIds.end() && "Unknown mode name");
   89   assert(F != ModeSelects.end() && "Record is not a \"mode select\"");
utils/TableGen/CodeGenHwModes.h
   48       assert(Id != 0 && "Mode id of 0 is reserved for the default mode");
utils/TableGen/CodeGenInstruction.cpp
  164   assert(!Name.empty() && "Cannot search for operand with no name!");
  451   assert(FirstImplicitDef->isSubClassOf("Register"));
  499     assert(VariantsEnd != Cur.size() &&
utils/TableGen/CodeGenInstruction.h
   56         assert(isTied());
  196         assert(i < OperandList.size() && "Invalid flat operand #");
  354       StringRef getName() const { assert(isRecord()); return Name; }
  355       Record *getRecord() const { assert(isRecord()); return R; }
  356       int64_t getImm() const { assert(isImm()); return Imm; }
  357       Record *getRegister() const { assert(isReg()); return R; }
utils/TableGen/CodeGenRegisters.cpp
  117   assert(M.any() && "Missing lane mask, sub-register cycle?");
  127     assert(std::equal(Parts.begin(), Parts.end(),
  138       assert(SRI->ConcatenationOf.empty() && "No transitive closure?");
  200   assert(TheDef && "no def");
  224   unsigned operator* () const { assert(isValid()); return *UnitI; }
  226   const CodeGenRegister *getReg() const { assert(isValid()); return *RegI; }
  230     assert(isValid() && "Cannot advance beyond the last operand");
  488       assert(!Cand->ExplicitSubRegs.empty() &&
  495       assert(Cand->ExplicitSubRegs[0] == SubReg && "LeadingSuperRegs correct");
  496       assert(getSubRegIndex(SubReg) == SubRegIdx && "LeadingSuperRegs correct");
  579   assert(SubRegsComplete && "Must precompute sub-registers");
  756   assert(!VTs.empty() && "RegisterClass must contain at least one ValueType!");
  795   assert((RSI.hasDefault() || Size != 0 || VTs[0].isSimple()) &&
  837   assert(!getDef() && "Only synthesized classes can inherit properties");
  838   assert(!SuperClasses.empty() && "Synthesized class without super class");
  881   assert(Members && B.Members);
 1011   assert(SuperRegRCs.front() == BiggestSuperRegRC && "Biggest class wasn't first");
 1286   assert(Parts.size() > 1 && "Need two parts to concatenate");
 1289     assert(Idx->ConcatenationOf.empty() && "No transitive closure?");
 1400         assert(Idx3 && "Sub-register doesn't have an index");
 1459       assert(Idx.LaneMask == LaneBitmask::getLane(DstBit) &&
 1478         assert(Idx2.LaneMask == SrcMask);
 1486         assert(Composite->getComposites().empty());
 1589   assert(Registers.size() == Registers.back().EnumValue &&
 1604     assert(USetID && "register number 0 is invalid");
 1777     assert(NumIters <= NumNativeRegUnits && "Runaway register unit weights");
 1827   assert(RegClassUnitSets.empty() && "this invalidates RegClassUnitSets");
 1877   assert(RegUnitSets.empty() && "dirty RegUnitSets");
 1926     assert(Idx < (2*NumRegUnitSubSets) && "runaway unit set inference");
 2009     assert(!RegClassUnitSets[RCIdx].empty() && "missing unit set for regclass");
 2067             assert(!Found);
 2073         assert(Found);
 2129   assert(!RegClasses.empty());
 2238       assert(Sub && "Missing sub-register");
 2247     assert(!RegClasses.empty());
 2285   assert(!RegClasses.empty());
 2382   assert(BestRC && "Couldn't find the register class");
utils/TableGen/CodeGenRegisters.h
  110       assert(A && B);
  183       assert(SubRegsComplete && "Must precompute sub-registers");
  203       assert(SubRegsComplete && "Must precompute sub-registers");
  220       assert(SuperRegsComplete && "TopoSigs haven't been computed yet.");
  499       assert(!(Roots[1] && !Roots[0]) && "Invalid roots array");
utils/TableGen/CodeGenSchedule.cpp
  275   assert(MaxIndex >= 0 && "Invalid negative indices in input!");
  278     assert(Index >= 0 && "Invalid negative indices!");
  608         assert(RW->isSubClassOf("SchedRead") && "Unknown SchedReadWrite");
  622         assert(RWDef->isSubClassOf("SchedRead") && "Unknown SchedReadWrite");
  636         assert(RWDef->isSubClassOf("SchedRead") && "Unknown SchedReadWrite");
  654       assert(MatchDef->isSubClassOf("SchedRead") && "Unknown SchedReadWrite");
  664     assert(!getSchedRWIdx(SWDef, /*IsRead=*/false) && "duplicate SchedWrite");
  669     assert(!getSchedRWIdx(SRDef, /*IsRead-*/true) && "duplicate SchedWrite");
  751       assert(RWDef->isSubClassOf("SchedRead") && "unknown SchedReadWrite");
  772     assert(Idx && "failed to collect SchedReadWrite");
  847   assert(!Seq.empty() && "cannot insert empty sequence");
  868   assert(SchedClasses.empty() && "Expected empty sched class");
 1011   assert(!ProcIndices.empty() && "expect at least one ProcIdx");
 1077           assert(SchedClasses[OldSCIdx].ProcIndices[0] == 0 &&
 1131         assert(OldRWDef != InstRWDef &&
 1159     assert(!ItinRecords.empty() && "ProcModel.hasItineraries is incorrect");
 1185     assert(!ProcModel.ItinDefList[0] && "NoItinerary class can't have rec");
 1231     assert(SchedClasses[Idx].Index == Idx && "bad SCIdx");
 1241     assert(SchedClasses.size() < (NumInstrSchedClasses*6) &&
 1272     assert(SchedClasses[SCIdx].InstRWs.size() == E && "InstrRWs was mutated!");
 1368     assert(SchedRW.HasVariants && "PredCheck must refer to a SchedVariant");
 1523     assert(VInfo.VarOrSeqDef->isSubClassOf("WriteSequence") &&
 1551     assert(OperIdx == RWSequences.size() && "missed a sequence");
 2032     assert(AliasRW.IsRead == IsRead && "cannot alias reads to writes");
 2062   assert(!ProcResourceDefs.empty());
 2063   assert(!ProcResGroups.empty());
 2119   assert(PIdx && "don't add resources to an invalid Processor model");
utils/TableGen/CodeGenSchedule.h
   77     assert(Sequence.size() > 1 && "implied sequence needs >1 RWs");
   81     assert((!HasVariants || TheDef) && "Variant write needs record def");
   82     assert((!IsVariadic || HasVariants) && "Variadic write needs variants");
   83     assert((!IsSequence || !HasVariants) && "Sequence can't have variant");
   84     assert((!IsSequence || !Sequence.empty()) && "Sequence should be nonempty");
   85     assert((!IsAlias || Aliases.empty()) && "Alias cannot have aliases");
  361     assert(std::find(Opcodes.begin(), Opcodes.end(), Opcode) == Opcodes.end() &&
  472       assert(ModelDef->getValueAsBit("NoModel")
  482     assert(I != ProcModelMap.end() && "missing machine model");
  488     assert(I != ProcModelMap.end() && "missing machine model");
  506     assert(Idx < SchedWrites.size() && "bad SchedWrite index");
  507     assert(SchedWrites[Idx].isValid() && "invalid SchedWrite");
  512     assert(Idx < SchedReads.size() && "bad SchedRead index");
  513     assert(SchedReads[Idx].isValid() && "invalid SchedRead");
  537     assert(Idx < SchedClasses.size() && "bad SchedClass index");
  541     assert(Idx < SchedClasses.size() && "bad SchedClass index");
utils/TableGen/CodeGenTarget.cpp
  437     assert(Instr && "Missing target independent instruction");
  438     assert(Instr->Namespace == "TargetOpcode" && "Bad namespace");
  442   assert(EndOfPredefines == getNumFixedInstructions() &&
  454   assert(InstrsByEnum.size() == Insts.size() && "Missing predefined instr");
  667       assert(TyEl->isSubClassOf("LLVMType") && "Expected a type!");
  684     assert(TyEl->isSubClassOf("LLVMType") && "Expected a type!");
  688       assert(MatchTy < OverloadedVTs.size() &&
  694       assert(((!TyEl->isSubClassOf("LLVMExtendedType") &&
  715     assert(TyEl->isSubClassOf("LLVMType") && "Expected a type!");
  730       assert(((!TyEl->isSubClassOf("LLVMExtendedType") &&
  751     assert(Property->isSubClassOf("IntrinsicProperty") &&
utils/TableGen/CodeGenTarget.h
  150     assert(I != Instructions.end() && "Not an instruction");
utils/TableGen/DAGISelMatcher.cpp
   55     assert(Other && "Other didn't come before 'this'?");
  109   assert(i < Operands.size());
utils/TableGen/DAGISelMatcher.h
  915     assert(i < ChainNodes.size());
 1011     assert(i < VTs.size());
 1017     assert(i < Operands.size());
utils/TableGen/DAGISelMatcherEmitter.cpp
  119         assert(Entry != 0);
  120         assert(TreePredicateFn(SameCodePreds.front()).usesOperands() ==
  214   assert(CurBuf && "Invalid or unspecified location!");
  245   assert(isUInt<16>(VecPatterns.size()) &&
  247   assert(VecPatterns.size() == VecIncludeStrings.size() &&
  289     assert(SM->getNext() == nullptr && "Shouldn't have next after scope");
  323       assert(ChildSize != 0 && "Should not have a zero-sized child!");
  481       assert(ChildSize != 0 && "Should not have a zero-sized child!");
  678       assert(isUInt<16>(Reg->EnumValue) && "not handled");
  846     assert(!PredFn.isAlwaysTrue() && "No code in this predicate");
utils/TableGen/DAGISelMatcherGen.cpp
   44     assert((!T.isSimple() || T.getSimple().SimpleTy == VT) &&
  127       assert(VarMapEntry != 0 &&
  203   assert(N->isLeaf() && "Not a leaf?");
  220     assert(N->hasName() && "Unnamed ? leaf");
  308   assert(!N->isLeaf() && "Not an operator?");
  470     assert(Entry == VarMapEntry);
  565     assert(!OpNodes.empty() &&"Complex Pattern must specify what it can match");
  619       assert(NextRecordedOperandNo > 1 &&
  638   assert(!N->getName().empty() && "Operand not named!");
  669   assert(N->isLeaf() && "Must be a leaf");
  843       assert(InstOps.size() > BeforeAddingNumOps && "Didn't add any operands");
  956   assert((!ResultVTs.empty() || TreeHasOutGlue || NodeHasChain) &&
  975   assert(N->getOperator()->isSubClassOf("SDNodeXForm") && "Not SDNodeXForm?");
  983   assert(N->getNumChildren() == 1);
  987   assert(InputOps.size() == 1 && "Unexpected input to SDNodeXForm");
 1050   assert(Ops.size() >= NumSrcResults && "Didn't provide enough results");
utils/TableGen/DAGISelMatcherOpt.cpp
  397       assert(Opcodes.insert(COM->getOpcode().getEnumName()).second &&
  413       assert(M && isa<CheckTypeMatcher>(M) && "Unknown Matcher type");
  445         assert(M.second && "null matcher");
utils/TableGen/DFAEmitter.cpp
  271     assert(T->isSubClassOf("Transition"));
  329   assert(NewStateInit->getNumBits() <= sizeof(uint64_t) * 8 &&
utils/TableGen/DFAPacketizerEmitter.cpp
   76     assert((InsnClass.size() <= DFA_MAX_RESTERMS) &&
  223       assert ((j < DFA_MAX_RESOURCES) &&
  263       assert ((j < DFA_MAX_RESOURCES) &&
  329       assert(FUNameToBitsMap.count(UnitName));
utils/TableGen/ExegesisEmitter.cpp
  184   assert(!Bindings.empty() && "there must be at least one binding");
utils/TableGen/FastISelEmitter.cpp
   72     assert(i < PredsByName.size());
  101       assert((unsigned)OK_Imm+V < 128 &&
  110     unsigned getImmCode() const { assert(isImm()); return Repr-OK_Imm; }
  174       assert(VVT.isSimple() &&
  250       assert(Op->hasConcreteType(0) && "Type infererence not done?");
  310     assert(PR.size() == Operands.size());
  526       assert(InstPatNode->getChild(0)->getNumTypes() == 1);
  647       assert(!OneHadNoPredicate &&
  887   assert(!InstNS.empty() && "Can't determine target-specific namespace!");
utils/TableGen/FixedLenDecoderEmitter.cpp
  299     assert(NumFiltered == 1);
  306     assert(NumFiltered == 1);
  307     assert(FilterChooserMap.size() == 1);
  466     assert(BestIndex != -1 && "BestIndex not set");
  556   assert(StartBit + NumBits - 1 < Owner->BitWidth);
  584   assert((FilteredInstructions.size() + VariableInstructions.size() > 0)
  614     assert(FilterChooserMap.size() == 1);
  653     assert(Delta < (1u << 24));
  682       assert(PrevFilter != 0 && "empty filter set!");
  713       assert(NumToSkip < (1u << 24) && "disassembler decoding table too large!");
  721   assert(TableInfo.FixupStack.size() > 1 && "fixup stack underflow!");
  764     assert (I < E && "incomplete decode table entry!");
  855         assert((p - Buffer) <= (ptrdiff_t)sizeof(Buffer)
 1100   assert(StartBits.size() == Num && EndBits.size() == Num &&
 1477   assert(numInstructions && "Filter created with no instructions");
 1486     assert(numInstructions == 3);
 1589     assert(bitAttr != ATTR_NONE && "Bit without attributes");
 1705   assert(Num && "FilterChooser created with no instructions");
 2493     assert(TableInfo.FixupStack.size() == 1 && "fixup stack phasing error!");
utils/TableGen/GICombinerEmitter.cpp
  173       assert(!MatchingFixupCode &&
utils/TableGen/GlobalISel/CodeExpansions.h
   28     assert(Inserted && "Declared variable twice");
utils/TableGen/GlobalISelEmitter.cpp
  452     assert((!LabelID_.hasValue() || LabelID != ~0u) &&
  568     assert(I != LabelMap.end() && "Use of undeclared label");
  726     assert(!Conditions.empty() &&
  733     assert(!Conditions.empty() &&
  906     assert(R && "Reserving a mutatable insn that isn't available");
 1114     assert(hasValue() && "Can not get a value of a value-less predicate!");
 1500     assert(SymbolicName.empty() && "Operand already has a symbolic name");
 1926     assert(MinAlign > 0);
 2094     assert(SymbolicName.empty());
 2291     assert(!Operands.empty() && "Nested instruction is expected to def a vreg");
 2349     assert(!SymbolicName.empty() && "Cannot copy from an unspecified source");
 2380     assert(PhysReg);
 2416     assert(!SymbolicName.empty() && "Cannot copy from an unspecified source");
 2813       assert(canMutate(Rule, Matched) &&
 3063   assert(Matchers.size() == 1 && "Cannot handle multi-root matchers yet");
 3216   assert(OtherInsnVarID == OtherOM.getInstructionMatcher().getInsnVarID());
 3398   assert(NodeEquivs.empty());
 3402   assert(ComplexPatternEquivs.empty());
 3410  assert(SDNodeXFormEquivs.empty());
 3675     assert(SrcGIOrNull &&
 4168     assert(SrcRCDstRCPair->second && "Couldn't find a matching subclass");
 4260         assert(SrcRCDstRCPair->second && "Couldn't find a matching subclass");
 4408   assert(Leaf && "Expected node?");
 4409   assert(Leaf->isLeaf() && "Expected leaf?");
 4479   assert(SubRegIdxNode && "Expected subregister index node!");
 4503   assert(SuperRegNode && "Expected super register node!");
 4740     assert(Src->getExtTypes().size() == 1 &&
 4745     assert(SrcRCDstRCPair->second && "Couldn't find a matching subclass");
 4756     assert(Src->getExtTypes().size() == 1 &&
 4778     assert(Src->getExtTypes().size() == 1 &&
 4882   assert(CurrentGroup->empty() && "Newly created group isn't empty!");
 4910     assert(CurrentGroup->empty() && "A group wasn't properly re-initialized");
 4921   assert(CurrentGroup->empty() && "The last group wasn't properly processed");
 4939     assert(!Opcode.empty() && "Didn't expect an undefined opcode");
 5199       assert(I != SubtargetFeatures.end() && "Didn't import predicate?");
 5263       assert(!B.isHigherPriorityThan(A) && "Cannot be more important "
 5367   assert(!insnmatchers_empty() &&
 5385   assert(!insnmatchers_empty() &&
 5439   assert(Conditions.empty() && "Already finalized?");
 5534   assert(Condition == nullptr && "Already finalized");
 5535   assert(Values.size() == Matchers.size() && "Broken SwitchMatcher");
 5551   assert(isSupportedPredicateType(P) && "Predicate type is not supported");
 5571   assert(Values.size() == Matchers.size() && "Broken SwitchMatcher");
 5574   assert(Condition != nullptr &&
utils/TableGen/InfoByHwMode.cpp
   36     assert(I.second && "Duplicate entry?");
   47   assert(isValid() && T.isValid() && "Invalid type in assignment");
   58   assert(isValid() && T.isValid() && "Invalid type in comparison");
  115   assert(Rec->isSubClassOf("ValueType") &&
  149     assert(I.second && "Duplicate entry?");
  198     assert(P.second && P.second->isSubClassOf("InstructionEncoding") &&
  201     assert(I.second && "Duplicate entry?");
utils/TableGen/InfoByHwMode.h
   88       assert(hasMode(DefaultMode));
   97     assert(F != Map.end());
  107     assert(isSimple());
  111     assert(hasMode(Mode) || hasDefault());
utils/TableGen/InstrInfoEmitter.cpp
  169       assert(!Op.OperandType.empty() && "Invalid operand type.");
  182         assert(Constraint.isTied());
utils/TableGen/IntrinsicEmitter.cpp
  272     assert(Number < ArgCodes.size() && "Invalid matching number!");
  325     assert(NextArgCode < ArgCodes.size() && ArgCodes[NextArgCode] == Tmp &&
  337       assert(AddrSpace < 256 && "Address space exceeds 255");
  404     assert(OriginalIdx >= Mapping.size());
  609     assert(AttrNum < 256 && "Too many unique attributes for table!");
utils/TableGen/PredicateExpander.cpp
   64   assert(Reg->isSubClassOf("Register") && "Expected a register Record!");
  119   assert(!Opcodes.empty() && "Expected at least one opcode to check!");
  158   assert(!Sequence.empty() && "Found an invalid empty predicate set!");
utils/TableGen/PseudoLoweringEmitter.cpp
   91       assert(BaseIdx == 0 && "Named subargument in pseudo expansion?!");
  127   assert(Dag && "Missing result instruction in pseudo expansion!");
  276   assert(ExpansionClass && "PseudoInstExpansion class definition missing!");
  277   assert(InstructionClass && "Instruction class definition missing!");
utils/TableGen/RISCVCompressInstEmitter.cpp
  133   assert(Reg->isSubClassOf("Register") && "Reg record should be a Register\n");
  134   assert(RegClass->isSubClassOf("RegisterClass") && "RegClass record should be"
  138   assert((R != nullptr) &&
  282   assert(Type1 && ("Arg1 type not found\n"));
  283   assert(Type2 && ("Arg2 type not found\n"));
  376     assert(DestDag->getArgNameStr(DagArgIdx) ==
  411   assert(SourceDag && "Missing 'Input' in compress pattern!");
  424   assert(DestDag && "Missing 'Output' in compress pattern!");
  477     assert(!Ops.empty() && "AssemblerCondString cannot be empty");
  479       assert(!Op.empty() && "Empty operator");
  777   assert(CompressClass && "Compress class definition missing!");
utils/TableGen/RegisterBankEmitter.cpp
   90     assert(RCWithLargestRegsSize && "RC was nullptr?");
utils/TableGen/RegisterInfoEmitter.cpp
  107   assert(Registers.size() <= 0xffff && "Too many regs to fit in tables");
  128   assert(Registers.size() == Registers.back().EnumValue &&
  139     assert(RegisterClasses.size() <= 0xffff &&
  237       assert(RU.Weight < 256 && "RegUnit too heavy");
  456     assert(AliasIter != DwarfRegNums.end() && AliasIter->first == Alias &&
  463     assert(RegIter != DwarfRegNums.end() && RegIter->first == Reg &&
  589   assert(Width <= 32 && "Width too large");
  639   assert(V.empty() && "Clear DiffVec before diffEncode.");
  652   assert(V.empty() && "Clear DiffVec before diffEncode.");
  684     assert((!Entry || Entry == I.second) &&
  948     assert(LaneMaskVec.empty());
  953       assert(!M.all() && "terminator mask should not be part of the list");
 1020     assert(!Roots.empty() && "All regunits must have a root register.");
 1021     assert(Roots.size() <= 2 && "More than two roots not supported yet.");
 1076     assert(isInt<8>(RC.CopyCost) && "Copy cost too large.");
 1279         assert(RC.EnumValue == EV++ && "Unexpected order of register classes");
 1539     assert(Regs && "Cannot expand CalleeSavedRegs instance");
utils/TableGen/SearchableTableEmitter.cpp
  196   assert(Index.Fields.size() == 1);
utils/TableGen/SequenceToOffsetTable.h
   68     assert(Entries == 0 && "Cannot call add() after layout()");
   86     assert((empty() || Entries) && "Call layout() before size()");
   92     assert(Entries == 0 && "Can only call layout() once");
  104     assert(Entries && "Call layout() before get()");
  106     assert(I != Seqs.end() && isSuffix(Seq, I->first) &&
  116     assert((empty() || Entries) && "Call layout() before emit()");
utils/TableGen/SubtargetEmitter.cpp
  451     assert(ProcModel.ItinDefList.size() == ItinList.size() && "bad Itins");
  570     assert(ProcItinListsIter != ProcItinLists.end() && "bad iterator");
  938   assert(PRVec.size() == Cycles.size() && "failed precondition");
 1021     assert(!SC.ProcIndices.empty() && "expect at least one procidx");
 1129           assert(WPREntry.ProcResourceIdx && "Bad ProcResourceIdx");
 1311     assert(SchedModels.getSchedClass(0).Name == "NoInstrModel"
 1666   assert(CGH.getNumModeIds() > 0);
utils/TableGen/SubtargetFeatureInfo.cpp
  103     assert(!CondStr.empty() && "true predicate should have been filtered");
utils/TableGen/TableGen.cpp
  221       assert(Elts && "Couldn't expand Set instance");
utils/TableGen/Types.cpp
   23   assert((MaxSize == 32 || MaxSize == 64) && "Unexpected size");
   24   assert(MaxSize <= 64 && "Unexpected size");
   25   assert(((MaxSize > 32) ? Range <= 0xFFFFFFFFFFFFFFFFULL
   42   assert(MaxIndex <= 64 && "Too many bits");
utils/TableGen/WebAssemblyDisassemblerEmitter.cpp
   42     assert(Opc <= 0xFFFF);
  105         assert(InstIt->second.second);
  115           assert(Op.OperandType != "MCOI::OPERAND_UNKNOWN");
utils/TableGen/X86DisassemblerTables.cpp
  573   assert(upper < IC_max);
  574   assert(lower < IC_max);
  758   assert(sEntryNumber < 65536U &&
utils/TableGen/X86EVEX2VEXTablesEmitter.cpp
  209       assert(AltInstRec && "EVEX2VEXOverride instruction not found!");
utils/TableGen/X86FoldTablesEmitter.cpp
  193   assert(B->getNumBits() <= sizeof(uint64_t) * 8 && "BitInits' too long!");
  304   assert(AltRegInstRec &&
  411         assert(isRegisterOperand(RegOpRec) && isMemoryOperand(MemOpRec));
utils/TableGen/X86RecognizableInstr.cpp
   34   assert(width <= 8 && "Field is too large for uint8_t!");
  358   assert(((encoding >= ENCODING_RM && encoding <= ENCODING_RM_CD64) ||
  374     assert(physicalOperandIndex < numPhysicalOperands);
  410   assert(numOperands <= X86_MAX_OPERANDS && "X86_MAX_OPERANDS is not large enough");
  474     assert(numPhysicalOperands <= 1 &&
  485     assert(numPhysicalOperands >= 1 && numPhysicalOperands <= 2 &&
  492     assert(numPhysicalOperands == 2 &&
  503     assert(numPhysicalOperands >= 2 + additionalOperands &&
  524     assert(numPhysicalOperands >= 2 + additionalOperands &&
  548     assert(numPhysicalOperands >= 2 + additionalOperands &&
  567     assert(numPhysicalOperands == 3 &&
  574     assert(numPhysicalOperands >= 4 && numPhysicalOperands <= 5 &&
  583     assert(numPhysicalOperands == 3 &&
  595     assert(numPhysicalOperands >= 2 + additionalOperands &&
  614     assert(numPhysicalOperands == 3 &&
  621     assert(numPhysicalOperands >= 4 && numPhysicalOperands <= 5 &&
  630     assert(numPhysicalOperands == 3 &&
  637     assert(numPhysicalOperands == 2 &&
  654     assert(numPhysicalOperands >= 0 + additionalOperands &&
  668     assert(numPhysicalOperands == 2 &&
  684     assert(numPhysicalOperands >= 1 + additionalOperands &&
  698     assert(numPhysicalOperands == 2 &&
  798   assert(opcodeType && "Opcode type not set");
  799   assert(filter && "Filter not set");
  805     assert(((opcodeToSet % Count) == 0) && "ADDREG_FRM opcode not aligned");
utils/benchmark/include/benchmark/benchmark.h
  578     assert(range_.size() > pos);
  662   assert(n > 0);
  664   assert(is_batch || n == 1);
  709     assert(cached_ > 0);
 1361     assert(out);
 1368     assert(err);
utils/unittest/googletest/include/gtest/internal/gtest-linked_ptr.h
  114       assert(p->next_ != this &&
  132       assert(p->next_ != next_ &&
  158     assert(&ptr != this);
utils/unittest/googletest/include/gtest/internal/gtest-param-util-generated.h
 3200       assert(!AtEnd());