mirror of
https://github.com/LIV2/bebbo-gcc.git
synced 2025-12-06 00:23:32 +00:00
merge upstream gcc-6-branch -> 6.5.0b
This commit is contained in:
commit
56c2b4d1da
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-10-02 Thomas Schwinge <thomas@codesourcery.com>
|
||||
|
||||
* gcc_update (files_and_dependencies): Handle libbacktrace.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-11-11 John David Anglin <danglin@gcc.gnu.org>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -1 +1 @@
|
||||
6.4.1b
|
||||
6.5.0b
|
||||
|
||||
154
gcc/ChangeLog
154
gcc/ChangeLog
@ -1,3 +1,157 @@
|
||||
2018-11-07 Max Filippov <jcmvbkbc@gmail.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
|
||||
|
||||
* config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
|
||||
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
PR middle-end/87623
|
||||
* fold-const.c (fold_truth_andor_1): If the right side is not constant,
|
||||
bail out if both sides do not have the same storage order.
|
||||
|
||||
2018-10-15 Richard Biener <rguenther@suse.de>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-23 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR middle-end/87024
|
||||
* tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
|
||||
calls.
|
||||
|
||||
2018-08-17 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR middle-end/86505
|
||||
* tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
|
||||
across a va-arg-pack using call adjust its return value accordingly.
|
||||
|
||||
2018-10-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2018-10-10 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR target/87550
|
||||
* config/i386/i386.c (bdesc_args): Move IX86_BUILTIN_RDPMC
|
||||
from here to ...
|
||||
(bdesc_special_args): ... here.
|
||||
|
||||
2018-09-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/87248
|
||||
* fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
|
||||
BIT_AND_EXPR's second operand is a power of two. Formatting fix.
|
||||
|
||||
2018-08-27 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/87065
|
||||
* combine.c (simplify_if_then_else): Formatting fix.
|
||||
(if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
|
||||
check.
|
||||
(known_cond): Don't return const_true_rtx for vector modes. Use
|
||||
CONST0_RTX instead of const0_rtx. Formatting fixes.
|
||||
|
||||
2018-07-24 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86627
|
||||
* expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
|
||||
and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
|
||||
and abs_d == d, do the power of two handling if profitable.
|
||||
|
||||
2018-07-17 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86542
|
||||
* omp-low.c (create_task_copyfn): Copy over also fields corresponding
|
||||
to _looptemp_ clauses, other than the first two.
|
||||
|
||||
PR middle-end/86539
|
||||
* gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
|
||||
and cond temporaries don't have reference type if iterator has
|
||||
pointer type. For init use &for_pre_body instead of pre_p if
|
||||
for_pre_body is non-empty.
|
||||
|
||||
2018-07-26 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86660
|
||||
* omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
|
||||
declare target to variables if they have always,{to,from,tofrom} map
|
||||
kinds.
|
||||
|
||||
2018-10-12 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR c++/54278
|
||||
Backport from mainline
|
||||
2017-03-23 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/80032
|
||||
* gimplify.c (gimple_push_cleanup): Forced unconditional
|
||||
cleanups still have to go to the conditional_cleanups
|
||||
sequence.
|
||||
|
||||
2017-03-21 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/80032
|
||||
* gimplify.c (gimple_push_cleanup): Add force_uncond parameter,
|
||||
if set force the cleanup to happen unconditionally.
|
||||
(gimplify_target_expr): Push inserted clobbers with force_uncond
|
||||
to avoid them being removed by control-dependent DCE.
|
||||
|
||||
2018-10-12 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR target/87517
|
||||
* config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
|
||||
Defined with __builtin_ia32_vfmaddsubpd512_mask.
|
||||
|
||||
2018-10-12 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR target/87522
|
||||
* config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
|
||||
assembler for -mavx.
|
||||
* config/i386/gnu-user64.h (ASM_SPEC): Likewise.
|
||||
|
||||
2018-09-19 John David Anglin <danglin@gcc.gnu.org>
|
||||
|
||||
* config/pa/pa.md (atomic_storeqi): Restore deleted expander.
|
||||
(atomic_storehi): Likewise.
|
||||
(atomic_storesi): Likewise.
|
||||
(atomic_loaddi): Restore compare and swap exchange loop code.
|
||||
|
||||
2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
|
||||
|
||||
* config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
|
||||
XOR operations in NAND case.
|
||||
|
||||
2018-09-03 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
backport from trunk:
|
||||
2018-06-21 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
PR tree-optimization/85859
|
||||
* tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
|
||||
test with comment from bb_no_side_effects_p.
|
||||
|
||||
2018-08-21 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR target/87014
|
||||
* config/i386/i386.md (eh_return): Always update EH return
|
||||
address in word_mode.
|
||||
|
||||
2018-08-17 John David Anglin <danglin@gcc.gnu.org>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -1 +1 @@
|
||||
20190113212543
|
||||
20190113225614
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-06-02 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-06-25 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-06-25 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
|
||||
@ -6277,7 +6277,7 @@ simplify_if_then_else (rtx x)
|
||||
pc_rtx, pc_rtx, 0, 0, 0);
|
||||
if (reg_mentioned_p (from, false_rtx))
|
||||
false_rtx = subst (known_cond (copy_rtx (false_rtx), false_code,
|
||||
from, false_val),
|
||||
from, false_val),
|
||||
pc_rtx, pc_rtx, 0, 0, 0);
|
||||
|
||||
SUBST (XEXP (x, 1), swapped ? false_rtx : true_rtx);
|
||||
@ -9035,6 +9035,7 @@ if_then_else_cond (rtx x, rtx *ptrue, rtx *pfalse)
|
||||
|
||||
if (COMPARISON_P (cond0)
|
||||
&& COMPARISON_P (cond1)
|
||||
&& SCALAR_INT_MODE_P (mode)
|
||||
&& ((GET_CODE (cond0) == reversed_comparison_code (cond1, NULL)
|
||||
&& rtx_equal_p (XEXP (cond0, 0), XEXP (cond1, 0))
|
||||
&& rtx_equal_p (XEXP (cond0, 1), XEXP (cond1, 1)))
|
||||
@ -9183,12 +9184,12 @@ known_cond (rtx x, enum rtx_code cond, rtx reg, rtx val)
|
||||
if (COMPARISON_P (x))
|
||||
{
|
||||
if (comparison_dominates_p (cond, code))
|
||||
return const_true_rtx;
|
||||
return VECTOR_MODE_P (GET_MODE (x)) ? x : const_true_rtx;
|
||||
|
||||
code = reversed_comparison_code (x, NULL);
|
||||
if (code != UNKNOWN
|
||||
&& comparison_dominates_p (cond, code))
|
||||
return const0_rtx;
|
||||
return CONST0_RTX (GET_MODE (x));
|
||||
else
|
||||
return x;
|
||||
}
|
||||
@ -9231,7 +9232,7 @@ known_cond (rtx x, enum rtx_code cond, rtx reg, rtx val)
|
||||
/* We must simplify subreg here, before we lose track of the
|
||||
original inner_mode. */
|
||||
new_rtx = simplify_subreg (GET_MODE (x), r,
|
||||
inner_mode, SUBREG_BYTE (x));
|
||||
inner_mode, SUBREG_BYTE (x));
|
||||
if (new_rtx)
|
||||
return new_rtx;
|
||||
else
|
||||
@ -9256,7 +9257,7 @@ known_cond (rtx x, enum rtx_code cond, rtx reg, rtx val)
|
||||
/* We must simplify the zero_extend here, before we lose
|
||||
track of the original inner_mode. */
|
||||
new_rtx = simplify_unary_operation (ZERO_EXTEND, GET_MODE (x),
|
||||
r, inner_mode);
|
||||
r, inner_mode);
|
||||
if (new_rtx)
|
||||
return new_rtx;
|
||||
else
|
||||
|
||||
@ -3312,7 +3312,7 @@ _mm512_maskz_fnmsub_round_ps (__mmask16 __U, __m512 __A, __m512 __B,
|
||||
(__m512d)__builtin_ia32_vfmaddsubpd512_mask(A, B, C, -1, R)
|
||||
|
||||
#define _mm512_mask_fmaddsub_round_pd(A, U, B, C, R) \
|
||||
(__m512d)__builtin_ia32_vfmaddpd512_mask(A, B, C, U, R)
|
||||
(__m512d)__builtin_ia32_vfmaddsubpd512_mask(A, B, C, U, R)
|
||||
|
||||
#define _mm512_mask3_fmaddsub_round_pd(A, B, C, U, R) \
|
||||
(__m512d)__builtin_ia32_vfmaddsubpd512_mask3(A, B, C, U, R)
|
||||
|
||||
@ -67,7 +67,7 @@ along with GCC; see the file COPYING3. If not see
|
||||
|
||||
#undef ASM_SPEC
|
||||
#define ASM_SPEC \
|
||||
"--32 %{!mno-sse2avx:%{mavx:-msse2avx}} %{msse2avx:%{!mavx:-msse2avx}}"
|
||||
"--32 %{msse2avx:%{!mavx:-msse2avx}}"
|
||||
|
||||
#undef SUBTARGET_EXTRA_SPECS
|
||||
#define SUBTARGET_EXTRA_SPECS \
|
||||
|
||||
@ -50,7 +50,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
|
||||
#define ASM_SPEC "%{" SPEC_32 ":--32} \
|
||||
%{" SPEC_64 ":--64} \
|
||||
%{" SPEC_X32 ":--x32} \
|
||||
%{!mno-sse2avx:%{mavx:-msse2avx}} %{msse2avx:%{!mavx:-msse2avx}}"
|
||||
%{msse2avx:%{!mavx:-msse2avx}}"
|
||||
|
||||
#define GNU_USER_TARGET_LINK_SPEC \
|
||||
"%{" SPEC_64 ":-m " GNU_USER_LINK_EMULATION64 "} \
|
||||
|
||||
@ -33509,6 +33509,7 @@ static const struct builtin_description bdesc_special_args[] =
|
||||
{
|
||||
{ 0, CODE_FOR_nothing, "__builtin_ia32_rdtsc", IX86_BUILTIN_RDTSC, UNKNOWN, (int) UINT64_FTYPE_VOID },
|
||||
{ 0, CODE_FOR_nothing, "__builtin_ia32_rdtscp", IX86_BUILTIN_RDTSCP, UNKNOWN, (int) UINT64_FTYPE_PUNSIGNED },
|
||||
{ 0, CODE_FOR_nothing, "__builtin_ia32_rdpmc", IX86_BUILTIN_RDPMC, UNKNOWN, (int) UINT64_FTYPE_INT },
|
||||
{ 0, CODE_FOR_pause, "__builtin_ia32_pause", IX86_BUILTIN_PAUSE, UNKNOWN, (int) VOID_FTYPE_VOID },
|
||||
|
||||
/* 80387 (for use internally for atomic compound assignment). */
|
||||
@ -33806,7 +33807,6 @@ static const struct builtin_description bdesc_args[] =
|
||||
{
|
||||
{ 0, CODE_FOR_bsr, "__builtin_ia32_bsrsi", IX86_BUILTIN_BSRSI, UNKNOWN, (int) INT_FTYPE_INT },
|
||||
{ OPTION_MASK_ISA_64BIT, CODE_FOR_bsr_rex64, "__builtin_ia32_bsrdi", IX86_BUILTIN_BSRDI, UNKNOWN, (int) INT64_FTYPE_INT64 },
|
||||
{ 0, CODE_FOR_nothing, "__builtin_ia32_rdpmc", IX86_BUILTIN_RDPMC, UNKNOWN, (int) UINT64_FTYPE_INT },
|
||||
{ 0, CODE_FOR_rotlqi3, "__builtin_ia32_rolqi", IX86_BUILTIN_ROLQI, UNKNOWN, (int) UINT8_FTYPE_UINT8_INT },
|
||||
{ 0, CODE_FOR_rotlhi3, "__builtin_ia32_rolhi", IX86_BUILTIN_ROLHI, UNKNOWN, (int) UINT16_FTYPE_UINT16_INT },
|
||||
{ 0, CODE_FOR_rotrqi3, "__builtin_ia32_rorqi", IX86_BUILTIN_RORQI, UNKNOWN, (int) UINT8_FTYPE_UINT8_INT },
|
||||
|
||||
@ -12699,7 +12699,10 @@
|
||||
stack address we wish to restore. */
|
||||
tmp = gen_rtx_PLUS (Pmode, arg_pointer_rtx, sa);
|
||||
tmp = plus_constant (Pmode, tmp, -UNITS_PER_WORD);
|
||||
tmp = gen_rtx_MEM (Pmode, tmp);
|
||||
/* Return address is always in word_mode. */
|
||||
tmp = gen_rtx_MEM (word_mode, tmp);
|
||||
if (GET_MODE (ra) != word_mode)
|
||||
ra = convert_to_mode (word_mode, ra, 1);
|
||||
emit_move_insn (tmp, ra);
|
||||
|
||||
emit_jump_insn (gen_eh_return_internal ());
|
||||
|
||||
@ -9969,7 +9969,59 @@ add,l %2,%3,%3\;bv,n %%r0(%3)"
|
||||
|
||||
;; These patterns are at the bottom so the non atomic versions are preferred.
|
||||
|
||||
;; Implement atomic DImode load using 64-bit floating point load.
|
||||
(define_expand "atomic_storeqi"
|
||||
[(match_operand:QI 0 "memory_operand") ;; memory
|
||||
(match_operand:QI 1 "register_operand") ;; val out
|
||||
(match_operand:SI 2 "const_int_operand")] ;; model
|
||||
""
|
||||
{
|
||||
if (TARGET_SYNC_LIBCALL)
|
||||
{
|
||||
rtx mem = operands[0];
|
||||
rtx val = operands[1];
|
||||
if (pa_maybe_emit_compare_and_swap_exchange_loop (NULL_RTX, mem, val))
|
||||
DONE;
|
||||
}
|
||||
FAIL;
|
||||
})
|
||||
|
||||
;; Implement atomic HImode stores using exchange.
|
||||
|
||||
(define_expand "atomic_storehi"
|
||||
[(match_operand:HI 0 "memory_operand") ;; memory
|
||||
(match_operand:HI 1 "register_operand") ;; val out
|
||||
(match_operand:SI 2 "const_int_operand")] ;; model
|
||||
""
|
||||
{
|
||||
if (TARGET_SYNC_LIBCALL)
|
||||
{
|
||||
rtx mem = operands[0];
|
||||
rtx val = operands[1];
|
||||
if (pa_maybe_emit_compare_and_swap_exchange_loop (NULL_RTX, mem, val))
|
||||
DONE;
|
||||
}
|
||||
FAIL;
|
||||
})
|
||||
|
||||
;; Implement atomic SImode store using exchange.
|
||||
|
||||
(define_expand "atomic_storesi"
|
||||
[(match_operand:SI 0 "memory_operand") ;; memory
|
||||
(match_operand:SI 1 "register_operand") ;; val out
|
||||
(match_operand:SI 2 "const_int_operand")] ;; model
|
||||
""
|
||||
{
|
||||
if (TARGET_SYNC_LIBCALL)
|
||||
{
|
||||
rtx mem = operands[0];
|
||||
rtx val = operands[1];
|
||||
if (pa_maybe_emit_compare_and_swap_exchange_loop (NULL_RTX, mem, val))
|
||||
DONE;
|
||||
}
|
||||
FAIL;
|
||||
})
|
||||
|
||||
;; Implement atomic DImode load.
|
||||
|
||||
(define_expand "atomic_loaddi"
|
||||
[(match_operand:DI 0 "register_operand") ;; val out
|
||||
@ -10010,6 +10062,14 @@ add,l %2,%3,%3\;bv,n %%r0(%3)"
|
||||
{
|
||||
enum memmodel model;
|
||||
|
||||
if (TARGET_SYNC_LIBCALL)
|
||||
{
|
||||
rtx mem = operands[0];
|
||||
rtx val = operands[1];
|
||||
if (pa_maybe_emit_compare_and_swap_exchange_loop (NULL_RTX, mem, val))
|
||||
DONE;
|
||||
}
|
||||
|
||||
if (TARGET_64BIT || TARGET_DISABLE_FPREGS || TARGET_SOFT_FLOAT)
|
||||
FAIL;
|
||||
|
||||
|
||||
@ -59,8 +59,8 @@ along with GCC; see the file COPYING3. If not see
|
||||
#undef LOCAL_LABEL_PREFIX
|
||||
#define LOCAL_LABEL_PREFIX "."
|
||||
|
||||
/* Always enable "-fpic" for Xtensa Linux. */
|
||||
#define XTENSA_ALWAYS_PIC 1
|
||||
/* Don't enable "-fpic" for Xtensa uclinux. */
|
||||
#define XTENSA_ALWAYS_PIC 0
|
||||
|
||||
#undef TARGET_LIBC_HAS_FUNCTION
|
||||
#define TARGET_LIBC_HAS_FUNCTION no_c99_libc_has_function
|
||||
|
||||
@ -1583,9 +1583,9 @@ xtensa_expand_atomic (enum rtx_code code, rtx target, rtx mem, rtx val,
|
||||
break;
|
||||
|
||||
case MULT: /* NAND */
|
||||
tmp = expand_simple_binop (SImode, XOR, old, ac.modemask,
|
||||
tmp = expand_simple_binop (SImode, AND, old, val,
|
||||
NULL_RTX, 1, OPTAB_DIRECT);
|
||||
tmp = expand_simple_binop (SImode, AND, tmp, val,
|
||||
tmp = expand_simple_binop (SImode, XOR, tmp, ac.modemask,
|
||||
new_rtx, 1, OPTAB_DIRECT);
|
||||
break;
|
||||
|
||||
|
||||
@ -1,3 +1,25 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-23 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
backport from trunk:
|
||||
2018-07-31 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
PR debug/86687
|
||||
* optimize.c (update_cloned_parm): Copy DECL_BY_REFERENCE.
|
||||
|
||||
2018-10-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2018-07-16 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/3698
|
||||
PR c++/86208
|
||||
* cp-gimplify.c (cp_genericize_r): When using extern_decl_map, or
|
||||
in TREE_USED flag from stmt to h->to.
|
||||
|
||||
2018-06-26 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/86291
|
||||
|
||||
@ -1064,6 +1064,7 @@ cp_genericize_r (tree *stmt_p, int *walk_subtrees, void *data)
|
||||
if (h)
|
||||
{
|
||||
*stmt_p = h->to;
|
||||
TREE_USED (h->to) |= TREE_USED (stmt);
|
||||
*walk_subtrees = 0;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@ -46,6 +46,8 @@ update_cloned_parm (tree parm, tree cloned_parm, bool first)
|
||||
/* We may have taken its address. */
|
||||
TREE_ADDRESSABLE (cloned_parm) = TREE_ADDRESSABLE (parm);
|
||||
|
||||
DECL_BY_REFERENCE (cloned_parm) = DECL_BY_REFERENCE (parm);
|
||||
|
||||
/* The definition might have different constness. */
|
||||
TREE_READONLY (cloned_parm) = TREE_READONLY (parm);
|
||||
|
||||
|
||||
@ -4345,6 +4345,11 @@ expand_divmod (int rem_flag, enum tree_code code, machine_mode mode,
|
||||
HOST_WIDE_INT d = INTVAL (op1);
|
||||
unsigned HOST_WIDE_INT abs_d;
|
||||
|
||||
/* Not prepared to handle division/remainder by
|
||||
0xffffffffffffffff8000000000000000 etc. */
|
||||
if (d == HOST_WIDE_INT_MIN && size > HOST_BITS_PER_WIDE_INT)
|
||||
break;
|
||||
|
||||
/* Since d might be INT_MIN, we have to cast to
|
||||
unsigned HOST_WIDE_INT before negating to avoid
|
||||
undefined signed overflow. */
|
||||
@ -4388,9 +4393,7 @@ expand_divmod (int rem_flag, enum tree_code code, machine_mode mode,
|
||||
compute_mode)
|
||||
!= CODE_FOR_nothing)))
|
||||
;
|
||||
else if (EXACT_POWER_OF_2_OR_ZERO_P (abs_d)
|
||||
&& (size <= HOST_BITS_PER_WIDE_INT
|
||||
|| abs_d != (unsigned HOST_WIDE_INT) d))
|
||||
else if (EXACT_POWER_OF_2_OR_ZERO_P (abs_d))
|
||||
{
|
||||
if (rem_flag)
|
||||
{
|
||||
|
||||
@ -5855,12 +5855,13 @@ fold_truth_andor_1 (location_t loc, enum tree_code code, tree truth_type,
|
||||
}
|
||||
|
||||
/* If the right sides are not constant, do the same for it. Also,
|
||||
disallow this optimization if a size or signedness mismatch occurs
|
||||
between the left and right sides. */
|
||||
disallow this optimization if a size, signedness or storage order
|
||||
mismatch occurs between the left and right sides. */
|
||||
if (l_const == 0)
|
||||
{
|
||||
if (ll_bitsize != lr_bitsize || rl_bitsize != rr_bitsize
|
||||
|| ll_unsignedp != lr_unsignedp || rl_unsignedp != rr_unsignedp
|
||||
|| ll_reversep != lr_reversep
|
||||
/* Make sure the two fields on the right
|
||||
correspond to the left without being swapped. */
|
||||
|| ll_bitpos - rl_bitpos != lr_bitpos - rr_bitpos)
|
||||
@ -11866,10 +11867,16 @@ fold_ternary_loc (location_t loc, enum tree_code code, tree type,
|
||||
&& integer_pow2p (arg1)
|
||||
&& TREE_CODE (TREE_OPERAND (arg0, 0)) == BIT_AND_EXPR
|
||||
&& operand_equal_p (TREE_OPERAND (TREE_OPERAND (arg0, 0), 1),
|
||||
arg1, OEP_ONLY_CONST))
|
||||
arg1, OEP_ONLY_CONST)
|
||||
/* operand_equal_p compares just value, not precision, so e.g.
|
||||
arg1 could be 8-bit -128 and be power of two, but BIT_AND_EXPR
|
||||
second operand 32-bit -128, which is not a power of two (or vice
|
||||
versa. */
|
||||
&& integer_pow2p (TREE_OPERAND (TREE_OPERAND (arg0, 0), 1)))
|
||||
return pedantic_non_lvalue_loc (loc,
|
||||
fold_convert_loc (loc, type,
|
||||
TREE_OPERAND (arg0, 0)));
|
||||
fold_convert_loc (loc, type,
|
||||
TREE_OPERAND (arg0,
|
||||
0)));
|
||||
|
||||
/* Disable the transformations below for vectors, since
|
||||
fold_binary_op_with_conditional_arg may undo them immediately,
|
||||
|
||||
@ -1,3 +1,17 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-09-07 Janus Weil <janus@gcc.gnu.org>
|
||||
|
||||
Backported from trunk
|
||||
PR fortran/86116
|
||||
* interface.c (compare_type): Remove a CLASS/TYPE check.
|
||||
(compare_type_characteristics): New function that behaves like the old
|
||||
'compare_type'.
|
||||
(gfc_check_dummy_characteristics, gfc_check_result_characteristics):
|
||||
Call 'compare_type_characteristics' instead of 'compare_type'.
|
||||
|
||||
2018-07-03 Paul Thomas <pault@gcc.gnu.org>
|
||||
|
||||
PR fortran/82969
|
||||
|
||||
@ -638,13 +638,20 @@ compare_type (gfc_symbol *s1, gfc_symbol *s2)
|
||||
if (s2->attr.ext_attr & (1 << EXT_ATTR_NO_ARG_CHECK))
|
||||
return 1;
|
||||
|
||||
return gfc_compare_types (&s1->ts, &s2->ts) || s2->ts.type == BT_ASSUMED;
|
||||
}
|
||||
|
||||
|
||||
static bool
|
||||
compare_type_characteristics (gfc_symbol *s1, gfc_symbol *s2)
|
||||
{
|
||||
/* TYPE and CLASS of the same declared type are type compatible,
|
||||
but have different characteristics. */
|
||||
if ((s1->ts.type == BT_CLASS && s2->ts.type == BT_DERIVED)
|
||||
|| (s1->ts.type == BT_DERIVED && s2->ts.type == BT_CLASS))
|
||||
return 0;
|
||||
|
||||
return gfc_compare_types (&s1->ts, &s2->ts) || s2->ts.type == BT_ASSUMED;
|
||||
return compare_type (s1, s2);
|
||||
}
|
||||
|
||||
|
||||
@ -1190,7 +1197,8 @@ gfc_check_dummy_characteristics (gfc_symbol *s1, gfc_symbol *s2,
|
||||
/* Check type and rank. */
|
||||
if (type_must_agree)
|
||||
{
|
||||
if (!compare_type (s1, s2) || !compare_type (s2, s1))
|
||||
if (!compare_type_characteristics (s1, s2)
|
||||
|| !compare_type_characteristics (s2, s1))
|
||||
{
|
||||
snprintf (errmsg, err_len, "Type mismatch in argument '%s' (%s/%s)",
|
||||
s1->name, gfc_typename (&s1->ts), gfc_typename (&s2->ts));
|
||||
@ -1409,7 +1417,7 @@ gfc_check_result_characteristics (gfc_symbol *s1, gfc_symbol *s2,
|
||||
return true;
|
||||
|
||||
/* Check type and rank. */
|
||||
if (!compare_type (r1, r2))
|
||||
if (!compare_type_characteristics (r1, r2))
|
||||
{
|
||||
snprintf (errmsg, err_len, "Type mismatch in function result (%s/%s)",
|
||||
gfc_typename (&r1->ts), gfc_typename (&r2->ts));
|
||||
|
||||
@ -5534,10 +5534,13 @@ gimplify_cleanup_point_expr (tree *expr_p, gimple_seq *pre_p)
|
||||
|
||||
/* Insert a cleanup marker for gimplify_cleanup_point_expr. CLEANUP
|
||||
is the cleanup action required. EH_ONLY is true if the cleanup should
|
||||
only be executed if an exception is thrown, not on normal exit. */
|
||||
only be executed if an exception is thrown, not on normal exit.
|
||||
If FORCE_UNCOND is true perform the cleanup unconditionally; this is
|
||||
only valid for clobbers. */
|
||||
|
||||
static void
|
||||
gimple_push_cleanup (tree var, tree cleanup, bool eh_only, gimple_seq *pre_p)
|
||||
gimple_push_cleanup (tree var, tree cleanup, bool eh_only, gimple_seq *pre_p,
|
||||
bool force_uncond = false)
|
||||
{
|
||||
gimple *wce;
|
||||
gimple_seq cleanup_stmts = NULL;
|
||||
@ -5569,22 +5572,31 @@ gimple_push_cleanup (tree var, tree cleanup, bool eh_only, gimple_seq *pre_p)
|
||||
}
|
||||
val
|
||||
*/
|
||||
tree flag = create_tmp_var (boolean_type_node, "cleanup");
|
||||
gassign *ffalse = gimple_build_assign (flag, boolean_false_node);
|
||||
gassign *ftrue = gimple_build_assign (flag, boolean_true_node);
|
||||
if (force_uncond)
|
||||
{
|
||||
gimplify_stmt (&cleanup, &cleanup_stmts);
|
||||
wce = gimple_build_wce (cleanup_stmts);
|
||||
gimplify_seq_add_stmt (&gimplify_ctxp->conditional_cleanups, wce);
|
||||
}
|
||||
else
|
||||
{
|
||||
tree flag = create_tmp_var (boolean_type_node, "cleanup");
|
||||
gassign *ffalse = gimple_build_assign (flag, boolean_false_node);
|
||||
gassign *ftrue = gimple_build_assign (flag, boolean_true_node);
|
||||
|
||||
cleanup = build3 (COND_EXPR, void_type_node, flag, cleanup, NULL);
|
||||
gimplify_stmt (&cleanup, &cleanup_stmts);
|
||||
wce = gimple_build_wce (cleanup_stmts);
|
||||
cleanup = build3 (COND_EXPR, void_type_node, flag, cleanup, NULL);
|
||||
gimplify_stmt (&cleanup, &cleanup_stmts);
|
||||
wce = gimple_build_wce (cleanup_stmts);
|
||||
|
||||
gimplify_seq_add_stmt (&gimplify_ctxp->conditional_cleanups, ffalse);
|
||||
gimplify_seq_add_stmt (&gimplify_ctxp->conditional_cleanups, wce);
|
||||
gimplify_seq_add_stmt (pre_p, ftrue);
|
||||
gimplify_seq_add_stmt (&gimplify_ctxp->conditional_cleanups, ffalse);
|
||||
gimplify_seq_add_stmt (&gimplify_ctxp->conditional_cleanups, wce);
|
||||
gimplify_seq_add_stmt (pre_p, ftrue);
|
||||
|
||||
/* Because of this manipulation, and the EH edges that jump
|
||||
threading cannot redirect, the temporary (VAR) will appear
|
||||
to be used uninitialized. Don't warn. */
|
||||
TREE_NO_WARNING (var) = 1;
|
||||
/* Because of this manipulation, and the EH edges that jump
|
||||
threading cannot redirect, the temporary (VAR) will appear
|
||||
to be used uninitialized. Don't warn. */
|
||||
TREE_NO_WARNING (var) = 1;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -5661,11 +5673,7 @@ gimplify_target_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p)
|
||||
NULL);
|
||||
TREE_THIS_VOLATILE (clobber) = true;
|
||||
clobber = build2 (MODIFY_EXPR, TREE_TYPE (temp), temp, clobber);
|
||||
if (cleanup)
|
||||
cleanup = build2 (COMPOUND_EXPR, void_type_node, cleanup,
|
||||
clobber);
|
||||
else
|
||||
cleanup = clobber;
|
||||
gimple_push_cleanup (temp, clobber, false, pre_p, true);
|
||||
}
|
||||
|
||||
if (cleanup)
|
||||
@ -8717,9 +8725,25 @@ gimplify_omp_for (tree *expr_p, gimple_seq *pre_p)
|
||||
t = TREE_VEC_ELT (OMP_FOR_INIT (for_stmt), i);
|
||||
if (!is_gimple_constant (TREE_OPERAND (t, 1)))
|
||||
{
|
||||
tree type = TREE_TYPE (TREE_OPERAND (t, 0));
|
||||
TREE_OPERAND (t, 1)
|
||||
= get_initialized_tmp_var (TREE_OPERAND (t, 1),
|
||||
pre_p, NULL);
|
||||
gimple_seq_empty_p (for_pre_body)
|
||||
? pre_p : &for_pre_body, NULL);
|
||||
/* Reference to pointer conversion is considered useless,
|
||||
but is significant for firstprivate clause. Force it
|
||||
here. */
|
||||
if (TREE_CODE (type) == POINTER_TYPE
|
||||
&& (TREE_CODE (TREE_TYPE (TREE_OPERAND (t, 1)))
|
||||
== REFERENCE_TYPE))
|
||||
{
|
||||
tree v = create_tmp_var (TYPE_MAIN_VARIANT (type));
|
||||
tree m = build2 (INIT_EXPR, TREE_TYPE (v), v,
|
||||
TREE_OPERAND (t, 1));
|
||||
gimplify_and_add (m, gimple_seq_empty_p (for_pre_body)
|
||||
? pre_p : &for_pre_body);
|
||||
TREE_OPERAND (t, 1) = v;
|
||||
}
|
||||
tree c = build_omp_clause (input_location,
|
||||
OMP_CLAUSE_FIRSTPRIVATE);
|
||||
OMP_CLAUSE_DECL (c) = TREE_OPERAND (t, 1);
|
||||
@ -8731,10 +8755,25 @@ gimplify_omp_for (tree *expr_p, gimple_seq *pre_p)
|
||||
t = TREE_VEC_ELT (OMP_FOR_COND (for_stmt), i);
|
||||
if (!is_gimple_constant (TREE_OPERAND (t, 1)))
|
||||
{
|
||||
tree type = TREE_TYPE (TREE_OPERAND (t, 0));
|
||||
TREE_OPERAND (t, 1)
|
||||
= get_initialized_tmp_var (TREE_OPERAND (t, 1),
|
||||
gimple_seq_empty_p (for_pre_body)
|
||||
? pre_p : &for_pre_body, NULL);
|
||||
/* Reference to pointer conversion is considered useless,
|
||||
but is significant for firstprivate clause. Force it
|
||||
here. */
|
||||
if (TREE_CODE (type) == POINTER_TYPE
|
||||
&& (TREE_CODE (TREE_TYPE (TREE_OPERAND (t, 1)))
|
||||
== REFERENCE_TYPE))
|
||||
{
|
||||
tree v = create_tmp_var (TYPE_MAIN_VARIANT (type));
|
||||
tree m = build2 (INIT_EXPR, TREE_TYPE (v), v,
|
||||
TREE_OPERAND (t, 1));
|
||||
gimplify_and_add (m, gimple_seq_empty_p (for_pre_body)
|
||||
? pre_p : &for_pre_body);
|
||||
TREE_OPERAND (t, 1) = v;
|
||||
}
|
||||
tree c = build_omp_clause (input_location,
|
||||
OMP_CLAUSE_FIRSTPRIVATE);
|
||||
OMP_CLAUSE_DECL (c) = TREE_OPERAND (t, 1);
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-04-25 Martin Liska <mliska@suse.cz>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -2063,13 +2063,16 @@ scan_sharing_clauses (tree clauses, omp_context *ctx,
|
||||
/* Global variables with "omp declare target" attribute
|
||||
don't need to be copied, the receiver side will use them
|
||||
directly. However, global variables with "omp declare target link"
|
||||
attribute need to be copied. */
|
||||
attribute need to be copied. Or when ALWAYS modifier is used. */
|
||||
if (OMP_CLAUSE_CODE (c) == OMP_CLAUSE_MAP
|
||||
&& DECL_P (decl)
|
||||
&& ((OMP_CLAUSE_MAP_KIND (c) != GOMP_MAP_FIRSTPRIVATE_POINTER
|
||||
&& (OMP_CLAUSE_MAP_KIND (c)
|
||||
!= GOMP_MAP_FIRSTPRIVATE_REFERENCE))
|
||||
|| TREE_CODE (TREE_TYPE (decl)) == ARRAY_TYPE)
|
||||
&& OMP_CLAUSE_MAP_KIND (c) != GOMP_MAP_ALWAYS_TO
|
||||
&& OMP_CLAUSE_MAP_KIND (c) != GOMP_MAP_ALWAYS_FROM
|
||||
&& OMP_CLAUSE_MAP_KIND (c) != GOMP_MAP_ALWAYS_TOFROM
|
||||
&& is_global_var (maybe_lookup_decl_in_outer_ctx (decl, ctx))
|
||||
&& varpool_node::get_create (decl)->offloadable
|
||||
&& !lookup_attribute ("omp declare target link",
|
||||
@ -15390,6 +15393,7 @@ create_task_copyfn (gomp_task *task_stmt, omp_context *ctx)
|
||||
splay_tree_node n;
|
||||
struct omp_taskcopy_context tcctx;
|
||||
location_t loc = gimple_location (task_stmt);
|
||||
size_t looptempno = 0;
|
||||
|
||||
child_fn = gimple_omp_task_copy_fn (task_stmt);
|
||||
child_cfun = DECL_STRUCT_FUNCTION (child_fn);
|
||||
@ -15503,6 +15507,15 @@ create_task_copyfn (gomp_task *task_stmt, omp_context *ctx)
|
||||
t = build2 (MODIFY_EXPR, TREE_TYPE (dst), dst, src);
|
||||
append_to_statement_list (t, &list);
|
||||
break;
|
||||
case OMP_CLAUSE__LOOPTEMP_:
|
||||
/* Fields for first two _looptemp_ clauses are initialized by
|
||||
GOMP_taskloop*, the rest are handled like firstprivate. */
|
||||
if (looptempno < 2)
|
||||
{
|
||||
looptempno++;
|
||||
break;
|
||||
}
|
||||
/* FALLTHRU */
|
||||
case OMP_CLAUSE_FIRSTPRIVATE:
|
||||
decl = OMP_CLAUSE_DECL (c);
|
||||
if (is_variable_sized (decl))
|
||||
@ -15528,7 +15541,10 @@ create_task_copyfn (gomp_task *task_stmt, omp_context *ctx)
|
||||
src = decl;
|
||||
dst = build_simple_mem_ref_loc (loc, arg);
|
||||
dst = omp_build_component_ref (dst, f);
|
||||
t = lang_hooks.decls.omp_clause_copy_ctor (c, dst, src);
|
||||
if (OMP_CLAUSE_CODE (c) == OMP_CLAUSE__LOOPTEMP_)
|
||||
t = build2 (MODIFY_EXPR, TREE_TYPE (dst), dst, src);
|
||||
else
|
||||
t = lang_hooks.decls.omp_clause_copy_ctor (c, dst, src);
|
||||
append_to_statement_list (t, &list);
|
||||
break;
|
||||
case OMP_CLAUSE_PRIVATE:
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,92 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-23 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
backport from trunk:
|
||||
2018-07-31 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
PR debug/86687
|
||||
* g++.dg/guality/pr86687.C: New test.
|
||||
|
||||
2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* gcc.c-torture/execute/pr87623.c: New test.
|
||||
|
||||
2018-10-15 Richard Biener <rguenther@suse.de>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-23 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR middle-end/87024
|
||||
* gcc.dg/pr87024.c: New testcase.
|
||||
|
||||
2018-08-17 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR middle-end/86505
|
||||
* gcc.dg/torture/pr86505.c: New testcase.
|
||||
|
||||
2018-10-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2018-10-10 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR target/87550
|
||||
* gcc.target/i386/pr87550.c: New test.
|
||||
|
||||
2018-09-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/87248
|
||||
* c-c++-common/torture/pr87248.c: New test.
|
||||
|
||||
2018-08-27 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR rtl-optimization/87065
|
||||
* gcc.target/i386/pr87065.c: New test.
|
||||
|
||||
2018-07-24 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86627
|
||||
* gcc.target/i386/pr86627.c: New test.
|
||||
|
||||
2018-07-16 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/3698
|
||||
PR c++/86208
|
||||
* g++.dg/opt/pr3698.C: New test.
|
||||
|
||||
2018-10-12 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR c++/54278
|
||||
Backport from mainline
|
||||
2017-03-21 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/80032
|
||||
* g++.dg/opt/pr80032.C: New testcase.
|
||||
|
||||
2018-09-07 Janus Weil <janus@gcc.gnu.org>
|
||||
|
||||
Backported from trunk
|
||||
PR fortran/86116
|
||||
* gfortran.dg/generic_34.f90: New test case.
|
||||
|
||||
2018-09-03 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
backport from trunk:
|
||||
2018-06-21 Tom de Vries <tdevries@suse.de>
|
||||
|
||||
PR tree-optimization/85859
|
||||
* gcc.dg/pr85859.c: New test.
|
||||
|
||||
2018-08-21 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR target/87014
|
||||
* g++.dg/torture/pr87014.C: New file.
|
||||
|
||||
2018-07-12 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR target/84829
|
||||
|
||||
36
gcc/testsuite/c-c++-common/torture/pr87248.c
Normal file
36
gcc/testsuite/c-c++-common/torture/pr87248.c
Normal file
@ -0,0 +1,36 @@
|
||||
/* PR middle-end/87248 */
|
||||
/* { dg-do run } */
|
||||
|
||||
void
|
||||
foo (signed char *p, int q)
|
||||
{
|
||||
*p = q & (-__SCHAR_MAX__ - 1) ? (-__SCHAR_MAX__ - 1) : 0;
|
||||
}
|
||||
|
||||
int
|
||||
bar (long long x)
|
||||
{
|
||||
return x & (-__INT_MAX__ - 1) ? (-__INT_MAX__ - 1) : 0;
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
#if __INT_MAX__ > 4 * __SCHAR_MAX__
|
||||
signed char a[4];
|
||||
foo (a, __SCHAR_MAX__ + 1U);
|
||||
foo (a + 1, 2 * (__SCHAR_MAX__ + 1U));
|
||||
foo (a + 2, -__INT_MAX__ - 1);
|
||||
foo (a + 3, (__SCHAR_MAX__ + 1U) / 2);
|
||||
if (a[0] != (-__SCHAR_MAX__ - 1) || a[1] != a[0] || a[2] != a[0] || a[3] != 0)
|
||||
__builtin_abort ();
|
||||
#endif
|
||||
#if __LONG_LONG_MAX__ > 4 * __INT_MAX__
|
||||
if (bar (__INT_MAX__ + 1LL) != (-__INT_MAX__ - 1)
|
||||
|| bar (2 * (__INT_MAX__ + 1LL)) != (-__INT_MAX__ - 1)
|
||||
|| bar (-__LONG_LONG_MAX__ - 1) != (-__INT_MAX__ - 1)
|
||||
|| bar ((__INT_MAX__ + 1LL) / 2) != 0)
|
||||
__builtin_abort ();
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
28
gcc/testsuite/g++.dg/guality/pr86687.C
Normal file
28
gcc/testsuite/g++.dg/guality/pr86687.C
Normal file
@ -0,0 +1,28 @@
|
||||
// PR debug/86687
|
||||
// { dg-do run }
|
||||
// { dg-options "-g" }
|
||||
|
||||
class string {
|
||||
public:
|
||||
string (int p) { this->p = p ; }
|
||||
string (const string &s) { this->p = s.p; }
|
||||
|
||||
int p;
|
||||
};
|
||||
|
||||
class foo {
|
||||
public:
|
||||
foo (string dir_hint) {
|
||||
p = dir_hint.p; // { dg-final { gdb-test 16 "dir_hint.p" 3 } }
|
||||
}
|
||||
|
||||
int p;
|
||||
};
|
||||
|
||||
int
|
||||
main (void)
|
||||
{
|
||||
string s = 3;
|
||||
foo bar(s);
|
||||
return !(bar.p == 3);
|
||||
}
|
||||
21
gcc/testsuite/g++.dg/opt/pr3698.C
Normal file
21
gcc/testsuite/g++.dg/opt/pr3698.C
Normal file
@ -0,0 +1,21 @@
|
||||
// PR c++/3698
|
||||
// { dg-do link }
|
||||
// { dg-options "-O0" }
|
||||
|
||||
struct X {
|
||||
int i;
|
||||
};
|
||||
|
||||
inline const int&
|
||||
OHashKey (const X& x)
|
||||
{
|
||||
return x.i;
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
extern const int& OHashKey (const X& x);
|
||||
X x;
|
||||
return OHashKey (x);
|
||||
}
|
||||
121
gcc/testsuite/g++.dg/opt/pr80032.C
Normal file
121
gcc/testsuite/g++.dg/opt/pr80032.C
Normal file
@ -0,0 +1,121 @@
|
||||
// PR tree-optimization/80032
|
||||
/* { dg-do compile } */
|
||||
/* { dg-require-effective-target c++11 } */
|
||||
/* { dg-options "-O2" } */
|
||||
/* If DCE removes too many CLOBBERs then stack usage goes through the
|
||||
roof as stack slots can no longer be shared. */
|
||||
/* { dg-additional-options "-Wstack-usage=200" { target x86_64-*-* i?86-*-* } } */
|
||||
|
||||
typedef unsigned a;
|
||||
namespace test {
|
||||
enum b { c };
|
||||
class ADataContainer;
|
||||
class BitMask;
|
||||
namespace api {
|
||||
enum DataStore { candidate };
|
||||
}
|
||||
using d = api::DataStore;
|
||||
namespace db {
|
||||
class e;
|
||||
class f;
|
||||
class g;
|
||||
class ManagedObjectConst {
|
||||
public:
|
||||
ManagedObjectConst(const ManagedObjectConst &);
|
||||
bool isFieldDefault(a, d) const;
|
||||
ADataContainer &getFieldDefault(a, d) const;
|
||||
g *h;
|
||||
e *i;
|
||||
f *j;
|
||||
};
|
||||
struct FieldInfo {
|
||||
FieldInfo(ManagedObjectConst, a, d);
|
||||
ManagedObjectConst k;
|
||||
};
|
||||
b compare(const FieldInfo &, const ADataContainer &);
|
||||
class ManagedObject : public ManagedObjectConst {};
|
||||
}
|
||||
using namespace db;
|
||||
void FN(ManagedObject &k, const BitMask &) {
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
if (!k.isFieldDefault(8, d::candidate) &&
|
||||
!compare(FieldInfo(k, 11, d::candidate),
|
||||
k.getFieldDefault(11, d::candidate)) == c)
|
||||
return;
|
||||
}
|
||||
}
|
||||
37
gcc/testsuite/g++.dg/torture/pr87014.C
Normal file
37
gcc/testsuite/g++.dg/torture/pr87014.C
Normal file
@ -0,0 +1,37 @@
|
||||
// { dg-do run }
|
||||
|
||||
void
|
||||
fillstack ()
|
||||
{
|
||||
long long foo[] =
|
||||
{
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
};
|
||||
}
|
||||
|
||||
void
|
||||
f (long long=-1,long long=-1,long long=-1,long long=-1,
|
||||
long long=-1,long long=-1,long long arg7_on_stack=-1)
|
||||
{
|
||||
throw 0;
|
||||
}
|
||||
|
||||
void
|
||||
g()
|
||||
{
|
||||
try
|
||||
{
|
||||
f ();
|
||||
}
|
||||
catch (int)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
int
|
||||
main()
|
||||
{
|
||||
fillstack ();
|
||||
g ();
|
||||
return 0;
|
||||
}
|
||||
34
gcc/testsuite/gcc.c-torture/execute/pr87623.c
Normal file
34
gcc/testsuite/gcc.c-torture/execute/pr87623.c
Normal file
@ -0,0 +1,34 @@
|
||||
/* PR middle-end/87623 */
|
||||
/* Testcase by George Thopas <george.thopas@gmail.com> */
|
||||
|
||||
struct be {
|
||||
unsigned short pad[1];
|
||||
unsigned char a;
|
||||
unsigned char b;
|
||||
} __attribute__((scalar_storage_order("big-endian")));
|
||||
|
||||
typedef struct be t_be;
|
||||
|
||||
struct le {
|
||||
unsigned short pad[3];
|
||||
unsigned char a;
|
||||
unsigned char b;
|
||||
};
|
||||
|
||||
typedef struct le t_le;
|
||||
|
||||
int a_or_b_different(t_be *x,t_le *y)
|
||||
{
|
||||
return (x->a != y->a) || (x->b != y->b);
|
||||
}
|
||||
|
||||
int main (void)
|
||||
{
|
||||
t_be x = { .a=1, .b=2 };
|
||||
t_le y = { .a=1, .b=2 };
|
||||
|
||||
if (a_or_b_different(&x,&y))
|
||||
__builtin_abort ();
|
||||
|
||||
return 0;
|
||||
}
|
||||
19
gcc/testsuite/gcc.dg/pr85859.c
Normal file
19
gcc/testsuite/gcc.dg/pr85859.c
Normal file
@ -0,0 +1,19 @@
|
||||
/* { dg-do run } */
|
||||
/* { dg-options "-ftree-tail-merge -Wno-div-by-zero -O2 -fno-dce -fno-isolate-erroneous-paths-dereference -fno-tree-dce -fno-tree-vrp" } */
|
||||
|
||||
int b, c, d, e;
|
||||
|
||||
__attribute__ ((noinline, noclone))
|
||||
int foo (short f)
|
||||
{
|
||||
f %= 0;
|
||||
return f;
|
||||
}
|
||||
|
||||
int
|
||||
main (void)
|
||||
{
|
||||
b = (unsigned char) __builtin_parity (d);
|
||||
e ? foo (0) : (long) &c;
|
||||
return 0;
|
||||
}
|
||||
14
gcc/testsuite/gcc.dg/pr87024.c
Normal file
14
gcc/testsuite/gcc.dg/pr87024.c
Normal file
@ -0,0 +1,14 @@
|
||||
/* { dg-do compile } */
|
||||
/* { dg-options "-O -fno-tree-dce" } */
|
||||
|
||||
static inline void __attribute__((always_inline))
|
||||
mp ()
|
||||
{
|
||||
(void) __builtin_va_arg_pack_len ();
|
||||
}
|
||||
|
||||
void
|
||||
ui (void)
|
||||
{
|
||||
mp ();
|
||||
}
|
||||
32
gcc/testsuite/gcc.dg/torture/pr86505.c
Normal file
32
gcc/testsuite/gcc.dg/torture/pr86505.c
Normal file
@ -0,0 +1,32 @@
|
||||
/* { dg-do run } */
|
||||
|
||||
static inline __attribute__(( __always_inline__)) int
|
||||
funA(unsigned int param, ...)
|
||||
{
|
||||
return __builtin_va_arg_pack_len();
|
||||
}
|
||||
|
||||
static inline __attribute__(( __always_inline__)) int
|
||||
funB(unsigned int param, ...)
|
||||
{
|
||||
return funA(param, 2, 4, __builtin_va_arg_pack());
|
||||
}
|
||||
|
||||
int
|
||||
testBuiltin(void)
|
||||
{
|
||||
int rc = funB(0,1,2);
|
||||
if (rc != 4)
|
||||
return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
main()
|
||||
{
|
||||
int rc = testBuiltin();
|
||||
if (rc == 1)
|
||||
__builtin_abort ();
|
||||
|
||||
return 0;
|
||||
}
|
||||
28
gcc/testsuite/gcc.target/i386/pr86627.c
Normal file
28
gcc/testsuite/gcc.target/i386/pr86627.c
Normal file
@ -0,0 +1,28 @@
|
||||
/* PR middle-end/86627 */
|
||||
/* { dg-do compile { target int128 } } */
|
||||
/* { dg-options "-O2" } */
|
||||
/* { dg-final { scan-assembler-not "call\[^\n\r]*__divti3" } } */
|
||||
|
||||
__int128_t
|
||||
f1 (__int128_t a)
|
||||
{
|
||||
return a / 2;
|
||||
}
|
||||
|
||||
__int128_t
|
||||
f2 (__int128_t a)
|
||||
{
|
||||
return a / -2;
|
||||
}
|
||||
|
||||
__int128_t
|
||||
f3 (__int128_t a)
|
||||
{
|
||||
return a / 0x4000000000000000LL;
|
||||
}
|
||||
|
||||
__int128_t
|
||||
f4 (__int128_t a)
|
||||
{
|
||||
return a / -0x4000000000000000LL;
|
||||
}
|
||||
22
gcc/testsuite/gcc.target/i386/pr87065.c
Normal file
22
gcc/testsuite/gcc.target/i386/pr87065.c
Normal file
@ -0,0 +1,22 @@
|
||||
/* PR rtl-optimization/87065 */
|
||||
/* { dg-do compile } */
|
||||
/* { dg-options "-O3 -mxop -mprefer-avx128" } */
|
||||
|
||||
int a, c, d, e;
|
||||
short *b;
|
||||
|
||||
void
|
||||
foo (void)
|
||||
{
|
||||
short *g = b;
|
||||
int h = 1;
|
||||
unsigned i;
|
||||
for (; h <= 1; h++)
|
||||
g = (short *) &c;
|
||||
for (; c; c++)
|
||||
{
|
||||
for (; i <= 1; i++)
|
||||
;
|
||||
a ^= (a > 0 <= i) + ((e += d) == 0 ?: (*g = 8));
|
||||
}
|
||||
}
|
||||
21
gcc/testsuite/gcc.target/i386/pr87550.c
Normal file
21
gcc/testsuite/gcc.target/i386/pr87550.c
Normal file
@ -0,0 +1,21 @@
|
||||
/* PR target/87550 */
|
||||
/* { dg-do compile } */
|
||||
/* { dg-options "-O2" } */
|
||||
|
||||
#include <x86intrin.h>
|
||||
|
||||
int
|
||||
foo (int x)
|
||||
{
|
||||
return __rdtsc () + __rdtsc ();
|
||||
}
|
||||
|
||||
/* { dg-final { scan-assembler-times "\trdtsc\[\n\r]" 2 } } */
|
||||
|
||||
int
|
||||
bar (int x)
|
||||
{
|
||||
return __rdpmc (0) + __rdpmc (0);
|
||||
}
|
||||
|
||||
/* { dg-final { scan-assembler-times "\trdpmc\[\n\r]" 2 } } */
|
||||
27
gcc/testsuite/gfortran.dg/generic_34.f90
Normal file
27
gcc/testsuite/gfortran.dg/generic_34.f90
Normal file
@ -0,0 +1,27 @@
|
||||
! { dg-do compile }
|
||||
!
|
||||
! PR 86116: [6/7/8/9 Regression] Ambiguous generic interface not recognised
|
||||
!
|
||||
! Contributed by martin <mscfd@gmx.net>
|
||||
|
||||
module mod
|
||||
|
||||
type :: t
|
||||
end type t
|
||||
|
||||
interface sub
|
||||
module procedure s1
|
||||
module procedure s2
|
||||
end interface
|
||||
|
||||
contains
|
||||
|
||||
subroutine s1(x) ! { dg-error "Ambiguous interfaces in generic interface" }
|
||||
type(t) :: x
|
||||
end subroutine
|
||||
|
||||
subroutine s2(x) ! { dg-error "Ambiguous interfaces in generic interface" }
|
||||
class(*), allocatable :: x
|
||||
end subroutine
|
||||
|
||||
end
|
||||
@ -1925,8 +1925,7 @@ copy_bb (copy_body_data *id, basic_block bb, int frequency_scale,
|
||||
&& id->call_stmt
|
||||
&& (decl = gimple_call_fndecl (stmt))
|
||||
&& DECL_BUILT_IN_CLASS (decl) == BUILT_IN_NORMAL
|
||||
&& DECL_FUNCTION_CODE (decl) == BUILT_IN_VA_ARG_PACK_LEN
|
||||
&& ! gimple_call_va_arg_pack_p (id->call_stmt))
|
||||
&& DECL_FUNCTION_CODE (decl) == BUILT_IN_VA_ARG_PACK_LEN)
|
||||
{
|
||||
/* __builtin_va_arg_pack_len () should be replaced by
|
||||
the number of anonymous arguments. */
|
||||
@ -1944,10 +1943,32 @@ copy_bb (copy_body_data *id, basic_block bb, int frequency_scale,
|
||||
if (POINTER_BOUNDS_P (gimple_call_arg (id->call_stmt, i)))
|
||||
nargs--;
|
||||
|
||||
count = build_int_cst (integer_type_node, nargs);
|
||||
new_stmt = gimple_build_assign (gimple_call_lhs (stmt), count);
|
||||
gsi_replace (©_gsi, new_stmt, false);
|
||||
stmt = new_stmt;
|
||||
if (!gimple_call_lhs (stmt))
|
||||
{
|
||||
/* Drop unused calls. */
|
||||
gsi_remove (©_gsi, false);
|
||||
continue;
|
||||
}
|
||||
else if (!gimple_call_va_arg_pack_p (id->call_stmt))
|
||||
{
|
||||
count = build_int_cst (integer_type_node, nargs);
|
||||
new_stmt = gimple_build_assign (gimple_call_lhs (stmt), count);
|
||||
gsi_replace (©_gsi, new_stmt, false);
|
||||
stmt = new_stmt;
|
||||
}
|
||||
else if (nargs != 0)
|
||||
{
|
||||
tree newlhs;
|
||||
if (gimple_in_ssa_p (cfun))
|
||||
newlhs = make_ssa_name (integer_type_node, NULL);
|
||||
else
|
||||
newlhs = create_tmp_reg (integer_type_node);
|
||||
count = build_int_cst (integer_type_node, nargs);
|
||||
new_stmt = gimple_build_assign (gimple_call_lhs (stmt),
|
||||
PLUS_EXPR, newlhs, count);
|
||||
gimple_call_set_lhs (stmt, newlhs);
|
||||
gsi_insert_after (©_gsi, new_stmt, GSI_NEW_STMT);
|
||||
}
|
||||
}
|
||||
else if (call_stmt
|
||||
&& id->call_stmt
|
||||
|
||||
@ -298,7 +298,15 @@ stmt_local_def (gimple *stmt)
|
||||
if (gimple_vdef (stmt) != NULL_TREE
|
||||
|| gimple_has_side_effects (stmt)
|
||||
|| gimple_could_trap_p_1 (stmt, false, false)
|
||||
|| gimple_vuse (stmt) != NULL_TREE)
|
||||
|| gimple_vuse (stmt) != NULL_TREE
|
||||
/* Copied from tree-ssa-ifcombine.c:bb_no_side_effects_p():
|
||||
const calls don't match any of the above, yet they could
|
||||
still have some side-effects - they could contain
|
||||
gimple_could_trap_p statements, like floating point
|
||||
exceptions or integer division by zero. See PR70586.
|
||||
FIXME: perhaps gimple_has_side_effects or gimple_could_trap_p
|
||||
should handle this. */
|
||||
|| is_gimple_call (stmt))
|
||||
return false;
|
||||
|
||||
def_p = SINGLE_SSA_DEF_OPERAND (stmt, SSA_OP_DEF);
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-06-15 Martin Liska <mliska@suse.cz>
|
||||
|
||||
PR bootstrap/86162
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-08-17 John David Anglin <danglin@gcc.gnu.org>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,12 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-16 Gerald Pfeifer <gerald@pfeifer.com>
|
||||
|
||||
Backport from trunk
|
||||
* io/close.c [!HAVE_UNLINK_OPEN_FILE]: Include <string.h>.
|
||||
|
||||
2018-01-03 Janne Blomqvist <jb@gcc.gnu.org>
|
||||
|
||||
Backport from trunk
|
||||
|
||||
@ -25,6 +25,9 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
|
||||
#include "io.h"
|
||||
#include "unix.h"
|
||||
#include <limits.h>
|
||||
#if !HAVE_UNLINK_OPEN_FILE
|
||||
#include <string.h>
|
||||
#endif
|
||||
|
||||
typedef enum
|
||||
{ CLOSE_DELETE, CLOSE_KEEP, CLOSE_UNSPECIFIED }
|
||||
|
||||
@ -1,3 +1,23 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-12 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
Backported from mainline
|
||||
2018-07-17 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86542
|
||||
* testsuite/libgomp.c++/pr86542.C: New test.
|
||||
|
||||
PR middle-end/86539
|
||||
* testsuite/libgomp.c++/pr86539.C: New test.
|
||||
|
||||
2018-07-26 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR middle-end/86660
|
||||
* testsuite/libgomp.c/pr86660.c: New test.
|
||||
|
||||
2018-06-26 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/86291
|
||||
|
||||
28
libgomp/testsuite/libgomp.c++/pr86539.C
Normal file
28
libgomp/testsuite/libgomp.c++/pr86539.C
Normal file
@ -0,0 +1,28 @@
|
||||
// PR middle-end/86539
|
||||
|
||||
int a[384];
|
||||
|
||||
__attribute__((noinline, noclone)) void
|
||||
foo (int &b, int &c)
|
||||
{
|
||||
#pragma omp taskloop shared (a) collapse(3)
|
||||
for (int i = 0; i < 1; i++)
|
||||
for (int *p = &b; p < &c; p++)
|
||||
for (int j = 0; j < 1; j++)
|
||||
if (p < &a[128] || p >= &a[256])
|
||||
__builtin_abort ();
|
||||
else
|
||||
p[0]++;
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
#pragma omp parallel
|
||||
#pragma omp single
|
||||
foo (a[128], a[256]);
|
||||
for (int i = 0; i < 384; i++)
|
||||
if (a[i] != (i >= 128 && i < 256))
|
||||
__builtin_abort ();
|
||||
return 0;
|
||||
}
|
||||
37
libgomp/testsuite/libgomp.c++/pr86542.C
Normal file
37
libgomp/testsuite/libgomp.c++/pr86542.C
Normal file
@ -0,0 +1,37 @@
|
||||
// PR middle-end/86542
|
||||
|
||||
struct S { int s; S (); ~S (); S (const S &); };
|
||||
S s;
|
||||
|
||||
S::S ()
|
||||
{
|
||||
}
|
||||
|
||||
S::~S ()
|
||||
{
|
||||
}
|
||||
|
||||
S::S (const S &x)
|
||||
{
|
||||
s = x.s;
|
||||
}
|
||||
|
||||
__attribute__((noinline, noclone)) void
|
||||
foo (int i, int j, int k, S s)
|
||||
{
|
||||
if (i != 0 || j != 0 || k != 0 || s.s != 12)
|
||||
__builtin_abort ();
|
||||
}
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
volatile int inc = 16, jnc = 16, knc = 16;
|
||||
s.s = 12;
|
||||
#pragma omp taskloop collapse (3) firstprivate (s)
|
||||
for (int i = 0; i < 16; i += inc)
|
||||
for (int j = 0; j < 16; j += jnc)
|
||||
for (int k = 0; k < 16; k += knc)
|
||||
foo (i, j, k, s);
|
||||
return 0;
|
||||
}
|
||||
28
libgomp/testsuite/libgomp.c/pr86660.c
Normal file
28
libgomp/testsuite/libgomp.c/pr86660.c
Normal file
@ -0,0 +1,28 @@
|
||||
/* PR middle-end/86660 */
|
||||
|
||||
#pragma omp declare target
|
||||
int v[20];
|
||||
|
||||
void
|
||||
foo (void)
|
||||
{
|
||||
if (v[7] != 2)
|
||||
__builtin_abort ();
|
||||
v[7] = 1;
|
||||
}
|
||||
#pragma omp end declare target
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
v[5] = 8;
|
||||
v[7] = 2;
|
||||
#pragma omp target map (always, tofrom: v)
|
||||
{
|
||||
foo ();
|
||||
v[5] = 3;
|
||||
}
|
||||
if (v[7] != 1 || v[5] != 3)
|
||||
__builtin_abort ();
|
||||
return 0;
|
||||
}
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-09-07 Matthias Klose <doko@ubuntu.com>
|
||||
|
||||
* include/x86_64-signal.h (HANDLE_DIVIDE_OVERFLOW): Replace
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-09-15 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR libquadmath/65757
|
||||
|
||||
@ -1,3 +1,41 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-15 Richard Biener <rguenther@suse.de>
|
||||
|
||||
Backport from mainline
|
||||
2018-03-19 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR sanitizer/84761
|
||||
* sanitizer_common/sanitizer_linux_libcdep.cc (__GLIBC_PREREQ):
|
||||
Define if not defined.
|
||||
(DL_INTERNAL_FUNCTION): Don't define.
|
||||
(InitTlsSize): For __i386__ if not compiled against glibc 2.27+
|
||||
determine at runtime whether to use regparm(3), stdcall calling
|
||||
convention for older glibcs or normal calling convention for
|
||||
newer glibcs for call to _dl_get_tls_static_info.
|
||||
|
||||
2017-09-23 Matthias Klose <doko@ubuntu.com>
|
||||
|
||||
Backported from the gcc-7-branch:
|
||||
2018-05-31 Matthias Klose <doko@ubuntu.com>
|
||||
|
||||
PR sanitizer/86012
|
||||
* sanitizer_common/sanitizer_platform_limits_posix.cc: Define
|
||||
SIZEOF_STRUCT_USTAT for 32bit sparc.
|
||||
|
||||
2017-09-21 Matthias Klose <doko@ubuntu.com>
|
||||
|
||||
Backported from the gcc-7-branch:
|
||||
2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR sanitizer/85835
|
||||
* sanitizer_common/sanitizer_platform_limits_posix.cc: Don't
|
||||
include <sys/ustat.h> for Linux.
|
||||
(SIZEOF_STRUCT_USTAT): New.
|
||||
(struct_ustat_sz): Use SIZEOF_STRUCT_USTAT for Linux.
|
||||
|
||||
2017-09-07 Matthias Klose <doko@ubuntu.com>
|
||||
|
||||
Backported from mainline
|
||||
|
||||
@ -154,14 +154,12 @@ bool SanitizerGetThreadName(char *name, int max_len) {
|
||||
#endif
|
||||
}
|
||||
|
||||
#if !SANITIZER_FREEBSD && !SANITIZER_ANDROID && !SANITIZER_GO
|
||||
static uptr g_tls_size;
|
||||
#ifndef __GLIBC_PREREQ
|
||||
#define __GLIBC_PREREQ(x, y) 0
|
||||
#endif
|
||||
|
||||
#ifdef __i386__
|
||||
# define DL_INTERNAL_FUNCTION __attribute__((regparm(3), stdcall))
|
||||
#else
|
||||
# define DL_INTERNAL_FUNCTION
|
||||
#if !SANITIZER_FREEBSD && !SANITIZER_ANDROID && !SANITIZER_GO
|
||||
static uptr g_tls_size;
|
||||
#endif
|
||||
|
||||
#if defined(__mips__) || defined(__powerpc64__)
|
||||
@ -186,16 +184,33 @@ void InitTlsSize() {
|
||||
#if !SANITIZER_FREEBSD && !SANITIZER_ANDROID && !SANITIZER_GO
|
||||
// all current supported platforms have 16 bytes stack alignment
|
||||
const size_t kStackAlign = 16;
|
||||
typedef void (*get_tls_func)(size_t*, size_t*) DL_INTERNAL_FUNCTION;
|
||||
get_tls_func get_tls;
|
||||
void *get_tls_static_info_ptr = dlsym(RTLD_NEXT, "_dl_get_tls_static_info");
|
||||
CHECK_EQ(sizeof(get_tls), sizeof(get_tls_static_info_ptr));
|
||||
internal_memcpy(&get_tls, &get_tls_static_info_ptr,
|
||||
sizeof(get_tls_static_info_ptr));
|
||||
CHECK_NE(get_tls, 0);
|
||||
size_t tls_size = 0;
|
||||
size_t tls_align = 0;
|
||||
get_tls(&tls_size, &tls_align);
|
||||
void *get_tls_static_info_ptr = dlsym(RTLD_NEXT, "_dl_get_tls_static_info");
|
||||
#if defined(__i386__) && !__GLIBC_PREREQ(2, 27)
|
||||
/* On i?86, _dl_get_tls_static_info used to be internal_function, i.e.
|
||||
__attribute__((regparm(3), stdcall)) before glibc 2.27 and is normal
|
||||
function in 2.27 and later. */
|
||||
if (!dlvsym(RTLD_NEXT, "glob", "GLIBC_2.27")) {
|
||||
typedef void (*get_tls_func)(size_t*, size_t*)
|
||||
__attribute__((regparm(3), stdcall));
|
||||
get_tls_func get_tls;
|
||||
CHECK_EQ(sizeof(get_tls), sizeof(get_tls_static_info_ptr));
|
||||
internal_memcpy(&get_tls, &get_tls_static_info_ptr,
|
||||
sizeof(get_tls_static_info_ptr));
|
||||
CHECK_NE(get_tls, 0);
|
||||
get_tls(&tls_size, &tls_align);
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
typedef void (*get_tls_func)(size_t*, size_t*);
|
||||
get_tls_func get_tls;
|
||||
CHECK_EQ(sizeof(get_tls), sizeof(get_tls_static_info_ptr));
|
||||
internal_memcpy(&get_tls, &get_tls_static_info_ptr,
|
||||
sizeof(get_tls_static_info_ptr));
|
||||
CHECK_NE(get_tls, 0);
|
||||
get_tls(&tls_size, &tls_align);
|
||||
}
|
||||
if (tls_align < kStackAlign)
|
||||
tls_align = kStackAlign;
|
||||
g_tls_size = RoundUpTo(tls_size, tls_align);
|
||||
|
||||
@ -150,7 +150,6 @@ typedef struct user_fpregs elf_fpregset_t;
|
||||
# include <sys/procfs.h>
|
||||
#endif
|
||||
#include <sys/user.h>
|
||||
#include <sys/ustat.h>
|
||||
#include <linux/cyclades.h>
|
||||
#include <linux/if_eql.h>
|
||||
#include <linux/if_plip.h>
|
||||
@ -243,7 +242,19 @@ namespace __sanitizer {
|
||||
#endif // SANITIZER_LINUX || SANITIZER_FREEBSD
|
||||
|
||||
#if SANITIZER_LINUX && !SANITIZER_ANDROID
|
||||
unsigned struct_ustat_sz = sizeof(struct ustat);
|
||||
// Use pre-computed size of struct ustat to avoid <sys/ustat.h> which
|
||||
// has been removed from glibc 2.28.
|
||||
#if defined(__aarch64__) || defined(__s390x__) || defined (__mips64) \
|
||||
|| defined(__powerpc64__) || defined(__arch64__) || defined(__sparcv9) \
|
||||
|| defined(__x86_64__)
|
||||
#define SIZEOF_STRUCT_USTAT 32
|
||||
#elif defined(__arm__) || defined(__i386__) || defined(__mips__) \
|
||||
|| defined(__powerpc__) || defined(__s390__) || defined(__sparc__)
|
||||
#define SIZEOF_STRUCT_USTAT 20
|
||||
#else
|
||||
#error Unknown size of struct ustat
|
||||
#endif
|
||||
unsigned struct_ustat_sz = SIZEOF_STRUCT_USTAT;
|
||||
unsigned struct_rlimit64_sz = sizeof(struct rlimit64);
|
||||
unsigned struct_statvfs64_sz = sizeof(struct statvfs64);
|
||||
#endif // SANITIZER_LINUX && !SANITIZER_ANDROID
|
||||
|
||||
@ -1,3 +1,7 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2017-07-04 Release Manager
|
||||
|
||||
* GCC 6.4.0 released.
|
||||
|
||||
@ -1,3 +1,178 @@
|
||||
2018-10-26 Release Manager
|
||||
|
||||
* GCC 6.5.0 released.
|
||||
|
||||
2018-10-25 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/87749
|
||||
* include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
|
||||
(basic_string::operator=(basic_string&&)): For short strings copy the
|
||||
buffer inline. Only fall back to using assign(const basic_string&) to
|
||||
do a deep copy when reallocation is needed.
|
||||
* testsuite/21_strings/basic_string/modifiers/assign/char/87749.cc:
|
||||
New test.
|
||||
* testsuite/21_strings/basic_string/modifiers/assign/char/
|
||||
move_assign_optim.cc: New test.
|
||||
* testsuite/21_strings/basic_string/modifiers/assign/wchar_t/87749.cc:
|
||||
New test.
|
||||
* testsuite/21_strings/basic_string/modifiers/assign/wchar_t/
|
||||
move_assign_optim.cc: New test.
|
||||
|
||||
2018-10-25 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
|
||||
Backport from mainline
|
||||
2018-10-23 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/87704
|
||||
* include/bits/unique_ptr.h (unique_ptr::unique_ptr(nullptr_t)): Do
|
||||
not delegate to default constructor.
|
||||
(unique_ptr<T[], D>::unique_ptr(nullptr_t)): Likewise.
|
||||
* testsuite/20_util/unique_ptr/cons/incomplete.cc: New test.
|
||||
* testsuite/20_util/unique_ptr/assign/48635_neg.cc: Adjust dg-error.
|
||||
* testsuite/20_util/unique_ptr/cons/cv_qual_neg.cc: Likewise.
|
||||
|
||||
2018-10-18 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-10-18 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/87641
|
||||
* include/bits/valarray_array.h (__valarray_sum): Use first element
|
||||
to initialize accumulator instead of value-initializing it.
|
||||
* testsuite/26_numerics/valarray/87641.cc: New test.
|
||||
|
||||
2018-10-15 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
* testsuite/22_locale/numpunct/members/char/3.cc: Adjust test to
|
||||
account for change to glibc it_IT localedata (glibc bz#10797).
|
||||
|
||||
2018-10-15 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-07-31 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/86751
|
||||
* include/bits/stl_pair.h (__pair_base): New class with deleted copy
|
||||
assignment operator.
|
||||
(pair): Derive from __pair_base.
|
||||
(pair::operator=): Remove deleted overload.
|
||||
* python/libstdcxx/v6/printers.py (StdPairPrinter): New pretty printer
|
||||
so that new base class isn't shown in GDB.
|
||||
* testsuite/20_util/pair/86751.cc: New test.
|
||||
* testsuite/20_util/pair/ref_assign.cc: New test.
|
||||
|
||||
2018-10-12 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-30 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
* include/ext/pointer.h (_Pointer_adapter): Define operators for
|
||||
pointer arithmetic using long long offsets.
|
||||
* testsuite/ext/ext_pointer/1.cc: Test pointer arithmetic using
|
||||
long long values.
|
||||
|
||||
2018-10-12 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-08-22 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/87061
|
||||
* include/experimental/regex [!_GLIBCXX_USE_CXX11_ABI]
|
||||
(experimental::pmr::match_results, experimental::pmr::cmatch)
|
||||
(experimental::pmr::smatch, experimental::pmr::wcmatch)
|
||||
(experimental::pmr::wsmatch): Do not declare for gcc4-compatible ABI,
|
||||
because COW strings don't support C++11 allocator model.
|
||||
* include/experimental/string [!_GLIBCXX_USE_CXX11_ABI]
|
||||
(experimental::pmr::basic_string, experimental::pmr::string)
|
||||
(experimental::pmr::u16string, experimental::pmr::u32string)
|
||||
(experimental::pmr::wstring): Likewise.
|
||||
|
||||
Backport from mainline
|
||||
2018-08-15 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
* include/experimental/regex: Remove begin/end macros for namespace.
|
||||
* include/experimental/string: Likewise.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_deque.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_forward_list.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_list.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_map.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_match.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_multimap.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_multiset.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_set.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_string.cc:
|
||||
New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_unordered_map.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_unordered_multimap.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_unordered_multiset.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/
|
||||
pmr_typedefs_unordered_set.cc: New test.
|
||||
* testsuite/experimental/polymorphic_allocator/pmr_typedefs_vector.cc:
|
||||
New test.
|
||||
|
||||
2018-10-12 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-07-24 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/70966
|
||||
* include/experimental/memory_resource (__get_default_resource): Use
|
||||
placement new to create an object with dynamic storage duration.
|
||||
|
||||
Backport from mainline
|
||||
2018-06-20 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/70966
|
||||
* include/experimental/memory_resource (__resource_adaptor_imp): Add
|
||||
static assertions to enforce requirements on pointer types.
|
||||
(__resource_adaptor_imp::get_allocator()): Add noexcept.
|
||||
(new_delete_resource, null_memory_resource): Return address of an
|
||||
object with dynamic storage duration.
|
||||
(__null_memory_resource): Remove.
|
||||
* testsuite/experimental/memory_resource/70966.cc: New.
|
||||
|
||||
2018-10-12 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/77854
|
||||
* doc/xml/manual/status_cxx1998.xml: Document size_type and
|
||||
difference_type for containers.
|
||||
* doc/html/*: Regenerate.
|
||||
|
||||
2018-10-12 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-05-18 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
PR libstdc++/85098
|
||||
* include/bits/regex.h [__cplusplus < 201703L] (basic_regex::icase)
|
||||
(basic_regex::nosubs, basic_regex::optimize, basic_regex::collate)
|
||||
(basic_regex::ECMAScript, basic_regex::basic, basic_regex::extended)
|
||||
(basic_regex::awk, basic_regex::grep, basic_regex::egrep): Add
|
||||
definitions.
|
||||
* include/bits/regex_automaton.h (_NFA::_M_insert_state): Adjust
|
||||
whitespace.
|
||||
* testsuite/28_regex/basic_regex/85098.cc: New
|
||||
|
||||
2018-10-08 Joseph Myers <joseph@codesourcery.com>
|
||||
|
||||
Backport from mainline
|
||||
2018-10-02 Joseph Myers <joseph@codesourcery.com>
|
||||
|
||||
* testsuite/lib/libstdc++.exp (libstdc++_init): Use
|
||||
-fno-show-column in default cxxflags.
|
||||
|
||||
2018-08-08 Jonathan Wakely <jwakely@redhat.com>
|
||||
|
||||
Backport from mainline
|
||||
|
||||
@ -121,6 +121,9 @@ This page describes the C++ support in the GCC 6 series.
|
||||
</p><p><span class="emphasis"><em>[22.*]</em></span> Anything and everything we have on locale
|
||||
implementation will be described under
|
||||
<a class="link" href="localization.html#std.localization.locales.locale" title="locale">Localization</a>.
|
||||
</p><p><span class="emphasis"><em>[23.*]</em></span> All of the containers in this clause
|
||||
define <span class="type">size_type</span> as <span class="type">std::size_t</span> and
|
||||
<span class="type">difference_type</span> as <span class="type">std::ptrdiff_t</span>.
|
||||
</p><p><span class="emphasis"><em>[26.2.8]/9</em></span> I have no idea what
|
||||
<code class="code">complex<T></code>'s <code class="code">pow(0,0)</code> returns.
|
||||
</p><p><span class="emphasis"><em>[27.4.2.4]/2</em></span> Calling
|
||||
|
||||
@ -1129,6 +1129,10 @@ This page describes the C++ support in the GCC 6 series.
|
||||
implementation will be described under
|
||||
<link linkend="std.localization.locales.locale">Localization</link>.
|
||||
</para>
|
||||
<para><emphasis>[23.*]</emphasis> All of the containers in this clause
|
||||
define <type>size_type</type> as <type>std::size_t</type> and
|
||||
<type>difference_type</type> as <type>std::ptrdiff_t</type>.
|
||||
</para>
|
||||
<para><emphasis>[26.2.8]/9</emphasis> I have no idea what
|
||||
<code>complex<T></code>'s <code>pow(0,0)</code> returns.
|
||||
</para>
|
||||
|
||||
@ -645,20 +645,29 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
|
||||
// Replace allocator if POCMA is true.
|
||||
std::__alloc_on_move(_M_get_allocator(), __str._M_get_allocator());
|
||||
|
||||
if (!__str._M_is_local()
|
||||
&& (_Alloc_traits::_S_propagate_on_move_assign()
|
||||
|| _Alloc_traits::_S_always_equal()))
|
||||
if (__str._M_is_local())
|
||||
{
|
||||
// We've always got room for a short string, just copy it.
|
||||
if (__str.size())
|
||||
this->_S_copy(_M_data(), __str._M_data(), __str.size());
|
||||
_M_set_length(__str.size());
|
||||
}
|
||||
else if (_Alloc_traits::_S_propagate_on_move_assign()
|
||||
|| _Alloc_traits::_S_always_equal()
|
||||
|| _M_get_allocator() == __str._M_get_allocator())
|
||||
{
|
||||
// Just move the allocated pointer, our allocator can free it.
|
||||
pointer __data = nullptr;
|
||||
size_type __capacity;
|
||||
if (!_M_is_local())
|
||||
{
|
||||
if (_Alloc_traits::_S_always_equal())
|
||||
{
|
||||
// __str can reuse our existing storage.
|
||||
__data = _M_data();
|
||||
__capacity = _M_allocated_capacity;
|
||||
}
|
||||
else
|
||||
else // __str can't use it, so free it.
|
||||
_M_destroy(_M_allocated_capacity);
|
||||
}
|
||||
|
||||
@ -673,8 +682,8 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
|
||||
else
|
||||
__str._M_data(__str._M_local_buf);
|
||||
}
|
||||
else
|
||||
assign(__str);
|
||||
else // Need to do a deep copy
|
||||
assign(__str);
|
||||
__str.clear();
|
||||
return *this;
|
||||
}
|
||||
|
||||
@ -785,6 +785,46 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
|
||||
_AutomatonPtr _M_automaton;
|
||||
};
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::icase;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::nosubs;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::optimize;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::collate;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::ECMAScript;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::basic;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::extended;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::awk;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::grep;
|
||||
|
||||
template<typename _Ch, typename _Tr>
|
||||
constexpr regex_constants::syntax_option_type
|
||||
basic_regex<_Ch, _Tr>::egrep;
|
||||
|
||||
/** @brief Standard regular expressions. */
|
||||
typedef basic_regex<char> regex;
|
||||
|
||||
|
||||
@ -332,7 +332,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
"Number of NFA states exceeds limit. Please use shorter regex "
|
||||
"string, or use smaller brace expression, or make "
|
||||
"_GLIBCXX_REGEX_STATE_LIMIT larger.");
|
||||
return this->size()-1;
|
||||
return this->size() - 1;
|
||||
}
|
||||
|
||||
// Eliminate dummy node in this NFA to make it compact.
|
||||
|
||||
@ -181,8 +181,18 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
struct __wrap_nonesuch : std::__nonesuch {
|
||||
explicit __wrap_nonesuch(const __nonesuch&) = delete;
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif // C++11
|
||||
|
||||
class __pair_base
|
||||
{
|
||||
#if __cplusplus >= 201103L
|
||||
template<typename _T1, typename _T2> friend struct pair;
|
||||
__pair_base() = default;
|
||||
~__pair_base() = default;
|
||||
__pair_base(const __pair_base&) = default;
|
||||
__pair_base& operator=(const __pair_base&) = delete;
|
||||
#endif // C++11
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Struct holding two objects of arbitrary type.
|
||||
@ -192,6 +202,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
*/
|
||||
template<typename _T1, typename _T2>
|
||||
struct pair
|
||||
: private __pair_base
|
||||
{
|
||||
typedef _T1 first_type; /// @c first_type is the first bound type
|
||||
typedef _T2 second_type; /// @c second_type is the second bound type
|
||||
@ -370,19 +381,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
return *this;
|
||||
}
|
||||
|
||||
pair&
|
||||
operator=(typename conditional<
|
||||
__not_<__and_<is_copy_assignable<_T1>,
|
||||
is_copy_assignable<_T2>>>::value,
|
||||
const pair&, const __wrap_nonesuch&>::type __p) = delete;
|
||||
|
||||
pair&
|
||||
operator=(typename conditional<
|
||||
__and_<is_move_assignable<_T1>,
|
||||
is_move_assignable<_T2>>::value,
|
||||
pair&&, __wrap_nonesuch&&>::type __p)
|
||||
noexcept(__and_<is_nothrow_move_assignable<_T1>,
|
||||
is_nothrow_move_assignable<_T2>>::value)
|
||||
is_nothrow_move_assignable<_T2>>::value)
|
||||
{
|
||||
first = std::forward<first_type>(__p.first);
|
||||
second = std::forward<second_type>(__p.second);
|
||||
|
||||
@ -201,7 +201,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
"rvalue deleter bound to reference"); }
|
||||
|
||||
/// Creates a unique_ptr that owns nothing.
|
||||
constexpr unique_ptr(nullptr_t) noexcept : unique_ptr() { }
|
||||
constexpr unique_ptr(nullptr_t) noexcept : _M_t()
|
||||
{ static_assert(!is_pointer<deleter_type>::value,
|
||||
"constructed with null function pointer deleter"); }
|
||||
|
||||
// Move constructors.
|
||||
|
||||
@ -491,7 +493,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
: _M_t(__u.release(), std::forward<deleter_type>(__u.get_deleter())) { }
|
||||
|
||||
/// Creates a unique_ptr that owns nothing.
|
||||
constexpr unique_ptr(nullptr_t) noexcept : unique_ptr() { }
|
||||
constexpr unique_ptr(nullptr_t) noexcept : _M_t()
|
||||
{ static_assert(!is_pointer<deleter_type>::value,
|
||||
"constructed with null function pointer deleter"); }
|
||||
|
||||
template<typename _Up, typename _Ep,
|
||||
typename = _Require<__safe_conversion_up<_Up, _Ep>>>
|
||||
|
||||
@ -341,17 +341,16 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
}
|
||||
|
||||
//
|
||||
// Compute the sum of elements in range [__f, __l)
|
||||
// Compute the sum of elements in range [__f, __l) which must not be empty.
|
||||
// This is a naive algorithm. It suffers from cancelling.
|
||||
// In the future try to specialize
|
||||
// for _Tp = float, double, long double using a more accurate
|
||||
// algorithm.
|
||||
// In the future try to specialize for _Tp = float, double, long double
|
||||
// using a more accurate algorithm.
|
||||
//
|
||||
template<typename _Tp>
|
||||
inline _Tp
|
||||
__valarray_sum(const _Tp* __f, const _Tp* __l)
|
||||
{
|
||||
_Tp __r = _Tp();
|
||||
_Tp __r = *__f++;
|
||||
while (__f != __l)
|
||||
__r += *__f++;
|
||||
return __r;
|
||||
|
||||
@ -33,7 +33,6 @@
|
||||
#include <new>
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
#include <bits/alloc_traits.h>
|
||||
#include <experimental/bits/lfts_config.h>
|
||||
|
||||
namespace std {
|
||||
@ -256,6 +255,22 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
template <typename _Alloc>
|
||||
class __resource_adaptor_imp : public memory_resource
|
||||
{
|
||||
static_assert(is_same<char,
|
||||
typename allocator_traits<_Alloc>::value_type>::value,
|
||||
"Allocator's value_type is char");
|
||||
static_assert(is_same<char*,
|
||||
typename allocator_traits<_Alloc>::pointer>::value,
|
||||
"Allocator's pointer type is value_type*");
|
||||
static_assert(is_same<const char*,
|
||||
typename allocator_traits<_Alloc>::const_pointer>::value,
|
||||
"Allocator's const_pointer type is value_type const*");
|
||||
static_assert(is_same<void*,
|
||||
typename allocator_traits<_Alloc>::void_pointer>::value,
|
||||
"Allocator's void_pointer type is void*");
|
||||
static_assert(is_same<const void*,
|
||||
typename allocator_traits<_Alloc>::const_void_pointer>::value,
|
||||
"Allocator's const_void_pointer type is void const*");
|
||||
|
||||
public:
|
||||
using allocator_type = _Alloc;
|
||||
|
||||
@ -274,7 +289,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
__resource_adaptor_imp&
|
||||
operator=(const __resource_adaptor_imp&) = default;
|
||||
|
||||
allocator_type get_allocator() const { return _M_alloc; }
|
||||
allocator_type get_allocator() const noexcept { return _M_alloc; }
|
||||
|
||||
protected:
|
||||
virtual void*
|
||||
@ -309,13 +324,13 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
private:
|
||||
// Calculate Aligned Size
|
||||
// Returns a size that is larger than or equal to __size and divisible
|
||||
// by __alignment, where __alignment is required to be the power of 2.
|
||||
// by __alignment, where __alignment is required to be a power of 2.
|
||||
static size_t
|
||||
_S_aligned_size(size_t __size, size_t __alignment)
|
||||
{ return ((__size - 1)|(__alignment - 1)) + 1; }
|
||||
|
||||
// Determine whether alignment meets one of those preconditions:
|
||||
// 1. Equals to Zero
|
||||
// 1. Equal to Zero
|
||||
// 2. Is power of two
|
||||
static bool
|
||||
_S_supported (size_t __x)
|
||||
@ -325,47 +340,50 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
};
|
||||
|
||||
// Global memory resources
|
||||
inline std::atomic<memory_resource*>&
|
||||
__get_default_resource()
|
||||
{
|
||||
static atomic<memory_resource*> _S_default_resource(new_delete_resource());
|
||||
return _S_default_resource;
|
||||
}
|
||||
|
||||
inline memory_resource*
|
||||
new_delete_resource() noexcept
|
||||
{
|
||||
static resource_adaptor<std::allocator<char>> __r;
|
||||
return static_cast<memory_resource*>(&__r);
|
||||
using type = resource_adaptor<std::allocator<char>>;
|
||||
alignas(type) static unsigned char __buf[sizeof(type)];
|
||||
static type* __r = new(__buf) type;
|
||||
return __r;
|
||||
}
|
||||
|
||||
template <typename _Alloc>
|
||||
class __null_memory_resource : private memory_resource
|
||||
{
|
||||
protected:
|
||||
void*
|
||||
do_allocate(size_t, size_t)
|
||||
{ std::__throw_bad_alloc(); }
|
||||
|
||||
void
|
||||
do_deallocate(void*, size_t, size_t) noexcept
|
||||
{ }
|
||||
|
||||
bool
|
||||
do_is_equal(const memory_resource& __other) const noexcept
|
||||
{ return this == &__other; }
|
||||
|
||||
friend memory_resource* null_memory_resource() noexcept;
|
||||
};
|
||||
|
||||
inline memory_resource*
|
||||
null_memory_resource() noexcept
|
||||
{
|
||||
static __null_memory_resource<void> __r;
|
||||
return static_cast<memory_resource*>(&__r);
|
||||
class type final : public memory_resource
|
||||
{
|
||||
void*
|
||||
do_allocate(size_t, size_t) override
|
||||
{ std::__throw_bad_alloc(); }
|
||||
|
||||
void
|
||||
do_deallocate(void*, size_t, size_t) noexcept override
|
||||
{ }
|
||||
|
||||
bool
|
||||
do_is_equal(const memory_resource& __other) const noexcept override
|
||||
{ return this == &__other; }
|
||||
};
|
||||
|
||||
alignas(type) static unsigned char __buf[sizeof(type)];
|
||||
static type* __r = new(__buf) type;
|
||||
return __r;
|
||||
}
|
||||
|
||||
// The default memory resource
|
||||
|
||||
inline std::atomic<memory_resource*>&
|
||||
__get_default_resource()
|
||||
{
|
||||
using type = atomic<memory_resource*>;
|
||||
alignas(type) static unsigned char __buf[sizeof(type)];
|
||||
static type* __r = new(__buf) type(new_delete_resource());
|
||||
return *__r;
|
||||
}
|
||||
|
||||
inline memory_resource*
|
||||
get_default_resource() noexcept
|
||||
{ return __get_default_resource().load(); }
|
||||
|
||||
@ -44,10 +44,10 @@ namespace experimental
|
||||
{
|
||||
inline namespace fundamentals_v2
|
||||
{
|
||||
#if _GLIBCXX_USE_CXX11_ABI
|
||||
namespace pmr
|
||||
{
|
||||
_GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||
_GLIBCXX_BEGIN_NAMESPACE_CXX11
|
||||
|
||||
template<typename _BidirectionalIterator>
|
||||
using match_results
|
||||
@ -59,10 +59,9 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
|
||||
typedef match_results<string::const_iterator> smatch;
|
||||
typedef match_results<wstring::const_iterator> wsmatch;
|
||||
|
||||
_GLIBCXX_END_NAMESPACE_CXX11
|
||||
_GLIBCXX_END_NAMESPACE_VERSION
|
||||
} // namespace pmr
|
||||
|
||||
#endif
|
||||
} // namespace fundamentals_v2
|
||||
} // namespace experimental
|
||||
} // namespace std
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user