kerneltest/e32test/system/t_condvar.cpp
branchRCL_3
changeset 28 5b5d147c7838
parent 0 a41df078684a
equal deleted inserted replaced
26:c734af59ce98 28:5b5d147c7838
    54 #include <e32svr.h>
    54 #include <e32svr.h>
    55 #include <e32test.h>
    55 #include <e32test.h>
    56 #include <e32ldr.h>
    56 #include <e32ldr.h>
    57 #include <e32def.h>
    57 #include <e32def.h>
    58 #include <e32def_private.h>
    58 #include <e32def_private.h>
       
    59 #include <u32std.h>
    59 
    60 
    60 RTest test(_L("T_CONDVAR"));
    61 RTest test(_L("T_CONDVAR"));
    61 RMutex M1;
    62 RMutex M1;
    62 RMutex M2;
    63 RMutex M2;
    63 RCondVar CV1;
    64 RCondVar CV1;
   525 	return r;
   526 	return r;
   526 	}
   527 	}
   527 
   528 
   528 TInt E32Main()
   529 TInt E32Main()
   529 	{
   530 	{
       
   531 	TInt cpus = UserSvr::HalFunction(EHalGroupKernel, EKernelHalNumLogicalCpus, 0, 0);
       
   532 	if (cpus != 1)
       
   533 		{
       
   534 		test(cpus>1);
       
   535 		// This test will require compatibility mode (and probably other changes)
       
   536 		// to work on SMP - it depends on explicit scheduling order.
       
   537 		test.Printf(_L("T_CONDVAR skipped, does not work on SMP\n"));
       
   538 		return KErrNone;
       
   539 		}	
       
   540 	
   530 	__KHEAP_MARK;
   541 	__KHEAP_MARK;
   531 	__UHEAP_MARK;
   542 	__UHEAP_MARK;
   532 
   543 
   533 	TInt r;
   544 	TInt r;
   534 	RCondVar cvp;
   545 	RCondVar cvp;