[LLVMbugs] [Bug 15225] New: MIPS does not implement __builtin_eh_return_data_regno correctly

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sun Feb 10 11:04:54 PST 2013


            Bug ID: 15225
           Summary: MIPS does not implement __builtin_eh_return_data_regno
           Product: clang
           Version: 3.2
          Hardware: Other
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: awg at embtoolkit.org
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 9995
  --> http://llvm.org/bugs/attachment.cgi?id=9995&action=edit
Proposed fix

Current MIPS TargetInfo (MipsTargetInfoBase) does not implement
getEHDataRegisterNumber() ie __builtin_eh_return_data_regno().
This makes c++ exception handling not working with libcxx/libcxxrt as
libcxxrt __gxx_personality_v0() function uses this builtin.

The simple attached patch makes the following test code works without
aborting, with libcxx/libcxxrt used as c++ standard library.

#include <stdio.h>
#include <exception>

int main(int argc, char **argv)
    try {
        throw 20;
    } catch (int e) {
        printf("Exception Nr %d occurred\n", e);

    return 0;

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/20130210/2a746922/attachment.html>

More information about the llvm-bugs mailing list