/cp
2018-04-05 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84792
* decl.c (grokdeclarator): Fix diagnostic about typedef name used
as nested-name-specifier, keep type and TREE_TYPE (decl) in sync.
/testsuite
2018-04-05 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84792
* g++.dg/other/pr84792-1.C: New.
* g++.dg/other/pr84792-2.C: Likewise.
From-SVN: r259136
2018-04-05 Tom de Vries <tom@codesourcery.com>
PR target/85204
* config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
cond jump.
* testsuite/libgomp.oacc-c-c++-common/broadcast-1.c: New test.
From-SVN: r259125
With concepts, we accept auto in explicit template arguments, but we
should only accept them for template classes. Passing them to
template functions or variables is not allowed. So, reject it, at
parse time if possible, at specialization time otherwise.
for gcc/cp/ChangeLog
PR c++/84979
* pt.c (check_auto_in_tmpl_args): New.
(tsubst_qualified_id): Use it to reject template args
referencing auto for non-type templates.
* parser.c (cp_parser_template_id): Likewise.
* cp-tree.h (check_auto_in_tmpl_args): Declare.
* typeck2.c (build_functional_cast): Report correct location
for invalid use of auto.
for gcc/testsuite/ChangeLog
PR c++/84979
* g++.dg/concepts/pr84979.C: New.
* g++.dg/concepts/pr84979-2.C: New.
* g++.dg/concepts/pr84979-3.C: New.
From-SVN: r259124
PR inline-asm/85172
* constexpr.c (cxx_eval_builtin_function_call): For calls to
builtin_valid_in_constant_expr_p functions, don't call
cxx_eval_constant_expression if argument is not
potential_constant_expression.
* g++.dg/ext/builtin13.C: New test.
* g++.dg/ext/atomic-4.C: New test.
From-SVN: r259104
__builtin_cmse_nonsecure_caller implementation returns true in almost
all cases due to 2 separate bugs:
* gen_addsi is used instead of gen_andsi to retrieve the lsb
* the lsb boolean value is not negated but the specification says
the intrinsic should return true for a nonsecure caller and a
nonsecure caller is characterized with LR's lsb being 0
This was not caught due to (1) lack of runtime test and (2) the existing
RTL scan not taking into account that '.' matches newline in Tcl regular
expressions.
This commit fixes the implementation issues and improves testing of
cmse_nonsecure_caller by (1) adding a runtime test for the secure caller
case and (2) looking for an SET insn of an AND expression in the right
function. This leaves the nonsecure caller case only partly tested
since the exact value being AND and the negation are not covered by the
scan and the existing test infrastructure does not allow 2 separate
compilation and link to be performed. It is enough though to catch the
current incorrect behavior.
The commit also reorganize the scan directives in cmse-1.c to more
easily identify what function they are intended to test in the file.
2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
gcc/
PR target/85203
* config/arm/arm-builtins.c (arm_expand_builtin): Change
expansion to perform a bitwise AND of the argument followed by a
boolean negation of the result.
gcc/testsuite/
PR target/85203
* gcc.target/arm/cmse/cmse-1.c: Tighten cmse_nonsecure_caller RTL scan
to match a single insn of the baz function. Move scan directives at
the end of the file below the functions they are trying to test for
better readability.
* gcc.target/arm/cmse/cmse-16.c: New testcase.
From-SVN: r259097
PR other/85161
* elf.c (elf_zlib_fetch): Fix up predefined macro names in test for
big endian, only use 32-bit loads if endianity macros are predefined
and indicate big or little endian.
From-SVN: r259096
gcc/
PR rtl-optimization/84878
* ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
the basic block. Assert the use reference is not artificial and that
it has an associated insn.
gcc/testsuite/
PR rtl-optimization/84878
* gcc.target/powerpc/pr84878.c: New test.
From-SVN: r259085
we shouldn't claim string overflows for character arrays at
end of structures; the code that tries to avoid these
accidentally passed the address of the accessed member to
array_at_struct_end_p(), but that one wants the component_ref
or array_ref itself. Needs updating of one testcase that
incorrectly expected warning to occur in this situation.
From-SVN: r259083
PR testsuite/85189
* g++.dg/inherit/override-attribs.C: Use dg-message instead of dg-error
for the diagnostics of overridden functions. Adjust for new wording.
From-SVN: r259082
2018-04-04 Richard Biener <rguenther@suse.de>
PR lto/85176
* dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
from contexts for DINFO_LEVEL_TERSE and below.
* g++.dg/lto/pr85176_0.C: New testcase.
From-SVN: r259080
2018-04-04 Martin Liska <mliska@suse.cz>
PR sanitizer/85174
* c-c++-common/asan/pointer-compare-1.c: Disable section anchors
and msdata as a workaround for powerpc.
From-SVN: r259074