Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

trap vector versus branching

Status
Not open for further replies.

daf12

Programmer
Mar 15, 2007
1
0
0
GB
What is the difference between a trap instruction and branching?
I read that a trap vector is much like an interrupt and when a trap instruction happens, program jumps to a subroutine.
Why can't branching be used? What is the difference between trap vector and branching? I thought that both perform the same instruction. thanks
 
A trap is an interrupt which occurs as a result of some action taken by the program - such as setting the single step flag, executing an INTO instruction, or issuing a break point interrupt. Unless you are doing something relatively specialised, such as writing a degugger, you seldom if ever need to worry about them.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top