diff options
author | Martin Storsjo <martin@martin.st> | 2018-11-29 20:53:57 +0000 |
---|---|---|
committer | Martin Storsjo <martin@martin.st> | 2018-11-29 20:53:57 +0000 |
commit | c1410635bfa8979862606056b5fc1eb5db4840e5 (patch) | |
tree | ea9918a2c256849eb51061de9a3558e12aa0a341 /llvm/tools/obj2yaml/coff2yaml.cpp | |
parent | 2b40470c6181c6b513146424fb963076114bbdd1 (diff) | |
download | bcm5719-llvm-c1410635bfa8979862606056b5fc1eb5db4840e5.tar.gz bcm5719-llvm-c1410635bfa8979862606056b5fc1eb5db4840e5.zip |
[obj2yaml] [COFF] Write RVA instead of VA for sections, fix roundtripping executables
yaml2obj writes the yaml value as is to the output file.
Differential Revision: https://reviews.llvm.org/D54965
llvm-svn: 347916
Diffstat (limited to 'llvm/tools/obj2yaml/coff2yaml.cpp')
-rw-r--r-- | llvm/tools/obj2yaml/coff2yaml.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/tools/obj2yaml/coff2yaml.cpp b/llvm/tools/obj2yaml/coff2yaml.cpp index 57fb1d04075..6835dcf71ff 100644 --- a/llvm/tools/obj2yaml/coff2yaml.cpp +++ b/llvm/tools/obj2yaml/coff2yaml.cpp @@ -147,7 +147,7 @@ void COFFDumper::dumpSections(unsigned NumSections) { COFFYAML::Section NewYAMLSection; ObjSection.getName(NewYAMLSection.Name); NewYAMLSection.Header.Characteristics = COFFSection->Characteristics; - NewYAMLSection.Header.VirtualAddress = ObjSection.getAddress(); + NewYAMLSection.Header.VirtualAddress = COFFSection->VirtualAddress; NewYAMLSection.Header.VirtualSize = COFFSection->VirtualSize; NewYAMLSection.Header.NumberOfLineNumbers = COFFSection->NumberOfLinenumbers; |