On Wed, Apr 5, 2023 at 6:44 PM Andrii Nakryiko <andrii.nakryiko@xxxxxxxxx> wrote:> > We could and I thought about this, but verifier logging is quite an > expensive operation due to all the extra formatting and reporting, so > it's not advised to have log_level=1 permanently enabled for > production BPF program loading. Any idea how expensive this is? > Note that even if log_buf==NULL when log_level>0 we'd be > doing printf()-ing everything, which is the expensive part. So do you > really want to add all this extra overhead *constantly* to all > production BPF programs? No, I'm just going off of what UAPI I would like to use. Keeping semantics as they are is fine if it's too slow. We could always use a small-ish buffer for the first retry and hope things fit.