@@ -401,16 +401,15 @@ class TRealBlockDevice : public IBlockDevice {
401
401
}
402
402
EndOffset = op->GetOffset () + opSize;
403
403
404
- ui64 duration = HPNow () - completionAction->SubmitTime ;
405
- ui64 durationMs = HPMilliSecondsFloat (duration);
404
+ double duration = HPMilliSecondsFloat (HPNow () - completionAction->SubmitTime );
406
405
if (op->GetType () == IAsyncIoOperation::EType::PRead) {
407
406
NSan::Unpoison (op->GetData (), opSize);
408
407
REQUEST_VALGRIND_MAKE_MEM_DEFINED (op->GetData (), opSize);
409
- Device.Mon.DeviceReadDuration.Increment(durationMs );
410
- LWPROBE (PDiskDeviceReadDuration, Device.GetPDiskId(), HPMilliSecondsFloat( duration) , opSize);
408
+ Device.Mon.DeviceReadDuration.Increment(duration );
409
+ LWPROBE (PDiskDeviceReadDuration, Device.GetPDiskId(), duration, opSize);
411
410
} else {
412
- Device.Mon .DeviceWriteDuration .Increment (durationMs );
413
- LWPROBE (PDiskDeviceWriteDuration, Device.GetPDiskId (), HPMilliSecondsFloat ( duration) , opSize);
411
+ Device.Mon .DeviceWriteDuration .Increment (duration );
412
+ LWPROBE (PDiskDeviceWriteDuration, Device.GetPDiskId (), duration, opSize);
414
413
}
415
414
if (completionAction->FlushAction) {
416
415
ui64 idx = completionAction->FlushAction ->OperationIdx ;
@@ -668,8 +667,8 @@ class TRealBlockDevice : public IBlockDevice {
668
667
Device.IsTrimEnabled = Device.IoContext ->DoTrim (op);
669
668
NHPTimer::STime endTime = HPNow ();
670
669
Device.IdleCounter .Decrement ();
671
- const ui64 durationUs = HPMicroSeconds (endTime - beginTime);
672
- Device.Mon .DeviceTrimDuration .Increment (durationUs );
670
+ const double duration = HPMilliSecondsFloat (endTime - beginTime);
671
+ Device.Mon .DeviceTrimDuration .Increment (duration );
673
672
*Device.Mon .DeviceEstimatedCostNs += completion->CostNs ;
674
673
if (Device.ActorSystem && Device.IsTrimEnabled ) {
675
674
LOG_DEBUG_S (*Device.ActorSystem , NKikimrServices::BS_DEVICE,
@@ -680,7 +679,7 @@ class TRealBlockDevice : public IBlockDevice {
680
679
<< " \" offset# " << op->GetOffset ()
681
680
<< " size# " << op->GetSize ());
682
681
LWPROBE (PDiskDeviceTrimDuration, Device.GetPDiskId (),
683
- HPMilliSecondsFloat (endTime - beginTime) , op->GetOffset ());
682
+ duration , op->GetOffset ());
684
683
}
685
684
}
686
685
completion->SetResult (EIoResult::Ok);
0 commit comments