[PATCH gnumach v3 1/3] add xfloat thread state interface

2024-09-04 Thread Luca Dariz
* i386/i386/fpu.c: extend current getter and setter to support the extended state; move the struct casting here to reuse the locking and allocation logic for the thread state; make sure the new state is set as valid, otherwise it won't be applied; add i386_get_xstate_size() to dynamically r

[PATCH gnumach 3/3] x86_64: fix double fault handler

2024-09-04 Thread Luca Dariz
* x86_64/locore.S: adjust to the changes in the thread state structure (segment registers), and add the missing opcode. --- x86_64/locore.S | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x86_64/locore.S b/x86_64/locore.S index 8f39a677..376f41c1 100644 --- a/x86_64/locore.S

[PATCH gnumach v3 2/3] add tests for FLOAT/XFLOAT state

2024-09-04 Thread Luca Dariz
--- tests/include/testlib.h | 1 + tests/test-thread-state-fp.c | 240 +++ tests/testlib.c | 16 +++ tests/user-qemu.mk | 3 +- 4 files changed, 259 insertions(+), 1 deletion(-) create mode 100644 tests/test-thread-state-fp.c diff