[lkml]   [2017]   [Aug]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC PATCH 4/4] x86/asm: Use ASM_CALL() macro for inline asm statements with call instructions
On Thu, Aug 31, 2017 at 09:11:20AM -0500, Josh Poimboeuf wrote:
> Inline asm statements which have call instructions can be problematic.
> GCC doesn't know about the call instructions, so in some cases it can
> insert the asm before setting up the frame pointer. This can result in
> bad stack traces when unwinding from the called function.
> Previously we worked around this issue by listing the stack pointer as
> an input/output constraint for the inline asm. That works for GCC, but
> unfortunately it doesn't work for Clang. In fact, it causes Clang to
> corrupt the stack pointer.

Sounds like it ought to get fixed regardless and then it might as well
do the right thing ;-)

 \ /
  Last update: 2017-08-31 16:51    [W:0.049 / U:3.188 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site