There are some safeties, aka limiters, that have to be modifed, but my custom tuning experience has taught me that OEM timing is the biggest factor in available power. Using 100% stock fuel quantity and pressure my 05 is able to make at least 55 more hp right where is counts, 1800-2200 rpms, to the ground.
Emissions dictates a lot for how the combustion event takes place inside the cylinder, and most of it decreases the power/efficiency.
Consider that Cummins makes a 480hp 5.9 and 550hp 6.7 for the marine application, the components are stronger than what is made in a pickup. Yes there are some differences in how a boat motor and truck motor use power, but it's still a substantial amount of power over the pickup ratings.
Many of the limiters/safeties are there to protect the engine and drivetrain under WOT driving at GCWR. Many people don't want, or feel the need, to monitor additional gauges when they change the tuning. IMHO even a simple 40hp tune needs additional monitoring, especially when towing.
Many people also get caught up in how easy it is to add hp to a diesel, and go to the highest setting on day one with a stock turbo/trans and no gauges.. and then wonder why they blew a trans or melted a piston.