DTrace User Guide

Discarding a Speculation

Discard speculations by using the discard() function. If the speculation has only been active on the CPU that is calling the discard() function, the buffer is immediately available for subsequent calls to the speculation() function. If the speculation has been active on more than one CPU, the discarded buffer will be available for subsequent calls to the speculation() function after the call to discard(). If no speculative buffers are available at the time that the speculation() function is called adtrace message that is similar to the following example is generated:


dtrace: 905 failed speculations (available buffer(s) still busy)