JamaicaVM -- User Documentation: The Virtual Machine for Real-time and Embedded Systems | ||
---|---|---|
Prev | Chapter 4. Configuration of the Memory Management | Next |
As we have just seen, the worst-case-execution-time of an allocation depends on the amount of garbage-collection work that has to be performed for the allocation. The configuration of the heap as shown above gives a worst-case number of garbage collection work units that need to be performed for the allocation of one block of memory. To determine the actual time an allocation might take in the worst case, it is additionally required to know the number of blocks that will be allocated and the platform dependent worst-case execution time of one unit of garbage collection work.
For an allocation statement S we get the following equation to calculate the worst-case-execution time:
wcet(S) = numblocks(S) · max_gc_units · wcet_of_gc_unit
Where
wcet(S) is the worst case execution time of the allocation
numblocks(S) gives the number of blocks that need to be allocated
max_gc_units is the maximum number of garbage collection units that need to be performed for the allocation of one block
wcet_of_gc_unit is the platform dependent worst-case-execution-time of a single unit of garbage collection work.