According the the documentation:
os.times()
Return a 5-tuple of floating point numbers indicating accumulated (processor or other) times, in seconds. The items are: user time, system time, children’s user time, children’s system time, and elapsed real time since a fixed point in the past, in that order. See the Unix manual page times(2) or the corresponding Windows Platform API documentation. On Windows, only the first two items are filled, the others are zero.
The 2nd floating point in the tuple is the system time
and according to this page system time
== clock_t tms_stime
The tms_stime
field contains the CPU time spent in the system while executing tasks on behalf of the calling process.
According to the WIKI on System Time the value returned by python is measured in μs
. 1 μs == One millionth of one second
So those numbers even though they are growing should never really effect system performance.
Also windows might be returning 1 ms
or 100 ns
values according to the WIKI. 1 ns == One billionth of one second
1 ms = One thousandth of one second
. Also numbers that are too small to really make a difference.
UPDATE:
After some testing I can see that the increase in the system time
per operation is happening for tkinter widgets being update. I did try both labels and entry fields. I did confirm that the values being displayed for system time
is the amount of time taken to process the method. I tested printing os.times()
only to see if the system time
would have the same growth as with updating a label and it does not.
I will keep looking to see what I can find.
I would think that if the same amount of lines of code is being called on each loop of the function then the same amount of processing time should be recorded. Maybe with a slight variation due to system response time but I should not see a slow and consistent growth of this response time.
It seams to only be happening while updating a tkinter widget like Entry
, Label
and Text
. When I am just printing these values to the console the system time
never goes up.