6 releases (stable)

2.0.2 Feb 9, 2022
2.0.0 Nov 22, 2021
1.0.0 Sep 21, 2021
0.1.1 Aug 20, 2020
0.1.0 Aug 20, 2020

#10 in #area

Download history 26/week @ 2024-07-17 28/week @ 2024-07-24 47/week @ 2024-07-31 27/week @ 2024-08-07 9/week @ 2024-08-14 6/week @ 2024-08-21 21/week @ 2024-08-28 108/week @ 2024-09-04 87/week @ 2024-09-11 39/week @ 2024-09-18 136/week @ 2024-09-25 115/week @ 2024-10-02 41/week @ 2024-10-09 37/week @ 2024-10-16 30/week @ 2024-10-23 25/week @ 2024-10-30

138 downloads per month
Used in 4 crates (3 directly)

Apache-2.0

13KB
265 lines

Workflow Status Average time to resolve an issue Percentage of issues still open Maintenance

xsave

This crate contains a practical implementation of the x86 xsave semantics.

We do not intend to support all possible variations of the instructures, nor do we intend to calculate the size of the xsave area dynamically. Instead, our practical strategy will overallocate the size of the xsave area so that we get a constant size for the struct. This allows for substantially easier embedding in other contexts.

For example, clearing the extended CPU state is a simple:

use xsave::XSave;

XSave::default().load();

Likewise, you can save and restore the extended CPU state like this:

use xsave::XSave;

let mut xsave = XSave::default();
xsave.save();
xsave.load();

License: Apache-2.0

Dependencies

~4MB
~79K SLoC