[llvm-bugs] [Bug 37524] New: the relocation type is changed to R_X86_64_32 for .gcc_except_table with -mcmodel=kernel

via llvm-bugs llvm-bugs at lists.llvm.org
Fri May 18 11:50:08 PDT 2018


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

            Bug ID: 37524
           Summary: the relocation type is changed to R_X86_64_32 for
                    .gcc_except_table with -mcmodel=kernel
           Product: clang
           Version: 6.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Frontend
          Assignee: unassignedclangbugs at nondot.org
          Reporter: pangbw at gmail.com
                CC: llvm-bugs at lists.llvm.org

Use clang 6.0.0.1 to compile this simple code, the relocation for
.gcc_except_table is R_X86_64_32:
$ cat x.cpp

int main () {
    try
      {
        throw 20;
      }
    catch (int e)
      {

      }
    return 0;
}

$ clang --target=x86_64 -m64 -mcmodel=kernel -c x.cpp

$ $ objdump -Dr x.o|grep .gcc_except_table
Disassembly of section .gcc_except_table:
                        31: R_X86_64_32 .gcc_except_table


But if use clang 5.0.0.3 to compile the same code, the relocaction type is
R_X86_64_64 for .gcc_except_table.

Is the difference between 5.0.0.3 and 6.0.0.1 expected? or a problem we should
fix?

-- 
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/20180518/7714d736/attachment.html>


More information about the llvm-bugs mailing list