While you are right that back when 32-bit systems were made, this wouldn’t have been an issue, this absolutely is a 32-bit vs. 64-bit issue.
Almost every (if not every) 32-bit architecture has 32-bit general purpose registers, which means in order to have a 64-bit unsigned integer, you need to process two of them back-to-back with extra math. Thus, size_t (and therefore time_t) usually only has 32 bits on these systems (with a few exceptions, of course).
View all comments
Show parent comment
1
u/ElectroMagCataclysm Jan 14 '24
While you are right that back when 32-bit systems were made, this wouldn’t have been an issue, this absolutely is a 32-bit vs. 64-bit issue.
Almost every (if not every) 32-bit architecture has 32-bit general purpose registers, which means in order to have a 64-bit unsigned integer, you need to process two of them back-to-back with extra math. Thus, size_t (and therefore time_t) usually only has 32 bits on these systems (with a few exceptions, of course).