3
$\begingroup$

In Software Performance and Scalability: A Quantitative Approach - Henry H. Liu, the author is presenting a scenario where the hardware becomes a bottleneck. In one ot the tests, he is checking the number disk (read/write) operations. In particular, the number of disk writes as the number of threads increases (see figure below).

enter image description here

After this, he states that: "A rule of thumb is that a resource is a bottleneck when the queue length associated with it is over 2 per unit. Since the RAID 0 configuration used for this test had four disks, the threshold would be 8. This threshold of 8 had been exceeded with a write average queue length of 20 with 4 threads. With 16 threads, the associated average write queue length even went up to 132, which was over 16 times the threshold value of 8. It is clear that the system was disk write bottlenecked."

My question is: Why a resource is a bottleneck when its queue length is over 2? Why is not over 1? why is not over 1000000? why 2?

$\endgroup$
2
$\begingroup$

He explicitly says it's a rule of thumb. That means it's not a hard-and-fast rule; it is just a guideline that is often helpful (but no guarantees). While I'm not familiar with that textbook, I suspect that justifying this rule of thumb would likely require concepts that are beyond the scope of that book.

If you want to understand where it is coming from, one approach is to try some simulations and see what happens. That will give you a rough feeling for it.

If you want to understand the mathematics behind it, your next step is to study queuing theory. There is a relationship between the average queue length and the average utilization of a resource. When queues get large, that tends to mean that the arrival rate is close to or exceeds the departure rate, and means that the resource is highly utilized. In the kind of setting talked about in the book, this in turn means that the resource is a good candidate to be a bottleneck.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.