Bluefoxicy has quit [Read error: No route to host]
Bluefoxicy has joined #riscv
ldevulder has joined #riscv
emdevt has joined #riscv
<sorear>
i'm a little concerned that the "preserve/save vectors across linux syscalls" sysctl will turn into a feature that needs to be supported in perpetuity
naoki has quit [Quit: naoki]
<drewfustini>
We talked about it in the patchwork call and it seems like the correct approach is to improve the save/restore vector state handling.
<drewfustini>
The current clobbering happens in the ecall handler before the syscall runs.
<drewfustini>
It should really be evaluated after the syscall runs and before the ecall handler returns
<drewfustini>
I'm looking at how to improve that now
<drewfustini>
Palmer said that if it is still a performance problem, then we could explore the sysctl
<drewfustini>
But that I need to look at the full scope of vector state handling and not just this one micro benchmark
emdevt has quit [Ping timeout: 248 seconds]
agentcasey has quit [Quit: ZNC 1.9.0+deb2build3 - https://znc.in]
agentcasey has joined #riscv
Kyuvi has quit [Ping timeout: 250 seconds]
robalni has joined #riscv
<bjdooks>
right, sent a new big-endian set against -rc2 out
<bjdooks>
I'm off to OSS_EU next week
jacklsw has joined #riscv
ldevulder has quit [Read error: Connection reset by peer]
ldevulder has joined #riscv
jacklsw has quit [Quit: Back to the real world]
<drewfustini>
see you there!
s1b1 has joined #riscv
Trifton has quit [Remote host closed the connection]
Trifton has joined #riscv
JanC has quit [Ping timeout: 248 seconds]
JanC has joined #riscv
<dramforever[m]1>
drewfustini: i'm really glad "actually fixing vector state handling" is back on the table
foxbat has quit [Ping timeout: 244 seconds]
<drewfustini>
Yeah, Palmer said that it should be handled after the syscall runs which makes sense. Clobbering before entering the syscall was just done while trying to fix a signal handler bug 2 years ago
matrixbrain has joined #riscv
JanC has quit [Killed (tantalum.libera.chat (Nickname regained by services))]
JanC has joined #riscv
<dramforever[m]1>
still think i have a point with the "Initial" thing
<drewfustini>
If the state is tracked properly, then it may not be a problem that is clobbered in some circumstances before the ecall handler returns
<drewfustini>
Yeah, I need to understand Andy's comments better
<dramforever[m]1>
but i'm not yet qualified to comment on the uh ptrace? thing
<dramforever[m]1>
but anyway i think the best possible case is we never have the sysctl ever
<dramforever[m]1>
that is agreed i think?
ldevulder has quit [Quit: Leaving]
<drewfustini>
Palmer said one issue with the sysctl is that it creates two scenarios to try in the future when debugging which is good point
<drewfustini>
There was also the point about it's possible that many syscalls will actually use vector in the kernel in which case avoiding the clobber doesn't necessarily matter that much
<drewfustini>
One of my takeaways was it would be good for me to generate some stats on how often the kernel uses vector for various workloads
<dramforever[m]1>
the classic "more research is needed"
JanC is now known as Guest1717
Guest1717 has quit [Killed (calcium.libera.chat (Nickname regained by services))]
JanC has joined #riscv
Noisytoot has left #riscv [Leaving]
psydroid2 has joined #riscv
<sorear>
i think we have 3 groups of syscalls: 1. doesn't touch vector, fastest approach is to preserve user state 2. vector used in kernel, needs to be saved/restored or cleared once on exit 3. blocking IPC syscall, we can save/restore as part of the user context switch or clear on exit
<sorear>
and something like read() could hit any of those categories, depending on whether it's a pipe, procfs file, or something on disk behind raid6 and dmcrypt
<sorear>
the fastest approach would be "state after sycalls nondetermistically may be cleared or preserved", being consistent is nicer for debugging, consistently _preserving_ is a state I'd like to avoid
<sorear>
maybe 4. fork(). someone needs to think about whether the "clobbered" state of vectors after syscalls is the same as the initial state after execve, we need to prevent vector state leakage across execve regardless
peeps[zen] is now known as peepsalot
<bjdooks>
I need to make a decision on riscv summit
___nick___ has quit [Ping timeout: 248 seconds]
foxbat has joined #riscv
matrixbrain has quit [Quit: Leaving]
djdelorie has quit [Remote host closed the connection]
ssb has quit [Server closed connection]
ssb has joined #riscv
<drewfustini>
> consistently _preserving_ is a state I'd like to avoid
<drewfustini>
Yeah, I think this is not needed unless there really is a new ABI offered. I don't think that is a concern for now
<drewfustini>
bjdooks: I'll be there but it is far for other side of Atlantic
<drewfustini>
sorear: thanks for breaking it down into those categoriees
LinuxRenaissance has quit [Ping timeout: 252 seconds]