C++ exception not working

Home Forums Forum C++ exception not working

This topic contains 6 replies, has 2 voices, and was last updated by  uroni 10 months ago.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
  • #27958 Reply



    with ellcc 0.1.27. Test program:

    #include <stdexcept>
    #include <iostream>
    int main()
                    throw std::runtime_error("test");
            catch(std::exception& e)
                    std::cout << "Caught exception: " << e.what() << std::endl;
                    return 0;
            return 1;

    Exception is not caught. Could not see anything obivous missing.
    ecc++ -v -Wl,–verbose shows that it sets -fexceptions, -fcxx-exceptions and it is linked with libunwind.


    #27983 Reply


    Hi uroni,
    What processor are you building for?

    #28247 Reply



    didn’t work with the targets armv6-linux-engeabihf, x86_64-linux-eng and i386-linux-eng.

    LLVM doesn’t seem to use exceptions and nghttp2 only sparingly, so you might not have noticed.

    #76516 Reply

    Alexej Harm


    is this problem being worked on? C++ without exceptions is quite useless in a lot of scenarios.

    Is there a bugzilla or some other bug/issue management for ELLCC?

    If the problem won’t be addressed during the next 1-2 months, I could take a look at it and possibly help.

    Best regards,
    Alexej Harm

    #76775 Reply

    Alexej Harm

    This problem still persists in ELLCC 0.1.30.

    #77591 Reply

    Alexej Harm

    This problem still persists in ELLCC 0.1.33.

    #77601 Reply


    @Alexej This is the bug Richard added with regard to this issue: http://ellcc.org/bugzilla/show_bug.cgi?id=78

    It’s probably not easy to fix because libunwind in llvm only works properly with Apple DWARF binaries, but documentation is a bit sparse.

Viewing 7 posts - 1 through 7 (of 7 total)
Reply To: C++ exception not working
Your information: