similar to: lld write wrong symbol value in .data section if enable -pie

Displaying 20 results from an estimated 400 matches similar to: "lld write wrong symbol value in .data section if enable -pie"

2019 Jan 29
3
lld write wrong symbol value in .data section if enable -pie
Hi Rui, > but why don't you use lld-link (lld for Windows target) instead of ld.lld (lld for Unix target) to create UEFI applications? I need support both PE/COFF and ELF format tools. I’m also working on the lld-link enabling (clang-cl + lld-link) in both Linux and windows. The ld.lld enabling (clang + ld.lld) is for ELF format native users. E.g.
2019 Jan 29
2
lld write wrong symbol value in .data section if enable -pie
Hi Rui, A quick question: Does lld-link only work with clang-cl with windows-msvc option? Can lld-link work with clang with linux-gnu option? Thanks Steven Shi Intel\SSG\FID\Firmware Infrastructure From: Shi, Steven Sent: Tuesday, January 29, 2019 1:32 PM To: 'Rui Ueyama' <ruiu at google.com> Cc: llvm-dev at lists.llvm.org Subject: RE: lld write wrong symbol value in .data
2013 Nov 17
6
Re: [edk2] [PATCH RFC 0/7] OvmfPkg: make OVMF fully working with Xen
On Sat, Nov 16, 2013 at 3:31 AM, Jordan Justen <jljusten@gmail.com> wrote: > When I try to boot this on qemu or kvm, it asserts because the video > framebuffer address is NULL. > That''s expected because of the hack. ;-) > On Fri, Nov 15, 2013 at 7:58 AM, Wei Liu <wei.liu2@citrix.com> wrote: >> This is a quick hack I pulled together last night to make OVMF
2013 Oct 31
7
[PATCH] tools: ovmf debug build only if tools debug is enabled
Signed-off-by: Fabio Fantoni <fabio.fantoni@m2r.biz> --- tools/firmware/ovmf-makefile | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/tools/firmware/ovmf-makefile b/tools/firmware/ovmf-makefile index 073ed44..efb4fb1 100644 --- a/tools/firmware/ovmf-makefile +++ b/tools/firmware/ovmf-makefile @@ -1,3 +1,6 @@ +XEN_ROOT = $(CURDIR)/../../.. +include
2019 Jul 16
2
lld-link crash when build openssl with LTO
lld should not crash in this case (so that's a bug that needs fixing), but setting it aside, did you try adding `-fno-builtin` to clang so that clang doesn't handle `memcpy` as a built-in function? On Tue, Jul 16, 2019 at 8:46 PM Shi, Steven <steven.shi at intel.com> wrote: > Hi Rui, > > For the test case in my previous email, if I change the `memcpy` to > `foobar` in
2019 Jul 16
2
lld-link crash when build openssl with LTO
Yeah, it crashes indeed. I can reproduce the problem locally. Let me see what is going on. On Tue, Jul 16, 2019 at 9:00 PM Shi, Steven <steven.shi at intel.com> wrote: > In my previous test case, after add the `-fno-builtin` to clang then > build, the lld-link still has same crash as below: > > > > $ make > >
2019 Jul 16
2
lld-link crash when build openssl with LTO
Hi Steven, One thing I noticed is that you are defining `memcpy`, which clang has an intrinsic with the same name. Can you try renaming it to a random name, like `foobar`, to see if the problem still exists? On Tue, Jul 16, 2019 at 10:10 AM Shi, Steven <steven.shi at intel.com> wrote: > I’ve submitted a BZ for this issue as below: > > > > Bug 42626 - lld-link crash when
2019 Jul 15
2
lld-link crash when build openssl with LTO
Hi Rui, We met a lld-link crash problem when build 32bits openssl1.0 with LTO in uefi firmware. We narrow down and figure out a simple test case to reproduce this problem as blow. Please advise. Thank you! $ cat main.c void TlsDriverEntryPoint () { unsigned char *ret = 0; const unsigned char cryptopro_ext[17] = {0x00,0x00,0x00,0x00,
2019 Feb 28
4
lld-link crash when linking intrinsics lib
+Peter Collingbourne <pcc at chromium.org> LTO is used in this test case, and one source file defines its own `memset` function while the other file uses llvm.memset. Looks like LTO is confused by the user-defined memset. Could you take a look? Steven, Do you need to use LTO? I thought that LTO is a workaround to not produce an object file that cannot be handled by your ELF-to-COFF
2019 Jul 16
3
lld-link crash when build openssl with LTO
Usage of the builtin appears independent of LTO, see below. With any of -fno-builtin, -fno-builtin-memcpy, and -ffreestanding, which are all typically used to prevent usage of memcpy calls, we still always get a memcpy builtin in TlsDriverEntryPoint(). I see this even without -flto (e.g. try with just -emit-llvm). I guess it is because this memcpy is not coming from the original source, but
2019 Feb 27
2
lld-link crash when linking intrinsics lib
Hello Rui, I met couples of lld-link crash when enable the clang-cl + lld-link build toolchain for Uefi firmware. Below is a simplified example (main.c and intrinsics.c). Uefi firmware is self-contained and doesn't depend on the compiler intrinsics implementation, so we have our own intrinsics lib. It is weird that if I don't use the llvm-lib but directly "lld-link /NODEFAULTLIB
2016 May 30
2
[cfe-dev] How to debug if LTO generate wrong code?
Hi Steven, > On May 29, 2016, at 11:28 PM, Shi, Steven <steven.shi at intel.com> wrote: > > Hi Mehdi, > Should I apply your attached patch on my llvm3.8 source firstly? Or should I use the latest llvm SVN trunk instead? I wrote it on trunk, but I expect it to be fairly easy to port on 3.8. This is really just quickly plumbing an option on the TargetMachine creation. --
2016 May 30
0
[cfe-dev] How to debug if LTO generate wrong code?
Hi Mehdi, The llvm3.8 gold-plugin.cpp is very different from the latest one on trunk. Your patch has compiling failure on llvm3.8 as below. I will try it on latest trunk later. Thank you help anyway! Building CXX object tools/gold/CMakeFiles/LLVMgold.dir/gold-plugin.cpp.o cd /home/jshi19/llvm38releasebuild/tools/gold && /home/jshi19/clang38/bin/clang++ -DGTEST_HAS_RTTI=0
2019 Aug 03
2
lld-link /ALIGN option doesn't work for the "execute in place (XIP)"
Hi Rui, We meet a problem when enable the execute in place (XIP, https://en.wikipedia.org/wiki/Execute_in_place) for uefi firmware with lld-link. We need to set the COFF executable file SectionAlignment through the lld-link /ALIGN option, but we find the SectionAlignment is hardcoded to 4096 which cause the /ALIGN option doesn't work at all. Below is the hardcode in lld: lld\COFF\Writer.h
2020 Jan 09
3
LLD PDB Lines zero number issue
Hello Rui, We meet an LLD PDB issue that if we link assembly code with C code and set >= -O1 level optimization in LTO, the executable's PDB will contain wrong zero Lines for the assembly code in DEBUG_S_LINES subsection, and then our COFF source debuggers will fail to do the source-level debug on the executable. This issue is same in both Linux and Windows, and I figure out a simple case
2020 Jan 09
2
LLD PDB Lines zero number issue
On Thu, 9 Jan 2020, David Blaikie via llvm-dev wrote: > +rnk who works on COFF debugging things. > >  My understanding is that this has nothing to do with the linker - but is a > function of LLVM optimizations creating line zero debug locations. I believe > rnk & folks have disabled line zero emission for CodeView debug info in some > manner - perhaps that needs a flag? or
2020 Jan 12
2
LLD PDB Lines zero number issue
I checked the LLVM master code and find that the “-use-unknown-locations” option and its related logic is only supported for Dwarf debug info as below. These codes are missing in the Codeview side. It looks the “-use-unknown-locations” option logic is not complex, could we port the code logic into llvm\lib\CodeGen\AsmPrinter\CodeViewDebug.cpp as well? I’ve submitted a BZ for this requirment:
2020 Jan 14
2
LLD PDB Lines zero number issue
OK, maybe I was wrong and the “-use-unknown-locations” option is not the issue root cause. I'm not familiar with the LLVM codebase and I appreciate any suggestion on how to debug this issue. I'd like to know is it a clang issue or a lld issue? Is there a tool which can dump the obj file debug location info? Let me simplify the previous test case to reproduce this issue. All what you need
2014 May 27
2
[LLVMdev] Assertion fails resolving R_X86_64_PC32 relocation
I would think that the R_X86_64_PC32 relocation type should never be generated with large code model since large code model, by definition, makes no assumptions about the size or address of sections. The use of win32-elf might throw a wrinkle into this, since that is a code path that probably isn't exercised much outside of MCJIT use. That said, when this assertion fails it is usually
2017 Mar 23
4
[LLD] Can't create dynamic relocation R_X86_64_64 against local symbol in readonly segment
Hi, the attached example works with bfd-ld and with gold, but not with lld: $ cat rodatareloc.s ... .align 16 leaq .JTab(%rip), %r10 jmp *(%r10, %rdx, 8) ... .section .rodata .JTab: .quad .L00, .L01, .L02, .L03, .L04, .L05, .L06, .L07 .quad .L08, .L09, .L10, .L11, .L12, .L13, .L14, .L15, .L16 $ gcc -o rodatareloc.s.o -c rodatareloc.s $ lld -o rodatareloc.so -shared