svn commit: r282150 - in vendor/gcc/dist: libcpp libcpp/include libgomp libgomp/config/linux libgomp/config/mingw32 libgomp/config/posix

Pedro F. Giffuni pfg at FreeBSD.org
Tue Apr 28 16:28:31 UTC 2015


Author: pfg
Date: Tue Apr 28 16:28:29 2015
New Revision: 282150
URL: https://svnweb.freebsd.org/changeset/base/282150

Log:
  Bring updated versions of libcpp and libgomp.
  
  While GCC 4.3 changed license, the library components remained under
  LGPLv2.1 all the during all the existence of the branch.
  From gcclibs, only libcpp and libgomp have some value for us in the base
  gcc 4.2.1: bring updated versions from GCC 4.3.5 as reference as we have
  already been including some of the fixes.
  
  These not expected to become part of any FreeBSD release.

Added:
  vendor/gcc/dist/libcpp/directives-only.c   (contents, props changed)
  vendor/gcc/dist/libgomp/config/linux/affinity.c   (contents, props changed)
  vendor/gcc/dist/libgomp/config/linux/proc.c   (contents, props changed)
  vendor/gcc/dist/libgomp/config/mingw32/proc.c   (contents, props changed)
  vendor/gcc/dist/libgomp/config/posix/affinity.c   (contents, props changed)
Modified:
  vendor/gcc/dist/libcpp/ChangeLog
  vendor/gcc/dist/libcpp/Makefile.in
  vendor/gcc/dist/libcpp/charset.c
  vendor/gcc/dist/libcpp/config.in
  vendor/gcc/dist/libcpp/configure
  vendor/gcc/dist/libcpp/configure.ac
  vendor/gcc/dist/libcpp/directives.c
  vendor/gcc/dist/libcpp/expr.c
  vendor/gcc/dist/libcpp/files.c
  vendor/gcc/dist/libcpp/include/cpplib.h
  vendor/gcc/dist/libcpp/include/line-map.h
  vendor/gcc/dist/libcpp/include/symtab.h
  vendor/gcc/dist/libcpp/init.c
  vendor/gcc/dist/libcpp/internal.h
  vendor/gcc/dist/libcpp/lex.c
  vendor/gcc/dist/libcpp/line-map.c
  vendor/gcc/dist/libcpp/macro.c
  vendor/gcc/dist/libcpp/pch.c
  vendor/gcc/dist/libcpp/traditional.c
  vendor/gcc/dist/libgomp/ChangeLog
  vendor/gcc/dist/libgomp/Makefile.am
  vendor/gcc/dist/libgomp/Makefile.in
  vendor/gcc/dist/libgomp/aclocal.m4
  vendor/gcc/dist/libgomp/config.h.in
  vendor/gcc/dist/libgomp/configure
  vendor/gcc/dist/libgomp/configure.ac
  vendor/gcc/dist/libgomp/configure.tgt
  vendor/gcc/dist/libgomp/env.c
  vendor/gcc/dist/libgomp/iter.c
  vendor/gcc/dist/libgomp/libgomp.h
  vendor/gcc/dist/libgomp/libgomp.texi
  vendor/gcc/dist/libgomp/omp.h.in
  vendor/gcc/dist/libgomp/omp_lib.h.in
  vendor/gcc/dist/libgomp/team.c

Modified: vendor/gcc/dist/libcpp/ChangeLog
==============================================================================
--- vendor/gcc/dist/libcpp/ChangeLog	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/ChangeLog	Tue Apr 28 16:28:29 2015	(r282150)
@@ -1,23 +1,381 @@
-2007-07-19  Release Manager
+2010-05-22  Release Manager
 
-	* GCC 4.2.1 released.
+	* GCC 4.3.5 released.
 
-2007-05-13  Release Manager
+2009-08-04  Release Manager
 
-	* GCC 4.2.0 released.
+	* GCC 4.3.4 released.
 
-2007-04-23  Tom Tromey  <tromey at redhat.com>
+2009-01-24  Release Manager
 
-	PR preprocessor/30468:
+	* GCC 4.3.3 released.
+
+2008-08-27  Release Manager
+
+	* GCC 4.3.2 released.
+
+2008-07-31  Jakub Jelinek  <jakub at redhat.com>
+
+	PR preprocessor/36649
+	* files.c (struct report_missing_guard_data): New type.
+	(report_missing_guard): Put paths into an array instead of printing
+	them right away.  Return 1 rather than 0.
+	(report_missing_guard_cmp): New function.
+	(_cpp_report_missing_guards): Sort and print paths gathered by
+	report_missing_guard callback.
+
+2008-06-06  Release Manager
+
+	* GCC 4.3.1 released.
+
+2008-03-05  Release Manager
+
+	* GCC 4.3.0 released.
+
+2008-01-25  Jakub Jelinek  <jakub at redhat.com>
+
+	PR preprocessor/34692
+	* macro.c (collect_args): Add pragma_buff argument.  Push
+	CPP_PRAGMA ... CPP_PRAGMA_EOL tokens to *pragma_buff, rather
+	than into arguments.  Reset prevent_expansion and parsing_args
+	state at CPP_PRAGMA_EOL/CPP_EOF.
+	(funlike_invocation_p): Add pragma_buff argument, pass it through
+	to collect_args.
+	(enter_macro_context): Add result argument.  Adjust
+	funlike_invocation_p caller.  Emit all deferred pragma tokens
+	gathered during collect_args before the expansion, add a padding
+	token.  Return 2 instead of 1 if any pragma tokens were prepended.
+	(cpp_get_token): If enter_macro_context returns 2, don't return
+	a padding token, instead cycle to grab CPP_PRAGMA token.
+	* directives.c (_cpp_handle_directive): If was_parsing_args
+	in deferred pragma, leave parsing_args and prevent_expansion as is.
+
+2008-01-22  Tom Tromey  <tromey at redhat.com>
+
+	PR c++/34859
+	* macro.c (_cpp_create_definition): Handle __STDC_LIMIT_MACROS and
+	__STDC_CONSTANT_MACROS.
+
+2008-01-07  Fred Fish  <fnf at specifix.com>
+
+	PR preprocessor/30363
+	* traditional.c (replace_args_and_push): Add local variable
+	cxtquote, calculate the replacement text size assuming a 
+	worst case of every input character quoted with backslash,
+	and properly handle output quoting of quote characters in
+	actual arguments used in function-like macros.
+
+2008-01-03  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/34602
+	* directives.c (do_line): Don't try to spell EOF token.
+	(do_linemarker): Add comment.
+
+2007-12-11  DJ Delorie  <dj at redhat.com>
+
+	* charset.c (convert_using_iconv): Close out any shift states,
+	returning to the initial state.
+
+2007-12-06  Tom Tromey  <tromey at redhat.com>
+
+	PR c/29172
+	* internal.h (struct cpp_reader) <file_hash_entries>: Changed
+	type.
+	<file_hash_entries_allocated, file_hash_entries_used>: Removed.
+	* files.c (FILE_HASH_POOL_SIZE): New macro.
+	(struct file_hash_entry_pool): New.
+	(destroy_all_cpp_files): New function.
+	(allocate_file_hash_entries): Allocate a file_hash_entry_pool.
+	(new_file_hash_entry): Update.
+	(free_file_hash_entries): New function.
+	(_cpp_cleanup_files): Call free_file_hash_entries and
+	destroy_all_cpp_files.
+	(cpp_clear_file_cache): New function.
+	* include/cpplib.h (cpp_clear_file_cache): Declare.
+
+2007-12-03  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/34288
+	* configure.ac, config.in: Rebuilt.
+	* configure.ac: Check for ssize_t.
+
+2007-11-30  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/32868
+	* macro.c (_cpp_create_definition): Special case
+	__STDC_FORMAT_MACROS.
+
+2007-11-16  Michael Matz  <matz at suse.de>
+
+	* files.c (search_path_head): Fix check for absolute paths.
+
+2007-11-11  Tom Tromey  <tromey at redhat.com>
+
+	PR c++/17557
+	* include/cpplib.h (cpp_included_before): Declare.
+	* files.c (struct file_hash_entry) <location>: New field.
+	(_cpp_find_file): Initialize new field.
+	(make_cpp_dir): Likewise.
+	(cpp_included_before): New function.
+
+2007-11-01  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/30805
+	* macro.c (paste_tokens): Handle padding token.
+	(paste_tokens): Don't abort unless padding has PASTE_LEFT flag.
+
+2007-10-31  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/30786
+	* macro.c (builtin_macro): Return result of _cpp_do__Pragma.
+	* directives.c (_cpp_do__Pragma): Return error status.
+	* internal.h (_cpp_do__Pragma): Update.
+	* directives.c (get__Pragma_string): Back up if EOF seen.
+
+2007-09-06  Tom Tromey  <tromey at redhat.com>
+
+	* internal.h (struct cpp_reader) <invocation_location>: New
+	field.
+	(struct cpp_reader) <set_invocation_location>: Likewise.
+	* init.c (cpp_set_line_map): New function.
+	* line-map.c (linemap_add): Use linemap's allocator.
+	* include/line-map.h (GTY): Define.
+	(line_map_realloc): New typedef.
+	(struct line_map): Mark with GTY.
+	(struct line_maps): Likewise.
+	(struct line_maps) <maps>: Likewise.
+	(struct line_maps) <reallocator>: New field.
+	* include/symtab.h (GTY): Conditionally define.
+	* include/cpplib.h (cpp_set_line_map): Declare.
+	(cpp_get_token_with_location): Declare.
+	* macro.c (cpp_get_token): Set invocation_location on the reader.
+	(cpp_get_token_with_location): New function.
+
+2007-08-30  Chao-ying Fu  <fu at mips.com>
+
+	* expr.c (interpret_float_suffix): Support hr, r, lr, llr, uhr, ur,
+	ulr, ullr, hk, k, lk, llk, uhk, uk, ulk, ullk.
+	(cpp_classify_number): Support decimal fixed-point constants without
+	exponents.
+	Warn about fixed-point constants when -pedantic.
+	* include/cpplib.h (CPP_N_SMALL, CPP_N_MEDIUM, CPP_N_LARGE): Change
+	comments to support fixed-point values.
+	(CPP_N_FRACT, CPP_N_ACCUM): Define.
+
+2007-08-18  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/32974
+	* directives.c (parse_include): Don't check for EOL when
+	processing #pragma dependency.
+
+2007-07-30  Ollie Wild  <aaw at google.com>
+
+	* directives-only.c: New file.
+	* internal.h (struct _cpp_dir_only_callbacks): New.
+	(_cpp_preprocess_dir_only): New function.
+	* directives.c (_cpp_handle_directive): Check directives_only before
+	disabling execution of indented directives.
+	* files.c (_cpp_stack_file): Add directives_only check.
+	* include/cpplib.h (struct cpp_options): Add directives_only.
+	(cpp_init_special_builtins): New function.
+	* init.c (cpp_init_special_builtins): New function.
+	(cpp_init_builtins): Move builtin_array initialization to
+	cpp_init_special_builtins.
+	(post_options): Check directives_only before setting
+	pfile->state.prevent_expansion = 1.
+	* macro.c (_cpp_builtin_macro_text): Print an error if __COUNTER__
+	is expanded inside a directive while -fdirectives-only is enabled.
+	* Makefile.in (libcpp_a_OBJS): Add directives-only.o.
+	(libcpp_a_SOURCES): Add directives-only.c.
+
+2007-07-04  Uros Bizjak  <ubizjak at gmail.com>
+
+	* traditional.c (_cpp_scan_out_logical_line): Initialize
+	fmacro.args, fmacro.node, fmacro.offset, fmacro.line and
+	fmacro.args to prevent 'may be used uninitialized' warning.
+
+2007-07-03  Uros Bizjak  <ubizjak at gmail.com>
+
+	* include/cpplib.h (CPP_N_WIDTH_MD, CPP_N_MD_W, CPP_N_MD_Q):
+	Add new constants.
+	* expr.c (interpret_float_suffix): Process 'w', 'W', 'q' and 'Q'
+	suffixes.  Return CPP_N_MD_W for 'w' or 'W' suffixes and CPP_N_MD_Q
+	for 'q' or 'Q' suffixes.
+
+2007-06-17  Danny Smith  <dannysmith at users.sourceforge.net
+
+	* files.c (open_file): Correct typo.
+
+2007-06-16  Vladimir Prus  <vladimir at codesourcery.com>
+
+	* files.c (open_file): Prevent the call
+	for stat from overwriting errno.
+
+2007-06-09  Vladimir Prus  <vladimir at codesourcery.com>
+
+	* files.c (open_file): Account for the
+        fact that on windows, opening a directory gives
+        EACCES.
+
+2007-06-05  Joerg Wunsch  <j.gnu at uriah.heep.sax.de>
+
+	PR preprocessor/23479
+	* expr.c (cpp_classify_number): Implement 0b-prefixed binary
+	integer constants.
+	(append_digit): Likewise.
+	* include/cpplib.h: Add CPP_N_BINARY, to be used for 0b-prefixed
+	binary integer constants.
+
+2007-05-31  Dave Korn  <dave.korn at artimi.com>
+
+	PR preprocessor/14331
+	* lex.c (_cpp_get_fresh_line):  Don't warn if no newline at EOF.
+
+2007-05-24  Ollie Wild  <aaw at google.com>
+
+	* macro.c (_cpp_builtin_macro_text): Handle BT_COUNTER.
+	* pch.c (cpp_write_pch_deps): Save __COUNTER__ state.
+	(cpp_write_pch_state): Save __COUNTER__ state.
+	(cpp_valid_state): Check valid __COUNTER__ state.
+	(cpp_read_state): Read new __COUNTER__ state.
+	* include/cpplib.h (enum builtin_type): Add BT_COUNTER enumerator.
+	* init.c (builtin_array): Add __COUNTER__/BT_COUNTER.
+	* internal.h (struct cpp_reader): Add counter member.
+
+2007-05-23  Simon Martin  <simartin at users.sourceforge.net>
+
+	PR preprocessor/20077
+	* macro.c (create_iso_definition): Fixed the method to determine
+	whether the token-pasting operator appears at the beginning or the end
+	of a macro.
+
+2007-05-21  Ian Lance Taylor  <iant at google.com>
+
+	* internal.h (struct cpp_reader): Add new fields:
+	nonexistent_file_hash and nonexistent_file_ob.
+	* files.c: Include "obstack.h".
+	(find_file_in_dir): Before trying to open the file, look up the
+	path name in the hash table of nonexistent files.  After failing
+	to open the file, add the path name to the hash table.
+	(_cpp_find_file): Cache the results of looking up the file name
+	starting with the quote and bracket chain heads, if we can.
+	(nonexistent_file_hash_eq): New static function.
+	(_cpp_init_files): Initialize pfile->nonexistent_file_hash and
+	pfile->nonexistent_file_ob.
+	(_cpp_cleanup_files): Free pfile->nonexistent_file_hash and
+	pfile->nonexistent_file_ob.
+
+2007-05-14  Janis Johnson  <janis187 at us.ibm.com>
+
+        * expr.c (cpp_classify_number): Warn about dfp constant for -pedantic.
+
+	PR c/31924
+	* expr.c (interpret_float_suffix): Check for invalid suffix.
+
+2007-05-02  Eric Christopher  <echristo at apple.com>
+
+	* expr.c (num_div_op): Don't overflow if the result is
+	zero.
+
+2007-05-02  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/28709
+	* macro.c (paste_tokens): Remove PASTE_LEFT from the old lhs.
+
+2007-03-30  Michael Meissner  <michael.meissner at amd.com>
+
+	* directives.c (lex_macro_node_from_str): Fix alloca call to be
+	type correct.
+
+2007-03-30  Richard Henderson  <rth at redhat.com>
+
+	* directives.c (lex_macro_node_from_str): New.
+	(cpp_push_definition, cpp_pop_definition): New.
+	* include/cpplib.h (cpp_push_definition, cpp_pop_definition): Declare.
+
+2007-03-01  Brooks Moses  <brooks.moses at codesourcery.com>
+
+	* Makefile.in: Add dummy install-pdf target.
+
+2007-01-30  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/30468
 	* mkdeps.c (apply_vpath): Strip successive '/'s if we stripped
 	'./'.
 
+2007-01-30  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/29966
+	* macro.c (lex_expansion_token): Save and restore cpp_reader's
+	cur_token.
+	(_cpp_create_definition): Don't restore cur_token here.
+	* lex.c (_cpp_lex_token): Added assertion.
+
+2007-01-27  Tom Tromey  <tromey at redhat.com>
+
+	* configure: Rebuilt.
+
+2007-01-12  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/28227
+	* directives.c (lex_macro_node): Added 'is_def_or_undef'
+	argument.
+	(do_define): Update.
+	(do_undef): Update.
+	(do_ifdef): Update.
+	(do_ifndef): Update.
+
+2007-01-11  Paolo Bonzini  <bonzini at gnu.org>
+
+	* configure: Regenerate.
+
+2007-01-11  Paolo Bonzini  <bonzini at gnu.org>
+
+	* configure: Regenerate.
+
+2007-01-04  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/28165
+	* internal.h (cpp_in_primary_file): New function.
+	* directives.c (do_include_next): Use cpp_in_primary_file.
+	(do_pragma_once): Likewise.
+	(do_pragma_system_header): Likewise.
+
+2006-12-29  Ian Lance Taylor  <iant at google.com>
+
+	* lex.c (_cpp_clean_line): Add uses of __builtin_expect.  Don't
+	look backward at the end of the line unless we saw a backslash.
+
 2006-12-29  Jakub Jelinek  <jakub at redhat.com>
 
 	PR preprocessor/29612
 	* directives.c (do_linemarker): Set pfile->buffer->sysp always, not
 	only when new_sysp is non-zero.
 
+2006-12-28  Tom Tromey  <tromey at redhat.com>
+
+	PR preprocessor/30001
+	* charset.c (_cpp_convert_input): Check that to.len is greater
+	than zero.
+
+2006-11-20  Trevor Smigiel <Trevor_Smigiel at playstation.sony.com>
+
+	* configure.ac (need_64bit_hwint): Need 64bit hwint for SPU.
+	* configure: Rebuilt.
+
+2006-11-01	Douglas Gregor <doug.gregor at gmail.com>
+
+	* include/cpplib.h (enum c_lang): Add CLK_GNUCXX0X and CLK_CXX0X
+	for experimental C++0x mode.
+	* init.c (lang_defaults): Add defaults for C++0x modes. C++0x has
+	adopted the preprocessor changes introduced in C99.
+
+2006-10-29  Joseph Myers  <joseph at codesourcery.com>
+
+	* configure.ac (need_64bit_hwint): Set for i[34567]86-*-linux*
+	depending on --enable-targets=all.
+	* configure: Regenerate.
+
 2006-10-12  Jakub Jelinek  <jakub at redhat.com>
 
 	PR preprocessor/28709

Modified: vendor/gcc/dist/libcpp/Makefile.in
==============================================================================
--- vendor/gcc/dist/libcpp/Makefile.in	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/Makefile.in	Tue Apr 28 16:28:29 2015	(r282150)
@@ -69,14 +69,14 @@ INCLUDES = -I$(srcdir) -I. -I$(srcdir)/.
 
 ALL_CFLAGS = $(CFLAGS) $(WARN_CFLAGS) $(INCLUDES) $(CPPFLAGS)
 
-libcpp_a_OBJS = charset.o directives.o errors.o expr.o files.o \
-	identifiers.o init.o lex.o line-map.o macro.o mkdeps.o \
-	pch.o symtab.o traditional.o
+libcpp_a_OBJS = charset.o directives.o directives-only.o errors.o \
+	expr.o files.o identifiers.o init.o lex.o line-map.o macro.o \
+	mkdeps.o pch.o symtab.o traditional.o
 makedepend_OBJS = makedepend.o
 
-libcpp_a_SOURCES = charset.c directives.c errors.c expr.c files.c \
-	identifiers.c init.c lex.c line-map.c macro.c mkdeps.c \
-	pch.c symtab.c traditional.c
+libcpp_a_SOURCES = charset.c directives.c directives-only.c errors.c \
+	expr.c files.c identifiers.c init.c lex.c line-map.c macro.c \
+	mkdeps.c pch.c symtab.c traditional.c
 
 all: libcpp.a makedepend$(EXEEXT) $(USED_CATALOGS)
 
@@ -184,6 +184,7 @@ pdf:
 html:
 info:
 install-info:
+install-pdf:
 install-man:
 install-html:
 

Modified: vendor/gcc/dist/libcpp/charset.c
==============================================================================
--- vendor/gcc/dist/libcpp/charset.c	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/charset.c	Tue Apr 28 16:28:29 2015	(r282150)
@@ -1,5 +1,5 @@
 /* CPP Library - charsets
-   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004
+   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006
    Free Software Foundation, Inc.
 
    Broken out of c-lex.c Apr 2003, adding valid C99 UCN ranges.
@@ -548,6 +548,15 @@ convert_no_conversion (iconv_t cd ATTRIB
 /* And this one uses the system iconv primitive.  It's a little
    different, since iconv's interface is a little different.  */
 #if HAVE_ICONV
+
+#define CONVERT_ICONV_GROW_BUFFER \
+  do { \
+      outbytesleft += OUTBUF_BLOCK_SIZE; \
+      to->asize += OUTBUF_BLOCK_SIZE; \
+      to->text = XRESIZEVEC (uchar, to->text, to->asize); \
+      outbuf = (char *)to->text + to->asize - outbytesleft; \
+  } while (0)
+
 static bool
 convert_using_iconv (iconv_t cd, const uchar *from, size_t flen,
 		     struct _cpp_strbuf *to)
@@ -570,16 +579,24 @@ convert_using_iconv (iconv_t cd, const u
       iconv (cd, &inbuf, &inbytesleft, &outbuf, &outbytesleft);
       if (__builtin_expect (inbytesleft == 0, 1))
 	{
+	  /* Close out any shift states, returning to the initial state.  */
+	  if (iconv (cd, 0, 0, &outbuf, &outbytesleft) == (size_t)-1)
+	    {
+	      if (errno != E2BIG)
+		return false;
+
+	      CONVERT_ICONV_GROW_BUFFER;
+	      if (iconv (cd, 0, 0, &outbuf, &outbytesleft) == (size_t)-1)
+		return false;
+	    }
+
 	  to->len = to->asize - outbytesleft;
 	  return true;
 	}
       if (errno != E2BIG)
 	return false;
 
-      outbytesleft += OUTBUF_BLOCK_SIZE;
-      to->asize += OUTBUF_BLOCK_SIZE;
-      to->text = XRESIZEVEC (uchar, to->text, to->asize);
-      outbuf = (char *)to->text + to->asize - outbytesleft;
+      CONVERT_ICONV_GROW_BUFFER;
     }
 }
 #else
@@ -1628,7 +1645,7 @@ _cpp_convert_input (cpp_reader *pfile, c
      terminate with another \r, not an \n, so that we do not mistake
      the \r\n sequence for a single DOS line ending and erroneously
      issue the "No newline at end of file" diagnostic.  */
-  if (to.text[to.len - 1] == '\r')
+  if (to.len && to.text[to.len - 1] == '\r')
     to.text[to.len] = '\r';
   else
     to.text[to.len] = '\n';

Modified: vendor/gcc/dist/libcpp/config.in
==============================================================================
--- vendor/gcc/dist/libcpp/config.in	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/config.in	Tue Apr 28 16:28:29 2015	(r282150)
@@ -280,3 +280,6 @@
 
 /* Define to `unsigned' if <sys/types.h> does not define. */
 #undef size_t
+
+/* Define to `int' if <sys/types.h> does not define. */
+#undef ssize_t

Modified: vendor/gcc/dist/libcpp/configure
==============================================================================
--- vendor/gcc/dist/libcpp/configure	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/configure	Tue Apr 28 16:28:29 2015	(r282150)
@@ -2816,7 +2816,7 @@ fi
 echo "$as_me:$LINENO: result: $acx_cv_prog_cc_pedantic__Wno_long_long" >&5
 echo "${ECHO_T}$acx_cv_prog_cc_pedantic__Wno_long_long" >&6
 if test $acx_cv_prog_cc_pedantic__Wno_long_long = yes; then
-  WARN_PEDANTIC="-pedantic -Wno-long-long"
+  WARN_PEDANTIC="$WARN_PEDANTIC${WARN_PEDANTIC:+ }-pedantic -Wno-long-long"
 fi
 
 
@@ -2835,11 +2835,12 @@ else
   enable_werror_always=no
 fi;
 if test $enable_werror_always = yes; then
-  WERROR=-Werror
+  WERROR="$WERROR${WERROR:+ }-Werror"
 fi
 
 
 
+
 # Dependency checking.
 rm -rf .tst 2>/dev/null
 mkdir .tst 2>/dev/null
@@ -4113,6 +4114,72 @@ _ACEOF
 
 fi
 
+echo "$as_me:$LINENO: checking for ssize_t" >&5
+echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6
+if test "${ac_cv_type_ssize_t+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+int
+main ()
+{
+if ((ssize_t *) 0)
+  return 0;
+if (sizeof (ssize_t))
+  return 0;
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+  (eval $ac_compile) 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } &&
+	 { ac_try='test -z "$ac_c_werror_flag"
+			 || test ! -s conftest.err'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; } &&
+	 { ac_try='test -s conftest.$ac_objext'
+  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  (eval $ac_try) 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_type_ssize_t=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_type_ssize_t=no
+fi
+rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
+echo "${ECHO_T}$ac_cv_type_ssize_t" >&6
+if test $ac_cv_type_ssize_t = yes; then
+  :
+else
+
+cat >>confdefs.h <<_ACEOF
+#define ssize_t int
+_ACEOF
+
+fi
+
 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
 if test "${ac_cv_struct_tm+set}" = set; then
@@ -8244,8 +8311,16 @@ case $target in
 	sparc64*-*-* | ultrasparc-*-freebsd* | \
 	sparcv9-*-solaris2* | \
 	sparc-*-solaris2.[789] | sparc-*-solaris2.1[0-9]* | \
+	spu-*-* | \
 	sh[123456789l]*-*-*)
 		need_64bit_hwint=yes ;;
+	i[34567]86-*-linux*)
+		if test "x$enable_targets" = xall; then
+			need_64bit_hwint=yes
+		else
+			need_64bit_hwint=no
+		fi
+		;;
 	*)
 		need_64bit_hwint=no ;;
 esac
@@ -8792,7 +8867,7 @@ cat >>$CONFIG_STATUS <<_ACEOF
 # INIT-COMMANDS section.
 #
 
-DEPDIR=$DEPDIR
+ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR
 
 _ACEOF
 
@@ -9526,7 +9601,7 @@ esac
   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
 echo "$as_me: executing $ac_dest commands" >&6;}
   case $ac_dest in
-    depdir ) mkdir $DEPDIR ;;
+    depdir ) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;;
   esac
 done
 _ACEOF

Modified: vendor/gcc/dist/libcpp/configure.ac
==============================================================================
--- vendor/gcc/dist/libcpp/configure.ac	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/configure.ac	Tue Apr 28 16:28:29 2015	(r282150)
@@ -46,6 +46,7 @@ AC_C_INLINE
 AC_FUNC_OBSTACK
 AC_TYPE_OFF_T
 AC_TYPE_SIZE_T
+AC_CHECK_TYPE(ssize_t, int)
 AC_STRUCT_TM
 AC_CHECK_SIZEOF(int)
 AC_CHECK_SIZEOF(long)
@@ -128,8 +129,16 @@ case $target in
 	sparc64*-*-* | ultrasparc-*-freebsd* | \
 	sparcv9-*-solaris2* | \
 	sparc-*-solaris2.[789] | sparc-*-solaris2.1[0-9]* | \
+	spu-*-* | \
 	sh[123456789l]*-*-*)
 		need_64bit_hwint=yes ;;
+	i[34567]86-*-linux*)
+		if test "x$enable_targets" = xall; then
+			need_64bit_hwint=yes
+		else
+			need_64bit_hwint=no
+		fi
+		;;
 	*)
 		need_64bit_hwint=no ;;
 esac

Added: vendor/gcc/dist/libcpp/directives-only.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ vendor/gcc/dist/libcpp/directives-only.c	Tue Apr 28 16:28:29 2015	(r282150)
@@ -0,0 +1,240 @@
+/* CPP Library - directive only preprocessing for distributed compilation.
+   Copyright (C) 2007
+   Free Software Foundation, Inc.
+   Contributed by Ollie Wild <aaw at google.com>.
+
+This program 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 2, or (at your option) any
+later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
+
+#include "config.h"
+#include "system.h"
+#include "cpplib.h"
+#include "internal.h"
+
+/* DO (Directive only) flags. */
+#define DO_BOL		 (1 << 0) /* At the beginning of a logical line. */
+#define DO_STRING	 (1 << 1) /* In a string constant. */
+#define DO_CHAR		 (1 << 2) /* In a character constant. */
+#define DO_BLOCK_COMMENT (1 << 3) /* In a block comment. */
+#define DO_LINE_COMMENT	 (1 << 4) /* In a single line "//-style" comment. */
+
+#define DO_LINE_SPECIAL (DO_STRING | DO_CHAR | DO_LINE_COMMENT)
+#define DO_SPECIAL	(DO_LINE_SPECIAL | DO_BLOCK_COMMENT)
+
+/* Writes out the preprocessed file, handling spacing and paste
+   avoidance issues.  */
+void
+_cpp_preprocess_dir_only (cpp_reader *pfile,
+			  const struct _cpp_dir_only_callbacks *cb)
+{
+  struct cpp_buffer *buffer;
+  const unsigned char *cur, *base, *next_line, *rlimit;
+  cppchar_t c, last_c;
+  unsigned flags;
+  int lines, col;
+  source_location loc;
+
+ restart:
+  /* Buffer initialization ala _cpp_clean_line(). */
+  buffer = pfile->buffer;
+  buffer->cur_note = buffer->notes_used = 0;
+  buffer->cur = buffer->line_base = buffer->next_line;
+  buffer->need_line = false;
+
+  /* This isn't really needed.  It prevents a compiler warning, though. */
+  loc = pfile->line_table->highest_line;
+
+  /* Scan initialization. */
+  next_line = cur = base = buffer->cur;
+  rlimit = buffer->rlimit;
+  flags = DO_BOL;
+  lines = 0;
+  col = 1;
+
+  for (last_c = '\n', c = *cur; cur < rlimit; last_c = c, c = *++cur, ++col)
+    {
+      /* Skip over escaped newlines. */
+      if (__builtin_expect (c == '\\', false))
+	{
+	  const unsigned char *tmp = cur + 1;
+
+	  while (is_nvspace (*tmp) && tmp < rlimit)
+	    tmp++;
+	  if (*tmp == '\r')
+	    tmp++;
+	  if (*tmp == '\n' && tmp < rlimit)
+	    {
+	      CPP_INCREMENT_LINE (pfile, 0);
+	      lines++;
+	      col = 0;
+	      cur = tmp;
+	      c = last_c;
+	      continue;
+	    }
+	}
+
+      if (__builtin_expect (last_c == '#', false) && !(flags & DO_SPECIAL))
+	{
+	  if (c != '#' && (flags & DO_BOL))
+	  {
+	    struct line_maps *line_table;
+
+	    if (!pfile->state.skipping && next_line != base)
+	      cb->print_lines (lines, base, next_line - base);
+
+	    /* Prep things for directive handling. */
+	    buffer->next_line = cur;
+	    buffer->need_line = true;
+	    _cpp_get_fresh_line (pfile);
+
+	    /* Ensure proper column numbering for generated error messages. */
+	    buffer->line_base -= col - 1;
+
+	    _cpp_handle_directive (pfile, 0 /* ignore indented */);
+
+	    /* Sanitize the line settings.  Duplicate #include's can mess
+	       things up. */
+	    line_table = pfile->line_table;
+	    line_table->highest_location = line_table->highest_line;
+
+	    /* The if block prevents us from outputing line information when
+	       the file ends with a directive and no newline.  Note that we
+	       must use pfile->buffer, not buffer. */
+	    if (pfile->buffer->next_line < pfile->buffer->rlimit)
+	      cb->maybe_print_line (pfile->line_table->highest_line);
+
+	    goto restart;
+	  }
+
+	  flags &= ~DO_BOL;
+	  pfile->mi_valid = false;
+	}
+      else if (__builtin_expect (last_c == '/', false) \
+	       && !(flags & DO_SPECIAL) && c != '*' && c != '/')
+	{
+	  /* If a previous slash is not starting a block comment, clear the
+	     DO_BOL flag.  */
+	  flags &= ~DO_BOL;
+	  pfile->mi_valid = false;
+	}
+
+      switch (c)
+	{
+	case '/':
+	  if ((flags & DO_BLOCK_COMMENT) && last_c == '*')
+	    {
+	      flags &= ~DO_BLOCK_COMMENT;
+	      c = 0;
+	    }
+	  else if (!(flags & DO_SPECIAL) && last_c == '/')
+	    flags |= DO_LINE_COMMENT;
+	  else if (!(flags & DO_SPECIAL))
+	    /* Mark the position for possible error reporting. */
+	    LINEMAP_POSITION_FOR_COLUMN (loc, pfile->line_table, col);
+
+	  break;
+
+	case '*':
+	  if (!(flags & DO_SPECIAL))
+	    {
+	      if (last_c == '/')
+		flags |= DO_BLOCK_COMMENT;
+	      else
+		{
+		  flags &= ~DO_BOL;
+		  pfile->mi_valid = false;
+		}
+	    }
+
+	  break;
+
+	case '\'':
+	case '"':
+	  {
+	    unsigned state = (c == '"') ? DO_STRING : DO_CHAR;
+
+	    if (!(flags & DO_SPECIAL))
+	      {
+		flags |= state;
+		flags &= ~DO_BOL;
+		pfile->mi_valid = false;
+	      }
+	    else if ((flags & state) && last_c != '\\')
+	      flags &= ~state;
+
+	    break;
+	  }
+
+	case '\\':
+	  {
+	    if ((flags & (DO_STRING | DO_CHAR)) && last_c == '\\')
+	      c = 0;
+
+	    if (!(flags & DO_SPECIAL))
+	      {
+		flags &= ~DO_BOL;
+		pfile->mi_valid = false;
+	      }
+
+	    break;
+	  }
+
+	case '\n':
+	  CPP_INCREMENT_LINE (pfile, 0);
+	  lines++;
+	  col = 0;
+	  flags &= ~DO_LINE_SPECIAL;
+	  if (!(flags & DO_SPECIAL))
+	    flags |= DO_BOL;
+	  break;
+
+	case '#':
+	  next_line = cur;
+	  /* Don't update DO_BOL yet. */
+	  break;
+
+	case ' ': case '\t': case '\f': case '\v': case '\0':
+	  break;
+
+	default:
+	  if (!(flags & DO_SPECIAL))
+	    {
+	      flags &= ~DO_BOL;
+	      pfile->mi_valid = false;
+	    }
+	  break;
+	}
+    }
+
+  if (flags & DO_BLOCK_COMMENT)
+    cpp_error_with_line (pfile, CPP_DL_ERROR, loc, 0, "unterminated comment");
+
+  if (!pfile->state.skipping && cur != base)
+    {
+      /* If the file was not newline terminated, add rlimit, which is
+         guaranteed to point to a newline, to the end of our range.  */
+      if (cur[-1] != '\n')
+	{
+	  cur++;
+	  CPP_INCREMENT_LINE (pfile, 0);
+	  lines++;
+	}
+
+      cb->print_lines (lines, base, cur - base);
+    }
+
+  _cpp_pop_buffer (pfile);
+  if (pfile->buffer)
+    goto restart;
+}

Modified: vendor/gcc/dist/libcpp/directives.c
==============================================================================
--- vendor/gcc/dist/libcpp/directives.c	Tue Apr 28 16:06:58 2015	(r282149)
+++ vendor/gcc/dist/libcpp/directives.c	Tue Apr 28 16:28:29 2015	(r282150)
@@ -1,6 +1,7 @@
 /* CPP Library. (Directive handling.)
    Copyright (C) 1986, 1987, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+   1999, 2000, 2001, 2002, 2003, 2004, 2005,
+   2007, 2008 Free Software Foundation, Inc.
    Contributed by Per Bothner, 1994-95.
    Based on CCCP program by Paul Rubin, June 1986
    Adapted to ANSI C, Richard Stallman, Jan 1987
@@ -102,7 +103,7 @@ static void push_conditional (cpp_reader
 static unsigned int read_flag (cpp_reader *, unsigned int);
 static int strtoul_for_line (const uchar *, unsigned int, unsigned long *);
 static void do_diagnostic (cpp_reader *, int, int);
-static cpp_hashnode *lex_macro_node (cpp_reader *);
+static cpp_hashnode *lex_macro_node (cpp_reader *, bool);
 static int undefine_macros (cpp_reader *, cpp_hashnode *, void *);
 static void do_include_common (cpp_reader *, enum include_type);
 static struct pragma_entry *lookup_pragma_entry (struct pragma_entry *,
@@ -423,8 +424,13 @@ _cpp_handle_directive (cpp_reader *pfile
 	 does not cause '#define foo bar' to get executed when
 	 compiled with -save-temps, we recognize directives in
 	 -fpreprocessed mode only if the # is in column 1.  macro.c
-	 puts a space in front of any '#' at the start of a macro.  */
+	 puts a space in front of any '#' at the start of a macro.
+	 
+	 We exclude the -fdirectives-only case because macro expansion
+	 has not been performed yet, and block comments can cause spaces
+	 to preceed the directive.  */
       if (CPP_OPTION (pfile, preprocessed)
+	  && !CPP_OPTION (pfile, directives_only)
 	  && (indented || !(dir->flags & IN_I)))
 	{
 	  skip = 0;
@@ -469,7 +475,7 @@ _cpp_handle_directive (cpp_reader *pfile
     _cpp_backup_tokens (pfile, 1);
 
   end_directive (pfile, skip);
-  if (was_parsing_args)
+  if (was_parsing_args && !pfile->state.in_deferred_pragma)
     {
       /* Restore state when within macro args.  */
       pfile->state.parsing_args = 2;
@@ -502,9 +508,11 @@ run_directive (cpp_reader *pfile, int di
 }
 
 /* Checks for validity the macro name in #define, #undef, #ifdef and
-   #ifndef directives.  */
+   #ifndef directives.  IS_DEF_OR_UNDEF is true if this call is
+   processing a #define or #undefine directive, and false
+   otherwise.  */
 static cpp_hashnode *
-lex_macro_node (cpp_reader *pfile)
+lex_macro_node (cpp_reader *pfile, bool is_def_or_undef)
 {
   const cpp_token *token = _cpp_lex_token (pfile);
 
@@ -519,7 +527,7 @@ lex_macro_node (cpp_reader *pfile)
     {
       cpp_hashnode *node = token->val.node;
 
-      if (node == pfile->spec_nodes.n_defined)
+      if (is_def_or_undef && node == pfile->spec_nodes.n_defined)
 	cpp_error (pfile, CPP_DL_ERROR,
 		   "\"defined\" cannot be used as a macro name");
       else if (! (node->flags & NODE_POISONED))
@@ -542,7 +550,7 @@ lex_macro_node (cpp_reader *pfile)
 static void
 do_define (cpp_reader *pfile)
 {
-  cpp_hashnode *node = lex_macro_node (pfile);
+  cpp_hashnode *node = lex_macro_node (pfile, true);
 
   if (node)
     {
@@ -561,7 +569,7 @@ do_define (cpp_reader *pfile)
 static void
 do_undef (cpp_reader *pfile)
 {
-  cpp_hashnode *node = lex_macro_node (pfile);
+  cpp_hashnode *node = lex_macro_node (pfile, true);
 
   if (node)
     {
@@ -690,7 +698,11 @@ parse_include (cpp_reader *pfile, int *p
       return NULL;
     }
 
-  if (buf == NULL || CPP_OPTION (pfile, discard_comments))
+  if (pfile->directive == &dtable[T_PRAGMA])
+    {
+      /* This pragma allows extra tokens after the file name.  */
+    }
+  else if (buf == NULL || CPP_OPTION (pfile, discard_comments))
     check_eol (pfile);
   else
     {
@@ -772,7 +784,7 @@ do_include_next (cpp_reader *pfile)
 
   /* If this is the primary source file, warn and use the normal
      search logic.  */
-  if (! pfile->buffer->prev)
+  if (cpp_in_primary_file (pfile))

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***


More information about the svn-src-all mailing list