diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2010-03-20 20:41:38 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2010-03-20 20:41:38 -0400 |
commit | bca0736f5a6df16d0d98a877d695d406a9be88b7 (patch) | |
tree | 10b87622bea1f2eccbb76b1234bdf9b0f429c456 /src/util.h | |
parent | d7eb27efa3f9265dca8357cfa05d9e0560fd4534 (diff) | |
download | seabios-hppa-bca0736f5a6df16d0d98a877d695d406a9be88b7.zip seabios-hppa-bca0736f5a6df16d0d98a877d695d406a9be88b7.tar.gz seabios-hppa-bca0736f5a6df16d0d98a877d695d406a9be88b7.tar.bz2 |
Force use of indirect function calls in inline assembler.
For indirect calls, place function address in a register and call it.
This is less optimal when gcc can inline the code and the destination
address is known at compile time. However, older gcc compilers don't
do as well with inlining, and they then mess up the code generation.
There doesn't seem to be a way to tell gcc how to emit the code
correctly for both immediate addresses and register addresses, so fall
back to a safe way.
Also, reduce params to stack_hop to avoid register assignment issues.
Diffstat (limited to 'src/util.h')
-rw-r--r-- | src/util.h | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -204,7 +204,7 @@ void biosusleep(u32 usec); int get_keystroke(int msec); // stacks.c -inline u32 stack_hop(u32 eax, u32 edx, u32 ecx, void *func); +inline u32 stack_hop(u32 eax, u32 edx, void *func); extern struct thread_info MainThread; void thread_setup(void); struct thread_info *getCurThread(void); |