[llvm-bugs] [Bug 36598] New: LLD crashes if ARM.exidx input section is empty

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Mar 5 04:16:46 PST 2018


https://bugs.llvm.org/show_bug.cgi?id=36598

            Bug ID: 36598
           Summary: LLD crashes if ARM.exidx input section is empty
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: ELF
          Assignee: unassignedbugs at nondot.org
          Reporter: konstantin.schwarz at hightec-rt.com
                CC: llvm-bugs at lists.llvm.org

ld.lld crashes if it is invoked with the following input

// test.s
.text
.globl _start
_start:

// linker.script
SECTIONS
{
  .foo:
  {
    exidx_start = .;
    *(.ARM.exidx*)
    exidx_end = .;
  }
}

The test.s file is assembled in the following way: 
llvm-mc -filetype=obj -triple=arm-arm-none-eabi test.s -o test.o

The program does not contain an ARM.exidx section, hence the InputSection
pointer 'First' in OutputSection::finalize is a nullptr and dereferenced later
on.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180305/f27e1398/attachment-0001.html>


More information about the llvm-bugs mailing list