Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 /*
0003  * arch/alpha/lib/dbg_stackcheck.S
0004  * Contributed by Richard Henderson (rth@tamu.edu)
0005  *
0006  * Verify that we have not overflowed the stack.  Oops if we have.
0007  */
0008 
0009 #include <asm/asm-offsets.h>
0010 
0011     .text
0012     .set noat
0013 
0014     .align 3
0015     .globl _mcount
0016     .ent _mcount
0017 _mcount:
0018     .frame $30, 0, $28, 0
0019     .prologue 0
0020 
0021     lda $0, TASK_SIZE($8)
0022     cmpult  $30, $0, $0
0023     bne $0, 1f
0024     ret ($28)
0025 1:  stq $31, -8($31)    # oops me, damn it.
0026     br  1b
0027 
0028     .end _mcount