MCPcopy Create free account
hub / github.com/F-Stack/f-stack / fpuinit_bsp2

Function fpuinit_bsp2

freebsd/amd64/amd64/fpu.c:372–388  ·  view source on GitHub ↗

* Calculate the fpu save area size. */

Source from the content-addressed store, hash-verified

370 * Calculate the fpu save area size.
371 */
372static void
373fpuinit_bsp2(void)
374{
375 u_int cp[4];
376
377 if (use_xsave) {
378 cpuid_count(0xd, 0x0, cp);
379 cpu_max_ext_state_size = cp[1];
380
381 /*
382 * Reload the cpu_feature2, since we enabled OSXSAVE.
383 */
384 do_cpuid(1, cp);
385 cpu_feature2 = cp[2];
386 } else
387 cpu_max_ext_state_size = sizeof(struct savefpu);
388}
389
390/*
391 * Initialize the floating point unit.

Callers 1

fpuinitFunction · 0.85

Calls 2

cpuid_countFunction · 0.50
do_cpuidFunction · 0.50

Tested by

no test coverage detected