diff options
author | Michal Meloun <mmel@FreeBSD.org> | 2017-03-26 08:36:56 +0000 |
---|---|---|
committer | Michal Meloun <mmel@FreeBSD.org> | 2017-03-26 08:36:56 +0000 |
commit | 6fc9f4dbc81f63b44d5cffb899b4e6e002345142 (patch) | |
tree | 06641c1b618e2df32eb91a4dfd068573728c416f /lib/libthread_db | |
parent | d9d7354968e9a2b71eac74a869f27a0ae2fdb0b2 (diff) | |
download | src-6fc9f4dbc81f63b44d5cffb899b4e6e002345142.tar.gz src-6fc9f4dbc81f63b44d5cffb899b4e6e002345142.zip |
Preserve VFP state across signal delivery.
We don't have enouch space to store full VFP context within mcontext
stucture. Due to this:
- follow i386/amd64 way and store VFP state outside of the mcontext_t
but point to it. Use the size of VFP state structure as an 'magic'
indicator of the saved VFP state presence.
- teach set_mcontext() about this external storage.
- for signal delivery, store VFP state to expanded 'struct sigframe'.
Submited by: Andrew Gierth (initial version)
PR: 217611
MFC after: 2 weeks
Notes
Notes:
svn path=/head/; revision=315974
Diffstat (limited to 'lib/libthread_db')
-rw-r--r-- | lib/libthread_db/arch/arm/libpthread_md.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libthread_db/arch/arm/libpthread_md.c b/lib/libthread_db/arch/arm/libpthread_md.c index a733475dbc21..086a3b530088 100644 --- a/lib/libthread_db/arch/arm/libpthread_md.c +++ b/lib/libthread_db/arch/arm/libpthread_md.c @@ -90,7 +90,9 @@ pt_fpreg_to_ucontext(const struct fpreg *r __unused, ucontext_t *uc) mcontext_t *mc = &uc->uc_mcontext; /* XXX */ - memset(&mc->mc_spare, 0, sizeof(mc->mc_spare)); + mc->mc_vfp_size = 0; + mc->mc_vfp_ptr = NULL; + memset(mc->mc_spare, 0, sizeof(mc->mc_spare)); } void |