Don't use pop to restore %rdi so that stack is aligned to 16 bytes
when calling __setcontext.
[BZ #18661]
* sysdeps/unix/sysv/linux/x86_64/__start_context.S
(__start_context): Don't use pop to restore %rdi so that stack
is aligned to 16 bytes when calling __setcontext.
+2015-08-05 H.J. Lu <hongjiu.lu@intel.com>
+
+ [BZ #18661]
+ * sysdeps/unix/sysv/linux/x86_64/__start_context.S
+ (__start_context): Don't use pop to restore %rdi so that stack
+ is aligned to 16 bytes when calling __setcontext.
+
2015-08-05 H.J. Lu <hongjiu.lu@intel.com>
* sysdeps/x86_64/multiarch/memcpy-sse2-unaligned.S: Compile
on the stack pointer for the next context. */
movq %rbx, %rsp
- popq %rdi /* This is the next context. */
- cfi_adjust_cfa_offset(-8)
+ /* Don't use pop here so that stack is aligned to 16 bytes. */
+ movq (%rsp), %rdi /* This is the next context. */
testq %rdi, %rdi
je 2f /* If it is zero exit. */