Re: [PATCH, rtl-optimization]: Fix post-reload compare elimination pre-pass
On Sat, Feb 11, 2012 at 11:01 PM, Richard Henderson r...@redhat.com wrote: * compare-elim.c (find_comparisons_in_bb): Eliminate only compares having mode compatible with the mode of previous compare. Substitute compare mode of previous compare with the mode, compatible with eliminated and previous compare. This patch is ok for 4.8. Unfortunately, we need to update all uses of flag register with a new, compatible mode, as well, similar to how compatible mode is handled in CSE2 pass with cse_condition_code_reg in cse.c We do? What subsequent pass really cares? Yes, please see an example in [1] how CSE2 pass handles this. I don't know if this is necessary, but when we merge arithmetic insn with compare, we _do_ update the flags users, in the same way as CSE2 pass. What goes wrong leaving things as they are? x86 tolerates wrong modes in flags users, so as far as x86 is concerned, this is allowed. But I don't know if wrong, although compatible modes, should be generated from a generic pass. [1] http://gcc.gnu.org/ml/gcc-patches/2012-02/msg00547.htm Uros.
Re: [PATCH] disable __size_t macro on GNU/kFreeBSD
El 12 de febrer de 2012 1:09, Gerald Pfeifer ger...@pfeifer.com ha escrit: Given that both Mike and me considered this patch on the obvious side, I now committed the following variation thereof on trunk. Thanks! -- Robert Millan
Re: [libitm] Link with -litm and -pthread
On Sat, Feb 11, 2012 at 08:23:45PM +0100, Eric Botcazou wrote: I missed the regeneration of libitm/configure the first time. The p2.diff with the regenerated libitm/configure passes make check in libitm now on x86_64-apple-darwin11... Great, thanks for the testing. Eric, The full regression tests show no new failures on x86_64-apple-darwin11... http://gcc.gnu.org/ml/gcc-testresults/2012-02/msg01063.html Jack -- Eric Botcazou
Re: [wwwdocs] update gcc-4.7/changes.html
On Wed, 8 Feb 2012, Jonathan Wakely wrote: Add note on thread improvements to libstdc++ changes. Nice. I have a hunch that many will be interested to learn which targets are now benefiting from this. Do you have a list, even if not complete to add there? Gerald Index: changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.75 diff -u -r1.75 changes.html --- changes.html5 Feb 2012 15:11:23 - 1.75 +++ changes.html8 Feb 2012 00:42:40 - @@ -412,6 +412,7 @@ li uses-allocator construction for codetuple/code; /li li codevector/code meets the allocator-aware container requirements; /li li replacing codemonotonic_clock/code with codesteady_clock/code; /li + li enabling the thread support library on a wider range of targets; /li li many small improvements to conform to the FDIS. /li /ul /li
[Patch, fortran] PR50981 correctly handle absent arrays as actual argument to elemental procedures
Hello, there was no specific handling for absent arrays passed as argument to elemental procedures. So, because of scalarisation, we were passing an array element reference of a NULL pointer which was failing. These patches add a conditional to pass NULL when the data pointer is NULL. Normally, it would be best to have the conditional moved out of the loop. However, for fear of combinatorial explosion and to avoid extra complexity when there is more than one optional argument, I have left the conditional in the loop, and hope that the middle-end will do the right thing. The first patch moves the recently added `can_be_null_ref' field out of the scalar-only part of the data union in the gfc_ss_info struct, and also moves the code setting it out of the scalar-only block in gfc_walk_elemental_function_args. The second patch adds the conditional in gfc_conv_procedure_call. We need to make sure to save the value of se-ss, as gfc_conv_tmp_array_ref or gfc_conv_expr_reference will advance it to the next in the chain. Otherwise nothing special. Regression tested on x86_64-unknown-freebsd9.0. OK for trunk? Mikael 2012-02-12 Mikael Morin mik...@gcc.gnu.org * trans.h (struct gfc_ss_info): Move can_be_null_ref component from the data::scalar subcomponent to the toplevel. * trans-expr.c (gfc_conv_expr): Update component reference. * trans-array.c (gfc_add_loop_ss_code): Ditto. (gfc_walk_elemental_function_args): Ditto. Move the conditional setting the field out of the scalar-only block. diff --git a/trans-array.c b/trans-array.c index bbe5afe..b54c95b 100644 --- a/trans-array.c +++ b/trans-array.c @@ -2448,7 +2448,7 @@ gfc_add_loop_ss_code (gfc_loopinfo * loop, gfc_ss * ss, bool subscript, case GFC_SS_REFERENCE: /* Scalar argument to elemental procedure. */ gfc_init_se (se, NULL); - if (ss_info-data.scalar.can_be_null_ref) + if (ss_info-can_be_null_ref) { /* If the actual argument can be absent (in other words, it can be a NULL reference), don't try to evaluate it; pass instead @@ -8493,17 +8493,18 @@ gfc_walk_elemental_function_args (gfc_ss * ss, gfc_actual_arglist *arg, newss = gfc_get_scalar_ss (head, arg-expr); newss-info-type = type; - if (dummy_arg != NULL - dummy_arg-sym-attr.optional - arg-expr-expr_type == EXPR_VARIABLE - (gfc_expr_attr (arg-expr).optional - || gfc_expr_attr (arg-expr).allocatable - || gfc_expr_attr (arg-expr).pointer)) - newss-info-data.scalar.can_be_null_ref = true; } else scalar = 0; + if (dummy_arg != NULL + dummy_arg-sym-attr.optional + arg-expr-expr_type == EXPR_VARIABLE + (gfc_expr_attr (arg-expr).optional + || gfc_expr_attr (arg-expr).allocatable + || gfc_expr_attr (arg-expr).pointer)) + newss-info-can_be_null_ref = true; + head = newss; if (!tail) { diff --git a/trans-expr.c b/trans-expr.c index ec21838..5bca3d6 100644 --- a/trans-expr.c +++ b/trans-expr.c @@ -5457,7 +5457,7 @@ gfc_conv_expr (gfc_se * se, gfc_expr * expr) se-expr = ss_info-data.scalar.value; /* If the reference can be NULL, the value field contains the reference, not the value the reference points to (see gfc_add_loop_ss_code). */ - if (ss_info-data.scalar.can_be_null_ref) + if (ss_info-can_be_null_ref) se-expr = build_fold_indirect_ref_loc (input_location, se-expr); se-string_length = ss_info-string_length; diff --git a/trans.h b/trans.h index e685a84..8beefe1 100644 --- a/trans.h +++ b/trans.h @@ -198,9 +198,6 @@ typedef struct gfc_ss_info struct { tree value; - /* Tells whether the reference can be null in the GFC_SS_REFERENCE case. - Used to handle elemental procedures' optional arguments. */ - bool can_be_null_ref; } scalar; @@ -223,6 +220,11 @@ typedef struct gfc_ss_info /* Suppresses precalculation of scalars in WHERE assignments. */ unsigned where:1; + + /* Tells whether the SS is for an actual argument which can be a NULL + reference. In other words, the associated dummy argument is OPTIONAL. + Used to handle elemental procedures. */ + bool can_be_null_ref; } gfc_ss_info; 2012-02-12 Mikael Morin mik...@gcc.gnu.org * trans-expr.c (gfc_conv_procedure_call): Save se-ss's value. Handle the case of unallocated arrays passed to elemental procedures. diff --git a/trans-expr.c b/trans-expr.c index 5bca3d6..18ce1a7 100644 --- a/trans-expr.c +++ b/trans-expr.c @@ -3522,12 +3522,16 @@ gfc_conv_procedure_call (gfc_se * se, gfc_symbol * sym, } else if (se-ss se-ss-info-useflags) { + gfc_ss *ss; + + ss = se-ss; + /* An elemental function inside a scalarized loop. */ gfc_init_se (parmse, se); parm_kind = ELEMENTAL; - if (se-ss-dimen 0 e-expr_type == EXPR_VARIABLE - se-ss-info-data.array.ref == NULL) + if (ss-dimen 0 e-expr_type ==
[wwwdocs] Rotate news
Applied. Gerald Index: index.html === RCS file: /cvs/gcc/wwwdocs/htdocs/index.html,v retrieving revision 1.832 diff -u -3 -p -r1.832 index.html --- index.html 8 Feb 2012 23:31:02 - 1.832 +++ index.html 12 Feb 2012 18:54:49 - @@ -92,35 +92,6 @@ project/a. Hosting is donated by the ddA port for Adapteva's Epiphany multicore processor has been contributed by Embecosm./dd -dtspana href=gcc-4.6/GCC 4.6.2/a released/span -span class=date[2011-10-26]/span/dt -dd/dd - -dtspanOpenMP v3.1/span -span class=date[2011-08-02]/span/dt -ddAn implementation of the a -href=http://www.openmp.org/mp-documents/OpenMP3.1.pdf;OpenMP v3.1/a -parallel programming interface for C, C++ and Fortran has been added. -Code was contributed by Jakub Jelinek of Red Hat, Inc. and -Tobias Burnus./dd - -dtspanTI C6X processor support/span -span class=date[2011-07-15]/span/dt -ddA port for the TI C6X family of processors has been contributed by -CodeSourcery./dd - -dtspana href=gcc-4.3/GCC 4.3.6/a released/span -span class=date[2011-06-27]/span/dt -dd/dd - -dtspana href=gcc-4.6/GCC 4.6.1/a released/span -span class=date[2011-06-27]/span/dt -dd/dd - -dtspana href=gcc-4.5/GCC 4.5.3/a released/span -span class=date[2011-04-28]/span/dt -dd/dd - /dl div Index: news.html === RCS file: /cvs/gcc/wwwdocs/htdocs/news.html,v retrieving revision 1.131 diff -u -3 -p -r1.131 news.html --- news.html 13 Nov 2011 14:26:47 - 1.131 +++ news.html 12 Feb 2012 18:54:53 - @@ -14,6 +14,35 @@ !-- ATTENTION: This page is for *OLD* news! Latest news goes first. -- +dtspana href=gcc-4.6/GCC 4.6.2/a released/span +span class=date[2011-10-26]/span/dt +dd/dd + +dtspanOpenMP v3.1/span +span class=date[2011-08-02]/span/dt +ddAn implementation of the a +href=http://www.openmp.org/mp-documents/OpenMP3.1.pdf;OpenMP v3.1/a +parallel programming interface for C, C++ and Fortran has been added. +Code was contributed by Jakub Jelinek of Red Hat, Inc. and +Tobias Burnus./dd + +dtspanTI C6X processor support/span +span class=date[2011-07-15]/span/dt +ddA port for the TI C6X family of processors has been contributed by +CodeSourcery./dd + +dtspana href=gcc-4.3/GCC 4.3.6/a released/span +span class=date[2011-06-27]/span/dt +dd/dd + +dtspana href=gcc-4.6/GCC 4.6.1/a released/span +span class=date[2011-06-27]/span/dt +dd/dd + +dtspana href=gcc-4.5/GCC 4.5.3/a released/span +span class=date[2011-04-28]/span/dt +dd/dd + dtspana href=gcc-4.4/GCC 4.4.6/a released/span span class=date[2011-04-16]/span/dt
[wwwdocs] Shorten rationale for development plan
This was totally suitable for when it was written; us now having had this in place for ages and approaching GCC 4.7, make this a bit shorter, by about a fourth, and make the context in time more explicit. Applied. Gerald Index: develop.html === RCS file: /cvs/gcc/wwwdocs/htdocs/develop.html,v retrieving revision 1.120 diff -u -3 -p -r1.120 develop.html --- develop.html2 Jan 2012 11:52:41 - 1.120 +++ develop.html12 Feb 2012 18:50:55 - @@ -26,21 +26,16 @@ rejected by the a href=steering.html pstrongRationale/strong/p -pIt has been difficult for us to make consistent, high-quality -releases that support a wide variety of targets. In particular, GCC -3.0 achieved a high standard of quality on many targets, but was by no -means perfect, and failed to support as many targets as we would have -liked./p - -pIn addition, the release was late relative to original scheduling -estimates. And, the time between the GCC 2.95 and GCC 3.0 releases -was longer than everyone would have liked. We think that we will -better serve the user community by making releases somewhat more -frequently, and on a consistent schedule./p - -pIn addition, a consistent schedule will make it possible for a -Release Manager to better understand his or her time commitment will -be when he or she agrees to take the job./p +pLate in the GCC 2.x series and then GCC 3.x we struggled making +consistent, high-quality releases for as wide a variety of targets +as we would have liked. GCC 3.0 came late relative to original +scheduling estimates and the time between the GCC 2.95 and GCC 3.0 +releases was longer than everyone would have liked./p + +pWe think that more frequent releases on a consistent schedule +serve our user communities better. In addition, a consistent schedule +makes it possible for Release Managers to better understand what they +are signing up for./p h2Development Methodology/h2
New Swedish PO file for 'gcc' (version 4.7-b20120128)
Hello, gentle maintainer. This is a message from the Translation Project robot. A revised PO file for textual domain 'gcc' has been submitted by the Swedish team of translators. The file is available at: http://translationproject.org/latest/gcc/sv.po (This file, 'gcc-4.7-b20120128.sv.po', has just now been sent to you in a separate email.) All other PO files for your package are available in: http://translationproject.org/latest/gcc/ Please consider including all of these in your next release, whether official or a pretest. Whenever you have a new distribution with a new version number ready, containing a newer POT file, please send the URL of that distribution tarball to the address below. The tarball may be just a pretest or a snapshot, it does not even have to compile. It is just used by the translators when they need some extra translation context. The following HTML page has been updated: http://translationproject.org/domain/gcc.html If any question arises, please contact the translation coordinator. Thank you for all your work, The Translation Project robot, in the name of your translation coordinator. coordina...@translationproject.org
Re: [wwwdocs] deprecation of access declarations
Ping ? 2012/1/27 Fabien Chêne fabien.ch...@gmail.com: Hi Gerald, 2012/1/13 Fabien Chêne fabien.ch...@gmail.com: [...] Mind suggesting a snippet for our release notes at http://gcc.gnu.org/gcc-4.7/changes.html ? Yes, sure, thanks for suggestion. Unfortunately, my machine is currently down, I'll get back to you when it is repaired. I get back to you for the snippet about deprecated access declarations. I would also find it sensible to advertise about the fix of c++/14258, a popular bug I have hit myself many times. OK to commit the below ? Index: gcc-4.7/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.74 diff -r1.74 changes.html 396a397,405 liAs per C++98, access-declarations are now deprecated by G++. Using-declarations are to be used instead. Furthermore, some efforts have been made to improve the support of class scope using declarations. In particular, using-declarations referring to a dependent type now work as expected (a href=http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14258;c++/14258/a). /li -- Fabien
[libitm] Add SPARC bits
Hi, this adds a SPARC (V9 only) port to the library. Straightforward, except that the unusual setup of _ITM_beginTransaction's frame consistently crashes GDB if it is fully described in the CFI. Since backtracing through that frame isn't very likely to happen in real life, I have left it as-is. Tested on SPARC/Solaris 8 9 (with the other patch) and on SPARC64/Linux, both in 32-bit and 64-bit mode. OK for the mainline? 2012-02-12 Eric Botcazou ebotca...@adacore.com * configure.tgt (target_cpu): Handle sparc and sparc64 sparcv9. * config/sparc/cacheline.h: New file. * config/sparc/target.h: Likewise. * config/sparc/sjlj.S: Likewise. * config/linux/sparc/futex_bits.h: Likewise. -- Eric Botcazou Index: configure.tgt === --- configure.tgt (revision 183864) +++ configure.tgt (working copy) @@ -66,6 +66,34 @@ case ${target_cpu} in sh*) ARCH=sh ;; + sparc) + case ${CC} ${CFLAGS} in + * -m64 *) + ;; + *) + if test -z $with_cpu; then + XCFLAGS=${XCFLAGS} -mcpu=v9 + fi + esac + ARCH=sparc + ;; + + sparc64|sparcv9) + case ${CC} ${CFLAGS} in + * -m32 *) + XCFLAGS=${XCFLAGS} -mcpu=v9 + ;; + * -m64 *) + ;; + *) + if test x$with_cpu = xv8; then + XCFLAGS=${XCFLAGS} -mcpu=v9 + fi + ;; + esac + ARCH=sparc + ;; + x86_64) case ${CC} ${CFLAGS} in * -m32 *) Index: config/linux/sparc/futex_bits.h === --- config/linux/sparc/futex_bits.h (revision 0) +++ config/linux/sparc/futex_bits.h (revision 0) @@ -0,0 +1,62 @@ +/* Copyright (C) 2012 Free Software Foundation, Inc. + + This file is part of the GNU Transactional Memory Library (libitm). + + Libitm 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 of the License, or + (at your option) any later version. + + Libitm 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. + + Under Section 7 of GPL version 3, you are granted additional + permissions described in the GCC Runtime Library Exception, version + 3.1, as published by the Free Software Foundation. + + You should have received a copy of the GNU General Public License and + a copy of the GCC Runtime Library Exception along with this program; + see the files COPYING3 and COPYING.RUNTIME respectively. If not, see + http://www.gnu.org/licenses/. */ + +#include sys/syscall.h + +static inline long +sys_futex0 (std::atomicint *addr, int op, int val) +{ + register long int g1 __asm__ (g1); + register long int o0 __asm__ (o0); + register long int o1 __asm__ (o1); + register long int o2 __asm__ (o2); + register long int o3 __asm__ (o3); + long res; + + g1 = SYS_futex; + o0 = (long) addr; + o1 = op; + o2 = val; + o3 = 0; + +#ifdef __arch64__ + __asm volatile (ta 0x6d +#else + __asm volatile (ta 0x10 +#endif + : =r(g1), =r(o0) + : 0(g1), 1(o0), r(o1), r(o2), r(o3) + : g2, g3, g4, g5, g6, + f0, f1, f2, f3, f4, f5, f6, f7, + f8, f9, f10, f11, f12, f13, f14, f15, + f16, f17, f18, f19, f20, f21, f22, f23, + f24, f25, f26, f27, f28, f29, f30, f31, + f32, f34, f36, f38, f40, f42, f44, f46, + f48, f50, f52, f54, f56, f58, f60, f62, + cc, memory); + + res = o0; + if (__builtin_expect ((unsigned long) res = -515UL, 0)) +res =- res; + return res; +} Index: config/sparc/cacheline.h === --- config/sparc/cacheline.h (revision 0) +++ config/sparc/cacheline.h (revision 0) @@ -0,0 +1,41 @@ +/* Copyright (C) 2012 Free Software Foundation, Inc. + + This file is part of the GNU Transactional Memory Library (libitm). + + Libitm 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 of the License, or + (at your option) any later version. + + Libitm 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. + + Under Section 7 of GPL version 3, you are granted additional + permissions described in the GCC Runtime Library Exception, version + 3.1, as published by the Free Software Foundation. + + You should have received a copy of the GNU General Public License and + a copy of the GCC Runtime Library Exception along with this program; + see the files COPYING3 and COPYING.RUNTIME respectively. If not, see +
[SPARC] Further work around problematic paradoxical subregs
Word-mode paradoxical subregs have been problematic on big-endian architectures for ages, and the PA and SPARC ports have a workaround for this in the form of the CANNOT_CHANGE_MODE_CLASS macro. The SPARC one was more limited in scope, but 10 ACATS tests fail at -O2 on the mainline because of this, so this patch extends it to fix them. Tested on SPARC64/Solaris, applied on the mainline. 2012-02-12 Eric Botcazou ebotca...@adacore.com * config/sparc/sparc.h (CANNOT_CHANGE_MODE_CLASS): In 64-bit mode, disallow changes from SFmode to mode with different size in FP regs. -- Eric Botcazou Index: config/sparc/sparc.h === --- config/sparc/sparc.h (revision 183864) +++ config/sparc/sparc.h (working copy) @@ -894,18 +894,21 @@ extern enum reg_class sparc_regno_reg_cl #define REGNO_REG_CLASS(REGNO) sparc_regno_reg_class[(REGNO)] -/* Defines invalid mode changes. Borrowed from pa64-regs.h. +/* Defines invalid mode changes. Borrowed from the PA port. SImode loads to floating-point registers are not zero-extended. The definition for LOAD_EXTEND_OP specifies that integer loads narrower than BITS_PER_WORD will be zero-extended. As a result, we inhibit changes from SImode unless they are to a mode that is - identical in size. */ + identical in size. + + Likewise for SFmode, since word-mode paradoxical subregs are + problematic on big-endian architectures. */ #define CANNOT_CHANGE_MODE_CLASS(FROM, TO, CLASS) \ (TARGET_ARCH64 \ -(FROM) == SImode \ -GET_MODE_SIZE (FROM) != GET_MODE_SIZE (TO) \ +GET_MODE_SIZE (FROM) == 4 \ +GET_MODE_SIZE (TO) != 4 \ ? reg_classes_intersect_p (CLASS, FP_REGS) : 0) /* This is the order in which to allocate registers normally.
[wwwdocs] Reduce references to stages in develop.html
This is in preparation of some potentially future changes in relation to the currently confusing naming of Stages 1 and 3. It reduces references to concrete stages and slightly reformats here and there. Committed. Gerald Index: develop.html === RCS file: /cvs/gcc/wwwdocs/htdocs/develop.html,v retrieving revision 1.121 diff -u -3 -p -r1.121 develop.html --- develop.html12 Feb 2012 19:32:38 - 1.121 +++ develop.html12 Feb 2012 19:52:17 - @@ -106,14 +106,14 @@ compiler. In particular, major changes Stage 1 is feature driven and will last at least four months. In order to avoid chaos, the Release Managers will ask for a list of major projects proposed for the coming release cycle before the start -of Stage 1. They will attempt to sequence the projects +of this stage. They will attempt to sequence the projects in such a way as to cause minimal disruption. The Release Managers will not reject projects that will be ready for inclusion before the -end of Stage 1. Similarly, the Release Managers have no special power -to accept a particular patch or branch beyond what their status -as maintainers affords. The role of the Release Managers during Stage 1 -is merely to attempt to order the inclusion of major features in an -organized manner./p +end of Stage 1. Similarly, the Release Managers have no special +power to accept a particular patch or branch beyond what their status +as maintainers affords. The role of the Release Managers is merely +to attempt to order the inclusion of major features in an organized +manner./p h4a name=stage2Stage 2/a/h4 @@ -135,7 +135,7 @@ release. Therefore, more radical change cycle, so that we have time to fix any problems that result./p pIn order to reach higher standards of quality, we must focus on -fixing bugs; by working exclusively on bug-fixing through Stage 3 +fixing bugs; by working exclusively on bug-fixing through this stage and before branching for the release, we will have a higher quality source base as we prepare for a release./p @@ -196,8 +196,8 @@ remain working, to avoid impeding other h3Schedule/h3 -pAt the conclusion of Stage 3, the trunk will go into release branch -mode which allows documentation and regression fixes only. +pAt the conclusion of Stage 3, the trunk will go into release +branch mode which allows documentation and regression fixes only. During this phase, the focus will be fixing any regressions from the previous release, so that each release is better than the one before./p
[Patch, fortran] PR50981 absent polymorphic scalar actual arguments
Hello, this is the next PR50981 fix: when passing polymorphic scalar actual arguments to elemental procedures, we were not adding the _data component reference. The fix is straightforward; checking that the expression's type is BT_CLASS was introducing regressions, so this patch uses a helper function to check the type without impacting the testsuite. Regression tested on x86_64-unknown-freebsd9.0. OK for trunk? Mikael 2012-02-12 Mikael Morin mik...@gcc.gnu.org * trans-expr.c (is_class_container_ref): New function. (gfc_conv_procedure_call): Add a _data component reference to polymorphic actual arguments. diff --git a/trans-expr.c b/trans-expr.c index 18ce1a7..ff4360e 100644 --- a/trans-expr.c +++ b/trans-expr.c @@ -3362,6 +3362,39 @@ conv_isocbinding_procedure (gfc_se * se, gfc_symbol * sym, } +/* Tells whether the expression E is a reference to a (scalar) class container. + Scalar because array class containers usually have an array reference after + them, and gfc_fix_class_refs will add the missing _data component reference + in that case. */ + +static bool +is_class_container_ref (gfc_expr *e) +{ + gfc_ref *ref; + bool result; + + if (e-expr_type != EXPR_VARIABLE) +return e-ts.type == BT_CLASS; + + if (e-symtree-n.sym-ts.type == BT_CLASS) +result = true; + else +result = false; + + for (ref = e-ref; ref; ref = ref-next) +{ + if (ref-type != REF_COMPONENT) + result = false; + else if (ref-u.c.component-ts.type == BT_CLASS) + result = true; + else + result = false; +} + + return result; +} + + /* Generate code for a procedure call. Note can return se-post != NULL. If se-direct_byref is set then se-expr contains the return parameter. Return nonzero, if the call has alternate specifiers. @@ -3542,6 +3575,9 @@ gfc_conv_procedure_call (gfc_se * se, gfc_symbol * sym, else gfc_conv_expr_reference (parmse, e); + if (fsym fsym-ts.type == BT_DERIVED is_class_container_ref (e)) + parmse.expr = gfc_class_data_get (parmse.expr); + /* If we are passing an absent array as optional dummy to an elemental procedure, make sure that we pass NULL when the data pointer is NULL. We need this extra conditional because of 2012-02-12 Mikael Morin mik...@gcc.gnu.org * gfortran.dg/elemental_optional_args_5.f03: Add subcomponent actual argument checks. --- elemental_optional_args_5.f03.old 2012-02-12 20:42:21.0 +0100 +++ elemental_optional_args_5.f03 2012-02-12 20:42:50.0 +0100 @@ -115,6 +115,111 @@ call sub_t (v, tp, .false.) if (s /= 3) call abort() if (any (v /= [9, 33])) call abort() +call sub_t (s, ca, .false.) +call sub_t (v, ca, .false.) +!print *, s, v +if (s /= 3) call abort() +if (any (v /= [9, 33])) call abort() + +call sub_t (s, cp, .false.) +call sub_t (v, cp, .false.) +!print *, s, v +if (s /= 3) call abort() +if (any (v /= [9, 33])) call abort() + +! SCALAR COMPONENTS: alloc/assoc + +allocate (ta, tp, ca, cp) +ta%a = 4 +tp%a = 5 +ca%a = 6 +cp%a = 7 + +call sub_t (s, ta, .true.) +call sub_t (v, ta, .true.) +!print *, s, v +if (s /= 4*2) call abort() +if (any (v /= [4*2, 4*2])) call abort() + +call sub_t (s, tp, .true.) +call sub_t (v, tp, .true.) +!print *, s, v +if (s /= 5*2) call abort() +if (any (v /= [5*2, 5*2])) call abort() + +call sub_t (s, ca, .true.) +call sub_t (v, ca, .true.) +!print *, s, v +if (s /= 6*2) call abort() +if (any (v /= [6*2, 6*2])) call abort() + +call sub_t (s, cp, .true.) +call sub_t (v, cp, .true.) +!print *, s, v +if (s /= 7*2) call abort() +if (any (v /= [7*2, 7*2])) call abort() + +! ARRAY COMPONENTS: Non alloc/assoc + +v = [9, 33] + +call sub_t (v, taa, .false.) +!print *, v +if (any (v /= [9, 33])) call abort() + +call sub_t (v, tpa, .false.) +!print *, v +if (any (v /= [9, 33])) call abort() + +call sub_t (v, caa, .false.) +!print *, v +if (any (v /= [9, 33])) call abort() + +call sub_t (v, cpa, .false.) +!print *, v +if (any (v /= [9, 33])) call abort() + +deallocate(ta, tp, ca, cp) + + +! ARRAY COMPONENTS: alloc/assoc + +allocate (taa(2), tpa(2)) +taa(1:2)%a = [44, 444] +tpa(1:2)%a = [55, 555] +allocate (caa(2), source=[t(66), t(666)]) +allocate (cpa(2), source=[t(77), t(777)]) + +select type (caa) +type is (t) + if (any (caa(:)%a /= [66, 666])) call abort() +end select + +select type (cpa) +type is (t) + if (any (cpa(:)%a /= [77, 777])) call abort() +end select + +call sub_t (v, taa, .true.) +!print *, v +if (any (v /= [44*2, 444*2])) call abort() + +call sub_t (v, tpa, .true.) +!print *, v +if (any (v /= [55*2, 555*2])) call abort() + + +call sub_t (v, caa, .true.) +!print *, v +if (any (v /= [66*2, 666*2])) call abort() + +call sub_t (v, cpa, .true.) +!print *, v +if (any (v /= [77*2, 777*2])) call abort() + +deallocate (taa, tpa, caa, cpa) + + contains elemental subroutine sub1 (x, y, alloc)
[wwwdocs] Change affiliation for Marc Lehmann
...on the steering committee web page, as suggested by Marc. Applied. Gerald Index: steering.html === RCS file: /cvs/gcc/wwwdocs/htdocs/steering.html,v retrieving revision 1.34 diff -u -3 -p -r1.34 steering.html --- steering.html 5 Feb 2012 17:29:03 - 1.34 +++ steering.html 12 Feb 2012 21:13:57 - @@ -30,7 +30,7 @@ place to reach them is the gcc a href= liDavid Edelsohn (IBM)/li liKaveh R. Ghazi/li liJeffrey A. Law (Red Hat)/li -liMarc Lehmann (Technische Universit? Karlsruhe)/li +liMarc Lehmann (nethype GmbH)/li liJason Merrill (Red Hat)/li liDavid Miller (Red Hat)/li liMark Mitchell (CodeSourcery / Mentor Graphics)/li
New German PO file for 'gcc' (version 4.7-b20120128)
Hello, gentle maintainer. This is a message from the Translation Project robot. A revised PO file for textual domain 'gcc' has been submitted by the German team of translators. The file is available at: http://translationproject.org/latest/gcc/de.po (This file, 'gcc-4.7-b20120128.de.po', has just now been sent to you in a separate email.) All other PO files for your package are available in: http://translationproject.org/latest/gcc/ Please consider including all of these in your next release, whether official or a pretest. Whenever you have a new distribution with a new version number ready, containing a newer POT file, please send the URL of that distribution tarball to the address below. The tarball may be just a pretest or a snapshot, it does not even have to compile. It is just used by the translators when they need some extra translation context. The following HTML page has been updated: http://translationproject.org/domain/gcc.html If any question arises, please contact the translation coordinator. Thank you for all your work, The Translation Project robot, in the name of your translation coordinator. coordina...@translationproject.org
Re: [PATCH] Re: New atomics not mentioned in /gcc-4.7/changes.html
On Wed, 8 Feb 2012, Andrew MacLeod wrote: Checked in the shortened version and code changes. How thats? seems better :-) Yep, thanks! There is just a minor grammor I went ahead fixing. On the title page, I was thinking to refer to the release notes entry (gcc-4.7/changes.html), and would make this change for you if you agree. If not, we can leave it as is. Gerald Index: changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.78 diff -u -3 -p -r1.78 changes.html --- changes.html8 Feb 2012 23:33:47 - 1.78 +++ changes.html12 Feb 2012 21:45:11 - @@ -226,8 +226,8 @@ void foo (char *a, const char *b, const li p - Support for atomic operations specifying the C++11/C11 memory model have - been added. These new code__atomic/code routines replace the + Support for atomic operations specifying the C++11/C11 memory model + has been added. These new code__atomic/code routines replace the existing code__sync/code built-in routines. /p p
Re: [wwwdocs] deprecation of access declarations
On Fri, 27 Jan 2012, Fabien Chêne wrote: I get back to you for the snippet about deprecated access declarations. I would also find it sensible to advertise about the fix of c++/14258, a popular bug I have hit myself many times. OK to commit the below ? Yes, thank you. One suggestion: where it reads c++/14258, how about making this bug c++/14258, for those who are less familiar how we name things? Do we need an update for http://gcc.gnu.org/gcc-4.7/porting_to.html as well? Gerald Index: gcc-4.7/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.74 diff -r1.74 changes.html 396a397,405 liAs per C++98, access-declarations are now deprecated by G++. Using-declarations are to be used instead. Furthermore, some efforts have been made to improve the support of class scope using declarations. In particular, using-declarations referring to a dependent type now work as expected (a href=http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14258;c++/14258/a). /li
Re: [wwwdocs] update gcc-4.7/changes.html
On 12 February 2012 18:25, Gerald Pfeifer wrote: On Wed, 8 Feb 2012, Jonathan Wakely wrote: Add note on thread improvements to libstdc++ changes. Nice. I have a hunch that many will be interested to learn which targets are now benefiting from this. Do you have a list, even if not complete to add there? Not a precise one, but I think it's basically any POSIX platform supporting pthreads. Previously it was only POSIX platorms supporting pthreads *and* the POSIX Timeouts option.
Re: Documenting the MIPS changes in 4.7
On Sun, 5 Feb 2012, Richard Sandiford wrote: I've committed this patch to describe the MIPS changes in GCC 4.7. Corrections, comments, and help with wordsmithing are all welcome. Nice! How about the small follow-up below? Gerald Index: changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.79 diff -u -3 -p -r1.79 changes.html --- changes.html12 Feb 2012 21:46:29 - 1.79 +++ changes.html12 Feb 2012 22:01:35 - @@ -52,7 +52,7 @@ obsoleted in GCC 4.6./li liIt is no longer possible to use the codel/code -constraint in MIPS16 asm statements./li +constraint in MIPS16 codeasm/code statements./li liMore information on porting to GCC 4.7 from previous versions of GCC can be found in @@ -609,7 +609,7 @@ well./p/li h3 id=mipsMIPS/h3 ul liGCC now supports thread-local storage (TLS) for MIPS16. -This support requires GNU binutils 2.22 or later./li +This requires GNU binutils 2.22 or later./li liGCC can now generate code specifically for the Cavium Octeon+ and Octeon2 processors. The associated command-line options are
Re: [Patch,wwwdocs,AVR]: AVR release notes
On Mon, 30 Jan 2012, Georg-Johann Lay wrote: Support for...has been added (also typo: beed - been) Hmm, this still seems to be in the latest version? Is C code better? Or C-code? Without the extension, inline assembler must be used to get correct code, using C like a = b or pstruct-component will yield wrong code without the extensions if b or *pstruct is located in flash. Thanks for the background. I really like how you have changed this in the new version of the patch! +liSupport for AVR-specific built-in functions has beed added./li Which ones? Must they all be named explicitly? Or is it ok to link to onlinedocs? I'd prefer a link to the explanation in onlinedocs but I am unsure how stable the links are as docs evolve over time/versions. If you think it's not beneficial, we don't have to do anything. The links should be rather stable in general (and I am running link checks somewhat regularly). +liSupport has beed added for the built-in, 24-bit, signed and unsigned + integer types code__int24/code and code__uint24/code./li I believe that should be signed and unsigned 24-bit integer types (omitting built-in should be fine, but in any case without commas). What does need no nbsp; mean? Nothing at ,etc. all or blank , etc.? I'd just use a regular space instead of nbsp; in that case. What is .progmen? Perhaps paraphrase this briefly? Not easy without getting into too much technical details... Okay. Attached an updated patch as there were many changes and so that Eric and Denis can easier catch up. Looks good! Please fix the one typo, and consider the other comments as well, and go ahead and commit this I'd say. We can always make further changes later. This looks like an impressive release for AVR! Gerald
Re: [wwwdocs] libstdcxx_so_7-2-branch branch creation
On Wed, 1 Feb 2012, François Dumont wrote: I have created yesterday the libstdcxx_so_7-2-branch in the gcc repo that only contains the libstdc++-v3 folder. This branch will contain all the abi breaking changes that are plan to be moved to trunk as soon as the decision to break the abi will have been taken. Paolo Carlini advise me to write you, and the mailing list, to ask if you could document it on this page: Thanks for the heads up, François (and thanks for Paolo for the reference ;-). Based on your mail, how about the following change to the web page? Should (also) others be listed as branch maintainers? Is there a specific way patches to that branch should be labled in the subject, similar to other branches? Any other changes? Gerald Index: svn.html === RCS file: /cvs/gcc/wwwdocs/htdocs/svn.html,v retrieving revision 1.167 diff -u -3 -p -r1.167 svn.html --- svn.html1 Feb 2012 19:55:33 - 1.167 +++ svn.html12 Feb 2012 22:21:54 - @@ -486,6 +486,12 @@ the command codesvn log --stop-on-copy Only patches backported from mainline are accepted. They should be marked with the tag [4_4-plugins] in the Subject line./dd + dtlibstdcxx_so_7-2-branch/dt + ddThis branch carries all ABI breaking changes to libstdc++ that + will be merged to trunk once the decision to break the C++ ABI is + taken. a href=mailto:frs.dum...@gmail.com;François Dumont/a + maintains this branch./dd + dtpph/dt ddThis branch implements a href=http://gcc.gnu.org/wiki/pph; Pre-Parsed Headers for C++/a. It is maintained by a
Re: Announcing new docstring relicensing maintainers
And here is the change to MAINTAINERS I just committed. 2012-02-12 Gerald Pfeifer ger...@pfeifer.com * MAINTAINERS (Various Maintainers): Add Diego Novillo, Gerald Pfeifer and Joseph Myers as docstring relicensing maintainers. Index: MAINTAINERS === --- MAINTAINERS (revision 184144) +++ MAINTAINERS (working copy) @@ -211,6 +211,9 @@ build machinery (*.in) Ralf Wildenhues ralf.wildenh...@gmx.de docs co-maintainer Gerald Pfeifer ger...@pfeifer.com docs co-maintainer Joseph Myersjos...@codesourcery.com +docstring relicensing Diego Novillo dnovi...@google.com +docstring relicensing Gerald Pfeifer ger...@pfeifer.com +docstring relicensing Joseph Myersjos...@codesourcery.com predict.defJan Hubicka j...@suse.cz contrib/regression Geoff Keating geo...@geoffk.org gcov Jan Hubicka j...@suse.cz
Re: adjust installation docs to discourage installing GMP, MPFR and MPC separately
On Sat, 4 Feb 2012, Jonathan Wakely wrote: * doc/install.texi (Prerequisites): Suggest building GMP, MPFR and MPC as part of GCC before describing configuring with --with-gmp etc. (Installing GCC: Configuration): State that --with-gmp etc. aren't needed if sources are present. For the ChangeLog I would just say --with-gmp etc. are not needed if..., omitting the State that which is implied for docs. +subdirectory of your GCC sources named @file{gmp}, it will be built +together with GCC, this avoids the need to build GMP separately. +Alternatively, if GMP is already installed but it is not in your How about GCC(full stop). This avoids the need, that is, making the latter a sentence of its own? Or just omit this? Same for the other two libraries. -If you do not have GMP (the GNU Multiple Precision library), the MPFR -library and/or the MPC library installed in a standard location and -you want to build GCC, you can explicitly specify the directory where +If you want to build GCC but do not have GMP (the GNU Multiple Precision +library), the MPFR library and/or the MPC library installed in a +standard location and don't have their sources present in the GCC +source tree then you can explicitly specify the directory where don't - do not And I would avoid the expansion of GMP in parenthesis, given how late we are in the document and all the prior uses. I acknowledge this predates you changes, but while we are at it. :-) The patch is fine with these changes. Thank you! Gerald
Re: adjust installation docs to discourage installing GMP, MPFR and MPC separately
On Sat, 21 Jan 2012, Jonathan Wakely wrote: My 2c - I heartily recommend this patch. Thanks. I'm a bit surprised noone else has commented - I hoped this would be a no-brainer, or at least get some constructive feedback for further improvement. One reason surely is that the diffs for changes like this look a lot more frightening than the actual changes are. :-) I recently added http://gcc.gnu.org/wiki/InstallingGCC That does indicate a problem, if our primary documentation is not suitable for beginners as well. Do you see any chance to merge the two and account for the use case you are addressing with the new document as part of doc/install.texi and its associated web pages? Gerald
Re: adjust installation docs to discourage installing GMP, MPFR and MPC separately
On 12 February 2012 23:43, Gerald Pfeifer wrote: On Sat, 21 Jan 2012, Jonathan Wakely wrote: My 2c - I heartily recommend this patch. Thanks. I'm a bit surprised noone else has commented - I hoped this would be a no-brainer, or at least get some constructive feedback for further improvement. One reason surely is that the diffs for changes like this look a lot more frightening than the actual changes are. :-) I recently added http://gcc.gnu.org/wiki/InstallingGCC That does indicate a problem, if our primary documentation is not suitable for beginners as well. Do you see any chance to merge the two and account for the use case you are addressing with the new document as part of doc/install.texi and its associated web pages? The wiki has several advantages, including that it's MUCH easier to make small improvements to without waiting weeks for review, and the less-official wiki docs can more easily refer to e.g. For Debian-based systems, including Ubuntu where the main docs seem to avoid referring to specific systems or vendors (though maybe that's just my perception.) That wiki page is far less formal in style than the main docs, which has both pros and cons.
RE: [Ping] RE: CR16 Port addition
On Fri, 3 Feb 2012, Jayant R. Sonar wrote: After making some minor changes related to build problems, I have checked-in the CR16 GCC port yesterday. How about a news item on our main web page, and release notes entry under gcc-4.7/changes.html? Details on how to create changes for our web pages are at http://gcc.gnu.org/cvs.html and I'll be happy to work with you on these. Gerald
RE: [PATCH ARM] backport r174803 from trunk to 4.6 branch
Ping... Thanks -Original Message- From: gcc-patches-ow...@gcc.gnu.org [mailto:gcc-patches-ow...@gcc.gnu.org] On Behalf Of Bin Cheng Sent: Wednesday, February 08, 2012 4:29 PM To: gcc-patches@gcc.gnu.org Subject: [PATCH ARM] backport r174803 from trunk to 4.6 branch Hi, Julian Brown once posted a patch fixing ARM EABI violation, which I think also essential to 4.6 branch. I created a patch against 4.6 branch as attached. Is it ok to back port? You can refer following link for original patch. http://gcc.gnu.org/ml/gcc-patches/2011-06/msg00260.html Thanks gcc/ChangeLog: 2012-02-08 Bin Cheng bin.ch...@arm.com Backport from mainline 2011-06-08 Julian Brown jul...@codesourcery.com * config/arm/arm.c (arm_libcall_uses_aapcs_base): Use correct ABI for double-precision helper functions in hard-float mode if only single-precision arithmetic is supported in hardware.