80 likes | 341 Views
2008.4.14. Sim 模拟器文件依赖关系. Makefile 的目标. All 包括 sim-fast , sim-safe , sim-eio , sim-bpred , sim-profile , sim-cheetah , sim-cache , sim-outorder 。. Gcc -M sim-fast.c. sim-fast.o: sim-fast.c /usr/include/stdio.h /usr/include/features.h
E N D
2008.4.14 Sim模拟器文件依赖关系
Makefile的目标 • All • 包括sim-fast,sim-safe, sim-eio,sim-bpred, sim-profile,sim-cheetah,sim-cache, sim-outorder。
Gcc -M sim-fast.c sim-fast.o: sim-fast.c /usr/include/stdio.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/bits/wordsize.h \ /usr/include/gnu/stubs.h /usr/include/gnu/stubs-32.h \ /usr/lib/gcc/i386-redhat-linux/4.1.2/include/stddef.h \ /usr/include/bits/types.h /usr/include/bits/typesizes.h \ /usr/include/libio.h /usr/include/_G_config.h /usr/include/wchar.h \ /usr/lib/gcc/i386-redhat-linux/4.1.2/include/stdarg.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sys_errlist.h \ /usr/include/stdlib.h /usr/include/sys/types.h /usr/include/time.h \ /usr/include/endian.h /usr/include/bits/endian.h \ /usr/include/sys/select.h /usr/include/bits/select.h \ /usr/include/bits/sigset.h /usr/include/bits/time.h \ /usr/include/sys/sysmacros.h /usr/include/bits/pthreadtypes.h \ /usr/include/alloca.h /usr/include/math.h /usr/include/bits/huge_val.h \ /usr/include/bits/mathdef.h /usr/include/bits/mathcalls.h host.h misc.h \ /usr/include/string.h machine.h config.h endian.h machine.def regs.h \ memory.h options.h stats.h eval.h loader.h syscall.h \ /usr/include/sys/time.h dlite.h sim.h /usr/include/setjmp.h \ /usr/include/bits/setjmp.h
Gcc -MM sim-fast.c [Hunterash@Hunter simplesim-3.0]$ gcc -MM sim-fast.c sim-fast.o: sim-fast.c host.h misc.h machine.h config.h endian.h \ machine.def regs.h memory.h options.h stats.h eval.h loader.h syscall.h \ dlite.h sim.h
Sim-fast的编译步骤 • main.o • syscall.o • memory.o • regs.o • loader.o • endian.o • dlite.o • symbol.o • eval.o • options.o • stats.o • eio.o • range.o • misc.o • Machine.o • Sim-fast.o • 先编译sysprobe标签 • 再编译sim-fast.o和其他文件 • 添加libexo目录下的libexo.a库 • 最后添加上`./sysprobe -libs` -lm(数学库)
Sim-cache的编译步骤 • main.o • syscall.o • memory.o • regs.o • loader.o • endian.o • dlite.o • symbol.o • eval.o • options.o • stats.o • eio.o • range.o • misc.o • Cache.o • Machine.o • Sim-cache.o • 先编译sysprobe标签 • 再编译sim-fast.o和其他文件 • 添加libexo目录下的libexo.a库 • 最后添加上`./sysprobe -libs` -lm(数学库) • 和sim-fast流程基本相同,多了一个编译cache.o的步骤
Sim-outorder的编译步骤 • main.o • syscall.o • memory.o • regs.o • loader.o • endian.o • dlite.o • symbol.o • eval.o • options.o • stats.o • eio.o • range.o • misc.o • Cache.o • Bpred.o • Resource.o • Ptrace.o • Machine.o • Sim-outorder.o • 先编译sysprobe标签 • 再编译sim-fast.o和其他文件 • 添加libexo目录下的libexo.a库 • 最后添加上`./sysprobe -libs` -lm(数学库) • 需要对cache.o,bpred.o,resourceo, ptrace.o进行编译
Sysprobe和libexo.a的编译 • sysprobe用来测试目标机的endian • Libexo.a不知道是干什么的