Make this assertion more self-explanatory.
authorBrian Gaeke <gaeke@uiuc.edu>
Thu, 15 Jan 2004 18:15:58 +0000 (18:15 +0000)
committerBrian Gaeke <gaeke@uiuc.edu>
Thu, 15 Jan 2004 18:15:58 +0000 (18:15 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10879 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/TargetInstrInfo.cpp

index 0f9015f8a60d2120d559ac6444bb6deeb5a6f755..a3131bb319f556766df98d3dd8a16c87eaca655d 100644 (file)
@@ -23,13 +23,13 @@ namespace llvm {
 // 
 const TargetInstrDescriptor* TargetInstrDescriptors = 0;
 
-
 TargetInstrInfo::TargetInstrInfo(const TargetInstrDescriptor* Desc,
                                 unsigned DescSize,
                                 unsigned NumRealOpCodes)
   : desc(Desc), descSize(DescSize), numRealOpCodes(NumRealOpCodes) {
   // FIXME: TargetInstrDescriptors should not be global
-  assert(TargetInstrDescriptors == NULL && desc != NULL);
+  assert(TargetInstrDescriptors == NULL && desc != NULL
+         && "TargetMachine data structure corrupt; maybe you tried to create another TargetMachine? (only one may exist in a program)");
   TargetInstrDescriptors = desc;       // initialize global variable
 }