Using uint8 does not give any efficiency, actually, it is the opposite as EVM operates on default of 256-bit values so uint8 is more expensive in this case as it needs a conversion. It only gives improvements in cases where you can pack variables together, e.g. structs.
Not sure why withdrawFees queries the receiver from the masterContract (itself):
There is a variable named feeTo which is supposed to receive fees, so it should probably be cheapier to directly read it.
Repeated calculations should be cached, e.g. totalShare - openFeeShare in function _lend could be extracted to a variable:
Using uint8 does not give any efficiency, actually, it is the opposite as EVM operates on default of 256-bit values so uint8 is more expensive in this case as it needs a conversion. It only gives improvements in cases where you can pack variables together, e.g. structs.
I don't think this library is used in any meaningful way: