its the cam phasers. we had the same issue. it only did it after it warmed up and under 1200 RPMs. local shop said 1500 to 1900. dealer said 2400. We traded it in at a different dealership. for 2400, your better off saving up and waiting for it to tank, then putting a jasper in or something... my advice is to try to sell it and buy a sierra ! :-) btw all of my vehicles were fords until I had two at once start having issues. 2007 f250 6.0 and 2004 f150 with 5.4. father recomended GM. said he has put over 300k on 4 different small block gm' with only minor issues. I bought two used silverados no issues for two years and counting. good luck.
My advice may be worth what you paid for it.