As we know, when we use "call" instruction, we will create a return address stack buffer in x86&x64 (see http://www.agner.org/optimize/microarchitecture.pdf p.36) for future prediction of function return address) .
But how about the “syscall” instruction? Will it break the previous return stack buffer when it returns via sysret? Can we view it just like a jmp instruction, only from the perspective of return stack buffer?
Thank you for your help!
Oh, this is totally not about calling convention but the (branch predict unit) implement of the "syscall" and "sysret" instruction in x64 CPU. The question is not related to the register status before/after the "syscall".