Hi Giacomo,


In SE mode, the segmentation fault is triggered

at  line 905 in build/ARM/cpu/o3/cpu.cc.



Following is the code that triggers the interrupt

and the code that is executed in the last two steps before the interrupt.



 gef➤  up

#1  0x0000555555dc2969 in gem5::o3::CPU::trap (this=0x55555b7ca000,
fault=std::shared_ptr<gem5::FaultBase> (use count 2, weak count 0) = {...},
tid=0x0, inst=...) at build/ARM/cpu/o3/cpu.cc:905

*905*     fault->invoke(threadContexts[tid], inst);



*void*

*CPU::trap(const Fault &fault, ThreadID tid, const StaticInstPtr &inst)*

*{*

*    // Pass the thread's TC into the invoke method.*

*    fault->invoke(threadContexts[tid], inst);             <---- line 905*

*}*





 gef➤  up

#2  0x0000555555dae664 in gem5::o3::Commit::commitHead
(this=0x55555b7cd8a0, head_inst=..., inst_num=0x0) at
build/ARM/cpu/o3/commit.cc:1252

*1252*         cpu->trap(inst_fault, tid,





 *  if (inst_fault != NoFault) {*



*        ……*

*        …….*

        ……..



*        assert(!thread[tid]->noSquashFromTC);*





*        cpu->trap(inst_fault, tid, <----- line 1252*

*                  head_inst->notAnInst() ? nullStaticInstPtr :*

*                      head_inst->staticInst);*





gef➤  up

#3  0x0000555555dacbaf in gem5::o3::Commit::commitInsts
(this=0x55555b7cd8a0) at build/ARM/cpu/o3/commit.cc:1020

*1020*             bool commit_success = commitHead(head_inst,
num_committed);



*if (head_inst->isSquashed()) {*



*        ……*

*        …….*

        ……..

*        } else {*

*            pc[tid] = head_inst->pcState();*



*            // Try to commit the head instruction.*

*            bool commit_success = commitHead(head_inst, num_committed);
 <---- line 1020*

Ali

On Tue, Oct 12, 2021 at 5:01 PM Giacomo Travaglini <
giacomo.travagl...@arm.com> wrote:

>
> > -----Original Message-----
> > From: Ali Ghandour via gem5-users <gem5-users@gem5.org>
> > Sent: 12 October 2021 08:50
> > To: gem5-users@gem5.org
> > Cc: Ali Ghandour <ghandour....@gmail.com>
> > Subject: [gem5-users] Re: Porting a configuration file from gem5 v20 to
> gem5
> > v21
> >
> > Hi Giacomo,
> >
> > Indeed, I was able to use ArmMMU.connectWalkerPorts method and run
> > the config file in fs mode.
>
> Great!
>
> > However, I a, still struggling with the segmentation fault in se mode.
> >
> > Does it make any sense to have a config file working in fs mode but
> failing in
> > se? (notice that it is running in both fs and se mode in v20.0.0.)
> >
>
> It does as I believe the two issues (in SE and FS) are not related to each
> other. You are probably hitting another bug in SE mode.
> If you are getting a segmentation fault you are probably trying to
> dereference an invalid pointer (nullptr?). With GDB, could you navigate the
> stack frames
> until you find the invalid pointer? (just print the pointer you are trying
> to dereference)
>
> > Ali
> > _______________________________________________
> > gem5-users mailing list -- gem5-users@gem5.org To unsubscribe send an
> > email to gem5-users-
> > le...@gem5.org %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
>
> Kind Regards
>
> Giacomo
> IMPORTANT NOTICE: The contents of this email and any attachments are
> confidential and may also be privileged. If you are not the intended
> recipient, please notify the sender immediately and do not disclose the
> contents to any other person, use it for any purpose, or store or copy the
> information in any medium. Thank you.
>
_______________________________________________
gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to