* include/parallel/settings.h (get): Mark const. * libsupc++/unwind-cxx.h (__cxa_call_terminate): Mark throw (). * libsupc++/eh_call.cc (__cxa_call_terminate): Mark throw (). * config/io/basic_file_stdio.cc (sys_open, is_open, fd, seekoff): Mark throw (). * config/io/basic_file_stdio.h (__basic_file, sys_open): Mark throw (). (is_open, fd): Mark pure and throw (). (seekoff): Mark throw (). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@147077 138bc75d-0d04-0410-961f-82ee72b054a4
* eh_type.cc (__cxa_current_exception_type) Mark throw(). * unwind-cxx.h (__cxa_get_globals, __cxa_get_globals_fast): Mark const. (__cxa_get_exception_ptr): Mark pure. (__cxa_bad_cast, __cxa_bad_typeid): Mark noreturn (__terminate): Makr throw (). * exception (terminate): Mark throw(). (uncaught_exception): Mark pure. * eh_ptr.cc (_M_safe_bool_dummy): Mark throw(). * guard.cc (__cxa_guard_abort, __cxa_guard_release): Mark throw(). * eh_terminate.cc (__terminate, terminate): Mark throw(). * vec.cc (__cxa_vec_cleanup): Mark throw(). * cxxabi.h (__cxa_vec_cleanup, __cxa_guard_release, __cxa_guard_abort): Mark throw (). (__cxa_pure_virtual): Mark noreturn. (__cxa_current_exception_type): Mark throw and pure. * exception_ptr.h (operator ==, !=, _M_get, !, ==, __cxa_exception_type): Mark pure. (_M_safe_bool_dummy): Mark pure and const. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@146331 138bc75d-0d04-0410-961f-82ee72b054a4
Licensing changes to GPLv3 resp. GPLv3 with GCC Runtime Exception. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@145841 138bc75d-0d04-0410-961f-82ee72b054a4
PR c++/34691 * name-lookup.c (pushdecl_maybe_friend): Diagnose mismatched extern C declarations. * libsupc++/unwind-cxx.h: Correct __cxa_call_terminate prototype. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@145386 138bc75d-0d04-0410-961f-82ee72b054a4
PR libstdc++/38732 * libsupc++/unwind-cxx.h (__cxxabiv1::__cxa_exception): Remove referenceCount field again. (__cxxabiv1::__cxa_refcounted_exception): New struct. (__cxxabiv1::__get_refcounted_exception_header_from_obj, __cxxabiv1::__get_refcounted_exception_header_from_ue): New static inline functions. * libsupc++/eh_alloc.cc (__cxxabiv1::__cxa_allocate_exception, __cxxabiv1::__cxa_free_exception): Use __cxa_refcounted_exception instead of __cxa_exception. * libsupc++/eh_throw.cc (__gxx_exception_cleanup, __cxxabiv1::__cxa_throw): Likewise. * libsupc++/eh_ptr.cc (std::rethrow_exception, std::__exception_ptr::exception_ptr::_M_addref, std::__exception_ptr::exception_ptr::_M_release, __gxx_dependent_exception_cleanup): Likewise. * testsuite/18_support/exception/38732.cc: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@143170 138bc75d-0d04-0410-961f-82ee72b054a4
2008-08-23 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/lib/libstdc++.exp (check_v3_target_atomic_builtins): Add. * testsuite/lib/dg-options.exp (dg-require-atomic-builtins): Likewise. * testsuite/18_support/exception_ptr/current_exception.cc: Use it. * testsuite/18_support/exception_ptr/rethrow_exception.cc: Likewise. * testsuite/18_support/exception_ptr/lifespan.cc: Likewise. 2008-08-23 Sebastian Redl <sebastian.redl@getdesigned.at> Add (again) exception propagation support as per N2179. Feature is available only when _GLIBCXX_ATOMIC_BUILTINS_4 is defined. * libsupc++/exception_ptr.h (exception_ptr, current_exception, copy_exception, rethrow_exception): New file, implement exception propagation. * libsupc++/eh_ptr.cc (exception_ptr, current_exception, rethrow_exception, __gxx_dependent_exception_cleanup): Likewise. * libsupc++/unwind-cxx.h (__cxa_exception): Add reference count. (__cxa_dependent_exception, __cxa_allocate_dependent_exception, __cxa_free_dependent_exception, __get_dependent_exception_from_ue, __GXX_INIT_DEPENDENT_EXCEPTION_CLASS, __is_dependent_exception, __gxx_dependent_exception_class, __get_object_from_ue, __get_object_from_ambiguous_exception): Add. (__GXX_INIT_EXCEPTION_CLASS, __gxx_exception_class): Rename. (__is_gxx_exception_class): Handle dependent exceptions. * libsupc++/eh_arm.cc (__cxa_type_match): Likewise. * libsupc++/eh_call.cc (__cxa_call_unexpected): Likewise. * libsupc++/eh_personality.cc (__gxx_personality_*): Likewise. * libsupc++/eh_type.cc (__cxa_current_exception_type): Likewise. * libsupc++/eh_alloc.cc (__cxa_allocate_dependent_exception, __cxa_free_dependent_exception): Add. * libsupc++/eh_throw.cc (__gxx_exception_cleanup): Handle reference counting. * libsupc++/exception: Conditionally include exception_ptr.h. * libsupc++/Makefile.am: Register new files. * libsupc++/Makefile.in: Regenerate. * config/abi/pre/gnu.ver: Add new symbols. * testsuite/18_support/exception_ptr/current_exception.cc: Test the core functionality of current_exception(). * testsuite/18_support/exception_ptr/rethrow_exception.cc: Test the core functionality of rethrow_exception(). * testsuite/18_support/exception_ptr/lifespan.cc: Test the life span of exception objects during exception propagation. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139509 138bc75d-0d04-0410-961f-82ee72b054a4
2008-08-22 Paolo Carlini <paolo.carlini@oracle.com> Revert again the N2179 patch. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139497 138bc75d-0d04-0410-961f-82ee72b054a4
2008-08-13 Paolo Carlini <paolo.carlini@oracle.com> Re-instate last patch, amended to use __exchange_and_add_dispatch and __atomic_add_dispatch in eh_ptr.cc and eh_throw.cc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139091 138bc75d-0d04-0410-961f-82ee72b054a4
2008-08-13 Paolo Carlini <paolo.carlini@oracle.com> Revert the last patch. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139074 138bc75d-0d04-0410-961f-82ee72b054a4
2008-08-13 Sebastian Redl <sebastian.redl@getdesigned.at> Add exception propagation support as per N2179. * libsupc++/exception_ptr.h (exception_ptr, current_exception, copy_exception, rethrow_exception): New file, implement exception propagation. * libsupc++/eh_ptr.cc (exception_ptr, current_exception, rethrow_exception, __gxx_dependent_exception_cleanup): Likewise. * libsupc++/unwind-cxx.h (__cxa_exception): Add reference count. (__cxa_dependent_exception, __cxa_allocate_dependent_exception, __cxa_free_dependent_exception, __get_dependent_exception_from_ue, __GXX_INIT_DEPENDENT_EXCEPTION_CLASS, __is_dependent_exception, __gxx_dependent_exception_class, __get_object_from_ue, __get_object_from_ambiguous_exception): Add. (__GXX_INIT_EXCEPTION_CLASS, __gxx_exception_class): Rename. (__is_gxx_exception_class): Handle dependent exceptions. * libsupc++/eh_arm.cc (__cxa_type_match): Likewise. * libsupc++/eh_call.cc (__cxa_call_unexpected): Likewise. * libsupc++/eh_personality.cc (__gxx_personality_*): Likewise. * libsupc++/eh_type.cc (__cxa_current_exception_type): Likewise. * libsupc++/eh_alloc.cc (__cxa_allocate_dependent_exception, __cxa_free_dependent_exception): Add. * libsupc++/eh_throw.cc (__gxx_exception_cleanup): Handle reference counting. * libsupc++/exception: Conditionally include exception_ptr.h. * libsupc++/Makefile.am: Register new files. * libsupc++/Makefile.in: Regenerate. * config/abi/pre/gnu.ver: Add new symbols. * testsuite/18_support/exception_ptr/current_exception.cc: Test the core functionality of current_exception(). * testsuite/18_support/exception_ptr/rethrow_exception.cc: Test the core functionality of rethrow_exception(). * testsuite/18_support/exception_ptr/lifespan.cc: Test the life span of exception objects during exception propagation. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@139064 138bc75d-0d04-0410-961f-82ee72b054a4
* libsupc++/unwind-cxx.h (__is_gxx_forced_unwind_class, __GXX_INIT_FORCED_UNWIND_CLASS): Define for ARM EABI unwinder. * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Call __GXX_INIT_FORCED_UNWIND_CLASS for forced unwind with ARM EABI unwinder. * libsupc++/eh_arm.cc (__cxa_type_match): Use __is_gxx_forced_unwind_class to check for forced unwind. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@137683 138bc75d-0d04-0410-961f-82ee72b054a4
2005-08-17 Kelley Cook <kcook@gcc.gnu.org> * All files: Update FSF address. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@103192 138bc75d-0d04-0410-961f-82ee72b054a4
2005-06-28 Paul Brook <paul@codesourcery.com> gcc/ * Makefile.in: Set and use UNWIND_H. Install as unwind.h. * c-decl.c (finish_decl): Call default_init_unwind_resume_libfunc. * except.c (add_ehspec_entry): Generate arm eabi filter lists. (assign_filter_values): Ditto. (output_ttype): New function. (output_function_exception_table): Use output_ttype. Generate arm eabi filter lists. (default_init_unwind_resume_libfunc): New function. * except.h (default_init_unwind_resume_libfunc): Add prototype. * optabs.c (init_optabs): Don't set unwind_resume_libfunc. * opts.c (decode_options): Use targetm.unwind_tables_default. * target-def.h (TARGET_ASM_TTYPE): Provide and use definition. (TARGET_ARM_EABI_UNWINDER, TARGET_UNWIND_TABLES_DEFAULT): Ditto. * target.h (struct gcc_target): Add asm.ttype, unwind_tables_default and arm_eabi_unwinder. * unwind-c.c: Support Arm EABI unwinder. * unwind.h: Rename ... * unwind-generic.h: ... To this. * doc/tm.texi (TARGET_ASM_TTYPE, TARGET_ARM_EABI_UNWINDER): Document. (TARGET_UNWID_TABLES_DEFAULT): Document. * config/arm/arm-protos.h (arm_output_fn_unwind): Add prototype. * config/arm/arm.c (arm_unwind_emit, arm_output_ttype): New functions. (TARGET_UNWIND_EMIT, TARGET_ASM_TTYPE, TARGET_ARM_EABI_UNWINDER): Define. (thumb_pushpop, thumb_output_function_prologue): Output unwinding directives. (arm_unwind_emit_stm, arm_unwind_emit_set): New functions. * config/arm/arm.h (MUST_USE_SJLJ_EXCEPTIONS): Only define when !TARGET_UNWIND_INFO. (ARM_OUTPUT_FN_UNWIND, ARM_EABI_UNWIND_TABLES): Define. * config/arm/bpabi.h (TARGET_UNWIND_INFO): Define. * config/arm/elf.h (ASM_DECLARE_FUNCTION_NAME, ASM_DECLARE_FUNCTION_SIZE): Use ARM_OUTPUT_FN_UNWIND. * config/arm/lib1funcs.asm: Include libunwind.S. * config/arm/libgcc-bpabi.ver: Add unwinding routines. * config/arm/libunwind.S: New file. * config/arm/pr-support.c: New file. * config/arm/t-bpabi (LIB1ASMFUNCS): Add _unwind. (UNWIND_H, LIB2ADDEH, LIB2ADDEHDEP): Set. * config/arm/t-symbian (UNWIND_H, LIB2ADDEH, LIB2ADDEHDEP): Set. * config/arm/unwind-arm.c: New file. * config/arm/unwind-arm.h: New file. * config/i386/t-netware (USER_H): Remove unwind.h. * config/ia64/ia64.h (TARGET_UNWIND_TABLES_DEFAULT): Define. gcc/cp/ * Make-lang.in (cp/except.o): Depend on $(TARGET_H) * except.c: Include target.h. (init_exception_processing): Initialize unwind_resume_libfunc. * doc/tm.texi: Document TARGET_ASM_TTYPE gcc/ada/ * misc.c (gnat_init_gcc_eh): Call default_init_unwind_resume_libfunc. gcc/java/ * decl.c (java_init_decl_processing): Call default_init_unwind_resume_libfunc. gcc/objc/ * objc-act.c (objc_init_exceptions): Call default_init_unwind_resume_libfunc. libstdc++/ * acinclude.m4 (GLIBCXX_ENABLE_SJLJ_EXCEPTIONS): Check for __cxa_end_cleanup. * libsupc++/Makefile.am (sources): Add eh_call.c and eh_arm.c. * libsupc++/eh_arm.cc: New file. * libsupc++/eh_call.cc: New file. * libsupc++/eh_catch.cc (__cxa_get_exception_ptr): Use __gxx_caught_object. (__cxa_begin_catch): Ditto. Use __is_gxx_exception_class. Call _Unwind_Complete when using the ARM EABI. (__cxa_end_catch): Use __is_gxx_exception_class. * libsupc++/eh_personality.cc: Define NO_SIZE_OF_ENCODED_VALUE when using the ARM EABI. (save_caught_exception, restore_caught_exception): New functions. (_throw_typet): New typedef. (get_ttype_entry, get_adjusted_ptr, check_exception_spec): Add ARM EABI implementations. (PERSONALITY_FUNCTION): Use new functions. Addd support for ARM EABI unwinding libary. (__cxa_unexpected): Disable when using the ARM EABI. * libsupc++/eh_throw.cc (__cxa_throw): Use __GXX_INIT_EXCEPTION_CLASS. (__cxa_rethrow): Use __is_gxx_exception_class. Call _Unwind_RaiseException when using the ARM EABI. * libsupc++/unwind-cxx.h (struct __cxa_exception): Add fields for ARM EABI semantics. (struct __cxa_eh_globals): Ditto. (__cxa_call_terminate): Add prototype. (__cxa_type_match, __cxa_begin_cleanup, __cxa_end_cleanup): Add prototypes. (__get_exception_header_from_obj, __get_exception_header_from_ue): Move earlier in file. (__is_gxx_exception_class, __GXX_INIT_EXCEPTION_CLASS, __gxx_caught_object): New functions. * aclocal.m4: Regenerate. * configure: Regenerate. * Makefile.in: Regenerate. * include/Makefile.in: Regenerate. * libmath/Makefile.in: Regenerate. * libsupc++/Makefile.in: Regenerate. * po/Makefile.in: Regenerate. * src/Makefie.in: Regenerate. * testsuite/makefile.in: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@101385 138bc75d-0d04-0410-961f-82ee72b054a4
* libsupc++/unwind-cxx.h: Revert gcc_unreachable change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@100002 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ 2005-05-19 Jan Beulich <jbeulich@novell.com> * unwind-compat.c: Include tconfig.h and tsystem.h. * unwind-dw2-fde-compat.c: Likewise. libstdc++-v3/ 2005-05-19 Jan Beulich <jbeulich@novell.com> * libsupc++/unwind-cxx.h: Include cstdlib. (gcc_unreachable): #define. * libsupc++/eh_personality.cc (gcc_unreachable): Remove #define. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@99952 138bc75d-0d04-0410-961f-82ee72b054a4
PR libstdc++/10606 gcc/cp/ * except.c (do_get_exception_ptr): New. (expand_start_catch_block): Use it. libstdc++/ * config/linker-map.gnu (CXXABI_1.3.1): Add __cxa_get_exception_ptr. * libsupc++/eh_alloc.cc (__cxa_allocate_exception): Increment uncaughtExceptions here instead of ... * libsupc++/eh_throw.cc (__cxa_throw) ... here. (__cxa_rethrow): Increment uncaughtExceptions here instead of ... * libsupc++/eh_catch.cc (__cxa_end_catch): ... here. (__cxa_get_exception_ptr): New. * libsupc++/unwind-cxx.h (__cxa_get_exception_ptr): Declare. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@95262 138bc75d-0d04-0410-961f-82ee72b054a4
* libsupc++/cxxabi.h: Make all declarations have default visibility. * libsupc++/exception: Likewise. * libsupc++/new: Likewise. * libsupc++/typeinfo: Likewise. * libsupc++/unwind-cxx.h: Likewise. * libsupc++/eh_alloc.cc (__cxa_allocate_exception): Put it into the __cxxabiv1 namespace. (__cxa_free_exception): Likewise. * libsupc++/eh_aux_runtime.cc (__cxa_bad_cast): Likewise. (__cxa_bad_typeid): Likewise. * libsupc++/eh_catch.cc (__cxa_begin_catch): Likewise. (__cxa_end_catch): Likewise. * libsupc++/eh_globals.cc (__cxa_get_globals_fast): Likewise. (__cxa_get_globals): Likewise. * libsupc++/eh_throw.cc (__cxa_throw): Likewise. (__cxa_rethrow): Likewise. * libsupc++/pure.cc (__cxa_pure_virtual): Likewise. * libsupc++/eh_type.cc: Include <cxxabi.h>. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85463 138bc75d-0d04-0410-961f-82ee72b054a4
2003-07-04 Benjamin Kosnik <bkoz@redhat.com> Move from CPP to CXX. * include/bits/c++config: Move to GLIBCXX from GLIBCPP. * testsuite/Makefile.am: Same. * testsuite/Makefile.in: Regenerate. * po/Makefile.am: Same. * po/Makefile.in: Regenerate. * libsupc++/Makefile.am: Same. * libsupc++/Makefile.in: Regenerate. * libmath/Makefile.am: Same. * libmath/Makefile.in: Regenerate. * include/Makefile.am: Same. * include/Makefile.in: Regenerate. * src/Makefile.am: Same. * src/Makefile.in: Regenerate. * acconfig.h: Same. * configure.host: Same. * configure.in: Same. * configure: Regenerate. * acinclude.m4: Same. * aclocal.m4: Same. * src: Change all files in this directory. * testsuite: Same. * include: Same, standardize include guards. * config: Same. * libsupc++: Same. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68958 138bc75d-0d04-0410-961f-82ee72b054a4
2003-05-24 Nathanael Nerode <neroden@gcc.gnu.org> * libsupc++/Makefile.am, libsupc++/cxxabi.h, libsupc++/del_op.cc, libsupc++/del_opnt.cc, libsupc++/del_opv.cc, libsupc++/del_opvnt.cc, libsupc++/eh_alloc.cc, libsupc++/eh_aux_runtime.cc, libsupc++/eh_catch.cc, libsupc++/eh_exception.cc, libsupc++/eh_globals.cc, libsupc++/eh_personality.cc, libsupc++/eh_term_handler.cc, libsupc++/eh_terminate.cc, libsupc++/eh_throw.cc, libsupc++/eh_type.cc, libsupc++/eh_unex_handler.cc, libsupc++/exception, libsupc++/new, libsupc++/new_handler.cc, libsupc++/new_op.cc, libsupc++/new_opnt.cc, libsupc++/new_opv.cc, libsupc++/new_opvnt.cc, libsupc++/pure.cc, libsupc++/tinfo.cc, libsupc++/tinfo2.cc, libsupc++/typeinfo, libsupc++/unwind-cxx.h, libsupc++/vec.cc: Replace "GNU CC" with "GCC". git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@67155 138bc75d-0d04-0410-961f-82ee72b054a4
* libstdc++-v3/libsupc++/unwind-cxx.h (__cxa_exception): Change catchTemp type from void* to _Unwind_Ptr. * libstdc++-v3/libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Do not cast landing_pad or base_of_encoded_value to (void *). * libstdc++-v3/libsupc++/eh_throw.cc (__gxx_exception_cleanup): Accept _URC_NO_REASON as a valid reason code. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@56352 138bc75d-0d04-0410-961f-82ee72b054a4