Update some assembler directives for darwin target (#395)

This commit is contained in:
jmpews(AKA.zz) 2020-09-23 13:10:26 +08:00 committed by GitHub
parent dc4b8c4822
commit d8d367b367
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 40 additions and 15 deletions

View File

@ -4,8 +4,14 @@
*/
.text
.align 2
.global invokeNative
.type invokeNative,function
#ifndef BH_PLATFORM_DARWIN
.globl invokeNative
.type invokeNative, @function
invokeNative:
#else
.globl _invokeNative
_invokeNative:
#endif /* end of BH_PLATFORM_DARWIN */
/*
* Arguments passed in:
@ -15,7 +21,6 @@
* x2 nstacks
*/
invokeNative:
sub sp, sp, #0x30
stp x19, x20, [sp, #0x20] /* save the registers */
stp x21, x22, [sp, #0x10]

View File

@ -4,8 +4,14 @@
*/
.text
.align 2
.global invokeNative
.type invokeNative,function
#ifndef BH_PLATFORM_DARWIN
.globl invokeNative
.type invokeNative, @function
invokeNative:
#else
.globl _invokeNative
_invokeNative:
#endif /* end of BH_PLATFORM_DARWIN */
/*
* Arguments passed in:
@ -15,7 +21,6 @@
* r2 argc
*/
invokeNative:
stmfd sp!, {r4, r5, r6, r7, lr}
sub sp, sp, #4 /* make sp 8 byte aligned */
mov ip, r0 /* ip = function ptr */

View File

@ -4,8 +4,14 @@
*/
.text
.align 2
.global invokeNative
.type invokeNative,function
#ifndef BH_PLATFORM_DARWIN
.globl invokeNative
.type invokeNative, @function
invokeNative:
#else
.globl _invokeNative
_invokeNative:
#endif /* end of BH_PLATFORM_DARWIN */
/*
* Arguments passed in:
@ -15,7 +21,6 @@
* r2 nstacks
*/
invokeNative:
stmfd sp!, {r4, r5, r6, r7, lr}
mov ip, r0 /* ip = function ptr */
mov r4, r1 /* r4 = argv */

View File

@ -4,8 +4,14 @@
*/
.text
.align 2
.global invokeNative
.type invokeNative,function
#ifndef BH_PLATFORM_DARWIN
.globl invokeNative
.type invokeNative, @function
invokeNative:
#else
.globl _invokeNative
_invokeNative:
#endif /* end of BH_PLATFORM_DARWIN */
/*
* Arguments passed in:
@ -15,7 +21,6 @@
* r2 argc
*/
invokeNative:
push {r4, r5, r6, r7}
push {lr}
mov ip, r0 /* ip = function ptr */

View File

@ -4,8 +4,14 @@
*/
.text
.align 2
.global invokeNative
.type invokeNative,function
#ifndef BH_PLATFORM_DARWIN
.globl invokeNative
.type invokeNative, @function
invokeNative:
#else
.globl _invokeNative
_invokeNative:
#endif /* end of BH_PLATFORM_DARWIN */
/*
* Arguments passed in:
@ -15,7 +21,6 @@
* r2 nstacks
*/
invokeNative:
push {r4, r5, r6, r7}
push {lr}
mov ip, r0 /* ip = function ptr */