aboutsummaryrefslogtreecommitdiff
path: root/sys/amd64/include/proc.h
diff options
context:
space:
mode:
authorKonstantin Belousov <kib@FreeBSD.org>2021-09-13 21:05:47 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2021-09-21 17:20:15 +0000
commitdf8dd6025af88a99d34f549fa9591a9b8f9b75b1 (patch)
treeb635520cbc5b72d1e33e072b02ec87d99aac2729 /sys/amd64/include/proc.h
parent0f6829488ef32142b9ea1c0806fb5ecfe0872c02 (diff)
downloadsrc-df8dd6025af88a99d34f549fa9591a9b8f9b75b1.tar.gz
src-df8dd6025af88a99d34f549fa9591a9b8f9b75b1.zip
amd64: stop using top of the thread' kernel stack for FPU user save area
Instead do one more allocation at the thread creation time. This frees a lot of space on the stack. Also do not use alloca() for temporal storage in signal delivery sendsig() function and signal return syscall sys_sigreturn(). This saves equal amount of space, again by the cost of one more allocation at the thread creation time. A useful experiment now would be to reduce KSTACK_PAGES. Reviewed by: jhb, markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D31954
Diffstat (limited to 'sys/amd64/include/proc.h')
-rw-r--r--sys/amd64/include/proc.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/amd64/include/proc.h b/sys/amd64/include/proc.h
index 0f8cf50e326d..bd07f70f8d44 100644
--- a/sys/amd64/include/proc.h
+++ b/sys/amd64/include/proc.h
@@ -75,6 +75,8 @@ struct mdthread {
int md_efirt_dis_pf; /* (k) */
struct pcb md_pcb;
vm_offset_t md_stack_base;
+ struct savefpu *md_usr_fpu_save;
+ struct savefpu *md_fpu_scratch;
};
struct mdproc {