Ich habe hier mal das Test-Script hinzugefügt und auch die Zeiten, die _GUICtrlListView_AddArray bei mir benötigt, sowie Infos zu Betriebssystemen , RAM und CPUs als Kommentar.
Treiber sind auf beiden Systemen auf den neusten Stand.
Woran kann es liegen, das der Quad-Core so lahm damit ist?
C
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Change2CUI=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
;-- TIME_STAMP 2018-12-19 21:51:47
#Region ;************ Includes ************
#Include <WinAPIProc.au3>
#Include <WindowsConstants.au3>
#Include <GuiListView.au3>
#include <GUIConstantsEx.au3>
#include <Date.au3>
#include <WinAPIMem.au3>
#EndRegion ;************ Includes ************
Global $g_hTimer, $g_sTime, $g_iHours, $g_iMins, $g_iSecs, $g_iMiliSecs, $g_iMicroSecs, $g_dTicks
_GUICtrlListView_AddArray_Demo()
Func _GUICtrlListView_AddArray_Demo()
Local $sTotalTime = _NowCalc()
_WinAPI_SetPriorityClass($HIGH_PRIORITY_CLASS)
#Region - GUI Create
Local $hGUI = GUICreate('GUICtrlCreateListView', 400, 300, 400, -1, BitOR($GUI_SS_DEFAULT_GUI, $WS_MAXIMIZEBOX, $WS_SIZEBOX), $WS_EX_WINDOWEDGE)
Local $idLV = GUICtrlCreateListView('Name|Status1|Status2|Status3|Status4|Status5|Status6|Status7|Status8|Status9|Status10|Status11|Status12|Status13|Status14|Status15|Status16|Status17|Status18|Status19|Status20|Status21|Status22|Status23|Status24|Status25|Status26|Status27|Status28|Status29|Status30|Status31', 2, 2, 396, 296)
;~ GUISetState(@SW_MAXIMIZE)
GUISetState()
#EndRegion - GUI Create
;~ Local $sStartTime = _NowCalc()
Local $aLV[1600][32], $sAdd
For $i = 0 To UBound($aLV) - 1 Step 1
$aLV[$i][0] = 'Name' & $i + 1
For $j = 1 To UBound($aLV, 2) - 1 Step 1
$aLV[$i][$j] = 'Status' & $j
Next
Next
Local $iWidth = 109
Local $aWJLV = [[$iWidth, 0], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2], [$iWidth, 2]]
For $i = 0 To UBound($aWJLV) - 1 Step 1
_GUICtrlListView_SetColumnWidth($idLV, $i, $aWJLV[$i][0])
_GUICtrlListView_JustifyColumn($idLV, $i, $aWJLV[$i][1]) ; 0 left, 1 right, 2 center
Next
ConsoleWrite('! Benoetigte Zeit, um das Listview mit _GUICtrlListView_AddArray zu befuellen ($aLV[1600][32]): ')
$g_hTimer = TimerInit()
_GUICtrlListView_AddArray($idLV, $aLV)
_GetTime($g_hTimer)
ConsoleWrite($g_sTime & @CRLF)
_GetGlobalMemoryStatus()
_GetCPUInfo()
#Region - GUI SwitchLoop
While True
Switch GUIGetMsg()
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
#EndRegion - GUI SwitchLoop
EndFunc ;==>_GUICtrlListView_AddArray_Demo
Func _GetTime($hTimer = $g_hTimer)
$g_dTicks = TimerDiff($hTimer)
$g_iMicroSecs = StringRegExpReplace($g_dTicks, '.+\.(.+)', '\1')
$g_iMiliSecs = Int(Mod($g_dTicks, 1000))
_TicksToTime(Int($g_dTicks), $g_iHours, $g_iMins, $g_iSecs)
$g_sTime = StringFormat("%02i:%02i:%02i:%03i:%05i", $g_iHours, $g_iMins, $g_iSecs, $g_iMiliSecs, $g_iMicroSecs)
EndFunc ;==>_GetTime
Func _GetGlobalMemoryStatus()
Local $aMem = _WinAPI_GlobalMemoryStatus()
_ArrayColInsert($aMem, 0)
$aMem[0][0] = 'Percent of Mem in use : '
$aMem[1][0] = 'Physical Mem: Total : '
$aMem[2][0] = 'Physical Mem: Free : '
$aMem[3][0] = 'Paging file: Total : '
$aMem[4][0] = 'Paging file: Free : '
$aMem[5][0] = 'User Mem: Total : '
$aMem[6][0] = 'User Mem: Free : '
ConsoleWrite(@CRLF & '! MemoryStatus' & @CRLF & _ArrayToString($aMem, '') & @CRLF)
EndFunc
Func _GetCPUInfo()
Local $iPID = Run('wmic cpu get /Format:List', '', @SW_HIDE, $STDOUT_CHILD)
If $iPID Then
ProcessWaitClose($iPID)
Local $sOutput = StringRegExpReplace(StdoutRead($iPID), '(\R)+', @CRLF)
ConsoleWrite(@CRLF & '>wmic cpu get /Format:List' & @CRLF & @CRLF & $sOutput & @CRLF)
EndIf
EndFunc
#cs
WIN_10 X64 WIN_7 X64
Benötigte Zeit _GUICtrlListView_AddArray ($aLV[1600][32])
00:00:07:341:03117 00:00:00:930:2147483647
MemoryStatus
Percent of Mem in use : 60 Percent of Mem in use : 36
Physical Mem: Total : 6432137216 Physical Mem: Total : 8454860800
Physical Mem: Free : 2527944704 Physical Mem: Free : 5352329216
Paging file: Total : 7841423360 Paging file: Total : 16907776000
Paging file: Free : 1641803776 Paging file: Free : 13577187328
User Mem: Total : 4294836224 User Mem: Total : 4294836224
User Mem: Free : 4103241728 User Mem: Free : 4164423680
CPU-Info
>wmic cpu get /Format:List
AddressWidth=64 AddressWidth=64
Architecture=9 Architecture=9
AssetTag=To Be Filled By O.E.M. Availability=3
Availability=3 Caption=AMD64 Family 16 Model 6 Stepping 3
Caption=Intel64 Family 6 Model 26 Stepping 5 ConfigManagerErrorCode=
Characteristics= ConfigManagerUserConfig=
ConfigManagerErrorCode= CpuStatus=1
ConfigManagerUserConfig= CreationClassName=Win32_Processor
CpuStatus=1 CurrentClockSpeed=2200
CreationClassName=Win32_Processor CurrentVoltage=11
CurrentClockSpeed=2668 DataWidth=64
CurrentVoltage= Description=AMD64 Family 16 Model 6 Stepping 3
DataWidth=64 DeviceID=CPU0
Description=Intel64 Family 6 Model 26 Stepping 5 ErrorCleared=
DeviceID=CPU0 ErrorDescription=
ErrorCleared= ExtClock=200
ErrorDescription= Family=1
ExtClock=133 InstallDate=
Family=198 L2CacheSize=2048
InstallDate= L2CacheSpeed=
L2CacheSize=1024 L3CacheSize=0
L2CacheSpeed= L3CacheSpeed=0
L3CacheSize=8192 LastErrorCode=
L3CacheSpeed=0 Level=16
LastErrorCode= LoadPercentage=4
Level=6 Manufacturer=AuthenticAMD
LoadPercentage=24 MaxClockSpeed=2200
Manufacturer=GenuineIntel Name=AMD Turion(tm) II Neo N54L Dual-Core Processor
MaxClockSpeed=2668 NumberOfCores=2
Name=Intel(R) Core(TM) i7 CPU 920 @ 2.67GHz NumberOfLogicalProcessors=2
NumberOfCores=4 OtherFamilyDescription=
NumberOfEnabledCore=4 PNPDeviceID=
NumberOfLogicalProcessors=8 PowerManagementCapabilities=
OtherFamilyDescription= PowerManagementSupported=FALSE
PartNumber=To Be Filled By O.E.M. ProcessorId=178BFBFF00100F63
PNPDeviceID= ProcessorType=3
PowerManagementCapabilities= Revision=1539
PowerManagementSupported=FALSE Role=CPU
ProcessorId=BFEBFBFF000106A5 SocketDesignation=CPU 1
ProcessorType=3 Status=OK
Revision=6661 StatusInfo=3
Role=CPU Stepping=3
SecondLevelAddressTranslationExtensions=TRUE SystemCreationClassName=Win32_ComputerSystem
SerialNumber=To Be Filled By O.E.M. SystemName=SERVER
SocketDesignation=CPU 1 UniqueId=
Status=OK UpgradeMethod=1
StatusInfo=3 Version=Modell 6, Stepping 3
Stepping= VoltageCaps=
SystemCreationClassName=Win32_ComputerSystem
SystemName=ILLUMINATI
ThreadCount=8
UniqueId=
UpgradeMethod=1
Version=
VirtualizationFirmwareEnabled=TRUE
VMMonitorModeExtensions=TRUE
VoltageCaps=0
#ce
Alles anzeigen