1
0
Fork 0

improve the assembly documentation

This commit is contained in:
edef 2015-04-16 00:22:50 -04:00
parent d25f43d4d5
commit 46b2a4007b
2 changed files with 12 additions and 7 deletions

View File

@ -1,11 +1,15 @@
// Copyright (c) 2015, edef <edef@edef.eu> // Copyright (c) 2015, edef <edef@edef.eu>
// See LICENSE file that comes with this distribution. // See LICENSE file that comes with this distribution.
/// initialise a new context //! initialise a new context
/// arguments: rdi: stack pointer, //! arguments:
/// rsi: function pointer, //! * rdi: stack pointer
/// rdx, data pointer //! * rsi: function pointer
/// rcx, stack limit //! * rdx: data pointer
//! * rcx: stack limit
//!
//! return values:
//! * rdi: new stack pointer
// switch to the fresh stack // switch to the fresh stack
xchg %rsp, %rdi xchg %rsp, %rdi

View File

@ -1,8 +1,9 @@
// Copyright (c) 2015, edef <edef@edef.eu> // Copyright (c) 2015, edef <edef@edef.eu>
// See LICENSE file that comes with this distribution. // See LICENSE file that comes with this distribution.
/// switch to a new context //! switch to a new context
/// arguments: rdi: stack pointer pointer //! arguments:
//! * rdi: stack pointer pointer
// make sure we leave the red zone alone // make sure we leave the red zone alone
sub $$128, %rsp sub $$128, %rsp