[gem5-users] Re: write if-else statement in slicc transition code blocks.
Hello Jason, Thank you for your reply, thank you very much. ___ 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
[gem5-users] Re: run a binary file for 3 times on gem5
Hello, I don't think there's a simple way to do this in SE mode. In FS mode, you could write a simple shell script to execute the program in a loop. One thing you can do is to modify the program to execute the ROI multiple times. Cheers, Jason On Sun, Jan 31, 2021 at 5:20 PM ABD ALRHMAN ABO ALKHEEL via gem5-users < gem5-users@gem5.org> wrote: > Hi All, > > How to run a binary file three times on gem5? I want to find the execution > time for a binary file for 1M instructions. However, the gem5 is completed > on 400K instructions because the binary file is completed. So how I can run > it three times in order to reach 1M instructions? > > For example, If I want to run the hello world on gem5 using the following > command, the gem5 will end before reach 10k insts since hello needs only 5k > insts to finish. So ho i can run it for 3 times? > > build/X86/gem5.opt configs/example/se.py -I 1 -c > tests/test-progs/hello/bin/x86/linux/hello --cpu-type=DerivO3CPU --caches > > Any help would be appreciated. > > Thanks > ___ > 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 ___ 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
[gem5-users] Re: Error in HMC Simulation
Hey Veronia, Thanks for bringing this to our attention. The issue is we're starting to move from Python 2 to Python 3 and this appears to be another teething problem. In Python 2 the `i/4` at line 270 will floor to an int. In Python3 it will return a float (obviously not a valid index for a list). I'll look into fixing this on our develop branch, but I believe this can be fixed by changing this to `i//4`. I.e.: ` mem_ctrls[i].port = xbar[i//4].master`. Kind regards, Bobby -- Dr. Bobby R. Bruce Room 2235, Kemper Hall, UC Davis Davis, CA, 95616 web: https://www.bobbybruce.net On Mon, Feb 1, 2021 at 11:38 AM Veronia Bahaa via gem5-users < gem5-users@gem5.org> wrote: > Hello, > I am new to gem5. When I try to run the gem5 using HMC configurations > build/ARM/gem5.opt configs/example/hmc_hello.py > or > build/ARM/gem5.opt configs/example/hmctest.py > > I get this error > Traceback (most recent call last): > File "", line 1, in > File "build/ARM/python/m5/main.py", line 457, in main > exec(filecode, scope) > File "configs/example/hmc_hello.py", line 63, in > MemConfig.config_mem(options, system) > File "/home/veronia/gem5/configs/common/MemConfig.py", line 270, in > config_mem > mem_ctrls[i].port = xbar[i/4].master > TypeError: list indices must be integers or slices, not float > > Thanks, > Veronia > ___ > 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 ___ 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
[gem5-users] Error in HMC Simulation
Hello, I am new to gem5. When I try to run the gem5 using HMC configurations build/ARM/gem5.opt configs/example/hmc_hello.py or build/ARM/gem5.opt configs/example/hmctest.py I get this error Traceback (most recent call last): File "", line 1, in File "build/ARM/python/m5/main.py", line 457, in main exec(filecode, scope) File "configs/example/hmc_hello.py", line 63, in MemConfig.config_mem(options, system) File "/home/veronia/gem5/configs/common/MemConfig.py", line 270, in config_mem mem_ctrls[i].port = xbar[i/4].master TypeError: list indices must be integers or slices, not float Thanks, Veronia ___ 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
[gem5-users] Re: write if-else statement in slicc transition code blocks.
Hello, If you want to trigger two different transitions based on different inputs, this should always go in the in_port definition. For instance, see http://www.gem5.org/documentation/learning_gem5/part3/cache-in-ports/. You can base this on the message information by using peek() on the buffer. If you want to trigger based on the cache state, you should make sure the state you need is stored in the TBE or cache block as a "State". Then, the transition tagged with that state as a starting state will be triggered. It's best practice to never use if statements except in in_ports. Remember, you're describing a state machine, not writing imperative code. SLICC is more like verilog than it is C/C++. Jason On Sun, Jan 31, 2021 at 5:33 AM zhen bang via gem5-users < gem5-users@gem5.org> wrote: > Hello everyone: > Recently, I am making some changes to the cache coherence protocol in > Gem5, in the SLICC documents, I should add some if-else statements, but the > transitions code blocks seem do not to cover this case, it shows syntax > error >>if<<. If I do so, should I change the related parts like action > code blocks and basic configurations? > Such as: > if (..){ > transition(..) > } > else{ > transition(..) > } > ___ > 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 > ___ 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