ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/SheepShaver/src/Unix/sysdeps.h
(Generate patch)

Comparing SheepShaver/src/Unix/sysdeps.h (file contents):
Revision 1.22 by gbeauche, 2004-01-18T22:05:28Z vs.
Revision 1.25 by gbeauche, 2004-02-25T22:02:59Z

# Line 44 | Line 44
44   #include <string.h>
45   #include <signal.h>
46  
47 + #ifdef HAVE_PTHREADS
48 + # include <pthread.h>
49 + #endif
50 +
51   #ifdef HAVE_FCNTL_H
52   # include <fcntl.h>
53   #endif
# Line 139 | Line 143 | typedef int64 intptr;
143   **/
144  
145   #if defined(__GNUC__)
146 < #if defined(__x86_64__)
146 > #if defined(__x86_64__) || defined(__i386__)
147   // Linux/AMD64 currently has no asm optimized bswap_32() in <byteswap.h>
148   #define opt_bswap_32 do_opt_bswap_32
149   static inline uint32 do_opt_bswap_32(uint32 x)
# Line 184 | Line 188 | static inline uint32 generic_bswap_32(ui
188                    ((x & 0x000000ff) << 24) );
189   }
190  
191 + #if defined(__i386__)
192 + #define opt_bswap_64 do_opt_bswap_64
193 + static inline uint64 do_opt_bswap_64(uint64 x)
194 + {
195 +  return (bswap_32(x >> 32) | (((uint64)bswap_32((uint32)x)) << 32));
196 + }
197 + #endif
198 +
199   #ifdef  opt_bswap_64
200   #undef  bswap_64
201   #define bswap_64 opt_bswap_64
# Line 348 | Line 360 | typedef struct timeval tm_time_t;
360   extern uint64 GetTicks_usec(void);
361   extern void Delay_usec(uint32 usec);
362  
363 + #if defined(HAVE_PTHREADS) || (defined(__linux__) && defined(__powerpc__))
364   // Setup pthread attributes
365   extern void Set_pthread_attr(pthread_attr_t *attr, int priority);
366 + #endif
367  
368   // Various definitions
369   typedef struct rgb_color {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines