Hi Alex, this looks good, but I'm concerned about turning a pointer lookup into a (non-inlined) function call here.  This path is in every LSM update.

Could you please move `__wt_btree_memsize` into `include/btree.i` as an inlined function?

Otherwise, this change looks good to me.

Thanks,
Michael.