Some good and some almost good answers here.
Diesel (or any piston) engines - contrary to that claimed above - do not necessarily need a long stroke for high compression; but they often have under square bores and/or strokes that are not short (by typical gasoline engine standards).
Diesel engines - contrary to that claimed above - do have throttle plates; these regulate the incoming air flow - which in turn regulates torque, power, and revs . . etc.
High compression can be achieved with and without altering the stroke, and this can be done by changing the con-rod length (not the same as stroke) so it places the piston further up the cylinder block and possibly protruding into the combustion chamber, and/or by altering the piston geometry.
Greater stroke can and does often lead to a greater instantaneous and composite torque moment at the crankshaft (think leverage with a big wrench; as this [plus more friction] is exactly what you give the BMEP and/or force exerted on the piston produced by each combustion product when it is connected to the crankshaft with a long stroke/"lever"); but - as mentioned - it also increases friction.
Diesel engines typically can run an extremely high compression (much higher than typical gasoline engines) due to the fuel they use that - amongst other things - doesn't compression-ignite at compression ratios that would in a typical gasoline engine.
As the responses and notes from above say; the name of the game is always Torque.
And that - plus the ability to produce high torque figures both reliably and (for the work done) economically - is why Diesel engines are made.
HorsePower (a force that is related to objects [a truck] that move in a straight line and/or linear plane) is simply a product of torque (a force associated with objects [a crankshaft] that spin and/or rotate); the amount of torque produced in a given time and/or revs.
Since there really are on a few things the powertrain-engineer can do to increase the output of any (diesel/gasoline) piston engine (aside from, increasing fuel burnt and/or swept capacity, increasing static engine capacity, increasing compression, reducing friction/reciprocal weight . .etc), please note that increasing compression is directly related to both increasing efficiency and output.
Unlike, say, increasing the static engine capacity; as a 454 cubic inch chev (<7 litre) is not necessarily more efficient than, say, a modern 3 litre V6 - despite the 454 probably chev probably being more powerful - provided the 3 litre V6 was not turbocharged.
Even then, turbocharge the 454 and you will have prodigious torque and power beyond 1500HP and possibly approaching 2000HP provided all tuning/fuelling is done right.
So Diesel engines are designed to produce significant torque via the above-mentioned design approaches and very high compression/combustion.
The length of the stroke within a diesel engine has more to do with maximum torque generation (from the combustion product) and/or design - than pure compression; but - as stated above - it can also assist the compression.
The combustion process is a complex one, and this is one place where efficiency, economy, and torque/power can be maximized.
This is why we see modern day gasoline cars - especially the European ones - all coming out with direct injection; like most diesels have had for years.
As this way the combustion process can be better controlled for all conditions and driving "modes".
Diesel engines - unlike most typical gasoline engines, especially those of a decade ago - almost always ensure that they fire precisely at top dead centre (TDC) due to the fact that they rely on compression-ignition.
Many typical gasoline engines - some of even today - are without the precision to fire every single combustion cycle right at TDC due to the complexity of an engine and how fast things inside move; and when this fails to happen efficiency and torque soon drop.
The faster an engine spins the harder it is to ensure that every single combustion cycle fires right at TDC; this is one reason why non-diesel engines these days all have individual coil packs (for each plug) and some form of electronic/computer controlled ignition.
Comparably, Diesel engines don't need electronic ignition systems at all, and they don't have high crankshaft speeds either (an ocean liner diesel will rarely do more than 250 - 300 rpm, if that).
Diesel engines are also basically built to generate significant torque from very low vehicle/engine speeds, and they also use a fuel that was designed (back when the only gasoline fuel available was leaded) to facilitate a very high compression ratio.
It is a fallacy that Diesel engines are way more efficient than typical modern day gasoline engines.
Usually - a decade or so ago - it was the diesel engine's ability to provide significant torque from low vehicle/engine speeds, combined with its ability to support high compression ratios, and also the fact that diesel's were turbocharged; that often provided the perceived efficiency and other advantages over the typical gasoline engine.
These days - especially with non-leaded gasoline products that support high compression - typical gasoline engines are not only turbocharged, direct injected and running high compression ratios - but they're also capable of both, greater crankshaft rotational speed bandwidths than diesels and also producing big torque numbers at low crankshaft rotational speeds, too.
That hits the same target as several of the unique selling propositions that diesels previously offered.
Still, the Diesel motor will enjoy popularity for a while longer as Diesel fuel is slightly cheaper than typical gasoline.
Plus, diesel engines; (a) are robust, (b) are relatively simple, (c) they usually run at low speeds [and are therefore torque products and "reasonably" economical/cost effective], (d) they don't require sophisticated valve-train and/or ignition system considerations, and, (e) when they're designed to operate in 2-stroke mode they can be implemented to yield greater torque outputs with sometimes equal or less complexity, particularly with respect to valve-train considerations.
That said, I think, the combination of the slow demise of the fossil fuel industry, most first world countries' carbon/pollution policies, and also the rise of hybrid/stand-alone electric motors within passenger vehicles, will probably - unless it significantly evolves - kill the diesel engine off within the next 10 years.