mirror of
https://github.com/clearlinux/graphene.git
synced 2026-09-06 22:01:29 +00:00
[LibOS] Use current_stack() to get current stack pointer
This commit is contained in:
committed by
Michał Kowalczyk
parent
994eb268a7
commit
5181b073b2
@@ -874,8 +874,7 @@ void check_stack_hook (void)
|
||||
{
|
||||
struct shim_thread * cur_thread = get_cur_thread();
|
||||
|
||||
void * rsp;
|
||||
__asm__ volatile ("movq %%rsp, %0" : "=r"(rsp) :: "memory");
|
||||
void* rsp = current_stack();
|
||||
|
||||
if (rsp <= cur_thread->stack_top && rsp > cur_thread->stack) {
|
||||
if ((uintptr_t)rsp - (uintptr_t)cur_thread->stack < PAL_CB(alloc_align))
|
||||
|
||||
Reference in New Issue
Block a user