Ignore:
Timestamp:
Dec 18, 2011, 10:28:22 PM (14 years ago)
Author:
dmik
Message:

Merge branch gcc-kmk to trunk.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

    • Property svn:ignore
      •  

        old new  
        1 bin
        2 Makefile.inc
         1env.cmd
         2LocalConfig.kmk
    • Property svn:mergeinfo set to
      /branches/gcc-kmkmergedeligible
  • trunk/src/kernel32/cpu.cpp

    r21343 r21916  
    2828
    2929static BYTE PF[64]          = {0,};
    30 static nrCPUs               = 1;
     30static int nrCPUs           = 1;
    3131static SYSTEM_INFO cachedsi = {0};
    3232
     
    5353 * Note that there is a hierarchy for every processor installed, so this
    5454 * supports multiprocessor systems. This is done like Win95 does it, I think.
    55  *                                                     
     55 *
    5656 * It also creates a cached flag array for IsProcessorFeaturePresent().
    5757 *
     
    104104        }
    105105
    106         if(SupportsCPUID()) 
     106        if(SupportsCPUID())
    107107        {
    108             for(int i=0;i<cachedsi.dwNumberOfProcessors;i++) 
     108            for(int i=0;i<cachedsi.dwNumberOfProcessors;i++)
    109109            {
    110110                // Create a new processor subkey
     
    153153
    154154                                        Sleep(32);      //sleep for about 32 ms
    155                                        
     155
    156156                                        GetTSC((LONG *)&tsc2.LowPart, &tsc2.HighPart);
    157157                                        QueryPerformanceCounter(&time2);
     
    167167                                        tmp1 = (double)tsc1.LowPart + (double)tsc1.HighPart*4.0*1024.0*1024.0;
    168168                                        clockticks = tmp - tmp1;
    169                                         if(millisec > 0) 
     169                                        if(millisec > 0)
    170170                                        {//make sure we have something valid here
    171171                                                tmp = 1000 / millisec;
     
    199199                if (features & CPUID_FPU_PRESENT) {
    200200                        if (i == 0) {
    201                                 if(RegCreateKeyA(HKEY_LOCAL_MACHINE,"HARDWARE\\DESCRIPTION\\System\\FloatingPointProcessor",&fpukey)!=ERROR_SUCCESS) 
     201                                if(RegCreateKeyA(HKEY_LOCAL_MACHINE,"HARDWARE\\DESCRIPTION\\System\\FloatingPointProcessor",&fpukey)!=ERROR_SUCCESS)
    202202                                        dprintf(("Unable to register FPU information\n"));
    203203                        }
     
    208208                        }
    209209                }
    210        
     210
    211211           } //for each cpu
    212212        }
Note: See TracChangeset for help on using the changeset viewer.