I think they respected each other and to an extent were friends, but there was always a rivalry between them to.
Noel Gallagher was supposedly invited to the Azzurri camp right before the semi final in 2006 by Del Piero and when he was there and he was talking to Ale, Ale pointed to Totti and said 'there's the devil'. The way Gallagher tells the story it's sort of an inside joke, but at the same time there is real tension between them.
It's Noel Gallagher though, so who the fuck knows.
I can say that I have never heard either one of them speak ill of the other, and Totti does not hold back when it comes to Juve.