红联Linux门户
Linux帮助

Ubuntu 16.04下GEM5安装及GEM5集成NVMain

发布时间:2016-11-29 11:55:33来源:linux网站作者:wangwcnl
1.GEM5安装
安装环境:Ubuntu 16.04lts
安装库文件
sudo apt-get install mercurial scons swig g++ protobuf-compiler libprotobuf-dev python-dev libgoogle-perftools-dev m4
下载GEM5
gem5下载:http://www.m5sim.org/Download
hg clone http://repo.gem5.org/gem5
编译gem5框架
zzz@zzz:~/gem5$ scons -j 28 build/X86/gem5.opt
ps:我的机子有28个核。
测试结果
命令
zzz@zzz:~/gem5$ scons build/X86/gem5.opt
结果
gem5 Simulator System.  http://gem5.org
gem5 is copyrighted software; use the --copyright option for details.
gem5 compiled Nov 28 2016 15:39:38
gem5 started Nov 28 2016 15:40:49
gem5 executing on zzz, pid 44126
command line: ./build/X86/gem5.opt configs/example/se.py -c tests/test-progs/hello/bin/x86/linux/hello
/home/zzz/gem5/configs/common/CacheConfig.py:48: SyntaxWarning: import * only allowed at module level
def config_cache(options, system):
Global frequency set at 1000000000000 ticks per second
warn: DRAM device capacity (8192 Mbytes) does not match the address range assigned (512 Mbytes)
0: system.remote_gdb.listener: listening for remote gdb #0 on port 7000
warn: ClockedObject: More than one power state change request encountered within the same simulation tick
**** REAL SIMULATION ****
info: Entering event queue @ 0.  Starting simulation...
Hello world!
Exiting @ tick 5942000 because target called exit()
GEM5 安装成功。
 
2.GEM5集成NVMain
下载NVMain
NVMain下载:http://wiki.nvmain.org/index.php?n=Site.GettingNVMain
hg clone https://bitbucket.org/mrp5060/nvmain/
修改hg配置文件
zzz@zzz:~/gem5$ vim ~/.hgrc
修改如下
[extensions]
mq =
[ui]
username = 你的bitbucket的邮箱
进入gem5的目录下面
更新gem5
zzz@zzz:~/gem5$ hg update 11620
用hg加入插件
zzz@zzz:~/gem5$ hg qimport nvmain/patches/gem5/nvmain2-gem5-10789+
zzz@zzz:~/gem5$ hg qpush
重新编译gem5.opt
zzz@zzz:~/gem5$ scons -j 28 build/X86/gem5.opt EXTRAS=~/gem5/nvmain
EXTRAS = 后面是你nvmain文件所在的路径。
 
本文永久更新地址:http://www.linuxdiyf.com/linux/26424.html