112
votes
Accepted
How do computers keep track of time?
Computers have a "real-time clock" -- a special hardware device (e.g., containing a quartz crystal) on the motherboard that maintains the time. It is always powered, even when you shut your computer ...

D.W.♦
- 154k
37
votes
Accepted
What is a CPU clock physically?
Modern clocks are originally generated by quartz crystal oscillators of about 20MHz or so, and then the frequency is multiplied by one or more phase-locked loops to generate the clock signals for ...
15
votes
How do computers keep track of time?
If you remove the battery on the motherboard then the computer wouldn't have any way to tell the time.
This is also the case with mobile phones. If you let a phone discharge and then not recharge it ...
7
votes
What is a CPU clock physically?
A CPU clock is a signal which is used for two related purposes:
Devices that are synchronous to a common clock agree that they will only look at signals from other such devices within a very short ...
6
votes
What are system clock and CPU clock; and what are their functions?
The answer provided by @Benjoyo is not accurate. The CPU clock can be lower than the system clock, at least in microcontrollers.
As seen in this link, the PIC microcontrollers have the CPU clock, ...
6
votes
Accepted
Are vector clocks useful in centralized systems?
No, there's no need for a vector clock in a centralized system.
A vector clock uses a $N$-vector of timestamps, where $N$ is the number of computers in the distributed system and the $i$th component ...

D.W.♦
- 154k
6
votes
What is a CPU clock physically?
This is a picture of a DIY quartz clock:
This is (part of) a picture of a mainboard:
Note the component I have marked with an arrow. You can see they look identical.
Some caveats:
Quartz crystals ...
5
votes
Accepted
Lamport logical clock: what does partial mean in the concept of `Partial ordering`?
The "partial ordering" in the papar means partial order as in standard mathemtics theory. To be more rigorous, the "partial ordering" in that paper, also called "irreflexive parital ordering" in that ...
5
votes
Accepted
Why computer didn't use cesium atom to define 1 second?
First of all, the reason personal computers dont't use atomic clocks based on caesium is price. One CSAC (chip scale atomic clock) costs 5000 USD nowadays. The added precision is not worth the price ...
4
votes
Accepted
How do computers synchronize their clocks with the standard time
The Network Time Protocol (NTP) uses a rather simple basis, it assumes that the roundtrip time is divided equally between up and down delays after server processing is subtracted.
NTP keeps 4 ...
4
votes
Vector clocks: Why is it necessary to increment my clock on receiving a message?
Look at the definition of $<_H$.
We say that $e_1<_H e_2$ (event 1 happened before event 2) if:
$e_1,e_2$ took place in the same process, and $e_1$ happened first (events within the same ...
3
votes
Accepted
Lamport logical clock: why event occurs in a process with smaller pid is treated earlier?
No, "it doesn't make sense". You are correct in the sense that that choice is not a logical consequence of any requirements and known truths. It could be considered as arbitrarily selected.
Well, we ...
3
votes
Vector clock :why Singhal Kshemkalyani differential technique require FIFO for message passing?
All it's saying is that the messages between two processes need to be received in the order they are sent. If I'm going to send only differences between the previous message, we both better agree on ...
3
votes
Accepted
How is clock syncing implemented?
You have a good understanding of clocking mechanism and how flip-flops (registers really, can be implemented using any clocked memory, not just flip-flops) are used to get a "final" reading after all ...
2
votes
How is clock syncing implemented?
I feel there are multiple questions in your post. I will attempt to answer the first -
"...The clock period is set such that the other circuitry (NAND gate in my case) has the time to stabilize ...
2
votes
Accepted
Applying information theory to processor clocks
Technically, clock skew does this already. Specifically the technique known as "useful skew". When a data signal is going to travel from one storage element to another (both updating based on the ...
2
votes
Accepted
How can I calculate the effective bandwidth of a memory system?
An N-bit wide data bus can transfer N bits in one clock cycle, after a latency of d clock cycles (or t seconds).
I think the ...
2
votes
Is there a way to compute time without system clock
On some video-gaming platforms where the performance characteristics are very rigidly defined and consistent, you can make a very good approximation of elapsed time by counting how many frames have ...
2
votes
Exactly how many clocks does a Computer consists of and how do they synchronize with each other?
Modern processors tend to have more clocks than processors in the past, because that means when a part of the processor isn't used, it may be possible to switch off that part completely, including the ...
2
votes
How do computers keep track of time?
When you start Windows, it gains direct access to the memory of the Real Time Clock (RTC) and uses its date and time values to set the computer date and time. Timer interrupts maintain the computer ...
2
votes
How are lamport timestamps useful in practice?
As Wikipedia explains:
The algorithm of Lamport timestamps is a simple algorithm used to determine the order of events in a distributed computer system. As different nodes or processes will typically ...
2
votes
Accepted
Whats the point of caching if the minimum single clock cycle time is the prorogation delay of the slowest component (fetching from DRAM)?
You are right that the clock speed is determined by the slowest stage. But on most architectures it is not true that fetching(or any kind of memory access in fact) takes one cycle. This is an illusion ...
2
votes
Does two system's clock synchronises to communicate with each other?
Your question is a bit vague, depending on what is communicating, so I will try to give a general answer. There are essentially two big ways of communicating:
Sending data together with a clock ...
2
votes
Resetting Vector clocks in distributed systems
Vector clocks overflow for the same reason that regular integers do. Vector clocks generally maintain a fixed number of bits per process to capture the event count for each respective process. There ...
2
votes
Accepted
Why is an accurate time so important for servers and computers?
It depends. If all atomic clocks would be turned off simultaneously, right now, that would be trouble. Because everyone relies on atomic clocks. And everything is organized in such a way that it doesn'...
1
vote
Accepted
How can this MIPS processor execute one instruction in one cycle?
The register file in this design is multi-ported, and the read ports work like combinational circuits. The only thing between the read input and the output port is propagation delay. The clock signal ...
1
vote
What is an example of an algorithm that requires synchronised clocks?
I did some more thinking about this and I see at least one benefit of synchronized clocks, which is 'fairness when the topology is skewed'.
Imagine a situation with a server and two trusted clients. ...
1
vote
Metrics on which Clock Cycles Per Instruction(CPI) depends
In part a same processor is assumed, and 2 compilers are used. In part b, 2 processors with different clock frequency is used, ...
1
vote
Ordering of operations in a DAG of git commits
Assuming I understand the semantics:
You cannot concurrently Create the same bug report twice, so that's not a problem
Title could be a Last-Writer-Wins (LWW) register. If two users perform SetTitle ...
1
vote
How does Lamport imply anomalous behavior is impossible given these constraints?
The constraint as written by Lamport is $C_i(t+\mu)-C_j(t)\gt0$ or $C_i(t+\mu)\gt C_j(t)$ which can be re-written $$C_i(t+\mu) - C_i(t)\gt C_j(t) - C_i(t) \tag{*}\label{*}$$
Given Lamport's previous ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
clocks × 47distributed-systems × 23
computer-architecture × 11
cpu × 8
algorithms × 5
synchronization × 4
computer-networks × 3
terminology × 2
cpu-cache × 2
performance × 2
algorithm-analysis × 1
operating-systems × 1
parallel-computing × 1
information-theory × 1
memory-management × 1
data-compression × 1
memory-hardware × 1
memory-access × 1
process-scheduling × 1
dag × 1
cpu-pipelines × 1
intuition × 1
mips × 1
real-time × 1
topological-ordering × 1