The cost is very low (I've had an email from somebody from the JVM
team stating that 15+ years ago).
However, it's still there (plus the cost of running extra VM instructions).
And those are linearly amplified by use (unless hotspot can optimize
those calls out all together)
This is, ATM, a balance between:
* paying the runtime cost (linear growth though)
* having bulkier code (engineering time cost, project dependent)
* maintaining thread-unsafe variant of lazy getter (Lombok devs
engineering time cost) PLUS juniors misinterpreting the
"thread-unsafe" flag, causing project engineering time cost.
Btw, there is an additional cost for handling nulles - the memory cost
of carrying an XReference instance, plus the GC cost to release that.
That cost is unnecessary if expensive() would never produce nulls.
Throw a "nullable=false" in for good measure?