3 ms·
> You can't possibly say that with any confidence. Assuming your module's interface isn't too complicated, it shouldn't be terribly difficult to write a test f
by bunderbunder 8y ago
> You can't possibly say that with any confidence.
Assuming your module's interface isn't too complicated, it shouldn't be terribly difficult to write a test fixture that fuzzes a module, and verifies that its memory consumption does not go outside a certain bound.
The first round of bugs you'll catch might be design flaws more than true memory leaks - places where the module isn't designed to limit its own memory usage in the face of adverse (or adversarial) input.
Get those pinned down, and then you can use it to catch memory leaks with confidence. Let it run for less time if you're only worried about catching fast leaks, and for more time if you need to catch the slow ones, too.