Also set __stkptr inside cprt0.as and dllprt0.as startup assembly sources

git-svn-id: trunk@48223 -
This commit is contained in:
pierre 2021-01-19 22:30:59 +00:00
parent 83a1f5fbc3
commit 0055023394
2 changed files with 2 additions and 0 deletions

View File

@ -38,6 +38,7 @@ __entry:
lea.l 8(%sp,%d0.l*4),%a0
move.l %a0,operatingsystem_parameter_envp
move.l %sp,%a0 /* argv */
move.l %sp,__stkptr
pea (%sp) /* highest available stack address */
pea (%a1) /* termination function provided by kernel */

View File

@ -24,6 +24,7 @@ _startlib:
# This is a normal C function with args (argc,argv,envp)
FPC_SHARED_LIB_START:
link.w %a6,#0
move.l %sp,__stkptr
move.l 8(%fp),%d0
move.l %d0,operatingsystem_parameter_argc
move.l 12(%fp),%d0