blob: f22716437b8f67029d0116c5dea07cc88d2cb792 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
#include <winpr/crt.h>
#include <winpr/sysinfo.h>
int TestGetNativeSystemInfo(int argc, char* argv[])
{
SYSTEM_INFO sysinfo;
WINPR_UNUSED(argc);
WINPR_UNUSED(argv);
GetNativeSystemInfo(&sysinfo);
printf("SystemInfo:\n");
printf("\twProcessorArchitecture: %" PRIu16 "\n", sysinfo.wProcessorArchitecture);
printf("\twReserved: %" PRIu16 "\n", sysinfo.wReserved);
printf("\tdwPageSize: 0x%08" PRIX32 "\n", sysinfo.dwPageSize);
printf("\tlpMinimumApplicationAddress: %p\n", sysinfo.lpMinimumApplicationAddress);
printf("\tlpMaximumApplicationAddress: %p\n", sysinfo.lpMaximumApplicationAddress);
printf("\tdwActiveProcessorMask: %p\n", (void*)sysinfo.dwActiveProcessorMask);
printf("\tdwNumberOfProcessors: %" PRIu32 "\n", sysinfo.dwNumberOfProcessors);
printf("\tdwProcessorType: %" PRIu32 "\n", sysinfo.dwProcessorType);
printf("\tdwAllocationGranularity: %" PRIu32 "\n", sysinfo.dwAllocationGranularity);
printf("\twProcessorLevel: %" PRIu16 "\n", sysinfo.wProcessorLevel);
printf("\twProcessorRevision: %" PRIu16 "\n", sysinfo.wProcessorRevision);
printf("\n");
return 0;
}
|