Commit Graph

1461 Commits

Author SHA1 Message Date
liuhongt 6576ad5add Compile __{mul,div}hc3 into libgcc_s.so.1.
libgcc/ChangeLog:

	* config/i386/t-softfp: Compile __{mul,div}hc3 into
	libgcc_s.so.1.
2021-09-08 19:18:15 +08:00
Jakub Jelinek 87d55da7d7 libgcc, i386: Export *hf* and *hc* from libgcc_s.so.1
The following patch exports it for Linux from config/i386/*.ver where it
IMNSHO belongs, aarch64 already exports some of those at GCC_11* and other
targets might add them at completely different gcc versions.

2021-09-08  Jakub Jelinek  <jakub@redhat.com>
	    Iain Sandoe  <iain@sandoe.co.uk>

	* config/i386/libgcc-glibc.ver: Add %inherit GCC_12.0.0 GCC_7.0.0
	and export *hf* and *hc* functions at GCC_12.0.0.
2021-09-08 11:34:45 +02:00
GCC Administrator 9f99555f29 Daily bump. 2021-09-07 00:16:34 +00:00
liuhongt 637dfcf43c Explicitly add -msse2 to compile HF related libgcc source file.
For 32-bit libgcc configure w/o sse2, there's would be an error since
GCC only support _Float16 under sse2. Explicitly add -msse2 for those
HF related libgcc functions, so users can still link them w/ the
upper configuration.

libgcc/ChangeLog:

	* Makefile.in: Adjust to support specific CFLAGS for each
	libgcc source file.
	* config/i386/64/t-softfp: Explicitly add -msse2 for HF
	related libgcc source files.
	* config/i386/t-softfp: Ditto.
	* config/i386/_divhc3.c: New file.
	* config/i386/_mulhc3.c: New file.
2021-09-06 15:13:14 +08:00
GCC Administrator 7b7395409c Daily bump. 2021-09-04 00:16:38 +00:00
Iain Sandoe 3ccb523bdd libgcc, soft-float: Fix strong_alias macro use for Darwin.
Darwin does not support strong symbol aliases and a work-
around is provided in sfp-machine.h where a second function
is created that simply calls the original.  However this
needs the arguments to the synthesized function to track
the mode of the original function.

So the fix here is to match known floating point modes from
the incoming function and apply the one found to the new
function args.

The matching is highly specific to the current set of modes
and will need adjusting should more cases be added.

Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>

libgcc/ChangeLog:

	* config/i386/sfp-machine.h (alias_HFtype, alias_SFtype
	alias_DFtype, alias_TFtype): New.
	(ALIAS_SELECTOR): New.
	(strong_alias): Use __typeof and a _Generic selector to
	provide the type to the synthesized function.
2021-09-03 16:25:40 +01:00
GCC Administrator 9f7c2bad52 Daily bump. 2021-09-03 00:16:33 +00:00
liuhongt b387e664cf libgcc: Enable hfmode soft-sf/df/xf/tf extensions and truncations.
libgcc/ChangeLog:

	* config/i386/32/sfp-machine.h (_FP_NANFRAC_H): New macro.
	* config/i386/64/sfp-machine.h (_FP_NANFRAC_H): Ditto.
	* config/i386/sfp-machine.h (_FP_NANSIGN_H): Ditto.
	* config/i386/t-softfp: Add hf soft-fp.
	* config.host: Add i386/64/t-softfp.
	* config/i386/64/t-softfp: New file.
2021-09-02 14:11:59 +08:00
liuhongt e42d2d2a20 Update hf soft-fp from glibc.
libgcc/ChangeLog

	* soft-fp/eqhf2.c: New file.
	* soft-fp/extendhfdf2.c: New file.
	* soft-fp/extendhfsf2.c: New file.
	* soft-fp/half.h (FP_CMP_EQ_H): New marco.
	* soft-fp/truncdfhf2.c: New file
	* soft-fp/truncsfhf2.c: New file
2021-09-02 14:11:53 +08:00
GCC Administrator e11c6046f9 Daily bump. 2021-09-02 00:16:59 +00:00
Sebastian Huber 7a6f40d045 Fix arm target build with inhibit_libc
Do not declare abort in "libgcc/unwind-arm-common.inc" since it is already
provided by "tsystem.h".  It fixes the following build error:

In file included from libgcc/config/arm/unwind-arm.c:144:
libgcc/unwind-arm-common.inc:55:24: error: macro "abort" passed 1 arguments, but takes just 0
   55 | extern void abort (void);

libgcc/

	* unwind-arm-common.inc (abort): Remove.
2021-09-01 17:50:00 +02:00
GCC Administrator 6d51ee4321 Daily bump. 2021-09-01 00:16:58 +00:00
Richard Sandiford de7a795c32 libgcc: Add missing runtime exception notices
Quoting from https://gcc.gnu.org/pipermail/gcc/2021-July/236716.html:

--------------------------------------------------------------------
It was pointed out to me off-list that config/aarch64/value-unwind.h
is missing the runtime exception.  It looks like a few other files
are too; a fuller list is:

libgcc/config/aarch64/value-unwind.h
libgcc/config/frv/frv-abi.h
libgcc/config/i386/value-unwind.h
libgcc/config/pa/pa64-hpux-lib.h

Certainly for the aarch64 file this was simply a mistake;
it seems to have been copied from the i386 version, both of which
reference the runtime exception but don't actually include it.
--------------------------------------------------------------------

Similarly, frv-abi.h referenced the exception but didn't include it.
pa64-hpux-lib.h was missing any reference to the exception.

The decision was that this was simply a mistake
[https://gcc.gnu.org/pipermail/gcc/2021-July/236717.html]:

--------------------------------------------------------------------
[…] It generally is
considered a textual omission.  The runtime library components of GCC
are intended to be licensed under the runtime exception, which was
granted and approved at the time of introduction.
--------------------------------------------------------------------

and that we should simply change all of the files above
[https://gcc.gnu.org/pipermail/gcc/2021-July/236719.html]:

--------------------------------------------------------------------
Please correct the text in the files. The files in libgcc used in the
GCC runtime are intended to be licensed with the runtime exception and
GCC previously was granted approval for that licensing and purpose.

[…]

The runtime exception explicitly was intended for this purpose and
usage at the time that GCC received approval to apply the exception.
--------------------------------------------------------------------

libgcc/
	* config/aarch64/value-unwind.h: Add missing runtime exception
	paragraph.
	* config/frv/frv-abi.h: Likewise.
	* config/i386/value-unwind.h: Likewise.
	* config/pa/pa64-hpux-lib.h: Likewise.
2021-08-31 10:56:34 +01:00
GCC Administrator ccc1914543 Daily bump. 2021-08-27 00:16:22 +00:00
David Edelsohn 5889e842ae rs6000: inline ldouble __gcc_qsub
While performing some tests of IEEE 128 float for PPC64LE, Michael
Meissner noticed that __gcc_qsub is substantially slower than
__gcc_qadd.  __gcc_qsub calls __gcc_add with the second operand
negated.  Because the functions normally are invoked through
libgcc shared object, the extra PLT overhead has a large impact
on the overall time of the function.  This patch converts
__gcc_qadd to a static inline function invoked by __gcc_qadd
and __gcc_qsub.

libgcc/ChangeLog:

	* config/rs6000/ibm-ldouble.c (ldouble_qadd_internal): Rename from
	__gcc_qadd.
	(__gcc_qadd): Call ldouble_qadd_internal.
	(__gcc_qsub): Call ldouble_qadd_internal with second long double
	argument negated.
2021-08-26 19:13:39 -04:00
Jonathan Yong 0012f921b6 cygming-crtend.c: fix build warnings
libgcc/Changelog:

	* config/i386/cygming-crtend.c: Fix register_frame_ctor
	and register_frame_dtor warnings.

Signed-off-by: Jonathan Yong <10walls@gmail.com>
2021-08-26 01:32:33 +00:00
GCC Administrator 05ace2946b Daily bump. 2021-08-25 00:16:57 +00:00
Richard Earnshaw 574e7950bd arm: add erratum mitigation to __gnu_cmse_nonsecure_call [PR102035]
Add the recommended erratum mitigation sequence to
__gnu_cmse_nonsecure_call for use on Armv8-m.main devices. Since this
is in the library code we cannot know in advance whether the core we
are running on will be affected by this, so always enable it.

libgcc:
	PR target/102035
	* config/arm/cmse_nonsecure_call.S (__gnu_cmse_nonsecure_call):
	Add vlldm erratum work-around.
2021-08-24 11:45:13 +01:00
GCC Administrator 4be4fa4ec7 Daily bump. 2021-08-22 00:16:40 +00:00
John David Anglin 776bd8a4e0 Don't build libgcc_stub.a on hppa[12]*-*-hpux11*.
2021-08-21  John David Anglin  <danglin@gcc.gnu.org>

libgcc/ChangeLog:
	* config.host: Remove extra_parts from hppa[12]*-*-hpux11* case.
2021-08-21 18:53:44 +00:00
GCC Administrator 9d1d9fc8b4 Daily bump. 2021-08-17 00:16:32 +00:00
Sebastian Huber 8cdcea51c0 gcov: Add TARGET_GCOV_TYPE_SIZE target hook
If -fprofile-update=atomic is used, then the target must provide atomic
operations for the counters of the type returned by get_gcov_type().
This is a 64-bit type for targets which have a 64-bit long long type.
On 32-bit targets this could be an issue since they may not provide
64-bit atomic operations.  Allow targets to override the default type
size with the new TARGET_GCOV_TYPE_SIZE target hook.

If a 32-bit gcov type size is used, then there is currently a warning in
libgcov-driver.c in a dead code block due to
sizeof (counter) == sizeof (gcov_unsigned_t):

libgcc/libgcov-driver.c: In function 'dump_counter':
libgcc/libgcov-driver.c:401:46: warning: right shift count >= width of type [-Wshift-count-overflow]
  401 |     dump_unsigned ((gcov_unsigned_t)(counter >> 32), dump_fn, arg);
      |                                              ^~

gcc/c-family/

	* c-cppbuiltin.c (c_cpp_builtins): Define
	__LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.

gcc/

	* config/sparc/rtemself.h (SPARC_GCOV_TYPE_SIZE): Define.
	* config/sparc/sparc.c (sparc_gcov_type_size): New.
	(TARGET_GCOV_TYPE_SIZE): Redefine if SPARC_GCOV_TYPE_SIZE is defined.
	* coverage.c (get_gcov_type): Use targetm.gcov_type_size().
	* doc/tm.texi (TARGET_GCOV_TYPE_SIZE): Add hook under "Misc".
	* doc/tm.texi.in: Regenerate.
	* target.def (gcov_type_size): New target hook.
	* targhooks.c (default_gcov_type_size): New.
	* targhooks.h (default_gcov_type_size): Declare.
	* tree-profile.c (gimple_gen_edge_profiler): Use precision of
	gcov_type_node.
	(gimple_gen_time_profiler): Likewise.

libgcc/

	* libgcov.h (gcov_type): Define using __LIBGCC_GCOV_TYPE_SIZE.
	(gcov_type_unsigned): Likewise.
2021-08-16 15:34:25 +02:00
GCC Administrator 7dd8f1982c Daily bump. 2021-08-15 00:16:27 +00:00
Stafford Horne da8a9d695b or1k: Use cmodel=large when building crtstuff
When linking gcc runtime objects into large binaries the link may fail
with the below errors.  This will happen even if we are building with
-mcmodel=large.

    /home/shorne/work/openrisc/output/host/lib/gcc/or1k-buildroot-linux-uclibc/10.3.0/crtbeginS.o: in function `deregister_tm_clones':
    crtstuff.c:(.text+0x3c): relocation truncated to fit: R_OR1K_GOT16 against undefined symbol `_ITM_deregisterTMCloneTable'
    /home/shorne/work/openrisc/output/host/lib/gcc/or1k-buildroot-linux-uclibc/10.3.0/crtbeginS.o: in function `register_tm_clones':
    crtstuff.c:(.text+0xc0): relocation truncated to fit: R_OR1K_GOT16 against undefined symbol `_ITM_registerTMCloneTable'

This patch builds the gcc crtstuff binaries always with the
-mcmodel=large option to ensure they can be linked into large binaries.

libgcc/ChangeLog:

	PR target/99783
	* config.host (or1k-*, tmake_file): Add or1k/t-crtstuff.
	* config/or1k/t-crtstuff: New file.
2021-08-15 07:23:12 +09:00
GCC Administrator f92f477852 Daily bump. 2021-08-07 00:16:39 +00:00
Sebastian Huber 3c94db20be gcov: Remove <stdint.h> from libgcov-driver.c
In the patch to add __gcov_info_to_gcda(), the include of <stdint.h> was added
to libgcov-driver.c even if inhibit_libc is defined.  It turned out that this
header file is not always available.  Remove the include of <stdint.h> and
replace the intptr_t with the compiler provided __INTPTR_TYPE__.

libgcc/

	* libgcov-driver.c (#include <stdint.h>): Remove.
	(write_topn_counters): Use __INTPTR_TYPE__ instead of intptr_t.
2021-08-06 12:27:48 +02:00
Sebastian Huber 9124bbe185 gcov: Add __gcov_info_to_gdca()
Add __gcov_info_to_gcda() to libgcov to get the gcda data for a gcda info in a
freestanding environment.  It is intended to be used with the
-fprofile-info-section option.  A crude test program which doesn't use a linker
script is (use "gcc -coverage -fprofile-info-section -lgcov test.c" to compile
it):

  #include <gcov.h>
  #include <stdio.h>
  #include <stdlib.h>

  extern const struct gcov_info *my_info;

  static void
  filename (const char *f, void *arg)
  {
    printf("filename: %s\n", f);
  }

  static void
  dump (const void *d, unsigned n, void *arg)
  {
    const unsigned char *c = d;

    for (unsigned i = 0; i < n; ++i)
      printf ("%02x", c[i]);
  }

  static void *
  allocate (unsigned length, void *arg)
  {
    return malloc (length);
  }

  int main()
  {
    __asm__ volatile (".set my_info, .LPBX2");
    __gcov_info_to_gcda (my_info, filename, dump, allocate, NULL);
    return 0;
  }

With this patch, <stdint.h> is included in libgcov-driver.c even if
inhibit_libc is defined.  This header file should be also available for
freestanding environments.  If this is not the case, then we have to define
intptr_t somehow.

The patch removes one use of memset() which makes the <string.h> include
superfluous.

gcc/

	* gcov-io.h (gcov_write): Declare.
	* gcov-io.c (gcov_write): New.
	(gcov_write_counter): Remove.
	(gcov_write_tag_length): Likewise.
	(gcov_write_summary): Replace gcov_write_tag_length() with calls to
	gcov_write_unsigned().
	* doc/invoke.texi (fprofile-info-section): Mention
	__gcov_info_to_gdca().

gcc/testsuite/

	* gcc.dg/gcov-info-to-gcda.c: New test.

libgcc/

	* Makefile.in (LIBGCOV_DRIVER): Add _gcov_info_to_gcda.
	* gcov.h (gcov_info): Declare.
	(__gcov_info_to_gdca): Likewise.
	* libgcov.h (gcov_write_counter): Remove.
	(gcov_write_tag_length): Likewise.
	* libgcov-driver.c (#include <stdint.h>): New.
	(#include <string.h>): Remove.
	(NEED_L_GCOV): Conditionally define.
	(NEED_L_GCOV_INFO_TO_GCDA): Likewise.
	(are_all_counters_zero): New.
	(gcov_dump_handler): Likewise.
	(gcov_allocate_handler): Likewise.
	(dump_unsigned): Likewise.
	(dump_counter): Likewise.
	(write_topn_counters): Add dump_fn, allocate_fn, and arg parameters.
	Use dump_unsigned() and dump_counter().
	(write_one_data): Add dump_fn, allocate_fn, and arg parameters.  Use
	dump_unsigned(), dump_counter(), and are_all_counters_zero().
	(__gcov_info_to_gcda): New.
2021-08-06 07:28:26 +02:00
GCC Administrator 8ebf4fb54a Daily bump. 2021-08-06 00:16:29 +00:00
Jakub Jelinek 02e5ffd5db libgcc: Honor LDFLAGS_FOR_TARGET when linking libgcc_s
When building gcc with some specific LDFLAGS_FOR_TARGET, e.g.
LDFLAGS_FOR_TARGET=-Wl,-z,relro,-z,now
those flags propagate info linking of target shared libraries,
e.g. lib{ubsan,tsan,stdc++,quadmath,objc,lsan,itm,gphobos,gdruntime,gomp,go,gfortran,atomic,asan}.so.*
but there is one important exception, libgcc_s.so.* linking ignores it.

The following patch fixes that.

Bootstrapped/regtested on x86_64-linux with LDFLAGS_FOR_TARGET=-Wl,-z,relro,-z,now
and verified that libgcc_s.so.* is BIND_NOW when it previously wasn't, and
without any LDFLAGS_FOR_TARGET on x86_64-linux and i686-linux.
There on x86_64-linux I've verified that the libgcc_s.so.1 linking command
line for -m64 is identical except for whitespace to one without the patch,
and for -m32 multilib $(LDFLAGS) actually do supply there an extra -m32
that also repeats later in the @multilib_flags@, which should be harmless.

2021-08-04  Jakub Jelinek  <jakub@redhat.com>

	* config/t-slibgcc (SHLIB_LINK): Add $(LDFLAGS).
	* config/t-slibgcc-darwin (SHLIB_LINK): Likewise.
	* config/t-slibgcc-vms (SHLIB_LINK): Likewise.
	* config/t-slibgcc-fuchsia (SHLIB_LDFLAGS): Remove $(LDFLAGS).
2021-08-05 17:32:06 +02:00
GCC Administrator 2697f8324f Daily bump. 2021-08-05 00:17:03 +00:00
Jakub Jelinek 7195fa03e7 libgcc: Fix duplicated content of config/t-slibgcc-fuchsia
The file has two identical halves, seems like twice applied patch.

2021-08-04  Jakub Jelinek  <jakub@redhat.com>

	* config/t-slibgcc-fuchsia: Undo doubly applied patch.
2021-08-04 11:40:52 +02:00
GCC Administrator d97d71a198 Daily bump. 2021-07-16 00:16:25 +00:00
Alan Modra cd6ca96f5d [POWER10] __morestack calls from pcrel code
Compiling gcc/testsuite/gcc.dg/split-*.c and others with -mcpu=power10
and linking with a non-pcrel libgcc results in crashes due to the
power10 pcrel code not having r2 set for the generic-morestack.c
functions called from __morestack.  There is also a problem when
non-pcrel code calls a pcrel libgcc.  See the patch comments.

A similar situation theoretically occurs with ELFv1 multi-toc
executables, when __morestack might be located in a different toc
group to its caller.  This patch makes no attempt to fix that, since
the gold linker does not support multi-toc (gold is needed for proper
support of -fsplit-stack code) nor does gcc emit __morestack calls
that support multi-toc.

	* config/rs6000/morestack.S (R2_SAVE): Define.
	(__morestack): Save and restore r2.  Set up r2 for called
	functions.
2021-07-15 15:27:09 +09:30
GCC Administrator bea7c16a46 Daily bump. 2021-07-02 00:16:47 +00:00
H.J. Lu 1a4b2224b8 soft-fp: Update soft-fp from glibc
This patch is updating soft-fp from glibc:

1. Add __extendhfxf2 to return an IEEE half converted to IEEE extended.
2. Add __truncxfhf2 to truncate IEEE extended into IEEE half.

These are needed by x86 _Float16 support.

	* soft-fp/extendhfxf2.c: New file.
	* soft-fp/truncxfhf2.c: Likewise.
2021-07-01 15:00:11 -07:00
GCC Administrator 6bc18203dd Daily bump. 2021-06-30 00:16:52 +00:00
Julian Brown a8a730cd99 amdgcn: Enable support for TImode for AMD GCN
This patch enables support for TImode for AMD GCN, the lack of which
is currently causing a number of test failures for the target and which
is also needed to support "omp_depend_kind" for OpenMP 5.0, since that
is implemented as a 128-bit integer.

Several libgcc support routines are built by default for the "word size"
of a machine, and also for "2 * word size" of the machine.  The libgcc
build for AMD GCN is changed so that it builds for a "word size" of 64
bits, in order to better match the (64-bit) host compiler.  However it
isn't really true that we have 64-bit words -- GCN has 32-bit registers,
so changing UNITS_PER_WORD unconditionally would be the wrong thing to do.

Changing this setting for libgcc (only) means that support routines
are built for "single word" operations that are DImode (64 bits), and
those for "double word" operations are built for TImode (128 bits).
That leaves some gaps regarding previous operations that were built
for a "single word" size of 32 bits and a "double word" size of 64 bits
(generic code doesn't cover both alternatives for all operations that
might be needed).  Those gaps are filled in by this patch, or by the
preceding patches in the series.

2021-06-18  Julian Brown  <julian@codesourcery.com>

gcc/
	* config/gcn/gcn.c (gcn_init_libfuncs): New function.
	(TARGET_INIT_LIBFUNCS): Define target hook using above function.
	* config/gcn/gcn.h (UNITS_PER_WORD): Define to 8 for IN_LIBGCC2, 4
	otherwise.
	(LIBGCC2_UNITS_PER_WORD, BITS_PER_WORD): Remove definitions.
	(MAX_FIXED_MODE_SIZE): Change to 128.

libgcc/
	* config/gcn/lib2-bswapti2.c: New file.
	* config/gcn/lib2-divmod-di.c: New file.
	* config/gcn/lib2-gcn.h (DItype, UDItype, TItype, UTItype): Add
	typedefs.
	(__divdi3, __moddi3, __udivdi3, __umoddi3): Add prototypes.
	* config/gcn/t-amdgcn (LIB2ADD): Add lib2-divmod-di.c and
	lib2-bswapti2.c.
2021-06-29 08:19:56 -07:00
Julian Brown 7a973fc03a amdgcn: Use unsigned types for udivsi3/umodsi3 libgcc helper args/return
This patch changes the argument and return types for the libgcc __udivsi3
and __umodsi3 helper functions for GCN to USItype instead of SItype.
This is probably just cosmetic in practice.

2021-06-18  Julian Brown  <julian@codesourcery.com>

libgcc/
	* config/gcn/lib2-divmod.c (__udivsi3, __umodsi3): Change argument and
	return types to USItype.
	* config/gcn/lib2-gcn.h (__udivsi3, __umodsi3): Update prototypes.
2021-06-29 08:19:55 -07:00
GCC Administrator fcf617f0d2 Daily bump. 2021-06-24 00:16:30 +00:00
Kewen Lin 47749c43ac rs6000: Fix typos in float128 ISA3.1 support
The recent float128 ISA3.1 support (r12-1340) has some typos,
it makes the libgcc build fail if it's with one binutils
(assembler) which doesn't support Power10 insns.  The error
looks like:

Error: invalid switch -mpower10
Error: unrecognized option -mpower10
... [...libgcc/shared-object.mk:14: float128-p10.o] Error 1

What this patch does are:
  - fix test target typo libgcc_cv_powerpc_3_1_float128_hw
    (written wrongly as libgcc_cv_powerpc_float128_hw, so it's
     going to build ISA3.1 stuffs just when detecting ISA3.0).
  - fix test used for libgcc_cv_powerpc_3_1_float128_hw check.
  - fix test option used for libgcc_cv_powerpc_3_1_float128_hw
    check.
  - remove the ISA3.1 related contents from t-float128-hw.
  - add new macro FLOAT128_HW_INSNS_ISA3_1 to differentiate
    ISA3.1 content from ISA3.0 part in ifunc support.

Bootstrapped/regtested on:
  - powerpc64le-linux-gnu P10
  - powerpc64le-linux-gnu P9 (w/i and w/o p10 supported as)
  - powerpc64-linux-gnu P8 (w/i and w/o p10 supported as)

libgcc/ChangeLog:

	* configure: Regenerate.
	* configure.ac (test for libgcc_cv_powerpc_3_1_float128_hw): Fix
	typos among the name, CFLAGS and the test.
	* config/rs6000/t-float128-hw (fp128_3_1_hw_funcs, fp128_3_1_hw_src,
	fp128_3_1_hw_static_obj, fp128_3_1_hw_shared_obj, fp128_3_1_hw_obj):
	Remove.
	* config/rs6000/t-float128-p10-hw (FLOAT128_HW_INSNS): Append
	macro FLOAT128_HW_INSNS_ISA3_1.
	(FP128_3_1_CFLAGS_HW): Fix option typo.
	* config/rs6000/float128-ifunc.c (SW_OR_HW_ISA3_1): Guard this with
	FLOAT128_HW_INSNS_ISA3_1.
	(__floattikf_resolve): Likewise.
	(__floatuntikf_resolve): Likewise.
	(__fixkfti_resolve): Likewise.
	(__fixunskfti_resolve): Likewise.
	(__floattikf): Likewise.
	(__floatuntikf): Likewise.
	(__fixkfti): Likewise.
	(__fixunskfti): Likewise.
2021-06-22 23:09:30 -05:00
GCC Administrator f16f65f836 Daily bump. 2021-06-12 00:16:27 +00:00
Srinath Parvathaneni c5ed014834 arm: Fix the mve multilib for the broken cmse support (pr99939).
The current CMSE support in the multilib build for
"-march=armv8.1-m.main+mve -mfloat-abi=hard -mfpu=auto" is broken
as specified in PR99939 and this patch fixes the issue.

gcc/testsuite/ChangeLog:

2021-06-11  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>

	PR target/99939
	* gcc.target/arm/cmse/cmse-18.c: Add separate scan-assembler
	directives check for target is v8.1-m.main+mve or not before
	comparing the assembly output.
	* gcc.target/arm/cmse/cmse-20.c: New test.

libgcc/ChangeLog:

2021-06-11  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>

	PR target/99939
	* config/arm/cmse_nonsecure_call.S: Add	__ARM_FEATURE_MVE
	macro.
	* config/arm/t-arm: To link cmse.o and cmse_nonsecure_call.o
	on passing -mcmse option.
2021-06-11 15:56:48 +01:00
GCC Administrator 43c35d0d90 Daily bump. 2021-06-11 09:09:28 +00:00
Segher Boessenkool 7a89595509 rs6000: Fix *TItype_ppc
The *TItype_ppc definitions are guarded by _ARCH_PPC64, so all
declarations using it should do so as well.

2021-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
libgcc/
	* config/rs6000/quad-float128.h: Guard all uses of [U]TItype_ppc by
	_ARCH_PPC64 .
2021-06-10 15:20:09 +00:00
GCC Administrator 4f625f47b4 Daily bump. 2021-06-10 00:16:30 +00:00
Carl Love 9090f48071 Conversions between 128-bit integer and floating point values.
The files fixkfti-sw.c and fixunskfti-sw.c are renamed versions of
fixkfti.c and fixunskfti.c respectively to do the conversions in software.
The function names in the files were updated with the rename as well as
some white spaces fixes. The file float128-p10.c contains the functions
for using the ISA 3.1 hardware instructions to perform the conversions.

2021-06-08  Carl Love  <cel@us.ibm.com>

gcc/ChangeLog

	* config/rs6000/rs6000.c (__fixkfti, __fixunskfti, __floattikf,
	__floatuntikf): Names changed to __fixkfti_sw, __fixunskfti_sw,
	__floattikf_sw, __floatuntikf_sw respectively.
	* config/rs6000/rs6000.md (floatti<mode>2, floatunsti<mode>2,
	fix_trunc<mode>ti2, fixuns_trunc<mode>ti2): Add
	define_insn for mode IEEE 128.

gcc/testsuite/ChangeLog

	* gcc.target/powerpc/fp128_conversions.c: New file.
	* gcc.target/powerpc/int_128bit-runnable.c(vextsd2q,
	vcmpuq, vcmpsq, vcmpequq, vcmpequq., vcmpgtsq, vcmpgtsq.
	vcmpgtuq, vcmpgtuq.): Update scan-assembler-times.
	(ppc_native_128bit): Remove dg-require-effective-target.

libgcc/ChangeLog

	* config.host: Add if test and set for
	libgcc_cv_powerpc_3_1_float128_hw.
	* config/rs6000/fixkfti.c: Renamed to fixkfti-sw.c.
	Change calls of __fixkfti to __fixkfti_sw.
	* config/rs6000/fixunskfti.c: Renamed to fixunskfti-sw.c.
	Change calls of __fixunskfti to __fixunskfti_sw.
	* config/rs6000/float128-p10.c (__floattikf_hw,
	__floatuntikf_hw, __fixkfti_hw, __fixunskfti_hw): New file.
	* config/rs6000/float128-ifunc.c (SW_OR_HW_ISA3_1): New macro.
	(__floattikf_resolve, __floatuntikf_resolve, __fixkfti_resolve,
	__fixunskfti_resolve): Add resolve functions.
	(__floattikf, __floatuntikf, __fixkfti, __fixunskfti): New functions.
	* config/rs6000/float128-sed (floattitf, __floatuntitf,
	__fixtfti, __fixunstfti): Add editor commands to change names.
	* config/rs6000/float128-sed-hw (__floattitf,
	__floatuntitf, __fixtfti, __fixunstfti): Add editor commands to
	change names.
	* config/rs6000/floattikf.c: Renamed to floattikf-sw.c.
	* config/rs6000/floatuntikf.c: Renamed to floatuntikf-sw.c.
	* config/rs6000/quad-float128.h (__floattikf_sw,
	__floatuntikf_sw, __fixkfti_sw, __fixunskfti_sw, __floattikf_hw,
	__floatuntikf_hw, __fixkfti_hw, __fixunskfti_hw, __floattikf,
	__floatuntikf, __fixkfti, __fixunskfti): New extern declarations.
	* config/rs6000/t-float128 (floattikf, floatuntikf,
	fixkfti, fixunskfti): Remove file names from fp128_ppc_funcs.
	(floattikf-sw, floatuntikf-sw, fixkfti-sw, fixunskfti-sw): Add
	file names to fp128_ppc_funcs.
	* config/rs6000/t-float128-hw(fp128_3_1_hw_funcs,
	fp128_3_1_hw_src, fp128_3_1_hw_static_obj, fp128_3_1_hw_shared_obj,
	fp128_3_1_hw_obj): Add variables for ISA 3.1 support.
	* config/rs6000/t-float128-p10-hw: New file.
	* configure: Update script for isa 3.1 128-bit float support.
	* configure.ac: Add check for 128-bit float hardware support.
2021-06-09 11:20:07 -05:00
Martin Liska 4d0385dfe0 Fix my name in ChangeLog files. 2021-05-14 12:14:22 +02:00
GCC Administrator f9af11c7f1 Daily bump. 2021-05-14 00:16:30 +00:00
Dimitar Dimitrov 8aa8a2af8f libgcc: pru: Place mpyll into its own section
This should help LD's --gc-sections feature to reduce final ELF size.

libgcc/ChangeLog:

	* config/pru/mpyll.S (__pruabi_mpyll): Place into own section.

Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
2021-05-13 23:11:01 +03:00
marxin 23eb66d1d4 gcov: Use system IO buffering
gcc/ChangeLog:

	* gcov-io.c (gcov_write_block): Remove.
	(gcov_write_words): Likewise.
	(gcov_read_words): Re-implement using gcov_read_bytes.
	(gcov_allocate): Remove.
	(GCOV_BLOCK_SIZE): Likewise.
	(struct gcov_var): Remove most of the fields.
	(gcov_position): Implement with ftell.
	(gcov_rewrite): Remove setting of start and offset fields.
	(from_file): Re-format.
	(gcov_open): Remove setbuf call. It should not be needed.
	(gcov_close): Remove internal buffer handling.
	(gcov_magic): Use __builtin_bswap32.
	(gcov_write_counter): Use directly gcov_write_unsigned.
	(gcov_write_string): Use direct fwrite and do not round
	to 4 bytes.
	(gcov_seek): Use directly fseek.
	(gcov_write_tag): Use gcov_write_unsigned directly.
	(gcov_write_length): Likewise.
	(gcov_write_tag_length): Likewise.
	(gcov_read_bytes): Use directly fread.
	(gcov_read_unsigned): Use gcov_read_words.
	(gcov_read_counter): Likewise.
	(gcov_read_string): Use gcov_read_bytes.
	* gcov-io.h (GCOV_WORD_SIZE): Adjust to reflect
	that size is not in bytes, but words (4B).
	(GCOV_TAG_FUNCTION_LENGTH): Likewise.
	(GCOV_TAG_ARCS_LENGTH): Likewise.
	(GCOV_TAG_ARCS_NUM): Likewise.
	(GCOV_TAG_COUNTER_LENGTH): Likewise.
	(GCOV_TAG_COUNTER_NUM): Likewise.
	(GCOV_TAG_SUMMARY_LENGTH): Likewise.

libgcc/ChangeLog:

	* libgcov-driver.c: Fix GNU coding style.
2021-05-13 10:59:36 +02:00