bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gold/22838] New: Incorrect linking for try-catch statement for targ


From: Ilija.Pavlovic at mips dot com
Subject: [Bug gold/22838] New: Incorrect linking for try-catch statement for target MIPS32 R2 little endian.
Date: Mon, 12 Feb 2018 14:36:20 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=22838

            Bug ID: 22838
           Summary: Incorrect linking for try-catch statement for target
                    MIPS32 R2 little endian.
           Product: binutils
           Version: 2.28
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: gold
          Assignee: ccoutant at gmail dot com
          Reporter: Ilija.Pavlovic at mips dot com
                CC: ian at airs dot com
  Target Milestone: ---

Created attachment 10812
  --> https://sourceware.org/bugzilla/attachment.cgi?id=10812&action=edit
Files and the script for reproducing the problem.

Consider following example:

int main(int argc, char* argv[]) {
  try {
    throw 20;
  } catch (...) {
    return 123;
  }
  return 0;
}

The catch block should capture any kind of exceptions.

If this example is linked with gold linker for target MIPS32 R2 little endian,
execution of the example will result with error message "Segmentation fault".

If the same example is linked without -pie flag (Create a position independent
executable), the example will be linked correctly and executed as it is
expected.

This is tested with the Clang version 6.0.0 (trunk 321529) and the gold linker
version 2.28 (GNU gold (GNU Binutils 2.28) 1.14).

All files, parameters and commands needed for reproducing the problem are in
the attached file.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]