Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1578597
| From | Andy Lutomirski <luto@amacapital.net> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] x86/selftests: add clobbers for int80 on x86_64 |
| Date | 2017-02-10 17:30 +0100 |
| Message-ID | <t9mf7-5Nv-3@gated-at.bofh.it> (permalink) |
| References | <t9mf7-5Nv-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Feb 10, 2017 at 3:52 AM, Dmitry Safonov <dsafonov@virtuozzo.com> wrote: > Kernel erases R8..R11 registers prior returning to userspace > from int80: https://lkml.org/lkml/2009/10/1/164 > > GCC can reuse this registers and doesn't expect them to change > during syscall invocation. I met this kind of bug in CRIU once > gcc 6.1 and clang stored local variables in those registers > and the kernel zerofied them during syscall: > https://github.com/xemul/criu/commit/990d33f1a1cdd17bca6c2eb059ab3be2564f7fa2 > > By that reason I suggest to add those registers to clobbers > in selftests. Seems reasonable, but presumably INT80_CLOBBERS should be defined the same way in all the tests. IOW, if the "flags" clobber is actually needed, it should be "flags", INT80_CLOBBERS (possibly without the comma if it's problematic).
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [PATCH] x86/selftests: add clobbers for int80 on x86_64 Andy Lutomirski <luto@amacapital.net> - 2017-02-10 17:30 +0100 Re: [PATCH] x86/selftests: add clobbers for int80 on x86_64 Andy Lutomirski <luto@amacapital.net> - 2017-02-10 17:50 +0100
csiph-web