radv/bvh: Prevent NANs when computing node cost
If the computed cost is NAN, the check if (cost_of_preferred_pair <= current_minimal_cost)
always returns false, meaning that the degenerate geometry workaround doesn't trigger for degenerate geometry.
This fixes the lag spikes in Control when shooting at glass.