Rev 80 | Rev 90 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 80 | Rev 84 | ||
---|---|---|---|
Line 49... | Line 49... | ||
49 | } |
49 | } |
50 | 50 | ||
51 | 51 | ||
52 | void fpu_lazy_context_save(fpu_context_t *fctx) |
52 | void fpu_lazy_context_save(fpu_context_t *fctx) |
53 | { |
53 | { |
- | 54 | printf(""); |
|
54 | asm( |
55 | asm( |
55 | "mov %0,%%eax;" |
56 | "mov %0,%%eax;" |
56 | "fxsave (%%eax);" |
57 | "fxsave (%%eax);" |
57 | "ret;" |
- | |
58 | :"=m"(fctx) |
58 | :"=m"(fctx) |
59 | : |
59 | : |
60 | :"%eax" |
60 | :"eax" |
61 | ); |
61 | ); |
- | 62 | printf(""); |
|
62 | } |
63 | } |
63 | 64 | ||
64 | void fpu_lazy_context_restore(fpu_context_t *fctx) |
65 | void fpu_lazy_context_restore(fpu_context_t *fctx) |
65 | { |
66 | { |
- | 67 | printf(""); |
|
66 | asm( |
68 | asm( |
67 | "mov %0,%%eax;" |
69 | "mov %0,%%eax;" |
68 | "fxrstor (%%eax);" |
70 | "fxrstor (%%eax);" |
69 | "ret;" |
- | |
70 | :"=m"(fctx) |
71 | :"=m"(fctx) |
71 | : |
72 | : |
72 | :"%eax" |
73 | :"eax" |
73 | ); |
74 | ); |
- | 75 | printf(""); |
|
74 | } |
76 | } |
75 | 77 | ||
76 | void fpu_init(void) |
78 | void fpu_init(void) |
77 | { |
79 | { |
78 | asm( |
80 | asm( |