Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(516)

Unified Diff: fusl/src/thread/mips/syscall_cp.s

Issue 1573973002: Add a "fork" of musl as //fusl. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fusl/src/thread/mips/clone.s ('k') | fusl/src/thread/mtx_destroy.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fusl/src/thread/mips/syscall_cp.s
diff --git a/fusl/src/thread/mips/syscall_cp.s b/fusl/src/thread/mips/syscall_cp.s
new file mode 100644
index 0000000000000000000000000000000000000000..8f76d40e1ebf2976f4139caaf735f781e098e50a
--- /dev/null
+++ b/fusl/src/thread/mips/syscall_cp.s
@@ -0,0 +1,46 @@
+.set noreorder
+
+.global __cp_begin
+.hidden __cp_begin
+.type __cp_begin,@function
+.global __cp_end
+.hidden __cp_end
+.type __cp_end,@function
+.global __cp_cancel
+.hidden __cp_cancel
+.type __cp_cancel,@function
+.hidden __cancel
+.global __syscall_cp_asm
+.hidden __syscall_cp_asm
+.type __syscall_cp_asm,@function
+__syscall_cp_asm:
+ subu $sp, $sp, 32
+__cp_begin:
+ lw $4, 0($4)
+ bne $4, $0, __cp_cancel
+ move $2, $5
+ move $4, $6
+ move $5, $7
+ lw $6, 48($sp)
+ lw $7, 52($sp)
+ lw $8, 56($sp)
+ lw $9, 60($sp)
+ lw $10,64($sp)
+ sw $8, 16($sp)
+ sw $9, 20($sp)
+ sw $10,24($sp)
+ sw $2, 28($sp)
+ lw $2, 28($sp)
+ syscall
+__cp_end:
+ beq $7, $0, 1f
+ addu $sp, $sp, 32
+ subu $2, $0, $2
+1: jr $ra
+ nop
+
+__cp_cancel:
+ addu $sp, $sp, 32
+ lw $25, %call16(__cancel)($gp)
+ jr $25
+ nop
« no previous file with comments | « fusl/src/thread/mips/clone.s ('k') | fusl/src/thread/mtx_destroy.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698