Why Does the Microcontroller Delay in Calling Address 0004h?

  • Thread starter Thread starter MSI
  • Start date Start date
  • Tags Tags
    Time
Click For Summary
The discussion centers on the latency observed in a microcontroller when handling an interrupt request, specifically why it does not immediately call address "0004h" during the third machine cycle. It suggests that the microcontroller's pipelining may prevent immediate execution due to already decoded instructions at PC + 1, which could complicate halting the current execution. Additionally, there may be a need to save certain data or status flags before switching execution threads. The complexity of the specific processor in question further complicates a definitive answer. Overall, while the delay raises questions, it is not deemed a significant issue.
MSI
Messages
16
Reaction score
1
http://img521.imageshack.us/img521/6018/msi7cv.jpg

this graph shows a latency time diagram when an inturept request occur in a micro controller ..
i was just wondering why doesn't the micro controller in the third machine cycle call the address "0004h" directly ?
whats the use of this cycle ? ... still the micro controller can flush inst (PC+1) ,, while fetching 0004h in the next cycle ? :/
 
Last edited by a moderator:
Engineering news on Phys.org
Couple of possible reasons. First, many CPUs have a pipelines instruction. The instruction at PC + 1 is probably already decoded and execution may be difficult to stop and more effective to just let it complete. Second, the cpu may have to save some data before allowing the thread of excution to jump to another thread, such at status flags.

To better answer he question would require significant knowledge of that particular processor.
 
well the second is not possibel , because saving the registers is done through the intrupt, and the first one .. yea it do pipelining (: , but it is already shown in the figer .. and if pc+1 is a calling function .. there will be extra latency (not shown in the figure) ..

anyway it is not a big deal (: , thanks
 
What mathematics software should engineering students use? Is it correct that much of the engineering industry relies on MATLAB, making it the tool many graduates will encounter in professional settings? How does SageMath compare? It is a free package that supports both numerical and symbolic computation and can be installed on various platforms. Could it become more widely used because it is freely available? I am an academic who has taught engineering mathematics, and taught the...

Similar threads

Replies
6
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 13 ·
Replies
13
Views
5K
  • · Replies 1 ·
Replies
1
Views
3K
Replies
10
Views
4K
  • · Replies 24 ·
Replies
24
Views
5K
  • · Replies 19 ·
Replies
19
Views
5K
  • · Replies 7 ·
Replies
7
Views
4K