It isn't.
Ecoboost is a gasoline engine that uses turbocharging to extract more power from a smaller package.
Direct injection is used for one very important reason:
It cools down the engine. Injecting gasoline directly into the combustion chamber cools down the engine. The gasoline mist vaporizes due to the high heat of the combustion chamber, and in doing so, cools it down... much in the same way as spritzing yourself with water mist cools you down.
Port injection of liquid gasoline also cools down the engine, but the point of cooling is spread between the intake manifold, the valves and the chamber... direct injection is more effective because all the cooling happens in the chamber. And the concentrated squirt of fuel, sitting right on top of the spark plug, ensures that you only have to maintain the air fuel ratio for that tiny amount of space around the spark plug, not the whole combustion chamber, during ultra-lean burn part-throttle operation.
You need specialized high pressure direct injection for this because the pressures in the combustion chamber is so high. Around 200 psi or more. Ordinary injectors are not powerful enough to push through this pressure. Direct injection systems run at thousands upon thousands of psi to overcome this.
Without direct injection, you'd have to use more gasoline to cool your turbocharged engine down. Owners of older turbocharged gasoline engines can relate to this... old high-output Mitsubishi Evo 2.0s were as thirsty as engines two to three times the size.
Ecoboost also uses variable geometry turbochargers. This gives a fast spooling low output turbo for low rpms and a slower spooling high output turbo for high rpms. It makes them more flexible than older systems that were either optimized for low rpms (old Saabs) or high rpms (Evos)
-
The relation to diesels is that modern diesels utilize direct injection and variable geometry turbocharging. Now that these are common on diesels, the technology is slowly migrating to gasoline engines.