summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--ChangeLog.MELT4
-rw-r--r--MAINTAINERS1
-rw-r--r--boehm-gc/ChangeLog5
-rwxr-xr-xboehm-gc/configure7
-rw-r--r--boehm-gc/configure.ac9
-rw-r--r--gcc/ChangeLog129
-rw-r--r--gcc/DATESTAMP2
-rw-r--r--gcc/builtins.c7
-rw-r--r--gcc/cfgexpand.c2
-rw-r--r--gcc/config.gcc11
-rw-r--r--gcc/config/alpha/elf.opt30
-rw-r--r--gcc/config/arm/vxworks.opt60
-rw-r--r--gcc/config/i386/cygming.opt5
-rw-r--r--gcc/config/i386/netware.opt33
-rw-r--r--gcc/config/i386/nto.opt33
-rw-r--r--gcc/config/interix.opt5
-rw-r--r--gcc/config/lm32/t-lm322
-rw-r--r--gcc/config/m32c/m32c.c3
-rw-r--r--gcc/config/m32c/m32c.h3
-rw-r--r--gcc/config/openbsd.opt5
-rw-r--r--gcc/cselib.c16
-rw-r--r--gcc/final.c7
-rw-r--r--gcc/fortran/ChangeLog11
-rw-r--r--gcc/fortran/resolve.c3
-rw-r--r--gcc/fortran/trans-expr.c2
-rw-r--r--gcc/gimple-low.c2
-rw-r--r--gcc/haifa-sched.c64
-rw-r--r--gcc/lto-wrapper.c8
-rw-r--r--gcc/opts.c3
-rw-r--r--gcc/params.def2
-rw-r--r--gcc/sched-deps.c9
-rw-r--r--gcc/sched-ebb.c4
-rw-r--r--gcc/sched-int.h17
-rw-r--r--gcc/sched-rgn.c2
-rw-r--r--gcc/testsuite/ChangeLog34
-rw-r--r--gcc/testsuite/g++.dg/torture/pr47559.C8
-rw-r--r--gcc/testsuite/gcc.dg/debug/pr47498.c11
-rw-r--r--gcc/testsuite/gcc.dg/debug/pr47501.c11
-rw-r--r--gcc/testsuite/gcc.dg/lto/20110201-1_0.c19
-rw-r--r--gcc/testsuite/gcc.dg/pr47555.c36
-rw-r--r--gcc/testsuite/gfortran.dg/class_36.f0314
-rw-r--r--gcc/testsuite/gfortran.dg/typebound_call_20.f0341
-rw-r--r--gcc/toplev.c8
-rw-r--r--gcc/tree-dump.c3
-rw-r--r--gcc/tree-flow-inline.h19
-rw-r--r--gcc/tree-inline.c2
-rw-r--r--gcc/tree-nrv.c2
-rw-r--r--gcc/tree-pass.h3
-rw-r--r--gcc/tree-ssa-live.c20
-rw-r--r--gcc/tree-ssa-loop-im.c4
-rw-r--r--libgfortran/ChangeLog9
-rwxr-xr-xlibgfortran/configure4
-rw-r--r--libgfortran/configure.ac6
-rw-r--r--libgfortran/intrinsics/time_1.h36
-rw-r--r--libgo/config.h.in4
-rw-r--r--libgo/configure28
-rw-r--r--libgo/configure.ac14
-rw-r--r--libgo/runtime/thread.c36
-rw-r--r--libjava/ChangeLog5
-rwxr-xr-xlibjava/configure11
-rw-r--r--libjava/configure.ac11
-rw-r--r--libstdc++-v3/ChangeLog19
-rw-r--r--libstdc++-v3/config/os/hpux/os_defines.h13
-rw-r--r--libstdc++-v3/include/bits/atomic_0.h28
65 files changed, 830 insertions, 139 deletions
diff --git a/ChangeLog b/ChangeLog
index 97450ce3882..f87b1eaa125 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2011-02-01 Sebastien Bourdeauducq <sebastien@milkymist.org>
+
+ * MAINTAINERS (CPU Port Maintainers): Add myself.
+
2011-01-31 Alexandre Oliva <aoliva@redhat.com>
PR libgcj/44341
diff --git a/ChangeLog.MELT b/ChangeLog.MELT
index 0c20acc6dbe..3150ee38bf6 100644
--- a/ChangeLog.MELT
+++ b/ChangeLog.MELT
@@ -1,4 +1,8 @@
+2011-02-02 Basile Starynkevitch <basile@starynkevitch.net>
+
+ MELT branch merged with trunk rev 169522
+
2011-02-01 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk rev 169468
diff --git a/MAINTAINERS b/MAINTAINERS
index cffbdb0dd46..8facbf88474 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -64,6 +64,7 @@ i386 port Uros Bizjak ubizjak@gmail.com
ia64 port Jim Wilson wilson@tuliptree.org
ia64 port Steve Ellcey sje@cup.hp.com
iq2000 port Nick Clifton nickc@redhat.com
+lm32 port Sebastien Bourdeauducq sebastien@milkymist.org
m32c port DJ Delorie dj@redhat.com
m32r port Nick Clifton nickc@redhat.com
m68hc11 port Stephane Carrez stcarrez@nerim.fr
diff --git a/boehm-gc/ChangeLog b/boehm-gc/ChangeLog
index 03a222e68c2..4a9f4766456 100644
--- a/boehm-gc/ChangeLog
+++ b/boehm-gc/ChangeLog
@@ -1,3 +1,8 @@
+2011-02-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * configure.ac: Don't use libdl on mips-sgi-irix6*.
+ * configure: Regenerate.
+
2011-01-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* configure.ac (*-*-solaris2*): Add -lrt to THREADLIBS.
diff --git a/boehm-gc/configure b/boehm-gc/configure
index 4f7490cbcc7..ef16f4b0fe5 100755
--- a/boehm-gc/configure
+++ b/boehm-gc/configure
@@ -15088,9 +15088,12 @@ fi
*) ;;
esac
-# We never want libdl on darwin. It is a fake libdl that just ends up making
-# dyld calls anyway
case "$host" in
+ # While IRIX 6 has libdl for the O32 and N32 ABIs, it's missing for N64
+ # and unnecessary everywhere.
+ mips-sgi-irix6*) ;;
+ # We never want libdl on darwin. It is a fake libdl that just ends up making
+ # dyld calls anyway
*-*-darwin*) ;;
*)
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
diff --git a/boehm-gc/configure.ac b/boehm-gc/configure.ac
index 42cd4190df9..61e12aafe67 100644
--- a/boehm-gc/configure.ac
+++ b/boehm-gc/configure.ac
@@ -1,4 +1,4 @@
-# Copyright (c) 1999, 2000, 2001, 2002, 2003, 2006, 2010 by Red Hat, Inc.
+# Copyright (c) 1999, 2000, 2001, 2002, 2003, 2006, 2010, 2011 by Red Hat, Inc.
# All rights reserved.
# Copyright 2004 Nathanael Nerode
#
@@ -312,9 +312,12 @@ case "$host" in
*) ;;
esac
-# We never want libdl on darwin. It is a fake libdl that just ends up making
-# dyld calls anyway
case "$host" in
+ # While IRIX 6 has libdl for the O32 and N32 ABIs, it's missing for N64
+ # and unnecessary everywhere.
+ mips-sgi-irix6*) ;;
+ # We never want libdl on darwin. It is a fake libdl that just ends up making
+ # dyld calls anyway
*-*-darwin*) ;;
*)
AC_CHECK_LIB(dl, dlopen, EXTRA_TEST_LIBS="$EXTRA_TEST_LIBS -ldl")
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index e5ed1d8ecf2..2af2c32edd6 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,132 @@
+2011-02-02 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47566
+ * builtins.c (builtin_save_expr): No SAVE_EXPR for SSA_NAMEs.
+
+2011-02-02 Alexandre Oliva <aoliva@redhat.com>
+
+ PR debug/47106
+ PR debug/47402
+ * tree-inline.c (declare_return_variable): Remove unused caller
+ variable.
+
+ PR debug/47106
+ PR debug/47402
+ * tree-flow-inline.h (clear_is_used, is_used_p): New.
+ * cfgexpand.c (account_used_vars_for_block): Use them.
+ * tree-nrv.c (tree_nrv): Likewise.
+ * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
+ (dump_scope_block): Likewise.
+ (remove_unused_locals): Likewise.
+
+ PR debug/47106
+ PR debug/47402
+ * tree-inline.c (declare_return_variable): Add result decl to
+ local decls only once.
+ * gimple-low.c (record_vars_into): Mark newly-created variables
+ as referenced.
+
+2011-02-02 Alexandre Oliva <aoliva@redhat.com>
+
+ PR debug/47498
+ PR debug/47501
+ PR debug/45136
+ PR debug/45130
+ * haifa-sched.c (get_ebb_head_tail): Move notes across boundary
+ debug insns.
+ (no_real_insns_p, schedule_block, set_priorities): Drop special
+ treatment of boundary debug insns.
+ * sched-deps.c (sd_init_insn, sd_finish_insn): Don't mark debug
+ insns.
+ * sched-ebb.c (schedule_ebbs): Adjust skipping of debug insns.
+ * sched-int.h (DEBUG_INSN_SCHED_P): Remove.
+ (BOUNDARY_DEBUG_INSN_P): Likewise.
+ (SCHEDULE_DEBUG_INSN_P): Likewise.
+ * sched-rgn.c (init_ready_list): Drop special treatment of
+ boundary debug insns.
+ * final.c (rest_of_clean_state): Clear notes' BB.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/openbsd.opt (assert=): New Driver option.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/i386/nto.opt: New.
+ * config.gcc (i[34567]86-*-nto-qnx*): Use i386/nto.opt.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/i386/netware.opt: New.
+ * config.gcc (i[3456x]86-*-netware*): Use i386/netware.opt.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/interix.opt (posix): New Driver option.
+
+2011-02-01 DJ Delorie <dj@redhat.com>
+
+ * config/m32c/m32c.h (PTRDIFF_TYPE): Remove extra definition.
+
+ * config/m32c/m32c.c (m32c_regno_reg_class): Return smallest reg
+ class for A0/A1.
+
+2011-02-01 Sebastian Pop <sebastian.pop@amd.com>
+
+ PR tree-optimization/47561
+ * toplev.c (process_options): Print the Graphite flags. Add
+ flag_loop_flatten to the list of options requiring Graphite.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/i386/cygming.opt (posix): New Driver option.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/arm/vxworks.opt: New.
+ * config.gcc (arm-wrs-vxworks): Use arm/vxworks.opt.
+
+2011-02-01 Joseph Myers <joseph@codesourcery.com>
+
+ * config/alpha/elf.opt: New.
+ * config.gcc (alpha*-*-linux*, alpha*-*-gnu*, alpha*-*-freebsd*,
+ alpha*-*-netbsd*, alpha*-*-openbsd*): Use alpha/elf.opt.
+
+2011-02-01 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47559
+ * tree-ssa-loop-im.c (can_sm_ref_p): Do not perform
+ store-motion on references that can throw.
+
+2011-02-01 Bernd Schmidt <bernds@codesourcery.com>
+
+ * tree-dump.c (dump_option_value_info): Add entry for TDF_CSELIB.
+ * tree-pass.h (TDF_CSELIB): New macro.
+ * cselib.c (new_cselib_val, expand_loc, cselib_expand_value_rtx_1,
+ cselib_lookup): Check for it rather than for TDF_DETAILS.
+
+2011-02-01 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR driver/47547
+ * lto-wrapper.c (run_gcc): Don't add -dumpdir if linker_output
+ is HOST_BIT_BUCKET.
+
+ * opts.c (finish_options): Don't add x_aux_base_name if it is
+ HOST_BIT_BUCKET.
+
+2011-02-01 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47555
+ Revert
+ 2010-07-15 Sebastian Pop <sebastian.pop@amd.com>
+
+ * params.def (PARAM_SCEV_MAX_EXPR_SIZE): Bump the value to 100.
+
+2011-02-01 Sebastien Bourdeauducq <sebastien@milkymist.org>
+
+ PR gcc/46692
+ * config/lm32/t-lm32: Add multilib for all CPU options.
+
2011-02-01 Richard Guenther <rguenther@suse.de>
PR tree-optimization/47541
diff --git a/gcc/DATESTAMP b/gcc/DATESTAMP
index 6c80c700c73..340ac9ee6f8 100644
--- a/gcc/DATESTAMP
+++ b/gcc/DATESTAMP
@@ -1 +1 @@
-20110201
+20110202
diff --git a/gcc/builtins.c b/gcc/builtins.c
index 5b7b673f90e..106b2ca10b0 100644
--- a/gcc/builtins.c
+++ b/gcc/builtins.c
@@ -652,9 +652,10 @@ target_char_cast (tree cst, char *p)
static tree
builtin_save_expr (tree exp)
{
- if (TREE_ADDRESSABLE (exp) == 0
- && (TREE_CODE (exp) == PARM_DECL
- || (TREE_CODE (exp) == VAR_DECL && !TREE_STATIC (exp))))
+ if (TREE_CODE (exp) == SSA_NAME
+ || (TREE_ADDRESSABLE (exp) == 0
+ && (TREE_CODE (exp) == PARM_DECL
+ || (TREE_CODE (exp) == VAR_DECL && !TREE_STATIC (exp)))))
return exp;
return save_expr (exp);
diff --git a/gcc/cfgexpand.c b/gcc/cfgexpand.c
index bb60c337084..7b1c441b966 100644
--- a/gcc/cfgexpand.c
+++ b/gcc/cfgexpand.c
@@ -1325,7 +1325,7 @@ account_used_vars_for_block (tree block, bool toplevel)
/* Expand all variables at this level. */
for (t = BLOCK_VARS (block); t ; t = DECL_CHAIN (t))
- if (var_ann (t) && var_ann (t)->used)
+ if (var_ann (t) && is_used_p (t))
size += expand_one_var (t, toplevel, false);
/* Expand all variables at containing levels. */
diff --git a/gcc/config.gcc b/gcc/config.gcc
index 0715af2470e..6ae7cd28642 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -695,30 +695,34 @@ case ${target} in
;;
alpha*-*-linux*)
tm_file="${tm_file} alpha/elf.h alpha/linux.h alpha/linux-elf.h glibc-stdint.h"
+ extra_options="${extra_options} alpha/elf.opt"
target_cpu_default="MASK_GAS"
tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee alpha/t-linux"
;;
alpha*-*-gnu*)
tm_file="$tm_file alpha/elf.h alpha/linux.h alpha/linux-elf.h gnu.h glibc-stdint.h alpha/gnu.h"
+ extra_options="${extra_options} alpha/elf.opt"
target_cpu_default="MASK_GAS"
tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee"
;;
alpha*-*-freebsd*)
tm_file="${tm_file} ${fbsd_tm_file} alpha/elf.h alpha/freebsd.h"
+ extra_options="${extra_options} alpha/elf.opt"
target_cpu_default="MASK_GAS"
tmake_file="${tmake_file} alpha/t-crtfm alpha/t-alpha alpha/t-ieee"
extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o"
;;
alpha*-*-netbsd*)
tm_file="${tm_file} netbsd.h alpha/elf.h netbsd-elf.h alpha/netbsd.h"
- extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+ extra_options="${extra_options} netbsd.opt netbsd-elf.opt \
+ alpha/elf.opt"
target_cpu_default="MASK_GAS"
tmake_file="${tmake_file} alpha/t-alpha alpha/t-ieee"
;;
alpha*-*-openbsd*)
tm_defines="${tm_defines} OBSD_HAS_DECLARE_FUNCTION_NAME OBSD_HAS_DECLARE_FUNCTION_SIZE OBSD_HAS_DECLARE_OBJECT"
tm_file="alpha/alpha.h alpha/elf.h openbsd.h openbsd-stdint.h alpha/openbsd.h openbsd-libpthread.h"
- extra_options="${extra_options} openbsd.opt"
+ extra_options="${extra_options} openbsd.opt alpha/elf.opt"
# default x-alpha is only appropriate for dec-osf.
target_cpu_default="MASK_GAS"
tmake_file="${tmake_file} alpha/t-alpha alpha/t-ieee"
@@ -770,6 +774,7 @@ arc-*-elf*)
;;
arm-wrs-vxworks)
tm_file="elfos.h arm/elf.h arm/aout.h ${tm_file} vx-common.h vxworks.h arm/vxworks.h"
+ extra_options="${extra_options} arm/vxworks.opt"
tmake_file="${tmake_file} arm/t-arm arm/t-vxworks"
;;
arm*-*-freebsd*)
@@ -1296,6 +1301,7 @@ i[3456x]86-*-netware*)
tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h tm-dwarf2.h i386/netware.h"
tmake_file="${tmake_file} i386/t-netware"
extra_objs=netware.o
+ extra_options="${extra_options} i386/netware.opt"
case /${with_ld} in
*/nwld)
extra_objs="$extra_objs nwld.o"
@@ -1313,6 +1319,7 @@ i[3456x]86-*-netware*)
;;
i[34567]86-*-nto-qnx*)
tm_file="${tm_file} i386/att.h dbxelf.h tm-dwarf2.h elfos.h i386/unix.h i386/nto.h"
+ extra_options="${extra_options} i386/nto.opt"
tmake_file="${tmake_file} i386/t-nto"
gnu_ld=yes
gas=yes
diff --git a/gcc/config/alpha/elf.opt b/gcc/config/alpha/elf.opt
new file mode 100644
index 00000000000..edafd5d37f5
--- /dev/null
+++ b/gcc/config/alpha/elf.opt
@@ -0,0 +1,30 @@
+; Alpha ELF options.
+
+; Copyright (C) 2011
+; Free Software Foundation, Inc.
+;
+; This file is part of GCC.
+;
+; GCC is free software; you can redistribute it and/or modify it under
+; the terms of the GNU General Public License as published by the Free
+; Software Foundation; either version 3, or (at your option) any later
+; version.
+;
+; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+; WARRANTY; without even the implied warranty of MERCHANTABILITY or
+; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+; for more details.
+;
+; You should have received a copy of the GNU General Public License
+; along with GCC; see the file COPYING3. If not see
+; <http://www.gnu.org/licenses/>.
+
+; See the GCC internals manual (options.texi) for a description of
+; this file's format.
+
+; Please try to keep this file in ASCII collating order.
+
+relax
+Driver
+
+; This comment is to ensure we retain the blank line above.
diff --git a/gcc/config/arm/vxworks.opt b/gcc/config/arm/vxworks.opt
new file mode 100644
index 00000000000..bc847839121
--- /dev/null
+++ b/gcc/config/arm/vxworks.opt
@@ -0,0 +1,60 @@
+; ARM VxWorks options.
+
+; Copyright (C) 2011
+; Free Software Foundation, Inc.
+;
+; This file is part of GCC.
+;
+; GCC is free software; you can redistribute it and/or modify it under
+; the terms of the GNU General Public License as published by the Free
+; Software Foundation; either version 3, or (at your option) any later
+; version.
+;
+; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+; WARRANTY; without even the implied warranty of MERCHANTABILITY or
+; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+; for more details.
+;
+; You should have received a copy of the GNU General Public License
+; along with GCC; see the file COPYING3. If not see
+; <http://www.gnu.org/licenses/>.
+
+; See the GCC internals manual (options.texi) for a description of
+; this file's format.
+
+; Please try to keep this file in ASCII collating order.
+
+t4
+Driver
+
+t4be
+Driver
+
+t4t
+Driver
+
+t4tbe
+Driver
+
+t5
+Driver
+
+t5be
+Driver
+
+t5t
+Driver
+
+t5tbe
+Driver
+
+tstrongarm
+Driver
+
+txscale
+Driver
+
+txscalebe
+Driver
+
+; This comment is to ensure we retain the blank line above.
diff --git a/gcc/config/i386/cygming.opt b/gcc/config/i386/cygming.opt
index 89d5d09d1aa..0fb325bdeea 100644
--- a/gcc/config/i386/cygming.opt
+++ b/gcc/config/i386/cygming.opt
@@ -1,6 +1,6 @@
; Cygwin- and MinGW-specific options.
-; Copyright (C) 2005, 2007, 2009, 2010 Free Software Foundation, Inc.
+; Copyright (C) 2005, 2007, 2009, 2010, 2011 Free Software Foundation, Inc.
;
; This file is part of GCC.
;
@@ -49,3 +49,6 @@ Use the GNU extension to the PE format for aligned common data
muse-libstdc-wrappers
Target Condition({defined (USE_CYGWIN_LIBSTDCXX_WRAPPERS)})
Compile code that relies on Cygwin DLL wrappers to support C++ operator new/delete replacement
+
+posix
+Driver
diff --git a/gcc/config/i386/netware.opt b/gcc/config/i386/netware.opt
new file mode 100644
index 00000000000..e1d903a2f7f
--- /dev/null
+++ b/gcc/config/i386/netware.opt
@@ -0,0 +1,33 @@
+; Netware options.
+
+; Copyright (C) 2011
+; Free Software Foundation, Inc.
+;
+; This file is part of GCC.
+;
+; GCC is free software; you can redistribute it and/or modify it under
+; the terms of the GNU General Public License as published by the Free
+; Software Foundation; either version 3, or (at your option) any later
+; version.
+;
+; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+; WARRANTY; without even the implied warranty of MERCHANTABILITY or
+; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+; for more details.
+;
+; You should have received a copy of the GNU General Public License
+; along with GCC; see the file COPYING3. If not see
+; <http://www.gnu.org/licenses/>.
+
+; See the GCC internals manual (options.texi) for a description of
+; this file's format.
+
+; Please try to keep this file in ASCII collating order.
+
+posix
+Driver
+
+pthread
+Driver
+
+; This comment is to ensure we retain the blank line above.
diff --git a/gcc/config/i386/nto.opt b/gcc/config/i386/nto.opt
new file mode 100644
index 00000000000..ddfaa90c97f
--- /dev/null
+++ b/gcc/config/i386/nto.opt
@@ -0,0 +1,33 @@
+; QNX options.
+
+; Copyright (C) 2011
+; Free Software Foundation, Inc.
+;
+; This file is part of GCC.
+;
+; GCC is free software; you can redistribute it and/or modify it under
+; the terms of the GNU General Public License as published by the Free
+; Software Foundation; either version 3, or (at your option) any later
+; version.
+;
+; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+; WARRANTY; without even the implied warranty of MERCHANTABILITY or
+; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+; for more details.
+;
+; You should have received a copy of the GNU General Public License
+; along with GCC; see the file COPYING3. If not see
+; <http://www.gnu.org/licenses/>.
+
+; See the GCC internals manual (options.texi) for a description of
+; this file's format.
+
+; Please try to keep this file in ASCII collating order.
+
+G
+Driver
+
+YP,
+Driver Joined
+
+; This comment is to ensure we retain the blank line above.
diff --git a/gcc/config/interix.opt b/gcc/config/interix.opt
index 5c95b250236..f5032996576 100644
--- a/gcc/config/interix.opt
+++ b/gcc/config/interix.opt
@@ -1,6 +1,6 @@
; Interix options.
-; Copyright (C) 2010
+; Copyright (C) 2010, 2011
; Free Software Foundation, Inc.
;
; This file is part of GCC.
@@ -30,4 +30,7 @@ Driver
G
Driver
+posix
+Driver
+
; This comment is to ensure we retain the blank line above.
diff --git a/gcc/config/lm32/t-lm32 b/gcc/config/lm32/t-lm32
index ebe377314dc..ec9a18b73a7 100644
--- a/gcc/config/lm32/t-lm32
+++ b/gcc/config/lm32/t-lm32
@@ -1,2 +1,2 @@
# for multilib
-MULTILIB_OPTIONS = mmultiply-enabled mbarrel-shift-enabled
+MULTILIB_OPTIONS = mbarrel-shift-enabled mmultiply-enabled mdivide-enabled msign-extend-enabled
diff --git a/gcc/config/m32c/m32c.c b/gcc/config/m32c/m32c.c
index 3a741392aa0..5ccaa2e335a 100644
--- a/gcc/config/m32c/m32c.c
+++ b/gcc/config/m32c/m32c.c
@@ -636,8 +636,9 @@ m32c_regno_reg_class (int regno)
case R3_REGNO:
return R3_REGS;
case A0_REGNO:
+ return A0_REGS;
case A1_REGNO:
- return A_REGS;
+ return A1_REGS;
case SB_REGNO:
return SB_REGS;
case FB_REGNO:
diff --git a/gcc/config/m32c/m32c.h b/gcc/config/m32c/m32c.h
index a953ee33a3e..5c6970ac22a 100644
--- a/gcc/config/m32c/m32c.h
+++ b/gcc/config/m32c/m32c.h
@@ -200,9 +200,6 @@ machine_function;
#undef SIZE_TYPE
#define SIZE_TYPE "unsigned int"
-#undef PTRDIFF_TYPE
-#define PTRDIFF_TYPE "int"
-
#undef WCHAR_TYPE
#define WCHAR_TYPE "long int"
diff --git a/gcc/config/openbsd.opt b/gcc/config/openbsd.opt
index b27a4689bbc..b8c8fd41698 100644
--- a/gcc/config/openbsd.opt
+++ b/gcc/config/openbsd.opt
@@ -1,6 +1,6 @@
; OpenBSD options.
-; Copyright (C) 2010
+; Copyright (C) 2010, 2011
; Free Software Foundation, Inc.
;
; This file is part of GCC.
@@ -24,6 +24,9 @@
; Please try to keep this file in ASCII collating order.
+assert=
+Driver JoinedOrMissing
+
posix
Driver
diff --git a/gcc/cselib.c b/gcc/cselib.c
index 8f5e45b08d2..d2980150c7e 100644
--- a/gcc/cselib.c
+++ b/gcc/cselib.c
@@ -1,6 +1,6 @@
/* Common subexpression elimination library for GNU compiler.
Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
+ 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
Free Software Foundation, Inc.
This file is part of GCC.
@@ -1015,7 +1015,7 @@ new_cselib_val (unsigned int hash, enum machine_mode mode, rtx x)
e->locs = 0;
e->next_containing_mem = 0;
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
{
fprintf (dump_file, "cselib value %u:%u ", e->uid, hash);
if (flag_dump_noaddr || flag_dump_unnumbered)
@@ -1132,7 +1132,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
else if (!REG_P (p->loc))
{
rtx result, note;
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
{
print_inline_rtx (dump_file, p->loc, 0);
fprintf (dump_file, "\n");
@@ -1153,7 +1153,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
if (regno != UINT_MAX)
{
rtx result;
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
fprintf (dump_file, "r%d\n", regno);
result = cselib_expand_value_rtx_1 (reg_result, evd, max_depth - 1);
@@ -1161,7 +1161,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
return result;
}
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
{
if (reg_result)
{
@@ -1302,7 +1302,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd,
bitmap_set_bit (evd->regs_active, regno);
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
fprintf (dump_file, "expanding: r%d into: ", regno);
result = expand_loc (l->elt->locs, evd, max_depth);
@@ -1367,7 +1367,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd,
{
rtx result;
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
{
fputs ("\nexpanding ", dump_file);
print_rtl_single (dump_file, orig);
@@ -1736,7 +1736,7 @@ cselib_lookup (rtx x, enum machine_mode mode, int create)
easiest setting cselib_current_insn to NULL before the call
above. */
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file && (dump_flags & TDF_CSELIB))
{
fputs ("cselib lookup ", dump_file);
print_inline_rtx (dump_file, x, 2);
diff --git a/gcc/final.c b/gcc/final.c
index 09dec08e0ea..ceb79744c41 100644
--- a/gcc/final.c
+++ b/gcc/final.c
@@ -4402,7 +4402,11 @@ rest_of_clean_state (void)
if (LABEL_P (insn))
INSN_UID (insn) = CODE_LABEL_NUMBER (insn);
else
- INSN_UID (insn) = 0;
+ {
+ if (NOTE_P (insn))
+ set_block_for_insn (insn, NULL);
+ INSN_UID (insn) = 0;
+ }
}
}
@@ -4423,7 +4427,6 @@ rest_of_clean_state (void)
&& NOTE_KIND (insn) != NOTE_INSN_BLOCK_END
&& NOTE_KIND (insn) != NOTE_INSN_CFA_RESTORE_STATE)))
print_rtl_single (final_output, insn);
-
}
if (final_output)
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog
index e05645d14af..2331b973e00 100644
--- a/gcc/fortran/ChangeLog
+++ b/gcc/fortran/ChangeLog
@@ -1,3 +1,14 @@
+2011-02-02 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/47572
+ * resolve.c (resolve_fl_variable): Handle polymorphic allocatables.
+
+2011-02-01 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/47565
+ * trans-expr.c (gfc_conv_structure): Handle constructors for procedure
+ pointer components with allocatable result.
+
2011-01-31 Janus Weil <janus@gcc.gnu.org>
PR fortran/47455
diff --git a/gcc/fortran/resolve.c b/gcc/fortran/resolve.c
index 2a0fc49571c..7f3734e8269 100644
--- a/gcc/fortran/resolve.c
+++ b/gcc/fortran/resolve.c
@@ -10063,7 +10063,8 @@ resolve_fl_variable (gfc_symbol *sym, int mp_flag)
/* Reject illegal initializers. */
if (!sym->mark && sym->value)
{
- if (sym->attr.allocatable)
+ if (sym->attr.allocatable || (sym->ts.type == BT_CLASS
+ && CLASS_DATA (sym)->attr.allocatable))
gfc_error ("Allocatable '%s' at %L cannot have an initializer",
sym->name, &sym->declared_at);
else if (sym->attr.external)
diff --git a/gcc/fortran/trans-expr.c b/gcc/fortran/trans-expr.c
index b5b6d614984..57bdb5d2318 100644
--- a/gcc/fortran/trans-expr.c
+++ b/gcc/fortran/trans-expr.c
@@ -4627,7 +4627,7 @@ gfc_conv_structure (gfc_se * se, gfc_expr * expr, int init)
components. Although the latter have a default initializer
of EXPR_NULL,... by default, the static nullify is not needed
since this is done every time we come into scope. */
- if (!c->expr || cm->attr.allocatable)
+ if (!c->expr || (cm->attr.allocatable && cm->attr.flavor != FL_PROCEDURE))
continue;
if (strcmp (cm->name, "_size") == 0)
diff --git a/gcc/gimple-low.c b/gcc/gimple-low.c
index 2c585e30266..4e492414290 100644
--- a/gcc/gimple-low.c
+++ b/gcc/gimple-low.c
@@ -907,6 +907,8 @@ record_vars_into (tree vars, tree fn)
/* Record the variable. */
add_local_decl (cfun, var);
+ if (gimple_referenced_vars (cfun))
+ add_referenced_var (var);
}
if (fn != current_function_decl)
diff --git a/gcc/haifa-sched.c b/gcc/haifa-sched.c
index bd3b84c5c23..9f7d06af6d5 100644
--- a/gcc/haifa-sched.c
+++ b/gcc/haifa-sched.c
@@ -1900,8 +1900,33 @@ get_ebb_head_tail (basic_block beg, basic_block end, rtx *headp, rtx *tailp)
beg_head = NEXT_INSN (beg_head);
while (beg_head != beg_tail)
- if (NOTE_P (beg_head) || BOUNDARY_DEBUG_INSN_P (beg_head))
+ if (NOTE_P (beg_head))
beg_head = NEXT_INSN (beg_head);
+ else if (DEBUG_INSN_P (beg_head))
+ {
+ rtx note, next;
+
+ for (note = NEXT_INSN (beg_head);
+ note != beg_tail;
+ note = next)
+ {
+ next = NEXT_INSN (note);
+ if (NOTE_P (note))
+ {
+ if (sched_verbose >= 9)
+ fprintf (sched_dump, "reorder %i\n", INSN_UID (note));
+
+ reorder_insns_nobb (note, note, PREV_INSN (beg_head));
+
+ if (BLOCK_FOR_INSN (note) != beg)
+ df_insn_change_bb (note, beg);
+ }
+ else if (!DEBUG_INSN_P (note))
+ break;
+ }
+
+ break;
+ }
else
break;
@@ -1913,8 +1938,36 @@ get_ebb_head_tail (basic_block beg, basic_block end, rtx *headp, rtx *tailp)
end_head = NEXT_INSN (end_head);
while (end_head != end_tail)
- if (NOTE_P (end_tail) || BOUNDARY_DEBUG_INSN_P (end_tail))
+ if (NOTE_P (end_tail))
end_tail = PREV_INSN (end_tail);
+ else if (DEBUG_INSN_P (end_tail))
+ {
+ rtx note, prev;
+
+ for (note = PREV_INSN (end_tail);
+ note != end_head;
+ note = prev)
+ {
+ prev = PREV_INSN (note);
+ if (NOTE_P (note))
+ {
+ if (sched_verbose >= 9)
+ fprintf (sched_dump, "reorder %i\n", INSN_UID (note));
+
+ reorder_insns_nobb (note, note, end_tail);
+
+ if (end_tail == BB_END (end))
+ BB_END (end) = note;
+
+ if (BLOCK_FOR_INSN (note) != end)
+ df_insn_change_bb (note, end);
+ }
+ else if (!DEBUG_INSN_P (note))
+ break;
+ }
+
+ break;
+ }
else
break;
@@ -1928,8 +1981,7 @@ no_real_insns_p (const_rtx head, const_rtx tail)
{
while (head != NEXT_INSN (tail))
{
- if (!NOTE_P (head) && !LABEL_P (head)
- && !BOUNDARY_DEBUG_INSN_P (head))
+ if (!NOTE_P (head) && !LABEL_P (head))
return 0;
head = NEXT_INSN (head);
}
@@ -2812,7 +2864,7 @@ schedule_block (basic_block *target_bb)
last_scheduled_insn = prev_head;
gcc_assert ((NOTE_P (last_scheduled_insn)
- || BOUNDARY_DEBUG_INSN_P (last_scheduled_insn))
+ || DEBUG_INSN_P (last_scheduled_insn))
&& BLOCK_FOR_INSN (last_scheduled_insn) == *target_bb);
/* Initialize INSN_QUEUE. Q_SIZE is the total number of insns in the
@@ -3319,7 +3371,7 @@ set_priorities (rtx head, rtx tail)
current_sched_info->sched_max_insns_priority;
rtx prev_head;
- if (head == tail && (! INSN_P (head) || BOUNDARY_DEBUG_INSN_P (head)))
+ if (head == tail && ! INSN_P (head))
gcc_unreachable ();
n_insn = 0;
diff --git a/gcc/lto-wrapper.c b/gcc/lto-wrapper.c
index 6f106a31f45..613c7b054df 100644
--- a/gcc/lto-wrapper.c
+++ b/gcc/lto-wrapper.c
@@ -392,6 +392,7 @@ run_gcc (unsigned argc, char *argv[])
if (linker_output)
{
char *output_dir, *base, *name;
+ bool bit_bucket = strcmp (linker_output, HOST_BIT_BUCKET) == 0;
output_dir = xstrdup (linker_output);
base = output_dir;
@@ -406,8 +407,11 @@ run_gcc (unsigned argc, char *argv[])
static char current_dir[] = { '.', DIR_SEPARATOR, '\0' };
output_dir = current_dir;
}
- *argv_ptr++ = "-dumpdir";
- *argv_ptr++ = output_dir;
+ if (!bit_bucket)
+ {
+ *argv_ptr++ = "-dumpdir";
+ *argv_ptr++ = output_dir;
+ }
*argv_ptr++ = "-dumpbase";
}
diff --git a/gcc/opts.c b/gcc/opts.c
index b958a091e85..9a3fb133a31 100644
--- a/gcc/opts.c
+++ b/gcc/opts.c
@@ -633,7 +633,8 @@ finish_options (struct gcc_options *opts, struct gcc_options *opts_set,
if (opts->x_dump_dir_name)
opts->x_dump_base_name = concat (opts->x_dump_dir_name,
opts->x_dump_base_name, NULL);
- else if (opts->x_aux_base_name)
+ else if (opts->x_aux_base_name
+ && strcmp (opts->x_aux_base_name, HOST_BIT_BUCKET) != 0)
{
const char *aux_base;
diff --git a/gcc/params.def b/gcc/params.def
index 7dc350af420..60d9f08422a 100644
--- a/gcc/params.def
+++ b/gcc/params.def
@@ -481,7 +481,7 @@ DEFPARAM(PARAM_IV_ALWAYS_PRUNE_CAND_SET_BOUND,
DEFPARAM(PARAM_SCEV_MAX_EXPR_SIZE,
"scev-max-expr-size",
"Bound on size of expressions used in the scalar evolutions analyzer",
- 100, 0, 0)
+ 20, 0, 0)
DEFPARAM(PARAM_OMEGA_MAX_VARS,
"omega-max-vars",
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
index 817d8f966f9..590f4deb483 100644
--- a/gcc/sched-deps.c
+++ b/gcc/sched-deps.c
@@ -715,9 +715,6 @@ sd_init_insn (rtx insn)
INSN_FORW_DEPS (insn) = create_deps_list ();
INSN_RESOLVED_FORW_DEPS (insn) = create_deps_list ();
- if (DEBUG_INSN_P (insn))
- DEBUG_INSN_SCHED_P (insn) = TRUE;
-
/* ??? It would be nice to allocate dependency caches here. */
}
@@ -727,12 +724,6 @@ sd_finish_insn (rtx insn)
{
/* ??? It would be nice to deallocate dependency caches here. */
- if (DEBUG_INSN_P (insn))
- {
- gcc_assert (DEBUG_INSN_SCHED_P (insn));
- DEBUG_INSN_SCHED_P (insn) = FALSE;
- }
-
free_deps_list (INSN_HARD_BACK_DEPS (insn));
INSN_HARD_BACK_DEPS (insn) = NULL;
diff --git a/gcc/sched-ebb.c b/gcc/sched-ebb.c
index 59b804249d9..9fbb9b96f63 100644
--- a/gcc/sched-ebb.c
+++ b/gcc/sched-ebb.c
@@ -598,9 +598,9 @@ schedule_ebbs (void)
a note or two. */
while (head != tail)
{
- if (NOTE_P (head) || BOUNDARY_DEBUG_INSN_P (head))
+ if (NOTE_P (head) || DEBUG_INSN_P (head))
head = NEXT_INSN (head);
- else if (NOTE_P (tail) || BOUNDARY_DEBUG_INSN_P (tail))
+ else if (NOTE_P (tail) || DEBUG_INSN_P (tail))
tail = PREV_INSN (tail);
else if (LABEL_P (head))
head = NEXT_INSN (head);
diff --git a/gcc/sched-int.h b/gcc/sched-int.h
index 68cfa23ee06..9077c881ce6 100644
--- a/gcc/sched-int.h
+++ b/gcc/sched-int.h
@@ -887,23 +887,6 @@ extern VEC(haifa_deps_insn_data_def, heap) *h_d_i_d;
#define IS_SPECULATION_BRANCHY_CHECK_P(INSN) \
(RECOVERY_BLOCK (INSN) != NULL && RECOVERY_BLOCK (INSN) != EXIT_BLOCK_PTR)
-/* The unchanging bit tracks whether a debug insn is to be handled
- like an insn (i.e., schedule it) or like a note (e.g., it is next
- to a basic block boundary. */
-#define DEBUG_INSN_SCHED_P(insn) \
- (RTL_FLAG_CHECK1("DEBUG_INSN_SCHED_P", (insn), DEBUG_INSN)->unchanging)
-
-/* True if INSN is a debug insn that is next to a basic block
- boundary, i.e., it is to be handled by the scheduler like a
- note. */
-#define BOUNDARY_DEBUG_INSN_P(insn) \
- (DEBUG_INSN_P (insn) && !DEBUG_INSN_SCHED_P (insn))
-/* True if INSN is a debug insn that is not next to a basic block
- boundary, i.e., it is to be handled by the scheduler like an
- insn. */
-#define SCHEDULE_DEBUG_INSN_P(insn) \
- (DEBUG_INSN_P (insn) && DEBUG_INSN_SCHED_P (insn))
-
/* Dep status (aka ds_t) of the link encapsulates information, that is needed
for speculative scheduling. Namely, it is 4 integers in the range
[0, MAX_DEP_WEAK] and 3 bits.
diff --git a/gcc/sched-rgn.c b/gcc/sched-rgn.c
index 6ed4675e550..6c4fd46a50f 100644
--- a/gcc/sched-rgn.c
+++ b/gcc/sched-rgn.c
@@ -2138,7 +2138,7 @@ init_ready_list (void)
src_head = head;
for (insn = src_head; insn != src_next_tail; insn = NEXT_INSN (insn))
- if (INSN_P (insn) && !BOUNDARY_DEBUG_INSN_P (insn))
+ if (INSN_P (insn))
try_ready (insn);
}
}
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 8164cf4c198..6b460a10efe 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,37 @@
+2011-02-02 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/47572
+ * gfortran.dg/class_36.f03: New.
+
+2011-02-02 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47566
+ * gcc.dg/lto/20110201-1_0.c: New testcase.
+
+2011-02-02 Alexandre Oliva <aoliva@redhat.com>
+
+ PR debug/47498
+ PR debug/47501
+ PR debug/45136
+ PR debug/45130
+ * debug/pr47498.c: New.
+ * debug/pr47501.c: New.
+
+2011-02-01 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47559
+ * g++.dg/torture/pr47559.C: New testcase.
+
+2011-02-01 Janus Weil <janus@gcc.gnu.org>
+
+ PR fortran/47565
+ * gfortran.dg/typebound_call_20.f03: New.
+
+2011-02-01 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/47555
+ * gcc.dg/pr47555.c: New testcase.
+
2011-02-01 Richard Guenther <rguenther@suse.de>
PR tree-optimization/47541
diff --git a/gcc/testsuite/g++.dg/torture/pr47559.C b/gcc/testsuite/g++.dg/torture/pr47559.C
new file mode 100644
index 00000000000..42dedee291c
--- /dev/null
+++ b/gcc/testsuite/g++.dg/torture/pr47559.C
@@ -0,0 +1,8 @@
+// { dg-do compile }
+// { dg-options "-std=c++0x -fnon-call-exceptions" }
+
+void foo (int *k) noexcept
+{
+ for (;;)
+ *k = 0;
+}
diff --git a/gcc/testsuite/gcc.dg/debug/pr47498.c b/gcc/testsuite/gcc.dg/debug/pr47498.c
new file mode 100644
index 00000000000..6bf1484cfaf
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/debug/pr47498.c
@@ -0,0 +1,11 @@
+/* { dg-do compile } */
+/* { dg-options "-O2 -fsched2-use-superblocks -fcompare-debug" } */
+
+int bar(void *);
+
+void foo (void *p)
+{
+ int i = 1;
+ while (i)
+ i = bar (p);
+}
diff --git a/gcc/testsuite/gcc.dg/debug/pr47501.c b/gcc/testsuite/gcc.dg/debug/pr47501.c
new file mode 100644
index 00000000000..3bfb5acc7e2
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/debug/pr47501.c
@@ -0,0 +1,11 @@
+/* { dg-do compile } */
+/* { dg-options "-Os -fmodulo-sched -fcompare-debug" } */
+
+void
+foo (void)
+{
+ unsigned numlen;
+ unsigned foldlen;
+ for (; foldlen; foldlen -= numlen)
+ foo ();
+}
diff --git a/gcc/testsuite/gcc.dg/lto/20110201-1_0.c b/gcc/testsuite/gcc.dg/lto/20110201-1_0.c
new file mode 100644
index 00000000000..f5d335572ee
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/lto/20110201-1_0.c
@@ -0,0 +1,19 @@
+/* { dg-lto-do run } */
+/* { dg-lto-options { { -O0 -flto } } } */
+/* { dg-extra-ld-options "-O2 -ffast-math -fuse-linker-plugin" } */
+/* { dg-require-linker-plugin "" } */
+
+/* We require a linker plugin because otherwise we'd need to link
+ against libm which we are not sure here has cabs on all targets.
+ This is because collect2 invokes ld on the -O0 object code
+ which does not have folded cabs. */
+
+double cabs(_Complex double);
+double __attribute__((used))
+foo (_Complex double x, int b)
+{
+ if (b)
+ x = 0;
+ return cabs(x);
+}
+int main() { return 0; }
diff --git a/gcc/testsuite/gcc.dg/pr47555.c b/gcc/testsuite/gcc.dg/pr47555.c
new file mode 100644
index 00000000000..d65265274f9
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/pr47555.c
@@ -0,0 +1,36 @@
+/* { dg-do compile } */
+/* { dg-options "-O2" } */
+
+#define FILL_BACK *ptrRGB++=0; *ptrRGB++=0; *ptrRGB++=0;
+
+
+void uncompact(unsigned char* ptrRGB, const unsigned int* ptrSrc, const unsigned char* ptrRGBcompact, int line, int nbPixLeft)
+{
+
+#define BIT_2_RGB32 \
+ if ((v & 0x00000001)){ nbPixLeft--; *ptrRGB++ = *ptrRGBcompact++; *ptrRGB++ = *ptrRGBcompact++; *ptrRGB++ = *ptrRGBcompact++; } \
+ else{ FILL_BACK } \
+ v >>= 1;
+#define BIT_2_RGB16 \
+ if ((v16 & 0x0001)){ nbPixLeft--; *ptrRGB++ = *ptrRGBcompact++; *ptrRGB++ = *ptrRGBcompact++; *ptrRGB++ = *ptrRGBcompact++; } \
+ else{ FILL_BACK } \
+ v16 >>= 1;
+
+ int x;
+ unsigned int v, *ptrSrc32bits=(unsigned int*)ptrSrc;
+ unsigned short v16,*ptrSrc16bits;
+
+ for(x=0; x<line; x++) {
+ v = *ptrSrc32bits++;
+ BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32
+ BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32
+ BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32
+ BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32 BIT_2_RGB32
+ }
+
+ ptrSrc16bits=(unsigned short *)ptrSrc32bits;
+ v16 = *ptrSrc16bits++;
+ BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16
+ BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16 BIT_2_RGB16
+
+}
diff --git a/gcc/testsuite/gfortran.dg/class_36.f03 b/gcc/testsuite/gfortran.dg/class_36.f03
new file mode 100644
index 00000000000..6911f3f04b6
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/class_36.f03
@@ -0,0 +1,14 @@
+! { dg-do compile }
+!
+! PR 47572: [OOP] Invalid: Allocatable polymorphic with init expression.
+!
+! Contributed by Edmondo Giovannozzi <edmondo.giovannozzi@gmail.com>
+! cf. http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/763785b16883ed68
+
+program scalar_allocation
+ type test
+ real :: a
+ end type
+ class (test), allocatable :: b = test(3.4) ! { dg-error "cannot have an initializer" }
+ print *,allocated(b)
+end program
diff --git a/gcc/testsuite/gfortran.dg/typebound_call_20.f03 b/gcc/testsuite/gfortran.dg/typebound_call_20.f03
new file mode 100644
index 00000000000..61eee5ba004
--- /dev/null
+++ b/gcc/testsuite/gfortran.dg/typebound_call_20.f03
@@ -0,0 +1,41 @@
+! { dg-do run }
+!
+! PR 47565: [4.6 Regression][OOP] Segfault with TBP
+!
+! Contributed by Tobias Burnus <burnus@gcc.gnu.org>
+
+module class_t
+ type :: t
+ procedure(find_y), pointer, nopass :: ppc
+ contains
+ procedure, nopass :: find_y
+ end type
+ integer, private :: count = 0
+contains
+ function find_y() result(res)
+ integer, allocatable :: res
+ allocate(res)
+ count = count + 1
+ res = count
+ end function
+end module
+
+program p
+ use class_t
+ class(t), allocatable :: this
+ integer :: y
+
+ allocate(this)
+ this%ppc => find_y
+ ! (1) ordinary procedure
+ y = find_y()
+ if (y/=1) call abort()
+ ! (2) procedure pointer component
+ y = this%ppc()
+ if (y/=2) call abort()
+ ! (3) type-bound procedure
+ y = this%find_y()
+ if (y/=3) call abort()
+end
+
+! { dg-final { cleanup-modules "class_t" } }
diff --git a/gcc/toplev.c b/gcc/toplev.c
index 06c795e0351..4669aa43ecb 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -1348,12 +1348,16 @@ process_options (void)
#ifndef HAVE_cloog
if (flag_graphite
+ || flag_graphite_identity
|| flag_loop_block
+ || flag_loop_flatten
|| flag_loop_interchange
|| flag_loop_strip_mine
- || flag_graphite_identity
|| flag_loop_parallelize_all)
- sorry ("Graphite loop optimizations cannot be used");
+ sorry ("Graphite loop optimizations cannot be used (-fgraphite, "
+ "-fgraphite-identity, -floop-block, -floop-flatten, "
+ "-floop-interchange, -floop-strip-mine, -floop-parallelize-all, "
+ "and -ftree-loop-linear)");
#endif
/* Unrolling all loops implies that standard loop unrolling must also
diff --git a/gcc/tree-dump.c b/gcc/tree-dump.c
index 7de09390561..e5fce0e1622 100644
--- a/gcc/tree-dump.c
+++ b/gcc/tree-dump.c
@@ -1,6 +1,6 @@
/* Tree-dumping functionality for intermediate representation.
Copyright (C) 1999, 2000, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
- 2010 Free Software Foundation, Inc.
+ 2010, 2011 Free Software Foundation, Inc.
Written by Mark Mitchell <mark@codesourcery.com>
This file is part of GCC.
@@ -814,6 +814,7 @@ static const struct dump_option_value_info dump_options[] =
{"raw", TDF_RAW},
{"graph", TDF_GRAPH},
{"details", TDF_DETAILS},
+ {"cselib", TDF_CSELIB},
{"stats", TDF_STATS},
{"blocks", TDF_BLOCKS},
{"vops", TDF_VOPS},
diff --git a/gcc/tree-flow-inline.h b/gcc/tree-flow-inline.h
index 1a62cdd1f44..23eb3d826de 100644
--- a/gcc/tree-flow-inline.h
+++ b/gcc/tree-flow-inline.h
@@ -569,9 +569,26 @@ static inline void
set_is_used (tree var)
{
var_ann_t ann = get_var_ann (var);
- ann->used = 1;
+ ann->used = true;
}
+/* Clear VAR's used flag. */
+
+static inline void
+clear_is_used (tree var)
+{
+ var_ann_t ann = var_ann (var);
+ ann->used = false;
+}
+
+/* Return true if VAR is marked as used. */
+
+static inline bool
+is_used_p (tree var)
+{
+ var_ann_t ann = var_ann (var);
+ return ann->used;
+}
/* Return true if T (assumed to be a DECL) is a global variable.
A variable is considered global if its storage is not automatic. */
diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c
index 24a6dd02373..8cfdb287d9c 100644
--- a/gcc/tree-inline.c
+++ b/gcc/tree-inline.c
@@ -2749,7 +2749,6 @@ declare_return_variable (copy_body_data *id, tree return_slot, tree modify_dest,
basic_block entry_bb)
{
tree callee = id->src_fn;
- tree caller = id->dst_fn;
tree result = DECL_RESULT (callee);
tree callee_type = TREE_TYPE (result);
tree caller_type;
@@ -2864,7 +2863,6 @@ declare_return_variable (copy_body_data *id, tree return_slot, tree modify_dest,
}
DECL_SEEN_IN_BIND_EXPR_P (var) = 1;
- add_local_decl (DECL_STRUCT_FUNCTION (caller), var);
/* Do not have the rest of GCC warn about this variable as it should
not be visible to the user. */
diff --git a/gcc/tree-nrv.c b/gcc/tree-nrv.c
index 8ee3b8b0a4b..32e422e5e20 100644
--- a/gcc/tree-nrv.c
+++ b/gcc/tree-nrv.c
@@ -263,7 +263,7 @@ tree_nrv (void)
DECL_HAS_VALUE_EXPR_P (found) = 1;
/* FOUND is no longer used. Ensure it gets removed. */
- var_ann (found)->used = 0;
+ clear_is_used (found);
return 0;
}
diff --git a/gcc/tree-pass.h b/gcc/tree-pass.h
index 6c551ae7697..d7b122bfd02 100644
--- a/gcc/tree-pass.h
+++ b/gcc/tree-pass.h
@@ -1,5 +1,5 @@
/* Definitions for describing one tree-ssa optimization pass.
- Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010
+ Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@redhat.com>
@@ -82,6 +82,7 @@ enum tree_dump_index
#define TDF_NOUID (1 << 20) /* omit UIDs from dumps. */
#define TDF_ALIAS (1 << 21) /* display alias information */
#define TDF_ENUMERATE_LOCALS (1 << 22) /* Enumerate locals by uid. */
+#define TDF_CSELIB (1 << 23) /* Dump cselib details. */
/* In tree-dump.c */
diff --git a/gcc/tree-ssa-live.c b/gcc/tree-ssa-live.c
index 4880a1a7bbd..d917bb99a83 100644
--- a/gcc/tree-ssa-live.c
+++ b/gcc/tree-ssa-live.c
@@ -468,7 +468,7 @@ remove_unused_scope_block_p (tree scope)
Exception are the scope blocks not containing any instructions
at all so user can't get into the scopes at first place. */
else if ((ann = var_ann (*t)) != NULL
- && ann->used)
+ && is_used_p (*t))
unused = false;
else if (TREE_CODE (*t) == LABEL_DECL && TREE_USED (*t))
/* For labels that are still used in the IL, the decision to
@@ -633,13 +633,11 @@ dump_scope_block (FILE *file, int indent, tree scope, int flags)
for (var = BLOCK_VARS (scope); var; var = DECL_CHAIN (var))
{
bool used = false;
- var_ann_t ann;
- if ((ann = var_ann (var))
- && ann->used)
- used = true;
+ if (var_ann (var))
+ used = is_used_p (var);
- fprintf (file, "%*s",indent, "");
+ fprintf (file, "%*s", indent, "");
print_generic_decl (file, var, flags);
fprintf (file, "%s\n", used ? "" : " (unused)");
}
@@ -708,7 +706,7 @@ remove_unused_locals (void)
/* Assume all locals are unused. */
FOR_EACH_REFERENCED_VAR (t, rvi)
- var_ann (t)->used = false;
+ clear_is_used (t);
/* Walk the CFG marking all referenced symbols. */
FOR_EACH_BB (bb)
@@ -769,7 +767,7 @@ remove_unused_locals (void)
var = VEC_index (tree, cfun->local_decls, srcidx);
if (TREE_CODE (var) != FUNCTION_DECL
&& (!(ann = var_ann (var))
- || !ann->used))
+ || !is_used_p (var)))
{
if (is_global_var (var))
{
@@ -801,7 +799,7 @@ remove_unused_locals (void)
if (TREE_CODE (var) == VAR_DECL
&& is_global_var (var)
&& (ann = var_ann (var)) != NULL
- && ann->used)
+ && is_used_p (var))
mark_all_vars_used (&DECL_INITIAL (var), global_unused_vars);
num = VEC_length (tree, cfun->local_decls);
@@ -827,8 +825,8 @@ remove_unused_locals (void)
if (!is_global_var (t)
&& TREE_CODE (t) != PARM_DECL
&& TREE_CODE (t) != RESULT_DECL
- && !(ann = var_ann (t))->used
- && !ann->is_heapvar)
+ && !is_used_p (t)
+ && !var_ann (t)->is_heapvar)
remove_referenced_var (t);
remove_unused_scope_block_p (DECL_INITIAL (current_function_decl));
if (dump_file && (dump_flags & TDF_DETAILS))
diff --git a/gcc/tree-ssa-loop-im.c b/gcc/tree-ssa-loop-im.c
index 30faeb9319d..57f98978223 100644
--- a/gcc/tree-ssa-loop-im.c
+++ b/gcc/tree-ssa-loop-im.c
@@ -2318,6 +2318,10 @@ can_sm_ref_p (struct loop *loop, mem_ref_p ref)
|| !for_each_index (&ref->mem, may_move_till, loop))
return false;
+ /* If it can throw fail, we do not properly update EH info. */
+ if (tree_could_throw_p (ref->mem))
+ return false;
+
/* If it can trap, it must be always executed in LOOP.
Readonly memory locations may trap when storing to them, but
tree_could_trap_p is a predicate for rvalues, so check that
diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog
index 3a51f9b1758..47ab730be5b 100644
--- a/libgfortran/ChangeLog
+++ b/libgfortran/ChangeLog
@@ -1,3 +1,12 @@
+2011-02-02 Janne Blomqvist <jb@gcc.gnu.org>
+
+ PR libfortran/47571
+ * configure: Regenerated.
+ * configure.ac: Don't add librt to LIBS.
+ * intrinsics/time_1.h (weak_gettime): Weakref trickery for
+ clock_gettime().
+ (gf_gettime): Use weak_gettime() instead of clock_gettime().
+
2011-02-01 Janne Blomqvist <jb@gcc.gnu.org>
* intrinsics/time_1.h: Include errno.h needed by fallbacks.
diff --git a/libgfortran/configure b/libgfortran/configure
index ec5c7ed999b..d052a05cdcf 100755
--- a/libgfortran/configure
+++ b/libgfortran/configure
@@ -25262,7 +25262,8 @@ fi
# At least for glibc, clock_gettime is in librt. But don't pull that
# in if it still doesn't give us the function we want.
-# This test is copied from libgomp.
+# This test is copied from libgomp, and modified to not link in -lrt
+# as libgfortran calls clock_gettime via a weak reference.
if test $ac_cv_func_clock_gettime = no; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5
$as_echo_n "checking for clock_gettime in -lrt... " >&6; }
@@ -25304,7 +25305,6 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5
$as_echo "$ac_cv_lib_rt_clock_gettime" >&6; }
if test "x$ac_cv_lib_rt_clock_gettime" = x""yes; then :
- LIBS="-lrt $LIBS"
$as_echo "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
index ed1e2cc31a1..816165988ce 100644
--- a/libgfortran/configure.ac
+++ b/libgfortran/configure.ac
@@ -486,11 +486,11 @@ AC_CHECK_LIB([m],[feenableexcept],[have_feenableexcept=yes AC_DEFINE([HAVE_FEENA
# At least for glibc, clock_gettime is in librt. But don't pull that
# in if it still doesn't give us the function we want.
-# This test is copied from libgomp.
+# This test is copied from libgomp, and modified to not link in -lrt
+# as libgfortran calls clock_gettime via a weak reference.
if test $ac_cv_func_clock_gettime = no; then
AC_CHECK_LIB(rt, clock_gettime,
- [LIBS="-lrt $LIBS"
- AC_DEFINE(HAVE_CLOCK_GETTIME, 1,
+ [AC_DEFINE(HAVE_CLOCK_GETTIME, 1,
[Define to 1 if you have the `clock_gettime' function.])])
fi
diff --git a/libgfortran/intrinsics/time_1.h b/libgfortran/intrinsics/time_1.h
index 58c51af287a..86e4331e889 100644
--- a/libgfortran/intrinsics/time_1.h
+++ b/libgfortran/intrinsics/time_1.h
@@ -189,6 +189,22 @@ gf_cputime (long *user_sec, long *user_usec, long *system_sec, long *system_usec
#define GF_CLOCK_MONOTONIC GF_CLOCK_REALTIME
#endif
+/* Weakref trickery for clock_gettime(). On Glibc, clock_gettime()
+ requires us to link in librt, which also pulls in libpthread. In
+ order to avoid this by default, only call clock_gettime() through a
+ weak reference. */
+#ifdef HAVE_CLOCK_GETTIME
+#ifdef SUPPORTS_WEAK
+static int weak_gettime (clockid_t, struct timespec *)
+ __attribute__((__weakref__("clock_gettime")));
+#else
+static inline int weak_gettime (clockid_t clk_id, struct timespec *res)
+{
+ return clock_gettime (clk_id, res);
+}
+#endif
+#endif
+
/* Arguments:
clock_id - INPUT, must be either GF_CLOCK_REALTIME or GF_CLOCK_MONOTONIC
secs - OUTPUT, seconds
@@ -208,14 +224,18 @@ gf_gettime (int clock_id __attribute__((unused)), time_t * secs,
long * nanosecs)
{
#ifdef HAVE_CLOCK_GETTIME
- struct timespec ts;
- int err;
- err = clock_gettime (clock_id, &ts);
- *secs = ts.tv_sec;
- if (nanosecs)
- *nanosecs = ts.tv_nsec;
- return err;
-#elif HAVE_GETTIMEOFDAY
+ if (weak_gettime)
+ {
+ struct timespec ts;
+ int err;
+ err = weak_gettime (clock_id, &ts);
+ *secs = ts.tv_sec;
+ if (nanosecs)
+ *nanosecs = ts.tv_nsec;
+ return err;
+ }
+#endif
+#ifdef HAVE_GETTIMEOFDAY
struct timeval tv;
int err;
err = gettimeofday (&tv, NULL);
diff --git a/libgo/config.h.in b/libgo/config.h.in
index 5422bdabd20..382362beb40 100644
--- a/libgo/config.h.in
+++ b/libgo/config.h.in
@@ -39,6 +39,10 @@
/* Define to 1 if you have the `strsignal' function. */
#undef HAVE_STRSIGNAL
+/* Define to 1 if the compiler provides the __sync_bool_compare_and_swap
+ function for uint32 */
+#undef HAVE_SYNC_BOOL_COMPARE_AND_SWAP_4
+
/* Define to 1 if you have the <syscall.h> header file. */
#undef HAVE_SYSCALL_H
diff --git a/libgo/configure b/libgo/configure
index dc5ad3fca97..ad4cc25810a 100644
--- a/libgo/configure
+++ b/libgo/configure
@@ -14099,6 +14099,34 @@ fi
done
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __sync_bool_compare_and_swap_4" >&5
+$as_echo_n "checking for __sync_bool_compare_and_swap_4... " >&6; }
+if test "${libgo_cv_func___sync_bool_compare_and_swap_4+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+typedef unsigned int uint32 __attribute__ ((mode (SI)));
+uint32 i;
+int main() { return __sync_bool_compare_and_swap (&i, 0, 1); }
+
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ libgo_cv_func___sync_bool_compare_and_swap_4=yes
+else
+ libgo_cv_func___sync_bool_compare_and_swap_4=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libgo_cv_func___sync_bool_compare_and_swap_4" >&5
+$as_echo "$libgo_cv_func___sync_bool_compare_and_swap_4" >&6; }
+if test "$libgo_cv_func___sync_bool_compare_and_swap_4" = "yes"; then
+ $as_echo "#define HAVE_SYNC_BOOL_COMPARE_AND_SWAP_4 1" >>confdefs.h
+
+fi
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler supports -minline-all-stringops" >&5
$as_echo_n "checking whether compiler supports -minline-all-stringops... " >&6; }
if test "${libgo_cv_c_stringops+set}" = set; then :
diff --git a/libgo/configure.ac b/libgo/configure.ac
index e1c0dd0e61e..6cd04d2609c 100644
--- a/libgo/configure.ac
+++ b/libgo/configure.ac
@@ -332,6 +332,20 @@ AC_CHECK_HEADERS(sys/mman.h syscall.h sys/epoll.h sys/ptrace.h sys/user.h sys/ut
AM_CONDITIONAL(HAVE_SYS_MMAN_H, test "$ac_cv_header_sys_mman_h" = yes)
AC_CHECK_FUNCS(srandom random strsignal)
+AC_CACHE_CHECK([for __sync_bool_compare_and_swap_4],
+[libgo_cv_func___sync_bool_compare_and_swap_4],
+[AC_LINK_IFELSE([
+typedef unsigned int uint32 __attribute__ ((mode (SI)));
+uint32 i;
+int main() { return __sync_bool_compare_and_swap (&i, 0, 1); }
+],
+[libgo_cv_func___sync_bool_compare_and_swap_4=yes],
+[libgo_cv_func___sync_bool_compare_and_swap_4=no])])
+if test "$libgo_cv_func___sync_bool_compare_and_swap_4" = "yes"; then
+ AC_DEFINE(HAVE_SYNC_BOOL_COMPARE_AND_SWAP_4, 1,
+ [Define to 1 if the compiler provides the __sync_bool_compare_and_swap function for uint32])
+fi
+
dnl For x86 we want to use the -minline-all-stringops option to avoid
dnl forcing a stack split when calling memcpy and friends.
AC_CACHE_CHECK([whether compiler supports -minline-all-stringops],
diff --git a/libgo/runtime/thread.c b/libgo/runtime/thread.c
index c4e7f6c72e0..b600754f64c 100644
--- a/libgo/runtime/thread.c
+++ b/libgo/runtime/thread.c
@@ -3,6 +3,7 @@
// license that can be found in the LICENSE file.
#include "runtime.h"
+#include "go-assert.h"
void
runtime_initlock(Lock *l)
@@ -75,3 +76,38 @@ runtime_destroylock(Lock *l)
{
sem_destroy(&l->sem);
}
+
+#ifndef HAVE_SYNC_BOOL_COMPARE_AND_SWAP_4
+
+// For targets which don't have the required sync support. Really
+// this should be provided by gcc itself. FIXME.
+
+static pthread_mutex_t sync_lock = PTHREAD_MUTEX_INITIALIZER;
+
+_Bool
+__sync_bool_compare_and_swap_4(uint32*, uint32, uint32)
+ __attribute__((visibility("hidden")));
+
+_Bool
+__sync_bool_compare_and_swap_4(uint32* ptr, uint32 old, uint32 new)
+{
+ int i;
+ _Bool ret;
+
+ i = pthread_mutex_lock(&sync_lock);
+ __go_assert(i == 0);
+
+ if(*ptr != old) {
+ ret = 0;
+ } else {
+ *ptr = new;
+ ret = 1;
+ }
+
+ i = pthread_mutex_unlock(&sync_lock);
+ __go_assert(i == 0);
+
+ return ret;
+}
+
+#endif
diff --git a/libjava/ChangeLog b/libjava/ChangeLog
index aa1c306ef8d..0b6ba9681cf 100644
--- a/libjava/ChangeLog
+++ b/libjava/ChangeLog
@@ -1,3 +1,8 @@
+2011-02-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * configure.ac: Don't use libdl on mips-sgi-irix6*.
+ * configure: Regenerate.
+
2011-01-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* testsuite/libjava.jni/jni.exp (gcj_jni_get_cxxflags_invocation):
diff --git a/libjava/configure b/libjava/configure
index 8ffc640c1c4..2fd20a4964e 100755
--- a/libjava/configure
+++ b/libjava/configure
@@ -23141,12 +23141,11 @@ fi
if test "$GC" = boehm; then
case "${host}" in
mips-sgi-irix6*)
- # IRIX 6 lacks a N64 libdl.so, but only the N32 (default multilib)
- # libgcj.spec is used, so override here
- SYSTEMSPEC="$SYSTEMSPEC %{!mabi=64:-ldl}"
- ;;
+ # While IRIX 6 has libdl for the O32 and N32 ABIs, the N64 one is
+ # missing. It's unnecessary anyway since dlopen lives in libc.
+ ;;
*-*-darwin*)
- ;;
+ ;;
*)
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ldl" >&5
$as_echo_n "checking for main in -ldl... " >&6; }
@@ -23185,7 +23184,7 @@ if test "x$ac_cv_lib_dl_main" = x""yes; then :
SYSTEMSPEC="$SYSTEMSPEC -ldl"
fi
- ;;
+ ;;
esac
fi
fi
diff --git a/libjava/configure.ac b/libjava/configure.ac
index 52e5d78e8cf..e5310c1c955 100644
--- a/libjava/configure.ac
+++ b/libjava/configure.ac
@@ -1460,15 +1460,14 @@ else
if test "$GC" = boehm; then
case "${host}" in
mips-sgi-irix6*)
- # IRIX 6 lacks a N64 libdl.so, but only the N32 (default multilib)
- # libgcj.spec is used, so override here
- SYSTEMSPEC="$SYSTEMSPEC %{!mabi=64:-ldl}"
- ;;
+ # While IRIX 6 has libdl for the O32 and N32 ABIs, the N64 one is
+ # missing. It's unnecessary anyway since dlopen lives in libc.
+ ;;
*-*-darwin*)
- ;;
+ ;;
*)
AC_CHECK_LIB(dl, main, SYSTEMSPEC="$SYSTEMSPEC -ldl")
- ;;
+ ;;
esac
fi
fi
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index cbb23f5cf7e..d6eac2072ee 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,15 @@
+2011-02-01 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR libstdc++/46914
+ * include/bits/atomic_0.h (_ATOMIC_STORE_, _ATOMIC_MODIFY_,
+ _ATOMIC_CMPEXCHNG_): Rename __v -> __w, and __m -> __n, to
+ avoid name conflicts.
+
+2011-02-01 Benjamin Kosnik <bkoz@redhat.com>
+
+ PR libstdc++/47560
+ * config/os/hpux/os_defines.h: Remove use of macros on namespace.
+
2011-02-01 Benjamin Kosnik <bkoz@redhat.com>
* scripts/run_doxygen: Allow doxygen 1.7.0 again.
@@ -33,6 +45,13 @@
* include/backward/auto_ptr.h: Same.
* include/backward/binders.h: Same.
+2011-01-31 Paolo Carlini <paolo.carlini@oracle.com>
+
+ * doc/html/ext/lwg-active.html: Update to Revision D73.
+ * doc/html/ext/lwg-closed.html: Likewise.
+ * doc/html/ext/lwg-defects.html: Likewise.
+ * doc/xml/manual/intro.xml: Update status of issues 408, 539, 865.
+
2011-01-30 Benjamin Kosnik <bkoz@redhat.com>
PR libstdc++/36104 part four
diff --git a/libstdc++-v3/config/os/hpux/os_defines.h b/libstdc++-v3/config/os/hpux/os_defines.h
index a41f30124af..00100005920 100644
--- a/libstdc++-v3/config/os/hpux/os_defines.h
+++ b/libstdc++-v3/config/os/hpux/os_defines.h
@@ -1,6 +1,6 @@
// Specific definitions for HPUX -*- C++ -*-
-// Copyright (C) 2000, 2002, 2004, 2005, 2008, 2009, 2010
+// Copyright (C) 2000, 2002, 2004, 2005, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
@@ -37,11 +37,6 @@
// Use macro form of ctype functions to ensure __SB_masks is defined.
#define _SB_CTYPE_MACROS 1
-// This would be defaulted in the main c++config header if we didn't
-// define it here, but it has to be defined before we can use the
-// namespace macros, so we have to define it to nothing here instead.
-#define _GLIBCXX_PSEUDO_VISIBILITY(V)
-
/* HP-UX, for reasons unknown choose to use a different name for
the string to [unsigned] long long conversion routines.
@@ -63,9 +58,8 @@
We also force _GLIBCXX_USE_LONG_LONG here so that we don't have
to bastardize configure to deal with this sillyness. */
-namespace std _GLIBCXX_VISIBILITY(default)
+namespace std
{
-_GLIBCXX_BEGIN_NAMESPACE_VERSION
_GLIBCXX_BEGIN_EXTERN_C
#ifndef __LP64__
@@ -81,8 +75,7 @@ _GLIBCXX_BEGIN_EXTERN_C
#endif
_GLIBCXX_END_EXTERN_C
-_GLIBCXX_END_NAMESPACE_VERSION
-} // namespace
+} // namespace std
#define _GLIBCXX_USE_LONG_LONG 1
diff --git a/libstdc++-v3/include/bits/atomic_0.h b/libstdc++-v3/include/bits/atomic_0.h
index 42ff462701f..02fa9695d95 100644
--- a/libstdc++-v3/include/bits/atomic_0.h
+++ b/libstdc++-v3/include/bits/atomic_0.h
@@ -1,6 +1,6 @@
// -*- C++ -*- header.
-// Copyright (C) 2008, 2009, 2010
+// Copyright (C) 2008, 2009, 2010, 2011
// Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
@@ -68,41 +68,41 @@ namespace __atomic0
atomic_flag_clear_explicit(__g, __x); \
__r; })
-#define _ATOMIC_STORE_(__a, __m, __x) \
+#define _ATOMIC_STORE_(__a, __n, __x) \
({typedef __typeof__(_ATOMIC_MEMBER_) __i_type; \
__i_type* __p = &_ATOMIC_MEMBER_; \
- __typeof__(__m) __v = (__m); \
+ __typeof__(__n) __w = (__n); \
__atomic_flag_base* __g = __atomic_flag_for_address(__p); \
__atomic_flag_wait_explicit(__g, __x); \
- *__p = __v; \
+ *__p = __w; \
atomic_flag_clear_explicit(__g, __x); \
- __v; })
+ __w; })
-#define _ATOMIC_MODIFY_(__a, __o, __m, __x) \
+#define _ATOMIC_MODIFY_(__a, __o, __n, __x) \
({typedef __typeof__(_ATOMIC_MEMBER_) __i_type; \
__i_type* __p = &_ATOMIC_MEMBER_; \
- __typeof__(__m) __v = (__m); \
+ __typeof__(__n) __w = (__n); \
__atomic_flag_base* __g = __atomic_flag_for_address(__p); \
__atomic_flag_wait_explicit(__g, __x); \
__i_type __r = *__p; \
- *__p __o __v; \
+ *__p __o __w; \
atomic_flag_clear_explicit(__g, __x); \
__r; })
-#define _ATOMIC_CMPEXCHNG_(__a, __e, __m, __x) \
+#define _ATOMIC_CMPEXCHNG_(__a, __e, __n, __x) \
({typedef __typeof__(_ATOMIC_MEMBER_) __i_type; \
__i_type* __p = &_ATOMIC_MEMBER_; \
__typeof__(__e) __q = (__e); \
- __typeof__(__m) __v = (__m); \
+ __typeof__(__n) __w = (__n); \
bool __r; \
__atomic_flag_base* __g = __atomic_flag_for_address(__p); \
__atomic_flag_wait_explicit(__g, __x); \
__i_type __t = *__p; \
if (*__q == __t) \
- { \
- *__p = (__i_type)__v; \
- __r = true; \
- } \
+ { \
+ *__p = (__i_type)__w; \
+ __r = true; \
+ } \
else { *__q = __t; __r = false; } \
atomic_flag_clear_explicit(__g, __x); \
__r; })