At high altitudes, engines suffer loss of horsepower due to reduced air density. Diesel engines work by compressing the air creating heat necessary to ignite this air and fuel mixture. Turbo Diesel engines can ram more air into the combustion chamber increasing the air density. Without turbo most diesel engines will suffer noticeable power loss and incomplete combustion at 3000 feet. If you are thinking of using a generator above 3000 feet, don't pick diesel or you will have problems.
To compensate for high altitude, engines need to be adjusted to avoid too rich a fuel/air mixture. Diesel engines are adjusted for high altitude by advancing the fuel injection timing. This gives the engine more time to burn the fuel before it is expelled. At high altitude engines are noisier, have difficulty accelerating and have reduced power output. Also, the rich mixture can generate black smoke, which indicates incomplete combustion or in extreme cases white smoke, caused by raw fuel in the exhaust.
Many portable generators have fixed fuel injection timing. You can however remove a shim between the engine and the fuel injection pump will advance the timing. Once an engine has been adjusted for altitude it can overheat due to the lean mixture if operated at low altitude. There may be no other signs before engine damage occurs. Some diesel engine manufactures such as Yanmar Diesel suggest the modifications be done at 5000 feet. Manufactures normally setup their generators to run at at 500 ft If you intend to run a generator at higher altitudes you should let your dealer know this before you purchase a diesel generator.