Well, generation numbers can be determined by counting up through parent commits. So they are derived information, it's just that that takes ages and lots of disk seeks to count through.
Timestamps aren't really needed. They are information that is useful to use that we want to store, just like the date in an email. Thus they are as required as the names of the author and committer.
The reason for the discussion about the commit timestamps is (AIUI) a heuristic optimisation that works because they happen to be there and happen to (most of the time) be in order.
>Well, generation numbers can be determined by counting up through parent commits. So they are derived information, it's just that that takes ages and lots of disk seeks to count through.
>Timestamps aren't really needed.
First off, timestamps are needed. They're used to order commits in the history. Generation numbers do the same thing, but a bit more elegantly, because they avoid most of potential clock issues in a distributed environment.
You're making the assumption that the set of derived data and the set containing the absolute minimum amount of data git needs to work are mutually exclusive sets. They're not, especially if the derived data is computationally expensive to get, and is still used for normal operation.
One of git's primary goals is fast, scalable performance. Commit generation numbers help reduce potential errors with the current timestamp approach. However, they're expensive to calculate, and don't scale well at all. Linus' argument is that instead of calculating them every time, it's far simpler to just add them in and be done with it.
By that definition of "derived information", the hash is "derived information" since it's based of the changes made to source data (whatever that data may be).
That said, point taken about the necessity of both generation numbers and timestamps. But that invalidates the OPs comment about git storing "only the minimum amount of information". It sounds like that's never been a hard principle.
Thanks for the background! (Seriously, not trying to be snarky.)
That info does support my original point that generational numbers probably should have been stored from the start and timestamps are the more "derivative" bit of information since it comes from the environment and not the data itself.
Thus, rlpb's concern that storing generational numbers pollutes its design of storing "only the minimum amount of information" isn't necessarily well founded, since the generational number might be more minimal and correct than the current timestamp. That was the aim of my original post: generational info is fundamental, not extraneous derived info, and probably have been stored with commits in the first place.
Timestamps aren't really needed. They are information that is useful to use that we want to store, just like the date in an email. Thus they are as required as the names of the author and committer.
The reason for the discussion about the commit timestamps is (AIUI) a heuristic optimisation that works because they happen to be there and happen to (most of the time) be in order.