Optimisation of assembler code for Windows x64 within prologue and epilogue 
code is pretty heavily constrained by the calling conventions so some of 
your changes between versions don't carry across to Windows.
 
In particular, unless a frame pointer is declared, the stack pointer must 
remain static in the function body (declaring a frame pointer is a pain so I 
try to avoid it) and register restore operations in any epiiogue code can 
only use pop instructions (i.e. mov instructions are not allowed)
 
There is an option in prologue code to use mov rather than push instructions 
(provided what is done can be undone by pop's in the epilogue). But at the 
moment I only use push operations for register saves in WIndows prologues so 
I ignore your mov based alternatives.  If there a clear rationale for whiich 
approach is better I could adopt a mov based approaach but I am wondering if 
this would make much difference in practice?
 
I also have to save rsi and rdi on entry as these are non-volatile on 
Windows so there may be further differences that interfere with any lead in 
optimisation that you are doing.
 
    Brian
 

-- 
You received this message because you are subscribed to the Google Groups 
"mpir-devel" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/mpir-devel/-/kISHWRz_ThoJ.
To post to this group, send email to mpir-devel@googlegroups.com.
To unsubscribe from this group, send email to 
mpir-devel+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/mpir-devel?hl=en.

Reply via email to