diff options
author | Yao Qi <yao.qi@linaro.org> | 2017-08-21 10:30:48 +0100 |
---|---|---|
committer | Yao Qi <yao.qi@linaro.org> | 2017-08-21 11:16:08 +0100 |
commit | c67782524530b3d146d0e9ac51d3338b5ddb3f95 (patch) | |
tree | af3ac984485ec924d5958729ff1d03e13023734e | |
parent | 2a9fdd0e5d2a6c123bacb9077d94d565f06eba67 (diff) | |
download | binutils-gdb-c67782524530b3d146d0e9ac51d3338b5ddb3f95.tar.gz |
Return X86_XSTATE_SSE_MASK instead of 0 in i386fbsd_core_read_xcr0
i386fbsd_core_read_xcr0 reads the value of xcr0 from the corefile. If
it fails, returns 0. This makes its caller {i386,amd64}_target_description
has to handle this special value. IMO, i386fbsd_core_read_xcr0 should
return the default xcr0 in case of error.
gdb:
2017-08-21 Yao Qi <yao.qi@linaro.org>
* i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
X86_XSTATE_SSE_MASK instead of 0.
-rw-r--r-- | gdb/i386-fbsd-tdep.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/i386-fbsd-tdep.c b/gdb/i386-fbsd-tdep.c index 594b8f6f0a4..baca978612d 100644 --- a/gdb/i386-fbsd-tdep.c +++ b/gdb/i386-fbsd-tdep.c @@ -248,14 +248,14 @@ i386fbsd_core_read_xcr0 (bfd *abfd) { warning (_("Couldn't read `xcr0' bytes from " "`.reg-xstate' section in core file.")); - return 0; + return X86_XSTATE_SSE_MASK; } xcr0 = bfd_get_64 (abfd, contents); } } else - xcr0 = 0; + xcr0 = X86_XSTATE_SSE_MASK; return xcr0; } |