X-Git-Url: https://git.saurik.com/apple/libc.git/blobdiff_plain/59e0d9fe772464b93d835d2a2964457702469a43..0a7506c9bdc0d0d560d4b9c8a3d1089f5db425b9:/pthreads/stack.s?ds=sidebyside diff --git a/pthreads/stack.s b/pthreads/stack.s index 2628266..5be1689 100644 --- a/pthreads/stack.s +++ b/pthreads/stack.s @@ -3,8 +3,6 @@ * * @APPLE_LICENSE_HEADER_START@ * - * Copyright (c) 1999-2003 Apple Computer, Inc. All Rights Reserved. - * * This file contains Original Code and/or Modifications of Original Code * as defined in and that are subject to the Apple Public Source License * Version 2.0 (the 'License'). You may not use this file except in @@ -87,6 +85,25 @@ LEAF(__adjust_sp,0) subl $0x100,%eax ret +#elif defined(__x86_64__) + +#import +/* + * void *_sp(void) + */ + +LEAF(__sp,0) + movq %rsp,%rax + ret + +/* + * void *_adjust_sp(void *sp) + */ +LEAF(__adjust_sp,0) + movq %rdi,%rax + subq $0x100,%rax + ret + #else #error sp functions not defined for this architecture #endif