Project

General

Profile

Actions

Feature #8539

closed

Feature #8534: Want AVX-512 Support

better handling for AMD-specifc *save_ctxt FP exceptions

Added by Robert Mustacchi about 5 years ago. Updated about 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
kernel
Start date:
2017-07-25
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
External Bug:

Description

In xsave_ctxt we have this block which was copied directly from fpxsave_ctxt.

        /*
         * (see notes above about "exception pointers")
         * TODO: does it apply to any machine that uses xsave?
         */
        btw     $7, FXSAVE_STATE_FSW(%rdi)      /* Test saved ES bit */
        jnc     0f                              /* jump if ES = 0 */
        fnclex          /* clear pending x87 exceptions */
0:      ffree   %st(7)  /* clear tag bit to remove possible stack overflow */
        fildl   .fpzero_const(%rip)
                        /* dummy load changes all exception pointers */

I did some research and that only applies to the fxsave handling on AMD K7 and K8 CPUs. After more research, it is not completely clear that the AMD behavior around floating-point zero pointer handling is disjoint from any of the save context handling. I'm going to check for that AMD-specific feature and handle that explicitly instead of the current approach where we blindly do this for every save context save.

Actions

Also available in: Atom PDF