summaryrefslogtreecommitdiffstats
path: root/llvm/lib/ObjectYAML/ELFEmitter.cpp
diff options
context:
space:
mode:
authorGeorge Rimar <grimar@accesssoftek.com>2019-10-03 15:02:18 +0000
committerGeorge Rimar <grimar@accesssoftek.com>2019-10-03 15:02:18 +0000
commitc18585e32eb0f69849ddb01f7aeb2cf7836b6a5c (patch)
tree12c67795e9d87f474efffe5fa2188b9cda07daa8 /llvm/lib/ObjectYAML/ELFEmitter.cpp
parent069cb6282db8bd378f411bb19e65db30a47cd879 (diff)
downloadbcm5719-llvm-c18585e32eb0f69849ddb01f7aeb2cf7836b6a5c.tar.gz
bcm5719-llvm-c18585e32eb0f69849ddb01f7aeb2cf7836b6a5c.zip
[yaml2obj] - Add a Size tag support for SHT_LLVM_ADDRSIG sections.
It allows using "Size" with or without "Content" in YAML descriptions of SHT_LLVM_ADDRSIG sections. Differential revision: https://reviews.llvm.org/D68334 llvm-svn: 373610
Diffstat (limited to 'llvm/lib/ObjectYAML/ELFEmitter.cpp')
-rw-r--r--llvm/lib/ObjectYAML/ELFEmitter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/ObjectYAML/ELFEmitter.cpp b/llvm/lib/ObjectYAML/ELFEmitter.cpp
index 3f3b27c5bfa..f9c31f335f1 100644
--- a/llvm/lib/ObjectYAML/ELFEmitter.cpp
+++ b/llvm/lib/ObjectYAML/ELFEmitter.cpp
@@ -1007,8 +1007,8 @@ void ELFState<ELFT>::writeSectionContent(Elf_Shdr &SHeader,
if (Section.Link.empty() && SN2I.lookup(".symtab", Link))
SHeader.sh_link = Link;
- if (Section.Content) {
- SHeader.sh_size = writeContent(OS, Section.Content, None);
+ if (Section.Content || Section.Size) {
+ SHeader.sh_size = writeContent(OS, Section.Content, Section.Size);
return;
}
OpenPOWER on IntegriCloud