[llvm-dev] I am trying to implement a c runtime in rust for msvc/windows.

Gleb Popov via llvm-dev llvm-dev at lists.llvm.org
Sat Oct 10 12:44:27 PDT 2020


On Sat, Oct 10, 2020 at 11:21 PM 罗勇刚(Yonggang Luo) via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> But I don't know how to implement
> __GSHandlerCheck
> __security_check_cookie
> __security_cookie
>
> when using msvc to compiling debug code.
>
> Who knows how to implement these three functions or possible alternatives.
>

How fortunately I've been passing by and stumbled upon this thread. Here is
my implementation:

uintptr_t __security_cookie = 0xAABBCCDD;

void __fastcall __security_check_cookie(uintptr_t cookie)
{
    if (cookie != __security_cookie)
        __debugbreak();
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20201010/a408b6d4/attachment.html>


More information about the llvm-dev mailing list