Commit Graph

76906 Commits

Author SHA1 Message Date
Christian Groessler 8eeccb77c3 fix changelog entry: we still have 2013, not 2014 2013-04-26 19:31:15 +00:00
Christian Groessler 00a3147e7e * config/tc-z8k.c (md_parse_option): Set z8k_target_from_cmdline
according to the target parameter.  Don't call s_segm since s_segm
	calls bfd_set_arch_mach using stdoutput, but stdoutput isn't
	initialized yet.
	(md_begin): Call s_segm according to target parameter from command
	line.
2013-04-26 19:21:25 +00:00
Nick Clifton 778ee4a6f2 * scripttempl/avr.sc: Add ALIGN directive after *(.progmem*). 2013-04-26 15:27:55 +00:00
gdbadmin 2260af53be GDB 7.6 released. 2013-04-26 14:07:53 +00:00
Will Newton 0f7325f98d Add missing test files from 2013-03-21 commit. 2013-04-26 09:40:18 +00:00
Will Newton ed5acf27f7 Remove some dead code from elf64_aarch64_check_relocs.
bfd/ChangeLog:

2013-04-25  Will Newton  <will.newton@linaro.org>

	* elf64-aarch64.c (elf64_aarch64_check_relocs): Remove dead code.
2013-04-26 09:18:43 +00:00
Alan Modra 4706eab946 * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Test
unresolved_syms_in_shared_libs rather than !executable to
	determine whether to load DT_NEEDED libraries.
2013-04-26 01:26:45 +00:00
Alan Modra 0b000dbb49 daily update 2013-04-26 00:00:03 +00:00
gdbadmin 7f5039149d *** empty log message *** 2013-04-26 00:00:02 +00:00
Tom Tromey ff54693587 PR corefiles/14983:
* dwarf2read.c (process_full_comp_unit): Always create a static
	block.
gdb/testsuite
	* gdb.dwarf2/nostaticblock.exp: New file.
2013-04-25 16:25:37 +00:00
Alan Modra 49926cd0c8 bfd/
* config.bfd: Add powerpc64le-linux.
gas/
	* configure.in: Allow little-endian linux.
	* configure: Regenerate.
gold/
	* configure.tgt: Add powerpcle and powerpc64le.
ld/
	* Makefile.am (ALL_EMULATION_SOURCES): Add eelf32lppclinux.c.
	(eelf32lppclinux.c): New rule.
	* Makefile.in: Regenerate.
	* configure.tgt: Merge powerpc-linux and other powerpc-elf targets
	with corresponding little-endian targets.
	* emulparams/elf32lppc.sh: Update comment.
	* emulparams/elf32lppclinux.sh: New.
2013-04-25 13:22:52 +00:00
Hui Zhu c65e009ff7 Fix format error of ChangeLog. 2013-04-25 08:03:31 +00:00
Hui Zhu f6150862d2 2013-04-25 Hui Zhu <hui@codesourcery.com>
PR gdb/15186

	* ax.c (ax_printf): Add fflush.
2013-04-25 02:58:05 +00:00
gdbadmin 320395c55a *** empty log message *** 2013-04-25 00:00:32 +00:00
Alan Modra 7f99879879 daily update 2013-04-25 00:00:04 +00:00
Hui Zhu 40fb6c5ead 2013-04-25 Hui Zhu <hui@codesourcery.com>
* breakpoint.c (build_target_command_list): Change loc->cond_bytecode
	to loc->cmd_bytecode.
2013-04-24 23:09:31 +00:00
Sandra Loosemore e3031850bc 2013-04-24 Sandra Loosemore <sandra@codesourcery.com>
gas/
	* config/tc-nios2.c (nios2_control_register_arg_p): Rename
	"fstatus" control register to "eccinj".

	opcodes/
	* nios2-opc.c (nios2_builtin_reg): Rename "fstatus" control register
	to "eccinj".
2013-04-24 20:51:58 +00:00
Doug Evans 74e04d1ccf * dwarf2read.c (setup_type_unit_groups): Fix comment. 2013-04-24 19:12:26 +00:00
H.J. Lu 05567e3d0b Enable x32 for x86_64-*-elf*
This patch enables x32 for x86_64-*-elf* for embedded target and disables
rex tests since it uses '/' as prefix separator which is `\' for
x86_64-*-elf*.

bfd/

	* config.bfd (targ_selvecs): Add bfd_elf32_x86_64_vec for
	x86_64-*-elf*.

gas/testsuite/

	* gas/i386/rex.d: Skip x86_64-*-elf*.
	* gas/i386/ilp32/rex.d: Likewise.

ld/

	* configure.tgt (targ_extra_emuls): Adds elf32_x86_64 for
	x86_64-*-elf*.
	(targ_extra_libpath): Likewise.
	(tdir_elf_i386): Replace x86_64 with i386 for x86_64-*-elf*.
2013-04-24 18:58:14 +00:00
Keith Seitz 3cf62c1d5c * tracepoint.c (trace_save): Call the writer's start method. 2013-04-24 18:22:31 +00:00
Yufeng Zhang 4390599b4e ld/
* emulparams/aarch64elf.sh: Define ELFSIZE=64.
	* emulparams/aarch64linux.sh: Ditto.
	* emultempl/aarch64elf.em (aarch64_elf_before_allocation):
	Replace elf64 with elf${ELFSIZE}.
	(elf64_aarch64_add_stub_section): Likewise.
	(build_section_lists): Likewise.
	(gld${EMULATION_NAME}_after_allocation): Likewise.
	(gld${EMULATION_NAME}_finish): Likewise.
	(aarch64_elf_create_output_section_statements): Likewise.
2013-04-24 17:22:31 +00:00
Roland McGrath 99059e56e2 bfd/
* elf32-arm.c (elf32_arm_allocate_plt_entry): If HTAB->nacl_p,
	allocate space for PLT header even if IS_IPLT_ENTRY.
	(arm_nacl_put_plt0): New function, broken out of ...
	(elf32_arm_finish_dynamic_sections): ... here.  Call it.
	If HTAB->nacl_p, set up the PLT header in .iplt too.
	(elf32_arm_output_arch_local_syms): If HTAB->nacl_p, write
	a mapping symbol for the start of .iplt too.
2013-04-24 16:29:55 +00:00
Nick Clifton 2cfa18a94a PR ld/15389
* scripttempl/avr.sc: Add .note.gnu.build-id section.
2013-04-24 15:28:12 +00:00
Muhammad Bilal bf9e4d0c1f 2013-04-24 Muhammad Bilal <mbilal@codesourcery.com>
PR gdb/10462
	* cli/cli-decode.c (lookup_command): Show an error if there is no space
	before argument.

2013-04-24  Muhammad Bilal  <mbilal@codesourcery.com>

	PR gdb/10462
	* gdb.base/setshow.exp: Add test case.
2013-04-24 14:29:17 +00:00
Nick Clifton ad83dabf1c oops - revert accidental commit 2013-04-24 13:24:30 +00:00
Nick Clifton 7b5d8d9642 *** empty log message *** 2013-04-24 13:22:43 +00:00
Nick Clifton 544008aaf7 * ecoff.c: casting the return value of BFD_ALIGN to int
* elf32-tic6x.c: removing unused variables
	* elf32-v850.c: redefine the type of a variable (int -> bfd_vma)
	* vms-alpha.c: initialize a variable
2013-04-24 13:19:27 +00:00
gdbadmin 901d9a9160 *** empty log message *** 2013-04-24 00:00:32 +00:00
Alan Modra 86c8247292 daily update 2013-04-24 00:00:04 +00:00
Tom Tromey 5d71132c29 * common/filestuff.c: Check USE_WIN32API before including
sys/socket.h.
	(HAVE_F_GETFD): New define.
	(mark_cloexec): Check HAVE_F_GETFD.
	(gdb_open_cloexec): Change 'mode' to unsigned long.
	(gdb_socketpair_cloexec): Check HAVE_SOCKETPAIR.
	(gdb_pipe_cloexec): Check HAVE_PIPE.
	* common/filestuff.h (gdb_open_cloexec): Change 'mode' to unsigned
	long.
2013-04-23 15:49:25 +00:00
DJ Delorie 29f045bb48 merge from gcc 2013-04-23 04:05:04 +00:00
Hui Zhu a11cfd87c0 2013-04-23 Hui Zhu <hui@codesourcery.com>
PR gdb/15293

	* breakpoint.c (bpstat_what): Add BPSTAT_WHAT_SINGLE to bp_dprintf.

2013-04-23  Hui Zhu  <hui@codesourcery.com>

	PR gdb/15293

	* gdb.base/dprintf.exp: Add ignore command.
2013-04-23 03:20:21 +00:00
Hui Zhu 2d9442cc40 2013-04-23 Hui Zhu <hui@codesourcery.com>
PR gdb/15165

	* breakpoint.c (dprintf_print_recreate): New.
	(save_breakpoints): Let it not save dprintf commands.
	(initialize_breakpoint_ops): Set dprintf_print_recreate.

2013-04-23  Hui Zhu  <hui@codesourcery.com>

	PR gdb/15165

	* gdb.base/save-bp.exp: Add test for dprintf.
2013-04-23 02:42:44 +00:00
Alan Modra e91d998a24 daily update 2013-04-23 00:00:04 +00:00
gdbadmin 4986ea1b42 *** empty log message *** 2013-04-23 00:00:02 +00:00
Tom Tromey 0f3305ed70 * gdb.gdb/selftest.exp (do_steps_and_nexts): Check for
notice_open_fds.
2013-04-22 20:18:23 +00:00
Jan-Benedict Glaw b836cb185e 2013-04-22 Jan-Benedict Glaw <jbglaw@lug-owl.de>
* Makefile.def: Sync with GCC.
	* Makefile.in: Regenerate.
2013-04-22 17:11:22 +00:00
Tom Tromey 614c279dda PR gdb/7912:
* Makefile.in (SFILES): Add filestuff.c
	(COMMON_OBS): Add filestuff.o.
	(filestuff.o): New target.
	* auto-load.c (auto_load_objfile_script_1): Use
	gdb_fopen_cloexec.
	* auxv.c (procfs_xfer_auxv): Use gdb_open_cloexec.
	* cli/cli-cmds.c (shell_escape): Call close_most_fds.
	* cli/cli-dump.c (fopen_with_cleanup): Use gdb_fopen_cloexec.
	* common/agent.c (gdb_connect_sync_socket): Use
	gdb_socket_cloexec.
	* common/filestuff.c: New file.
	* common/filestuff.h: New file.
	* common/linux-osdata.c (linux_common_core_of_thread)
	(command_from_pid, commandline_from_pid, print_source_lines)
	(linux_xfer_osdata_shm, linux_xfer_osdata_sem)
	(linux_xfer_osdata_msg, linux_xfer_osdata_modules): Use
	gdb_fopen_cloexec.
	* common/linux-procfs.c (linux_proc_get_int)
	(linux_proc_pid_has_state): Use gdb_fopen_cloexec.
	* config.in, configure: Rebuild.
	* configure.ac: Don't check for sys/socket.h.  Check for
	fdwalk, pipe2.
	* corelow.c (core_open): Use gdb_open_cloexec.
	* dwarf2read.c (write_psymtabs_to_index): Use gdb_fopen_cloexec.
	* fork-child.c (fork_inferior): Call close_most_fds.
	* gdb_bfd.c (gdb_bfd_open): Use gdb_open_cloexec.
	* inf-child.c (inf_child_fileio_readlink): Use gdb_open_cloexec.
	* linux-nat.c (linux_nat_thread_name, linux_proc_pending_signals):
	Use gdb_fopen_cloexec.
	(linux_proc_xfer_partial, linux_proc_xfer_spu): Use
	gdb_open_cloexec.
	(linux_async_pipe): Use gdb_pipe_cloexec.
	* remote-fileio.c (remote_fileio_func_open): Use
	gdb_open_cloexec.
	* remote.c (remote_file_put, remote_file_get): Use
	gdb_fopen_cloexec.
	* ser-pipe.c (pipe_open): Use gdb_socketpair_cloexec,
	close_most_fds.
	* ser-tcp.c (net_open): Use gdb_socket_cloexec.
	* ser-unix.c (hardwire_open): Use gdb_open_cloexec.
	* solib.c (solib_find): Use gdb_open_cloexec.
	* source.c (openp, find_and_open_source): Use gdb_open_cloexec.
	* tracepoint.c (tfile_start): Use gdb_fopen_cloexec.
	(tfile_open): Use gdb_open_cloexec.
	* tui/tui-io.c (tui_initialize_io): Use gdb_pipe_cloexec.
	* ui-file.c (gdb_fopen): Use gdb_fopen_cloexec.
	* xml-support.c (xml_fetch_content_from_file): Use
	gdb_fopen_cloexec.
	* main.c (captured_main): Call notice_open_fds.
gdbserver
	* Makefile.in (SFILES): Add filestuff.c.
	(OBS): Add filestuff.o.
	(filestuff.o): New target.
	* config.in, configure: Rebuild.
	* configure.ac: Check for fdwalk, pipe2.
2013-04-22 16:46:15 +00:00
Edjunior Barbosa Machado 5fda2332f3 2013-04-22 Edjunior Machado <emachado@linux.vnet.ibm.com>
* remote-sim.c (dump_mem): Change the type of 'buf' parameter from
'char *' to 'gdb_byte *'.
(gdbsim_store_register): Change the type of 'tmp' from 'char' to
'gdb_byte'.
2013-04-22 15:50:57 +00:00
Jan-Benedict Glaw e7d5abf103 2013-04-22 Jan-Benedict Glaw <jbglaw@lug-owl.de>
* configure.ac: Sync with GCC.
	* configure: Regenerated.
2013-04-22 15:25:09 +00:00
Alan Modra 86f7d49be5 PR ld/15382
* elf-bfd.h (RELOC_AGAINST_DISCARDED_SECTION): Don't multiply
	sh_size or reloc_count adjustment by count.
2013-04-22 15:03:01 +00:00
Yao Qi eb6c553bd4 gdb/
* infrun.c: Fix typo in comment.
2013-04-22 09:34:27 +00:00
Sergio Durigan Junior d504301e64 2013-04-22 Sergio Durigan Junior <sergiodj@redhat.com>
* gdb.arch/arm-bl-branch-dest.exp: Replace additional_flags by
	ldflags.
2013-04-22 09:32:21 +00:00
Sergio Durigan Junior 9991b20795 Andrew Haley found a bug on GDB running on ARM when using
--enable-64-bit-bfd.  Basically the issue happens when dealing with "bl"
instructions: GDB does branch destination calculation and (wrongly)
sign-extends the PC.  Here is a piece of his original message explaining
the problem:

>      next_pc = arm_get_next_pc (frame, get_frame_pc (frame));
>
>      /* The Linux kernel offers some user-mode helpers in a high page.  We can
>         not read this page (as of 2.6.23), and even if we could then we couldn't
>         set breakpoints in it, and even if we could then the atomic operations
>         would fail when interrupted.  They are all called as functions and return
>         to the address in LR, so step to there instead.  */
>      if (next_pc > 0xffff0000)
>        next_pc = get_frame_register_unsigned (frame, ARM_LR_REGNUM);
>
>      arm_insert_single_step_breakpoint (gdbarch, aspace, next_pc);
>
>    Unfortunately, branch destination addresses are SIGN EXTENDED to 64
>    bits.  So,
>
>    (top-gdb) p/x next_pc
>    $14 = 0xffffffffb6df2864
>
>    Which triggers the next_pc = get_frame_register_unsigned(), and we
>    cannot step into any branches because the destination PC is wrong.

Anyway, the fix is simple and Andrew himself provided it for us.  It
took a while for me to figure out how to trigger the bug (in order to
write a testcase for it), but I finally made it.

The attached patch fixes the problem (by casting to `unsigned long'
instead of just `long'), and also includes a testcase to reproduce the
issue.

gdb/ChangeLog:

2013-04-22  Andrew Haley  <aph@redhat.com>

	* arm-tdep.c (BranchDest): Cast result as "unsigned long",
	instead of "long".

gdb/testsuite/ChangeLog:

2013-04-22  Sergio Durigan Junior  <sergiodj@redhat.com>

	* gdb.arch/arm-bl-branch-dest.c: New file.
	* gdb.arch/arm-bl-branch-dest.exp: Likewise.
2013-04-22 09:20:33 +00:00
Alan Modra bfeb4a285a bfd/
* elf64-ppc.c (ppc64_elf_check_relocs): Don't call
	create_linkage_sections here..
	(ppc64_elf_init_stub_bfd): ..do so here.  Return status.
	(create_linkage_sections): Move earlier in file.
	(ppc64_elf_setup_section_lists): Remove now useless htab->brlt test.
	* elf64-ppc.h (ppc64_elf_init_stub_bfd): Update proto.
ld/
	* emultempl/ppc64elf.em (ppc_create_output_section_statements):
	Check return from ppc64_elf_init_stub_bfd.
ld/testsuite/
	* ld-powerpc/tlsexe.d: Adjust.
	* ld-powerpc/tlsexe.r: Adjust.
	* ld-powerpc/tlsexetoc.d: Adjust.
	* ld-powerpc/tlsexetoc.r: Adjust.
	* ld-powerpc/tlsso.d: Adjust.
	* ld-powerpc/tlsso.r: Adjust.
	* ld-powerpc/tlstocso.d: Adjust.
	* ld-powerpc/tlstocso.r: Adjust.
2013-04-22 03:11:40 +00:00
gdbadmin 1f81bca148 *** empty log message *** 2013-04-22 00:00:32 +00:00
Alan Modra b82b1bb254 daily update 2013-04-22 00:00:04 +00:00
Alan Modra a40347502e PR gold/15355
* layout.cc (Layout::segment_precedes): Allow more than one
	segment with the same type and flags.
2013-04-21 23:21:56 +00:00
gdbadmin e365947e94 *** empty log message *** 2013-04-21 00:00:32 +00:00
Alan Modra f6ac2e48e4 daily update 2013-04-21 00:00:05 +00:00