Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
ff77ba8e
Commit
ff77ba8e
authored
May 31, 2008
by
Simon Richter
Committed by
Alexandre Julliard
Jun 02, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libwine: Implement wine_call_on_stack for ppc.
parent
238e1868
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
0 deletions
+17
-0
port.c
libs/wine/port.c
+17
-0
No files found.
libs/wine/port.c
View file @
ff77ba8e
...
...
@@ -179,6 +179,23 @@ __ASM_GLOBAL_FUNC( wine_call_on_stack,
"popq %rbx
\n\t
"
"popq %rbp
\n\t
"
"ret"
)
#elif defined(__powerpc__) && defined(__GNUC__)
__ASM_GLOBAL_FUNC
(
wine_call_on_stack
,
"mflr 0
\n\t
"
/* get return address */
"stw 0, 4(1)
\n\t
"
/* save return address */
"subi 5, 5, 16
\n\t
"
/* reserve space on new stack */
"stw 1, 12(5)
\n\t
"
/* store old sp */
"mtctr 3
\n\t
"
/* func -> ctr */
"mr 3,4
\n\t
"
/* args -> function param 1 (r3) */
"mr 1,5
\n\t
"
/* stack */
"li 0, 0
\n\t
"
/* zero */
"stw 0, 0(1)
\n\t
"
/* bottom of stack */
"stwu 1, -16(1)
\n\t
"
/* create a frame for this function */
"bctrl
\n\t
"
/* call ctr */
"lwz 1, 28(1)
\n\t
"
/* fetch old sp */
"lwz 0, 4(1)
\n\t
"
/* fetch return address */
"mtlr 0
\n\t
"
/* return address -> lr */
"blr"
)
/* return */
#else
#error You must implement wine_switch_to_stack for your platform
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment