[cvs] / xvidcore / src / portab.h Repository:
ViewVC logotype

Diff of /xvidcore/src/portab.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.55, Wed Apr 26 17:44:29 2006 UTC revision 1.58.2.1, Sun Nov 30 16:38:31 2008 UTC
# Line 75  Line 75 
75  #    define CACHE_LINE 64  #    define CACHE_LINE 64
76  #    define ptr_t uint32_t  #    define ptr_t uint32_t
77  #    define intptr_t int32_t  #    define intptr_t int32_t
78    #    define _INTPTR_T_DEFINED
79  #    if defined(_MSC_VER) && _MSC_VER >= 1300 && !defined(__INTEL_COMPILER)  #    if defined(_MSC_VER) && _MSC_VER >= 1300 && !defined(__INTEL_COMPILER)
80  #        include <stdarg.h>  #        include <stdarg.h>
81  #    else  #    else
# Line 84  Line 85 
85  #    define CACHE_LINE  64  #    define CACHE_LINE  64
86  #    define ptr_t uint64_t  #    define ptr_t uint64_t
87  #    define intptr_t int64_t  #    define intptr_t int64_t
88    #    define _INTPTR_T_DEFINED
89  #    if defined (_MSC_VER) && _MSC_VER >= 1300 && !defined(__INTEL_COMPILER)  #    if defined (_MSC_VER) && _MSC_VER >= 1300 && !defined(__INTEL_COMPILER)
90  #        include <stdarg.h>  #        include <stdarg.h>
91  #    else  #    else
# Line 130  Line 132 
132                  va_start(args, fmt);                  va_start(args, fmt);
133                  vsprintf(buf, fmt, args);                  vsprintf(buf, fmt, args);
134                  va_end(args);                  va_end(args);
135                  OutputDebugString(buf);                  OutputDebugStringA(buf);
136                  fprintf(stderr, "%s", buf);                  fprintf(stderr, "%s", buf);
137          }          }
138  }  }
# Line 151  Line 153 
153  /*----------------------------------------------------------------------------  /*----------------------------------------------------------------------------
154    | msvc x86 specific macros/functions    | msvc x86 specific macros/functions
155   *---------------------------------------------------------------------------*/   *---------------------------------------------------------------------------*/
156  #    if defined(ARCH_IS_IA32) || defined(ARCH_IS_X86_64)  #    if defined(ARCH_IS_IA32)
157  #        define BSWAP(a) __asm mov eax,a __asm bswap eax __asm mov a, eax  #        define BSWAP(a) __asm mov eax,a __asm bswap eax __asm mov a, eax
158    
159  static __inline int64_t read_counter(void)  static __inline int64_t read_counter(void)
# Line 167  Line 169 
169          return ts;          return ts;
170  }  }
171    
172    #    elif defined(ARCH_IS_X86_64)
173    
174    #    include <intrin.h>
175    
176    #    define BSWAP(a) ((a) = _byteswap_ulong(a))
177    
178    static __inline int64_t read_counter(void) { return __rdtsc(); }
179    
180  /*----------------------------------------------------------------------------  /*----------------------------------------------------------------------------
181    | msvc GENERIC (plain C only) - Probably alpha or some embedded device    | msvc GENERIC (plain C only) - Probably alpha or some embedded device
182   *---------------------------------------------------------------------------*/   *---------------------------------------------------------------------------*/
# Line 358  Line 368 
368  /*----------------------------------------------------------------------------  /*----------------------------------------------------------------------------
369    | watcom ia32 specific macros/functions    | watcom ia32 specific macros/functions
370   *---------------------------------------------------------------------------*/   *---------------------------------------------------------------------------*/
371  #    if defined(ARCH_IS_IA32)  #    if defined(ARCH_IS_IA32) || defined(ARCH_IS_X86_64)
372    
373  #        define BSWAP(a)  __asm mov eax,a __asm bswap eax __asm mov a, eax  #        define BSWAP(a)  __asm mov eax,a __asm bswap eax __asm mov a, eax
374    

Legend:
Removed from v.1.55  
changed lines
  Added in v.1.58.2.1

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4