[svn] / trunk / xvidcore / src / motion / motion_smp.h Repository:
ViewVC logotype

Diff of /trunk/xvidcore/src/motion/motion_smp.h

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

revision 1692, Mon Feb 27 12:16:04 2006 UTC revision 1874, Fri Jun 5 07:58:41 2009 UTC
# Line 22  Line 22 
22   *  along with this program ; if not, write to the Free Software   *  along with this program ; if not, write to the Free Software
23   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA   *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
24   *   *
25   * $Id: motion_smp.h,v 1.4 2006-02-27 12:16:04 suxen_drol Exp $   * $Id: motion_smp.h,v 1.6 2009-06-05 07:58:41 Isibaar Exp $
26   *   *
27   ****************************************************************************/   ****************************************************************************/
28    
# Line 40  Line 40 
40  static __inline int pthread_num_processors_np()  static __inline int pthread_num_processors_np()
41  {  {
42          DWORD p_aff, s_aff, r = 0;          DWORD p_aff, s_aff, r = 0;
43          GetProcessAffinityMask(GetCurrentProcess(), &p_aff, &s_aff);          GetProcessAffinityMask(GetCurrentProcess(), (PDWORD_PTR) &p_aff, (PDWORD_PTR) &s_aff);
44          for(; p_aff != 0; p_aff>>=1) r += p_aff&1;          for(; p_aff != 0; p_aff>>=1) r += p_aff&1;
45          return r;          return r;
46  }  }
47    
48    #elif defined(__amigaos4__)
49    
50    # include <pthread.h>
51    # include <proto/dos.h>
52    # define sched_yield() IDOS->Delay(1)
53    
54  #elif defined(SYS_BEOS)  #elif defined(SYS_BEOS)
55    
56  # include <kernel/OS.h>  # include <kernel/OS.h>

Legend:
Removed from v.1692  
changed lines
  Added in v.1874

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