aboutsummaryrefslogtreecommitdiff
path: root/libgcc
AgeCommit message (Collapse)AuthorFilesLines
2018-01-05RTEMS/EPIPHANY: Add RTEMS supportSebastian Huber2-2/+7
gcc/ * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration. * config/epiphany/rtems.h: New file. libgcc/ * config.host (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration. From-SVN: r256273
2018-01-03Update copyright years.Jakub Jelinek1005-1007/+1015
From-SVN: r256169
2017-12-12Use C version of multi3 for RVE support.Kito Cheng4-91/+93
libgcc/ * config/riscv/t-elf: Use multi3.c instead of multi3.S. * config/riscv/multi3.c: New file. * config/riscv/multi3.S: Remove. From-SVN: r255598
2017-12-08Add .type and .size directives to riscv libgcc functions.Jim Wilson6-102/+182
libgcc/ * config/riscv/div.S: Use FUNC_* macros. * config/riscv/muldi3.S, config/riscv/multi3.S: Likewise * config/riscv/save-restore.S: Likewise. * config/riscv/riscv-asm.h: New. From-SVN: r255521
2017-12-01_mulkc3.c (__mulkc3): Add forward declaration.Michael Meissner3-0/+7
2017-11-30 Michael Meissner <meissner@linux.vnet.ibm.com> * config/rs6000/_mulkc3.c (__mulkc3): Add forward declaration. * config/rs6000/_divkc3.c (__divkc3): Likewise. From-SVN: r255289
2017-11-30re PR libgcc/83112 (Silence warnings from PowerPC libgcc float128-ifunc.c ↵Michael Meissner7-84/+166
compilation) 2017-11-30 Michael Meissner <meissner@linux.vnet.ibm.com> PR libgcc/83112 * config/rs6000/float128-ifunc.c (__addkf3_resolve): Use the correct type for all ifunc resolvers to silence -Wattribute-alias warnings. Eliminate the forward declaration of the resolver functions which is no longer needed. (__subkf3_resolve): Likewise. (__mulkf3_resolve): Likewise. (__divkf3_resolve): Likewise. (__negkf2_resolve): Likewise. (__eqkf2_resolve): Likewise. (__nekf2_resolve): Likewise. (__gekf2_resolve): Likewise. (__gtkf2_resolve): Likewise. (__lekf2_resolve): Likewise. (__ltkf2_resolve): Likewise. (__unordkf2_resolve): Likewise. (__extendsfkf2_resolve): Likewise. (__extenddfkf2_resolve): Likewise. (__trunckfsf2_resolve): Likewise. (__trunckfdf2_resolve): Likewise. (__fixkfsi_resolve): Likewise. (__fixkfdi_resolve): Likewise. (__fixunskfsi_resolve): Likewise. (__fixunskfdi_resolve): Likewise. (__floatsikf_resolve): Likewise. (__floatdikf_resolve): Likewise. (__floatunsikf_resolve): Likewise. (__floatundikf_resolve): Likewise. (__extendkftf2_resolve): Likewise. (__trunctfkf2_resolve): Likewise. PR libgcc/83103 * config/rs6000/quad-float128.h (TF): Don't define if long double is IEEE 128-bit floating point. (TCtype): Define as either TCmode or KCmode, depending on whether long double is IEEE 128-bit floating point. (__mulkc3_sw): Add declarations for software/hardware versions of complex multiply/divide. (__divkc3_sw): Likewise. (__mulkc3_hw): Likewise. (__divkc3_hw): Likewise. * config/rs6000/_mulkc3.c (_mulkc3): If we are building ifunc handlers to switch between using software emulation and hardware float128 instructions, build the complex multiply/divide functions for both software and hardware support. * config/rs6000/_divkc3.c (_divkc3): Likewise. * config/rs6000/float128-ifunc.c (__mulkc3_resolve): Likewise. (__divkc3_resolve): Likewise. (__mulkc3): Likewise. (__divkc3): Likewise. * config/rs6000/t-float128-hw (fp128_hardfp_src): Likewise. (fp128_hw_src): Likewise. (fp128_hw_static_obj): Likewise. (fp128_hw_shared_obj): Likewise. (_mulkc3-hw.c): Create _mulkc3-hw.c and _divkc3-hw.c from _mulkc3.c and _divkc3.c, changing the function name. (_divkc3-hw.c): Likewise. * config/rs6000/t-float128 (clean-float128): Delete _mulkc3-hw.c and _divkc3-hw.c. From-SVN: r255282
2017-11-26i386.c (processor_target_table): Add skylake_cost for skylake-avx512.Uros Bizjak3-0/+12
* config/i386/i386.c (processor_target_table): Add skylake_cost for skylake-avx512. * config/i386/x86-tune-costs.h (skylake_memcpy, skylake_memset, skylake_cost): New. * config/i386/driver-i386.c (host_detect_local_cpu): Detect skylake-avx512. * config.gcc: Add -march=cannonlake. * config/i386/driver-i386.c (host_detect_local_cpu): Detect cannonlake. * config/i386/i386-c.c (ix86_target_macros_internal): Handle cannonlake. * config/i386/i386.c (processor_costs): Add m_CANNONLAKE. (PTA_CANNONLAKE): New. (processor_target_table): Add cannonlake. (ix86_option_override_internal): Ditto. (fold_builtin_cpu): Ditto. (get_builtin_code_for_version): Handle cannonlake. (M_INTEL_COREI7_CANNONLAKE): New. * config/i386/i386.h (TARGET_CANNONLAKE, PROCESSOR_CANNONLAKE): New. * doc/invoke.texi: Add -march=cannonlake. gcc/testsuite/ * gcc.target/i386/funcspec-56.inc: Handle new march. * g++.dg/ext/mv16.C: Ditto. libgcc/ * config/i386/cpuinfo.c (get_intel_cpu): Handle cannonlake. * config/i386/cpuinfo.h (processor_subtypes): Add INTEL_COREI7_CANNONLAKE. From-SVN: r255155
2017-11-20re PR bootstrap/83015 (bootstrap comparison failure on ia64)Igor Tsimbalist5-5/+16
PR bootstrap/83015 * config/cr16/unwind-cr16.c (uw_install_context): Add FRAMES parameter. * config/xtensa/unwind-dw2-xtensa.c: Likewise * config/ia64/unwind-ia64.c: Add frames parameter. * unwind-sjlj.c: Likewise. From-SVN: r254951
2017-11-17Add Intel CET support for EH in libgcc.Igor Tsimbalist6-13/+106
Control-flow Enforcement Technology (CET), published by Intel, introduces the Shadow Stack feature, which ensures a return from a function is done to exactly the same location from where the function was called. When EH is present the control-flow transfer may skip some stack frames and the shadow stack has to be adjusted not to signal a violation of a control-flow transfer. It's done by counting a number of skiping frames and adjasting shadow stack pointer by this number. Having new semantic of the 'ret' instruction if CET is supported in HW the 'ret' instruction cannot be generated in ix86_expand_epilogue when we are returning after EH is processed. Added a code in ix86_expand_epilogue to adjust Shadow Stack pointer and to generate an indirect jump instead of 'ret'. As sp register is used during this adjustment thus the argument in pro_epilogue_adjust_stack is changed to update cfa_reg based on whether control-flow instrumentation is set. Without updating the cfa_reg field there is an assert later in dwarf2 pass related to mismatch the stack register and cfa_reg value. gcc/ * config/i386/i386.c (ix86_expand_epilogue): Change simple return to indirect jump for EH return if control-flow protection is enabled. Change explicit 'false' argument in pro_epilogue_adjust_stack with a value of flag_cf_protection. * config/i386/i386.md (simple_return_indirect_internal): Remove SImode restriction to support 64-bit. libgcc/ * config/i386/linux-unwind.h: Include config/i386/shadow-stack-unwind.h. * config/i386/shadow-stack-unwind.h: New file. * unwind-dw2.c: (uw_install_context): Add a frame parameter and pass it to _Unwind_Frames_Extra. * unwind-generic.h (_Unwind_Frames_Extra): New. * unwind.inc (_Unwind_RaiseException_Phase2): Add frames_p parameter. Add local variable frames to count number of frames. (_Unwind_ForcedUnwind_Phase2): Likewise. (_Unwind_RaiseException): Add local variable frames to count number of frames, pass it to _Unwind_RaiseException_Phase2 and uw_install_context. (_Unwind_ForcedUnwind): Likewise. (_Unwind_Resume): Likewise. (_Unwind_Resume_or_Rethrow): Likewise. From-SVN: r254876
2017-11-17Enable building libgcc with CET options.Igor Tsimbalist12-2/+115
Enable building libgcc with CET options by default on Linux/x86 if binutils supports CET v2.0. It can be disabled with --disable-cet. It is an error to configure GCC with --enable-cet if bintuiils doesn't support CET v2.0. ENDBR instruction is added to __morestack_large_model since it is called indirectly. 2017-11-17 Igor Tsimbalist <igor.v.tsimbalist@intel.com> config/ * cet.m4: New file. gcc/ * config.gcc (extra_headers): Add cet.h for x86 targets. * config/i386/cet.h: New file. * doc/install.texi: Add --enable-cet/--disable-cet. libgcc/ * Makefile.in (configure_deps): Add $(srcdir)/../config/cet.m4. (CET_FLAGS): New. * config/i386/morestack.S: Include <cet.h>. (__morestack_large_model): Add _CET_ENDBR at function entrance. * config/i386/resms64.h: Include <cet.h>. * config/i386/resms64f.h: Likewise. * config/i386/resms64fx.h: Likewise. * config/i386/resms64x.h: Likewise. * config/i386/savms64.h: Likewise. * config/i386/savms64f.h: Likewise. * config/i386/t-linux (HOST_LIBGCC2_CFLAGS): Add $(CET_FLAGS). (CRTSTUFF_T_CFLAGS): Likewise. * configure.ac: Include ../config/cet.m4. Set and substitute CET_FLAGS. * configure: Regenerated. From-SVN: r254868
2017-11-14Adapt Solaris 12 referencesRainer Orth5-8/+15
libgcc: * config.host (*-*-solaris2*): Adapt comment for Solaris 12 renaming. * config/sol2/crtpg.c (__start_crt_compiler): Likewise. * configure.ac (libgcc_cv_solaris_crts): Likewise. * configure: Regenerate. gcc: * config.gcc (*-*-solaris2*): Enable default_use_cxa_atexit since Solaris 11. Update comment. * configure.ac (gcc_cv_ld_pid): Adapt comment for Solaris 12 renaming. * config/sol2.h (STARTFILE_SPEC): Likewise. * configure: Regenerate. gcc/testsuite: * lib/target-supports.exp (check_effective_target_pie): Adapt comment for Solaris 12 renaming. * gcc.dg/torture/pr60092.c: Remove *-*-solaris2.11* dg-xfail-run-if. From-SVN: r254737
2017-11-07[libgcc, rs6000] Remove semicolon after do {} while (0) in ↵Tom de Vries2-1/+6
REGISTER_CFA_OFFSET_FOR 2017-11-07 Tom de Vries <tom@codesourcery.com> * config/rs6000/aix-unwind.h (REGISTER_CFA_OFFSET_FOR): Remove semicolon after "do {} while (0)". From-SVN: r254491
2017-11-07[libgcc] Remove semicolon after do {} while (0) in FP_HANDLE_EXCEPTIONSTom de Vries6-5/+15
2017-11-07 Tom de Vries <tom@codesourcery.com> PR other/82784 * config/aarch64/sfp-machine.h (FP_HANDLE_EXCEPTIONS): Remove semicolon after "do {} while (0)". * config/i386/sfp-machine.h (FP_HANDLE_EXCEPTIONS): Same. * config/ia64/sfp-machine.h (FP_HANDLE_EXCEPTIONS): Same. * config/mips/sfp-machine.h (FP_HANDLE_EXCEPTIONS): Same. * config/rs6000/sfp-machine.h (FP_HANDLE_EXCEPTIONS): Same. From-SVN: r254489
2017-11-04re PR libgcc/82635 (std::thread's join broken on FreeBSD with all GCCs >= 5)Andreas Tobler2-2/+49
2017-11-04 Andreas Tobler <andreast@gcc.gnu.org> PR libgcc/82635 * config/i386/freebsd-unwind.h (MD_FALLBACK_FRAME_STATE_FOR): Use a sysctl to determine whether we're in a trampoline. Keep the pattern matching method for systems without KERN_PROC_SIGTRAMP sysctl. From-SVN: r254411
2017-11-03[ARC] Fix to unwinding.Cupertino Miranda4-0/+203
gcc/ChangeLog: 2017-11-03 Cupertino Miranda <cmiranda@synopsys.com> * config/arc/arc.c (arc_save_restore): Corrected CFA note. (arc_expand_prologue): Restore blink for millicode. * config/arc/linux.h (LINK_EH_SPEC): Defined. libgcc/ChangeLog: 2017-11-03 Cupertino Miranda <cmiranda@synopsys.com> Vineet Gupta <vgupta@synopsys.com> * config.host (arc*-*-linux*): Set md_unwind_header variable. * config/arc/linux-unwind-reg.def: New file. * config/arc/linux-unwind.h: Likewise. Co-Authored-By: Vineet Gupta <vgupta@synopsys.com> From-SVN: r254367
2017-10-23rl78.md: New define_expand "subdi3".Sebastian Perta3-1/+65
* config/rl78/rl78.md: New define_expand "subdi3". * config/rl78/subdi3.S: New assembly file. * config/rl78/t-rl78: Added subdi3.S to LIB2ADD. From-SVN: r254019
2017-10-23Forgot to add the new file :-P 2017-10-13 Sebastian Perta ↵Sebastian Perta1-0/+58
<sebastian.perta@renesas.com> Forgot to add the new file :-P 2017-10-13 Sebastian Perta <sebastian.perta@renesas.com> * config/rl78/adddi3.S: New assembly file. * config/rl78/t-rl78: Added adddi3.S to LIB2ADD. From-SVN: r254016
2017-10-13rl78.c (rl78_emit_libcall): New function.Sebastian Perta2-1/+7
[gcc] * config/rl78/rl78.c (rl78_emit_libcall): New function. * config/rl78/rl78-protos.h (rl78_emit_libcall): New function. * config/rl78/rl78.md: New define_expand "adddi3". [libgcc] * config/rl78/adddi3.S: New assembly file. * config/rl78/t-rl78: Added adddi3.S to LIB2ADD. From-SVN: r253748
2017-10-13re PR target/82274 (__builtin_mul_overflow fails to detect overflow for ↵Jakub Jelinek2-1/+9
int64_t when compiled with -m32) PR target/82274 * internal-fn.c (expand_mul_overflow): If both operands have the same highpart of -1 or 0 and the topmost bit of lowpart is different, overflow is if res <= 0 rather than res < 0. * libgcc2.c (__mulvDI3): If both operands have the same highpart of -1 and the topmost bit of lowpart is 0, multiplication overflows even if both lowparts are 0. * gcc.dg/pr82274-1.c: New test. * gcc.dg/pr82274-2.c: New test. From-SVN: r253734
2017-09-29crti-hw.S: Add watchdog vector, FT930 IRQ support.James Bowman2-11/+21
libgcc/ * config/ft32/crti-hw.S: Add watchdog vector, FT930 IRQ support. From-SVN: r253276
2017-09-26Enable no-exec stacks for more targets using the Linux kernel.Joseph Myers12-0/+76
Building glibc for many different configurations and running the compilation parts of the testsuite runs into failures of the elf/check-execstack test for hppa and microblaze. Those configurations default to executable stacks in the Linux kernel because of VM_DATA_DEFAULT_FLAGS definitions including VM_EXEC (VM_DATA_DEFAULT_FLAGS being the default definition of VM_STACK_DEFAULT_FLAGS). This fails because those configurations are not generating .note.GNU-stack sections to indicate that programs do not need an executable stack. This patch fixes GCC to generate those sections on those architectures (when configured for a target using the Linux kernel), as it does on other architectures, together with adding that section to libgcc .S sources, with the same code as used on other architectures (or a variant using "#ifdef __linux__" instead of the usual "#if defined(__ELF__) && defined(__linux__)" for microblaze, as that configuration doesn't use elfos.h and so doesn't define __ELF__). This suffices to eliminate that glibc test failure. (For hppa, the compilation parts of the glibc testsuite still fail because of the separate elf/check-textrel failure.) gcc: * config/microblaze/linux.h (TARGET_ASM_FILE_END): Likewise. * config/pa/pa.h (NEED_INDICATE_EXEC_STACK): Likewise. * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Likewise. * config/pa/pa.c (pa_hpux_file_end): Rename to pa_file_end. Define unconditionally, with [ASM_OUTPUT_EXTERNAL_REAL] conditionals inside the function instead of around it. Call file_end_indicate_exec_stack if NEED_INDICATE_EXEC_STACK. (TARGET_ASM_FILE_END): Define unconditionally to pa_file_end. libgcc: * config/microblaze/crti.S, config/microblaze/crtn.S, config/microblaze/divsi3.S, config/microblaze/moddi3.S, config/microblaze/modsi3.S, config/microblaze/muldi3_hard.S, config/microblaze/mulsi3.S, config/microblaze/stack_overflow_exit.S, config/microblaze/udivsi3.S, config/microblaze/umodsi3.S, config/pa/milli64.S: Add .note.GNU-stack section. From-SVN: r253204
2017-09-23PR target/82196 addendum: Fix Darwin build breakage and test FAILS on SolarisDaniel Santos5-8/+105
gcc/testsuite: * gcc.target/i386/pr82196-1.c: (b): Remove volatile asm. * gcc.target/i386/pr82196-2.c: (b): Likewise. libgcc: * configure.ac: Add Check for HAVE_AS_AVX. * config.in: Regenerate. * configure: Likewise. * config/i386/i386-asm.h: Include auto-target.h from libgcc. (SSE_SAVE, SSE_RESTORE): Emit .byte sequence for !HAVE_AS_AVX. Correct out-of-date comments. From-SVN: r253116
2017-09-20config.gcc: Support "knm".Sebastian Peryt3-20/+30
gcc/ * config.gcc: Support "knm". * config/i386/driver-i386.c (host_detect_local_cpu): Detect "knm". * config/i386/i386-c.c (ix86_target_macros_internal): Handle PROCESSOR_KNM. * config/i386/i386.c (m_KNM): Define. (processor_target_table): Add "knm". (PTA_KNM): Define. (ix86_option_override_internal): Add "knm". (ix86_issue_rate): Add PROCESSOR_KNM. (ix86_adjust_cost): Ditto. (ia32_multipass_dfa_lookahead): Ditto. (get_builtin_code_for_version): Handle PROCESSOR_KNM. (fold_builtin_cpu): Add M_INTEL_KNM. * config/i386/i386.h (processor_costs): Define TARGET_KNM. (processor_type): Add PROCESSOR_KNM. * config/i386/x86-tune.def: Add m_KNM. * doc/invoke.texi: Add knm as x86 -march=/-mtune= CPU type. libgcc/ * config/i386/cpuinfo.h (processor_types): Add INTEL_KNM. * config/i386/cpuinfo.c (get_intel_cpu): Detect Knights Mill. gcc/testsuite/ * gcc.target/i386/builtin_target.c: Test knm. * gcc.target/i386/funcspec-56.inc: Test arch=knm. From-SVN: r253013
2017-09-17PR target/82196 correct choice of avx/sse stubs for -mcall-ms2sysv-xloguesDaniel Santos21-96/+164
gcc: config/i386/i386.c: (xlogue_layout::STUB_NAME_MAX_LEN): Increase to 20 bytes. (xlogue_layout::s_stub_names): Add an additional size-2 diminsion. (xlogue_layout::get_stub_name): Modify to select the appropairate sse or avx version of the stub. gcc/testsuite: gcc.target/i386/pr82196-1.c: New test. gcc.target/i386/pr82196-2.c: Likewise. libgcc: config/i386/i386-asm.h (PASTE2): New macro. (ASMNAME): Modify to use PASTE2. (MS2SYSV_STUB_PREFIX): New macro for isa prefix. (MS2SYSV_STUB_BEGIN, MS2SYSV_STUB_END): New macros for stub headers. config/i386/resms64.S: Rename to a header file, use MS2SYSV_STUB_BEGIN instead of HIDDEN_FUNC and MS2SYSV_STUB_END instead of FUNC_END. config/i386/resms64f.S: Likewise. config/i386/resms64fx.S: Likewise. config/i386/resms64x.S: Likewise. config/i386/savms64.S: Likewise. config/i386/savms64f.S: Likewise. config/i386/avx_resms64.S: New file that only defines a macro and includes it's corresponding header file. config/i386/avx_resms64f.S: Likewise. config/i386/avx_resms64fx.S: Likewise. config/i386/avx_resms64x.S: Likewise. config/i386/avx_savms64.S: Likewise. config/i386/avx_savms64f.S: Likewise. config/i386/sse_resms64.S: Likewise. config/i386/sse_resms64f.S: Likewise. config/i386/sse_resms64fx.S: Likewise. config/i386/sse_resms64x.S: Likewise. config/i386/sse_savms64.S: Likewise. config/i386/sse_savms64f.S: Likewise. config/i386/t-msabi: Modified to add avx and sse versions of stubs. From-SVN: r252896
2017-09-01config.host (*-*-vxworks7): Widen scope to vxworks7*.Olivier Hainque2-1/+5
2017-09-01 Olivier Hainque <hainque@adacore.com> libgcc/ * config.host (*-*-vxworks7): Widen scope to vxworks7*. From-SVN: r251594
2017-08-31config.gcc (powerpc-wrs-vxworks|vxworksae|vxworksmils): Now match as ↵Olivier Hainque2-1/+6
powerpc-wrs-vxworks*. 2017-08-31 Olivier Hainque <hainque@adacore.com> gcc/ * config.gcc (powerpc-wrs-vxworks|vxworksae|vxworksmils): Now match as powerpc-wrs-vxworks*. libgcc/ * config.host: Likewise. From-SVN: r251573
2017-08-07Share mingw fset-stack-executable with cygwinJonathan Yong2-0/+8
This patch is in use by Cygwin for years, upstream to GCC. * gcc/config/i386/mingw.opt (fset-stack-executable): Removed. * gcc/config/i386/cygming.opt (fset-stack-executable): Moved from mingw.opt. * gcc/config/i386/cygwin.h: Define CHECK_EXECUTE_STACK_ENABLED. * ligcc/config.host (*-cygwin): Include file from mingw config/i386/enable-execute-stack-mingw32.c From-SVN: r250914
2017-08-01config.gcc (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as well as ↵Jerome Lambourg4-1/+55
arm-wrs-vxworks. 2017-08-01 Jerome Lambourg <lambourg@adacore.com> Doug Rupp <rupp@adacore.com> Olivier Hainque <hainque@adacore.com> gcc/ * config.gcc (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as well as arm-wrs-vxworks. Update target_cpu_name from arm6 (arch v3) to arm8 (arch v4). * config/arm/vxworks.h (MAYBE_TARGET_BPABI_CPP_BUILTINS): New, helper for TARGET_OS_CPP_BUILTIN. (TARGET_OS_CPP_BUILTIN): Invoke MAYBE_TARGET_BPABI_CPP_BUILTINS(), refine CPU definitions for arm_arch5 and add those for arm_arch6 and arm_arch7. (MAYBE_ASM_ABI_SPEC): New, helper for SUBTARGET_EXTRA_ASM_SPEC, passing required abi options to the assembler for EABI configurations. (EXTRA_CC1_SPEC): New macro, to help prevent the implicit production of .text.hot and .text.unlikely sections for kernel modules when using ARM style exceptions. (CC1_SPEC): Remove obsolete attempt at mimicking Diab toolchain options. Add EXTRA_CC1_SPEC. (VXWORKS_ENDIAN_SPEC): Adjust comment and remove handling of Diab toolchain options. (DWARF2_UNWIND_INFO): Redefine to handle the pre/post VxWorks 7 transition. (ARM_TARGET2_DWARF_FORMAT): Define. * config/arm/t-vxworks: Adjust multilib control to removal of the Diab command line options. libgcc/ * config.host (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as well as arm-wrs-vxworks. * config/arm/t-vxworks7: New file. Add unwind-arm-vxworks.c to LIB2ADDEH. * config/arm/unwind-arm-vxworks.c: New file. Provide dummy __exidx_start and __exidx_end for downloadable modules. Co-Authored-By: Doug Rupp <rupp@adacore.com> Co-Authored-By: Olivier Hainque <hainque@adacore.com> From-SVN: r250781
2017-08-01t-vxworks (LIBGCC2_INCLUDES): Start with -I.Olivier Hainque3-8/+15
2017-08-01 Olivier Hainque <hainque@adacore.com> * config/t-vxworks (LIBGCC2_INCLUDES): Start with -I. after -nostdinc. * config/t-vxworks7: Likewise. From-SVN: r250776
2017-08-01t-vxworks: Instead of redefining LIB2ADD, augment LIB2ADDEH with vxlib.c and ↵Olivier Hainque2-1/+6
vxlib-tls.c. 2017-08-01 Olivier Hainque <hainque@adacore.com> * config/t-vxworks: Instead of redefining LIB2ADD, augment LIB2ADDEH with vxlib.c and vxlib-tls.c. From-SVN: r250775
2017-07-28[PowerPC/RTEMS] Add 64-bit support using ELFv2 ABISebastian Huber2-1/+6
Add 64-bit support for RTEMS using the ELFv2 ABI with 64-bit long double. gcc/ * config.gcc (powerpc-*-rtems*): Remove rs6000/eabi.h. Add rs6000/biarch64.h. * config/rs6000/rtems.h (ASM_DECLARE_FUNCTION_SIZE): New macro. (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Likewise. (CRT_CALL_STATIC_FUNCTION): Likewise. (ASM_DEFAULT_SPEC): New define. (ASM_SPEC32): Likewise. (ASM_SPEC64): Likewise. (ASM_SPEC_COMMON): Likewise. (ASM_SPEC): Likewise. (INVALID_64BIT): Likewise. (LINK_OS_DEFAULT_SPEC): Likewise. (LINK_OS_SPEC32): Likewise. (LINK_OS_SPEC64): Likewise. (POWERPC_LINUX): Likewise. (PTRDIFF_TYPE): Likewise. (RESTORE_FP_PREFIX): Likewise. (RESTORE_FP_SUFFIX): Likewise. (SAVE_FP_PREFIX): Likewise. (SAVE_FP_SUFFIX): Likewise. (SIZE_TYPE): Likewise. (SUBSUBTARGET_OVERRIDE_OPTIONS): Likewise. (TARGET_64BIT): Likewise. (TARGET_64BIT): Likewise. (TARGET_AIX): Likewise. (WCHAR_TYPE_SIZE): Likewise. (WCHAR_TYPE): Undefine. (TARGET_OS_CPP_BUILTINS): Add 64-bit PowerPC defines. (CPP_OS_DEFAULT_SPEC): Use previous CPP_OS_RTEMS_SPEC. (CPP_OS_RTEMS_SPEC): Delete. (SUBSUBTARGET_EXTRA_SPECS): Remove cpp_os_rtems. Add asm_spec_common, asm_spec32, asm_spec64, link_os_spec32, and link_os_spec64. * config/rs6000/t-rtems: Add mcpu=e6500/m64 multilibs. libgcc/ * config/rs6000/ibm-ldouble.c: Disable if defined __rtems__. From-SVN: r250652
2017-07-24PR testsuite/80759 Fix -mcall-ms2sysv-xlogues on Darwin and SolarisDaniel Santos9-43/+85
2017-07-24 Daniel Santos <daniel.santos@pobox.com> PR testsuite/80759 * config.host: include i386/t-msabi for darwin and solaris. * config/i386/i386-asm.h (ELFFN): Rename to FN_TYPE. (FN_SIZE): New macro. (FN_HIDDEN): Likewise. (ASMNAME): Likewise. (FUNC_START): Rename to FUNC_BEGIN, use ASMNAME, replace .global with .globl. (HIDDEN_FUNC): Use ASMNAME and .globl instead of .global. (SSE_SAVE): Convert to cpp macro, hard-code offset (always 0x60). * config/i386/resms64.S: Use SSE_SAVE as cpp macro instead of gas .macro. * config/i386/resms64f.S: Likewise. * config/i386/resms64fx.S: Likewise. * config/i386/resms64x.S: Likewise. * config/i386/savms64.S: Likewise. * config/i386/savms64f.S: Likewise. From-SVN: r250488
2017-07-19Fix Unwind support on DragonFly BSD after sigtramp moveJohn Marino2-17/+46
2017-07-19 John Marino <gnugcc@marino.st> * config/i386/dragonfly-unwind.h: Handle sigtramp relocation. From-SVN: r250354
2017-07-12re PR target/81193 (PowerPC GCC __builtin_cpu_is and __builtin_cpu_supports ↵Michael Meissner3-8/+22
should warn about old libraries) [gcc] 2017-07-12 Michael Meissner <meissner@linux.vnet.ibm.com> PR target/81193 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If GLIBC provides the hardware capability bits, define the macro __BUILTIN_CPU_SUPPORTS__. * config/rs6000/rs6000.c (cpu_expand_builtin): Generate a warning if GLIBC does not provide the hardware capability bits. Add a gcc_unreachable call if the built-in cpu function is neither __builtin_cpu_is nor __builtin_cpu_supports. (rs6000_get_function_versions_dispatcher): Change the warning that an old GLIBC is used which does not export the capability bits to be an error. * doc/extend.texi (target_clones attribute): Document the restriction that GLIBC 2.23 or newer is needed on the PowerPC. (PowerPC built-in functions): Document that GLIBC 2.23 or newer is needed by __builtin_cpu_is and __builtin_cpu_supports. Document the macros defined by GCC if the newer GLIBC is available. [gcc/testsuite] 2017-07-12 Michael Meissner <meissner@linux.vnet.ibm.com> PR target/81193 * gcc.target/powerpc/bmi-andn-1.c: Add guard against using __builtin_cpu_supports with old GLIBC's. * gcc.target/powerpc/bmi-andn-2.c: Likewise. * gcc.target/powerpc/bmi-bextr-1.c: Likewise. * gcc.target/powerpc/bmi-bextr-2.c: Likewise. * gcc.target/powerpc/bmi-bextr-4.c: Likewise. * gcc.target/powerpc/bmi-bextr-5.c: Likewise. * gcc.target/powerpc/bmi-blsi-1.c: Likewise. * gcc.target/powerpc/bmi-blsi-2.c: Likewise. * gcc.target/powerpc/bmi-blsmsk-1.c: Likewise. * gcc.target/powerpc/bmi-blsmsk-2.c: Likewise. * gcc.target/powerpc/bmi-blsr-1.c: Likewise. * gcc.target/powerpc/bmi-blsr-2.c: Likewise. * gcc.target/powerpc/bmi-tzcnt-1.c: Likewise. * gcc.target/powerpc/bmi-tzcnt-2.c: Likewise. * gcc.target/powerpc/bmi2-bzhi32-1.c: Likewise. * gcc.target/powerpc/bmi2-bzhi64-1.c: Likewise. * gcc.target/powerpc/bmi2-mulx32-1.c: Likewise. * gcc.target/powerpc/bmi2-mulx32-2.c: Likewise. * gcc.target/powerpc/bmi2-mulx64-1.c: Likewise. * gcc.target/powerpc/bmi2-mulx64-2.c: Likewise. * gcc.target/powerpc/bmi2-pdep32-1.c: Likewise. * gcc.target/powerpc/bmi2-pdep64-1.c: Likewise. * gcc.target/powerpc/bmi2-pext32-1.c: Likewise. * gcc.target/powerpc/bmi2-pext64-1.c: Likewise. * gcc.target/powerpc/cpu-builtin-1.c: Likewise. [libgcc] 2017-07-12 Michael Meissner <meissner@linux.vnet.ibm.com> PR target/81193 * configure.ac (PowerPC float128 hardware support): Test whether we can use __builtin_cpu_supports before enabling the ifunc handler. * configure: Regenerate. From-SVN: r250165
2017-07-10[ARC] Configure script to allow non uclibc based tripletsVineet Gupta2-1/+5
gcc/ 2017-07-10 Vineet Gupta <vgupta@synopsys.com> * config.gcc: Remove uclibc from arc target spec. libgcc/ 2017-07-10 Vineet Gupta <vgupta@synopsys.com> * config.host: Remove uclibc from arc target spec. From-SVN: r250097
2017-07-09config.host (*-*-netbsd*): Remove check for aout NetBSD releases.Krister Walfridsson2-8/+5
2017-07-09 Krister Walfridsson <krister.walfridsson@gmail.com> * config.host (*-*-netbsd*): Remove check for aout NetBSD releases. From-SVN: r250080
2017-07-07float128-ifunc.c: Don't include auxv.h.Peter Bergner2-42/+8
libgcc/ * config/rs6000/float128-ifunc.c: Don't include auxv.h. (have_ieee_hw_p): Delete function. (SW_OR_HW) Use __builtin_cpu_supports(). From-SVN: r250061
2017-07-06Add support for ARMv8-R architectureThomas Preud'homme2-1/+5
2017-07-06 Thomas Preud'homme <thomas.preudhomme@arm.com> gcc/ * config/arm/arm-cpus.in (armv8-r): Add new entry. * config/arm/arm-isa.h (ISA_ARMv8r): Define macro. * config/arm/arm-tables.opt: Regenerate. * config/arm/arm.h (enum base_architecture): Add BASE_ARCH_8R enumerator. * doc/invoke.texi: Mention -march=armv8-r and its extensions. gcc/testsuite/ * lib/target-supports.exp: Generate check_effective_target_arm_arch_v8r_ok, add_options_for_arm_arch_v8r and check_effective_target_arm_arch_v8r_multilib. libgcc/ * config/arm/lib1funcs.S: Defined __ARM_ARCH__ to 8 for ARMv8-R. From-SVN: r250025
2017-07-04Add missing libgcc/ChangeLog entry.Olivier Hainque1-0/+4
From-SVN: r249953
2017-07-03t-vxworks7: New file.Olivier Hainque1-0/+16
2017-06-27 Olivier Hainque <hainque@adacore.com> * config/t-vxworks7: New file. New file mistakenly omitted from previous commit referencing it. From-SVN: r249938
2017-06-28Use ucontext_t not struct ucontext in linux-unwind.h files.Joseph Myers12-12/+27
Current glibc no longer gives the ucontext_t type the tag struct ucontext, to conform with POSIX namespace rules. This requires various linux-unwind.h files in libgcc, that were previously using struct ucontext, to be fixed to use ucontext_t instead. This is similar to the removal of the struct siginfo tag from siginfo_t some years ago. This patch changes those files to use ucontext_t instead. As the standard name that should be unconditionally safe, so this is not restricted to architectures supported by glibc, or conditioned on the glibc version. Tested compilation together with current glibc with glibc's build-many-glibcs.py. * config/aarch64/linux-unwind.h (aarch64_fallback_frame_state), config/alpha/linux-unwind.h (alpha_fallback_frame_state), config/bfin/linux-unwind.h (bfin_fallback_frame_state), config/i386/linux-unwind.h (x86_64_fallback_frame_state, x86_fallback_frame_state), config/m68k/linux-unwind.h (struct uw_ucontext), config/nios2/linux-unwind.h (struct nios2_ucontext), config/pa/linux-unwind.h (pa32_fallback_frame_state), config/riscv/linux-unwind.h (riscv_fallback_frame_state), config/sh/linux-unwind.h (sh_fallback_frame_state), config/tilepro/linux-unwind.h (tile_fallback_frame_state), config/xtensa/linux-unwind.h (xtensa_fallback_frame_state): Use ucontext_t instead of struct ucontext. From-SVN: r249731
2017-06-27config.gcc (i*86-wrs-vxworks7): Handle new acceptable triplet.Jerome Lambourg2-1/+6
2017-06-27 Jerome Lambourg <lambourg@adacore.com> gcc/ * config.gcc (i*86-wrs-vxworks7): Handle new acceptable triplet. (x86_64-wrs-vxworks7): Likewise. libgcc/ * config.host (i*86-wrs)vxworks7): Handle new acceptable triplet. (x86_64-wrs-vxworks7): Likewise. From-SVN: r249689
2017-06-27t-vxworks7: New file.Olivier Hainque2-0/+8
2017-06-27 Olivier Hainque <hainque@adacore.com> * config/t-vxworks7: New file. * config.host (*-*-vxworks7): Use it. From-SVN: r249688
2017-06-22driver-i386.c (host_detect_local_cpu): Add Kaby Lake models to skylake case.Matt Turner2-0/+8
gcc/ 2017-06-22 Matt Turner <mattst88@gmail.com> * config/i386/driver-i386.c (host_detect_local_cpu): Add Kaby Lake models to skylake case. Assume skylake for unknown models with clflushopt. gcc/testsuite/ 2017-06-22 Matt Turner <mattst88@gmail.com> * gcc.target/i386/builtin_target.c: Add Kaby Lake models to skylake check. libgcc/ 2017-06-22 Matt Turner <mattst88@gmail.com> * config/i386/cpuinfo.c (get_intel_cpu): Add Kaby Lake models to skylake case. From-SVN: r249574
2017-06-21re PR gcov-profile/81080 (target libgcov not built with large file support)Richard Biener5-0/+219
2017-06-21 Richard Biener <rguenther@suse.de> PR gcov-profile/81080 * configure.ac: Add AC_SYS_LARGEFILE. * libgcov.h: Include auto-target.h before tsystem.h to pick up _FILE_OFFSET_BITS which might differ for multilibs. * config.in: Regenerate. * configure: Likewise. From-SVN: r249435
2017-06-16[arm] Explicitly set .fpu in cmse_nonsecure_call.SRichard Earnshaw2-0/+12
This file is missing a .fpu directive and was relying on the compiler driver passing through a -mfpu= command line option. When the FPU is auto, that will not be passed through correctly, so set something suitable within the file itself. libgcc: * config/arm/cmse_nonsecure_call.S: Explicitly set the FPU. From-SVN: r249297
2017-06-09Speed-up indirect-call instrumentationMartin Liska2-0/+7
2017-06-09 Martin Liska <mliska@suse.cz> * tree-profile.c (gimple_gen_ic_profiler): Update comment. (gimple_gen_ic_func_profiler): Emit direct comparison of __gcov_indirect_call_callee with NULL. (gimple_gen_time_profiler): Change probability from PROB_VERY_UNLIKELY to PROB_UNLIKELY. 2017-06-09 Martin Liska <mliska@suse.cz> * libgcov-profiler.c (__gcov_indirect_call_profiler_v2): Reset __gcov_indirect_call_callee to NULL. From-SVN: r249058
2017-06-08t-vxworks (LIBGCC2_INCLUDES): Add path to wrn/coreip to the set of -I options...Olivier Hainque2-3/+9
2017-06-08 Olivier Hainque <hainque@adacore.com> * config/t-vxworks (LIBGCC2_INCLUDES): Add path to wrn/coreip to the set of -I options, support for direct inclusions of net/uio.h by VxWorks header files via ioLib.h. From-SVN: r249016
2017-06-07Fix white space.David Edelsohn1-4/+4
From-SVN: r248969
2017-06-07aix-unwind.h (MD_FALLBACK_FRAME_STATE_FOR): Define unconditionally.Tony Reix2-9/+37
2017-06-07 Tony Reix <tony.reix@atos.net> Matthieu Sarter <matthieu.sarter.external@atos.net> David Edelsohn <dje.gcc@gmail.com> * config/rs6000/aix-unwind.h (MD_FALLBACK_FRAME_STATE_FOR): Define unconditionally. (ucontext_for): Add 64-bit AIX 6.1, 7.1, 7.2 support. Add 32-bit AIX 7.2 support. Co-Authored-By: David Edelsohn <dje.gcc@gmail.com> Co-Authored-By: Matthieu Sarter <matthieu.sarter.external@atos.net> From-SVN: r248968