optimize backends metaclass