I don't think that an oil leak at the valve covers would cause it to run bad. It sounds like you have a vacuum leak on the intake side. Could be the dealer did not do a good job of installing the intake manifold gasket and it is leaking. By the way, after I had my block replaced, it leaked oil from one of the oil galley plugs on the new block - the dealer fixed it under warranty from BMW.