Hi Anmol,

For TraceFlex (either x86 or SPARC), the function to look for is  
insn_fetch in components/DecoupledFeeder/SImicsTracer.cpp.

For CMPFlex (again, x86 or SPARC), the function to look for is  
doFetch() in components/IFetch/IFetchImpl.cpp.  There is a line that  
assigns currentPC pretty early in that function.

For OoO simulators (only SPARC, so e.g. CMPFlex.OoO), the retirement  
stream (correct path instructions) can be found in the function called  
retire() in components/uArch/CoreModel/cycle.cpp.  To get the PC of  
the retiring instruction (the head of the ROB), use: theROB.front()- 
 >pc()

If you want to integrate these (whether TraceFlex or CMPFlex or  
CMPFlex.OoO) to use a common tracing mechanism, use TraceTracker.  Add  
a callback in components/Common/TraceTracker.hpp and implement in the  
corresponding cpp file in the same directory.

Hope this helps,
Brian

On Mar 13, 2008, at 6:11 PM, [email protected] wrote:

>
>
> (1) Could you tell me for both -- TraceFlex on x86 and CMPFlex on  
> SPARC.
> At this moment I just want to know the current executing instruction.
>
> (2) Thanks :)
>
>
> Quoting Brian Gold <[email protected]>:
>
>> Hi Anmol,
>>
>> (1) This depends on what kind of simulation you are doing (trace vs.
>> in-order timing vs. out-of-order timing).  What's the name of the
>> simulator you compile? Also, do you just want the PCs or do you want
>> more information about the instruction stream?  TraceTracker does not
>> (currently) receive callbacks on new instruction fetches, but it  
>> would
>> be easy to add that.
>>
>> (2) ASO is implemented in the out-of-order core.  This is
>> components/uArch (mostly in the subdirectory CoreModel).
>>
>> Regards,
>> Brian
>>
>>
>> On Mar 12, 2008, at 4:17 PM, [email protected] wrote:
>>
>>>
>>> Hello,
>>>
>>> I have two questions:
>>>
>>> (1) If I want to track the instruction stream within Flexus,  
>>> should  I look at TraceTracker, or InstructionTransport, or  
>>> somewhere else  ...?
>>>
>>> (2) Which component in Flexus corresponds to the ASO functionality?
>>>
>>> Thanks,
>>> Anmol
>>>
>>> _______________________________________________
>>> SimFlex mailing list
>>> [email protected]
>>> https://sos.ece.cmu.edu/mailman/listinfo/simflex
>>> SimFlex web page: http://www.ece.cmu.edu/~simflex
>
>
> _______________________________________________
> SimFlex mailing list
> [email protected]
> https://sos.ece.cmu.edu/mailman/listinfo/simflex
> SimFlex web page: http://www.ece.cmu.edu/~simflex

Reply via email to