The contentUpdateDate / contentDirty implementation is completely wrong.
For example, try the following in a document :
As we can see, the content is already considered dirty as soon as we retrieved it. Then we save without any change on the document, and the content update is the same as the last modification date.
One of the main reason for this to happen, is that the method XWiki#setFullName does set the contentDirty flag to true. This method (setFullName) is called when retrieving a document.
I don't have a fix for now, since I don't fully understand the implications of changing this, but the current behavior is wrong.