In addition to Fernando's information, unconditional branches are checked in 
decode stage (O3 model), see source file decode_impl.hh for details.

----[src/cpu/o3/decode_impl.hh]--------
    // Go ahead and compute any PC-relative branches.
    if (inst->isDirectCtrl() && inst->isUncondCtrl()) {

----
        '              Huang He (Henry)
       /-\\            CPU Design and Verification
      /---\'\          Advanced Micro Devices, Inc
     /-----\'`\        AMD Technology Development (Beijing) Co., Ltd.
    /-------\'`,\      Beijing, China
   /---------\' ,`7    O: +(86) 10 62801421  M: +(86) 18616862712
  /-----------\' /
 /-------------\/      [cid:[email protected]]   Visit us at: 
Facebook<https://www.facebook.com/AMD> | amd.com<http://www.amd.com/>

From: [email protected] [mailto:[email protected]] On 
Behalf Of Fernando Endo
Sent: Wednesday, July 03, 2013 4:35 PM
To: gem5 users mailing list
Subject: Re: [gem5-users] Branch Misperdiction.

Hello,

In the stats file (in my case O3 model), there's 
'system.cpu.BPredUnit.condIncorrect'. Then, you can look for it in the O3 cpu 
code and see what function updates it. If I'm not wrong, there're signals 
comming from pipestages to inform when there's a branch misprediction (squash). 
By there:

src/cpu/o3/fetch_impl.hh:
DefaultFetch<Impl>::checkSignalsAndUpdate(ThreadID tid)

Regards,

--
Fernando A. Endo, PhD student and researcher

Université de Grenoble, UJF
France

2013/6/28 ali bagherian <[email protected]<mailto:[email protected]>>
Hi,

Which file or function in the Gem5 detects branch misperdiction?

Thanks for you help,
Ali

_______________________________________________
gem5-users mailing list
[email protected]<mailto:[email protected]>
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

<<inline: image001.jpg>>

_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Reply via email to