Enough underwater range to get out of Biscay without ever going to periscope depth.
Hydrophones so sensitive that you can attack with out exposing your periscope to enemy radar at all.
Torpedo tubes that launch at 50m depth.
As long as you never surface at all, only use diesels and the snorkel for charging batteries and attack convoys from below 40m depth you are almost invincible.
The blueprints for the IXX existed before the war, but the project was put on hold due to lack of funding. This means that starting with a IXX in 1941 would only require a few small changes in history to be historically correct.