OK, I'm building a drum machine, and I looked to an old Exonerate model that looked like it was the basis for both of some of our ideas and I played with it till it uses less CPU and does not stack on CPU indefinitely.
Yours, if you keep doing piano crescendos will keep building in CPU cost and halt there, this one; albeit with one sample does not. And that is why I am feeling that it would be more sensible to separate zones by the zone applied.
One zone per sample right? Crescendos are common, and even in the case of drum machine programming; it's common to expect that there is rising CPU, but in this model, it recedes back to 0. Maybe separating zones is best, but that would also to be to suggest that there would be a maximum amount of zones. I guess I could do some research and ask at KVR what the max amount is and usually is.
If not used they could be disabled and dormant, I mean; maybe it's the best way and I wondered your thoughts. I'll continue adding to this and add more functionality until it does everything that yours does. The last piece of the puzzle I guess would be the Trogluddite SK Sampler. It can match to a frequency and note, perhaps we could make an array automatically created, but just for the zone; Trogluddites code could be utilized with our software to create and pitch each sample perfectly in sequence.
And then, in turn; each zone would use an array; but like in My example, there would be different code per zone.
Perhaps that is the best of both worlds and I'd venture to say that there might not be a better sampler concievbly in existence, if we were able to succeed at that. However, it's tempting to try and make that idea of Trog's to match time and pitch in real time.
I hope you enjoy the preview

try a crescendo with Nubeat's (superior) ruby keyboard. His does not get stuck on rolls.