As a former '08 BMW 535i owner, I can tell you this N54 engine is riddled with issues. If you don't mind fixing oil leaks every 4 months, go for it. If you don't mind the electronic water pump and can get it wired correctly, do it. The trany is going to be an issue if you use the ones bolted the N54.
Lastly, If you can afford the swap and don't mind the work, WOW! what beast it would be 330+ HP! Good Luck! Please DOCUMENT if you take it on. Someone like CX Racing might be interested in helping with the swap.