[cfe-dev] Preserve SSE state in interrupt handler

Anatol Pomozov via cfe-dev cfe-dev at lists.llvm.org
Wed Sep 13 15:10:05 PDT 2017


Hi

On Wed, Sep 13, 2017 at 2:16 PM, David Chisnall
<David.Chisnall at cl.cam.ac.uk> wrote:
> On 13 Sep 2017, at 21:16, Anatol Pomozov via cfe-dev <cfe-dev at lists.llvm.org> wrote:
> I don’t believe the interrupt attribute is intended for this purpose: certainly no mainstream operating systems use it.  It is intended for people writing embedded systems that use x86, not for x86 systems using full-blown operating systems, which typically need much more control over how context switches happen as a result of interrupts.

w.r.t. interrupt handling requirements there is not much difference
between embedded systems and full-blown OS. Both types of project
require correct, fast and easy-to-use interruption handling.

> certainly no mainstream operating systems use it

The reason for this attribute low adoption is that the attribute is
not fully functional on both major compilers yet. Actually GCC added
this attribute to x86 only few months back (the fact Clang had this
feature implemented was one of the reasons why GCC finally added it).
We will have higher adoption of this feature once we have attribute
that handles full CPU state preservation correctly (i.e. saves SSE/FPU
state as well) with all major compilers.



More information about the cfe-dev mailing list