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

References

lib/IR/Verifier.cpp
  565   Assert(!GV.isDeclaration() || GV.hasValidDeclarationLinkage(),
  565   Assert(!GV.isDeclaration() || GV.hasValidDeclarationLinkage(),
  566          "Global is external, but doesn't have external or weak linkage!", &GV);
  568   Assert(GV.getAlignment() <= Value::MaximumAlignment,
  569          "huge alignment values are unsupported", &GV);
  570   Assert(!GV.hasAppendingLinkage() || isa<GlobalVariable>(GV),
  570   Assert(!GV.hasAppendingLinkage() || isa<GlobalVariable>(GV),
  571          "Only global variables can have appending linkage!", &GV);
  573   if (GV.hasAppendingLinkage()) {
  574     const GlobalVariable *GVar = dyn_cast<GlobalVariable>(&GV);
  579   if (GV.isDeclarationForLinker())
  580     Assert(!GV.hasComdat(), "Declaration may not be in a Comdat!", &GV);
  580     Assert(!GV.hasComdat(), "Declaration may not be in a Comdat!", &GV);
  582   if (GV.hasDLLImportStorageClass()) {
  583     Assert(!GV.isDSOLocal(),
  584            "GlobalValue with DLLImport Storage is dso_local!", &GV);
  586     Assert((GV.isDeclaration() && GV.hasExternalLinkage()) ||
  586     Assert((GV.isDeclaration() && GV.hasExternalLinkage()) ||
  587                GV.hasAvailableExternallyLinkage(),
  588            "Global is marked as dllimport, but not external", &GV);
  591   if (GV.hasLocalLinkage())
  592     Assert(GV.isDSOLocal(),
  594            &GV);
  596   if (!GV.hasDefaultVisibility() && !GV.hasExternalWeakLinkage())
  596   if (!GV.hasDefaultVisibility() && !GV.hasExternalWeakLinkage())
  597     Assert(GV.isDSOLocal(),
  598            "GlobalValue with non default visibility must be dso_local!", &GV);
  600   forEachUser(&GV, GlobalValueVisited, [&](const Value *V) -> bool {
  603         CheckFailed("Global is referenced by parentless instruction!", &GV, &M,
  606         CheckFailed("Global is referenced in a different module!", &GV, &M, I,
  612         CheckFailed("Global is used by function in a different module", &GV, &M,