Last change
on this file since 444 was
444,
checked in by satin@…, 6 years ago
|
add newlib,libalmos-mkh, restructure shared_syscalls.h and mini-libc
|
File size:
571 bytes
|
Rev | Line | |
---|
[444] | 1 | /* Various stuff for the sparclet processor. |
---|
| 2 | |
---|
| 3 | This file is in the public domain. */ |
---|
| 4 | |
---|
| 5 | #ifndef _MACHINE_SPARCLET_H_ |
---|
| 6 | #define _MACHINE_SPARCLET_H_ |
---|
| 7 | |
---|
| 8 | #ifdef __sparclet__ |
---|
| 9 | |
---|
| 10 | /* sparclet scan instruction */ |
---|
| 11 | |
---|
| 12 | extern __inline__ int |
---|
| 13 | scan (int a, int b) |
---|
| 14 | { |
---|
| 15 | int res; |
---|
| 16 | __asm__ ("scan %1,%2,%0" : "=r" (res) : "r" (a), "r" (b)); |
---|
| 17 | return res; |
---|
| 18 | } |
---|
| 19 | |
---|
| 20 | /* sparclet shuffle instruction */ |
---|
| 21 | |
---|
| 22 | extern __inline__ int |
---|
| 23 | shuffle (int a, int b) |
---|
| 24 | { |
---|
| 25 | int res; |
---|
| 26 | __asm__ ("shuffle %1,%2,%0" : "=r" (res) : "r" (a), "r" (b)); |
---|
| 27 | return res; |
---|
| 28 | } |
---|
| 29 | |
---|
| 30 | #endif /* __sparclet__ */ |
---|
| 31 | |
---|
| 32 | #endif /* _MACHINE_SPARCLET_H_ */ |
---|
Note: See
TracBrowser
for help on using the repository browser.