diff options
author | Rich Felker <dalias@aerifal.cx> | 2016-04-18 05:19:13 +0000 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2016-04-18 05:19:13 +0000 |
commit | 5972c4a4113e2a4de5edf519faf15296ae1eb3ed (patch) | |
tree | 6e808f23bb96a9b8a82eb505e2a719f4f42a758d /src/setjmp | |
parent | 6d99ad91e869aab35a4d76d34c3c9eaf29482bad (diff) | |
download | musl-5972c4a4113e2a4de5edf519faf15296ae1eb3ed.tar.gz musl-5972c4a4113e2a4de5edf519faf15296ae1eb3ed.tar.bz2 musl-5972c4a4113e2a4de5edf519faf15296ae1eb3ed.tar.xz musl-5972c4a4113e2a4de5edf519faf15296ae1eb3ed.zip |
add mips n32 port (ILP32 ABI for mips64)
based on patch submitted by Jaydeep Patil, with minor changes.
Diffstat (limited to 'src/setjmp')
-rw-r--r-- | src/setjmp/mipsn32/longjmp.S | 36 | ||||
-rw-r--r-- | src/setjmp/mipsn32/setjmp.S | 34 |
2 files changed, 70 insertions, 0 deletions
diff --git a/src/setjmp/mipsn32/longjmp.S b/src/setjmp/mipsn32/longjmp.S new file mode 100644 index 00000000..30c3ee0b --- /dev/null +++ b/src/setjmp/mipsn32/longjmp.S @@ -0,0 +1,36 @@ +.set noreorder +.global _longjmp +.global longjmp +.type _longjmp,@function +.type longjmp,@function +_longjmp: +longjmp: + move $2, $5 + bne $2, $0, 1f + nop + addu $2, $2, 1 +1: +#ifndef __mips_soft_float + ldc1 $24, 96($4) + ldc1 $25, 104($4) + ldc1 $26, 112($4) + ldc1 $27, 120($4) + ldc1 $28, 128($4) + ldc1 $29, 136($4) + ldc1 $30, 144($4) + ldc1 $31, 152($4) +#endif + ld $ra, 0($4) + ld $sp, 8($4) + ld $gp, 16($4) + ld $16, 24($4) + ld $17, 32($4) + ld $18, 40($4) + ld $19, 48($4) + ld $20, 56($4) + ld $21, 64($4) + ld $22, 72($4) + ld $23, 80($4) + ld $30, 88($4) + jr $ra + nop diff --git a/src/setjmp/mipsn32/setjmp.S b/src/setjmp/mipsn32/setjmp.S new file mode 100644 index 00000000..b9646c2a --- /dev/null +++ b/src/setjmp/mipsn32/setjmp.S @@ -0,0 +1,34 @@ +.set noreorder +.global __setjmp +.global _setjmp +.global setjmp +.type __setjmp,@function +.type _setjmp,@function +.type setjmp,@function +__setjmp: +_setjmp: +setjmp: + sd $ra, 0($4) + sd $sp, 8($4) + sd $gp, 16($4) + sd $16, 24($4) + sd $17, 32($4) + sd $18, 40($4) + sd $19, 48($4) + sd $20, 56($4) + sd $21, 64($4) + sd $22, 72($4) + sd $23, 80($4) + sd $30, 88($4) +#ifndef __mips_soft_float + sdc1 $24, 96($4) + sdc1 $25, 104($4) + sdc1 $26, 112($4) + sdc1 $27, 120($4) + sdc1 $28, 128($4) + sdc1 $29, 136($4) + sdc1 $30, 144($4) + sdc1 $31, 152($4) +#endif + jr $ra + li $2, 0 |