It's an option for the m5 utility, not the gem5 simulator. It tells the utility to use a different mechanism to trigger the operations, one based on a special address rather than special, otherwise undefined instructions.
Gabe On Sat, Nov 14, 2020 at 1:10 AM krishnan gosakan <krishnan.gosa...@gmail.com> wrote: > I am using KVM cpu. What is that --addr flag? I can't find it in > options.py and get an error when invoking gem5 with it. > fs.py: error: no such option: --addr > I compiled m5 from the latest master branch and tried using it in my old > branch > I get "Illegal Instruction" error. Is that due to KVM and not using --addr > flag? > > On Sat, Nov 14, 2020 at 2:32 PM Gabe Black <gabe.bl...@gmail.com> wrote: > >> I think that should work, although I haven't tried it. If you're using >> the new m5 utility with x86 and the KVM cpu, be sure you use the --addr >> flag. If not, then I think it should work the same. >> >> Gabe >> >> On Sat, Nov 14, 2020 at 12:24 AM krishnan gosakan via gem5-users < >> gem5-users@gem5.org> wrote: >> >>> Can I use m5 util from the current stable branch with the old gem5 repo >>> I am currently using? Will that won't create compatibility issues? >>> >>> On Sat, Nov 14, 2020 at 1:38 PM Gabe Black via gem5-users < >>> gem5-users@gem5.org> wrote: >>> >>>> Probably not. There were some other fixes which made things partially >>>> work with PIE code, but the version of the utility you're using may be too >>>> old to include those, or you might be trying to use it in a way that the >>>> partial support didn't cover (different ISA for instance). You'll probably >>>> save yourself a lot of headaches by moving to a more recent version of >>>> gem5, at least for the m5 utility if you can't or don't want to move >>>> completely. >>>> >>>> Gabe >>>> >>>> On Fri, Nov 13, 2020 at 11:28 PM krishnan gosakan < >>>> krishnan.gosa...@gmail.com> wrote: >>>> >>>>> I tried make. >>>>> I used the command make -f Makefile.x86 >>>>> for which I got the following error >>>>> >>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -o m5.o -c m5.c >>>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -o m5op_x86.o -c >>>>>> m5op_x86.S >>>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -o m5_mmap.o -c >>>>>> m5_mmap.c >>>>>> gcc -o m5 m5.o m5op_x86.o m5_mmap.o >>>>>> /usr/bin/ld: m5op_x86.o: relocation R_X86_64_32S against symbol >>>>>> `m5_mem' can not be used when making a PIE object; recompile with -fPIC >>>>>> /usr/bin/ld: final link failed: Nonrepresentable section on output >>>>>> collect2: error: ld returned 1 exit status >>>>>> Makefile.x86:54: recipe for target 'm5' failed >>>>>> make: *** [m5] Error 1 >>>>>> >>>>> >>>>> Even i added -fPIC in makefile and still getting the same error >>>>> >>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -fPIC -o m5.o -c m5.c >>>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -fPIC -o m5op_x86.o -c >>>>>> m5op_x86.S >>>>>> gcc -O2 -DM5OP_ADDR=0xFFFF0000 -I../../include -fPIC -o m5_mmap.o -c >>>>>> m5_mmap.c >>>>>> gcc -o m5 m5.o m5op_x86.o m5_mmap.o >>>>>> /usr/bin/ld: m5op_x86.o: relocation R_X86_64_32S against symbol >>>>>> `m5_mem' can not be used when making a PIE object; recompile with -fPIC >>>>>> /usr/bin/ld: final link failed: Nonrepresentable section on output >>>>>> collect2: error: ld returned 1 exit status >>>>>> Makefile.x86:54: recipe for target 'm5' failed >>>>>> make: *** [m5] Error 1 >>>>>> >>>>> >>>>> Am I missing anything here? >>>>> >>>>> On Sat, Nov 14, 2020 at 9:32 AM Gabe Black <gabe.bl...@gmail.com> >>>>> wrote: >>>>> >>>>>> That version of gem5 is a few years old and doesn't have the updates >>>>>> to the m5 utility that made it use scons. In that version, you need to >>>>>> use >>>>>> make. >>>>>> >>>>>> Gabe >>>>>> >>>>>> On Fri, Nov 13, 2020 at 7:43 PM krishnan gosakan via gem5-users < >>>>>> gem5-users@gem5.org> wrote: >>>>>> >>>>>>> Hi all, >>>>>>> I am trying to compile m5 utils. I followed the documentation >>>>>>> available at https://www.gem5.org/documentation/general_docs/m5ops/ >>>>>>> I am using >>>>>>> https://gem5.googlesource.com/public/gem5/+/f0364a2b08f8919347164e9aad82ca3a0167eb4b >>>>>>> >>>>>>> In the above repo, utils/m5 directory has no scons file and I am >>>>>>> facing difficulty in compiling m5. Can anyone help me with this? >>>>>>> Thanks in advance. >>>>>>> >>>>>>> -- >>>>>>> Regards, >>>>>>> Krishnan. >>>>>>> _______________________________________________ >>>>>>> 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 >>>>>> >>>>>> >>>>> >>>>> -- >>>>> Regards, >>>>> Krishnan. >>>>> >>>> _______________________________________________ >>>> 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 >>> >>> >>> >>> -- >>> Regards, >>> Krishnan. >>> _______________________________________________ >>> 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 >> >> > > -- > Regards, > Krishnan. >
_______________________________________________ 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