File tree Expand file tree Collapse file tree 2 files changed +21
-17
lines changed Expand file tree Collapse file tree 2 files changed +21
-17
lines changed Original file line number Diff line number Diff line change @@ -551,19 +551,19 @@ INT_PTR CALLBACK EtpGpuPageDlgProc(
551
551
{
552
552
FLOAT max = 0 ;
553
553
554
- if (EtGpuSharedLimit != 0 )
555
- {
556
- max = (FLOAT )EtGpuSharedLimit / PAGE_SIZE ;
557
- }
554
+ // if (EtGpuSharedLimit != 0)
555
+ // {
556
+ // max = (FLOAT)EtGpuSharedLimit / PAGE_SIZE;
557
+ // }
558
558
559
559
for (ULONG i = 0 ; i < drawInfo -> LineDataCount ; i ++ )
560
560
{
561
- FLOAT data1 ;
561
+ FLOAT data ;
562
562
563
- context -> MemorySharedGraphState .Data1 [i ] = data1 = (FLOAT )PhGetItemCircularBuffer_ULONG (& context -> Block -> MemorySharedHistory , i );
563
+ context -> MemorySharedGraphState .Data1 [i ] = data = (FLOAT )PhGetItemCircularBuffer_ULONG (& context -> Block -> MemorySharedHistory , i );
564
564
565
- if (max < data1 )
566
- max = data1 ;
565
+ if (max < data )
566
+ max = data ;
567
567
}
568
568
569
569
if (max != 0 )
Original file line number Diff line number Diff line change @@ -694,7 +694,6 @@ VOID EtpNotifyGpuGraph(
694
694
drawInfo -> LabelYFunctionParameter = max ;
695
695
}
696
696
697
-
698
697
GpuGraphState .Valid = TRUE;
699
698
}
700
699
}
@@ -841,19 +840,24 @@ VOID EtpNotifySharedGraph(
841
840
842
841
if (!SharedGraphState .Valid )
843
842
{
843
+ FLOAT max = 0 ;
844
+
845
+ //if (EtGpuSharedLimit != 0)
846
+ //{
847
+ // max = (FLOAT)EtGpuSharedLimit / PAGE_SIZE;
848
+ //}
849
+
844
850
for (i = 0 ; i < drawInfo -> LineDataCount ; i ++ )
845
851
{
846
- SharedGraphState .Data1 [i ] = (FLOAT )PhGetItemCircularBuffer_ULONG64 (& EtGpuSharedHistory , i );
852
+ FLOAT data = SharedGraphState .Data1 [i ] = (FLOAT )PhGetItemCircularBuffer_ULONG64 (& EtGpuSharedHistory , i );
853
+
854
+ if (max < data )
855
+ max = data ;
847
856
}
848
857
849
- if (EtGpuSharedLimit != 0 )
858
+ if (max != 0 )
850
859
{
851
- // Scale the data.
852
- PhDivideSinglesBySingle (
853
- SharedGraphState .Data1 ,
854
- (FLOAT )EtGpuSharedLimit ,
855
- drawInfo -> LineDataCount
856
- );
860
+ PhDivideSinglesBySingle (SharedGraphState .Data1 , max , drawInfo -> LineDataCount );
857
861
}
858
862
859
863
SharedGraphState .Valid = TRUE;
You can’t perform that action at this time.
0 commit comments