diff options
author | Anton Korobeynikov <asl@math.spbu.ru> | 2010-07-06 15:24:56 +0000 |
---|---|---|
committer | Anton Korobeynikov <asl@math.spbu.ru> | 2010-07-06 15:24:56 +0000 |
commit | e4152304770369471414c8b9b5beb5df741e2254 (patch) | |
tree | 2aca460bd91bb19e871f98a4fe291fd5b232d910 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp | |
parent | 1e33b18e28452a28c8d7107bb261c017a0609a84 (diff) | |
download | llvm-e4152304770369471414c8b9b5beb5df741e2254.zip llvm-e4152304770369471414c8b9b5beb5df741e2254.tar.gz llvm-e4152304770369471414c8b9b5beb5df741e2254.tar.bz2 |
Fix a major regression on COFF targets introduced by r103267: 'discardable' section means that it is used only during the program load and can be discarded afterwards.
This way *only* debug sections can be discarded, but not the opposite. Seems like the copy-and-pasto from ELF code, since there it contains the reverse flag ('alloc').
llvm-svn: 107658
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
-rw-r--r-- | llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp b/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp index 350d50c..a80cfc4 100644 --- a/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp +++ b/llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp @@ -936,7 +936,7 @@ static unsigned getCOFFSectionFlags(SectionKind K) { unsigned Flags = 0; - if (!K.isMetadata()) + if (K.isMetadata()) Flags |= COFF::IMAGE_SCN_MEM_DISCARDABLE; else if (K.isText()) |