Shankar Easwaran
2013-Sep-23 17:02 UTC
[LLVMdev] [lld]Native reader/writer is not called, treated as Dead Code!
Hi Nick, When changes were brought from lld core to the Universal Driver, calls to NativeReader/NativeWriter code was stripped away. Was this by accident ? Thanks Shankar Easwaran -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by the Linux Foundation
Nick Kledzik
2013-Sep-23 17:20 UTC
[LLVMdev] [lld]Native reader/writer is not called, treated as Dead Code!
On Sep 23, 2013, at 10:02 AM, Shankar Easwaran <shankare at codeaurora.org> wrote:> Hi Nick, > > When changes were brought from lld core to the Universal Driver, calls to NativeReader/NativeWriter code was stripped away.This needs to be fixed. Originally, ever run of the linker would have a step were it wrote to native and read that back in. That makes sense for test cases, but not for a production linker. We could add a flag to LinkingContext which triggers Driver::link() to side step through native format, then let the drivers decide whether to set the flag or not. -Nick
Shankar Easwaran
2013-Sep-23 17:46 UTC
[LLVMdev] [lld]Native reader/writer is not called, treated as Dead Code!
On 9/23/2013 12:20 PM, Nick Kledzik wrote:> > On Sep 23, 2013, at 10:02 AM, Shankar Easwaran <shankare at codeaurora.org> wrote: >> Hi Nick, >> >> When changes were brought from lld core to the Universal Driver, calls to NativeReader/NativeWriter code was stripped away. > This needs to be fixed. Originally, ever run of the linker would have a step were it wrote to native and read that back in. That makes sense for test cases, but not for a production linker.We could do this always in DEBUG mode, so that assumptions in the code are still valid, and no hidden data structures are being passed in to the Writer.> > We could add a flag to LinkingContext which triggers Driver::link() to side step through native format, then let the drivers decide whether to set the flag or not.I added --output-filetype to the ELF driver, that sets the LinkingContext to the appropriate output file that needs to be emitted. Thanks Shankar Easwaran -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by the Linux Foundation