[lkml]   [2003]   [Oct]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [x86] Access off the bottom of stack causes a segfault?
    > Any interrupt causes the return address to be pushed onto the
    > stack. This will overwrite any data you've put there. In principle,
    > in user-mode, you can write below the stack-pointer because an
    > interrupt uses the kernel stack. However, your data will still
    > get corrupted by signal delivery, etc. So as to not corrupt your
    > user-mode stack, the kernel calls your signal code, just like
    > a nested call. This means the new return address will be below
    > the non-signal user-mode stack-pointer value. This will surely
    > corrupt anything you have written below the stack-pointer.

    Thanks to everyone for all of the answers. :) I guess the moral of the
    story is to not perform leaf function optimization on X86. At least
    frame-pointer elimination is still safe.

    Thanks again,



    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:49    [W:0.018 / U:12.072 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site