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 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
|
puts "========"
puts "OCC25514"
puts "========"
puts ""
#########################################################################################
# TKernel, OSD_Timer - do not accumulate error in timer within queries in running state
#########################################################################################
# Set number of cycle iteration
set IterationCount 10000
set iCounter 1
# Set rank of timer's value
set TimeRank 2
# Start timers
dchrono bug_info_1 reset
dchrono bug_info_2 reset
dchrono bug_info_1 start
dchrono bug_info_2 start
# Operation cycle (show only one timer state)
while {$iCounter != $IterationCount} {
dchrono bug_info_1 show
set iCounter [expr {$iCounter + 1}]
}
# Stop timers
dchrono bug_info_1 stop
dchrono bug_info_2 stop
# Get timers value
set Timer_1 [dchrono bug_info_1 show]
set Timer_2 [dchrono bug_info_2 show]
# Modify timers value for comparison
set TimerValue_1 [lindex $Timer_1 6]
set TimerValue_1 [string range $TimerValue_1 0 [expr {[string first "." $TimerValue_1] + $TimeRank}]]
set TimerValue_2 [lindex $Timer_2 6]
set TimerValue_2 [string range $TimerValue_2 0 [expr {[string first "." $TimerValue_2] + $TimeRank}]]
# Comparison of timer's values
puts "Compare: [lindex $Timer_1 6] vs [lindex $Timer_2 6]"
if {$TimerValue_1 != $TimerValue_2} {
puts "ERROR: OCC25514 is reproduced."
} else {
puts "OK"
}
|