Merge pull request #2003 from bbbradsmith/large_align_false_positive_fix

supress spurious "large alignment" warnings
This commit is contained in:
Bob Andrews
2023-02-24 16:32:41 +01:00
committed by GitHub
3 changed files with 10 additions and 10 deletions

View File

@@ -230,7 +230,7 @@ Section* ReadSection (FILE* F, ObjData* O)
"%lu. Last module requiring alignment was '%s'.",
GetString (Name), Alignment, MAX_ALIGNMENT,
GetObjFileName (O));
} else if (Alignment >= LARGE_ALIGNMENT && !LargeAlignment) {
} else if (Alignment >= LARGE_ALIGNMENT && Alignment > S->Alignment && Alignment > Sec->Alignment && !LargeAlignment) {
Warning ("Combined alignment for segment '%s' is suspiciously "
"large (%lu). Last module requiring alignment was '%s'.",
GetString (Name), Alignment, GetObjFileName (O));