[klibc] Debian #943425: [s390x] setjmp/longjmp do not save/restore all registers in use (was Use of $v10 register (was Re: klibc: [s390x] SIGSEGV in mksh testcase funsub-2))
tg at mirbsd.de
Mon May 3 16:25:28 PDT 2021
>So, setjmp/longjmp in klibc save f1/f3/f5/f7 (as shown on Wikipedia
>“the z/Architecture ABI, used in Linux” a page down), while
>glibc’s save f8–f15 instead.
Jessica Clarke brought out docs saying f8‥f15 must be saved, the
other FPU registers not:
This matches what glibc does. Maybe an s390x porter wishes to fix
>shows that the vector registers overlap and extend the FPU registers.
>• is register v10 (vector extension) even supposed to be used?
This needs to be answered, I guess, because…
>• klibc does not really support the FPU anyway
… GCC chooses to allocate an FPU register for a pointer value.
>• the half of v10 that equals f10 just HAPPENS to be saved by
> glibc, but what if the upper half, that is outside of the FPU,
> is used?
The question here is, does GCC only use the halves of the half
of the vector registers that match the FPU registers?
@klibc list: as indicated earlier, I can provide a patch if needed
(though it should be obvious).
22:20⎜<asarch> The crazy that persists in his craziness becomes a master
22:21⎜<asarch> And the distance between the craziness and geniality is
only measured by the success 18:35⎜<asarch> "Psychotics are consistently
inconsistent. The essence of sanity is to be inconsistently inconsistent
More information about the klibc