diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1996-08-15 15:43:42 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1996-08-15 15:43:42 +0000 |
commit | 16f2a716d9132d7624473f0c91d63045f25a7bc9 (patch) | |
tree | 61c7a3e450f8f4d8891ed1e993fc6c3483f72fcf | |
parent | 5b8bc6cfc27b80e98588790026b0fe51f3044268 (diff) |
Merge of GCC 2.7.2.1
30 files changed, 555 insertions, 340 deletions
diff --git a/gnu/usr.bin/gcc/ChangeLog b/gnu/usr.bin/gcc/ChangeLog index 21a129dc72b..3f955fb4a2e 100644 --- a/gnu/usr.bin/gcc/ChangeLog +++ b/gnu/usr.bin/gcc/ChangeLog @@ -1,3 +1,118 @@ +Sat Jun 29 12:33:39 1996 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> + + * Version 2.7.2.1 released. + +Tue Jun 11 20:18:03 1996 Per Bothner <bothner@cygnus.com> + + * fix-header.c (read_scna_file): Invoke FIXPROTO_INIT if defined. + * alpha.h (FIXPROTO_INIT): Define new macro. + +Fri May 10 18:35:00 1996 Richard Kenner (kenner@vlsi1.ultra.nyu.edu) + + * loop.c (maybe_eliminate_biv_1): Disable all but two cases + of biv elimination with givs and restrict those two cases to + an ADD_VAL that is an address. + +Mon Apr 22 16:50:19 1996 Jeremy Bettis <jeremy@hksys.com> + + * objc/hash.c (hash_value_for_key): Prevent endless loop when 0 was + stored in a hashtable. + +Wed Apr 17 17:53:23 1996 Michael Meissner <meissner@tiktok.cygnus.com> + + * rs6000.c (expand_block_move_mem): Copy RTX_UNCHANGING_P. + (expand_block_move): Copy dest/src to registers using + copy_addr_to_reg, call expand_block_move_mem to copy all of the + bits. + +Mon Apr 8 13:46:28 1996 Michael Meissner <meissner@tiktok.cygnus.com> + + * rs6000.c (output_{prolog,epilog}): For V.4/eabi systems, change + prologue and epilogue so that accesses beyond the current stack + pointer are not done like they are for AIX. + +Fri Mar 26 05:43:06 1996 Torbjorn Granlund <tege@noisy.matematik.su.se> + + * vax.md (insv matcher): Call CC_STATUS_INIT. + * vax.h (NOTICE_UPDATE_CC): Handle ZERO_EXTRACT destination. + +Sat Mar 23 18:25:39 1996 J"orn Rennecke (amylaar@meolyon.hanse.de) + + * c-typeck.c (set_init_index): Check for use outside an array + initializer. + +Sat Mar 23 09:21:40 1996 Doug Evans <dje@canuck.cygnus.com> + + * sparc/sparc.h (CONDITIONAL_REGISTER_USAGE): Don't unfix %g[234] + if fixed with -ffixed-. + +Wed Mar 13 20:36:10 1996 Jim Wilson <wilson@chestnut.cygnus.com> + + * mips.c (mips_expand_prologue): Change TYPE_NEEDS_CONSTRUCTING to + TREE_ADDRESSABLE; + * pa.h (ASM_DECLARE_FUNCTION_NAME): Likewise. + +Tue Mar 12 14:36:02 1996 Jason Merrill <jason@yorick.cygnus.com> + + * lex.c (real_yylex): Warn about using the `namespace' keyword. + +Tue Feb 27 08:18:12 1996 Richard Earnshaw (rearnsha@armltd.co.uk) + + * arm.md (mov{si,sf,df}cc and matchers): All conditional move + patterns must have a mode. + +Mon Feb 19 07:35:07 1996 Torbjorn Granlund <tege@tmg.se> + + * rs6000.md (not:SI with assign and compare): Fix typo. + +Wed Jan 24 18:00:12 1996 Brendan Kehoe <brendan@lisa.cygnus.com> + + * alpha.c (alpha_write_verstamp): Only emit MS_STAMP and LS_STAMP, + not the extra numbers. + +Wed Jan 17 21:22:40 1996 Brendan Kehoe <brendan@lisa.cygnus.com> + + * cp/decl2.c (grokfield): Call cplus_decl_attributes with the attrlist. + Pass a null tree to grokdeclarator for its ATTRLIST arg, since it's + only ever used for functions in it. + +Tue Jan 16 06:01:28 1996 Thomas Graichen <graichen@omega.physik.fu-berlin.de> + + * i386/freebsd.h (ASM_WEAKEN_LABEL): Deleted; not supported. + +Sun Jan 7 17:11:11 1996 David Edelsohn <edelsohn@mhpcc.edu> + + * collect2.c (scan_libraries): Correct Import File ID interpretation. + +Thu Dec 28 22:24:53 1995 Michael Meissner <meissner@tiktok.cygnus.com> + + * rs6000.md (common mode functions): Add condition reg clobbers. + +Tue Dec 19 15:08:31 1995 Jason Merrill <jason@yorick.cygnus.com> + + * collect2.c: Remove auto_export functionality. + +Mon Dec 18 18:40:34 1995 Jim Wilson <wilson@chestnut.cygnus.com> + + * svr4.h (ASM_IDENTIFY_GCC): Don't output stab here. + (ASM_IDENTIFY_GCC_AFTER_SOURCE): Output stab here instead of + above. + +Sat Dec 16 07:03:33 1995 Philippe De Muyter (phdm@info.ucl.ac.be) + + * stor-layout.c (layout_record): When PCC_BITFIELD_TYPE_MATTERS, + compute bitpos using field_size % type_align instead of field_size. + +Fri Dec 15 18:41:50 1995 Philippe De Muyter (phdm@info.ucl.ac.be) + + * fixincludes (sys/wait.h): Add forward declaration of struct rusage + on AIX 3.2.5. + +Sat Dec 9 18:05:03 1995 Jim Wilson <wilson@cygnus.com> + + * expr.c (expand_expr, case INDIRECT_REF): Correct typo in May 8 + change. + Sun Nov 26 14:47:42 1995 Richard Kenner <kenner@mole.gnu.ai.mit.edu> * Version 2.7.2 released. diff --git a/gnu/usr.bin/gcc/INSTALL b/gnu/usr.bin/gcc/INSTALL index d4ac7c5a2ea..d792b336e4c 100644 --- a/gnu/usr.bin/gcc/INSTALL +++ b/gnu/usr.bin/gcc/INSTALL @@ -657,76 +657,47 @@ special things you must know: Structures are no longer a multiple of 2 bytes. `hppa*-*-*' - There are two variants of this CPU, called 1.0 and 1.1, which have - different machine descriptions. You must use the right one for - your machine. All 7NN machines and 8N7 machines use 1.1, while - all other 8NN machines use 1.0. - - The easiest way to handle this problem is to use `configure hpNNN' - or `configure hpNNN-hpux', where NNN is the model number of the - machine. Then `configure' will figure out if the machine is a 1.0 - or 1.1. Use `uname -a' to find out the model number of your - machine. + There are several variants of the HP-PA processor which run a + variety of operating systems. GNU CC must be configured to use + the correct processor type and operating system, or GNU CC will + not function correctly. The easiest way to handle this problem is + to *not* specify a target when configuring GNU CC, the `configure' + script will try to automatically determine the right processor + type and operating system. `-g' does not work on HP-UX, since that system uses a peculiar debugging format which GNU CC does not know about. However, `-g' will work if you also use GAS and GDB in conjunction with GCC. We highly recommend using GAS for all HP-PA configurations. - You should be using GAS-2.3 (or later) along with GDB-4.12 (or + You should be using GAS-2.6 (or later) along with GDB-4.16 (or later). These can be retrieved from all the traditional GNU ftp archive sites. - Build GAS and install the resulting binary as: - - /usr/local/lib/gcc-lib/CONFIGURATION/GCCVERSION/as - - where CONFIGURATION is the configuration name (perhaps - `hpNNN-hpux') and GCCVERSION is the GNU CC version number. Do - this *before* starting the build process, otherwise you will get - errors from the HPUX assembler while building `libgcc2.a'. The - command - - make install-dir - - will create the necessary directory hierarchy so you can install - GAS before building GCC. - - To enable debugging, configure GNU CC with the `--with-gnu-as' - option before building. - - It has been reported that GNU CC produces invalid assembly code for - 1.1 machines running HP-UX 8.02 when using the HP assembler. - Typically the errors look like this: - as: bug.s @line#15 [err#1060] - Argument 0 or 2 in FARG upper - - lookahead = ARGW1=FR,RTNVAL=GR - as: foo.s @line#28 [err#1060] - Argument 0 or 2 in FARG upper - - lookahead = ARGW1=FR + GAS will need to be installed into a directory before `/bin', + `/usr/bin', and `/usr/ccs/bin' in your search path. You should + install GAS before you build GNU CC. - You can check the version of HP-UX you are running by executing - the command `uname -r'. If you are indeed running HP-UX 8.02 on - a PA and using the HP assembler then configure GCC with - "hpNNN-hpux8.02". + To enable debugging, you must configure GNU CC with the + `--with-gnu-as' option before building. `i370-*-*' This port is very preliminary and has many known bugs. We hope to have a higher-quality port for this machine soon. `i386-*-linuxoldld' - Use this configuration to generate a.out binaries on Linux if you - do not have gas/binutils version 2.5.2 or later installed. This is - an obsolete configuration. + Use this configuration to generate a.out binaries on Linux-based + GNU systems, if you do not have gas/binutils version 2.5.2 or later + installed. This is an obsolete configuration. `i386-*-linuxaout' - Use this configuration to generate a.out binaries on Linux. This - configuration is being superseded. You must use gas/binutils - version 2.5.2 or later. + Use this configuration to generate a.out binaries on Linux-based + GNU systems. This configuration is being superseded. You must use + gas/binutils version 2.5.2 or later. `i386-*-linux' - Use this configuration to generate ELF binaries on Linux. You must - use gas/binutils version 2.5.2 or later. + Use this configuration to generate ELF binaries on Linux-based GNU + systems. You must use gas/binutils version 2.5.2 or later. `i386-*-sco' Compilation with RCC is recommended. Also, it may be a good idea diff --git a/gnu/usr.bin/gcc/NEWS b/gnu/usr.bin/gcc/NEWS index 2a665a1a60c..9c2309328e4 100644 --- a/gnu/usr.bin/gcc/NEWS +++ b/gnu/usr.bin/gcc/NEWS @@ -1,3 +1,7 @@ +Noteworthy changes in GCC version 2.7.2.1: + +This release fixes some serious bugs discovered since the 2.7.2 release. + Noteworthy changes in GCC version 2.7.2: A few bugs have been fixed (most notably the generation of an diff --git a/gnu/usr.bin/gcc/c-typeck.c b/gnu/usr.bin/gcc/c-typeck.c index e9d6b2a4196..bae52e323f4 100644 --- a/gnu/usr.bin/gcc/c-typeck.c +++ b/gnu/usr.bin/gcc/c-typeck.c @@ -5723,6 +5723,8 @@ set_init_index (first, last) error_init ("nonconstant array index in initializer%s", " for `%s'", NULL); else if (last != 0 && TREE_CODE (last) != INTEGER_CST) error_init ("nonconstant array index in initializer%s", " for `%s'", NULL); + else if (! constructor_unfilled_index) + error_init ("array index in non-array initializer%s", " for `%s'", NULL); else if (tree_int_cst_lt (first, constructor_unfilled_index)) error_init ("duplicate array index in initializer%s", " for `%s'", NULL); else diff --git a/gnu/usr.bin/gcc/collect2.c b/gnu/usr.bin/gcc/collect2.c index ac040c693e4..84e75ab57c2 100644 --- a/gnu/usr.bin/gcc/collect2.c +++ b/gnu/usr.bin/gcc/collect2.c @@ -255,7 +255,6 @@ static char *temp_filename; /* Base of temp filenames */ static char *c_file; /* <xxx>.c for constructor/destructor list. */ static char *o_file; /* <xxx>.o for constructor/destructor list. */ static char *export_file; /* <xxx>.x for AIX export list. */ -static int auto_export = 1; /* true if exporting everything. */ char *ldout; /* File for ld errors. */ static char *output_file; /* Output file for ld. */ static char *nm_file_name; /* pathname of nm */ @@ -1245,15 +1244,6 @@ main (argc, argv) } break; -#ifdef COLLECT_EXPORT_LIST - case 'b': - if ((!strncmp (arg, "-bE:", 4) - || !strncmp (arg, "-bexport:", 9)) - && strcmp (arg, "-bexport:/usr/lib/libg.exp")) - auto_export = 0; - break; -#endif - case 'l': if (first_file) { @@ -2556,8 +2546,6 @@ scan_prog_file (prog_name, which_pass) break; default: /* not a constructor or destructor */ - if (which_pass == PASS_OBJ && auto_export) - add_to_list (&exports, name); continue; } @@ -2608,62 +2596,72 @@ scan_libraries (prog_name) { LDHDR ldh; char *impbuf; - int idx; + int entry; + FSEEK (ldptr, ldsh.s_scnptr, BEGINNING); - FREAD (&ldh, sizeof ldh, 1, ldptr); + FREAD (&ldh, sizeof (ldh), 1, ldptr); /* read import library list */ impbuf = alloca (ldh.l_istlen); FSEEK (ldptr, ldh.l_impoff + ldsh.s_scnptr, BEGINNING); FREAD (impbuf, ldh.l_istlen, 1, ldptr); - idx = strlen (impbuf) + 1; - idx += strlen (impbuf+idx) + 1; + if (debug) fprintf (stderr, "LIBPATH=%s\n", impbuf); prefix_from_string (impbuf, &libpath); - while (idx < ldh.l_istlen) + + /* skip LIBPATH and empty base and member fields */ + impbuf += strlen (impbuf) + 3; + for (entry = 1; entry < ldh.l_nimpid; ++entry) { - char *implib = impbuf + idx; + char *impath = impbuf; + char *implib = impath + strlen (impath) + 1; char *impmem = implib + strlen (implib) + 1; - char *soname = 0; + char *soname = NULL; + char *trial; + int pathlen; LDFILE *libptr = NULL; struct prefix_list *pl; ARCHDR ah; - idx += strlen (implib) + 1; - if (!implib[0]) + + impbuf = impmem + strlen (impmem) + 1; + if (debug) + fprintf (stderr, "PATH+BASE=%s%s\n", impath, implib); + /* Skip AIX kernel exports */ + if (*impath == '/' && *(impath+1) == '\0' + && strcmp (implib, "unix") == 0) continue; - idx += strlen (impmem) + 1; - if (*implib == '/') + pathlen = strlen (impath); + trial = alloca (MAX (pathlen + 1, libpath.max_len) + + strlen (implib) + 1); + if (*impath) { - if (access (soname, R_OK) == 0) - soname = implib; + strcpy (trial, impath); + if (impath[pathlen - 1] != '/') + trial[pathlen++] = '/'; + strcpy (trial + pathlen, implib); + if (access (trial, R_OK) == 0) + soname = trial; } else - { - char *temp = alloca (libpath.max_len + strlen (implib) + 1); - for (pl = libpath.plist; pl; pl = pl->next) - { - strcpy (temp, pl->prefix); - strcat (temp, implib); - if (access (temp, R_OK) == 0) - { - soname = temp; - break; - } - } - } - if (!soname) - { - fatal ("%s: library not found", implib); - continue; - } + for (pl = libpath.plist; pl; pl = pl->next) + { + strcpy (trial, pl->prefix); + strcat (trial, implib); + if (access (trial, R_OK) == 0) + { + soname = trial; + break; + } + } + + if (! soname) + fatal ("%s: library not found", implib); if (debug) - { - if (impmem[0]) - fprintf (stderr, "%s (%s)\n", soname, impmem); - else - fprintf (stderr, "%s\n", soname); - } - ah.ar_name[0] = 0; + if (*impmem) + fprintf (stderr, "%s (%s)\n", soname, impmem); + else + fprintf (stderr, "%s\n", soname); + do { /* scan imported shared objects for GCC GLOBAL ctors */ @@ -2673,7 +2671,7 @@ scan_libraries (prog_name) if (TYPE (libptr) == ARTYPE) { LDFILE *memptr; - if (!impmem[0]) + if (! *impmem) fatal ("%s: no archive member specified", soname); ldahread (libptr, &ah); if (strcmp (ah.ar_name, impmem)) @@ -2690,12 +2688,12 @@ scan_libraries (prog_name) if (!ldnshread (libptr, _LOADER, &soldsh)) fatal ("%s: not an import library", soname); FSEEK (libptr, soldsh.s_scnptr, BEGINNING); - if (FREAD (&soldh, sizeof soldh, 1, libptr) != 1) + if (FREAD (&soldh, sizeof (soldh), 1, libptr) != 1) fatal ("%s: can't read loader section", soname); /*fprintf (stderr, "\tscanning %s\n", soname);*/ symcnt = soldh.l_nsyms; - lsyms = (LDSYM*) alloca (symcnt * sizeof *lsyms); - symcnt = FREAD (lsyms, sizeof *lsyms, symcnt, libptr); + lsyms = (LDSYM*) alloca (symcnt * sizeof (*lsyms)); + symcnt = FREAD (lsyms, sizeof (*lsyms), symcnt, libptr); ldstrings = alloca (soldh.l_stlen); FSEEK (libptr, soldsh.s_scnptr+soldh.l_stoff, BEGINNING); FREAD (ldstrings, soldh.l_stlen, 1, libptr); diff --git a/gnu/usr.bin/gcc/config/alpha/alpha.c b/gnu/usr.bin/gcc/config/alpha/alpha.c index b80717d41c1..0efe27ca733 100644 --- a/gnu/usr.bin/gcc/config/alpha/alpha.c +++ b/gnu/usr.bin/gcc/config/alpha/alpha.c @@ -1247,12 +1247,7 @@ alpha_write_verstamp (file) FILE *file; { #ifdef MS_STAMP - char *p; - - fprintf (file, "\t.verstamp %d %d ", MS_STAMP, LS_STAMP); - for (p = version_string; *p != ' ' && *p != 0; p++) - fprintf (file, "%c", *p == '.' ? ' ' : *p); - fprintf (file, "\n"); + fprintf (file, "\t.verstamp %d %d\n", MS_STAMP, LS_STAMP); #endif } diff --git a/gnu/usr.bin/gcc/config/alpha/alpha.h b/gnu/usr.bin/gcc/config/alpha/alpha.h index b179f1445a0..a4ff2e31272 100644 --- a/gnu/usr.bin/gcc/config/alpha/alpha.h +++ b/gnu/usr.bin/gcc/config/alpha/alpha.h @@ -2094,6 +2094,9 @@ do { \ /* The system headers under OSF/1 are C++-aware. */ #define NO_IMPLICIT_EXTERN_C +/* Also define __LANGUAGE_C__ when running fix-header. */ +#define FIXPROTO_INIT(CPPFILE) cpp_define (CPPFILE, "__LANGUAGE_C__") + /* The linker will stick __main into the .init section. */ #define HAS_INIT_SECTION #define LD_INIT_SWITCH "-init" diff --git a/gnu/usr.bin/gcc/config/arm/arm.md b/gnu/usr.bin/gcc/config/arm/arm.md index 461aeada97a..5e60f2d227b 100644 --- a/gnu/usr.bin/gcc/config/arm/arm.md +++ b/gnu/usr.bin/gcc/config/arm/arm.md @@ -3316,9 +3316,9 @@ (define_expand "movsicc" [(set (match_operand:SI 0 "register_operand" "") - (if_then_else (match_operand 1 "comparison_operator" "") - (match_operand:SI 2 "arm_not_operand" "") - (match_operand:SI 3 "register_operand" "")))] + (if_then_else:SI (match_operand 1 "comparison_operator" "") + (match_operand:SI 2 "arm_not_operand" "") + (match_operand:SI 3 "register_operand" "")))] "" " { @@ -3331,9 +3331,9 @@ (define_expand "movsfcc" [(set (match_operand:SF 0 "register_operand" "") - (if_then_else (match_operand 1 "comparison_operator" "") - (match_operand:SF 2 "nonmemory_operand" "") - (match_operand:SF 3 "register_operand" "")))] + (if_then_else:SF (match_operand 1 "comparison_operator" "") + (match_operand:SF 2 "nonmemory_operand" "") + (match_operand:SF 3 "register_operand" "")))] "" " { @@ -3346,9 +3346,9 @@ (define_expand "movdfcc" [(set (match_operand:DF 0 "register_operand" "") - (if_then_else (match_operand 1 "comparison_operator" "") - (match_operand:DF 2 "nonmemory_operand" "") - (match_operand:DF 3 "register_operand" "")))] + (if_then_else:DF (match_operand 1 "comparison_operator" "") + (match_operand:DF 2 "nonmemory_operand" "") + (match_operand:DF 3 "register_operand" "")))] "TARGET_HARD_FLOAT" " { @@ -3361,10 +3361,10 @@ (define_insn "*movsicc_insn" [(set (match_operand:SI 0 "register_operand" "=r,r") - (if_then_else (match_operator 1 "comparison_operator" - [(reg 24) (const_int 0)]) - (match_operand:SI 2 "arm_not_operand" "rI,K") - (match_operand:SI 3 "register_operand" "0,0")))] + (if_then_else:SI (match_operator 1 "comparison_operator" + [(reg 24) (const_int 0)]) + (match_operand:SI 2 "arm_not_operand" "rI,K") + (match_operand:SI 3 "register_operand" "0,0")))] "" "@ mov%d1\\t%0, %2 @@ -3374,10 +3374,10 @@ (define_insn "*movsfcc_hard_insn" [(set (match_operand:SF 0 "register_operand" "=f") - (if_then_else (match_operator 1 "comparison_operator" - [(reg 24) (const_int 0)]) - (match_operand:SF 2 "register_operand" "f") - (match_operand:SF 3 "register_operand" "0")))] + (if_then_else:SF (match_operator 1 "comparison_operator" + [(reg 24) (const_int 0)]) + (match_operand:SF 2 "register_operand" "f") + (match_operand:SF 3 "register_operand" "0")))] "TARGET_HARD_FLOAT" "mvf%d1s\\t%0, %2" [(set_attr "type" "ffarith") @@ -3385,10 +3385,10 @@ (define_insn "*movsfcc_soft_insn" [(set (match_operand:SF 0 "register_operand" "=r") - (if_then_else (match_operator 1 "comparison_operator" - [(reg 24) (const_int 0)]) - (match_operand:SF 2 "register_operand" "r") - (match_operand:SF 3 "register_operand" "0")))] + (if_then_else:SF (match_operator 1 "comparison_operator" + [(reg 24) (const_int 0)]) + (match_operand:SF 2 "register_operand" "r") + (match_operand:SF 3 "register_operand" "0")))] "TARGET_SOFT_FLOAT" "mov%d1\\t%0, %2" [(set_attr "type" "*") @@ -3396,10 +3396,10 @@ (define_insn "*movdfcc_insn" [(set (match_operand:DF 0 "register_operand" "=f") - (if_then_else (match_operator 1 "comparison_operator" - [(reg 24) (const_int 0)]) - (match_operand:DF 2 "register_operand" "f") - (match_operand:DF 3 "register_operand" "0")))] + (if_then_else:DF (match_operator 1 "comparison_operator" + [(reg 24) (const_int 0)]) + (match_operand:DF 2 "register_operand" "f") + (match_operand:DF 3 "register_operand" "0")))] "TARGET_HARD_FLOAT" "mvf%d1d\\t%0, %2" [(set_attr "type" "ffarith") diff --git a/gnu/usr.bin/gcc/config/i386/freebsd.h b/gnu/usr.bin/gcc/config/i386/freebsd.h index 72fcdd13366..c4e9991c62f 100644 --- a/gnu/usr.bin/gcc/config/i386/freebsd.h +++ b/gnu/usr.bin/gcc/config/i386/freebsd.h @@ -120,12 +120,6 @@ Boston, MA 02111-1307, USA. */ #define TYPE_ASM_OP ".type" #define SIZE_ASM_OP ".size" -/* This is how we tell the assembler that a symbol is weak. */ - -#define ASM_WEAKEN_LABEL(FILE,NAME) \ - do { fputs ("\t.weak\t", FILE); assemble_name (FILE, NAME); \ - fputc ('\n', FILE); } while (0) - /* The following macro defines the format used to output the second operand of the .type assembler directive. Different svr4 assemblers expect various different forms for this operand. The one given here diff --git a/gnu/usr.bin/gcc/config/mips/mips.c b/gnu/usr.bin/gcc/config/mips/mips.c index 205d81f3ed4..9fe34af6e06 100644 --- a/gnu/usr.bin/gcc/config/mips/mips.c +++ b/gnu/usr.bin/gcc/config/mips/mips.c @@ -4930,7 +4930,7 @@ mips_expand_prologue () enum machine_mode passed_mode = TYPE_MODE (passed_type); rtx entry_parm; - if (TYPE_NEEDS_CONSTRUCTING (passed_type)) + if (TREE_ADDRESSABLE (passed_type)) { passed_type = build_pointer_type (passed_type); passed_mode = Pmode; diff --git a/gnu/usr.bin/gcc/config/msdos/top.sed b/gnu/usr.bin/gcc/config/msdos/top.sed index 7881236d9b7..bc94119ffea 100644 --- a/gnu/usr.bin/gcc/config/msdos/top.sed +++ b/gnu/usr.bin/gcc/config/msdos/top.sed @@ -19,9 +19,9 @@ host_xm_file=config/i386/xm-dos.h /^xmake_file=/ d /^tmake_file=/ d /^version=/ c\ -version=2.7.2 +version=2.7.2.1 /^mainversion=/ c\ -mainversion=2.7.2 +mainversion=2.7.2.1 s/CC = cc/CC = gcc/ s/:\$/: \$/g s/^ \ *\.\// / diff --git a/gnu/usr.bin/gcc/config/pa/pa.h b/gnu/usr.bin/gcc/config/pa/pa.h index 5422df2e7b2..85a4c15c97d 100644 --- a/gnu/usr.bin/gcc/config/pa/pa.h +++ b/gnu/usr.bin/gcc/config/pa/pa.h @@ -1067,7 +1067,7 @@ extern enum cmp_type hppa_branch_type; /* Passing structs by invisible reference uses \ one general register. */ \ if (arg_size > 2 \ - || TYPE_NEEDS_CONSTRUCTING (DECL_ARG_TYPE (parm)))\ + || TREE_ADDRESSABLE (DECL_ARG_TYPE (parm)))\ arg_size = 1; \ if (arg_size == 2 && i <= 2) \ { \ diff --git a/gnu/usr.bin/gcc/config/rs6000/rs6000.c b/gnu/usr.bin/gcc/config/rs6000/rs6000.c index 08ebd4e37da..e1c58b18474 100644 --- a/gnu/usr.bin/gcc/config/rs6000/rs6000.c +++ b/gnu/usr.bin/gcc/config/rs6000/rs6000.c @@ -1164,6 +1164,7 @@ expand_block_move_mem (mode, addr, orig_mem) rtx orig_mem; { rtx mem = gen_rtx (MEM, mode, addr); + RTX_UNCHANGING_P (mem) = RTX_UNCHANGING_P (orig_mem); MEM_VOLATILE_P (mem) = MEM_VOLATILE_P (orig_mem); MEM_IN_STRUCT_P (mem) = MEM_IN_STRUCT_P (orig_mem); return mem; @@ -1183,6 +1184,8 @@ int expand_block_move (operands) rtx operands[]; { + rtx orig_dest = operands[0]; + rtx orig_src = operands[1]; rtx bytes_rtx = operands[2]; rtx align_rtx = operands[3]; int constp = (GET_CODE (bytes_rtx) == CONST_INT); @@ -1224,8 +1227,8 @@ expand_block_move (operands) return 0; /* Move the address into scratch registers. */ - dest_reg = copy_addr_to_reg (XEXP (operands[0], 0)); - src_reg = copy_addr_to_reg (XEXP (operands[1], 0)); + dest_reg = copy_addr_to_reg (XEXP (orig_dest, 0)); + src_reg = copy_addr_to_reg (XEXP (orig_src, 0)); if (TARGET_STRING) /* string instructions are available */ { @@ -1242,8 +1245,8 @@ expand_block_move (operands) && !fixed_regs[12]) { move_bytes = (bytes > 32) ? 32 : bytes; - emit_insn (gen_movstrsi_8reg (dest_reg, - src_reg, + emit_insn (gen_movstrsi_8reg (expand_block_move_mem (BLKmode, dest_reg, orig_dest), + expand_block_move_mem (BLKmode, src_reg, orig_src), GEN_INT ((move_bytes == 32) ? 0 : move_bytes), align_rtx)); } @@ -1256,8 +1259,8 @@ expand_block_move (operands) && !fixed_regs[12]) { move_bytes = (bytes > 24) ? 24 : bytes; - emit_insn (gen_movstrsi_6reg (dest_reg, - src_reg, + emit_insn (gen_movstrsi_6reg (expand_block_move_mem (BLKmode, dest_reg, orig_dest), + expand_block_move_mem (BLKmode, src_reg, orig_src), GEN_INT (move_bytes), align_rtx)); } @@ -1268,16 +1271,16 @@ expand_block_move (operands) && !fixed_regs[12]) { move_bytes = (bytes > 16) ? 16 : bytes; - emit_insn (gen_movstrsi_4reg (dest_reg, - src_reg, + emit_insn (gen_movstrsi_4reg (expand_block_move_mem (BLKmode, dest_reg, orig_dest), + expand_block_move_mem (BLKmode, src_reg, orig_src), GEN_INT (move_bytes), align_rtx)); } else if (bytes > 4 && !TARGET_64BIT) { /* move up to 8 bytes at a time */ move_bytes = (bytes > 8) ? 8 : bytes; - emit_insn (gen_movstrsi_2reg (dest_reg, - src_reg, + emit_insn (gen_movstrsi_2reg (expand_block_move_mem (BLKmode, dest_reg, orig_dest), + expand_block_move_mem (BLKmode, src_reg, orig_src), GEN_INT (move_bytes), align_rtx)); } @@ -1285,28 +1288,28 @@ expand_block_move (operands) { /* move 4 bytes */ move_bytes = 4; tmp_reg = gen_reg_rtx (SImode); - emit_move_insn (tmp_reg, gen_rtx (MEM, SImode, src_reg)); - emit_move_insn (gen_rtx (MEM, SImode, dest_reg), tmp_reg); + emit_move_insn (tmp_reg, expand_block_move_mem (SImode, src_reg, orig_src)); + emit_move_insn (expand_block_move_mem (SImode, dest_reg, orig_dest), tmp_reg); } else if (bytes == 2 && (align >= 2 || !STRICT_ALIGNMENT)) { /* move 2 bytes */ move_bytes = 2; tmp_reg = gen_reg_rtx (HImode); - emit_move_insn (tmp_reg, gen_rtx (MEM, HImode, src_reg)); - emit_move_insn (gen_rtx (MEM, HImode, dest_reg), tmp_reg); + emit_move_insn (tmp_reg, expand_block_move_mem (HImode, src_reg, orig_src)); + emit_move_insn (expand_block_move_mem (HImode, dest_reg, orig_dest), tmp_reg); } else if (bytes == 1) /* move 1 byte */ { move_bytes = 1; tmp_reg = gen_reg_rtx (QImode); - emit_move_insn (tmp_reg, gen_rtx (MEM, QImode, src_reg)); - emit_move_insn (gen_rtx (MEM, QImode, dest_reg), tmp_reg); + emit_move_insn (tmp_reg, expand_block_move_mem (QImode, src_reg, orig_src)); + emit_move_insn (expand_block_move_mem (QImode, dest_reg, orig_dest), tmp_reg); } else { /* move up to 4 bytes at a time */ move_bytes = (bytes > 4) ? 4 : bytes; - emit_insn (gen_movstrsi_1reg (dest_reg, - src_reg, + emit_insn (gen_movstrsi_1reg (expand_block_move_mem (BLKmode, dest_reg, orig_dest), + expand_block_move_mem (BLKmode, src_reg, orig_src), GEN_INT (move_bytes), align_rtx)); } @@ -1337,26 +1340,33 @@ expand_block_move (operands) } /* Generate the appropriate load and store, saving the stores for later */ - if (bytes >= 4 && (align >= 4 || !STRICT_ALIGNMENT)) + if (bytes >= 8 && TARGET_64BIT && (align >= 8 || !STRICT_ALIGNMENT)) + { + move_bytes = 8; + tmp_reg = gen_reg_rtx (DImode); + emit_insn (gen_movdi (tmp_reg, expand_block_move_mem (DImode, src_addr, orig_src))); + stores[ num_reg++ ] = gen_movdi (expand_block_move_mem (DImode, dest_addr, orig_dest), tmp_reg); + } + else if (bytes >= 4 && (align >= 4 || !STRICT_ALIGNMENT)) { move_bytes = 4; tmp_reg = gen_reg_rtx (SImode); - emit_insn (gen_movsi (tmp_reg, gen_rtx (MEM, SImode, src_addr))); - stores[ num_reg++ ] = gen_movsi (gen_rtx (MEM, SImode, dest_addr), tmp_reg); + emit_insn (gen_movsi (tmp_reg, expand_block_move_mem (SImode, src_addr, orig_src))); + stores[ num_reg++ ] = gen_movsi (expand_block_move_mem (SImode, dest_addr, orig_dest), tmp_reg); } else if (bytes >= 2 && (align >= 2 || !STRICT_ALIGNMENT)) { move_bytes = 2; tmp_reg = gen_reg_rtx (HImode); - emit_insn (gen_movhi (tmp_reg, gen_rtx (MEM, HImode, src_addr))); - stores[ num_reg++ ] = gen_movhi (gen_rtx (MEM, HImode, dest_addr), tmp_reg); + emit_insn (gen_movsi (tmp_reg, expand_block_move_mem (HImode, src_addr, orig_src))); + stores[ num_reg++ ] = gen_movhi (expand_block_move_mem (HImode, dest_addr, orig_dest), tmp_reg); } else { move_bytes = 1; tmp_reg = gen_reg_rtx (QImode); - emit_insn (gen_movqi (tmp_reg, gen_rtx (MEM, QImode, src_addr))); - stores[ num_reg++ ] = gen_movqi (gen_rtx (MEM, QImode, dest_addr), tmp_reg); + emit_insn (gen_movsi (tmp_reg, expand_block_move_mem (QImode, src_addr, orig_src))); + stores[ num_reg++ ] = gen_movqi (expand_block_move_mem (QImode, dest_addr, orig_dest), tmp_reg); } if (num_reg >= MAX_MOVE_REG) @@ -1367,11 +1377,8 @@ expand_block_move (operands) } } - if (num_reg > 0) - { - for (i = 0; i < num_reg; i++) - emit_insn (stores[i]); - } + for (i = 0; i < num_reg; i++) + emit_insn (stores[i]); } return 1; @@ -2611,6 +2618,9 @@ output_prolog (file, size) { rs6000_stack_t *info = rs6000_stack_info (); char *store_reg = (TARGET_64BIT) ? "\tstd %s,%d(%s)" : "\t{st|stw} %s,%d(%s)\n"; + int reg_size = info->reg_size; + int sp_reg = 1; + int sp_offset = 0; if (TARGET_DEBUG_STACK) debug_stack_info (info); @@ -2644,12 +2654,38 @@ output_prolog (file, size) common_mode_defined = 1; } + /* For V.4, update stack before we do any saving and set back pointer. */ +#ifdef USING_SVR4_H + if (info->push_p && TARGET_V4_CALLS) + { + if (info->total_size < 32767) + { + asm_fprintf (file, + (!TARGET_64BIT) ? "\t{stu|stwu} %s,%d(%s)\n" : "\tstdu %s,%d(%s)\n", + reg_names[1], - info->total_size, reg_names[1]); + sp_offset = info->total_size; + } + else + { + int neg_size = - info->total_size; + sp_reg = 12; + asm_fprintf (file, "\tmr %s,%s\n", reg_names[12], reg_names[1]); + asm_fprintf (file, "\t{liu|lis} %s,%d\n\t{oril|ori} %s,%s,%d\n", + reg_names[0], (neg_size >> 16) & 0xffff, + reg_names[0], reg_names[0], neg_size & 0xffff); + asm_fprintf (file, + (!TARGET_64BIT) ? "\t{stux|stwux} %s,%s,%s\n" : "\tstdux %s,%s,%s\n", + reg_names[1], reg_names[1], reg_names[0]); + } + } +#endif + /* If we use the link register, get it into r0. */ if (info->lr_save_p) asm_fprintf (file, "\tmflr %s\n", reg_names[0]); /* If we need to save CR, put it into r12. */ - if (info->cr_save_p) + if (info->cr_save_p && sp_reg != 12) asm_fprintf (file, "\tmfcr %s\n", reg_names[12]); /* Do any required saving of fpr's. If only one or two to save, do it @@ -2658,10 +2694,10 @@ output_prolog (file, size) if (FP_SAVE_INLINE (info->first_fp_reg_save)) { int regno = info->first_fp_reg_save; - int loc = info->fp_save_offset; + int loc = info->fp_save_offset + sp_offset; for ( ; regno < 64; regno++, loc += 8) - asm_fprintf (file, "\tstfd %s,%d(%s)\n", reg_names[regno], loc, reg_names[1]); + asm_fprintf (file, "\tstfd %s,%d(%s)\n", reg_names[regno], loc, reg_names[sp_reg]); } else if (info->first_fp_reg_save != 64) asm_fprintf (file, "\tbl %s%d%s\n", SAVE_FP_PREFIX, @@ -2671,29 +2707,44 @@ output_prolog (file, size) if (! TARGET_MULTIPLE || info->first_gp_reg_save == 31 || TARGET_64BIT) { int regno = info->first_gp_reg_save; - int loc = info->gp_save_offset; - int reg_size = (TARGET_64BIT) ? 8 : 4; + int loc = info->gp_save_offset + sp_offset; for ( ; regno < 32; regno++, loc += reg_size) - asm_fprintf (file, store_reg, reg_names[regno], loc, reg_names[1]); + asm_fprintf (file, store_reg, reg_names[regno], loc, reg_names[sp_reg]); } else if (info->first_gp_reg_save != 32) asm_fprintf (file, "\t{stm|stmw} %s,%d(%s)\n", reg_names[info->first_gp_reg_save], - info->gp_save_offset, - reg_names[1]); + info->gp_save_offset + sp_offset, + reg_names[sp_reg]); /* Save lr if we used it. */ if (info->lr_save_p) - asm_fprintf (file, store_reg, reg_names[0], info->lr_save_offset, reg_names[1]); + asm_fprintf (file, store_reg, reg_names[0], info->lr_save_offset + sp_offset, + reg_names[sp_reg]); /* Save CR if we use any that must be preserved. */ if (info->cr_save_p) - asm_fprintf (file, store_reg, reg_names[12], info->cr_save_offset, reg_names[1]); + { + if (sp_reg == 12) /* If r12 is used to hold the original sp, copy cr now */ + { + asm_fprintf (file, "\tmfcr %s\n", reg_names[0]); + asm_fprintf (file, store_reg, reg_names[0], + info->cr_save_offset + sp_offset, + reg_names[sp_reg]); + } + else + asm_fprintf (file, store_reg, reg_names[12], info->cr_save_offset + sp_offset, + reg_names[sp_reg]); + } - /* Update stack and set back pointer. */ - if (info->push_p) + /* Update stack and set back pointer and we have already done so for V.4. */ + if (info->push_p +#ifdef USING_SVR4_H + && TARGET_AIX_CALLS +#endif + ) { if (info->total_size < 32767) asm_fprintf (file, @@ -2791,6 +2842,8 @@ output_epilog (file, size) rs6000_stack_t *info = rs6000_stack_info (); char *load_reg = (TARGET_64BIT) ? "\tld %s,%d(%s)" : "\t{l|lwz} %s,%d(%s)\n"; rtx insn = get_last_insn (); + int sp_reg = 1; + int sp_offset = 0; int i; /* Forget about any temporaries created */ @@ -2808,9 +2861,23 @@ output_epilog (file, size) we know what size to update it with. */ if (frame_pointer_needed || current_function_calls_alloca || info->total_size > 32767) - asm_fprintf (file, load_reg, reg_names[1], 0, reg_names[1]); + { + /* Under V.4, don't reset the stack pointer until after we're done + loading the saved registers. */ +#ifdef USING_SVR4_H + if (TARGET_V4_CALLS) + sp_reg = 11; +#endif + + asm_fprintf (file, load_reg, reg_names[sp_reg], 0, reg_names[1]); + } else if (info->push_p) { +#ifdef USING_SVR4_H + if (TARGET_V4_CALLS) + sp_offset = info->total_size; + else +#endif if (TARGET_NEW_MNEMONICS) asm_fprintf (file, "\taddi %s,%s,%d\n", reg_names[1], reg_names[1], info->total_size); else @@ -2819,11 +2886,11 @@ output_epilog (file, size) /* Get the old lr if we saved it. */ if (info->lr_save_p) - asm_fprintf (file, load_reg, reg_names[0], info->lr_save_offset, reg_names[1]); + asm_fprintf (file, load_reg, reg_names[0], info->lr_save_offset + sp_offset, reg_names[sp_reg]); /* Get the old cr if we saved it. */ if (info->cr_save_p) - asm_fprintf (file, load_reg, reg_names[12], info->cr_save_offset, reg_names[1]); + asm_fprintf (file, load_reg, reg_names[12], info->cr_save_offset + sp_offset, reg_names[sp_reg]); /* Set LR here to try to overlap restores below. */ if (info->lr_save_p) @@ -2833,27 +2900,27 @@ output_epilog (file, size) if (! TARGET_MULTIPLE || info->first_gp_reg_save == 31 || TARGET_64BIT) { int regno = info->first_gp_reg_save; - int loc = info->gp_save_offset; + int loc = info->gp_save_offset + sp_offset; int reg_size = (TARGET_64BIT) ? 8 : 4; for ( ; regno < 32; regno++, loc += reg_size) - asm_fprintf (file, load_reg, reg_names[regno], loc, reg_names[1]); + asm_fprintf (file, load_reg, reg_names[regno], loc, reg_names[sp_reg]); } else if (info->first_gp_reg_save != 32) asm_fprintf (file, "\t{lm|lmw} %s,%d(%s)\n", reg_names[info->first_gp_reg_save], - info->gp_save_offset, - reg_names[1]); + info->gp_save_offset + sp_offset, + reg_names[sp_reg]); /* Restore fpr's if we can do it without calling a function. */ if (FP_SAVE_INLINE (info->first_fp_reg_save)) { int regno = info->first_fp_reg_save; - int loc = info->fp_save_offset; + int loc = info->fp_save_offset + sp_offset; for ( ; regno < 64; regno++, loc += 8) - asm_fprintf (file, "\tlfd %s,%d(%s)\n", reg_names[regno], loc, reg_names[1]); + asm_fprintf (file, "\tlfd %s,%d(%s)\n", reg_names[regno], loc, reg_names[sp_reg]); } /* If we saved cr, restore it here. Just those of cr2, cr3, and cr4 @@ -2864,6 +2931,19 @@ output_epilog (file, size) + (regs_ever_live[71] != 0) * 0x10 + (regs_ever_live[72] != 0) * 0x8, reg_names[12]); + /* If this is V.4, unwind the stack pointer after all of the loads have been done */ +#ifdef USING_SVR4_H + if (sp_offset) + { + if (TARGET_NEW_MNEMONICS) + asm_fprintf (file, "\taddi %s,%s,%d\n", reg_names[1], reg_names[1], sp_offset); + else + asm_fprintf (file, "\tcal %s,%d(%s)\n", reg_names[1], sp_offset, reg_names[1]); + } + else if (sp_reg != 1) + asm_fprintf (file, "\tmr %s,%s\n", reg_names[1], reg_names[sp_reg]); +#endif + /* If we have to restore more than two FP registers, branch to the restore function. It will return to our caller. */ if (info->first_fp_reg_save != 64 && !FP_SAVE_INLINE (info->first_fp_reg_save)) diff --git a/gnu/usr.bin/gcc/config/rs6000/rs6000.md b/gnu/usr.bin/gcc/config/rs6000/rs6000.md index 3a975abe03f..99ca900c3dd 100644 --- a/gnu/usr.bin/gcc/config/rs6000/rs6000.md +++ b/gnu/usr.bin/gcc/config/rs6000/rs6000.md @@ -814,7 +814,7 @@ (set (match_operand:SI 0 "gpc_reg_operand" "=r") (not:SI (match_dup 1)))] "" - "nor. %0,%2,%1" + "nor. %0,%1,%1" [(set_attr "type" "compare")]) (define_insn "" @@ -1492,7 +1492,9 @@ (set (reg:SI 4) (umod:SI (reg:SI 3) (reg:SI 4))) (clobber (match_scratch:SI 0 "=l")) - (clobber (reg:SI 0))] + (clobber (reg:SI 0)) + (clobber (match_scratch:CC 1 "=x")) + (clobber (reg:CC 69))] "! TARGET_POWER && ! TARGET_POWERPC" "bla __divus") @@ -1507,7 +1509,9 @@ [(set (reg:SI 3) (udiv:SI (reg:SI 3) (reg:SI 4))) (clobber (match_scratch:SI 0 "=l")) - (clobber (reg:SI 0))] + (clobber (reg:SI 0)) + (clobber (match_scratch:CC 1 "=x")) + (clobber (reg:CC 69))] "! TARGET_POWER && ! TARGET_POWERPC" "bla __quous") @@ -4823,10 +4827,10 @@ ;; Argument 3 is the alignment (define_expand "movstrsi" - [(parallel [(set (match_operand:BLK 0 "memory_operand" "") - (match_operand:BLK 1 "memory_operand" "")) - (use (match_operand:SI 2 "general_operand" "")) - (use (match_operand:SI 3 "immediate_operand" ""))])] + [(parallel [(set (match_operand:BLK 0 "" "") + (match_operand:BLK 1 "" "")) + (use (match_operand:SI 2 "" "")) + (use (match_operand:SI 3 "" ""))])] "" " { @@ -4839,10 +4843,10 @@ ;; Move up to 32 bytes at a time. The fixed registers are needed because the ;; register allocator doesn't have a clue about allocating 8 word registers (define_expand "movstrsi_8reg" - [(parallel [(set (mem:BLK (match_operand:SI 0 "register_operand" "")) - (mem:BLK (match_operand:SI 1 "register_operand" ""))) - (use (match_operand:SI 2 "immediate_operand" "")) - (use (match_operand:SI 3 "immediate_operand" "")) + [(parallel [(set (match_operand 0 "" "") + (match_operand 1 "" "")) + (use (match_operand 2 "" "")) + (use (match_operand 3 "" "")) (clobber (reg:SI 5)) (clobber (reg:SI 6)) (clobber (reg:SI 7)) @@ -4875,7 +4879,8 @@ && (REGNO (operands[1]) < 5 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 5" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) (define_insn "" [(set (mem:BLK (match_operand:SI 0 "register_operand" "b")) @@ -4897,15 +4902,16 @@ && (REGNO (operands[1]) < 5 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 5" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) ;; Move up to 24 bytes at a time. The fixed registers are needed because the ;; register allocator doesn't have a clue about allocating 6 word registers (define_expand "movstrsi_6reg" - [(parallel [(set (mem:BLK (match_operand:SI 0 "register_operand" "")) - (mem:BLK (match_operand:SI 1 "register_operand" ""))) - (use (match_operand:SI 2 "immediate_operand" "")) - (use (match_operand:SI 3 "immediate_operand" "")) + [(parallel [(set (match_operand 0 "" "") + (match_operand 1 "" "")) + (use (match_operand 2 "" "")) + (use (match_operand 3 "" "")) (clobber (reg:SI 7)) (clobber (reg:SI 8)) (clobber (reg:SI 9)) @@ -4934,7 +4940,8 @@ && (REGNO (operands[1]) < 7 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 7" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) (define_insn "" [(set (mem:BLK (match_operand:SI 0 "register_operand" "b")) @@ -4954,15 +4961,16 @@ && (REGNO (operands[1]) < 7 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 7" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) ;; Move up to 16 bytes at a time, using 4 fixed registers to avoid spill problems ;; with TImode (define_expand "movstrsi_4reg" - [(parallel [(set (mem:BLK (match_operand:SI 0 "register_operand" "")) - (mem:BLK (match_operand:SI 1 "register_operand" ""))) - (use (match_operand:SI 2 "immediate_operand" "")) - (use (match_operand:SI 3 "immediate_operand" "")) + [(parallel [(set (match_operand 0 "" "") + (match_operand 1 "" "")) + (use (match_operand 2 "" "")) + (use (match_operand 3 "" "")) (clobber (reg:SI 9)) (clobber (reg:SI 10)) (clobber (reg:SI 11)) @@ -4987,7 +4995,8 @@ && (REGNO (operands[1]) < 9 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 9" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) (define_insn "" [(set (mem:BLK (match_operand:SI 0 "register_operand" "b")) @@ -5005,14 +5014,15 @@ && (REGNO (operands[1]) < 9 || REGNO (operands[1]) > 12) && REGNO (operands[4]) == 9" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) ;; Move up to 8 bytes at a time. (define_expand "movstrsi_2reg" - [(parallel [(set (mem:BLK (match_operand:SI 0 "register_operand" "")) - (mem:BLK (match_operand:SI 1 "register_operand" ""))) - (use (match_operand:SI 2 "immediate_operand" "")) - (use (match_operand:SI 3 "immediate_operand" "")) + [(parallel [(set (match_operand 0 "" "") + (match_operand 1 "" "")) + (use (match_operand 2 "" "")) + (use (match_operand 3 "" "")) (clobber (match_scratch:DI 4 "")) (clobber (match_scratch:SI 5 ""))])] "TARGET_STRING && !TARGET_64BIT" @@ -5028,7 +5038,8 @@ "TARGET_STRING && TARGET_POWER && !TARGET_64BIT && INTVAL (operands[2]) > 4 && INTVAL (operands[2]) <= 8" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) (define_insn "" [(set (mem:BLK (match_operand:SI 0 "register_operand" "b")) @@ -5040,14 +5051,15 @@ "TARGET_STRING && !TARGET_POWER && !TARGET_64BIT && INTVAL (operands[2]) > 4 && INTVAL (operands[2]) <= 8" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) ;; Move up to 4 bytes at a time. (define_expand "movstrsi_1reg" - [(parallel [(set (mem:BLK (match_operand:SI 0 "register_operand" "")) - (mem:BLK (match_operand:SI 1 "register_operand" ""))) - (use (match_operand:SI 2 "immediate_operand" "")) - (use (match_operand:SI 3 "immediate_operand" "")) + [(parallel [(set (match_operand 0 "" "") + (match_operand 1 "" "")) + (use (match_operand 2 "" "")) + (use (match_operand 3 "" "")) (clobber (match_scratch:SI 4 "")) (clobber (match_scratch:SI 5 ""))])] "TARGET_STRING" @@ -5063,7 +5075,8 @@ "TARGET_STRING && TARGET_POWER && INTVAL (operands[2]) > 0 && INTVAL (operands[2]) <= 4" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) (define_insn "" [(set (mem:BLK (match_operand:SI 0 "register_operand" "b")) @@ -5075,7 +5088,8 @@ "TARGET_STRING && !TARGET_POWER && INTVAL (operands[2]) > 0 && INTVAL (operands[2]) <= 4" "{lsi|lswi} %4,%1,%2\;{stsi|stswi} %4,%0,%2" - [(set_attr "length" "8")]) + [(set_attr "type" "load") + (set_attr "length" "8")]) ;; Define insns that do load or store with update. Some of these we can diff --git a/gnu/usr.bin/gcc/config/sparc/sparc.h b/gnu/usr.bin/gcc/config/sparc/sparc.h index 5edf530050d..d8ba186c7f2 100644 --- a/gnu/usr.bin/gcc/config/sparc/sparc.h +++ b/gnu/usr.bin/gcc/config/sparc/sparc.h @@ -621,18 +621,10 @@ do \ for (regno = 32; regno < FIRST_PSEUDO_REGISTER; regno++) \ fixed_regs[regno] = 1; \ } \ - if (! TARGET_APP_REGS) \ - { \ - fixed_regs[2] = 1; \ - fixed_regs[3] = 1; \ - fixed_regs[4] = 1; \ - } \ - else \ - { \ - fixed_regs[2] = 0; \ - fixed_regs[3] = 0; \ - fixed_regs[4] = TARGET_MEDANY != 0; \ - } \ + /* Don't unfix g2-g4 if they were fixed with -ffixed-. */ \ + fixed_regs[2] |= ! TARGET_APP_REGS; \ + fixed_regs[3] |= ! TARGET_APP_REGS; \ + fixed_regs[4] |= ! TARGET_APP_REGS || TARGET_MEDANY; \ if (TARGET_FLAT) \ { \ /* Let the compiler believe the frame pointer is still \ diff --git a/gnu/usr.bin/gcc/config/svr4.h b/gnu/usr.bin/gcc/config/svr4.h index bc80297359d..41c6ffa0e10 100644 --- a/gnu/usr.bin/gcc/config/svr4.h +++ b/gnu/usr.bin/gcc/config/svr4.h @@ -273,15 +273,23 @@ do { \ #define DBX_BLOCKS_FUNCTION_RELATIVE 1 /* When using stabs, gcc2_compiled must be a stabs entry, not an - ordinary symbol, or gdb won't see it. The stabs entry must be - before the N_SO in order for gdb to find it. */ + ordinary symbol, or gdb won't see it. Furthermore, since gdb reads + the input piecemeal, starting with each N_SO, it's a lot easier if + the gcc2 flag symbol is *after* the N_SO rather than before it. So + we emit an N_OPT stab there. */ #define ASM_IDENTIFY_GCC(FILE) \ do \ { \ if (write_symbols != DBX_DEBUG) \ fputs ("gcc2_compiled.:\n", FILE); \ - else \ + } \ +while (0) + +#define ASM_IDENTIFY_GCC_AFTER_SOURCE(FILE) \ +do \ + { \ + if (write_symbols == DBX_DEBUG) \ fputs ("\t.stabs\t\"gcc2_compiled.\", 0x3c, 0, 0, 0\n", FILE); \ } \ while (0) diff --git a/gnu/usr.bin/gcc/config/vax/vax.h b/gnu/usr.bin/gcc/config/vax/vax.h index 99386c08903..10ba85509c6 100644 --- a/gnu/usr.bin/gcc/config/vax/vax.h +++ b/gnu/usr.bin/gcc/config/vax/vax.h @@ -963,7 +963,8 @@ gen_rtx (PLUS, Pmode, frame, gen_rtx (CONST_INT, VOIDmode, 12)) { if (GET_CODE (EXP) == SET) \ { if (GET_CODE (SET_SRC (EXP)) == CALL) \ CC_STATUS_INIT; \ - else if (GET_CODE (SET_DEST (EXP)) != PC) \ + else if (GET_CODE (SET_DEST (EXP)) != ZERO_EXTRACT \ + && GET_CODE (SET_DEST (EXP)) != PC) \ { cc_status.flags = 0; \ cc_status.value1 = SET_DEST (EXP); \ cc_status.value2 = SET_SRC (EXP); } } \ diff --git a/gnu/usr.bin/gcc/config/vax/vax.md b/gnu/usr.bin/gcc/config/vax/vax.md index 3dd73df62aa..0b0c5c4ac66 100644 --- a/gnu/usr.bin/gcc/config/vax/vax.md +++ b/gnu/usr.bin/gcc/config/vax/vax.md @@ -1341,6 +1341,7 @@ operands[0] = adj_offsettable_operand (operands[0], INTVAL (operands[2]) / 8); + CC_STATUS_INIT; if (INTVAL (operands[1]) == 8) return \"movb %3,%0\"; return \"movw %3,%0\"; diff --git a/gnu/usr.bin/gcc/config/winnt/config-nt.sed b/gnu/usr.bin/gcc/config/winnt/config-nt.sed index ee0088ad818..d70f5c6cc74 100644 --- a/gnu/usr.bin/gcc/config/winnt/config-nt.sed +++ b/gnu/usr.bin/gcc/config/winnt/config-nt.sed @@ -13,7 +13,7 @@ s/$(srcdir)\/c-gperf/c-gperf/g /^lang_specs_files=/ d /^lang_options_files=/ d /^version=/ c\ -version=2.7.2 +version=2.7.2.1 s/CC = cc/CC = cl/ s/^SHELL =.*/SHELL =/ s/CFLAGS = -g/CFLAGS =/ diff --git a/gnu/usr.bin/gcc/cp/decl2.c b/gnu/usr.bin/gcc/cp/decl2.c index 7a3f7d5e094..9b7f88e2d68 100644 --- a/gnu/usr.bin/gcc/cp/decl2.c +++ b/gnu/usr.bin/gcc/cp/decl2.c @@ -1363,7 +1363,7 @@ grokfield (declarator, declspecs, raises, init, asmspec_tree, attrlist) init = NULL_TREE; value = grokdeclarator (declarator, declspecs, FIELD, init != 0, - raises, attrlist); + raises, NULL_TREE); if (! value) return value; /* friend or constructor went bad. */ @@ -1477,6 +1477,10 @@ grokfield (declarator, declspecs, raises, init, asmspec_tree, attrlist) /* The corresponding pop_obstacks is in cp_finish_decl. */ push_obstacks_nochange (); + if (attrlist) + cplus_decl_attributes (value, TREE_PURPOSE (attrlist), + TREE_VALUE (attrlist)); + if (TREE_CODE (value) == VAR_DECL) { /* We cannot call pushdecl here, because that would diff --git a/gnu/usr.bin/gcc/cp/lex.c b/gnu/usr.bin/gcc/cp/lex.c index 1861f9ea977..22763f56f62 100644 --- a/gnu/usr.bin/gcc/cp/lex.c +++ b/gnu/usr.bin/gcc/cp/lex.c @@ -3313,6 +3313,14 @@ real_yylex () token_buffer[0] = '^'; token_buffer[1] = 0; } + else if (ptr->token == NAMESPACE) + { + static int warned; + if (! warned) + warning ("namespaces are mostly broken in this version of g++"); + + warned = 1; + } value = (int) ptr->token; } diff --git a/gnu/usr.bin/gcc/expr.c b/gnu/usr.bin/gcc/expr.c index 2d307a2af67..39591c9efef 100644 --- a/gnu/usr.bin/gcc/expr.c +++ b/gnu/usr.bin/gcc/expr.c @@ -4582,7 +4582,7 @@ expand_expr (exp, target, tmode, modifier) through a pointer to const does not mean that the value there can never change. Languages where it can never change should also set TREE_STATIC. */ - RTX_UNCHANGING_P (temp) = TREE_READONLY (exp) | TREE_STATIC (exp); + RTX_UNCHANGING_P (temp) = TREE_READONLY (exp) & TREE_STATIC (exp); return temp; } diff --git a/gnu/usr.bin/gcc/fix-header.c b/gnu/usr.bin/gcc/fix-header.c index 53e5c06052a..7059d12e102 100644 --- a/gnu/usr.bin/gcc/fix-header.c +++ b/gnu/usr.bin/gcc/fix-header.c @@ -531,7 +531,18 @@ read_scan_file (in_fname, argc, argv) push_parse_file (&scan_in, in_fname); CPP_OPTIONS (&scan_in)->no_line_commands = 1; +#ifdef FIXPROTO_INIT + /* Some targets may assume special definitions (for example + OSF header files assume __LANGUAGE_C__). These macros + are normally passed to cpplib by gcc - but we here invoke + cpplib directly, without going through gcc. + Handle these and other target-dependent initializations here. */ + FIXPROTO_INIT (&scan_in); +#endif + + /* Actually (pre-)process the header file. */ scan_decls (&scan_in, argc, argv); + check_macro_names (&scan_in, include_entry->required); check_macro_names (&scan_in, include_entry->extra); diff --git a/gnu/usr.bin/gcc/fixincludes b/gnu/usr.bin/gcc/fixincludes index ba6781df59e..cc8801d349b 100644 --- a/gnu/usr.bin/gcc/fixincludes +++ b/gnu/usr.bin/gcc/fixincludes @@ -1520,6 +1520,33 @@ if [ -r ${LIB}/$file ]; then fi fi +# sys/wait.h on AIX 3.2.5 puts the declaration of wait3 before the definition +# of struct rusage, so the prototype (added by fixproto) causes havoc. +file=sys/wait.h +if [ -r $file ] && [ ! -r ${LIB}/$file ]; then + cp $file ${LIB}/$file >/dev/null 2>&1 || echo "Can't copy $file" + chmod +w ${LIB}/$file 2>/dev/null +fi + +if [ -r ${LIB}/$file ] \ + && grep 'bos325,' ${LIB}/$file >/dev/null; then + echo Fixing $file, wait3 declaration + sed -e '/^extern pid_t wait3();$/i\ +struct rusage; +'\ + ${LIB}/$file > ${LIB}/${file}.sed + rm -f ${LIB}/$file; mv ${LIB}/${file}.sed ${LIB}/$file + if cmp $file ${LIB}/$file >/dev/null 2>&1; then + rm -f ${LIB}/$file + else + # Find any include directives that use "file". + for include in `egrep '^[ ]*#[ ]*include[ ]*"[^/]' ${LIB}/$file | sed -e 's/^[ ]*#[ ]*include[ ]*"\([^"]*\)".*$/\1/'`; do + dir=`echo $file | sed -e s'|/[^/]*$||'` + required="$required ${INPUT} $dir/$include ${LIB}/$dir/$include" + done + fi +fi + # NeXT 2.0 defines 'int wait(union wait*)', which conflicts with Posix.1. # Note that version 3 of the NeXT system has wait.h in a different directory, # so that this code won't do anything. But wait.h in version 3 has a diff --git a/gnu/usr.bin/gcc/gcc.texi b/gnu/usr.bin/gcc/gcc.texi index f0638e7db4a..bfcf1997090 100644 --- a/gnu/usr.bin/gcc/gcc.texi +++ b/gnu/usr.bin/gcc/gcc.texi @@ -147,12 +147,12 @@ original English. @sp 2 @center Richard M. Stallman @sp 3 -@center Last updated 26 November 1995 +@center Last updated 29 June 1996 @center (Revised for GNU Fortran 1996-03-06) @sp 1 @c The version number appears twice more in this file. -@center for version 2.7.2 +@center for version 2.7.2.1 @page @vskip 0pt plus 1filll Copyright @copyright{} 1988, 89, 92, 93, 94, 1995 Free Software Foundation, Inc. @@ -905,18 +905,23 @@ the ones who have actually sued. Apple's lawsuit was defeated, for reasons only partly related to the general issue of interface copyright. Lotus won lawsuits against two small companies, which were thus put out -of business. Then they sued Borland; they won in the trial court (no +of business. Then Lotus sued Borland; Lotus won in the trial court (no surprise, since it was the same court that had ruled for Lotus twice -before), but the decision was reversed by the court of appeals, with -help from the League for Programming Freedom in the form of a -friend-of-the-court brief. We are now waiting to see if the Supreme -Court will hear the case. If it does, the League for Programming -Freedom will again submit a brief. - -The battle is not over. Just this summer a company that produced a -simulator for a CDC computer was shut down by a copyright lawsuit by -CDC, which charged that the simulator infringed the copyright on the -manuals for the computer. +before), but the court of appeals ruled in favor of Borland, which was +assisted by a friend-of-the-court brief from the League for Programming +Freedom. + +Lotus appealed the case to the Supreme Court, which heard the case but +was unable to reach a decision. This failure means that the appeals +court decision stands, in one portion of the United States, and may +influence the other appeals courts, but it does not set a nationwide +precedent. The battle is not over, and it is not limited to the United +States. + +The battle is extending into other areas of software as well. In 1995 a +company that produced a simulator for a CDC computer was shut down by a +copyright lawsuit, in which CDC charged that the simulator infringed the +copyright on the manuals for the computer. If the monopolists get their way, they will hobble the software field: @@ -1239,11 +1244,11 @@ GNU CC. The fix is to get rid of the file @code{real-ld} which purify installs---so that GNU CC won't try to use it. @item -On Linux SLS 1.01, there is a problem with @file{libc.a}: it does not -contain the obstack functions. However, GNU CC assumes that the obstack -functions are in @file{libc.a} when it is the GNU C library. To work -around this problem, change the @code{__GNU_LIBRARY__} conditional -around line 31 to @samp{#if 1}. +On SLS 1.01, a Linux-based GNU system, there is a problem with +@file{libc.a}: it does not contain the obstack functions. However, GNU +CC assumes that the obstack functions are in @file{libc.a} when it is +the GNU C library. To work around this problem, change the +@code{__GNU_LIBRARY__} conditional around line 31 to @samp{#if 1}. @item On some 386 systems, building the compiler never finishes because diff --git a/gnu/usr.bin/gcc/install.texi b/gnu/usr.bin/gcc/install.texi index 0a4c99b97cf..962a6e7a088 100644 --- a/gnu/usr.bin/gcc/install.texi +++ b/gnu/usr.bin/gcc/install.texi @@ -778,82 +778,45 @@ first three arguments in function calls in registers. Structures are no longer a multiple of 2 bytes. @item hppa*-*-* -There are two variants of this CPU, called 1.0 and 1.1, which have -different machine descriptions. You must use the right one for your -machine. All 7@var{nn} machines and 8@var{n}7 machines use 1.1, while -all other 8@var{nn} machines use 1.0. - -The easiest way to handle this problem is to use @samp{configure -hp@var{nnn}} or @samp{configure hp@var{nnn}-hpux}, where @var{nnn} is -the model number of the machine. Then @file{configure} will figure out -if the machine is a 1.0 or 1.1. Use @samp{uname -a} to find out the -model number of your machine. +There are several variants of the HP-PA processor which run a variety +of operating systems. GNU CC must be configured to use the correct +processor type and operating system, or GNU CC will not function correctly. +The easiest way to handle this problem is to @emph{not} specify a target +when configuring GNU CC, the @file{configure} script will try to automatically +determine the right processor type and operating system. @samp{-g} does not work on HP-UX, since that system uses a peculiar debugging format which GNU CC does not know about. However, @samp{-g} will work if you also use GAS and GDB in conjunction with GCC. We highly recommend using GAS for all HP-PA configurations. -You should be using GAS-2.3 (or later) along with GDB-4.12 (or later). These +You should be using GAS-2.6 (or later) along with GDB-4.16 (or later). These can be retrieved from all the traditional GNU ftp archive sites. -Build GAS and install the resulting binary as: - -@example -/usr/local/lib/gcc-lib/@var{configuration}/@var{gccversion}/as -@end example - -@noindent -where @var{configuration} is the configuration name (perhaps -@samp{hp@var{nnn}-hpux}) and @var{gccversion} is the GNU CC version -number. Do this @emph{before} starting the build process, otherwise you will -get errors from the HPUX assembler while building @file{libgcc2.a}. The -command - -@example -make install-dir -@end example - -@noindent -will create the necessary directory hierarchy so you can install GAS before -building GCC. - -To enable debugging, configure GNU CC with the @samp{--with-gnu-as} option -before building. +GAS will need to be installed into a directory before @code{/bin}, +@code{/usr/bin}, and @code{/usr/ccs/bin} in your search path. You +should install GAS before you build GNU CC. -It has been reported that GNU CC produces invalid assembly code for -1.1 machines running HP-UX 8.02 when using the HP assembler. Typically -the errors look like this: -@example -as: bug.s @@line#15 [err#1060] - Argument 0 or 2 in FARG upper - - lookahead = ARGW1=FR,RTNVAL=GR -as: foo.s @@line#28 [err#1060] - Argument 0 or 2 in FARG upper - - lookahead = ARGW1=FR -@end example - -You can check the version of HP-UX you are running by executing the command -@samp{uname -r}. If you are indeed running HP-UX 8.02 on a PA and -using the HP assembler then configure GCC with "hp@var{nnn}-hpux8.02". +To enable debugging, you must configure GNU CC with the @samp{--with-gnu-as} +option before building. @item i370-*-* This port is very preliminary and has many known bugs. We hope to have a higher-quality port for this machine soon. @item i386-*-linuxoldld -Use this configuration to generate a.out binaries on Linux if you do not -have gas/binutils version 2.5.2 or later installed. This is an obsolete -configuration. +Use this configuration to generate a.out binaries on Linux-based GNU +systems, if you do not have gas/binutils version 2.5.2 or later +installed. This is an obsolete configuration. @item i386-*-linuxaout -Use this configuration to generate a.out binaries on Linux. This configuration -is being superseded. You must use gas/binutils version 2.5.2 or -later. +Use this configuration to generate a.out binaries on Linux-based GNU +systems. This configuration is being superseded. You must use +gas/binutils version 2.5.2 or later. @item i386-*-linux -Use this configuration to generate ELF binaries on Linux. You must -use gas/binutils version 2.5.2 or later. +Use this configuration to generate ELF binaries on Linux-based GNU +systems. You must use gas/binutils version 2.5.2 or later. @item i386-*-sco Compilation with RCC is recommended. Also, it may be a good idea to diff --git a/gnu/usr.bin/gcc/loop.c b/gnu/usr.bin/gcc/loop.c index c87f1c33eec..3e780203977 100644 --- a/gnu/usr.bin/gcc/loop.c +++ b/gnu/usr.bin/gcc/loop.c @@ -6042,13 +6042,16 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) { /* Can replace with any giv that was reduced and that has (MULT_VAL != 0) and (ADD_VAL == 0). - Require a constant for MULT_VAL, so we know it's nonzero. */ + Require a constant for MULT_VAL, so we know it's nonzero. + ??? We disable this optimization to avoid potential + overflows. */ for (v = bl->giv; v; v = v->next_iv) if (CONSTANT_P (v->mult_val) && v->mult_val != const0_rtx && v->add_val == const0_rtx && ! v->ignore && ! v->maybe_dead && v->always_computable - && v->mode == mode) + && v->mode == mode + && 0) { if (! eliminate_p) return 1; @@ -6068,12 +6071,19 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) /* Look for a giv with (MULT_VAL != 0) and (ADD_VAL != 0); replace test insn with a compare insn (cmp REDUCED_GIV ADD_VAL). - Require a constant for MULT_VAL, so we know it's nonzero. */ + Require a constant for MULT_VAL, so we know it's nonzero. + ??? Do this only if ADD_VAL is a pointer to avoid a potential + overflow problem. */ for (v = bl->giv; v; v = v->next_iv) if (CONSTANT_P (v->mult_val) && v->mult_val != const0_rtx && ! v->ignore && ! v->maybe_dead && v->always_computable - && v->mode == mode) + && v->mode == mode + && (GET_CODE (v->add_val) == SYMBOL_REF + || GET_CODE (v->add_val) == LABEL_REF + || GET_CODE (v->add_val) == CONST + || (GET_CODE (v->add_val) == REG + && REGNO_POINTER_FLAG (REGNO (v->add_val))))) { if (! eliminate_p) return 1; @@ -6128,7 +6138,11 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) for (v = bl->giv; v; v = v->next_iv) if (CONSTANT_P (v->mult_val) && INTVAL (v->mult_val) > 0 - && CONSTANT_P (v->add_val) + && (GET_CODE (v->add_val) == SYMBOL_REF + || GET_CODE (v->add_val) == LABEL_REF + || GET_CODE (v->add_val) == CONST + || (GET_CODE (v->add_val) == REG + && REGNO_POINTER_FLAG (REGNO (v->add_val)))) && ! v->ignore && ! v->maybe_dead && v->always_computable && v->mode == mode) { @@ -6161,12 +6175,14 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) } /* Look for giv with positive constant mult_val and nonconst add_val. - Insert insns to calculate new compare value. */ + Insert insns to calculate new compare value. + ??? Turn this off due to possible overflow. */ for (v = bl->giv; v; v = v->next_iv) if (CONSTANT_P (v->mult_val) && INTVAL (v->mult_val) > 0 && ! v->ignore && ! v->maybe_dead && v->always_computable - && v->mode == mode) + && v->mode == mode + && 0) { rtx tem; @@ -6192,12 +6208,14 @@ maybe_eliminate_biv_1 (x, insn, bl, eliminate_p, where) if (invariant_p (arg) == 1) { /* Look for giv with constant positive mult_val and nonconst - add_val. Insert insns to compute new compare value. */ + add_val. Insert insns to compute new compare value. + ??? Turn this off due to possible overflow. */ for (v = bl->giv; v; v = v->next_iv) if (CONSTANT_P (v->mult_val) && INTVAL (v->mult_val) > 0 && ! v->ignore && ! v->maybe_dead && v->always_computable - && v->mode == mode) + && v->mode == mode + && 0) { rtx tem; diff --git a/gnu/usr.bin/gcc/objc/hash.c b/gnu/usr.bin/gcc/objc/hash.c index 33912743fd8..a3077597e42 100644 --- a/gnu/usr.bin/gcc/objc/hash.c +++ b/gnu/usr.bin/gcc/objc/hash.c @@ -243,9 +243,10 @@ hash_value_for_key (cache_ptr cache, const void *key) if (node) do { - if ((*cache->compare_func)(node->key, key)) + if ((*cache->compare_func)(node->key, key)) { retval = node->value; - else + break; + } else node = node->next; } while (!retval && node); diff --git a/gnu/usr.bin/gcc/stor-layout.c b/gnu/usr.bin/gcc/stor-layout.c index 8cdbf86aa80..e743c373766 100644 --- a/gnu/usr.bin/gcc/stor-layout.c +++ b/gnu/usr.bin/gcc/stor-layout.c @@ -437,7 +437,7 @@ layout_record (rec) That can happen because the width exceeds BIGGEST_ALIGNMENT or because it exceeds maximum_field_alignment. */ if (const_size / type_align - != (const_size + field_size - 1) / type_align) + != (const_size + (field_size % type_align) - 1) / type_align) const_size = CEIL (const_size, type_align) * type_align; } #endif diff --git a/gnu/usr.bin/gcc/version.c b/gnu/usr.bin/gcc/version.c index 4afca5693ab..3480e3fdac2 100644 --- a/gnu/usr.bin/gcc/version.c +++ b/gnu/usr.bin/gcc/version.c @@ -1 +1 @@ -char *version_string = "2.7.2"; +char *version_string = "2.7.2.1"; |