Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: "karthikeyan natarajan" <karthik_96cse@yahoo.com>
To: Ralf Baechle <ralf@linux-mips.org>
Cc: Dominic Sweetman <dom@mips.com>, linux-mips@linux-mips.org
Subject: Re: In r4k, where does PC point to?
Date: Mon, 19 Jan 2004 15:45:38 +0000 (GMT)	[thread overview]
Message-ID: <20040119154538.92376.qmail@web10108.mail.yahoo.com> (raw)
In-Reply-To: <20040119152214.GA9933@linux-mips.org>

Hi Ralf,

> > > Which is true, but perhaps a bit cryptic given
> the
> > > question.
> > > 
> > > A MIPS CPU does not have a register called "PC".
>  In
> > 
> > In the r4k user manual, it is mentioned that there
> is
> > a special register PC in the core CPU (other than
> the 
> > HI & LO special registers). Could you please let
> me 
> > know the purpose of this register?
> 
> Obviously the CPU needs to know where to fetch the
> next instruction from

So the PC points to the next instruction to be
fetched,
but it is not visible to the programmer..

> or for computing the destination address of branch
> and jump instructions
> or the value to put into the programmer visible EPC
> and ErrorEPC registers

Am curious to know, how the PC register can be used to

locate the instruction which caused the exception as 
the exception can happen at any one of the eight 
pipeline stages..

Thanks much,
-karthi


> etc.  The PC register is an internal register that
> isn't visible to the
> programmer.

So the bottom line here is PC is internal register and

the EPC is visible to the programmer.. 


Thanks,
-karthi
 
>   Ralf
>  

=====
The expert at anything was once a beginner
                  ______________________________
                 /                              \
             O  /      Karthikeyan.N             \
           O   |       Chennai, India.            |
    `\|||/'     \    Mobile: +919884104346       /
     (o o)       \                              /
_ ooO (_) Ooo____________________________________
_____|_____|_____|_____|_____|_____|_____|_____|_
__|_____|_____|_____|_____|_____|_____|_____|____
_____|_____|_____|_____|_____|_____|_____|_____|_

________________________________________________________________________
Yahoo! Messenger - Communicate instantly..."Ping" 
your friends today! Download Messenger Now 
http://uk.messenger.yahoo.com/download/index.html

  reply	other threads:[~2004-01-19 15:45 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-19  7:42 In r4k, where does PC point to? karthikeyan natarajan
2004-01-19 14:50 ` Ralf Baechle
2004-01-19 14:57   ` Dominic Sweetman
2004-01-19 15:14     ` karthikeyan natarajan
2004-01-19 15:22       ` Ralf Baechle
2004-01-19 15:45         ` karthikeyan natarajan [this message]
2004-01-19 17:08           ` Dominic Sweetman
2004-01-19 16:30       ` Dominic Sweetman
2004-01-19 16:49         ` karthikeyan natarajan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040119154538.92376.qmail@web10108.mail.yahoo.com \
    --to=karthik_96cse@yahoo.com \
    --cc=dom@mips.com \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox