2013-11-25  Steve Ellcey  <sellcey@mips.com>

	* igen/Makefile.in (igen): Use BUILD_CFLAGS in link.
PR c++/14819:  Explicit class:: inside class scope does not work

https://sourceware.org/ml/gdb-patches/2013-11/msg00102.html
daily update
Fix PR16193 - gdbserver aborts.

The MPX patch has broken the I386_XSTATE_SIZE macro.  For AVX machines,
it ends up returning I386_XSTATE_SSE_SIZE.  Where it first reads
I386_XSTATE_AVX_SIZE, it should have read I386_XSTATE_AVX:

 #define I386_XSTATE_SIZE(XCR0) \
     (((XCR0) & I386_XSTATE_BNDCFG) != 0 ? I386_XSTATE_BNDCFG_SIZE \
        : (((XCR0) & I386_XSTATE_BNDREGS) != 0 ? I386_XSTATE_BNDCFG_SIZE \
 -       : (((XCR0) & I386_XSTATE_AVX_SIZE) != 0 ? I386_XSTATE_AVX_SIZE \
 +       : (((XCR0) & I386_XSTATE_AVX) != 0 ? I386_XSTATE_AVX_SIZE \
        : I386_XSTATE_SSE_SIZE)))

The patch goes a step further and improves readability of the macro,
by adding a couple other auxiliary macros.


2013-11-26  Walfred Tedeschi  <walfred.tedeschi@intel.com>

	* i386-xstate.h (I386_XSTATE_MPX): New Macro.
	(I386_XSTATE_MPX_MASK): Makes use of I386_XSTATE_MPX.
	(HAS_MPX): New macro.
	(HAS_AVX): New macro.
	(I386_XSTATE_SIZE): Uses HAS_MPX and HAS_AVX.
revert patch from 2013-11-22

This reverts da2b2fdf57a96f7a5b6b153e94afb747e212b17f and some
follow-up patches.  They were incorrect.

2013-11-26  Tom Tromey  <tromey@redhat.com>

	* dwarf2-frame.c (dwarf2_frame_cache): Revert patch from
	2013-11-22.

2013-11-26  Tom Tromey  <tromey@redhat.com>

	* gdb.dwarf2/dw2-unspecified-ret-addr.S: Remove.
	* gdb.dwarf2/dw2-unspecified-ret-addr.c: Remove.
	* gdb.dwarf2/dw2-unspecified-ret-addr.exp: Remove.
bfd/elfnn-aarch64.c: Fix miscalculation of GOTPLT offset for ifunc syms.

The .got.plt header size was not being correctly taken into account
when calculating the offset for relocations against ifunc symbols.

bfd/ChangeLog:

2013-11-26  Will Newton  <will.newton@linaro.org>

	* elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Ensure
	PLT_INDEX is calculated using correct header size.

ld/testsuite/ChangeLog:

2013-11-26  Will Newton  <will.newton@linaro.org>

	* ld-aarch64/aarch64-elf.exp: Add ifunc-21 test.
	* ld-aarch64/ifunc-21.d: New file.
	* ld-aarch64/ifunc-21.s: Likewise.
bfd/elfnn-aarch64.c: Handle static links with ifunc correctly.

The code for handling GOT references to ifunc symbols in static links
was missing.

bfd/ChangeLog:

2013-11-26  Will Newton  <will.newton@linaro.org>

	* elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol):
	Handle STT_GNU_IFUNC symbols correctly in static links.

ld/testsuite/ChangeLog:

2013-11-26  Will Newton  <will.newton@linaro.org>

	* ld-aarch64/aarch64-elf.exp: Add ifunc-22.
	* ld-aarch64/ifunc-22.d: New file.
	* ld-aarch64/ifunc-22.s: Likewise.
Mark entirely optimized out value as non-lazy.

If a value is entirely optimized out, then there's nothing for
value_fetch_lazy to fetch.  Sequences like:

 if (value_lazy (retval))
   value_fetch_lazy (retval);

End up allocating the value contents buffer, wasting memory, for no
use.

gdb/ChangeLog
2013-11-26  Andrew Burgess  <aburgess@broadcom.com>

	* value.c (allocate_optimized_out_value): Mark value as non-lazy.
Fix demangler to handle conversion operators correctly.

libiberty/
	PR other/59195
	* cp-demangle.c (struct d_info_checkpoint): New struct.
	(struct d_print_info): Add current_template field.
	(d_operator_name): Set flag when processing a conversion
	operator.
	(cplus_demangle_type): When processing <template-args> for
	a conversion operator, backtrack if necessary.
	(d_expression_1): Renamed from d_expression.
	(d_expression): New wrapper around d_expression_1.
	(d_checkpoint): New function.
	(d_backtrack): New function.
	(d_print_init): Initialize current_template.
	(d_print_comp): Set current_template.
	(d_print_cast): Put current_template in scope for
	printing conversion operator name.
	(cplus_demangle_init_info): Initialize is_expression and
	is_conversion.
	* cp-demangle.h (struct d_info): Add is_expression and
	is_conversion fields.
	* testsuite/demangle-expected: New test cases.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@205292 138bc75d-0d04-0410-961f-82ee72b054a4
Tighten regexp in gdb.base/setshow.exp

  https://sourceware.org/ml/gdb-patches/2013-11/msg00817.html

gdb/testsuite/ChangeLog

	* gdb.base/setshow.exp: Add $gdb_prompt to the patterns in
	gdb_test_multiple.
Add HOSTING_SLIBS and use it for -pie

ld/

	PR ld/16259
	* Makefile.am (HOSTING_SLIBS): New.
	* configure.host (HOSTING_SLIBS): New.  Used for PIE.
	* configure.in (HOSTING_SLIBS): New AC_SUBST.
	* Makefile.in: Regenerated.
	* configure: Likewise.

ld/testsuite/

	PR ld/16259
	* config/default.exp (get_target_emul): Also set HOSTING_SLIBS.
	* lib/ld-lib.exp (default_ld_link): Use HOSTING_SLIBS for -pie.
Fix a typo
daily update
binutils/testsuite/
2013-11-27  Matthew Fortune <matthew.fortune@imgtec.com>

	* binutils-all/objcopy.exp: Consider mips-mti-elf the same as
	mips-sde-elf
	* binutils-all/readelf.exp: Likewise

gas/testsuite/
2013-11-27  Matthew Fortune <matthew.fortune@imgtec.com>

	* gas/mips/mips.exp: Consider mips-mti-elf the same as mips-sde-elf

ld/testsuite/
2013-11-27  Matthew Fortune <matthew.fortune@imgtec.com>

	* ld-mips-elf/mips-elf.exp: Consider mips-mti-elf the same as
	mips-sde-elf
Improve dump of xdata/pdata on x86_64.

bfd/
2013-11-27  Tristan Gingold  <gingold@adacore.com>

	* pei-x86_64.c (pex_regs): Make it const.  Add comments.
	(pex64_get_runtime_function): Do not split UnwindData.
	(pex64_get_unwind_info): Extract the chain and the handler.
	(pex64_xdata_print_uwd_codes): Rewritten: do not reverse print
	the opcode, handle version 2, add consistency check, make the
	code host neutral.
	(pex64_dump_xdata): Change arguments to pass the section and its
	content.  Handle version 2, change output.
	(pex64_bfd_print_pdata): Add comments, load section for xdata.
	Avoid duplicate outputs.

include/coff
2013-11-27  Tristan Gingold  <gingold@adacore.com>

	* pe.h (struct pex64_runtime_function): Remove isChained.
	(UWOP_SAVE_XMM): Add comment.
	(struct pex64_unwind_info): Remove extra fields.
	* gdb.base/callfuncs.c (main): Assign malloc's return value
	and free it afterwards.
	* gdb.base/charset-malloc.c (malloc_stub): Likewise.
	* gdb.base/printcmds.c (main): Likewise.
	* gdb.base/randomize.c (main): Free "p" and change breakpoint
	marker position.
	* gdb.base/setvar.c (dummy): Assign malloc's return value
	and free it afterwards.
[ld/testsuite/]
2013-11-27  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>

	* ld-plugin/lto.exp: Add -ffat-lto-objects.
	* lib/ld-lib.exp (check_lto_available): Likewise.
Make "set debug frame 1" use the standard print routine for optimized out values.

 ...
 - { frame_unwind_register_value (frame=0,regnum=7(rsp),...) -> optimized out }
 + { frame_unwind_register_value (frame=0,regnum=7(rsp),...) -> <optimized out> }
 ...

Tested on x86_64 Fedora 17.

2013-11-27  Andrew Burgess  <aburgess@broadcom.com>

	* frame.c: Include "valprint.h".
	(frame_unwind_register_value): Use value_optimized_out.
	* value.c (value_fetch_lazy): Likewise.
Make "set debug frame 1" output print <not saved> instead of <optimized out>.

"set debug frame 1" is printing "<optimized out>" for not saved
registers.  That's because the unwinders are returning optimized out
not_lval values instead of optimized out lval_register values.  "<not
saved>" is how val_print_optimized_out prints lval_register values.

  ...
  - { frame_unwind_register_value (frame=0,regnum=7(rsp),...) -> <optimized out> }
  + { frame_unwind_register_value (frame=0,regnum=7(rsp),...) -> <not saved> }
  ...

Tested on x86_64 Fedora 17.

2013-11-27  Pedro Alves  <palves@redhat.com>

	* frame-unwind.c (frame_unwind_got_optimized): Return
	an lval_register value instead of a not_lval value.
Fix type of not saved registers.

value_of_register_lazy uses the type of REGNUM in FRAME, but given
multi-arch, the arch of FRAME might be different from the previous
frame's arch, and therefore the type of register REGNUM should be
retrieved from the unwound arch.  This used to be correct before the
previous change.

Tested on x86_64 Fedora 17.

gdb/
2013-11-27  Pedro Alves  <palves@redhat.com>

	* frame-unwind.c (frame_unwind_got_optimized): Use the type of the
	register in the previous frame's arch.