This is the mail archive of the
gdb-cvs@sourceware.org
mailing list for the GDB project.
gdb and binutils branch master updated. 6ae274b7dc305ae7cebcf55c5018dab05228235a
- From: qiyao at sourceware dot org
- To: gdb-cvs at sourceware dot org
- Date: 29 Oct 2014 05:45:14 -0000
- Subject: gdb and binutils branch master updated. 6ae274b7dc305ae7cebcf55c5018dab05228235a
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gdb and binutils".
The branch, master has been updated
via 6ae274b7dc305ae7cebcf55c5018dab05228235a (commit)
from 5e1b37e7a31f898916d3d5b7e9f6f4f6bf2b50ce (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6ae274b7dc305ae7cebcf55c5018dab05228235a
commit 6ae274b7dc305ae7cebcf55c5018dab05228235a
Author: Yao Qi <yao@codesourcery.com>
Date: Wed Oct 29 13:39:16 2014 +0800
Fix skipping stack protector on arm
This patch fixes the bug in my patch skipping stack protector
https://www.sourceware.org/ml/gdb-patches/2010-12/msg00110.html
In my skipping stack protector patch, I misunderstood the constant vs.
immediate on instruction encodings, and treated immediate as constant
by mistake. The instruction 'ldr Rd, [PC, #immed]' loads the
address of __stack_chk_guard to Rd, and #immed is an offset from PC.
We should get the __stack_chk_guard from *(pc + #immed).
As a result of this mistake, arm_analyze_load_stack_chk_guard returns
the wrong address of __stack_chk_guard, and the symbol
__stack_chk_guard can't be found. However, we continue to match the
following instructions when symbol isn't found, so the code still
works. In other words, the code just matches the instruction pattern
without checking __stack_chk_guard symbol correctly.
Joel's patch <https://sourceware.org/ml/gdb-patches/2014-10/msg00605.html>
makes the heuristics stricter that we stop matching instructions if
symbol __stack_chk_guard isn't found. Then the bug is exposed. This
patch is to correct the load address computation for ldr instruction,
and it fixes some fails in gdb.mi/gdb792.exp on armv4t both arm and
thumb mode.
Regression tested on arm-linux-gnueabi target with
{armv4t, armv7-a} x {marm, mthumb} x {-fstack-protector,-fno-stack-protector}
gdb:
2014-10-29 Yao Qi <yao@codesourcery.com>
* arm-tdep.c (arm_analyze_load_stack_chk_guard): Compute the
loaded address correctly of ldr instruction.
-----------------------------------------------------------------------
Summary of changes:
gdb/ChangeLog | 5 +++++
gdb/arm-tdep.c | 11 ++++++++---
2 files changed, 13 insertions(+), 3 deletions(-)
hooks/post-receive
--
gdb and binutils