[PATCH] D57970: [WinEH] Allocate unique stack slots for xmm CSRs in funclets

Andy Kaylor via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 13 17:47:49 PST 2019

andrew.w.kaylor added a comment.

I haven't had a lot more time to spend on this, but I did do a bit of investigation. I still only have a vague idea of what would be required to implement hard-coded offsets, but it didn't look to me like there is existing infrastructure for this so all of the things that just kind of magically worked with this patch (like growing the stack allocation and writing the .seh_savexmm directive) would need to be explicitly updated, right?

On the other hand, it looked like it might be relatively easy to update the code that writes the savexmm directive to describe the actual location of the stack slot I'm using in the current version of this patch. If I was reading the code correctly, it looks like it's already using the offset between the parent stack pointer and the funclet stack pointer to figure out how to build the instruction that actually stores the register to the stack. So we should be able to do a similar calculation to fill out the savexmm directive correctly. Does that seem worth exploring?




More information about the llvm-commits mailing list