I have an 04 Yukon 4.8 127k miles. I had similar rough idling and acceleration depending on how you hit the gas in take off, it bogged and was not responsive.
Finally in one of the hard take offs where it would not downshift as in passing threw a code. Mass airflow performance.
I saw vids about cleaning mafs and how it resolved starting and rough idle. I spent 10.00 on a can of mass air cleaner (it's specific only for mass air),. It is now like a new car increased mileage, acceleration was amazing, nonlag or bog and smooth shifting. All these function are regulated by fuel/air mix which the ecm then can properly tune timing of fuel and combustion etc.
It didn't look obviously dirty but the needles apparently we're.
Google clean mass air sensor. I'm so glad I've done it the motor is so happy and me too.
Sent from my SM-G950U1 using Tapatalk