Car and driver did a test of the Z4 M40 prototype and confirms that the car will have 382 horses, according to BMW engineers. and 369 lb-ft of torque.
It is safe to assume the M340i will have the same specs.
https://g29.bimmerpost.com/forums/sh....php?t=1502592