Now
MAIN commitmail json YAML
pserialize(9): Fix bug in recent micro-optimization.
curcpu() is always a valid struct cpu_info pointer, but curlwp->l_cpu
is not necessarily -- early at boot on some architectures (like x86,
apparently) it may be null.
Not clear that l->l_cpu is always a cost win over curcpu(): on some
architectures curcpu() is basically a macro for curlwp->l_cpu, while
on others it is a fixed VA. So let's use the one that always works
instead of the one that's sometimes cheaper and sometimes crashier.
curcpu() is always a valid struct cpu_info pointer, but curlwp->l_cpu
is not necessarily -- early at boot on some architectures (like x86,
apparently) it may be null.
Not clear that l->l_cpu is always a cost win over curcpu(): on some
architectures curcpu() is basically a macro for curlwp->l_cpu, while
on others it is a fixed VA. So let's use the one that always works
instead of the one that's sometimes cheaper and sometimes crashier.