Add myself as write after approval maintainer

2014-05-12  Simon Marchi  <simon.marchi@ericsson.com>

	* MAINTAINERS (Write After Approval): Add "Simon Marchi".
mi: Use the value in mi_console_file->quote as the quoting character

In mi_interpreter_init, multiple MI consoles/channels are created and a quoting
character is given.  In mi_console_raw_packet, we check if the value is not 0
to decide if we should quote the string, but we don't use the value. It is
hardcoded to ".  We might never use another quoting character than an actual
quote, but I suggest we change it, for correctness.  There is not visible
behavior change.

I changed the latest fputs_unfiltered changed to fputc_unfiltered just to stay
consistent.

gdb/ChangeLog:

2014-05-12  Simon Marchi  <simon.marchi@ericsson.com>

	* mi/mi-console.c (mi_console_raw_packet): Use the value from
	mi_console->quote as the quoting character.
Split out older testsuite/ChangeLog entries (prior to 2014)
into separate file: ChangeLog-1993-2013.
Add link to older changes in ChangeLog-1993-2013.
Support 32->64 sign extension in msp430's sign_ext

* msp43-sim.c (sign_ext): Change to "long long" to support
sign-extending 32-bit values.
daily update
Re-work register size macros for MIPS.

gas/
	* config/tc-mips.c (mips_set_options): Rename gp32 to gp throughout.
	(HAVE_32BIT_GPRS, HAVE_64BIT_GPRS): Remove. Re-implement via GPR_SIZE.
	(HAVE_32BIT_FPRS, HAVE_64BIT_FPRS): Remove. Re-implement via FPR_SIZE.
	(GPR_SIZE, FPR_SIZE): New macros. Use throughout.
S390: Fix erroneous offset in fill_gregset.

This fixes a bug that leads to various failures when debugging a
31-bit inferior with a 64-bit gdb on s390x.
Optimizing accesses to Globals with -fpie -pie:

With -pie and x86, the linker complains if it sees a PC-relative relocation
to access a global as it expects a GOTPCREL relocation.  This is really not
necessary as the linker could use a copy relocation to get around it.  This
patch enables copy relocations with pie.

Context:
This is useful because currently the GCC compiler with option -fpie makes
every extern global access go through the GOT. That is because the compiler
cannot tell if a global will end up being defined in the executable or not
and is conservative. This ends up hurting performance when the binary is linked
as mostly static where most of the globals do end up being defined in the
executable.  By allowing copy relocs with fPIE, the compiler need not generate
a GOTPCREL(GOT access) for any global access.  It can safely assume that all
globals will be defined in the executable and generate a PC-relative access
instead.  Gold can then create a copy reloc for only the undefined globals.
remove an unused macro and an unused declaration

This patch removes an unused macro from language.h.  It also removes
the declaration of a function which is not defined.

I'm checking this in as obvious.
Tested by rebuilding.

2014-05-13  Tom Tromey  <tromey@redhat.com>

	* language.h (unop_type_check): Remove.
	(binop_type_check): Don't declare.
With -pie and x86, the linker complains if it sees a PC-relative relocation
to access a global as it expects a GOTPCREL relocation.  This is really not
necessary as the linker could use a copy relocation to get around it.  This
patch enables copy relocations with pie.

Context:
This is useful because currently the GCC compiler with option -fpie makes
every extern global access go through the GOT. That is because the compiler
cannot tell if a global will end up being defined in the executable or not
and is conservative. This ends up hurting performance when the binary is linked
as mostly static where most of the globals do end up being defined in the
executable.  By allowing copy relocs with fPIE, the compiler need not generate
a GOTPCREL(GOT access) for any global access.  It can safely assume that all
globals will be defined in the executable and generate a PC-relative access
instead.  Gold can then create a copy reloc for only the undefined globals.

	gold/
	* symtab.h (may_need_copy_reloc): Remove check for position independent
	code.
	* x86_64.cc (Target_x86_64<size>::Scan::global): Add check for no
	position independence before pc absolute may_need_copy_reloc call.
	Add check for executable output befor pc relative may_need_copy_reloc
	call.
	* i386.cc: Ditto.
	* arm.cc: Ditto.
	* sparc.cc: Ditto.
	* tilegx.cc: Ditto.
	* powerpc.cc: Add check for no position independence before
	may_need_copy_reloc calls.
	* testsuite/pie_copyrelocs_test.cc: New file.
	* testsuite/pie_copyrelocs_shared_test.cc: New file.
	* Makefile.am (pie_copyrelocs_test): New test.
	* Makefile.in: Regenerate.
Remove unused variable

should_resume is set to 1 at the beginning and never changed.

gdb/ChangeLog:

2014-05-13  Simon Marchi  <simon.marchi@ericsson.com>

	* infrun.c (resume): Remove should_resume (unused).  Move up
	declaration of resume_ptid.
daily update
* python/py-cmd.c (cmdpy_completer): Add comment.
(completers): Make const.
Overwrite ${board}_file in local-remote-host

After I run test like this,

 $ make check RUNTESTFLAGS='--host_board=local-remote-host dw2-basic.exp'

gdb.dwarf2/file1.txt in source tree was removed.  In some gdb.dwarf2/*.exp,
file1.txt is copied to host and then removed at the end.  However, in
local-remote-host-notty.exp, ${board}_download doesn't copy the file but
return the absolute path of the src file.  'remote_file host delete' at
the end will remove the file in source tree.

This patch is to overwrite ${board}_file, and specially make "delete"
option do nothing.  This approach is used in gdbserver-base.exp and
remote-stdio-gdbserver.exp too.

gdb/testsuite:

2014-05-14  Yao Qi  <yao@codesourcery.com>

	* boards/local-remote-host-notty.exp (${board}_file): New
	proc.
Fix mi-file.exp fails on remote host

This patch fixes mi-file.exp fails on remote host.  First, we can't
assume ${srcdir}/${subdir}/${srcfile} directory exists on remote host,
so this patch changes it to match ${srcfile} only on remote host.
Second, regexp pattern ".*/${srcfile}" isn't friendly to Windows path.
The file name is "basics.c" in my test env and can't match the pattern
due to "/" in it.  Remove "/" from the pattern.

gdb/testsuite:

2014-05-14  Yao Qi  <yao@codesourcery.com>

	* gdb.mi/mi-file.exp (test_file_list_exec_source_file): Don't
	match absolute path on remote host.
	(test_file_list_exec_source_files): Remove "/" from the
	pattern.
reindent print_macro_definition

I happened to notice that print_macro_definition is indented
improperly.  All the lines were a few extra spaces to the right.

This patch fixes the indentation.
Tested by rebuilding, committed.

2014-05-14  Tom Tromey  <tromey@redhat.com>

	* macrocmd.c (print_macro_definition): Reindent.
Sync nios2 configure changes from GCC mainline.

2014-05-14  Sandra Loosemore  <sandra@codesourcery.com>

	* configure.ac (target_makefile_frag): Set for nios2-*-elf*.
	* configure: Regenerated.

	config/
	* mt-nios2-elf: New file.
daily update
Fix "overflow in PLT unwind data" warning

When linking statically, it's possible to hit this warning with IFUNC
or very large executables, due to .glink being unused.

	* powerpc.cc (do_plt_fde_location): Handle zero length .glink.
	Compare FDE contents with DW_CFA_nop rather than 0.