diff options
93 files changed, 3835 insertions, 929 deletions
diff --git a/SConscript b/SConscript index 444f71afe..7f9e56f70 100644 --- a/SConscript +++ b/SConscript @@ -28,6 +28,7 @@ import os import sys +from os.path import isdir # This file defines how to build a particular configuration of M5 # based on variable settings in the 'env' build environment. @@ -187,6 +188,9 @@ base_sources = Split(''' mem/trace/mem_trace_writer.cc mem/trace/m5_writer.cc + python/pyconfig.cc + python/embedded_py.cc + sim/builder.cc sim/configfile.cc sim/debug.cc @@ -203,8 +207,6 @@ base_sources = Split(''' sim/stat_control.cc sim/trace_context.cc sim/universe.cc - sim/pyconfig/pyconfig.cc - sim/pyconfig/embedded_py.cc ''') # MySql sources @@ -340,18 +342,17 @@ else: extra_libraries = [] env.Append(LIBS=['z']) -if env['USE_MYSQL']: +if isdir('/usr/lib64/mysql') or isdir('/usr/lib/mysql') or \ + isdir('/usr/local/lib/mysql'): + print 'Compiling with MySQL support!' + env.Append(LIBPATH=['/usr/lib64/mysql', '/usr/local/lib/mysql/', + '/usr/lib/mysql']) + env.Append(CPPPATH=['/usr/local/include/mysql', '/usr/include/mysql']) sources += mysql_sources env.Append(CPPDEFINES = 'USE_MYSQL') env.Append(CPPDEFINES = 'STATS_BINNING') - env.Append(CPPPATH=['/usr/local/include/mysql', '/usr/include/mysql']) - if os.path.isdir('/usr/lib64'): - env.Append(LIBPATH=['/usr/lib64/mysql']) - else: - env.Append(LIBPATH=['/usr/lib/mysql/']) env.Append(LIBS=['mysqlclient']) - ################################################### # # Special build rules. @@ -380,8 +381,8 @@ env.Command(Split('''arch/alpha/decoder.cc # SConscript-local is the per-config build, which just copies some # header files into a place where they can be found. SConscript('libelf/SConscript-local', exports = 'env', duplicate=0) -SConscript('sim/pyconfig/SConscript', exports = ['env'], duplicate=0) - +SConscript('python/SConscript', exports = ['env'], duplicate=0) +SConscript('simobj/SConscript', exports = 'env', duplicate=0) # This function adds the specified sources to the given build # environment, and returns a list of all the corresponding SCons diff --git a/arch/alpha/alpha_linux_process.cc b/arch/alpha/alpha_linux_process.cc index ba4b1d07e..600de4447 100644 --- a/arch/alpha/alpha_linux_process.cc +++ b/arch/alpha/alpha_linux_process.cc @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2004 The Regents of The University of Michigan + * Copyright (c) 2003-2005 The Regents of The University of Michigan * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -232,7 +232,7 @@ class Linux { static const char *hostname; /// Target uname() handler. - static int + static SyscallReturn unameFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -251,7 +251,7 @@ class Linux { /// Target osf_getsysyinfo() handler. Even though this call is /// borrowed from Tru64, the subcases that get used appear to be /// different in practice from those used by Tru64 processes. - static int + static SyscallReturn osf_getsysinfoFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -278,7 +278,7 @@ class Linux { } /// Target osf_setsysinfo() handler. - static int + static SyscallReturn osf_setsysinfoFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -306,7 +306,7 @@ class Linux { } /// Target fnctl() handler. - static int + static SyscallReturn fcntlFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { diff --git a/arch/alpha/alpha_tru64_process.cc b/arch/alpha/alpha_tru64_process.cc index 149569f14..441e7c89f 100644 --- a/arch/alpha/alpha_tru64_process.cc +++ b/arch/alpha/alpha_tru64_process.cc @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001-2004 The Regents of The University of Michigan + * Copyright (c) 2001-2005 The Regents of The University of Michigan * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -476,7 +476,7 @@ class Tru64 { static const char *hostname; /// Target uname() handler. - static int + static SyscallReturn unameFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -494,7 +494,7 @@ class Tru64 { /// Target getsysyinfo() handler. - static int + static SyscallReturn getsysinfoFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -574,7 +574,7 @@ class Tru64 { } /// Target fnctl() handler. - static int + static SyscallReturn fcntlFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -618,7 +618,7 @@ class Tru64 { /// Target getdirentries() handler. - static int + static SyscallReturn getdirentriesFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -669,11 +669,11 @@ class Tru64 { *basep = host_basep; basep.copyOut(xc->mem); - return (tgt_buf_ptr - tgt_buf); + return tgt_buf_ptr - tgt_buf; } /// Target sigreturn() handler. - static int + static SyscallReturn sigreturnFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -699,7 +699,7 @@ class Tru64 { } /// Target table() handler. - static int + static SyscallReturn tableFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -716,7 +716,7 @@ class Tru64 { TypedBufferArg<Tru64::tbl_sysinfo> elp(xc->getSyscallArg(2)); const int clk_hz = one_million; - elp->si_user = curTick / (ticksPerSecond / clk_hz); + elp->si_user = curTick / (Clock::Frequency / clk_hz); elp->si_nice = 0; elp->si_sys = 0; elp->si_idle = 0; @@ -749,7 +749,7 @@ class Tru64 { // /// Create a stack region for a thread. - static int + static SyscallReturn stack_createFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -776,7 +776,7 @@ class Tru64 { /// This call sets up the interface between the user and kernel /// schedulers by creating a shared-memory region. The shared memory /// region has several structs, some global, some per-RAD, some per-VP. - static int + static SyscallReturn nxm_task_initFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -877,6 +877,10 @@ class Tru64 { *configptr_ptr = config_addr; configptr_ptr.copyOut(xc->mem); + // Register this as a valid address range with the process + process->nxm_start = base_addr; + process->nxm_end = cur_addr; + return 0; } @@ -899,7 +903,7 @@ class Tru64 { } /// Create thread. - static int + static SyscallReturn nxm_thread_createFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -953,7 +957,7 @@ class Tru64 { Tru64::nxm_sched_state *ssp = &rad_state->nxm_ss[thread_index]; if (ssp->nxm_u.nxm_active != 0) - return Tru64::KERN_NOT_RECEIVER; + return (int) Tru64::KERN_NOT_RECEIVER; ssp->nxm_u.pth_id = attrp->pthid; ssp->nxm_u.nxm_active = uniq_val | 1; @@ -1011,7 +1015,7 @@ class Tru64 { } /// Thread idle call (like yield()). - static int + static SyscallReturn nxm_idleFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1019,7 +1023,7 @@ class Tru64 { } /// Block thread. - static int + static SyscallReturn nxm_thread_blockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1036,7 +1040,7 @@ class Tru64 { } /// block. - static int + static SyscallReturn nxm_blockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1057,7 +1061,7 @@ class Tru64 { } /// Unblock thread. - static int + static SyscallReturn nxm_unblockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1070,7 +1074,7 @@ class Tru64 { } /// Switch thread priority. - static int + static SyscallReturn swtch_priFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1081,7 +1085,7 @@ class Tru64 { // // Since we assume at most one "kernel" thread per CPU, it's // always safe to return false here. - return false; + return 0; //false; } @@ -1154,7 +1158,7 @@ class Tru64 { } /// Lock acquire syscall handler. - static int + static SyscallReturn m5_mutex_lockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1169,7 +1173,7 @@ class Tru64 { } /// Try lock (non-blocking). - static int + static SyscallReturn m5_mutex_trylockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1189,7 +1193,7 @@ class Tru64 { } /// Unlock syscall handler. - static int + static SyscallReturn m5_mutex_unlockFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1201,7 +1205,7 @@ class Tru64 { } /// Signal ocndition. - static int + static SyscallReturn m5_cond_signalFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1214,7 +1218,7 @@ class Tru64 { } /// Wake up all processes waiting on the condition variable. - static int + static SyscallReturn m5_cond_broadcastFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1226,7 +1230,7 @@ class Tru64 { } /// Wait on a condition. - static int + static SyscallReturn m5_cond_waitFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1248,7 +1252,7 @@ class Tru64 { } /// Thread exit. - static int + static SyscallReturn m5_thread_exitFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -1291,7 +1295,7 @@ class Tru64 { } /// Indirect syscall invocation (call #0). - static int + static SyscallReturn indirectSyscallFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { diff --git a/arch/alpha/isa_traits.hh b/arch/alpha/isa_traits.hh index 8db8c6994..9327fa88b 100644 --- a/arch/alpha/isa_traits.hh +++ b/arch/alpha/isa_traits.hh @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2004 The Regents of The University of Michigan + * Copyright (c) 2003-2005 The Regents of The University of Michigan * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -286,6 +286,43 @@ const int ArgumentReg1 = TheISA::ArgumentReg1; const int BranchPredAddrShiftAmt = TheISA::BranchPredAddrShiftAmt; const int MaxAddr = (Addr)-1; +#ifndef FULL_SYSTEM +class SyscallReturn { + public: + template <class T> + SyscallReturn(T v, bool s) + { + retval = (uint64_t)v; + success = s; + } + + template <class T> + SyscallReturn(T v) + { + success = (v >= 0); + retval = (uint64_t)v; + } + + ~SyscallReturn() {} + + SyscallReturn& operator=(const SyscallReturn& s) { + retval = s.retval; + success = s.success; + return *this; + } + + bool successful() { return success; } + uint64_t value() { return retval; } + + + private: + uint64_t retval; + bool success; +}; + +#endif + + #ifdef FULL_SYSTEM typedef TheISA::InternalProcReg InternalProcReg; const int NumInternalProcRegs = TheISA::NumInternalProcRegs; diff --git a/arch/alpha/pseudo_inst.cc b/arch/alpha/pseudo_inst.cc index 22d65638b..3c3b37928 100644 --- a/arch/alpha/pseudo_inst.cc +++ b/arch/alpha/pseudo_inst.cc @@ -95,7 +95,7 @@ namespace AlphaPseudo m5exit(ExecContext *xc) { Tick delay = xc->regs.intRegFile[16]; - Tick when = curTick + NS2Ticks(delay); + Tick when = curTick + delay * Clock::Int::ns; SimExit(when, "m5_exit instruction encountered"); } @@ -108,8 +108,8 @@ namespace AlphaPseudo Tick delay = xc->regs.intRegFile[16]; Tick period = xc->regs.intRegFile[17]; - Tick when = curTick + NS2Ticks(delay); - Tick repeat = NS2Ticks(period); + Tick when = curTick + delay * Clock::Int::ns; + Tick repeat = period * Clock::Int::ns; using namespace Stats; SetupEvent(Reset, when, repeat); @@ -124,8 +124,8 @@ namespace AlphaPseudo Tick delay = xc->regs.intRegFile[16]; Tick period = xc->regs.intRegFile[17]; - Tick when = curTick + NS2Ticks(delay); - Tick repeat = NS2Ticks(period); + Tick when = curTick + delay * Clock::Int::ns; + Tick repeat = period * Clock::Int::ns; using namespace Stats; SetupEvent(Dump, when, repeat); @@ -140,8 +140,8 @@ namespace AlphaPseudo Tick delay = xc->regs.intRegFile[16]; Tick period = xc->regs.intRegFile[17]; - Tick when = curTick + NS2Ticks(delay); - Tick repeat = NS2Ticks(period); + Tick when = curTick + delay * Clock::Int::ns; + Tick repeat = period * Clock::Int::ns; using namespace Stats; SetupEvent(Dump|Reset, when, repeat); @@ -156,8 +156,8 @@ namespace AlphaPseudo Tick delay = xc->regs.intRegFile[16]; Tick period = xc->regs.intRegFile[17]; - Tick when = curTick + NS2Ticks(delay); - Tick repeat = NS2Ticks(period); + Tick when = curTick + delay * Clock::Int::ns; + Tick repeat = period * Clock::Int::ns; Checkpoint::setup(when, repeat); } diff --git a/build/SConstruct b/build/SConstruct index 3d7db1db2..28cb77762 100644 --- a/build/SConstruct +++ b/build/SConstruct @@ -62,6 +62,9 @@ if not os.path.isdir('ext'): % EXT_SRCDIR sys.exit(1) +# tell python where to find m5 python code +sys.path.append(os.path.join(SRCDIR, 'python')) + ################################################### # @@ -101,23 +104,12 @@ configs_map = { 'KERNEL' : KernelConfig } -# Enable detailed full-system binning. -def MeasureOpt(env): - env.Replace(USE_MYSQL = True) - env.Append(CPPDEFINES = 'FS_MEASURE') - -# Enable MySql database output for stats. -def MySqlOpt(env): - env.Replace(USE_MYSQL = True) - # Disable FastAlloc object allocation. def NoFastAllocOpt(env): env.Append(CPPDEFINES = 'NO_FAST_ALLOC') # Configuration options map. options_map = { - 'MEASURE' : MeasureOpt, - 'MYSQL' : MySqlOpt, 'NO_FAST_ALLOC' : NoFastAllocOpt } @@ -289,7 +281,7 @@ for build_dir in build_dirs: ################################################### # # Let SCons do its thing. At this point SCons will use the defined -# build enviornments to build the requested targets. +# build environments to build the requested targets. # ################################################### diff --git a/configs/boot/micro_ctx.rcS b/configs/boot/micro_ctx.rcS new file mode 100644 index 000000000..4d1c5bcf7 --- /dev/null +++ b/configs/boot/micro_ctx.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_ctx 2 4 8 16 +m5 exit + diff --git a/configs/boot/micro_memlat2mb.rcS b/configs/boot/micro_memlat2mb.rcS new file mode 100644 index 000000000..12643c629 --- /dev/null +++ b/configs/boot/micro_memlat2mb.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_mem_rd_2MB 2 64 +m5 exit + diff --git a/configs/boot/micro_memlat8.rcS b/configs/boot/micro_memlat8.rcS new file mode 100644 index 000000000..c831c2b75 --- /dev/null +++ b/configs/boot/micro_memlat8.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_mem_rd 128 8 +m5 exit + diff --git a/configs/boot/micro_memlat8mb.rcS b/configs/boot/micro_memlat8mb.rcS new file mode 100644 index 000000000..1688a6452 --- /dev/null +++ b/configs/boot/micro_memlat8mb.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_mem_rd_8MB 8 64 +m5 exit + diff --git a/configs/boot/micro_stream.rcS b/configs/boot/micro_stream.rcS new file mode 100644 index 000000000..7b4c445c6 --- /dev/null +++ b/configs/boot/micro_stream.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/stream +m5 exit + diff --git a/configs/boot/micro_streamcopy.rcS b/configs/boot/micro_streamcopy.rcS new file mode 100644 index 000000000..820e84031 --- /dev/null +++ b/configs/boot/micro_streamcopy.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/simstreamcopy +m5 exit + diff --git a/configs/boot/micro_streamscale.rcS b/configs/boot/micro_streamscale.rcS new file mode 100644 index 000000000..005da8d65 --- /dev/null +++ b/configs/boot/micro_streamscale.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/simstreamscale +m5 exit + diff --git a/configs/boot/micro_syscall.rcS b/configs/boot/micro_syscall.rcS index 0e8e209c1..f954becc3 100644 --- a/configs/boot/micro_syscall.rcS +++ b/configs/boot/micro_syscall.rcS @@ -1,3 +1,3 @@ -/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_syscall null +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_syscall read m5 exit diff --git a/configs/boot/micro_tlblat.rcS b/configs/boot/micro_tlblat.rcS new file mode 100644 index 000000000..ab05fd9ff --- /dev/null +++ b/configs/boot/micro_tlblat.rcS @@ -0,0 +1,3 @@ +/benchmarks/micros/lmbench/bin/alphaev6-linux-gnu/lat_mem_rd_2MB 2 8192 +m5 exit + diff --git a/configs/boot/nat-netperf-maerts-client.rcS b/configs/boot/nat-netperf-maerts-client.rcS index ab9fd8c4e..ab66b7d4a 100644 --- a/configs/boot/nat-netperf-maerts-client.rcS +++ b/configs/boot/nat-netperf-maerts-client.rcS @@ -22,7 +22,7 @@ echo "262143" > /proc/sys/net/core/wmem_default echo "262143" > /proc/sys/net/core/optmem_max echo "100000" > /proc/sys/net/core/netdev_max_backlog -echo -n "waiting for server..." +echo -n "waiting for natbox..." /usr/bin/netcat -c -l -p 8000 BINARY=/benchmarks/netperf/netperf diff --git a/configs/boot/nat-netperf-server.rcS b/configs/boot/nat-netperf-server.rcS index 5b094b790..69717b7ce 100644 --- a/configs/boot/nat-netperf-server.rcS +++ b/configs/boot/nat-netperf-server.rcS @@ -23,7 +23,8 @@ echo "100000" > /proc/sys/net/core/netdev_max_backlog echo "running netserver..." /benchmarks/netperf/netserver -echo -n "signal client to begin..." +echo -n "signal natbox to begin..." +sleep 1 echo "server ready" | /usr/bin/netcat -c $NATBOX 8000 echo "done." diff --git a/configs/boot/nfs-client-nhfsstone.rcS b/configs/boot/nfs-client-nhfsstone.rcS new file mode 100755 index 000000000..229e418d8 --- /dev/null +++ b/configs/boot/nfs-client-nhfsstone.rcS @@ -0,0 +1,50 @@ +#!/bin/sh +# +# /etc/init.d/rcS +# + +echo -n "mounting swap..." +/sbin/swapon /dev/hdc +echo "done." + +echo -n "setting up network..." +/sbin/ifconfig eth0 10.0.0.2 txqueuelen 1000 +/sbin/ifconfig lo 127.0.0.1 + +echo "1" > /proc/sys/net/ipv4/tcp_tw_recycle +echo "1" > /proc/sys/net/ipv4/tcp_tw_reuse +echo "1" > /proc/sys/net/ipv4/tcp_window_scaling +echo "0" > /proc/sys/net/ipv4/tcp_timestamps +echo "0" > /proc/sys/net/ipv4/tcp_sack +echo "15" > /proc/sys/net/ipv4/tcp_fin_timeout +echo "16384" > /proc/sys/net/ipv4/tcp_max_syn_backlog + +echo "1024 65535" > /proc/sys/net/ipv4/ip_local_port_range +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_rmem +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_wmem +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_mem + +echo "524287" > /proc/sys/net/core/rmem_max +echo "524287" > /proc/sys/net/core/wmem_max +echo "524287" > /proc/sys/net/core/optmem_max +echo "300000" > /proc/sys/net/core/netdev_max_backlog + +echo "131072" > /proc/sys/fs/file-max +echo "done." + +echo -n "starting nfs client..." +/sbin/portmap & +/sbin/lockd & +echo "done." + +echo -n "waiting for server..." +/usr/bin/netcat -c -l -p 8000 + +echo -n "mounting remote share..." +mkdir /nfs +mount 10.0.0.1:/nfs /nfs +echo "done." + +/benchmarks/nhfsstone/nhfsstone -t 30 -p 10 /nfs + +/sbin/m5 exit diff --git a/configs/boot/nfs-client.rcS b/configs/boot/nfs-client.rcS index a999fb72c..84d15439f 100755 --- a/configs/boot/nfs-client.rcS +++ b/configs/boot/nfs-client.rcS @@ -45,6 +45,6 @@ mkdir /nfs mount 10.0.0.1:/nfs /nfs echo "done." -/bin/bonnie++ -u 99 -s 700 -r 0 -n 0 -f -F -d /nfs +/bin/bonnie++ -u 99 -s 500 -r 0 -n 0 -f -F -d /nfs /sbin/m5 exit diff --git a/configs/boot/nfs-server-nhfsstone.rcS b/configs/boot/nfs-server-nhfsstone.rcS new file mode 100755 index 000000000..564833cb1 --- /dev/null +++ b/configs/boot/nfs-server-nhfsstone.rcS @@ -0,0 +1,67 @@ +#!/bin/sh +# +# /etc/init.d/rcS +# + +echo -n "mounting swap..." +/sbin/swapon /dev/hdc +echo "done." + +echo -n "setting up network..." +/sbin/ifconfig eth0 10.0.0.1 txqueuelen 1000 +/sbin/ifconfig lo 127.0.0.1 + +echo "1" > /proc/sys/net/ipv4/tcp_tw_recycle +echo "1" > /proc/sys/net/ipv4/tcp_tw_reuse +echo "1" > /proc/sys/net/ipv4/tcp_window_scaling +echo "0" > /proc/sys/net/ipv4/tcp_timestamps +echo "0" > /proc/sys/net/ipv4/tcp_sack +echo "15" > /proc/sys/net/ipv4/tcp_fin_timeout +echo "16384" > /proc/sys/net/ipv4/tcp_max_syn_backlog + +echo "1024 65535" > /proc/sys/net/ipv4/ip_local_port_range +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_rmem +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_wmem +echo "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_mem + +echo "524287" > /proc/sys/net/core/rmem_max +echo "524287" > /proc/sys/net/core/wmem_max +echo "524287" > /proc/sys/net/core/optmem_max +echo "300000" > /proc/sys/net/core/netdev_max_backlog + +echo "131072" > /proc/sys/fs/file-max +echo "done." + +#if [ ! -x /dev/sda ] +#then +# mknod /dev/sda b 8 0 +# mknod /dev/sda1 b 8 1 +#fi + +/sbin/insmod /modules/scsi_debug.ko dev_size_mb=80 + +echo -n "creating partition and formatting..." +/sbin/mke2fs -F /dev/sda +mkdir /nfs +/bin/mount /dev/sda /nfs +chmod a+rwx /nfs +echo "done." + +echo "/nfs 10.0.0.0/255.0.0.0(rw,sync,no_root_squash)" > /etc/exports +echo -n "starting nfs kernel server..." +/sbin/portmap +/sbin/lockd +/sbin/statd +/sbin/nfsd 8 +/sbin/mountd +echo "done." + +echo "Exporting shares..." +/sbin/exportfs -r -v + +echo -n "signal client to mount..." +echo "server ready" | /usr/bin/netcat -c 10.0.0.2 8000 +echo "done." + +echo -n "starting bash shell..." +/bin/bash diff --git a/configs/boot/nfs-server.rcS b/configs/boot/nfs-server.rcS index 21b7ab83c..0cb489a9d 100755 --- a/configs/boot/nfs-server.rcS +++ b/configs/boot/nfs-server.rcS @@ -38,7 +38,7 @@ echo "done." # mknod /dev/sda1 b 8 1 #fi -/sbin/insmod /modules/scsi_debug.ko dev_size_mb=768 +/sbin/insmod /modules/scsi_debug.ko dev_size_mb=512 echo -n "creating partition and formatting..." #echo "1,767,L" > /tmp/sfdisk.run diff --git a/configs/boot/ping-client.rcS b/configs/boot/ping-client.rcS new file mode 100644 index 000000000..3f0ded75e --- /dev/null +++ b/configs/boot/ping-client.rcS @@ -0,0 +1,25 @@ +#!/bin/sh +SERVER=10.0.0.1 +CLIENT=10.0.0.2 + +echo "setting up network..." +ifconfig lo 127.0.0.1 +ifconfig eth0 $CLIENT txqueuelen 1000 + +echo "0" > /proc/sys/net/ipv4/tcp_timestamps +echo "0" > /proc/sys/net/ipv4/tcp_sack +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_rmem +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_wmem +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_mem +echo "262143" > /proc/sys/net/core/rmem_max +echo "262143" > /proc/sys/net/core/wmem_max +echo "262143" > /proc/sys/net/core/rmem_default +echo "262143" > /proc/sys/net/core/wmem_default +echo "262143" > /proc/sys/net/core/optmem_max +echo "100000" > /proc/sys/net/core/netdev_max_backlog + +echo -n "waiting for server..." +/usr/bin/netcat -c -l -p 8000 + +ping $SERVER +/sbin/m5 exit diff --git a/configs/boot/ping-server.rcS b/configs/boot/ping-server.rcS new file mode 100644 index 000000000..5dab6effb --- /dev/null +++ b/configs/boot/ping-server.rcS @@ -0,0 +1,26 @@ +#!/bin/sh +SERVER=10.0.0.1 +CLIENT=10.0.0.2 + +echo "setting up network..." +ifconfig lo 127.0.0.1 +ifconfig eth0 $SERVER txqueuelen 1000 + +echo "0" > /proc/sys/net/ipv4/tcp_timestamps +echo "0" > /proc/sys/net/ipv4/tcp_sack +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_rmem +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_wmem +echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_mem +echo "262143" > /proc/sys/net/core/rmem_max +echo "262143" > /proc/sys/net/core/wmem_max +echo "262143" > /proc/sys/net/core/rmem_default +echo "262143" > /proc/sys/net/core/wmem_default +echo "262143" > /proc/sys/net/core/optmem_max +echo "100000" > /proc/sys/net/core/netdev_max_backlog + +echo -n "signal client to begin..." +echo "server ready" | /usr/bin/netcat -c $CLIENT 8000 +echo "done." + +echo "starting bash..." +exec /bin/bash diff --git a/configs/splash2/run.mpy b/configs/splash2/run.mpy new file mode 100644 index 000000000..800bff6f8 --- /dev/null +++ b/configs/splash2/run.mpy @@ -0,0 +1,50 @@ +import Splash2 + +if 'SYSTEM' not in env: + panic("The SYSTEM environment variable must be set!\ne.g -ESYSTEM=Detailed\n") + +if env['SYSTEM'] == 'Simple': + from SimpleConfig import * + BaseCPU.workload = parent.workload + SimpleStandAlone.cpu = [ CPU() for i in xrange(int(env['NP'])) ] + root = SimpleStandAlone +elif env['SYSTEM'] == 'Detailed': + from DetailedConfig import * + BaseCPU.workload = parent.workload + DetailedStandAlone.cpu = [ DetailedCPU() for i in xrange(int(env['NP'])) ] + root = DetailedStandAlone +else: + panic("The SYSTEM environment variable was set to something improper.\n Use Simple or Detailed\n") + +if 'BENCHMARK' not in env: + panic("The BENCHMARK environment variable must be set!\ne.g. -EBENCHMARK=Cholesky\n") + +if env['BENCHMARK'] == 'Cholesky': + root.workload = Splash2.Cholesky() +elif env['BENCHMARK'] == 'FFT': + root.workload = Splash2.FFT() +elif env['BENCHMARK'] == 'LUContig': + root.workload = Splash2.LU_contig() +elif env['BENCHMARK'] == 'LUNoncontig': + root.workload = Splash2.LU_noncontig() +elif env['BENCHMARK'] == 'Radix': + root.workload = Splash2.Radix() +elif env['BENCHMARK'] == 'Barnes': + root.workload = Splash2.Barnes() +elif env['BENCHMARK'] == 'FMM': + root.workload = Splash2.FMM() +elif env['BENCHMARK'] == 'OceanContig': + root.workload = Splash2.Ocean_contig() +elif env['BENCHMARK'] == 'OceanNoncontig': + root.workload = Splash2.Ocean_noncontig() +elif env['BENCHMARK'] == 'Raytrace': + root.workload = Splash2.Raytrace() +elif env['BENCHMARK'] == 'WaterNSquared': + root.workload = Splash2.Water_nsquared() +elif env['BENCHMARK'] == 'WaterSpatial': + root.workload = Splash2.Water_spatial() +else: + panic("The BENCHMARK environment variable was set to something" \ + +" improper.\nUse Cholesky, FFT, LUContig, LUNoncontig, Radix" \ + +", Barnes, FMM, OceanContig,\nOceanNoncontig, Raytrace," \ + +" WaterNSquared, or WaterSpatial\n") diff --git a/cpu/base_cpu.cc b/cpu/base_cpu.cc index a17edd371..74e57baa6 100644 --- a/cpu/base_cpu.cc +++ b/cpu/base_cpu.cc @@ -36,6 +36,7 @@ #include "base/output.hh" #include "cpu/base_cpu.hh" #include "cpu/exec_context.hh" +#include "cpu/sampling_cpu/sampling_cpu.hh" #include "sim/param.hh" #include "sim/sim_events.hh" @@ -194,9 +195,9 @@ BaseCPU::registerExecContexts() void -BaseCPU::switchOut() +BaseCPU::switchOut(SamplingCPU *sampler) { - // default: do nothing + panic("This CPU doesn't support sampling!"); } void diff --git a/cpu/base_cpu.hh b/cpu/base_cpu.hh index dd1c7ac58..f346f4ec5 100644 --- a/cpu/base_cpu.hh +++ b/cpu/base_cpu.hh @@ -32,6 +32,7 @@ #include <vector> #include "base/statistics.hh" +#include "cpu/sampling_cpu/sampling_cpu.hh" #include "sim/eventq.hh" #include "sim/sim_object.hh" #include "targetarch/isa_traits.hh" @@ -117,9 +118,9 @@ class BaseCPU : public SimObject void registerExecContexts(); - /// Prepare for another CPU to take over execution. Called by - /// takeOverFrom() on its argument. - virtual void switchOut(); + /// Prepare for another CPU to take over execution. When it is + /// is ready (drained pipe) it signals the sampler. + virtual void switchOut(SamplingCPU *); /// Take over execution from the given CPU. Used for warm-up and /// sampling. diff --git a/cpu/exec_context.hh b/cpu/exec_context.hh index 8437a5585..d6140d52f 100644 --- a/cpu/exec_context.hh +++ b/cpu/exec_context.hh @@ -435,20 +435,20 @@ class ExecContext regs.intRegFile[ArgumentReg0 + i] = val; } - void setSyscallReturn(int64_t return_value) + void setSyscallReturn(SyscallReturn return_value) { // check for error condition. Alpha syscall convention is to // indicate success/failure in reg a3 (r19) and put the // return value itself in the standard return value reg (v0). const int RegA3 = 19; // only place this is used - if (return_value >= 0) { + if (return_value.successful()) { // no error regs.intRegFile[RegA3] = 0; - regs.intRegFile[ReturnValueReg] = return_value; + regs.intRegFile[ReturnValueReg] = return_value.value(); } else { // got an error, return details regs.intRegFile[RegA3] = (IntReg) -1; - regs.intRegFile[ReturnValueReg] = -return_value; + regs.intRegFile[ReturnValueReg] = -return_value.value(); } } diff --git a/cpu/pc_event.cc b/cpu/pc_event.cc index 8f046a7a4..21eef677a 100644 --- a/cpu/pc_event.cc +++ b/cpu/pc_event.cc @@ -31,10 +31,11 @@ #include <string> #include <utility> -#include "sim/debug.hh" +#include "base/trace.hh" +#include "cpu/base_cpu.hh" #include "cpu/exec_context.hh" #include "cpu/pc_event.hh" -#include "base/trace.hh" +#include "sim/debug.hh" #include "sim/universe.hh" using namespace std; @@ -123,6 +124,8 @@ BreakPCEvent::BreakPCEvent(PCEventQueue *q, const std::string &desc, bool del) void BreakPCEvent::process(ExecContext *xc) { + StringWrap name(xc->cpu->name() + ".break_event"); + DPRINTFN("break event %s triggered", descr()); debug_break(); if (remove) delete this; diff --git a/cpu/simple_cpu/simple_cpu.cc b/cpu/simple_cpu/simple_cpu.cc index 044ee9b9d..6a95a52c2 100644 --- a/cpu/simple_cpu/simple_cpu.cc +++ b/cpu/simple_cpu/simple_cpu.cc @@ -47,6 +47,7 @@ #include "cpu/exec_context.hh" #include "cpu/exetrace.hh" #include "cpu/full_cpu/smt.hh" +#include "cpu/sampling_cpu/sampling_cpu.hh" #include "cpu/simple_cpu/simple_cpu.hh" #include "cpu/static_inst.hh" #include "mem/base_mem.hh" @@ -149,11 +150,21 @@ SimpleCPU::~SimpleCPU() } void -SimpleCPU::switchOut() +SimpleCPU::switchOut(SamplingCPU *s) { - _status = SwitchedOut; - if (tickEvent.scheduled()) - tickEvent.squash(); + sampler = s; + if (status() == DcacheMissStall) { + DPRINTF(Sampler,"Outstanding dcache access, waiting for completion\n"); + _status = DcacheMissSwitch; + } + else { + _status = SwitchedOut; + + if (tickEvent.scheduled()) + tickEvent.squash(); + + sampler->signalSwitched(); + } } @@ -173,8 +184,6 @@ SimpleCPU::takeOverFrom(BaseCPU *oldCPU) tickEvent.schedule(curTick); } } - - oldCPU->switchOut(); } @@ -384,21 +393,20 @@ template <class T> Fault SimpleCPU::read(Addr addr, T &data, unsigned flags) { + if (status() == DcacheMissStall || status() == DcacheMissSwitch) { + Fault fault = xc->read(memReq,data); + + if (traceData) { + traceData->setAddr(addr); + } + return fault; + } + memReq->reset(addr, sizeof(T), flags); // translate to physical address Fault fault = xc->translateDataReadReq(memReq); - // do functional access - if (fault == No_Fault) - fault = xc->read(memReq, data); - - if (traceData) { - traceData->setAddr(addr); - if (fault == No_Fault) - traceData->setData(data); - } - // if we have a cache, do cache access too if (fault == No_Fault && dcacheInterface) { memReq->cmd = Read; @@ -414,7 +422,15 @@ SimpleCPU::read(Addr addr, T &data, unsigned flags) lastDcacheStall = curTick; unscheduleTickEvent(); _status = DcacheMissStall; + } else { + // do functional access + fault = xc->read(memReq, data); + } + } else if(fault == No_Fault) { + // do functional access + fault = xc->read(memReq, data); + } if (!dcacheInterface && (memReq->flags & UNCACHEABLE)) @@ -470,11 +486,6 @@ template <class T> Fault SimpleCPU::write(T data, Addr addr, unsigned flags, uint64_t *res) { - if (traceData) { - traceData->setAddr(addr); - traceData->setData(data); - } - memReq->reset(addr, sizeof(T), flags); // translate to physical address @@ -575,10 +586,23 @@ SimpleCPU::processCacheCompletion() scheduleTickEvent(1); break; case DcacheMissStall: + if (memReq->cmd.isRead()) { + curStaticInst->execute(this,traceData); + if (traceData) + traceData->finalize(); + } dcacheStallCycles += curTick - lastDcacheStall; _status = Running; scheduleTickEvent(1); break; + case DcacheMissSwitch: + if (memReq->cmd.isRead()) { + curStaticInst->execute(this,traceData); + if (traceData) + traceData->finalize(); + } + _status = SwitchedOut; + sampler->signalSwitched(); case SwitchedOut: // If this CPU has been switched out due to sampling/warm-up, // ignore any further status changes (e.g., due to cache @@ -720,10 +744,10 @@ SimpleCPU::tick() comInstEventQueue[0]->serviceEvents(numInst); // decode the instruction - inst = htoa(inst); - StaticInstPtr<TheISA> si(inst); + inst = htoa(inst); + curStaticInst = StaticInst<TheISA>::decode(inst); - traceData = Trace::getInstRecord(curTick, xc, this, si, + traceData = Trace::getInstRecord(curTick, xc, this, curStaticInst, xc->regs.pc); #ifdef FULL_SYSTEM @@ -732,24 +756,28 @@ SimpleCPU::tick() xc->func_exe_inst++; - fault = si->execute(this, traceData); + fault = curStaticInst->execute(this, traceData); #ifdef FULL_SYSTEM if (xc->fnbin) - xc->execute(si.get()); + xc->execute(curStaticInst.get()); #endif - if (si->isMemRef()) { + if (curStaticInst->isMemRef()) { numMemRefs++; } - if (si->isLoad()) { + if (curStaticInst->isLoad()) { ++numLoad; comLoadEventQueue[0]->serviceEvents(numLoad); } - if (traceData) + // If we have a dcache miss, then we can't finialize the instruction + // trace yet because we want to populate it with the data later + if (traceData && + !(status() == DcacheMissStall && memReq->cmd.isRead())) { traceData->finalize(); + } traceFunctions(xc->regs.pc); diff --git a/cpu/simple_cpu/simple_cpu.hh b/cpu/simple_cpu/simple_cpu.hh index c802a1c06..f245a7bba 100644 --- a/cpu/simple_cpu/simple_cpu.hh +++ b/cpu/simple_cpu/simple_cpu.hh @@ -33,6 +33,7 @@ #include "cpu/base_cpu.hh" #include "cpu/exec_context.hh" #include "cpu/pc_event.hh" +#include "cpu/sampling_cpu/sampling_cpu.hh" #include "cpu/static_inst.hh" #include "sim/eventq.hh" @@ -105,6 +106,7 @@ class SimpleCPU : public BaseCPU IcacheMissStall, IcacheMissComplete, DcacheMissStall, + DcacheMissSwitch, SwitchedOut }; @@ -143,7 +145,7 @@ class SimpleCPU : public BaseCPU // execution context ExecContext *xc; - void switchOut(); + void switchOut(SamplingCPU *s); void takeOverFrom(BaseCPU *oldCPU); #ifdef FULL_SYSTEM @@ -164,6 +166,13 @@ class SimpleCPU : public BaseCPU // Refcounted pointer to the one memory request. MemReqPtr memReq; + // Pointer to the sampler that is telling us to switchover. + // Used to signal the completion of the pipe drain and schedule + // the next switchover + SamplingCPU *sampler; + + StaticInstPtr<TheISA> curStaticInst; + class CacheCompletionEvent : public Event { private: diff --git a/dev/etherdump.cc b/dev/etherdump.cc index 3de417bdc..39b94f923 100644 --- a/dev/etherdump.cc +++ b/dev/etherdump.cc @@ -74,9 +74,6 @@ void EtherDump::init() { curtime = time(NULL); - s_freq = ticksPerSecond; - us_freq = ticksPerSecond / ULL(1000000); - struct pcap_file_header hdr; hdr.magic = TCPDUMP_MAGIC; hdr.version_major = PCAP_VERSION_MAJOR; @@ -108,8 +105,8 @@ void EtherDump::dumpPacket(PacketPtr &packet) { pcap_pkthdr pkthdr; - pkthdr.seconds = curtime + (curTick / s_freq); - pkthdr.microseconds = (curTick / us_freq) % ULL(1000000); + pkthdr.seconds = curtime + (curTick / Clock::Int::s); + pkthdr.microseconds = (curTick / Clock::Int::us) % ULL(1000000); pkthdr.caplen = std::min(packet->length, maxlen); pkthdr.len = packet->length; stream.write(reinterpret_cast<char *>(&pkthdr), sizeof(pkthdr)); diff --git a/dev/etherdump.hh b/dev/etherdump.hh index ba15796c8..1296ebb10 100644 --- a/dev/etherdump.hh +++ b/dev/etherdump.hh @@ -49,8 +49,6 @@ class EtherDump : public SimObject void init(); Tick curtime; - Tick s_freq; - Tick us_freq; public: EtherDump(const std::string &name, const std::string &file, int max); diff --git a/dev/etherlink.cc b/dev/etherlink.cc index 0acc50b0b..ba0fa705c 100644 --- a/dev/etherlink.cc +++ b/dev/etherlink.cc @@ -47,32 +47,32 @@ using namespace std; -EtherLink::EtherLink(const string &name, EtherInt *i1, EtherInt *i2, +EtherLink::EtherLink(const string &name, EtherInt *peer0, EtherInt *peer1, Tick speed, Tick dly, EtherDump *dump) : SimObject(name) { double rate = ((double)ticksPerSecond * 8.0) / (double)speed; - Tick delay = US2Ticks(dly); + Tick delay = dly * Clock::Int::us; - link1 = new Link(name + ".link1", rate, delay, dump); - link2 = new Link(name + ".link2", rate, delay, dump); + link[0] = new Link(name + ".link0", this, 0, rate, delay, dump); + link[1] = new Link(name + ".link1", this, 1, rate, delay, dump); - int1 = new Interface(name + ".int1", link1, link2); - int2 = new Interface(name + ".int2", link2, link1); + interface[0] = new Interface(name + ".int0", link[0], link[1]); + interface[1] = new Interface(name + ".int1", link[1], link[0]); - int1->setPeer(i1); - i1->setPeer(int1); - int2->setPeer(i2); - i2->setPeer(int2); + interface[0]->setPeer(peer0); + peer0->setPeer(interface[0]); + interface[1]->setPeer(peer1); + peer1->setPeer(interface[1]); } EtherLink::~EtherLink() { - delete link1; - delete link2; + delete link[0]; + delete link[1]; - delete int1; - delete int2; + delete interface[0]; + delete interface[1]; } EtherLink::Interface::Interface(const string &name, Link *tx, Link *rx) @@ -82,26 +82,25 @@ EtherLink::Interface::Interface(const string &name, Link *tx, Link *rx) rx->setRxInt(this); } -EtherLink::Link::Link(const string &name, double rate, Tick delay, - EtherDump *d) - : objName(name), txint(NULL), rxint(NULL), ticksPerByte(rate), - linkDelay(delay), dump(d), doneEvent(this) -{} +EtherLink::Link::Link(const string &name, EtherLink *p, int num, + double rate, Tick delay, EtherDump *d) + : objName(name), parent(p), number(num), txint(NULL), rxint(NULL), + ticksPerByte(rate), linkDelay(delay), dump(d), + doneEvent(this) +{ } void EtherLink::serialize(ostream &os) { - nameOut(os, name() + ".link1"); - link1->serialize(os); - nameOut(os, name() + ".link2"); - link2->serialize(os); + link[0]->serialize("link0", os); + link[1]->serialize("link1", os); } void EtherLink::unserialize(Checkpoint *cp, const string §ion) { - link1->unserialize(cp, section + ".link1"); - link2->unserialize(cp, section + ".link2"); + link[0]->unserialize("link0", cp, section); + link[1]->unserialize("link1", cp, section); } void @@ -118,10 +117,9 @@ class LinkDelayEvent : public Event EtherLink::Link *link; PacketPtr packet; - // non-scheduling version for createForUnserialize() - LinkDelayEvent(EtherLink::Link *link); - public: + // non-scheduling version for createForUnserialize() + LinkDelayEvent(); LinkDelayEvent(EtherLink::Link *link, PacketPtr pkt, Tick when); void process(); @@ -132,7 +130,6 @@ class LinkDelayEvent : public Event const string §ion); }; - void EtherLink::Link::txDone() { @@ -173,43 +170,44 @@ EtherLink::Link::transmit(PacketPtr pkt) } void -EtherLink::Link::serialize(ostream &os) +EtherLink::Link::serialize(const string &base, ostream &os) { bool packet_exists = packet; - SERIALIZE_SCALAR(packet_exists); + paramOut(os, base + ".packet_exists", packet_exists); + if (packet_exists) + packet->serialize(base + ".packet", os); bool event_scheduled = doneEvent.scheduled(); - SERIALIZE_SCALAR(event_scheduled); + paramOut(os, base + ".event_scheduled", event_scheduled); if (event_scheduled) { Tick event_time = doneEvent.when(); - SERIALIZE_SCALAR(event_time); + paramOut(os, base + ".event_time", event_time); } - if (packet_exists) - packet->serialize("packet", os); } void -EtherLink::Link::unserialize(Checkpoint *cp, const string §ion) +EtherLink::Link::unserialize(const string &base, Checkpoint *cp, + const string §ion) { bool packet_exists; - UNSERIALIZE_SCALAR(packet_exists); + paramIn(cp, section, base + ".packet_exists", packet_exists); if (packet_exists) { packet = new PacketData(16384); - packet->unserialize("packet", cp, section); + packet->unserialize(base + ".packet", cp, section); } bool event_scheduled; - UNSERIALIZE_SCALAR(event_scheduled); + paramIn(cp, section, base + ".event_scheduled", event_scheduled); if (event_scheduled) { Tick event_time; - UNSERIALIZE_SCALAR(event_time); + paramIn(cp, section, base + ".event_time", event_time); doneEvent.schedule(event_time); } } -LinkDelayEvent::LinkDelayEvent(EtherLink::Link *l) - : Event(&mainEventQueue), link(l) +LinkDelayEvent::LinkDelayEvent() + : Event(&mainEventQueue), link(NULL) { setFlags(AutoSerialize); setFlags(AutoDelete); @@ -234,7 +232,11 @@ LinkDelayEvent::serialize(ostream &os) { paramOut(os, "type", string("LinkDelayEvent")); Event::serialize(os); - SERIALIZE_OBJPTR(link); + + EtherLink *parent = link->parent; + bool number = link->number; + SERIALIZE_OBJPTR(parent); + SERIALIZE_SCALAR(number); packet->serialize("packet", os); } @@ -244,6 +246,14 @@ void LinkDelayEvent::unserialize(Checkpoint *cp, const string §ion) { Event::unserialize(cp, section); + + EtherLink *parent; + bool number; + UNSERIALIZE_OBJPTR(parent); + UNSERIALIZE_SCALAR(number); + + link = parent->link[number]; + packet = new PacketData(16384); packet->unserialize("packet", cp, section); } @@ -252,9 +262,7 @@ LinkDelayEvent::unserialize(Checkpoint *cp, const string §ion) Serializable * LinkDelayEvent::createForUnserialize(Checkpoint *cp, const string §ion) { - EtherLink::Link *link; - UNSERIALIZE_OBJPTR(link); - return new LinkDelayEvent(link); + return new LinkDelayEvent(); } REGISTER_SERIALIZEABLE("LinkDelayEvent", LinkDelayEvent) diff --git a/dev/etherlink.hh b/dev/etherlink.hh index d5cd7d7c8..28ab61301 100644 --- a/dev/etherlink.hh +++ b/dev/etherlink.hh @@ -40,7 +40,7 @@ #include "sim/sim_object.hh" class EtherDump; - +class Checkpoint; /* * Model for a fixed bandwidth full duplex ethernet link */ @@ -53,10 +53,14 @@ class EtherLink : public SimObject /* * Model for a single uni-directional link */ - class Link : public Serializable { + class Link + { protected: std::string objName; + EtherLink *parent; + int number; + Interface *txint; Interface *rxint; @@ -78,11 +82,11 @@ class EtherLink : public SimObject void txComplete(PacketPtr packet); public: - Link(const std::string &name, double rate, Tick delay, - EtherDump *dump); + Link(const std::string &name, EtherLink *p, int num, + double rate, Tick delay, EtherDump *dump); ~Link() {} - virtual const std::string name() const { return objName; } + const std::string name() const { return objName; } bool busy() const { return (bool)packet; } bool transmit(PacketPtr packet); @@ -90,8 +94,9 @@ class EtherLink : public SimObject void setTxInt(Interface *i) { assert(!txint); txint = i; } void setRxInt(Interface *i) { assert(!rxint); rxint = i; } - virtual void serialize(std::ostream &os); - virtual void unserialize(Checkpoint *cp, const std::string §ion); + void serialize(const std::string &base, std::ostream &os); + void unserialize(const std::string &base, Checkpoint *cp, + const std::string §ion); }; /* @@ -108,14 +113,11 @@ class EtherLink : public SimObject void sendDone() { peer->sendDone(); } }; - Link *link1; - Link *link2; - - EtherInt *int1; - EtherInt *int2; + Link *link[2]; + EtherInt *interface[2]; public: - EtherLink(const std::string &name, EtherInt *i1, EtherInt *i2, + EtherLink(const std::string &name, EtherInt *peer0, EtherInt *peer1, Tick speed, Tick delay, EtherDump *dump); virtual ~EtherLink(); diff --git a/dev/ns_gige.cc b/dev/ns_gige.cc index db1474d1c..bc3103540 100644 --- a/dev/ns_gige.cc +++ b/dev/ns_gige.cc @@ -138,7 +138,7 @@ NSGigE::NSGigE(Params *p) } - intrDelay = US2Ticks(p->intr_delay); + intrDelay = p->intr_delay * Clock::Int::us; dmaReadDelay = p->dma_read_delay; dmaWriteDelay = p->dma_write_delay; dmaReadFactor = p->dma_read_factor; @@ -1597,8 +1597,10 @@ NSGigE::rxKick() DPRINTF(Ethernet, "ID is %d\n", ip->id()); TcpPtr tcp(ip); if (tcp) { - DPRINTF(Ethernet, "Src Port=%d, Dest Port=%d\n", - tcp->sport(), tcp->dport()); + DPRINTF(Ethernet, + "Src Port=%d, Dest Port=%d, Seq=%d, Ack=%d\n", + tcp->sport(), tcp->dport(), tcp->seq(), + tcp->ack()); } } } @@ -1803,14 +1805,15 @@ NSGigE::transmit() DPRINTF(Ethernet, "ID is %d\n", ip->id()); TcpPtr tcp(ip); if (tcp) { - DPRINTF(Ethernet, "Src Port=%d, Dest Port=%d\n", - tcp->sport(), tcp->dport()); + DPRINTF(Ethernet, + "Src Port=%d, Dest Port=%d, Seq=%d, Ack=%d\n", + tcp->sport(), tcp->dport(), tcp->seq(), tcp->ack()); } } } #endif - DDUMP(Ethernet, txFifo.front()->data, txFifo.front()->length); + DDUMP(EthernetData, txFifo.front()->data, txFifo.front()->length); txBytes += txFifo.front()->length; txPackets++; @@ -2296,8 +2299,18 @@ NSGigE::recvPacket(PacketPtr packet) } if (rxFifo.avail() < packet->length) { - DPRINTF(Ethernet, - "packet will not fit in receive buffer...packet dropped\n"); +#if TRACING_ON + IpPtr ip(packet); + TcpPtr tcp(ip); + if (ip) { + DPRINTF(Ethernet, + "packet won't fit in receive buffer...pkt ID %d dropped\n", + ip->id()); + if (tcp) { + DPRINTF(Ethernet, "Seq=%d\n", tcp->seq()); + } + } +#endif droppedPackets++; devIntrPost(ISR_RXORN); return false; diff --git a/dev/pciconfigall.cc b/dev/pciconfigall.cc index 1a9804f79..2cbd5adc0 100644 --- a/dev/pciconfigall.cc +++ b/dev/pciconfigall.cc @@ -98,11 +98,12 @@ PciConfigAll::startup() Fault PciConfigAll::read(MemReqPtr &req, uint8_t *data) { - DPRINTF(PciConfigAll, "read va=%#x size=%d\n", - req->vaddr, req->size); Addr daddr = (req->paddr - (addr & EV5::PAddrImplMask)); + DPRINTF(PciConfigAll, "read va=%#x da=%#x size=%d\n", + req->vaddr, daddr, req->size); + int device = (daddr >> 11) & 0x1F; int func = (daddr >> 8) & 0x7; int reg = daddr & 0xFF; diff --git a/dev/pcidev.cc b/dev/pcidev.cc index c45afadd4..76b42390a 100644 --- a/dev/pcidev.cc +++ b/dev/pcidev.cc @@ -285,11 +285,6 @@ PciDev::unserialize(Checkpoint *cp, const std::string §ion) BEGIN_DECLARE_SIM_OBJECT_PARAMS(PciConfigData) - SimObjectParam<MemoryController *> mmu; - Param<Addr> addr; - SimObjectParam<Bus*> io_bus; - Param<Tick> pio_latency; - Param<uint16_t> VendorID; Param<uint16_t> DeviceID; Param<uint16_t> Command; @@ -327,11 +322,6 @@ END_DECLARE_SIM_OBJECT_PARAMS(PciConfigData) BEGIN_INIT_SIM_OBJECT_PARAMS(PciConfigData) - INIT_PARAM(mmu, "Memory Controller"), - INIT_PARAM(addr, "Device Address"), - INIT_PARAM_DFLT(io_bus, "The IO Bus to attach to", NULL), - INIT_PARAM_DFLT(pio_latency, "Programmed IO latency in bus cycles", 1), - INIT_PARAM(VendorID, "Vendor ID"), INIT_PARAM(DeviceID, "Device ID"), INIT_PARAM_DFLT(Command, "Command Register", 0x00), diff --git a/dev/sinic.cc b/dev/sinic.cc index fa4cd570f..13e16afae 100644 --- a/dev/sinic.cc +++ b/dev/sinic.cc @@ -79,7 +79,7 @@ const char *TxStateStrings[] = // Base::Base(Params *p) : PciDev(p), rxEnable(false), txEnable(false), - intrDelay(US2Ticks(p->intr_delay)), + intrDelay(p->intr_delay * Clock::Int::us), intrTick(0), cpuIntrEnable(false), cpuPendingIntr(false), intrEvent(0), interface(NULL) { diff --git a/dev/tsunami.cc b/dev/tsunami.cc index a95b7365d..c84dde9bc 100644 --- a/dev/tsunami.cc +++ b/dev/tsunami.cc @@ -77,13 +77,13 @@ Tsunami::clearConsoleInt() void Tsunami::postPciInt(int line) { - cchip->postDRIR(line); + cchip->postDRIR(line); } void Tsunami::clearPciInt(int line) { - cchip->clearDRIR(line); + cchip->clearDRIR(line); } Addr diff --git a/dev/tsunami_io.cc b/dev/tsunami_io.cc index 6c9195bff..1e4f44346 100644 --- a/dev/tsunami_io.cc +++ b/dev/tsunami_io.cc @@ -95,6 +95,13 @@ TsunamiIO::RTCEvent::unserialize(Checkpoint *cp, const std::string §ion) TsunamiIO::ClockEvent::ClockEvent() : Event(&mainEventQueue) { + /* This is the PIT Tick Rate. A constant for the 8254 timer. The + * Tsunami platform has one of these cycle counters on the Cypress + * South Bridge and it is used by linux for estimating the cycle + * frequency of the machine it is running on. --Ali + */ + interval = (Tick)(Clock::Float::s / 1193180.0); + DPRINTF(Tsunami, "Clock Event Initilizing\n"); mode = 0; } @@ -113,9 +120,7 @@ void TsunamiIO::ClockEvent::Program(int count) { DPRINTF(Tsunami, "Timer set to curTick + %d\n", count); - // should be count * (cpufreq/pitfreq) - interval = count * ticksPerSecond/1193180UL; - schedule(curTick + interval); + schedule(curTick + count * interval); status = 0; } diff --git a/dev/uart.cc b/dev/uart.cc index 3c4ab6d04..caa169a2e 100644 --- a/dev/uart.cc +++ b/dev/uart.cc @@ -73,17 +73,28 @@ Uart::IntrEvent::process() } +/* The linux serial driver (8250.c about line 1182) loops reading from + * the device until the device reports it has no more data to + * read. After a maximum of 255 iterations the code prints "serial8250 + * too much work for irq X," and breaks out of the loop. Since the + * simulated system is so much slower than the actual system, if a + * user is typing on the keyboard it is very easy for them to provide + * input at a fast enough rate to not allow the loop to exit and thus + * the error to be printed. This magic number provides a delay between + * the time the UART receives a character to send to the simulated + * system and the time it actually notifies the system it has a + * character to send to alleviate this problem. --Ali + */ void Uart::IntrEvent::scheduleIntr() { + static const Tick interval = (Tick)((Clock::Float::s / 2e9) * 450); DPRINTF(Uart, "Scheduling IER interrupt for %#x, at cycle %lld\n", intrBit, - curTick + (ticksPerSecond/2000) * 350); + curTick + interval); if (!scheduled()) - /* @todo Make this cleaner, will be much easier with - * nanosecond time everywhere. Hint hint Nate. */ - schedule(curTick + (ticksPerSecond/2000000000) * 450); + schedule(curTick + interval); else - reschedule(curTick + (ticksPerSecond/2000000000) * 450); + reschedule(curTick + interval); } Uart::Uart(const string &name, SimConsole *c, MemoryController *mmu, Addr a, diff --git a/kern/linux/linux_system.cc b/kern/linux/linux_system.cc index 401b4ef44..4ac03143e 100644 --- a/kern/linux/linux_system.cc +++ b/kern/linux/linux_system.cc @@ -102,12 +102,19 @@ LinuxSystem::LinuxSystem(Params *p) } else panic("could not find dp264_mv\n"); -#ifdef DEBUG +#ifndef NDEBUG kernelPanicEvent = new BreakPCEvent(&pcEventQueue, "kernel panic"); if (kernelSymtab->findAddress("panic", addr)) kernelPanicEvent->schedule(addr); else panic("could not find kernel symbol \'panic\'"); + + kernelDieEvent = new BreakPCEvent(&pcEventQueue, "die if kernel"); + if (kernelSymtab->findAddress("die_if_kernel", addr)) + kernelDieEvent->schedule(addr); + else + panic("could not find kernel symbol \'die_if_kernel\'"); + #endif /** @@ -174,7 +181,7 @@ LinuxSystem::LinuxSystem(Params *p) LinuxSystem::~LinuxSystem() { -#ifdef DEBUG +#ifndef NDEBUG delete kernelPanicEvent; #endif delete skipIdeDelay50msEvent; diff --git a/kern/linux/linux_system.hh b/kern/linux/linux_system.hh index 5e3cba9b3..905b0ee70 100644 --- a/kern/linux/linux_system.hh +++ b/kern/linux/linux_system.hh @@ -57,9 +57,12 @@ class PrintThreadInfo; class LinuxSystem : public System { private: -#ifdef DEBUG +#ifndef NDEBUG /** Event to halt the simulator if the kernel calls panic() */ BreakPCEvent *kernelPanicEvent; + + /** Event to halt the simulator if the kernel calls die_if_kernel */ + BreakPCEvent *kernelDieEvent; #endif /** diff --git a/objects/AlphaConsole.mpy b/objects/AlphaConsole.mpy deleted file mode 100644 index 79918a01e..000000000 --- a/objects/AlphaConsole.mpy +++ /dev/null @@ -1,9 +0,0 @@ -from Device import PioDevice - -simobj AlphaConsole(PioDevice): - type = 'AlphaConsole' - cpu = Param.BaseCPU(Super, "Processor") - disk = Param.SimpleDisk("Simple Disk") - num_cpus = Param.Int(1, "Number of CPUs") - sim_console = Param.SimConsole(Super, "The Simulator Console") - system = Param.BaseSystem(Super, "system object") diff --git a/objects/BaseCPU.mpy b/objects/BaseCPU.mpy deleted file mode 100644 index f6e6ff96c..000000000 --- a/objects/BaseCPU.mpy +++ /dev/null @@ -1,39 +0,0 @@ -simobj BaseCPU(SimObject): - type = 'BaseCPU' - abstract = True - icache = Param.BaseMem(NULL, "L1 instruction cache object") - dcache = Param.BaseMem(NULL, "L1 data cache object") - - dtb = Param.AlphaDTB("Data TLB") - itb = Param.AlphaITB("Instruction TLB") - mem = Param.FunctionalMemory("memory") - system = Param.BaseSystem(Super, "system object") - workload = VectorParam.Process("processes to run") - - max_insts_all_threads = Param.Counter(0, - "terminate when all threads have reached this inst count") - max_insts_any_thread = Param.Counter(0, - "terminate when any thread reaches this inst count") - max_loads_all_threads = Param.Counter(0, - "terminate when all threads have reached this load count") - max_loads_any_thread = Param.Counter(0, - "terminate when any thread reaches this load count") - - defer_registration = Param.Bool(False, - "defer registration with system (for sampling)") - - def check(self): - has_workload = self._hasvalue('workload') - has_dtb = self._hasvalue('dtb') - has_itb = self._hasvalue('itb') - has_mem = self._hasvalue('mem') - has_system = self._hasvalue('system') - - if has_workload: - self.dtb.disable = True - self.itb.disable = True - self.mem.disable = True - self.system.disable = True - - if has_dtb or has_itb or has_mem or has_system: - self.workload.disable = True diff --git a/sim/pyconfig/SConscript b/python/SConscript index 9154d3b99..9c15c6d50 100644 --- a/sim/pyconfig/SConscript +++ b/python/SConscript @@ -26,7 +26,11 @@ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -import os, os.path, re +import os, os.path, re, sys + +Import('env') + +import m5scons def WriteEmbeddedPyFile(target, source, path, name, ext, filename): if isinstance(source, str): @@ -89,7 +93,6 @@ def splitpath(path): path.insert(0, base) return path, file -Import('env') def MakeEmbeddedPyFile(target, source, env): target = file(str(target[0]), 'w') @@ -144,6 +147,13 @@ def MakeEmbeddedPyFile(target, source, env): for pyfile, path, name, ext, filename in files: WriteEmbeddedPyFile(target, pyfile, path, name, ext, filename) +def MakeDefinesPyFile(target, source, env): + f = file(str(target[0]), 'w') + print >>f, "import __main__" + print >>f, "__main__.m5_build_env = ", + print >>f, m5scons.flatten_defines(env['CPPDEFINES']) + f.close() + CFileCounter = 0 def MakePythonCFile(target, source, env): global CFileCounter @@ -170,8 +180,10 @@ EmbedMap %(name)s("%(fname)s", /* namespace */ } ''' -embedded_py_files = ['m5config.py', '../../util/pbs/jobfile.py'] -objpath = os.path.join(env['SRCDIR'], 'objects') +# base list of .py files to embed +embedded_py_files = [ '../util/pbs/jobfile.py' ] +# add all .py and .mpy files in python/m5 +objpath = os.path.join(env['SRCDIR'], 'python', 'm5') for root, dirs, files in os.walk(objpath, topdown=True): for i,dir in enumerate(dirs): if dir == 'SCCS': @@ -184,7 +196,9 @@ for root, dirs, files in os.walk(objpath, topdown=True): embedded_py_files.append(os.path.join(root, f)) embedfile_hh = os.path.join(env['SRCDIR'], 'base/embedfile.hh') -env.Depends('embedded_py.cc', embedfile_hh) +env.Command('defines.py', None, MakeDefinesPyFile) env.Command('embedded_py.py', embedded_py_files, MakeEmbeddedPyFile) -env.Command('embedded_py.cc', ['importer.py', 'embedded_py.py'], +env.Depends('embedded_py.cc', embedfile_hh) +env.Command('embedded_py.cc', + ['string_importer.py', 'defines.py', 'embedded_py.py'], MakePythonCFile) diff --git a/python/m5/__init__.py b/python/m5/__init__.py new file mode 100644 index 000000000..27bd91749 --- /dev/null +++ b/python/m5/__init__.py @@ -0,0 +1,37 @@ +import sys, os + +# define this here so we can use it right away if necessary +def panic(string): + print >>sys.stderr, 'panic:', string + sys.exit(1) + +# the mpy import code is added to the global import meta_path as a +# side effect of this import +from mpy_importer import AddToPath, LoadMpyFile + +# find the m5 compile options: must be specified as a dict in +# __main__.m5_build_env. +import __main__ +if not hasattr(__main__, 'm5_build_env'): + panic("__main__ must define m5_build_env") + +# make a SmartDict out of the build options for our local use +import smartdict +build_env = smartdict.SmartDict() +build_env.update(__main__.m5_build_env) + +# make a SmartDict out of the OS environment too +env = smartdict.SmartDict() +env.update(os.environ) + +# import the main m5 config code +from config import * +config.add_param_types(config) + +# import the built-in object definitions +from objects import * +config.add_param_types(objects) + +cpp_classes = config.MetaSimObject.cpp_classes +cpp_classes.sort() + diff --git a/sim/pyconfig/m5config.py b/python/m5/config.py index 17a0d8f42..a791bbebf 100644 --- a/sim/pyconfig/m5config.py +++ b/python/m5/config.py @@ -25,23 +25,18 @@ # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. from __future__ import generators -import os, re, sys, types +import os, re, sys, types, inspect + +from m5 import panic, env +from convert import * +from multidict import multidict + noDot = False try: import pydot except: noDot = True -env = {} -env.update(os.environ) - -def panic(string): - print >>sys.stderr, 'panic:', string - sys.exit(1) - -def issequence(value): - return isinstance(value, tuple) or isinstance(value, list) - class Singleton(type): def __call__(cls, *args, **kwargs): if hasattr(cls, '_instance'): @@ -70,7 +65,7 @@ class Singleton(type): # object, either using keyword assignment in the constructor or in # separate assignment statements. For example: # -# cache = BaseCache('my_cache', root, size=64*K) +# cache = BaseCache('my_cache', root, size='64KB') # cache.hit_latency = 3 # cache.assoc = 8 # @@ -146,25 +141,95 @@ class Singleton(type): ##################################################################### class Proxy(object): - def __init__(self, path = ()): + def __init__(self, path): self._object = None - self._path = path + if path == 'any': + self._path = None + else: + # path is a list of (attr,index) tuples + self._path = [(path,None)] + self._index = None + self._multiplier = None def __getattr__(self, attr): - return Proxy(self._path + (attr, )) + # python uses __bases__ internally for inheritance + if attr == '__bases__': + return super(Proxy, self).__getattr__(self, attr) + if (self._path == None): + panic("Can't add attributes to 'any' proxy") + self._path.append((attr,None)) + return self def __setattr__(self, attr, value): if not attr.startswith('_'): raise AttributeError, 'cannot set attribute %s' % attr super(Proxy, self).__setattr__(attr, value) - def _convert(self): - obj = self._object - for attr in self._path: - obj = obj.__getattribute__(attr) + # support indexing on proxies (e.g., parent.cpu[0]) + def __getitem__(self, key): + if not isinstance(key, int): + raise TypeError, "Proxy object requires integer index" + if self._path == None: + raise IndexError, "Index applied to 'any' proxy" + # replace index portion of last path element with new index + self._path[-1] = (self._path[-1][0], key) + return self + + # support multiplying proxies by constants + def __mul__(self, other): + if not isinstance(other, int): + raise TypeError, "Proxy multiplier must be integer" + if self._multiplier == None: + self._multiplier = other + else: + # support chained multipliers + self._multiplier *= other + return self + + def _mulcheck(self, result): + if self._multiplier == None: + return result + if not isinstance(result, int): + raise TypeError, "Proxy with multiplier resolves to " \ + "non-integer value" + return result * self._multiplier + + def unproxy(self, base, ptype): + obj = base + done = False + while not done: + if obj is None: + raise AttributeError, \ + 'Parent of %s type %s not found at path %s' \ + % (base.name, ptype, self._path) + + result, done = obj.find(ptype, self._path) + obj = obj.parent + + if isinstance(result, Proxy): + result = result.unproxy(obj, ptype) + + return self._mulcheck(result) + + def getindex(obj, index): + if index == None: + return obj + try: + obj = obj[index] + except TypeError: + if index != 0: + raise + # if index is 0 and item is not subscriptable, just + # use item itself (so cpu[0] works on uniprocessors) return obj + getindex = staticmethod(getindex) -Super = Proxy() +class ProxyFactory(object): + def __getattr__(self, attr): + return Proxy(attr) + +# global object for handling parent.foo proxies +parent = ProxyFactory() def isSubClass(value, cls): try: @@ -172,9 +237,6 @@ def isSubClass(value, cls): except: return False -def isParam(self): - return isinstance(self, _Param) - def isConfigNode(value): try: return issubclass(value, ConfigNode) @@ -188,7 +250,7 @@ def isSimObject(value): return False def isSimObjSequence(value): - if not issequence(value): + if not isinstance(value, (list, tuple)): return False for val in value: @@ -204,10 +266,32 @@ def isParamContext(value): return False -class_decorator = '_M5M5_SIMOBJECT_' -expr_decorator = '_M5M5_EXPRESSION_' +class_decorator = 'M5M5_SIMOBJECT_' +expr_decorator = 'M5M5_EXPRESSION_' dot_decorator = '_M5M5_DOT_' +# 'Global' map of legitimate types for SimObject parameters. +param_types = {} + +# Dummy base class to identify types that are legitimate for SimObject +# parameters. +class ParamType(object): + pass + +# Add types defined in given context (dict or module) that are derived +# from ParamType to param_types map. +def add_param_types(ctx): + if isinstance(ctx, types.DictType): + source_dict = ctx + elif isinstance(ctx, types.ModuleType): + source_dict = ctx.__dict__ + else: + raise TypeError, \ + "m5.config.add_param_types requires dict or module as arg" + for key,val in source_dict.iteritems(): + if isinstance(val, type) and issubclass(val, ParamType): + param_types[key] = val + # The metaclass for ConfigNode (and thus for everything that derives # from ConfigNode, including SimObject). This class controls how new # classes that derive from ConfigNode are instantiated, and provides @@ -215,9 +299,11 @@ dot_decorator = '_M5M5_DOT_' # of that class are instantiated, and provides inherited instance # behavior). class MetaConfigNode(type): - keywords = { 'abstract' : types.BooleanType, - 'check' : types.FunctionType, - 'type' : (types.NoneType, types.StringType) } + # Attributes that can be set only at initialization time + init_keywords = {} + # Attributes that can be set any time + keywords = { 'check' : types.FunctionType, + 'children' : types.ListType } # __new__ is called before __init__, and is where the statements # in the body of the class definition get loaded into the class's @@ -225,177 +311,106 @@ class MetaConfigNode(type): # and only allow "private" attributes to be passed to the base # __new__ (starting with underscore). def __new__(mcls, name, bases, dict): - priv = { 'abstract' : False, - # initialize _params and _values dicts to empty - '_params' : {}, - '_values' : {}, - '_disable' : {} } - + # Copy "private" attributes (including special methods such as __new__) + # to the official dict. Everything else goes in _init_dict to be + # filtered in __init__. + cls_dict = {} for key,val in dict.items(): - del dict[key] - - # See description of decorators in the importer.py file - # We just strip off the expr_decorator now since we don't - # need from this point on. - if key.startswith(expr_decorator): - key = key[len(expr_decorator):] - - if mcls.keywords.has_key(key): - if not isinstance(val, mcls.keywords[key]): - raise TypeError, \ - 'keyword %s has the wrong type %s should be %s' % \ - (key, type(val), mcls.keywords[key]) - - if isinstance(val, types.FunctionType): - val = classmethod(val) - priv[key] = val - - elif key.startswith('_'): - priv[key] = val - - elif not isNullPointer(val) and isConfigNode(val): - dict[key] = val() - - elif isSimObjSequence(val): - dict[key] = [ v() for v in val ] - - else: - dict[key] = val - - # If your parent has a value in it that's a config node, clone it. - for base in bases: - if not isConfigNode(base): - continue - - for key,value in base._values.iteritems(): - if dict.has_key(key): - continue - - if isConfigNode(value): - priv['_values'][key] = value() - elif isSimObjSequence(value): - priv['_values'][key] = [ val() for val in value ] - - # entries left in dict will get passed to __init__, where we'll - # deal with them as params. - return super(MetaConfigNode, mcls).__new__(mcls, name, bases, priv) + if key.startswith('_'): + cls_dict[key] = val + del dict[key] + cls_dict['_init_dict'] = dict + return super(MetaConfigNode, mcls).__new__(mcls, name, bases, cls_dict) # initialization def __init__(cls, name, bases, dict): - super(MetaConfigNode, cls).__init__(cls, name, bases, {}) + super(MetaConfigNode, cls).__init__(name, bases, dict) + # initialize required attributes + cls._params = multidict() + cls._values = multidict() + cls._param_types = {} cls._bases = [c for c in cls.__mro__ if isConfigNode(c)] + cls._anon_subclass_counter = 0 + + # We don't support multiple inheritence. If you want to, you + # must fix multidict to deal with it properly. + cnbase = [ base for base in bases if isConfigNode(base) ] + if len(cnbase) == 1: + # If your parent has a value in it that's a config node, clone + # it. Do this now so if we update any of the values' + # attributes we are updating the clone and not the original. + for key,val in cnbase[0]._values.iteritems(): + + # don't clone if (1) we're about to overwrite it with + # a local setting or (2) we've already cloned a copy + # from an earlier (more derived) base + if cls._init_dict.has_key(key) or cls._values.has_key(key): + continue - # initialize attributes with values from class definition - for key,value in dict.iteritems(): - # turn an expression that was munged in the importer - # because it had dots into a list so that we can find the - # proper variable to modify. - key = key.split(dot_decorator) - c = cls - for item in key[:-1]: - c = getattr(c, item) - setattr(c, key[-1], value) - - def _isvalue(cls, name): - for c in cls._bases: - if c._params.has_key(name): - return True - - for c in cls._bases: - if c._values.has_key(name): - return True - - return False + if isConfigNode(val): + cls._values[key] = val() + elif isSimObjSequence(val) and len(val): + cls._values[key] = [ v() for v in val ] + + cls._params.parent = cnbase[0]._params + cls._values.parent = cnbase[0]._values + + elif len(cnbase) > 1: + panic("""\ +The config hierarchy only supports single inheritence of SimObject +classes. You're trying to derive from: +%s""" % str(cnbase)) + + # process param types from _init_dict, as these may be needed + # by param descriptions also in _init_dict + for key,val in cls._init_dict.items(): + if isinstance(val, type) and issubclass(val, ParamType): + cls._param_types[key] = val + if not issubclass(val, ConfigNode): + del cls._init_dict[key] + + # now process remaining _init_dict items + for key,val in cls._init_dict.items(): + # param descriptions + if isinstance(val, ParamBase): + cls._new_param(key, val) + + # init-time-only keywords + elif cls.init_keywords.has_key(key): + cls._set_keyword(key, val, cls.init_keywords[key]) + + # See description of decorators in the importer.py file. + # We just strip off the expr_decorator now since we don't + # need from this point on. + elif key.startswith(expr_decorator): + key = key[len(expr_decorator):] + # because it had dots into a list so that we can find the + # proper variable to modify. + key = key.split(dot_decorator) + c = cls + for item in key[:-1]: + c = getattr(c, item) + setattr(c, key[-1], val) + + # default: use normal path (ends up in __setattr__) + else: + setattr(cls, key, val) - # generator that iterates across all parameters for this class and - # all classes it inherits from - def _getparams(cls): - params = {} - for c in cls._bases: - for p,v in c._params.iteritems(): - if not params.has_key(p): - params[p] = v - return params - - # Lookup a parameter description by name in the given class. - def _getparam(cls, name, default = AttributeError): - for c in cls._bases: - if c._params.has_key(name): - return c._params[name] - if isSubClass(default, Exception): - raise default, \ - "object '%s' has no attribute '%s'" % (cls.__name__, name) - else: - return default + def _set_keyword(cls, keyword, val, kwtype): + if not isinstance(val, kwtype): + raise TypeError, 'keyword %s has bad type %s (expecting %s)' % \ + (keyword, type(val), kwtype) + if isinstance(val, types.FunctionType): + val = classmethod(val) + type.__setattr__(cls, keyword, val) - def _setparam(cls, name, value): + def _new_param(cls, name, value): cls._params[name] = value - - def _hasvalue(cls, name): - for c in cls._bases: - if c._values.has_key(name): - return True - - return False - - def _getvalues(cls): - values = {} - for i,c in enumerate(cls._bases): - for p,v in c._values.iteritems(): - if not values.has_key(p): - values[p] = v - for p,v in c._params.iteritems(): - if not values.has_key(p) and hasattr(v, 'default'): - v.valid(v.default) - v = v.default - cls._setvalue(p, v) - values[p] = v - - return values - - def _getvalue(cls, name, default = AttributeError): - value = None - for c in cls._bases: - if c._values.has_key(name): - value = c._values[name] - break - if value is not None: - return value - - param = cls._getparam(name, None) - if param is not None and hasattr(param, 'default'): - param.valid(param.default) - value = param.default - cls._setvalue(name, value) - return value - - if isSubClass(default, Exception): - raise default, 'value for %s not found' % name - else: - return default - - def _setvalue(cls, name, value): - cls._values[name] = value - - def _getdisable(cls, name): - for c in cls._bases: - if c._disable.has_key(name): - return c._disable[name] - return False - - def _setdisable(cls, name, value): - cls._disable[name] = value - - def __getattr__(cls, attr): - if cls._isvalue(attr): - return Value(cls, attr) - - if attr == '_cppname' and hasattr(cls, 'type'): - return cls.type + '*' - - raise AttributeError, \ - "object '%s' has no attribute '%s'" % (cls.__name__, attr) + if hasattr(value, 'default'): + cls._values[name] = value.default + # try to resolve local param types in local param_types scope + value.maybe_resolve_type(cls._param_types) # Set attribute (called on foo.attr = value when foo is an # instance of class cls). @@ -406,34 +421,44 @@ class MetaConfigNode(type): return if cls.keywords.has_key(attr): - raise TypeError, \ - "keyword '%s' can only be set in a simobj definition" % attr - - if isParam(value): - cls._setparam(attr, value) + cls._set_keyword(attr, value, cls.keywords[attr]) return # must be SimObject param - param = cls._getparam(attr, None) + param = cls._params.get(attr, None) if param: # It's ok: set attribute by delegating to 'object' class. # Note the use of param.make_value() to verify/canonicalize # the assigned value - param.valid(value) - cls._setvalue(attr, value) + try: + param.valid(value) + except Exception, e: + msg = "%s\nError setting param %s.%s to %s\n" % \ + (e, cls.__name__, attr, value) + e.args = (msg, ) + raise + cls._values[attr] = value elif isConfigNode(value) or isSimObjSequence(value): - cls._setvalue(attr, value) + cls._values[attr] = value else: - for p,v in cls._getparams().iteritems(): - print p,v raise AttributeError, \ "Class %s has no parameter %s" % (cls.__name__, attr) + def __getattr__(cls, attr): + if cls._params.has_key(attr) or cls._values.has_key(attr): + return Value(cls, attr) + + if attr == '_cpp_param_decl' and hasattr(cls, 'type'): + return cls.type + '*' + + raise AttributeError, \ + "object '%s' has no attribute '%s'" % (cls.__name__, attr) + def add_child(cls, instance, name, child): if isNullPointer(child) or instance.top_child_names.has_key(name): return - if issequence(child): + if isinstance(child, (list, tuple)): kid = [] for i,c in enumerate(child): n = '%s%d' % (name, i) @@ -453,36 +478,28 @@ class MetaConfigNode(type): # Print instance info to .ini file. def instantiate(cls, name, parent = None): - instance = Node(name, cls, cls.type, parent, isParamContext(cls)) + instance = Node(name, cls, parent, isParamContext(cls)) if hasattr(cls, 'check'): cls.check() - for key,value in cls._getvalues().iteritems(): - if cls._getdisable(key): - continue - + for key,value in cls._values.iteritems(): if isConfigNode(value): cls.add_child(instance, key, value) - if issequence(value): - list = [ v for v in value if isConfigNode(v) ] - if len(list): - cls.add_child(instance, key, list) + if isinstance(value, (list, tuple)): + vals = [ v for v in value if isConfigNode(v) ] + if len(vals): + cls.add_child(instance, key, vals) - for pname,param in cls._getparams().iteritems(): - try: - if cls._getdisable(pname): - continue - - try: - value = cls._getvalue(pname) - except: - print 'Error getting %s' % pname - raise + for pname,param in cls._params.iteritems(): + value = cls._values.get(pname, None) + if value is None: + panic('Error getting %s from %s' % (pname, name)) + try: if isConfigNode(value): value = instance.child_objects[value] - elif issequence(value): + elif isinstance(value, (list, tuple)): v = [] for val in value: if isConfigNode(val): @@ -494,9 +511,10 @@ class MetaConfigNode(type): p = NodeParam(pname, param, value) instance.params.append(p) instance.param_names[pname] = p - except: - print 'Exception while evaluating %s.%s' % \ - (instance.path, pname) + except Exception, e: + msg = 'Exception while evaluating %s.%s\n%s' % \ + (instance.path, pname, e) + e.args = (msg, ) raise return instance @@ -530,53 +548,59 @@ class ConfigNode(object): # Specify metaclass. Any class inheriting from ConfigNode will # get this metaclass. __metaclass__ = MetaConfigNode - type = None def __new__(cls, **kwargs): - return MetaConfigNode(cls.__name__, (cls, ), kwargs) - - # Set attribute. All attribute assignments go through here. Must - # be private attribute (starts with '_') or valid parameter entry. - # Basically identical to MetaConfigClass.__setattr__(), except - # this sets attributes on specific instances rather than on classes. - #def __setattr__(self, attr, value): - # if attr.startswith('_'): - # object.__setattr__(self, attr, value) - # return - # not private; look up as param - # param = self.__class__.lookup_param(attr) - # if not param: - # raise AttributeError, \ - # "Class %s has no parameter %s" \ - # % (self.__class__.__name__, attr) - # It's ok: set attribute by delegating to 'object' class. - # Note the use of param.make_value() to verify/canonicalize - # the assigned value. - # v = param.convert(value) - # object.__setattr__(self, attr, v) - -class ParamContext(ConfigNode): + name = cls.__name__ + ("_%d" % cls._anon_subclass_counter) + cls._anon_subclass_counter += 1 + return cls.__metaclass__(name, (cls, ), kwargs) + +class ParamContext(ConfigNode,ParamType): pass -# SimObject is a minimal extension of ConfigNode, implementing a -# hierarchy node that corresponds to an M5 SimObject. It prints out a -# "type=" line to indicate its SimObject class, prints out the -# assigned parameters corresponding to its class, and allows -# parameters to be set by keyword in the constructor. Note that most -# of the heavy lifting for the SimObject param handling is done in the -# MetaConfigNode metaclass. -class SimObject(ConfigNode): - def _sim_code(cls): +class MetaSimObject(MetaConfigNode): + # init_keywords and keywords are inherited from MetaConfigNode, + # with overrides/additions + init_keywords = MetaConfigNode.init_keywords + init_keywords.update({ 'abstract' : types.BooleanType, + 'type' : types.StringType }) + + keywords = MetaConfigNode.keywords + # no additional keywords + + cpp_classes = [] + + # initialization + def __init__(cls, name, bases, dict): + super(MetaSimObject, cls).__init__(name, bases, dict) + + if hasattr(cls, 'type'): + if name == 'SimObject': + cls._cpp_base = None + elif hasattr(cls._bases[1], 'type'): + cls._cpp_base = cls._bases[1].type + else: + panic("SimObject %s derives from a non-C++ SimObject %s "\ + "(no 'type')" % (cls, cls_bases[1].__name__)) + + # This class corresponds to a C++ class: put it on the global + # list of C++ objects to generate param structs, etc. + MetaSimObject.cpp_classes.append(cls) + + def _cpp_decl(cls): name = cls.__name__ + code = "" + code += "\n".join([e.cpp_declare() for e in cls._param_types.values()]) + code += "\n" param_names = cls._params.keys() param_names.sort() - code = "BEGIN_DECLARE_SIM_OBJECT_PARAMS(%s)\n" % name - decls = [" " + cls._params[pname].sim_decl(pname) \ - for pname in param_names] - code += "\n".join(decls) + "\n" - code += "END_DECLARE_SIM_OBJECT_PARAMS(%s)\n\n" % name + code += "struct Params" + if cls._cpp_base: + code += " : public %s::Params" % cls._cpp_base + code += " {\n " + code += "\n ".join([cls._params[pname].cpp_decl(pname) \ + for pname in param_names]) + code += "\n};\n" return code - _sim_code = classmethod(_sim_code) class NodeParam(object): def __init__(self, name, param, value): @@ -589,10 +613,13 @@ class NodeParam(object): class Node(object): all = {} - def __init__(self, name, realtype, type, parent, paramcontext): + def __init__(self, name, realtype, parent, paramcontext): self.name = name self.realtype = realtype - self.type = type + if isSimObject(realtype): + self.type = realtype.type + else: + self.type = None self.parent = parent self.children = [] self.child_names = {} @@ -622,50 +649,40 @@ class Node(object): if issubclass(child.realtype, realtype): if obj is not None: raise AttributeError, \ - 'Super matched more than one: %s %s' % \ + 'parent.any matched more than one: %s %s' % \ (obj.path, child.path) obj = child return obj, obj is not None try: obj = self - for node in path[:-1]: - obj = obj.child_names[node] + for (node,index) in path[:-1]: + if obj.child_names.has_key(node): + obj = obj.child_names[node] + else: + obj = obj.top_child_names[node] + obj = Proxy.getindex(obj, index) - last = path[-1] + (last,index) = path[-1] if obj.child_names.has_key(last): value = obj.child_names[last] - if issubclass(value.realtype, realtype): - return value, True + return Proxy.getindex(value, index), True + elif obj.top_child_names.has_key(last): + value = obj.top_child_names[last] + return Proxy.getindex(value, index), True elif obj.param_names.has_key(last): value = obj.param_names[last] realtype._convert(value.value) - return value.value, True + return Proxy.getindex(value.value, index), True except KeyError: pass return None, False - def unproxy(self, ptype, value): - if not isinstance(value, Proxy): - return value - - if value is None: - raise AttributeError, 'Error while fixing up %s' % self.path - - obj = self - done = False - while not done: - if obj is None: - raise AttributeError, \ - 'Parent of %s type %s not found at path %s' \ - % (self.name, ptype, value._path) - found, done = obj.find(ptype, value._path) - if isinstance(found, Proxy): - done = False - obj = obj.parent - - return found + def unproxy(self, param, ptype): + if not isinstance(param, Proxy): + return param + return param.unproxy(self, ptype) def fixup(self): self.all[self.path] = self @@ -675,12 +692,14 @@ class Node(object): pval = param.value try: - if issequence(pval): - param.value = [ self.unproxy(ptype, pv) for pv in pval ] + if isinstance(pval, (list, tuple)): + param.value = [ self.unproxy(pv, ptype) for pv in pval ] else: - param.value = self.unproxy(ptype, pval) - except: - print 'Error while fixing up %s:%s' % (self.path, param.name) + param.value = self.unproxy(pval, ptype) + except Exception, e: + msg = 'Error while fixing up %s:%s\n%s' % \ + (self.path, param.name, e) + e.args = (msg, ) raise for child in self.children: @@ -697,7 +716,10 @@ class Node(object): if self.children: # instantiate children in same order they were added for # backward compatibility (else we can end up with cpu1 - # before cpu0). + # before cpu0). Changing ordering can also influence timing + # in the current memory system, as caches get added to a bus + # in different orders which affects their priority in the + # case of simulataneous requests. self.children.sort(lambda x,y: cmp(x.name, y.name)) children = [ c.name for c in self.children if not c.paramcontext] print 'children =', ' '.join(children) @@ -710,8 +732,9 @@ class Node(object): value = param.convert(param.value) string = param.string(value) - except: - print 'exception in %s:%s' % (self.path, param.name) + except Exception, e: + msg = 'exception in %s:%s\n%s' % (self.path, param.name, e) + e.args = (msg, ) raise print '%s = %s' % (param.name, string) @@ -724,8 +747,6 @@ class Node(object): # print type and parameter values to .ini file def outputDot(self, dot): - - label = "{%s|" % self.path if isSimObject(self.realtype): label += '%s|' % self.type @@ -745,9 +766,11 @@ class Node(object): value = param.convert(param.value) string = param.string(value) - except: - print 'exception in %s:%s' % (self.name, param.name) + except Exception, e: + msg = 'exception in %s:%s\n%s' % (self.name, param.name, e) + e.args = (msg, ) raise + if isConfigNode(param.ptype) and string != "Null": simobjs.append(string) else: @@ -755,7 +778,8 @@ class Node(object): for so in simobjs: label += "|<%s> %s" % (so, so) - dot.add_edge(pydot.Edge("%s:%s" % (self.path, so), so, tailport="w")) + dot.add_edge(pydot.Edge("%s:%s" % (self.path, so), so, + tailport="w")) label += '}' dot.add_node(pydot.Node(self.path,shape="Mrecord",label=label)) @@ -795,19 +819,13 @@ class Value(object): super(Value, self).__setattr__('obj', obj) def _getattr(self): - return self.obj._getvalue(self.attr) + return self.obj._values.get(self.attr) def __setattr__(self, attr, value): - if attr == 'disable': - self.obj._setdisable(self.attr, value) - else: - setattr(self._getattr(), attr, value) + setattr(self._getattr(), attr, value) def __getattr__(self, attr): - if attr == 'disable': - return self.obj._getdisable(self.attr) - else: - return getattr(self._getattr(), attr) + return getattr(self._getattr(), attr) def __getitem__(self, index): return self._getattr().__getitem__(index) @@ -821,12 +839,18 @@ class Value(object): def __str__(self): return str(self._getattr()) + def __len__(self): + return len(self._getattr()) + # Regular parameter. -class _Param(object): - def __init__(self, ptype_string, *args, **kwargs): - self.ptype_string = ptype_string - # can't eval ptype_string here to get ptype, since the type might - # not have been defined yet. Do it lazily in __getattr__. +class ParamBase(object): + def __init__(self, ptype, *args, **kwargs): + if isinstance(ptype, types.StringType): + self.ptype_string = ptype + elif isinstance(ptype, type): + self.ptype = ptype + else: + raise TypeError, "Param type is not a type (%s)" % ptype if args: if len(args) == 1: @@ -853,13 +877,24 @@ class _Param(object): if not hasattr(self, 'desc'): raise TypeError, 'desc attribute missing' + def maybe_resolve_type(self, context): + # check if already resolved... don't use hasattr(), + # as that calls __getattr__() + if self.__dict__.has_key('ptype'): + return + try: + self.ptype = context[self.ptype_string] + except KeyError: + # no harm in trying... we'll try again later using global scope + pass + def __getattr__(self, attr): if attr == 'ptype': try: - self.ptype = eval(self.ptype_string) + self.ptype = param_types[self.ptype_string] return self.ptype except: - raise TypeError, 'Param.%s: undefined type' % self.ptype_string + panic("undefined Param type %s" % self.ptype_string) else: raise AttributeError, "'%s' object has no attribute '%s'" % \ (type(self).__name__, attr) @@ -877,17 +912,19 @@ class _Param(object): def set(self, name, instance, value): instance.__dict__[name] = value - def sim_decl(self, name): - return '%s %s;' % (self.ptype._cppname, name) + def cpp_decl(self, name): + return '%s %s;' % (self.ptype._cpp_param_decl, name) -class _ParamProxy(object): +class ParamFactory(object): def __init__(self, type): self.ptype = type # E.g., Param.Int(5, "number of widgets") def __call__(self, *args, **kwargs): - return _Param(self.ptype, *args, **kwargs) + return ParamBase(self.ptype, *args, **kwargs) + # Strange magic to theoretically allow dotted names as Param classes, + # e.g., Param.Foo.Bar(...) to have a param of type Foo.Bar def __getattr__(self, attr): if attr == '__bases__': raise AttributeError, '' @@ -898,23 +935,22 @@ class _ParamProxy(object): if attr != 'ptype': raise AttributeError, \ 'Attribute %s not available in %s' % (attr, self.__class__) - super(_ParamProxy, self).__setattr__(attr, value) + super(ParamFactory, self).__setattr__(attr, value) - -Param = _ParamProxy(None) +Param = ParamFactory(None) # Vector-valued parameter description. Just like Param, except that # the value is a vector (list) of the specified type instead of a # single value. -class _VectorParam(_Param): +class VectorParamBase(ParamBase): def __init__(self, type, *args, **kwargs): - _Param.__init__(self, type, *args, **kwargs) + ParamBase.__init__(self, type, *args, **kwargs) def valid(self, value): if value == None: return True - if issequence(value): + if isinstance(value, (list, tuple)): for val in value: if not isinstance(val, Proxy): self.ptype._convert(val) @@ -927,7 +963,7 @@ class _VectorParam(_Param): if value == None: return [] - if issequence(value): + if isinstance(value, (list, tuple)): # list: coerce each element into new list return [ self.ptype._convert(v) for v in value ] else: @@ -935,20 +971,20 @@ class _VectorParam(_Param): return self.ptype._convert(value) def string(self, value): - if issequence(value): + if isinstance(value, (list, tuple)): return ' '.join([ self.ptype._string(v) for v in value]) else: return self.ptype._string(value) - def sim_decl(self, name): - return 'std::vector<%s> %s;' % (self.ptype._cppname, name) + def cpp_decl(self, name): + return 'std::vector<%s> %s;' % (self.ptype._cpp_param_decl, name) -class _VectorParamProxy(_ParamProxy): +class VectorParamFactory(ParamFactory): # E.g., VectorParam.Int(5, "number of widgets") def __call__(self, *args, **kwargs): - return _VectorParam(self.ptype, *args, **kwargs) + return VectorParamBase(self.ptype, *args, **kwargs) -VectorParam = _VectorParamProxy(None) +VectorParam = VectorParamFactory(None) ##################################################################### # @@ -963,127 +999,212 @@ VectorParam = _VectorParamProxy(None) # to correspond to distinct C++ types as well. # ##################################################################### -# Integer parameter type. -class _CheckedInt(object): + +class MetaRange(type): + def __init__(cls, name, bases, dict): + super(MetaRange, cls).__init__(name, bases, dict) + if name == 'Range': + return + cls._cpp_param_decl = 'Range<%s>' % cls.type._cpp_param_decl + def _convert(cls, value): - t = type(value) - if t == bool: - return int(value) + if not isinstance(value, Range): + raise TypeError, 'value %s is not a Pair' % value + value = cls(value) + value.first = cls.type._convert(value.first) + value.second = cls.type._convert(value.second) + return value - if t != int and t != long and t != float and t != str: - raise TypeError, 'Integer parameter of invalid type %s' % t + def _string(cls, value): + first = int(value.first) + second = int(value.second) + if value.extend: + second += first + if not value.inclusive: + second -= 1 + return '%s:%s' % (cls.type._string(first), cls.type._string(second)) + +class Range(ParamType): + __metaclass__ = MetaRange + def __init__(self, *args, **kwargs): + if len(args) == 0: + self.first = kwargs.pop('start') + + if 'end' in kwargs: + self.second = kwargs.pop('end') + self.inclusive = True + self.extend = False + elif 'size' in kwargs: + self.second = kwargs.pop('size') + self.inclusive = False + self.extend = True + else: + raise TypeError, "Either end or size must be specified" + + elif len(args) == 1: + if kwargs: + self.first = args[0] + if 'end' in kwargs: + self.second = kwargs.pop('end') + self.inclusive = True + self.extend = False + elif 'size' in kwargs: + self.second = kwargs.pop('size') + self.inclusive = False + self.extend = True + else: + raise TypeError, "Either end or size must be specified" + elif isinstance(args[0], Range): + self.first = args[0].first + self.second = args[0].second + self.inclusive = args[0].inclusive + self.extend = args[0].extend + else: + self.first = 0 + self.second = args[0] + self.inclusive = False + self.extend = True + + elif len(args) == 2: + self.first, self.second = args + self.inclusive = True + self.extend = False + else: + raise TypeError, "Too many arguments specified" - if t == str or t == float: - value = long(value) + if kwargs: + raise TypeError, "too many keywords: %s" % kwargs.keys() - if not cls._min <= value <= cls._max: - raise TypeError, 'Integer parameter out of bounds %d < %d < %d' % \ - (cls._min, value, cls._max) +# Metaclass for bounds-checked integer parameters. See CheckedInt. +class CheckedIntType(type): + def __init__(cls, name, bases, dict): + super(CheckedIntType, cls).__init__(name, bases, dict) - return value - _convert = classmethod(_convert) + # CheckedInt is an abstract base class, so we actually don't + # want to do any processing on it... the rest of this code is + # just for classes that derive from CheckedInt. + if name == 'CheckedInt': + return - def _string(cls, value): - return str(value) - _string = classmethod(_string) + if not (hasattr(cls, 'min') and hasattr(cls, 'max')): + if not (hasattr(cls, 'size') and hasattr(cls, 'unsigned')): + panic("CheckedInt subclass %s must define either\n" \ + " 'min' and 'max' or 'size' and 'unsigned'\n" \ + % name); + if cls.unsigned: + cls.min = 0 + cls.max = 2 ** cls.size - 1 + else: + cls.min = -(2 ** (cls.size - 1)) + cls.max = (2 ** (cls.size - 1)) - 1 -class CheckedInt(type): - def __new__(cls, cppname, min, max): - # New class derives from _CheckedInt base with proper bounding - # parameters - dict = { '_cppname' : cppname, '_min' : min, '_max' : max } - return type.__new__(cls, cppname, (_CheckedInt, ), dict) - -class CheckedIntType(CheckedInt): - def __new__(cls, cppname, size, unsigned): - dict = {} - if unsigned: - min = 0 - max = 2 ** size - 1 - else: - min = -(2 ** (size - 1)) - max = (2 ** (size - 1)) - 1 + cls._cpp_param_decl = cls.cppname + + def _convert(cls, value): + if isinstance(value, bool): + return int(value) - return super(cls, CheckedIntType).__new__(cls, cppname, min, max) + if not isinstance(value, (int, long, float, str)): + raise TypeError, 'Integer param of invalid type %s' % type(value) -Int = CheckedIntType('int', 32, False) -Unsigned = CheckedIntType('unsigned', 32, True) + if isinstance(value, float): + value = long(value) + elif isinstance(value, str): + value = toInteger(value) -Int8 = CheckedIntType('int8_t', 8, False) -UInt8 = CheckedIntType('uint8_t', 8, True) -Int16 = CheckedIntType('int16_t', 16, False) -UInt16 = CheckedIntType('uint16_t', 16, True) -Int32 = CheckedIntType('int32_t', 32, False) -UInt32 = CheckedIntType('uint32_t', 32, True) -Int64 = CheckedIntType('int64_t', 64, False) -UInt64 = CheckedIntType('uint64_t', 64, True) + if not cls.min <= value <= cls.max: + raise TypeError, 'Integer param out of bounds %d < %d < %d' % \ + (cls.min, value, cls.max) -Counter = CheckedIntType('Counter', 64, True) -Addr = CheckedIntType('Addr', 64, True) -Tick = CheckedIntType('Tick', 64, True) + return value -Percent = CheckedInt('int', 0, 100) + def _string(cls, value): + return str(value) -class Pair(object): - def __init__(self, first, second): - self.first = first - self.second = second +# Abstract superclass for bounds-checked integer parameters. This +# class is subclassed to generate parameter classes with specific +# bounds. Initialization of the min and max bounds is done in the +# metaclass CheckedIntType.__init__. +class CheckedInt(long,ParamType): + __metaclass__ = CheckedIntType + +class Int(CheckedInt): cppname = 'int'; size = 32; unsigned = False +class Unsigned(CheckedInt): cppname = 'unsigned'; size = 32; unsigned = True + +class Int8(CheckedInt): cppname = 'int8_t'; size = 8; unsigned = False +class UInt8(CheckedInt): cppname = 'uint8_t'; size = 8; unsigned = True +class Int16(CheckedInt): cppname = 'int16_t'; size = 16; unsigned = False +class UInt16(CheckedInt): cppname = 'uint16_t'; size = 16; unsigned = True +class Int32(CheckedInt): cppname = 'int32_t'; size = 32; unsigned = False +class UInt32(CheckedInt): cppname = 'uint32_t'; size = 32; unsigned = True +class Int64(CheckedInt): cppname = 'int64_t'; size = 64; unsigned = False +class UInt64(CheckedInt): cppname = 'uint64_t'; size = 64; unsigned = True + +class Counter(CheckedInt): cppname = 'Counter'; size = 64; unsigned = True +class Tick(CheckedInt): cppname = 'Tick'; size = 64; unsigned = True + +class Percent(CheckedInt): cppname = 'int'; min = 0; max = 100 + +class MemorySize(CheckedInt): + cppname = 'uint64_t' + size = 64 + unsigned = True + def __new__(cls, value): + return super(MemorySize, cls).__new__(cls, toMemorySize(value)) -class _Range(object): def _convert(cls, value): - if not isinstance(value, Pair): - raise TypeError, 'value %s is not a Pair' % value - return Pair(cls._type._convert(value.first), - cls._type._convert(value.second)) + return cls(value) _convert = classmethod(_convert) def _string(cls, value): - return '%s:%s' % (cls._type._string(value.first), - cls._type._string(value.second)) + return '%d' % value _string = classmethod(_string) -def RangeSize(start, size): - return Pair(start, start + size - 1) - -class Range(type): - def __new__(cls, type): - dict = { '_cppname' : 'Range<%s>' % type._cppname, '_type' : type } - clsname = 'Range_' + type.__name__ - return super(cls, Range).__new__(cls, clsname, (_Range, ), dict) +class Addr(CheckedInt): + cppname = 'Addr' + size = 64 + unsigned = True + def __new__(cls, value): + try: + value = long(toMemorySize(value)) + except TypeError: + value = long(value) + return super(Addr, cls).__new__(cls, value) -AddrRange = Range(Addr) + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) -# Boolean parameter type. -class Bool(object): - _cppname = 'bool' - def _convert(value): - t = type(value) - if t == bool: - return value + def _string(cls, value): + return '%d' % value + _string = classmethod(_string) - if t == int or t == long: - return bool(value) +class AddrRange(Range): + type = Addr - if t == str: - v = value.lower() - if v == "true" or v == "t" or v == "yes" or v == "y": - return True - elif v == "false" or v == "f" or v == "no" or v == "n": - return False +# Boolean parameter type. +class Bool(ParamType): + _cpp_param_decl = 'bool' + def __init__(self, value): + try: + self.value = toBool(value) + except TypeError: + self.value = bool(value) - raise TypeError, 'Bool parameter (%s) of invalid type %s' % (v, t) - _convert = staticmethod(_convert) + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) - def _string(value): - if value: + def _string(cls, value): + if value.value: return "true" else: return "false" - _string = staticmethod(_string) + _string = classmethod(_string) # String-valued parameter. -class String(object): - _cppname = 'string' +class String(ParamType): + _cpp_param_decl = 'string' # Constructor. Value must be Python string. def _convert(cls,value): @@ -1101,7 +1222,6 @@ class String(object): return value _string = classmethod(_string) - def IncEthernetAddr(addr, val = 1): bytes = map(lambda x: int(x, 16), addr.split(':')) bytes[5] += val @@ -1122,8 +1242,8 @@ class NextEthernetAddr(object): self.value = self.addr self.addr = IncEthernetAddr(self.addr, inc) -class EthernetAddr(object): - _cppname = 'EthAddr' +class EthernetAddr(ParamType): + _cpp_param_decl = 'EthAddr' def _convert(cls, value): if value == NextEthernetAddr: @@ -1155,15 +1275,10 @@ class EthernetAddr(object): # only one copy of a particular node class NullSimObject(object): __metaclass__ = Singleton - _cppname = 'NULL' def __call__(cls): return cls - def _sim_code(cls): - pass - _sim_code = classmethod(_sim_code) - def _instantiate(self, parent = None, path = ''): pass @@ -1200,12 +1315,47 @@ Null = NULL = NullSimObject() # derive the new type from the appropriate base class on the fly. -# Base class for Enum types. -class _Enum(object): +# Metaclass for Enum types +class MetaEnum(type): + def __init__(cls, name, bases, init_dict): + if init_dict.has_key('map'): + if not isinstance(cls.map, dict): + raise TypeError, "Enum-derived class attribute 'map' " \ + "must be of type dict" + # build list of value strings from map + cls.vals = cls.map.keys() + cls.vals.sort() + elif init_dict.has_key('vals'): + if not isinstance(cls.vals, list): + raise TypeError, "Enum-derived class attribute 'vals' " \ + "must be of type list" + # build string->value map from vals sequence + cls.map = {} + for idx,val in enumerate(cls.vals): + cls.map[val] = idx + else: + raise TypeError, "Enum-derived class must define "\ + "attribute 'map' or 'vals'" + + cls._cpp_param_decl = name + + super(MetaEnum, cls).__init__(name, bases, init_dict) + + def cpp_declare(cls): + s = 'enum %s {\n ' % cls.__name__ + s += ',\n '.join(['%s = %d' % (v,cls.map[v]) for v in cls.vals]) + s += '\n};\n' + return s + +# Base class for enum types. +class Enum(ParamType): + __metaclass__ = MetaEnum + vals = [] + def _convert(self, value): if value not in self.map: raise TypeError, "Enum param got bad value '%s' (not in %s)" \ - % (value, self.map) + % (value, self.vals) return value _convert = classmethod(_convert) @@ -1214,57 +1364,125 @@ class _Enum(object): return str(value) _string = classmethod(_string) -# Enum metaclass... calling Enum(foo) generates a new type (class) -# that derives from _ListEnum or _DictEnum as appropriate. -class Enum(type): - # counter to generate unique names for generated classes - counter = 1 +root_frequency = None - def __new__(cls, *args): - if len(args) > 1: - enum_map = args - else: - enum_map = args[0] - - if isinstance(enum_map, dict): - map = enum_map - elif issequence(enum_map): - map = {} - for idx,val in enumerate(enum_map): - map[val] = idx - else: - raise TypeError, "Enum map must be list or dict (got %s)" % map +# +# "Constants"... handy aliases for various values. +# +class RootFrequency(float,ParamType): + _cpp_param_decl = 'Tick' - classname = "Enum%04d" % Enum.counter - Enum.counter += 1 + def __new__(cls, value): + return super(cls, RootFrequency).__new__(cls, toFrequency(value)) - # New class derives from _Enum base, and gets a 'map' - # attribute containing the specified list or dict. - return type.__new__(cls, classname, (_Enum, ), { 'map': map }) + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) + def _string(cls, value): + return '%d' % int(value) + _string = classmethod(_string) -# -# "Constants"... handy aliases for various values. -# +class ClockPeriod(float,ParamType): + _cpp_param_decl = 'Tick' + def __new__(cls, value): + relative = False + try: + val = toClockPeriod(value) + except ValueError, e: + relative = True + if value.endswith('f'): + val = float(value[:-1]) + if val: + val = 1 / val + elif value.endswith('c'): + val = float(value[:-1]) + else: + raise e -# Some memory range specifications use this as a default upper bound. -MAX_ADDR = Addr._max -MaxTick = Tick._max + self = super(cls, ClockPeriod).__new__(cls, val) + self.relative = relative + return self + + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) + + def _string(cls, value): + if not value.relative: + value *= root_frequency + + return '%d' % int(value) + _string = classmethod(_string) -# For power-of-two sizing, e.g. 64*K gives an integer value 65536. -K = 1024 -M = K*K -G = K*M +class Frequency(float,ParamType): + _cpp_param_decl = 'Tick' + + def __new__(cls, value): + relative = False + try: + val = toFrequency(value) + except ValueError, e: + if value.endswith('f'): + val = float(value[:-1]) + relative = True + else: + raise e + self = super(cls, Frequency).__new__(cls, val) + self.relative = relative + return self + + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) + + def _string(cls, value): + if not value.relative: + value = root_frequency / value + + return '%d' % int(value) + _string = classmethod(_string) + +class Latency(float,ParamType): + _cpp_param_decl = 'Tick' + def __new__(cls, value): + relative = False + try: + val = toLatency(value) + except ValueError, e: + if value.endswith('c'): + val = float(value[:-1]) + relative = True + else: + raise e + self = super(cls, Latency).__new__(cls, val) + self.relative = relative + return self + + def _convert(cls, value): + return cls(value) + _convert = classmethod(_convert) + + def _string(cls, value): + if not value.relative: + value *= root_frequency + return '%d' % value + _string = classmethod(_string) + + +# Some memory range specifications use this as a default upper bound. +MaxAddr = Addr.max +MaxTick = Tick.max +AllMemory = AddrRange(0, MaxAddr) ##################################################################### # The final hook to generate .ini files. Called from configuration # script once config is built. def instantiate(root): - if not issubclass(root, Root): - raise AttributeError, 'Can only instantiate the Root of the tree' - + global root_frequency instance = root.instantiate('root') + root_frequency = RootFrequency._convert(root.frequency._getattr()) instance.fixup() instance.display() if not noDot: @@ -1277,5 +1495,27 @@ def instantiate(root): dot.write("config.dot") dot.write_ps("config.ps") -from objects import * - +# SimObject is a minimal extension of ConfigNode, implementing a +# hierarchy node that corresponds to an M5 SimObject. It prints out a +# "type=" line to indicate its SimObject class, prints out the +# assigned parameters corresponding to its class, and allows +# parameters to be set by keyword in the constructor. Note that most +# of the heavy lifting for the SimObject param handling is done in the +# MetaConfigNode metaclass. +class SimObject(ConfigNode, ParamType): + __metaclass__ = MetaSimObject + type = 'SimObject' + + +# __all__ defines the list of symbols that get exported when +# 'from config import *' is invoked. Try to keep this reasonably +# short to avoid polluting other namespaces. +__all__ = ['ConfigNode', 'SimObject', 'ParamContext', 'Param', 'VectorParam', + 'parent', 'Enum', + 'Int', 'Unsigned', 'Int8', 'UInt8', 'Int16', 'UInt16', + 'Int32', 'UInt32', 'Int64', 'UInt64', + 'Counter', 'Addr', 'Tick', 'Percent', + 'MemorySize', 'RootFrequency', 'Frequency', 'Latency', + 'ClockPeriod', + 'Range', 'AddrRange', 'MaxAddr', 'MaxTick', 'AllMemory', 'NULL', + 'NextEthernetAddr', 'instantiate'] diff --git a/python/m5/convert.py b/python/m5/convert.py new file mode 100644 index 000000000..6ccefd2fc --- /dev/null +++ b/python/m5/convert.py @@ -0,0 +1,206 @@ +# metric prefixes +exa = 1.0e18 +peta = 1.0e15 +tera = 1.0e12 +giga = 1.0e9 +mega = 1.0e6 +kilo = 1.0e3 + +milli = 1.0e-3 +micro = 1.0e-6 +nano = 1.0e-9 +pico = 1.0e-12 +femto = 1.0e-15 +atto = 1.0e-18 + +# power of 2 prefixes +kibi = 1024 +mebi = kibi * 1024 +gibi = mebi * 1024 +tebi = gibi * 1024 +pebi = tebi * 1024 +exbi = pebi * 1024 + +# memory size configuration stuff +def toFloat(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('Ei'): + return float(value[:-2]) * exbi + elif value.endswith('Pi'): + return float(value[:-2]) * pebi + elif value.endswith('Ti'): + return float(value[:-2]) * tebi + elif value.endswith('Gi'): + return float(value[:-2]) * gibi + elif value.endswith('Mi'): + return float(value[:-2]) * mebi + elif value.endswith('ki'): + return float(value[:-2]) * kibi + elif value.endswith('E'): + return float(value[:-1]) * exa + elif value.endswith('P'): + return float(value[:-1]) * peta + elif value.endswith('T'): + return float(value[:-1]) * tera + elif value.endswith('G'): + return float(value[:-1]) * giga + elif value.endswith('M'): + return float(value[:-1]) * mega + elif value.endswith('k'): + return float(value[:-1]) * kilo + elif value.endswith('m'): + return float(value[:-1]) * milli + elif value.endswith('u'): + return float(value[:-1]) * micro + elif value.endswith('n'): + return float(value[:-1]) * nano + elif value.endswith('p'): + return float(value[:-1]) * pico + elif value.endswith('f'): + return float(value[:-1]) * femto + else: + return float(value) + +def toLong(value): + value = toFloat(value) + result = int(value) + if value != result: + raise ValueError, "cannot convert '%s' to long" % value + + return result + +def toInteger(value): + value = toFloat(value) + result = int(value) + if value != result: + raise ValueError, "cannot convert '%s' to integer" % value + + return result + +def toBool(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + value = value.lower() + if value == "true" or value == "t" or value == "yes" or value == "y": + return True + elif value == "false" or value == "f" or value == "no" or value == "n": + return False + + raise ValueError, "cannot convert '%s' to bool" % value + +def toFrequency(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('THz'): + return float(value[:-3]) * tera + elif value.endswith('GHz'): + return float(value[:-3]) * giga + elif value.endswith('MHz'): + return float(value[:-3]) * mega + elif value.endswith('kHz'): + return float(value[:-3]) * kilo + elif value.endswith('Hz'): + return float(value[:-2]) + + raise ValueError, "cannot convert '%s' to frequency" % value + +def toLatency(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('ps'): + return float(value[:-2]) * pico + elif value.endswith('ns'): + return float(value[:-2]) * nano + elif value.endswith('us'): + return float(value[:-2]) * micro + elif value.endswith('ms'): + return float(value[:-2]) * milli + elif value.endswith('s'): + return float(value[:-1]) + + raise ValueError, "cannot convert '%s' to latency" % value + +def toClockPeriod(value): + """result is a clock period""" + + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + try: + val = toFrequency(value) + if val != 0: + val = 1 / val + return val + except ValueError: + pass + + try: + val = toLatency(value) + return val + except ValueError: + pass + + raise ValueError, "cannot convert '%s' to clock period" % value + + +def toNetworkBandwidth(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('Tbps'): + return float(value[:-3]) * tera + elif value.endswith('Gbps'): + return float(value[:-3]) * giga + elif value.endswith('Mbps'): + return float(value[:-3]) * mega + elif value.endswith('kbps'): + return float(value[:-3]) * kilo + elif value.endswith('bps'): + return float(value[:-2]) + else: + return float(value) + + raise ValueError, "cannot convert '%s' to network bandwidth" % value + +def toMemoryBandwidth(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('PB/s'): + return float(value[:-4]) * pebi + elif value.endswith('TB/s'): + return float(value[:-4]) * tebi + elif value.endswith('GB/s'): + return float(value[:-4]) * gibi + elif value.endswith('MB/s'): + return float(value[:-4]) * mebi + elif value.endswith('kB/s'): + return float(value[:-4]) * kibi + elif value.endswith('B/s'): + return float(value[:-3]) + + raise ValueError, "cannot convert '%s' to memory bandwidth" % value + +def toMemorySize(value): + if not isinstance(value, str): + raise TypeError, "wrong type '%s' should be str" % type(value) + + if value.endswith('PB'): + return float(value[:-2]) * pebi + elif value.endswith('TB'): + return float(value[:-2]) * tebi + elif value.endswith('GB'): + return float(value[:-2]) * gibi + elif value.endswith('MB'): + return float(value[:-2]) * mebi + elif value.endswith('kB'): + return float(value[:-2]) * kibi + elif value.endswith('B'): + return float(value[:-1]) + + raise ValueError, "cannot convert '%s' to memory size" % value diff --git a/python/m5/multidict.py b/python/m5/multidict.py new file mode 100644 index 000000000..d0c27fa8e --- /dev/null +++ b/python/m5/multidict.py @@ -0,0 +1,158 @@ +__all__ = [ 'multidict' ] + +class multidict(object): + __nodefault = object() + def __init__(self, parent = {}, **kwargs): + self.dict = dict(**kwargs) + self.parent = parent + self.deleted = {} + + def __str__(self): + return str(dict(self.items())) + + def __repr__(self): + return `dict(self.items())` + + def __contains__(self, key): + return self.dict.has_key(key) or self.parent.has_key(key) + + def __delitem__(self, key): + try: + del self.dict[key] + except KeyError, e: + if key in self.parent: + self.deleted[key] = True + else: + raise KeyError, e + + def __setitem__(self, key, value): + self.deleted.pop(key, False) + self.dict[key] = value + + def __getitem__(self, key): + try: + return self.dict[key] + except KeyError, e: + if not self.deleted.get(key, False) and key in self.parent: + return self.parent[key] + else: + raise KeyError, e + + def __len__(self): + return len(self.dict) + len(self.parent) + + def next(self): + for key,value in self.dict.items(): + yield key,value + + if self.parent: + for key,value in self.parent.next(): + if key not in self.dict and key not in self.deleted: + yield key,value + + def has_key(self, key): + return key in self + + def iteritems(self): + for item in self.next(): + yield item + + def items(self): + return [ item for item in self.next() ] + + def iterkeys(self): + for key,value in self.next(): + yield key + + def keys(self): + return [ key for key,value in self.next() ] + + def itervalues(self): + for key,value in self.next(): + yield value + + def values(self): + return [ value for key,value in self.next() ] + + def get(self, key, default=__nodefault): + try: + return self[key] + except KeyError, e: + if default != self.__nodefault: + return default + else: + raise KeyError, e + + def setdefault(self, key, default): + try: + return self[key] + except KeyError: + self.deleted.pop(key, False) + self.dict[key] = default + return default + + def _dump(self): + print 'multidict dump' + node = self + while isinstance(node, multidict): + print ' ', node.dict + node = node.parent + + def _dumpkey(self, key): + values = [] + node = self + while isinstance(node, multidict): + if key in node.dict: + values.append(node.dict[key]) + node = node.parent + print key, values + +if __name__ == '__main__': + test1 = multidict() + test2 = multidict(test1) + test3 = multidict(test2) + test4 = multidict(test3) + + test1['a'] = 'test1_a' + test1['b'] = 'test1_b' + test1['c'] = 'test1_c' + test1['d'] = 'test1_d' + test1['e'] = 'test1_e' + + test2['a'] = 'test2_a' + del test2['b'] + test2['c'] = 'test2_c' + del test1['a'] + + test2.setdefault('f', multidict) + + print 'test1>', test1.items() + print 'test2>', test2.items() + #print test1['a'] + print test1['b'] + print test1['c'] + print test1['d'] + print test1['e'] + + print test2['a'] + #print test2['b'] + print test2['c'] + print test2['d'] + print test2['e'] + + for key in test2.iterkeys(): + print key + + test2.get('g', 'foo') + #test2.get('b') + test2.get('b', 'bar') + test2.setdefault('b', 'blah') + print test1 + print test2 + print `test2` + + print len(test2) + + test3['a'] = [ 0, 1, 2, 3 ] + + print test4 diff --git a/python/m5/objects/AlphaConsole.mpy b/python/m5/objects/AlphaConsole.mpy new file mode 100644 index 000000000..63aea5b7d --- /dev/null +++ b/python/m5/objects/AlphaConsole.mpy @@ -0,0 +1,9 @@ +from Device import PioDevice + +simobj AlphaConsole(PioDevice): + type = 'AlphaConsole' + cpu = Param.BaseCPU(parent.any, "Processor") + disk = Param.SimpleDisk("Simple Disk") + num_cpus = Param.Int(1, "Number of CPUs") + sim_console = Param.SimConsole(parent.any, "The Simulator Console") + system = Param.BaseSystem(parent.any, "system object") diff --git a/objects/AlphaTLB.mpy b/python/m5/objects/AlphaTLB.mpy index 8e7cd62cc..8e7cd62cc 100644 --- a/objects/AlphaTLB.mpy +++ b/python/m5/objects/AlphaTLB.mpy diff --git a/objects/BadDevice.mpy b/python/m5/objects/BadDevice.mpy index 35a12e0bf..35a12e0bf 100644 --- a/objects/BadDevice.mpy +++ b/python/m5/objects/BadDevice.mpy diff --git a/python/m5/objects/BaseCPU.mpy b/python/m5/objects/BaseCPU.mpy new file mode 100644 index 000000000..d84e30e53 --- /dev/null +++ b/python/m5/objects/BaseCPU.mpy @@ -0,0 +1,25 @@ +simobj BaseCPU(SimObject): + type = 'BaseCPU' + abstract = True + icache = Param.BaseMem(NULL, "L1 instruction cache object") + dcache = Param.BaseMem(NULL, "L1 data cache object") + + if build_env['FULL_SYSTEM']: + dtb = Param.AlphaDTB("Data TLB") + itb = Param.AlphaITB("Instruction TLB") + mem = Param.FunctionalMemory("memory") + system = Param.BaseSystem(parent.any, "system object") + else: + workload = VectorParam.Process("processes to run") + + max_insts_all_threads = Param.Counter(0, + "terminate when all threads have reached this inst count") + max_insts_any_thread = Param.Counter(0, + "terminate when any thread reaches this inst count") + max_loads_all_threads = Param.Counter(0, + "terminate when all threads have reached this load count") + max_loads_any_thread = Param.Counter(0, + "terminate when any thread reaches this load count") + + defer_registration = Param.Bool(False, + "defer registration with system (for sampling)") diff --git a/objects/BaseCache.mpy b/python/m5/objects/BaseCache.mpy index cb3e56de6..198665325 100644 --- a/objects/BaseCache.mpy +++ b/python/m5/objects/BaseCache.mpy @@ -23,7 +23,7 @@ simobj BaseCache(BaseMem): "always service demand misses first") protocol = Param.CoherenceProtocol(NULL, "coherence protocol to use") repl = Param.Repl(NULL, "replacement policy") - size = Param.Int("capacity in bytes") + size = Param.MemorySize("capacity in bytes") split = Param.Bool(False, "whether or not this cache is split") split_size = Param.Int(0, "How many ways of the cache belong to CPU/LRU partition") diff --git a/objects/BaseSystem.mpy b/python/m5/objects/BaseSystem.mpy index 1cbdf4e99..450b6a58e 100644 --- a/objects/BaseSystem.mpy +++ b/python/m5/objects/BaseSystem.mpy @@ -1,8 +1,8 @@ simobj BaseSystem(SimObject): type = 'BaseSystem' abstract = True - memctrl = Param.MemoryController(Super, "memory controller") - physmem = Param.PhysicalMemory(Super, "phsyical memory") + memctrl = Param.MemoryController(parent.any, "memory controller") + physmem = Param.PhysicalMemory(parent.any, "phsyical memory") kernel = Param.String("file that contains the kernel code") console = Param.String("file that contains the console code") pal = Param.String("file that contains palcode") diff --git a/objects/Bus.mpy b/python/m5/objects/Bus.mpy index 025d69785..aa12f757a 100644 --- a/objects/Bus.mpy +++ b/python/m5/objects/Bus.mpy @@ -2,5 +2,5 @@ from BaseHier import BaseHier simobj Bus(BaseHier): type = 'Bus' - clock_ratio = Param.Int("ratio of CPU to bus frequency") + clock_ratio = Param.ClockPeriod("ratio of CPU to bus frequency") width = Param.Int("bus width in bytes") diff --git a/objects/CoherenceProtocol.mpy b/python/m5/objects/CoherenceProtocol.mpy index ae041b638..f3b0026b7 100644 --- a/objects/CoherenceProtocol.mpy +++ b/python/m5/objects/CoherenceProtocol.mpy @@ -1,4 +1,4 @@ -Coherence = Enum('uni', 'msi', 'mesi', 'mosi', 'moesi') +class Coherence(Enum): vals = ['uni', 'msi', 'mesi', 'mosi', 'moesi'] simobj CoherenceProtocol(SimObject): type = 'CoherenceProtocol' diff --git a/objects/Device.mpy b/python/m5/objects/Device.mpy index 47f8db1cb..a0d02a647 100644 --- a/objects/Device.mpy +++ b/python/m5/objects/Device.mpy @@ -14,7 +14,7 @@ simobj FooPioDevice(FunctionalMemory): type = 'PioDevice' abstract = True addr = Param.Addr("Device Address") - mmu = Param.MemoryController(Super, "Memory Controller") + mmu = Param.MemoryController(parent.any, "Memory Controller") io_bus = Param.Bus(NULL, "The IO Bus to attach to") pio_latency = Param.Tick(1, "Programmed IO latency in bus cycles") @@ -25,7 +25,7 @@ simobj FooDmaDevice(FooPioDevice): simobj PioDevice(FooPioDevice): type = 'PioDevice' abstract = True - platform = Param.Platform(Super, "Platform") + platform = Param.Platform(parent.any, "Platform") simobj DmaDevice(PioDevice): type = 'DmaDevice' diff --git a/objects/DiskImage.mpy b/python/m5/objects/DiskImage.mpy index 80ef7b072..80ef7b072 100644 --- a/objects/DiskImage.mpy +++ b/python/m5/objects/DiskImage.mpy diff --git a/objects/Ethernet.mpy b/python/m5/objects/Ethernet.mpy index 088df4b93..3acd8d04d 100644 --- a/objects/Ethernet.mpy +++ b/python/m5/objects/Ethernet.mpy @@ -49,8 +49,8 @@ simobj EtherDev(DmaDevice): intr_delay = Param.Tick(0, "Interrupt Delay in microseconds") payload_bus = Param.Bus(NULL, "The IO Bus to attach to for payload") - physmem = Param.PhysicalMemory(Super, "Physical Memory") - tlaser = Param.Turbolaser(Super, "Turbolaser") + physmem = Param.PhysicalMemory(parent.any, "Physical Memory") + tlaser = Param.Turbolaser(parent.any, "Turbolaser") simobj NSGigE(PciDevice): type = 'NSGigE' @@ -68,12 +68,12 @@ simobj NSGigE(PciDevice): rx_delay = Param.Tick(1000, "Receive Delay") tx_delay = Param.Tick(1000, "Transmit Delay") - rx_fifo_size = Param.Int(131072, "max size in bytes of rxFifo") - tx_fifo_size = Param.Int(131072, "max size in bytes of txFifo") + rx_fifo_size = Param.MemorySize('128kB', "max size in bytes of rxFifo") + tx_fifo_size = Param.MemorySize('128kB', "max size in bytes of txFifo") intr_delay = Param.Tick(0, "Interrupt Delay in microseconds") payload_bus = Param.Bus(NULL, "The IO Bus to attach to for payload") - physmem = Param.PhysicalMemory(Super, "Physical Memory") + physmem = Param.PhysicalMemory(parent.any, "Physical Memory") simobj EtherDevInt(EtherInt): type = 'EtherDevInt' diff --git a/objects/Ide.mpy b/python/m5/objects/Ide.mpy index c4aa2aca0..786109efa 100644 --- a/objects/Ide.mpy +++ b/python/m5/objects/Ide.mpy @@ -1,13 +1,13 @@ from Pci import PciDevice -IdeID = Enum('master', 'slave') +class IdeID(Enum): vals = ['master', 'slave'] simobj IdeDisk(SimObject): type = 'IdeDisk' delay = Param.Tick(1, "Fixed disk delay in microseconds") driveID = Param.IdeID('master', "Drive ID") image = Param.DiskImage("Disk image") - physmem = Param.PhysicalMemory(Super, "Physical memory") + physmem = Param.PhysicalMemory(parent.any, "Physical memory") simobj IdeController(PciDevice): type = 'IdeController' diff --git a/objects/IntrControl.mpy b/python/m5/objects/IntrControl.mpy index 1ef5a17ee..144be0fd4 100644 --- a/objects/IntrControl.mpy +++ b/python/m5/objects/IntrControl.mpy @@ -1,3 +1,3 @@ simobj IntrControl(SimObject): type = 'IntrControl' - cpu = Param.BaseCPU(Super, "the cpu") + cpu = Param.BaseCPU(parent.any, "the cpu") diff --git a/objects/MemTest.mpy b/python/m5/objects/MemTest.mpy index af14ed9c3..af14ed9c3 100644 --- a/objects/MemTest.mpy +++ b/python/m5/objects/MemTest.mpy diff --git a/objects/Pci.mpy b/python/m5/objects/Pci.mpy index caa3c52ff..b9b3e5a95 100644 --- a/objects/Pci.mpy +++ b/python/m5/objects/Pci.mpy @@ -1,8 +1,7 @@ from Device import FooPioDevice, DmaDevice -simobj PciConfigData(FooPioDevice): +simobj PciConfigData(SimObject): type = 'PciConfigData' - addr = 0xffffffffffffffffL VendorID = Param.UInt16("Vendor ID") DeviceID = Param.UInt16("Device ID") Command = Param.UInt16(0, "Command") @@ -44,9 +43,9 @@ simobj PciConfigAll(FooPioDevice): simobj PciDevice(DmaDevice): type = 'PciDevice' abstract = True + addr = 0xffffffffL pci_bus = Param.Int("PCI bus") pci_dev = Param.Int("PCI device number") pci_func = Param.Int("PCI function code") - configdata = Param.PciConfigData(Super, "PCI Config data") - configspace = Param.PciConfigAll(Super, "PCI Configspace") - addr = 0xffffffffffffffffL + configdata = Param.PciConfigData(parent.any, "PCI Config data") + configspace = Param.PciConfigAll(parent.any, "PCI Configspace") diff --git a/objects/PhysicalMemory.mpy b/python/m5/objects/PhysicalMemory.mpy index d1e4ad4b4..e6df2a161 100644 --- a/objects/PhysicalMemory.mpy +++ b/python/m5/objects/PhysicalMemory.mpy @@ -4,4 +4,4 @@ simobj PhysicalMemory(FunctionalMemory): type = 'PhysicalMemory' range = Param.AddrRange("Device Address") file = Param.String('', "memory mapped file") - mmu = Param.MemoryController(Super, "Memory Controller") + mmu = Param.MemoryController(parent.any, "Memory Controller") diff --git a/objects/Platform.mpy b/python/m5/objects/Platform.mpy index d0510eaf8..a71ab3b77 100644 --- a/objects/Platform.mpy +++ b/python/m5/objects/Platform.mpy @@ -2,4 +2,4 @@ simobj Platform(SimObject): type = 'Platform' abstract = True interrupt_frequency = Param.Tick(1200, "frequency of interrupts") - intrctrl = Param.IntrControl(Super, "interrupt controller") + intrctrl = Param.IntrControl(parent.any, "interrupt controller") diff --git a/objects/Process.mpy b/python/m5/objects/Process.mpy index 6a91c09c2..6a91c09c2 100644 --- a/objects/Process.mpy +++ b/python/m5/objects/Process.mpy diff --git a/objects/Repl.mpy b/python/m5/objects/Repl.mpy index fff5a2a02..fff5a2a02 100644 --- a/objects/Repl.mpy +++ b/python/m5/objects/Repl.mpy diff --git a/objects/Root.mpy b/python/m5/objects/Root.mpy index 0e531054b..c535bd2dc 100644 --- a/objects/Root.mpy +++ b/python/m5/objects/Root.mpy @@ -5,7 +5,7 @@ from Trace import Trace simobj Root(SimObject): type = 'Root' - frequency = Param.Tick(200000000, "tick frequency") + frequency = Param.RootFrequency('200MHz', "tick frequency") output_file = Param.String('cout', "file to dump simulator output to") full_system = Param.Bool("Full system simulation?") hier = HierParams(do_data = False, do_events = True) diff --git a/objects/SimConsole.mpy b/python/m5/objects/SimConsole.mpy index fb74f1775..3588a949d 100644 --- a/objects/SimConsole.mpy +++ b/python/m5/objects/SimConsole.mpy @@ -5,7 +5,7 @@ simobj ConsoleListener(SimObject): simobj SimConsole(SimObject): type = 'SimConsole' append_name = Param.Bool(True, "append name() to filename") - intr_control = Param.IntrControl(Super, "interrupt controller") + intr_control = Param.IntrControl(parent.any, "interrupt controller") listener = Param.ConsoleListener("console listener") number = Param.Int(0, "console number") output = Param.String('console', "file to dump output to") diff --git a/objects/SimpleDisk.mpy b/python/m5/objects/SimpleDisk.mpy index c4dd5435b..b616fb3d1 100644 --- a/objects/SimpleDisk.mpy +++ b/python/m5/objects/SimpleDisk.mpy @@ -1,4 +1,4 @@ simobj SimpleDisk(SimObject): type = 'SimpleDisk' disk = Param.DiskImage("Disk Image") - physmem = Param.PhysicalMemory(Super, "Physical Memory") + physmem = Param.PhysicalMemory(parent.any, "Physical Memory") diff --git a/objects/Tsunami.mpy b/python/m5/objects/Tsunami.mpy index cfe23977e..a8471cee2 100644 --- a/objects/Tsunami.mpy +++ b/python/m5/objects/Tsunami.mpy @@ -4,12 +4,12 @@ from Platform import Platform simobj Tsunami(Platform): type = 'Tsunami' pciconfig = Param.PciConfigAll("PCI configuration") - system = Param.BaseSystem(Super, "system") + system = Param.BaseSystem(parent.any, "system") interrupt_frequency = Param.Int(1024, "frequency of interrupts") simobj TsunamiCChip(FooPioDevice): type = 'TsunamiCChip' - tsunami = Param.Tsunami(Super, "Tsunami") + tsunami = Param.Tsunami(parent.any, "Tsunami") simobj TsunamiFake(FooPioDevice): type = 'TsunamiFake' @@ -18,8 +18,8 @@ simobj TsunamiIO(FooPioDevice): type = 'TsunamiIO' time = Param.UInt64(1136073600, "System time to use (0 for actual time, default is 1/1/06)") - tsunami = Param.Tsunami(Super, "Tsunami") + tsunami = Param.Tsunami(parent.any, "Tsunami") simobj TsunamiPChip(FooPioDevice): type = 'TsunamiPChip' - tsunami = Param.Tsunami(Super, "Tsunami") + tsunami = Param.Tsunami(parent.any, "Tsunami") diff --git a/objects/Uart.mpy b/python/m5/objects/Uart.mpy index 76ee8805f..5a6c25f8e 100644 --- a/objects/Uart.mpy +++ b/python/m5/objects/Uart.mpy @@ -2,5 +2,5 @@ from Device import PioDevice simobj Uart(PioDevice): type = 'Uart' - console = Param.SimConsole(Super, "The console") + console = Param.SimConsole(parent.any, "The console") size = Param.Addr(0x8, "Device size") diff --git a/python/m5/smartdict.py b/python/m5/smartdict.py new file mode 100644 index 000000000..a2661c279 --- /dev/null +++ b/python/m5/smartdict.py @@ -0,0 +1,126 @@ +# The SmartDict class fixes a couple of issues with using the content +# of os.environ or similar dicts of strings as Python variables: +# +# 1) Undefined variables should return False rather than raising KeyError. +# +# 2) String values of 'False', '0', etc., should evaluate to False +# (not just the empty string). +# +# #1 is solved by overriding __getitem__, and #2 is solved by using a +# proxy class for values and overriding __nonzero__ on the proxy. +# Everything else is just to (a) make proxies behave like normal +# values otherwise, (b) make sure any dict operation returns a proxy +# rather than a normal value, and (c) coerce values written to the +# dict to be strings. + + +from convert import * + +class Variable(str): + """Intelligent proxy class for SmartDict. Variable will use the + various convert functions to attempt to convert values to useable + types""" + def __int__(self): + return toInteger(str(self)) + def __long__(self): + return toLong(str(self)) + def __float__(self): + return toFloat(str(self)) + def __nonzero__(self): + return toBool(str(self)) + def convert(self, other): + t = type(other) + if t == bool: + return bool(self) + if t == int: + return int(self) + if t == long: + return long(self) + if t == float: + return float(self) + return str(self) + def __lt__(self, other): + return self.convert(other) < other + def __le__(self, other): + return self.convert(other) <= other + def __eq__(self, other): + return self.convert(other) == other + def __ne__(self, other): + return self.convert(other) != other + def __gt__(self, other): + return self.convert(other) > other + def __ge__(self, other): + return self.convert(other) >= other + + def __add__(self, other): + return self.convert(other) + other + def __sub__(self, other): + return self.convert(other) - other + def __mul__(self, other): + return self.convert(other) * other + def __div__(self, other): + return self.convert(other) / other + def __truediv__(self, other): + return self.convert(other) / other + + def __radd__(self, other): + return other + self.convert(other) + def __rsub__(self, other): + return other - self.convert(other) + def __rmul__(self, other): + return other * self.convert(other) + def __rdiv__(self, other): + return other / self.convert(other) + def __rtruediv__(self, other): + return other / self.convert(other) + +class UndefinedVariable(object): + """Placeholder class to represent undefined variables. Will + generally cause an exception whenever it is used, but evaluates to + zero for boolean truth testing such as in an if statement""" + def __nonzero__(self): + return False + +class SmartDict(dict): + """Dictionary class that holds strings, but intelligently converts + those strings to other types depending on their usage""" + + def __getitem__(self, key): + """returns a Variable proxy if the values exists in the database and + returns an UndefinedVariable otherwise""" + + if key in self: + return Variable(dict.get(self, key)) + else: + # Note that this does *not* change the contents of the dict, + # so that even after we call env['foo'] we still get a + # meaningful answer from "'foo' in env" (which + # calls dict.__contains__, which we do not override). + return UndefinedVariable() + + def __setitem__(self, key, item): + """intercept the setting of any variable so that we always + store strings in the dict""" + dict.__setitem__(self, key, str(item)) + + def values(self): + return [ Variable(v) for v in dict.values(self) ] + + def itervalues(self): + for value in dict.itervalues(self): + yield Variable(value) + + def items(self): + return [ (k, Variable(v)) for k,v in dict.items(self) ] + + def iteritems(self): + for key,value in dict.iteritems(self): + yield key, Variable(value) + + def get(self, key, default='False'): + return Variable(dict.get(self, key, str(default))) + + def setdefault(self, key, default='False'): + return Variable(dict.setdefault(self, key, str(default))) + +__all__ = [ 'SmartDict' ] diff --git a/sim/main.cc b/sim/main.cc index c15d24453..ee59cb83b 100644 --- a/sim/main.cc +++ b/sim/main.cc @@ -51,6 +51,7 @@ #include "base/time.hh" #include "cpu/base_cpu.hh" #include "cpu/full_cpu/smt.hh" +#include "python/pyconfig.hh" #include "sim/async.hh" #include "sim/builder.hh" #include "sim/configfile.hh" @@ -61,7 +62,6 @@ #include "sim/stat_control.hh" #include "sim/stats.hh" #include "sim/universe.hh" -#include "sim/pyconfig/pyconfig.hh" using namespace std; diff --git a/sim/process.cc b/sim/process.cc index acc6762f8..c18b31da7 100644 --- a/sim/process.cc +++ b/sim/process.cc @@ -65,14 +65,14 @@ using namespace std; // current number of allocated processes int num_processes = 0; -Process::Process(const string &name, +Process::Process(const string &nm, int stdin_fd, // initial I/O descriptors int stdout_fd, int stderr_fd) - : SimObject(name) + : SimObject(nm) { // allocate memory space - memory = new MainMemory(name + ".MainMem"); + memory = new MainMemory(nm + ".MainMem"); // allocate initial register file init_regs = new RegFile; @@ -88,6 +88,8 @@ Process::Process(const string &name, fd_map[i] = -1; } + mmap_start = mmap_end = 0; + nxm_start = nxm_end = 0; // other parameters will be initialized when the program is loaded } @@ -252,10 +254,10 @@ copyStringArray(vector<string> &strings, Addr array_ptr, Addr data_ptr, memory->access(Write, array_ptr, &data_ptr, sizeof(Addr)); } -LiveProcess::LiveProcess(const string &name, ObjectFile *objFile, +LiveProcess::LiveProcess(const string &nm, ObjectFile *objFile, int stdin_fd, int stdout_fd, int stderr_fd, vector<string> &argv, vector<string> &envp) - : Process(name, stdin_fd, stdout_fd, stderr_fd) + : Process(nm, stdin_fd, stdout_fd, stderr_fd) { prog_fname = argv[0]; @@ -339,7 +341,7 @@ LiveProcess::LiveProcess(const string &name, ObjectFile *objFile, LiveProcess * -LiveProcess::create(const string &name, +LiveProcess::create(const string &nm, int stdin_fd, int stdout_fd, int stderr_fd, vector<string> &argv, vector<string> &envp) { @@ -353,13 +355,13 @@ LiveProcess::create(const string &name, if (objFile->getArch() == ObjectFile::Alpha) { switch (objFile->getOpSys()) { case ObjectFile::Tru64: - process = new AlphaTru64Process(name, objFile, + process = new AlphaTru64Process(nm, objFile, stdin_fd, stdout_fd, stderr_fd, argv, envp); break; case ObjectFile::Linux: - process = new AlphaLinuxProcess(name, objFile, + process = new AlphaLinuxProcess(nm, objFile, stdin_fd, stdout_fd, stderr_fd, argv, envp); break; diff --git a/sim/process.hh b/sim/process.hh index 3bcc65da6..51d7639ac 100644 --- a/sim/process.hh +++ b/sim/process.hh @@ -42,6 +42,7 @@ #include "sim/sim_object.hh" #include "sim/stats.hh" #include "base/statistics.hh" +#include "base/trace.hh" class ExecContext; class FunctionalMemory; @@ -96,6 +97,10 @@ class Process : public SimObject Addr mmap_start; Addr mmap_end; + // Base of region for nxm data + Addr nxm_start; + Addr nxm_end; + std::string prog_fname; // file name Addr prog_entry; // entry point (initial PC) @@ -104,7 +109,7 @@ class Process : public SimObject protected: // constructor - Process(const std::string &name, + Process(const std::string &nm, int stdin_fd, // initial I/O descriptors int stdout_fd, int stderr_fd); @@ -158,9 +163,10 @@ class Process : public SimObject bool validDataAddr(Addr addr) { return ((data_base <= addr && addr < brk_point) || - ((stack_base - 16*1024*1024) <= addr && addr < stack_base) || + (next_thread_stack_base <= addr && addr < stack_base) || (text_base <= addr && addr < (text_base + text_size)) || - (mmap_start <= addr && addr < mmap_end)); + (mmap_start <= addr && addr < mmap_end) || + (nxm_start <= addr && addr < nxm_end)); } virtual void syscall(ExecContext *xc) = 0; @@ -175,7 +181,7 @@ class ObjectFile; class LiveProcess : public Process { protected: - LiveProcess(const std::string &name, ObjectFile *objFile, + LiveProcess(const std::string &nm, ObjectFile *objFile, int stdin_fd, int stdout_fd, int stderr_fd, std::vector<std::string> &argv, std::vector<std::string> &envp); @@ -184,7 +190,7 @@ class LiveProcess : public Process // this function is used to create the LiveProcess object, since // we can't tell which subclass of LiveProcess to use until we // open and look at the object file. - static LiveProcess *create(const std::string &name, + static LiveProcess *create(const std::string &nm, int stdin_fd, int stdout_fd, int stderr_fd, std::vector<std::string> &argv, std::vector<std::string> &envp); diff --git a/sim/sim_object.cc b/sim/sim_object.cc index 818648b98..559415102 100644 --- a/sim/sim_object.cc +++ b/sim/sim_object.cc @@ -61,14 +61,29 @@ namespace Stats { // // SimObject constructor: used to maintain static simObjectList // +SimObject::SimObject(Params *p) + : _params(p) +{ +#ifdef DEBUG + doDebugBreak = false; +#endif + + doRecordEvent = !Stats::event_ignore.match(name()); + simObjectList.push_back(this); +} + +// +// SimObject constructor: used to maintain static simObjectList +// SimObject::SimObject(const string &_name) - : objName(_name) + : _params(new Params) { + _params->name = _name; #ifdef DEBUG doDebugBreak = false; #endif - doRecordEvent = !Stats::event_ignore.match(_name); + doRecordEvent = !Stats::event_ignore.match(name()); simObjectList.push_back(this); } diff --git a/sim/sim_object.hh b/sim/sim_object.hh index f4b316ebb..db8d4f4d3 100644 --- a/sim/sim_object.hh +++ b/sim/sim_object.hh @@ -48,8 +48,16 @@ */ class SimObject : public Serializable, protected StartupCallback { + public: + struct Params { + std::string name; + }; + protected: - std::string objName; + Params *_params; + + public: + const Params *params() const { return _params; } private: friend class Serializer; @@ -60,11 +68,12 @@ class SimObject : public Serializable, protected StartupCallback static SimObjectList simObjectList; public: + SimObject(Params *_params); SimObject(const std::string &_name); virtual ~SimObject() {} - virtual const std::string name() const { return objName; } + virtual const std::string name() const { return params()->name; } // initialization pass of all objects. // Gets invoked after construction, before unserialize. diff --git a/sim/stat_control.cc b/sim/stat_control.cc index 8a8eaa790..4d72ce213 100644 --- a/sim/stat_control.cc +++ b/sim/stat_control.cc @@ -105,7 +105,7 @@ InitSimStats() ; simFreq - .scalar(ticksPerSecond) + .scalar(Clock::Frequency) .name("sim_freq") .desc("Frequency of simulated ticks") ; diff --git a/sim/syscall_emul.cc b/sim/syscall_emul.cc index a0cbdf414..22d62e4d1 100644 --- a/sim/syscall_emul.cc +++ b/sim/syscall_emul.cc @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2004 The Regents of The University of Michigan + * Copyright (c) 2003-2005 The Regents of The University of Michigan * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -47,17 +47,17 @@ SyscallDesc::doSyscall(int callnum, Process *process, ExecContext *xc) DPRINTFR(SyscallVerbose, "%s: syscall %s called\n", xc->cpu->name(), name); - int retval = (*funcPtr)(this, callnum, process, xc); + SyscallReturn retval = (*funcPtr)(this, callnum, process, xc); DPRINTFR(SyscallVerbose, "%s: syscall %s returns %d\n", - xc->cpu->name(), name, retval); + xc->cpu->name(), name, retval.value()); - if (!((flags & SyscallDesc::SuppressReturnValue) && retval == 0)) + if (!(flags & SyscallDesc::SuppressReturnValue)) xc->setSyscallReturn(retval); } -int +SyscallReturn unimplementedFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -70,7 +70,7 @@ unimplementedFunc(SyscallDesc *desc, int callnum, Process *process, } -int +SyscallReturn ignoreFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -83,7 +83,7 @@ ignoreFunc(SyscallDesc *desc, int callnum, Process *process, } -int +SyscallReturn exitFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -93,25 +93,28 @@ exitFunc(SyscallDesc *desc, int callnum, Process *process, } -int +SyscallReturn getpagesizeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { return VMPageSize; } -int +SyscallReturn obreakFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { // change brk addr to first arg Addr new_brk = xc->getSyscallArg(0); if (new_brk != 0) + { p->brk_point = xc->getSyscallArg(0); + } + DPRINTF(SyscallVerbose, "Break Point changed to: %#X\n", p->brk_point); return p->brk_point; } -int +SyscallReturn closeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { int fd = p->sim_fd(xc->getSyscallArg(0)); @@ -119,7 +122,7 @@ closeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) } -int +SyscallReturn readFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { int fd = p->sim_fd(xc->getSyscallArg(0)); @@ -134,7 +137,7 @@ readFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) return bytes_read; } -int +SyscallReturn writeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { int fd = p->sim_fd(xc->getSyscallArg(0)); @@ -151,7 +154,7 @@ writeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) } -int +SyscallReturn lseekFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { int fd = p->sim_fd(xc->getSyscallArg(0)); @@ -164,7 +167,7 @@ lseekFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) } -int +SyscallReturn munmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { // given that we don't really implement mmap, munmap is really easy @@ -174,7 +177,7 @@ munmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) const char *hostname = "m5.eecs.umich.edu"; -int +SyscallReturn gethostnameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { int name_len = xc->getSyscallArg(1); @@ -187,19 +190,19 @@ gethostnameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) return 0; } -int +SyscallReturn unlinkFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { std::string path; if (xc->mem->readString(path, xc->getSyscallArg(0)) != No_Fault) - return -EFAULT; + return (TheISA::IntReg)-EFAULT; int result = unlink(path.c_str()); return (result == -1) ? -errno : result; } -int +SyscallReturn renameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { std::string old_name; @@ -212,7 +215,7 @@ renameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) if (xc->mem->readString(new_name, xc->getSyscallArg(1)) != No_Fault) return -EFAULT; - int result = rename(old_name.c_str(),new_name.c_str()); + int64_t result = rename(old_name.c_str(),new_name.c_str()); return (result == -1) ? -errno : result; } diff --git a/sim/syscall_emul.hh b/sim/syscall_emul.hh index 831708a21..cc1692bfb 100644 --- a/sim/syscall_emul.hh +++ b/sim/syscall_emul.hh @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003-2004 The Regents of The University of Michigan + * Copyright (c) 2003-2005 The Regents of The University of Michigan * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -54,7 +54,7 @@ class SyscallDesc { public: /// Typedef for target syscall handler functions. - typedef int (*FuncPtr)(SyscallDesc *, int num, + typedef SyscallReturn (*FuncPtr)(SyscallDesc *, int num, Process *, ExecContext *); const char *name; //!< Syscall name (e.g., "open"). @@ -158,46 +158,46 @@ class TypedBufferArg : public BaseBufferArg /// Handler for unimplemented syscalls that we haven't thought about. -int unimplementedFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn unimplementedFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Handler for unimplemented syscalls that we never intend to /// implement (signal handling, etc.) and should not affect the correct /// behavior of the program. Print a warning only if the appropriate /// trace flag is enabled. Return success to the target program. -int ignoreFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn ignoreFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target exit() handler: terminate simulation. -int exitFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn exitFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target getpagesize() handler. -int getpagesizeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn getpagesizeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target obreak() handler: set brk address. -int obreakFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn obreakFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target close() handler. -int closeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn closeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target read() handler. -int readFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn readFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target write() handler. -int writeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn writeFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target lseek() handler. -int lseekFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn lseekFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target munmap() handler. -int munmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn munmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target gethostname() handler. -int gethostnameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn gethostnameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target unlink() handler. -int unlinkFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn unlinkFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// Target rename() handler. -int renameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); +SyscallReturn renameFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc); /// This struct is used to build an target-OS-dependent table that /// maps the target's open() flags to the host open() flags. @@ -222,9 +222,7 @@ template <class T1, class T2> void getElapsedTime(T1 &sec, T2 &usec) { - int cycles_per_usec = ticksPerSecond / one_million; - - int elapsed_usecs = curTick / cycles_per_usec; + int elapsed_usecs = curTick / Clock::Int::us; sec = elapsed_usecs / one_million; usec = elapsed_usecs % one_million; } @@ -240,7 +238,7 @@ getElapsedTime(T1 &sec, T2 &usec) /// only to find out if their stdout is a tty, to determine whether to /// do line or block buffering. template <class OS> -int +SyscallReturn ioctlFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -272,7 +270,7 @@ ioctlFunc(SyscallDesc *desc, int callnum, Process *process, /// Target open() handler. template <class OS> -int +SyscallReturn openFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -317,7 +315,7 @@ openFunc(SyscallDesc *desc, int callnum, Process *process, /// Target stat() handler. template <class OS> -int +SyscallReturn statFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -330,7 +328,7 @@ statFunc(SyscallDesc *desc, int callnum, Process *process, int result = stat(path.c_str(), &hostBuf); if (result < 0) - return -errno; + return errno; OS::copyOutStatBuf(xc->mem, xc->getSyscallArg(1), &hostBuf); @@ -340,7 +338,7 @@ statFunc(SyscallDesc *desc, int callnum, Process *process, /// Target lstat() handler. template <class OS> -int +SyscallReturn lstatFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -362,7 +360,7 @@ lstatFunc(SyscallDesc *desc, int callnum, Process *process, /// Target fstat() handler. template <class OS> -int +SyscallReturn fstatFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -398,7 +396,7 @@ fstatFunc(SyscallDesc *desc, int callnum, Process *process, /// file descriptor, and fail (or implement!) a non-anonymous mmap to /// anything else. template <class OS> -int +SyscallReturn mmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) { Addr start = xc->getSyscallArg(0); @@ -412,6 +410,10 @@ mmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) // user didn't give an address... pick one from our "mmap region" start = p->mmap_end; p->mmap_end += RoundUp<Addr>(length, VMPageSize); + if (p->nxm_start != 0) { + //If we have an nxm space, make sure we haven't colided + assert(p->mmap_end < p->nxm_start); + } } if (!(flags & OS::TGT_MAP_ANONYMOUS)) { @@ -424,7 +426,7 @@ mmapFunc(SyscallDesc *desc, int num, Process *p, ExecContext *xc) /// Target getrlimit() handler. template <class OS> -int +SyscallReturn getrlimitFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -449,7 +451,7 @@ getrlimitFunc(SyscallDesc *desc, int callnum, Process *process, /// Target gettimeofday() handler. template <class OS> -int +SyscallReturn gettimeofdayFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { @@ -466,7 +468,7 @@ gettimeofdayFunc(SyscallDesc *desc, int callnum, Process *process, /// Target getrusage() function. template <class OS> -int +SyscallReturn getrusageFunc(SyscallDesc *desc, int callnum, Process *process, ExecContext *xc) { diff --git a/sim/universe.cc b/sim/universe.cc index 9137baaf0..8419e1fe4 100644 --- a/sim/universe.cc +++ b/sim/universe.cc @@ -42,16 +42,41 @@ using namespace std; Tick curTick = 0; -Tick ticksPerSecond; -double __ticksPerMS; -double __ticksPerUS; -double __ticksPerNS; -double __ticksPerPS; - bool fullSystem; ostream *outputStream; ostream *configStream; +/// The simulated frequency of curTick. (This is only here for a short time) +Tick ticksPerSecond; + +namespace Clock { +/// The simulated frequency of curTick. (In ticks per second) +Tick Frequency; + +namespace Float { +double s; +double ms; +double us; +double ns; +double ps; + +double Hz; +double kHz; +double MHz; +double GHZ; +/* namespace Float */ } + +namespace Int { +Tick s; +Tick ms; +Tick us; +Tick ns; +Tick ps; +/* namespace Float */ } + +/* namespace Clock */ } + + // Dummy Object class Root : public SimObject { @@ -92,17 +117,31 @@ CREATE_SIM_OBJECT(Root) panic("FULL_SYSTEM not compiled but configuration is full_system"); #endif - ticksPerSecond = frequency; - double freq = double(ticksPerSecond); - __ticksPerMS = freq / 1.0e3; - __ticksPerUS = freq / 1.0e6; - __ticksPerNS = freq / 1.0e9; - __ticksPerPS = freq / 1.0e12; - outputStream = simout.find(output_file); + Root *root = new Root(getInstanceName()); - return new Root(getInstanceName()); + ticksPerSecond = frequency; + + using namespace Clock; + Frequency = frequency; + Float::s = static_cast<double>(Frequency); + Float::ms = Float::s / 1.0e3; + Float::us = Float::s / 1.0e6; + Float::ns = Float::s / 1.0e9; + Float::ps = Float::s / 1.0e12; + + Float::Hz = 1.0 / Float::s; + Float::kHz = 1.0 / Float::ms; + Float::MHz = 1.0 / Float::us; + Float::GHZ = 1.0 / Float::ns; + + Int::s = Frequency; + Int::ms = Int::s / 1000; + Int::us = Int::ms / 1000; + Int::ns = Int::us / 1000; + Int::ps = Int::ns / 1000; + + return root; } REGISTER_SIM_OBJECT("Root", Root) - diff --git a/test/genini.py b/test/genini.py index 9c28ef361..b8eda5d46 100755 --- a/test/genini.py +++ b/test/genini.py @@ -30,13 +30,12 @@ from os.path import join as joinpath, realpath mypath = sys.path[0] sys.path.append(joinpath(mypath, '..')) +sys.path.append(joinpath(mypath, '../python')) sys.path.append(joinpath(mypath, '../util/pbs')) -sys.path.append(joinpath(mypath, '../sim/pyconfig')) -from importer import AddToPath, LoadMpyFile -from m5config import * +pathlist = [ '.' ] -AddToPath('.') +m5_build_env = {} try: opts, args = getopt.getopt(sys.argv[1:], '-E:I:') @@ -45,16 +44,22 @@ try: offset = arg.find('=') if offset == -1: name = arg - value = True + value = '1' else: name = arg[:offset] value = arg[offset+1:] - env[name] = value + os.environ[name] = value + m5_build_env[name] = value if opt == '-I': - AddToPath(arg) + pathlist.append(arg) except getopt.GetoptError: sys.exit('Improper Usage') +from m5 import * + +for path in pathlist: + AddToPath(path) + for arg in args: LoadMpyFile(arg) diff --git a/util/categories.py b/util/categories.py new file mode 100644 index 000000000..509e5cefd --- /dev/null +++ b/util/categories.py @@ -0,0 +1,1631 @@ +categories = { + 'CALL_PALrdunique_' : 'interrupt', # + 'Call_Pal_Callsys' : 'interrupt', # + 'Call_Pal_Rdps' : 'interrupt', # + 'Call_Pal_Rdusp' : 'interrupt', # + 'Call_Pal_Rti' : 'interrupt', # + 'Call_Pal_Swpctx' : 'interrupt', # + 'Call_Pal_Swpipl' : 'interrupt', # + 'Call_Pal_Wrusp' : 'interrupt', # + 'SHATransform': 'driver', # drivers/char/random.c, + 'TRAP_INTERRUPT_10_' : 'interrupt', # + 'Trap_Dtbmiss_Single' : 'bufmgt', # + 'Trap_Dtbmiss_double' : 'bufmgt', # + 'Trap_Interrupt' : 'interrupt', # + 'Trap_Itbmiss' : 'bufmgt', # + 'Trap_Unalign' : 'alignment', + 'UNALIGN_NO_DISMISS' : 'alignment', + 'UNALIGN_NO_DISMISS_10_' : 'alignment', + '__alloc_pages' : 'bufmgt', # mm/page_alloc.c, + '__anon_vma_link': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, + '__bio_add_page' : 'other', # fs/bio.c, + '__bitmap_weight' : 'other', # lib/bitmap.c, include/linux/bitmap.h, + '__blk_put_request' : 'other', # drivers/block/ll_rw_blk.c, + '__block_commit_write' : 'other', # fs/buffer.c, + '__block_prepare_write' : 'other', # fs/buffer.c, + '__block_write_full_page': 'other', # fs/buffer.c, + '__bread' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + '__brelse' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + '__bss_start' : 'user', + '__bss_stop' : 'other', # include/asm-generic/sections.h, + '__cond_resched' : 'other', # kernel/sched.c, include/linux/sched.h, + '__const_udelay': 'other', # include/asm-i386/delay.h, + '__constant_c_memset' : 'other', # include/asm-alpha/string.h, + '__copy_from_user_ll': 'copy', # include/asm-i386/uaccess.h, + '__copy_to_user_ll': 'copy', # include/asm-i386/uaccess.h, + '__copy_user' : 'copy', # include/asm-alpha/uaccess.h, + '__d_lookup' : 'other', # fs/dcache.c, include/linux/dcache.h, + '__d_path': 'other', # fs/dcache.c, + '__delay': 'other', # arch/alpha/lib/udelay.c, include/asm-alpha/delay.h, include/asm-i386/delay.h, + '__dequeue_signal' : 'other', # kernel/signal.c, + '__divl' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__divlu' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__divq' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__divqu' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__do_softirq' : 'stack', # kernel/softirq.c, + '__down': 'interrupt', # include/asm-alpha/semaphore.h, include/asm-i386/semaphore.h, + '__down_failed' : 'other', # arch/alpha/kernel/semaphore.c, include/asm-alpha/semaphore.h, + '__down_trylock': 'interrupt', # include/asm-alpha/semaphore.h, include/asm-i386/semaphore.h, + '__elv_add_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + '__end_that_request_first' : 'other', # drivers/block/ll_rw_blk.c, + '__exit_sighand': 'other', # kernel/signal.c, include/linux/sched.h, + '__exit_signal': 'other', # kernel/signal.c, include/linux/sched.h, + '__filemap_copy_from_user_iovec' : 'bufmgt', # mm/filemap.c, + '__filemap_fdatawrite' : 'bufmgt', # mm/filemap.c, + '__find_get_block' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + '__find_get_block_slow' : 'other', # fs/buffer.c, + '__fput' : 'other', # fs/file_table.c, + '__free_pages' : 'bufmgt', # mm/page_alloc.c, + '__free_pages_ok': 'bufmgt', # mm/page_alloc.c, + '__generic_file_aio_read': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + '__generic_unplug_device' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + '__get_free_pages' : 'other', # mm/page_alloc.c, drivers/md/raid6.h, + '__get_page_state': 'bufmgt', # mm/page_alloc.c, + '__get_user_4': 'other', # include/asm-i386/uaccess.h, + '__get_zone_counts': 'other', # + '__getblk' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + '__getblk_slow' : 'other', # fs/buffer.c, + '__group_complete_signal' : 'user', # kernel/signal.c, is kinda syscall + '__group_send_sig_info' : 'user', # kernel/signal.c, is kinda syscall + '__iget' : 'other', # fs/inode.c, include/linux/fs.h, + '__insert_inode_hash': 'other', # fs/inode.c, include/linux/fs.h, + '__insert_vm_struct': 'bufmgt', # mm/mmap.c, + '__ip_conntrack_confirm' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + '__ip_conntrack_find' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, + '__ip_ct_find_proto' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + '__ip_route_output_key' : 'stack', # net/ipv4/route.c, + '__kfree_skb' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + '__kmalloc' : 'bufmgt', # mm/slab.c, include/linux/slab.h, + '__load_new_mm_context': 'bufmgt', + '__lookup': 'other', # lib/radix-tree.c, + '__lookup_hash': 'other', # fs/namei.c, + '__lookup_tag' : 'bufmgt', # lib/radix-tree.c, + '__make_request' : 'driver', # drivers/block/ll_rw_blk.c, drivers/block/ll_rw_blk.c, + '__mark_inode_dirty' : 'other', # fs/fs-writeback.c, include/linux/fs.h, + '__memcpy_aligned_up' : 'copy', # arch/alpha/lib/memcpy.c, + '__memcpy_unaligned_up' : 'copy', # arch/alpha/lib/memcpy.c, + '__memset' : 'copy', # include/asm-alpha/string.h, + '__mmdrop': 'other', # kernel/fork.c, + '__mod_timer' : 'other', # kernel/timer.c, include/linux/timer.h, + '__modify_IO_APIC_irq': 'interrupt', # + '__net_random': 'other', # + '__page_cache_release' : 'bufmgt', # mm/swap.c, + '__pagevec_free': 'bufmgt', # mm/page_alloc.c, include/linux/pagevec.h, + '__pagevec_lru_add' : 'bufmgt', # mm/swap.c, include/linux/pagevec.h, + '__pagevec_lru_add_active': 'bufmgt', # mm/swap.c, include/linux/pagevec.h, + '__pagevec_release' : 'bufmgt', # mm/swap.c, include/linux/pagevec.h, + '__pollwait' : 'other', # fs/select.c, fs/select.c, + '__pskb_trim_head': 'stack', # net/ipv4/tcp_output.c, + '__put_task_struct': 'other', # kernel/fork.c, include/linux/sched.h, + '__queue_work': 'other', # kernel/workqueue.c, + '__rb_erase_color' : 'bufmgt', # lib/rbtree.c, + '__rb_rotate_left' : 'bufmgt', # lib/rbtree.c, + '__rb_rotate_right' : 'bufmgt', # lib/rbtree.c, + '__rcu_process_callbacks': 'other', # + '__read_page_state' : 'bufmgt', # mm/page_alloc.c, include/linux/page-flags.h, + '__release_sock' : 'stack', # net/core/sock.c, + '__remlu' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__remove_from_page_cache': 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + '__remove_shared_vm_struct': 'bufmgt', # mm/mmap.c, + '__remqu' : 'other', # arch/alpha/kernel/alpha_ksyms.c, + '__rmqueue' : 'bufmgt', # mm/page_alloc.c, + '__scsi_done' : 'other', # drivers/scsi/scsi.c, drivers/scsi/scsi_priv.h, + '__scsi_get_command' : 'other', # drivers/scsi/scsi.c, + '__set_page_buffers' : 'other', # fs/buffer.c, + '__set_page_dirty_nobuffers' : 'bufmgt', # mm/page-writeback.c, include/linux/mm.h, + '__sk_stream_mem_reclaim' : 'bufmgt', # net/core/stream.c, + '__sock_create': 'stack', # net/socket.c, + '__strncpy_from_user' : 'copy', # include/asm-alpha/uaccess.h, + '__strnlen_user': 'user', + '__switch_to': 'interrupt', # + '__sync_single_inode' : 'other', # fs/fs-writeback.c, + '__tasklet_schedule' : 'other', # kernel/softirq.c, + '__tcp_ack_snd_check' : 'stack', # net/ipv4/tcp_input.c, + '__tcp_data_snd_check' : 'stack', # net/ipv4/tcp_input.c, + '__tcp_grow_window' : 'stack', # net/ipv4/tcp_input.c, + '__tcp_put_port' : 'stack', # net/ipv4/tcp_ipv4.c, + '__tcp_select_window' : 'stack', # net/ipv4/tcp_output.c, + '__tcp_tw_hashdance' : 'stack', # net/ipv4/tcp_minisocks.c, + '__tcp_v4_check_established':'stack', + '__unhash_process': 'other', # kernel/exit.c, + '__unmask_IO_APIC_irq': 'interrupt', # + '__up_wakeup' : 'interrupt', # arch/alpha/kernel/semaphore.c, include/asm-alpha/semaphore.h, + '__user_walk' : 'other', # fs/namei.c, + '__vm_stat_account': 'other', # + '__vma_link': 'bufmgt', # mm/mmap.c, + '__vma_link_rb': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + '__wait_on_buffer' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + '__wake_up' : 'other', # kernel/sched.c, + '__wake_up_common' : 'other', # kernel/sched.c, + '__wake_up_locked': 'other', # kernel/sched.c, + '__wake_up_parent': 'other', # kernel/signal.c, + '__wake_up_sync': 'other', # kernel/sched.c, + '__writeback_single_inode' : 'other', # fs/fs-writeback.c, + 'acct_process': 'other', # kernel/acct.c, include/linux/acct.h, include/linux/acct.h, + 'ack_edge_ioapic_irq': 'interrupt', # + 'ack_edge_ioapic_vector': 'interrupt', # + 'activate_page' : 'bufmgt', # mm/swap.c, + 'activate_task' : 'other', # kernel/sched.c, + 'add_disk_randomness' : 'other', # drivers/char/random.c, include/linux/genhd.h, + 'add_interrupt_randomness': 'driver', # drivers/char/random.c, include/linux/random.h, + 'add_timer_randomness' : 'driver', # drivers/char/random.c, + 'add_to_page_cache' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'add_to_page_cache_lru' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'add_wait_queue' : 'other', # kernel/fork.c, + 'add_wait_queue_exclusive' : 'other', # kernel/fork.c, + 'aligned' : 'other', # + 'alloc_buffer_head' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'alloc_dcookie': 'other', # fs/dcookies.c, + 'alloc_fd_array': 'other', # fs/file.c, include/linux/file.h, + 'alloc_inode' : 'other', # fs/inode.c, + 'alloc_pidmap': 'other', # kernel/pid.c, include/linux/pid.h, + 'alloc_skb' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + 'alloc_slabmgmt' : 'bufmgt', # mm/slab.c, + 'alpha_switch_to' : 'other', # include/asm-alpha/system.h, + 'anon_vma_link': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, include/linux/rmap.h, + 'anon_vma_prepare': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, include/linux/rmap.h, + 'anon_vma_unlink': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, + 'apache': 'other', # + 'apic_timer_interrupt': 'interrupt', # include/asm-i386/hw_irq.h, + 'arch_get_unmapped_area': 'bufmgt', + 'arch_get_unmapped_area_1': 'bufmgt', + 'arch_get_unmapped_area_topdown': 'other', # + 'arch_pick_mmap_layout': 'other', # + 'arch_unmap_area_topdown': 'other', # + 'arp_hash': 'stack', # net/ipv4/arp.c, net/ipv4/arp.c, + 'arp_process': 'stack', # net/ipv4/arp.c, + 'arp_rcv': 'stack', # net/ipv4/arp.c, + 'artsd': 'other', # + 'as_add_arq_hash' : 'other', # drivers/block/as-iosched.c, + 'as_add_arq_rb' : 'other', # drivers/block/as-iosched.c, + 'as_add_request' : 'other', # drivers/block/as-iosched.c, + 'as_antic_stop' : 'other', # drivers/block/as-iosched.c, + 'as_choose_req' : 'other', # drivers/block/as-iosched.c, + 'as_completed_request' : 'other', # drivers/block/as-iosched.c, + 'as_dispatch_request' : 'other', # drivers/block/as-iosched.c, + 'as_fifo_expired' : 'other', # drivers/block/as-iosched.c, + 'as_find_arq_hash' : 'other', # drivers/block/as-iosched.c, + 'as_find_arq_rb' : 'other', # drivers/block/as-iosched.c, + 'as_find_first_arq' : 'other', # drivers/block/as-iosched.c, + 'as_find_next_arq' : 'other', # drivers/block/as-iosched.c, + 'as_former_request' : 'other', # drivers/block/as-iosched.c, + 'as_get_io_context' : 'other', # drivers/block/as-iosched.c, + 'as_insert_request' : 'other', # drivers/block/as-iosched.c, + 'as_latter_request' : 'other', # drivers/block/as-iosched.c, + 'as_merge' : 'other', # drivers/block/as-iosched.c, + 'as_merged_request' : 'other', # drivers/block/as-iosched.c, + 'as_merged_requests' : 'other', # drivers/block/as-iosched.c, + 'as_move_to_dispatch' : 'other', # drivers/block/as-iosched.c, + 'as_next_request' : 'other', # drivers/block/as-iosched.c, + 'as_put_request' : 'other', # drivers/block/as-iosched.c, + 'as_queue_empty' : 'other', # drivers/block/as-iosched.c, + 'as_remove_dispatched_request' : 'other', # drivers/block/as-iosched.c, + 'as_remove_merge_hints' : 'other', # drivers/block/as-iosched.c, + 'as_remove_queued_request' : 'other', # drivers/block/as-iosched.c, + 'as_remove_request' : 'other', # drivers/block/as-iosched.c, + 'as_set_request' : 'other', # drivers/block/as-iosched.c, + 'as_update_arq' : 'other', # drivers/block/as-iosched.c, + 'as_update_iohist' : 'other', # drivers/block/as-iosched.c, + 'atomic_dec_and_lock' : 'other', # lib/dec_and_lock.c, include/linux/spinlock.h, include/linux/spinlock.h, + 'atomic_dec_and_lock_1' : 'other', # arch/alpha/lib/dec_and_lock.c, + 'attach_pid': 'other', # kernel/pid.c, + 'attempt_merge' : 'other', # drivers/block/ll_rw_blk.c, + 'auth_domain_drop' : 'other', # net/sunrpc/svcauth.c, + 'auth_domain_put' : 'other', # net/sunrpc/svcauth.c, include/linux/sunrpc/svcauth.h, + 'autoremove_wake_function' : 'other', # kernel/fork.c, include/linux/wait.h, + 'bad_range' : 'bufmgt', # mm/page_alloc.c, + 'balance_dirty_pages' : 'bufmgt', # mm/page-writeback.c, + 'balance_dirty_pages_ratelimited' : 'bufmgt', # mm/page-writeback.c, include/linux/writeback.h, + 'basename': 'other', # + 'bash': 'other', # + 'batch_entropy_store' : 'interrupt', # drivers/char/random.c, include/linux/random.h, + 'bh_lru_install' : 'other', # fs/buffer.c, + 'bh_waitq_head' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'bh_wake_function' : 'other', # fs/buffer.c, + 'bio_add_page' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_alloc' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_destructor' : 'other', # fs/bio.c, + 'bio_endio' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_get_nr_vecs' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_hw_segments' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_phys_segments' : 'other', # fs/bio.c, include/linux/bio.h, + 'bio_put' : 'other', # fs/bio.c, include/linux/bio.h, + 'blk_backing_dev_unplug' : 'other', # drivers/block/ll_rw_blk.c, + 'blk_cleanup_queue': 'driver', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_get_queue': 'driver', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_hw_contig_segment' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_phys_contig_segment' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_plug_device' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_queue_bounce' : 'bufmgt', # mm/highmem.c, include/linux/blkdev.h, + 'blk_recount_segments' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_remove_plug' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_rq_map_sg' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blk_run_queue' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'blkdev_ioctl': 'driver', # drivers/block/ioctl.c, include/linux/fs.h, + 'block_ioctl': 'other', # fs/block_dev.c, + 'block_prepare_write' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'block_read_full_page': 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'block_write_full_page': 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'bmap': 'other', # fs/jfs/jfs_dmap.h, fs/inode.c, include/linux/fs.h, + 'buffer_insert_list' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'buffered_rmqueue' : 'bufmgt', # mm/page_alloc.c, + 'cache_alloc_refill' : 'bufmgt', # mm/slab.c, + 'cache_check' : 'other', # net/sunrpc/cache.c, include/linux/sunrpc/cache.h, + 'cache_flusharray' : 'bufmgt', # mm/slab.c, + 'cache_grow' : 'bufmgt', # mm/slab.c, + 'cache_init_objs' : 'bufmgt', # mm/slab.c, + 'cache_reap': 'bufmgt', # mm/slab.c, + 'cached_lookup': 'other', # fs/namei.c, + 'call_rcu' : 'other', # kernel/rcupdate.c, + 'can_share_swap_page': 'bufmgt', # mm/swapfile.c, include/linux/swap.h, include/linux/swap.h, + 'can_vma_merge_after': 'bufmgt', # mm/mmap.c, + 'can_vma_merge_before': 'bufmgt', # mm/mmap.c, + 'capable': 'other', + 'cascade' : 'interrupt', # kernel/timer.c, + 'cat': 'other', # + 'cdev_get': 'other', # fs/char_dev.c, include/linux/cdev.h, + 'cdrom': 'other', # + 'check_kill_permission' : 'other', # kernel/signal.c, + 'chrdev_open': 'other', # fs/char_dev.c, include/linux/fs.h, + 'cleanup_rbuf' : 'stack', # net/ipv4/tcp.c, + 'clear_inode' : 'other', # fs/inode.c, include/linux/fs.h, + 'clear_page' : 'bufmgt', # include/asm-alpha/page.h, + 'clear_page_dirty_for_io' : 'bufmgt', # mm/page-writeback.c, include/linux/mm.h, + 'clear_page_tables': 'bufmgt', # mm/memory.c, include/linux/mm.h, + 'clear_queue_congested' : 'other', # drivers/block/ll_rw_blk.c, + 'clear_user': 'other', # include/asm-alpha/uaccess.h, include/asm-i386/uaccess.h, + 'clock_panelapplet.so': 'other', # + 'close_private_file' : 'other', # fs/file_table.c, include/linux/fs.h, + 'copy_skb_header' : 'copy', + 'common_interrupt': 'interrupt', # + 'complete': 'other', # kernel/sched.c, + 'compute_creds': 'other', # fs/exec.c, include/linux/binfmts.h, + 'con_chars_in_buffer': 'driver', # drivers/char/vt.c, + 'con_write_room': 'driver', # drivers/char/vt.c, + 'convert_fxsr_from_user': 'interrupt', # + 'convert_fxsr_to_user': 'interrupt', # + 'copy_files': 'other', # kernel/fork.c, + 'copy_from_user': 'copy', # include/asm-alpha/uaccess.h, include/asm-i386/uaccess.h, + 'copy_mm': 'other', # kernel/fork.c, + 'copy_namespace': 'other', # fs/namespace.c, include/linux/namespace.h, + 'copy_page': 'copy', + 'copy_page_range': 'bufmgt', # mm/memory.c, include/linux/mm.h, + 'copy_process': 'other', # kernel/fork.c, include/linux/sched.h, + 'copy_semundo': 'other', # ipc/sem.c, include/linux/sem.h, + 'copy_strings': 'other', # fs/exec.c, include/linux/binfmts.h, + 'copy_strings_kernel': 'other', # fs/exec.c, include/linux/binfmts.h, + 'copy_thread': 'syscall', # arch/alpha/kernel/process.c, include/linux/sched.h, + 'copy_to_user': 'copy', # include/asm-alpha/uaccess.h, include/asm-i386/uaccess.h, + 'copy_vma': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'count': 'driver', # fs/exec.c, init/initramfs.c, drivers/char/serial_tx3912.c, drivers/char/rocket.c, drivers/isdn/hardware/eicon/diva_didd.c, drivers/isdn/hardware/eicon/divasmain.c, drivers/isdn/hardware/eicon/divasmain.c, drivers/isdn/hardware/eicon/capimain.c, drivers/isdn/hardware/eicon/divasi.c, drivers/isdn/hardware/eicon/divasi.c, drivers/isdn/hardware/eicon/divasi.c, drivers/isdn/hardware/eicon/divasi.c, drivers/isdn/hardware/eicon/divasi.c, drivers/isdn/hardware/eicon/divamnt.c, drivers/isdn/hardware/eicon/divamnt.c, drivers/isdn/hardware/eicon/divamnt.c, drivers/isdn/hardware/eicon/divamnt.c, drivers/isdn/hardware/eicon/divamnt.c, drivers/media/video/w9966.c, drivers/media/video/w9966.c, + 'count_open_files': 'other', # kernel/fork.c, + 'cp_new_stat' : 'other', # fs/stat.c, + 'cp_new_stat64': 'other', # fs/stat.c, + 'cpu_idle' : 'idle', # arch/alpha/kernel/process.c, init/main.c, + 'cpu_quiet' : 'other', # kernel/rcupdate.c, + 'create_buffers' : 'other', # fs/buffer.c, + 'create_elf_tables': 'other', # fs/binfmt_elf.c, + 'create_empty_buffers' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'cron': 'other', # + 'csum_partial' : 'stack', # arch/alpha/lib/checksum.c, include/asm-alpha/checksum.h, + 'csum_partial_copy_nocheck' : 'copy', # arch/alpha/lib/csum_partial_copy.c, include/asm-alpha/checksum.h, + 'csum_partial_copy_to_xdr' : 'copy', # net/sunrpc/xprt.c, net/sunrpc/svcsock.c, + 'csum_tcpudp_magic' : 'stack', # arch/alpha/lib/checksum.c, include/asm-alpha/checksum.h, + 'csum_tcpudp_nofold' : 'stack', # arch/alpha/lib/checksum.c, include/asm-alpha/checksum.h, + 'current_kernel_time' : 'other', # kernel/time.c, include/linux/time.h, + 'cut': 'other', # + 'd_alloc' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_alloc_anon' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_callback' : 'other', # fs/dcache.c, + 'd_find_alias' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_free' : 'other', # fs/dcache.c, + 'd_instantiate' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_lookup': 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_path': 'other', # fs/dcache.c, include/linux/dcache.h, + 'd_rehash' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'deactivate_task' : 'other', # kernel/sched.c, + 'default_idle' : 'idle', # arch/alpha/kernel/process.c, include/linux/platform.h, + 'default_llseek': 'other', # fs/read_write.c, include/linux/fs.h, + 'default_wake_function' : 'other', # kernel/sched.c, include/linux/wait.h, + 'del_singleshot_timer_sync' : 'other', # kernel/timer.c, include/linux/timer.h, include/linux/timer.h, + 'del_timer' : 'other', # kernel/timer.c, include/linux/timer.h, + 'delay_pmtmr': 'interrupt', # + 'delayed_work_timer_fn': 'other', # kernel/workqueue.c, + 'dentry_open': 'other', # fs/open.c, include/linux/fs.h, + 'deny_write_access': 'other', # fs/namei.c, include/linux/fs.h, + 'dequeue_signal' : 'other', # kernel/signal.c, include/linux/sched.h, + 'dequeue_task' : 'other', # kernel/sched.c, + 'destroy_context': 'interrupt', # include/asm-alpha/mmu_context.h, include/asm-i386/mmu_context.h, + 'destroy_inode' : 'other', # fs/inode.c, include/linux/fs.h, + 'detach_pid': 'other', # kernel/pid.c, + 'detach_vmas_to_be_unmapped': 'bufmgt', # mm/mmap.c, + 'dev_queue_xmit' : 'stack', # net/core/dev.c, include/linux/netdevice.h, + 'dev_shutdown' : 'stack', # net/sched/sch_generic.c, + 'dev_watchdog': 'stack', # net/sched/sch_generic.c, + 'device_not_available': 'interrupt', # + 'disable_irq_nosync': 'interrupt', # arch/alpha/kernel/irq.c, include/asm-alpha/irq.h, include/asm-i386/irq.h, + 'disk_round_stats' : 'other', # drivers/block/ll_rw_blk.c, include/linux/genhd.h, + 'dnotify_flush' : 'other', # fs/dnotify.c, include/linux/dnotify.h, + 'dnotify_parent' : 'other', # fs/dnotify.c, include/linux/dnotify.h, + 'do_IRQ': 'driver', # drivers/s390/cio/cio.c, + 'do_anonymous_page' : 'bufmgt', # mm/memory.c, + 'do_bindings' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, include/linux/netfilter_ipv4/ip_nat_core.h, + 'do_brk': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'do_csum_partial_copy_from_user' : 'copy', # arch/alpha/lib/csum_partial_copy.c, + 'do_entInt' : 'interrupt', # arch/alpha/kernel/irq_alpha.c, + 'do_entUna': 'alignment', + 'do_execve': 'other', # fs/exec.c, include/linux/sched.h, + 'do_exit': 'other', # kernel/exit.c, + 'do_fcntl' : 'user', # fs/fcntl.c, used to be syscall` + 'do_fork': 'other', # kernel/fork.c, include/linux/sched.h, + 'do_futex': 'other', # kernel/futex.c, include/linux/futex.h, + 'do_generic_mapping_read': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'do_gettimeofday' : 'user', # arch/alpha/kernel/time.c, include/linux/time.h, used to by syscall + 'do_group_exit': 'other', # kernel/exit.c, include/linux/sched.h, + 'do_invalidatepage': 'bufmgt', # mm/truncate.c, + 'do_lookup' : 'user', # fs/namei.c, used to by syscall + 'do_mmap_pgoff': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'do_mpage_readpage': 'other', # fs/mpage.c, + 'do_mremap': 'bufmgt', # mm/mremap.c, + 'do_munmap': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'do_no_page' : 'user', # mm/memory.c, used to by syscall + 'do_nosym': 'other', # + 'do_notify_parent': 'other', # kernel/signal.c, include/linux/sched.h, + 'do_notify_resume': 'interrupt', # arch/alpha/kernel/signal.c, + 'do_osf_sigprocmask' : 'user', # arch/alpha/kernel/signal.c, used to by syscall + 'do_page_cache_readahead': 'bufmgt', # mm/readahead.c, include/linux/mm.h, + 'do_page_fault' : 'user', # arch/alpha/mm/fault.c, used to by syscall + 'do_pipe': 'syscall', # fs/pipe.c, arch/alpha/kernel/osf_sys.c, include/linux/fs.h, + 'do_poll' : 'user', # fs/select.c, drivers/macintosh/apm_emu.c, used to by syscall + 'do_pollfd' : 'user', # fs/select.c, used to by syscall + 'do_posix_clock_monotonic_gettime': 'other', # kernel/posix-timers.c, kernel/posix-timers.c, include/linux/time.h, + 'do_posix_clock_monotonic_gettime_parts': 'other', # kernel/posix-timers.c, kernel/posix-timers.c, + 'do_posix_gettime': 'other', # kernel/posix-timers.c, kernel/posix-timers.c, + 'do_readv_writev' : 'user', # fs/read_write.c, used to by syscall + 'do_select': 'other', # fs/select.c, include/linux/poll.h, + 'do_setitimer': 'other', # kernel/itimer.c, include/linux/time.h, + 'do_sigaction': 'other', # kernel/signal.c, include/linux/sched.h, + 'do_signal' : 'user', # arch/alpha/kernel/signal.c, arch/alpha/kernel/signal.c, used to by syscall + 'do_sigreturn' : 'user', # arch/alpha/kernel/signal.c, used to by syscall + 'do_sigsuspend' : 'user', # arch/alpha/kernel/signal.c, used to by syscall + 'do_softirq' : 'interrupt', # kernel/softirq.c, include/linux/interrupt.h, + 'do_switch_stack' : 'other', # + 'do_sync_read' : 'other', # fs/read_write.c, include/linux/fs.h, + 'do_sync_write': 'other', # fs/read_write.c, include/linux/fs.h, + 'do_timer' : 'other', # kernel/timer.c, include/linux/sched.h, + 'do_truncate': 'other', # fs/open.c, include/linux/fs.h, + 'do_tx_done' : 'driver', # drivers/net/ns83820.c, + 'do_wait': 'other', # + 'do_wp_page': 'bufmgt', # mm/memory.c, + 'do_writepages' : 'bufmgt', # mm/page-writeback.c, include/linux/writeback.h, + 'done' : 'other', # drivers/usb/gadget/net2280.c, drivers/usb/gadget/goku_udc.c, drivers/usb/gadget/pxa2xx_udc.c, drivers/scsi/aha152x.c, drivers/scsi/aha152x.c, include/linux/wavefront.h, + 'dp264_disable_irq' : 'interrupt', # arch/alpha/kernel/sys_dp264.c, + 'dp264_enable_irq' : 'interrupt', # arch/alpha/kernel/sys_dp264.c, + 'dp264_end_irq' : 'interrupt', # arch/alpha/kernel/sys_dp264.c, + 'dp264_srm_device_interrupt' : 'interrupt', # arch/alpha/kernel/sys_dp264.c, + 'dput' : 'other', # fs/dcache.c, include/linux/dcache.h, + 'drain_array_locked': 'bufmgt', # mm/slab.c, mm/slab.c, + 'drive_stat_acct' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'drop_buffers': 'other', # fs/buffer.c, + 'drop_key_refs': 'other', # kernel/futex.c, + 'dst_alloc': 'stack', # net/core/dst.c, + 'dst_output' : 'stack', # + 'dummy_bprm_alloc_security': 'other', # security/dummy.c, + 'dummy_bprm_apply_creds': 'other', # security/dummy.c, + 'dummy_bprm_check_security': 'other', # security/dummy.c, + 'dummy_bprm_secureexec': 'other', # security/dummy.c, + 'dummy_bprm_set_security': 'other', # security/dummy.c, + 'dummy_capable': 'other', # security/dummy.c, + 'dummy_d_instantiate': 'other', # security/dummy.c, + 'dummy_file_alloc_security': 'other', # security/dummy.c, + 'dummy_file_free_security': 'other', # security/dummy.c, + 'dummy_file_ioctl': 'other', # security/dummy.c, + 'dummy_file_mmap': 'other', # security/dummy.c, + 'dummy_file_permission': 'other', # security/dummy.c, + 'dummy_inode_alloc_security': 'other', # security/dummy.c, + 'dummy_inode_create': 'other', # security/dummy.c, + 'dummy_inode_free_security': 'other', # security/dummy.c, + 'dummy_inode_getattr': 'other', # security/dummy.c, + 'dummy_inode_mkdir': 'other', # security/dummy.c, + 'dummy_inode_permission': 'other', # security/dummy.c, + 'dummy_inode_post_create': 'other', # security/dummy.c, + 'dummy_inode_post_mkdir': 'other', # security/dummy.c, + 'dummy_task_create': 'other', # security/dummy.c, + 'dummy_task_free_security': 'other', # security/dummy.c, + 'dummy_task_kill': 'other', # security/dummy.c, + 'dummy_task_wait': 'other', # security/dummy.c, + 'dummy_vm_enough_memory': 'other', # security/dummy.c, + 'dup_task_struct': 'other', # kernel/fork.c, + 'e100': 'driver', # + 'e1000': 'driver', + 'effective_prio' : 'other', # kernel/sched.c, + 'ehci_hcd': 'driver', # drivers/usb/host/ehci.h, + 'elf_map': 'other', # fs/binfmt_elf.c, fs/binfmt_elf.c, + 'eligible_child': 'other', # kernel/exit.c, + 'elv_completed_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_former_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_latter_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_merge' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_merge_requests' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_merged_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_next_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_put_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_queue_empty' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_remove_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_rq_merge_ok' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_set_request' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'elv_try_last_merge' : 'other', # drivers/block/elevator.c, include/linux/elevator.h, + 'enable_irq': 'driver', # arch/alpha/kernel/irq.c, drivers/net/wan/sdla_ppp.c, drivers/net/wan/sdla_x25.c, drivers/net/wan/wanpipe_multppp.c, drivers/net/wan/sdla_chdlc.c, drivers/net/wan/sdlamain.c, drivers/net/wan/sdla_fr.c, include/asm-alpha/irq.h, include/asm-i386/irq.h, + 'encode_post_op_attr' : 'other', # fs/nfsd/nfs3xdr.c, + 'encode_wcc_data' : 'other', # fs/nfsd/nfs3xdr.c, + 'end' : 'other', # arch/alpha/boot/misc.c, drivers/media/video/w9966.c, drivers/media/video/w9966.c, + 'end_bio_bh_io_sync' : 'other', # fs/buffer.c, + 'end_buffer_async_write': 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'end_buffer_write_sync' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'end_edge_ioapic_vector': 'other', # include/asm-i386/io_apic.h, + 'end_level_ioapic_irq': 'interrupt', # + 'end_level_ioapic_vector': 'interrupt', # + 'end_page_writeback' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'end_that_request_chunk' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'end_that_request_first': 'driver', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'end_that_request_last' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'enqueue_task' : 'other', # kernel/sched.c, + 'entInt' : 'interrupt', # arch/alpha/kernel/proto.h, + 'entMM' : 'interrupt', # arch/alpha/kernel/proto.h, + 'entSys' : 'interrupt', # arch/alpha/kernel/proto.h, + 'entUna' : 'alignment', + 'entUnaUser':'alignment', + 'error_code': 'other', # + 'eth_header' : 'stack', # net/ethernet/eth.c, include/linux/etherdevice.h, + 'eth_type_trans' : 'stack', # net/ethernet/eth.c, include/linux/etherdevice.h, + 'ev5_flush_tlb_current_page': 'bufmgt', + 'ev5_switch_mm' : 'other', # include/asm-alpha/mmu_context.h, + 'eventpoll_init_file' : 'other', # fs/eventpoll.c, include/linux/eventpoll.h, + 'exec_mmap': 'other', # fs/exec.c, + 'exim4': 'other', # + 'exit_aio': 'other', # fs/aio.c, + 'exit_itimers': 'other', # kernel/posix-timers.c, include/linux/sched.h, + 'exit_mmap': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'exit_notify': 'other', # kernel/exit.c, + 'exit_sem': 'other', # ipc/sem.c, include/linux/sem.h, include/linux/sem.h, + 'exp_find_key' : 'other', # fs/nfsd/export.c, include/linux/nfsd/export.h, + 'exp_readlock' : 'other', # fs/nfsd/export.c, include/linux/nfsd/export.h, + 'exp_readunlock' : 'other', # fs/nfsd/export.c, include/linux/nfsd/export.h, + 'expand_fd_array': 'other', # fs/file.c, include/linux/file.h, + 'expand_files': 'other', # fs/fcntl.c, + 'expand_stack': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'expkey_put' : 'other', # fs/nfsd/export.c, include/linux/nfsd/export.h, + 'export_decode_fh' : 'other', # fs/exportfs/expfs.c, + 'export_iget' : 'other', # fs/exportfs/expfs.c, + 'expr': 'other', # + 'ext2_alloc_block' : 'other', # fs/ext2/inode.c, + 'ext2_alloc_branch' : 'other', # fs/ext2/inode.c, + 'ext2_block_to_path' : 'other', # fs/ext2/inode.c, + 'ext2_discard_prealloc' : 'other', # fs/ext2/inode.c, fs/ext2/ext2.h, + 'ext2_find_near' : 'other', # fs/ext2/inode.c, + 'ext2_free_blocks' : 'other', # fs/ext2/balloc.c, fs/ext2/ext2.h, + 'ext2_get_block' : 'other', # fs/ext2/inode.c, + 'ext2_get_branch' : 'other', # fs/ext2/inode.c, + 'ext2_get_group_desc' : 'other', # fs/ext2/balloc.c, fs/ext2/ext2.h, + 'ext2_get_inode' : 'other', # fs/ext2/inode.c, + 'ext2_new_block' : 'other', # fs/ext2/balloc.c, fs/ext2/ext2.h, + 'ext2_prepare_write' : 'other', # fs/ext2/inode.c, + 'ext2_put_inode' : 'other', # fs/ext2/inode.c, fs/ext2/ext2.h, + 'ext2_release_file' : 'other', # fs/ext2/file.c, + 'ext2_setattr' : 'other', # fs/ext2/inode.c, fs/ext2/ext2.h, + 'ext2_sync_file' : 'other', # fs/ext2/fsync.c, fs/ext2/ext2.h, + 'ext2_sync_inode' : 'other', # fs/ext2/inode.c, fs/ext2/ext2.h, + 'ext2_update_inode' : 'other', # fs/ext2/inode.c, fs/ext2/inode.c, + 'ext2_write_inode' : 'other', # fs/ext2/inode.c, fs/ext2/ext2.h, + 'ext2_writepages' : 'other', # fs/ext2/inode.c, + 'ext3': 'other', # + 'fasync_helper': 'other', # fs/fcntl.c, include/linux/fs.h, + 'fd_install' : 'other', # fs/open.c, + 'fget' : 'other', # fs/file_table.c, + 'fget_light' : 'other', # fs/file_table.c, + 'fh_put' : 'other', # fs/nfsd/nfsfh.c, include/linux/nfsd/nfsfh.h, + 'fh_verify' : 'other', # fs/nfsd/nfsfh.c, include/linux/nfsd/nfsfh.h, + 'fib_lookup': 'stack', # net/ipv4/fib_rules.c, + 'fib_rule_put': 'stack', # net/ipv4/fib_rules.c, + 'fib_semantic_match': 'stack', # net/ipv4/fib_semantics.c, + 'file_ioctl': 'other', # fs/ioctl.c, + 'file_kill' : 'other', # fs/file_table.c, include/linux/fs.h, + 'file_move': 'other', # fs/file_table.c, include/linux/fs.h, + 'file_ra_state_init': 'bufmgt', # mm/readahead.c, include/linux/fs.h, + 'file_read_actor': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'filemap_fdatawait' : 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'filemap_fdatawrite' : 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'filemap_nopage': 'bufmgt', # mm/filemap.c, include/linux/mm.h, + 'filesystems_read_proc': 'other', # fs/proc/proc_misc.c, + 'filp_close' : 'other', # fs/open.c, include/linux/fs.h, + 'filp_open' : 'other', # fs/open.c, include/linux/fs.h, + 'find_best_ips_proto_fast' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, + 'find_busiest_group' : 'other', # kernel/sched.c, + 'find_dcookie': 'other', # fs/dcookies.c, + 'find_exported_dentry' : 'other', # fs/exportfs/expfs.c, fs/nfsd/export.c, + 'find_extend_vma': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'find_get_page' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'find_get_pages': 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'find_get_pages_tag' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'find_inode_fast' : 'other', # fs/inode.c, + 'find_inode_number' : 'other', # fs/dcache.c, include/linux/fs.h, + 'find_lock_page' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'find_mergeable_anon_vma': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'find_nat_proto' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, include/linux/netfilter_ipv4/ip_nat_protocol.h, + 'find_next_zero_bit': 'other', # include/asm-alpha/bitops.h, include/asm-i386/bitops.h, + 'find_or_create_page' : 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'find_pid' : 'user', # kernel/pid.c, used to be syscall + 'find_snap_client': 'stack', # net/802/psnap.c, + 'find_task_by_pid' : 'user', # kernel/pid.c, include/linux/sched.h, used to be syscall + 'find_task_by_pid_type': 'other', # + 'find_vma' : 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, used to be syscall + 'find_vma_prepare': 'bufmgt', # mm/mmap.c, + 'find_vma_prev': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'finish_task_switch' : 'other', # kernel/sched.c, used to be syscall + 'finish_wait' : 'other', # kernel/fork.c, used to be syscall + 'flush_old_exec': 'other', # fs/exec.c, include/linux/binfmts.h, + 'flush_signal_handlers': 'other', # kernel/signal.c, include/linux/sched.h, + 'flush_sigqueue': 'other', # kernel/signal.c, + 'flush_thread': 'syscall', # arch/alpha/kernel/process.c, include/linux/sched.h, + 'fn_hash_lookup': 'stack', # net/ipv4/fib_hash.c, + 'follow_mount' : 'user', # fs/namei.c, used to be syscall + 'found' : 'other', # sound/oss/forte.c, scripts/kconfig/gconf.c, drivers/net/fec.c, drivers/scsi/ibmmca.c, drivers/scsi/fd_mcs.c, + 'fput' : 'user', # fs/file_table.c, used to be syscall + 'free_block' : 'bufmgt', # mm/slab.c, drivers/char/drm/radeon_mem.c, mm/slab.c, + 'free_buffer_head': 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'free_fd_array': 'other', # fs/file.c, include/linux/file.h, + 'free_hot_cold_page' : 'bufmgt', # mm/page_alloc.c, + 'free_hot_page' : 'bufmgt', # mm/page_alloc.c, + 'free_page_and_swap_cache': 'bufmgt', # mm/swap_state.c, include/linux/swap.h, include/linux/swap.h, + 'free_pages' : 'bufmgt', # mm/page_alloc.c, drivers/char/drm/drm_memory_debug.h, drivers/md/raid6.h, drivers/char/drm/drmP.h, + 'free_pages_bulk': 'bufmgt', # mm/page_alloc.c, + 'free_pgtables': 'bufmgt', # mm/mmap.c, + 'free_pidmap': 'other', # kernel/pid.c, + 'free_task': 'other', # kernel/fork.c, + 'free_uid' : 'other', # kernel/user.c, include/linux/sched.h, + 'freed_request' : 'other', # drivers/block/ll_rw_blk.c, + 'fs_may_remount_ro' : 'other', # fs/file_table.c, include/linux/fs.h, + 'fsync_buffers_list' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'futex_wait': 'other', # kernel/futex.c, + 'futex_wake': 'other', # kernel/futex.c, + 'gconfd-2': 'other', # + 'generic_commit_write' : 'user', # fs/buffer.c, include/linux/buffer_head.h, used to be syscall + 'generic_delete_inode': 'other', # fs/inode.c, include/linux/fs.h, + 'generic_drop_inode' : 'user', # fs/inode.c, used to be syscall + 'generic_file_aio_read': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'generic_file_aio_write': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'generic_file_aio_write_nolock' : 'user', # mm/filemap.c, include/linux/fs.h, used to be syscall + 'generic_file_buffered_write': 'other', # + 'generic_file_llseek': 'other', # fs/read_write.c, include/linux/fs.h, + 'generic_file_mmap': 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'generic_file_open' : 'user', # fs/open.c, include/linux/fs.h, used to be syscall + 'generic_file_write' : 'user', # mm/filemap.c, include/linux/fs.h, used to be syscall + 'generic_file_write_nolock' : 'user', # mm/filemap.c, include/linux/fs.h, used to be syscall + 'generic_file_writev' : 'user', # mm/filemap.c, include/linux/fs.h, used to be syscall + 'generic_fillattr' : 'user', # fs/stat.c, include/linux/fs.h, used to be syscall + 'generic_forget_inode' : 'user', # fs/inode.c, used to be syscall + 'generic_make_request' : 'user', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, used to be syscall + 'generic_unplug_device' : 'driver', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'get_conntrack_index' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_tcp.c, + 'get_device' : 'driver', # drivers/base/core.c, include/linux/device.h, + 'get_dirty_limits' : 'bufmgt', # mm/page-writeback.c, + 'get_empty_filp' : 'other', # fs/file_table.c, include/linux/fs.h, + 'get_free_idx': 'interrupt', # + 'get_futex_key': 'other', # kernel/futex.c, + 'get_io_context' : 'other', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'get_jiffies_64': 'other', # kernel/time.c, include/linux/jiffies.h, include/linux/jiffies.h, + 'get_new_inode_fast': 'other', # fs/inode.c, + 'get_object' : 'other', # fs/exportfs/expfs.c, + 'get_offset_pmtmr': 'interrupt', # + 'get_one_pte_map_nested': 'bufmgt', # mm/mremap.c, + 'get_page_state': 'bufmgt', # mm/page_alloc.c, include/linux/page-flags.h, + 'get_pipe_inode': 'other', # fs/pipe.c, + 'get_request' : 'other', # drivers/block/ll_rw_blk.c, + 'get_sample_stats' : 'stack', # net/core/dev.c, + 'get_signal_to_deliver' : 'other', # kernel/signal.c, include/linux/signal.h, + 'get_task_mm': 'other', # include/linux/sched.h, + 'get_tuple' : 'driver', # net/ipv4/netfilter/ip_conntrack_core.c, drivers/isdn/hisax/elsa_cs.c, drivers/isdn/hisax/teles_cs.c, drivers/isdn/hisax/avma1_cs.c, drivers/isdn/hardware/avm/avm_cs.c, drivers/bluetooth/bt3c_cs.c, drivers/bluetooth/btuart_cs.c, drivers/bluetooth/dtl1_cs.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + 'get_unique_tuple' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, + 'get_unmapped_area': 'bufmgt', # mm/mmap.c, mm/nommu.c, include/linux/mm.h, + 'get_unused_fd' : 'other', # fs/open.c, include/linux/file.h, used to be syscall + 'get_vmalloc_info': 'other', # fs/proc/proc_misc.c, + 'get_write_access' : 'other', # fs/namei.c, include/linux/fs.h, used to be syscall + 'get_writeback_state' : 'other', # mm/page-writeback.c, used to be syscall + 'get_zone_counts': 'bufmgt', # mm/page_alloc.c, include/linux/mmzone.h, + 'getname' : 'other', # fs/namei.c, include/linux/fs.h, used to be syscall + 'getnstimeofday': 'other', # + 'getrusage': 'other', # kernel/sys.c, kernel/exit.c, + 'grab_block' : 'other', # fs/ext2/balloc.c, + 'grep': 'other', # + 'group_release_blocks' : 'other', # fs/ext2/balloc.c, + 'group_reserve_blocks' : 'other', # fs/ext2/balloc.c, + 'group_send_sig_info' : 'other', # kernel/signal.c, include/linux/signal.h, + 'groups_alloc' : 'other', # kernel/sys.c, include/linux/sched.h, used to be syscall + 'groups_free' : 'other', # kernel/sys.c, include/linux/sched.h, used to be syscall + 'groups_search' : 'other', # kernel/sys.c, used to be syscall + 'groups_sort' : 'other', # kernel/sys.c, used to be syscall + 'groups_to_user': 'other', # kernel/sys.c, + 'grow_dev_page' : 'other', # fs/buffer.c, + 'halfMD4Transform' : 'other', # fs/ext3/hash.c, drivers/char/random.c, + 'handle_IRQ_event' : 'interrupt', # arch/alpha/kernel/irq.c, include/asm-alpha/irq.h, + 'handle_irq' : 'interrupt', # arch/alpha/kernel/irq.c, arch/alpha/kernel/irq_impl.h, + 'handle_mm_fault' : 'interrupt', # mm/memory.c, include/linux/mm.h, + 'handle_signal': 'interrupt', # arch/alpha/kernel/signal.c, + 'handle_stop_signal' : 'interrupt', # kernel/signal.c, + 'hash_conntrack' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, + 'hash_futex': 'other', # kernel/futex.c, + 'hash_refile' : 'other', # fs/nfsd/nfscache.c, + 'i8042_interrupt': 'interrupt', # drivers/input/serio/i8042.c, drivers/input/serio/i8042.c, + 'i8042_timer_func': 'driver', # drivers/input/serio/i8042.c, + 'i_waitq_head' : 'other', # fs/inode.c, + 'ide_cd': 'other', # + 'ide_core': 'other', # + 'ide_disk': 'other', # include/linux/ide.h, + 'idle_cpu' : 'idle', # kernel/sched.c, include/linux/sched.h, + 'iget_locked' : 'other', # fs/inode.c, include/linux/fs.h, + 'in_group_p' : 'other', # kernel/sys.c, include/linux/sched.h, + 'inet_accept' : 'stack', # net/ipv4/af_inet.c, + 'inet_create': 'stack', # net/ipv4/af_inet.c, + 'inet_getname' : 'stack', # net/ipv4/af_inet.c, + 'inet_release' : 'stack', # net/ipv4/af_inet.c, + 'inet_sendmsg' : 'stack', # net/ipv4/af_inet.c, + 'inet_sendpage' : 'stack', # net/ipv4/af_inet.c, + 'inet_shutdown' : 'stack', # net/ipv4/af_inet.c, + 'inet_sock_destruct' : 'stack', # net/ipv4/af_inet.c, + 'init': 'driver', # net/core/pktgen.c, net/ipv4/netfilter/ip_conntrack_ftp.c, net/ipv4/netfilter/ip_conntrack_irc.c, net/ipv4/netfilter/ip_tables.c, net/ipv4/netfilter/ipt_ECN.c, net/ipv4/netfilter/ipt_LOG.c, net/ipv4/netfilter/ipt_helper.c, net/ipv4/netfilter/ipt_TOS.c, net/ipv4/netfilter/ipt_addrtype.c, net/ipv4/netfilter/ipt_limit.c, net/ipv4/netfilter/ipt_tcpmss.c, net/ipv4/netfilter/ipt_ecn.c, net/ipv4/netfilter/ipt_esp.c, net/ipv4/netfilter/ipt_mac.c, net/ipv4/netfilter/ipt_tos.c, net/ipv4/netfilter/ipt_ttl.c, net/ipv4/netfilter/ip_nat_ftp.c, net/ipv4/netfilter/ip_nat_irc.c, net/ipv4/netfilter/ipt_multiport.c, net/ipv4/netfilter/ipt_dscp.c, net/ipv4/netfilter/arp_tables.c, net/ipv4/netfilter/ip_conntrack_tftp.c, net/ipv4/netfilter/ipt_physdev.c, net/ipv4/netfilter/ipt_state.c, net/ipv4/netfilter/ipt_ah.c, net/ipv4/netfilter/ipt_mark.c, net/ipv4/netfilter/ip_queue.c, net/ipv4/netfilter/ipt_conntrack.c, net/ipv4/netfilter/ip_fw_compat.c, net/ipv4/netfilter/ipt_NETMAP.c, net/ipv4/netfilter/ipt_pkttype.c, net/ipv4/netfilter/ipt_MASQUERADE.c, net/ipv4/netfilter/ip_conntrack_standalone.c, net/ipv4/netfilter/ip_nat_snmp_basic.c, net/ipv4/netfilter/ipt_length.c, net/ipv4/netfilter/arpt_mangle.c, net/ipv4/netfilter/ipt_CLASSIFY.c, net/ipv4/netfilter/ip_nat_standalone.c, net/ipv4/netfilter/ipt_NOTRACK.c, net/ipv4/netfilter/ip_nat_amanda.c, net/ipv4/netfilter/ipt_REDIRECT.c, net/ipv4/netfilter/ipt_TCPMSS.c, net/ipv4/netfilter/ipt_REJECT.c, net/ipv4/netfilter/ip_conntrack_amanda.c, net/ipv4/netfilter/ipt_owner.c, net/ipv4/netfilter/ipt_DSCP.c, net/ipv4/netfilter/ip_nat_tftp.c, net/ipv4/netfilter/arptable_filter.c, net/ipv4/netfilter/ipt_iprange.c, net/ipv4/netfilter/ipt_MARK.c, net/ipv4/netfilter/iptable_filter.c, net/ipv4/netfilter/iptable_mangle.c, net/ipv4/netfilter/ipt_SAME.c, net/ipv4/netfilter/ipt_realm.c, net/ipv4/netfilter/ipt_ULOG.c, net/ipv4/netfilter/iptable_raw.c, net/ipv6/netfilter/ip6t_length.c, net/ipv6/netfilter/ip6t_eui64.c, net/ipv6/netfilter/ip6t_frag.c, net/ipv6/netfilter/ip6t_multiport.c, net/ipv6/netfilter/ip6t_ah.c, net/ipv6/netfilter/ip6t_hl.c, net/ipv6/netfilter/ip6t_rt.c, net/ipv6/netfilter/ip6t_mark.c, net/ipv6/netfilter/ip6_queue.c, net/ipv6/netfilter/ip6table_filter.c, net/ipv6/netfilter/ip6table_mangle.c, net/ipv6/netfilter/ip6t_owner.c, net/ipv6/netfilter/ip6t_LOG.c, net/ipv6/netfilter/ip6t_dst.c, net/ipv6/netfilter/ip6t_esp.c, net/ipv6/netfilter/ip6t_hbh.c, net/ipv6/netfilter/ip6t_mac.c, net/ipv6/netfilter/ip6_tables.c, net/ipv6/netfilter/ip6t_MARK.c, net/ipv6/netfilter/ip6table_raw.c, net/ipv6/netfilter/ip6t_limit.c, net/bridge/netfilter/ebt_among.c, net/bridge/netfilter/ebt_dnat.c, net/bridge/netfilter/ebt_802_3.c, net/bridge/netfilter/ebt_mark.c, net/bridge/netfilter/ebt_redirect.c, net/bridge/netfilter/ebt_pkttype.c, net/bridge/netfilter/ebt_snat.c, net/bridge/netfilter/ebt_vlan.c, net/bridge/netfilter/ebt_arp.c, net/bridge/netfilter/ebt_log.c, net/bridge/netfilter/ebt_stp.c, net/bridge/netfilter/ebtables.c, net/bridge/netfilter/ebt_limit.c, net/bridge/netfilter/ebtable_broute.c, net/bridge/netfilter/ebt_arpreply.c, net/bridge/netfilter/ebt_ip.c, net/bridge/netfilter/ebtable_filter.c, net/bridge/netfilter/ebt_mark_m.c, net/bridge/netfilter/ebtable_nat.c, net/decnet/netfilter/dn_rtmsg.c, init/main.c, scripts/kconfig/qconf.cc, , as member of class ConfigItemdrivers/usb/host/ehci-hcd.c, drivers/usb/gadget/ether.c, drivers/usb/gadget/net2280.c, drivers/usb/gadget/goku_udc.c, drivers/usb/gadget/zero.c, drivers/usb/gadget/dummy_hcd.c, drivers/usb/gadget/inode.c, drivers/media/dvb/frontends/grundig_29504-401.c, crypto/tcrypt.c, crypto/khazad.c, crypto/digest.c, crypto/des.c, crypto/md4.c, crypto/md5.c, crypto/tea.c, crypto/serpent.c, crypto/blowfish.c, crypto/sha1.c, crypto/crypto_null.c, crypto/crc32c.c, crypto/deflate.c, crypto/cast5.c, crypto/cast6.c, crypto/sha256.c, crypto/sha512.c, crypto/twofish.c, kernel/futex.c, init/main.c, net/ipv4/netfilter/ipt_recent.c, drivers/i2c/chips/w83781d.c, drivers/i2c/chips/w83627hf.c, drivers/media/video/saa7114.c, + 'init_bictcp' : 'stack', # net/ipv4/tcp_input.c, + 'init_buffer_head' : 'other', # fs/buffer.c, + 'init_conntrack' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, + 'init_fpu': 'interrupt', # include/asm-i386/i387.h, + 'init_new_context': 'interrupt', # include/asm-alpha/mmu_context.h, include/asm-i386/mmu_context.h, + 'init_page_buffers' : 'other', # fs/buffer.c, + 'init_westwood' : 'stack', # net/ipv4/tcp_input.c, + 'inode_add_bytes' : 'other', # fs/stat.c, include/linux/fs.h, + 'inode_change_ok': 'other', # fs/attr.c, include/linux/fs.h, + 'inode_has_buffers' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'inode_setattr': 'other', # fs/attr.c, include/linux/fs.h, + 'inode_sub_bytes' : 'other', # fs/stat.c, include/linux/fs.h, + 'inode_times_differ' : 'other', # fs/inode.c, + 'inode_update_time' : 'other', # fs/inode.c, include/linux/fs.h, + 'insert_vm_struct': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'install_arg_page': 'other', # fs/exec.c, include/linux/mm.h, + 'internal_add_timer' : 'other', # kernel/timer.c, + 'invalid_dpte_no_dismiss_10_' : 'interrupt', # + 'invalidate_inode_buffers' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'invert_tuple' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, + 'invert_tuplepr' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'io_schedule' : 'other', # kernel/sched.c, include/linux/sched.h, + 'ip_append_data' : 'stack', # net/ipv4/ip_output.c, + 'ip_append_page' : 'stack', # net/ipv4/ip_output.c, + 'ip_build_and_send_pkt' : 'stack', # net/ipv4/ip_output.c, + 'ip_cmsg_recv': 'stack', # net/ipv4/ip_sockglue.c, + 'ip_cmsg_send' : 'stack', # net/ipv4/ip_sockglue.c, + 'ip_confirm' : 'stack', # net/ipv4/netfilter/ip_conntrack_standalone.c, + 'ip_conntrack': 'other', # include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_conntrack_alter_reply' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_conntrack_defrag' : 'stack', # net/ipv4/netfilter/ip_conntrack_standalone.c, + 'ip_conntrack_find_get' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + 'ip_conntrack_get' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_conntrack_in' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + 'ip_conntrack_local' : 'stack', # net/ipv4/netfilter/ip_conntrack_standalone.c, + 'ip_conntrack_tuple_taken' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_conntrack_unexpect_related' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_helper.h, + 'ip_ct_find_helper' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_helper.h, + 'ip_ct_find_proto' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack_core.h, + 'ip_ct_gather_frags' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_ct_refresh' : 'stack', # net/ipv4/netfilter/ip_conntrack_core.c, include/linux/netfilter_ipv4/ip_conntrack.h, + 'ip_defrag' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_evictor' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_fast_csum' : 'stack', # arch/alpha/lib/checksum.c, include/asm-alpha/checksum.h, + 'ip_finish_output' : 'stack', # net/ipv4/ip_output.c, + 'ip_finish_output2' : 'stack', # net/ipv4/ip_output.c, + 'ip_frag_create' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_frag_destroy' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_frag_intern' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_frag_queue' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_frag_reasm' : 'stack', # net/ipv4/ip_fragment.c, + 'ip_local_deliver' : 'stack', # net/ipv4/ip_input.c, + 'ip_local_deliver_finish' : 'stack', # net/ipv4/ip_input.c, + 'ip_map_lookup' : 'stack', # net/sunrpc/svcauth_unix.c, + 'ip_map_put' : 'stack', # net/sunrpc/svcauth_unix.c, + 'ip_mc_drop_socket' : 'stack', # net/ipv4/igmp.c, net/ipv4/af_inet.c, include/linux/igmp.h, + 'ip_nat_fn' : 'stack', # net/ipv4/netfilter/ip_nat_standalone.c, + 'ip_nat_out' : 'stack', # net/ipv4/netfilter/ip_nat_standalone.c, + 'ip_nat_rule_find' : 'stack', # net/ipv4/netfilter/ip_nat_rule.c, include/linux/netfilter_ipv4/ip_nat_rule.h, + 'ip_nat_setup_info' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, include/linux/netfilter_ipv4/ip_nat.h, + 'ip_nat_used_tuple' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, include/linux/netfilter_ipv4/ip_nat.h, + 'ip_output' : 'stack', # net/ipv4/ip_output.c, + 'ip_push_pending_frames' : 'stack', # net/ipv4/ip_output.c, + 'ip_queue_xmit' : 'stack', # net/ipv4/ip_output.c, + 'ip_rcv' : 'stack', # net/ipv4/ip_input.c, + 'ip_rcv_finish' : 'stack', # net/ipv4/ip_input.c, + 'ip_refrag' : 'stack', # net/ipv4/netfilter/ip_conntrack_standalone.c, + 'ip_route_input' : 'stack', # net/ipv4/route.c, + 'ip_route_input_slow': 'stack', # net/ipv4/route.c, + 'ip_route_output_flow' : 'stack', # net/ipv4/route.c, + 'ip_send_check' : 'stack', # net/ipv4/ip_output.c, + 'ip_tables': 'other', # + 'ipq_kill' : 'stack', # net/ipv4/ip_fragment.c, + 'ipqhashfn' : 'stack', # net/ipv4/ip_fragment.c, + 'ipt_do_table' : 'stack', # net/ipv4/netfilter/ip_tables.c, include/linux/netfilter_ipv4/ip_tables.h, + 'ipt_find_target_lock' : 'stack', # net/ipv4/netfilter/ip_tables.c, include/linux/netfilter_ipv4/ip_tables.h, include/linux/netfilter.h, + 'ipt_hook' : 'stack', # net/ipv4/netfilter/iptable_filter.c, net/ipv4/netfilter/iptable_raw.c, + 'ipt_local_hook' : 'stack', # net/ipv4/netfilter/iptable_mangle.c, + 'ipt_local_out_hook' : 'stack', # net/ipv4/netfilter/iptable_filter.c, + 'ipt_route_hook' : 'stack', # net/ipv4/netfilter/iptable_mangle.c, + 'iptable_filter': 'other', # + 'iptable_mangle': 'other', # + 'iptable_nat': 'other', # + 'iput' : 'other', # fs/inode.c, include/linux/fs.h, + 'ipv4_sabotage_in' : 'stack', # net/bridge/br_netfilter.c, + 'ipv4_sabotage_out' : 'stack', # net/bridge/br_netfilter.c, + 'irq_entries_start': 'interrupt', # + 'is_bad_inode' : 'other', # fs/bad_inode.c, include/linux/fs.h, + 'it_real_fn': 'other', # kernel/itimer.c, include/linux/timer.h, + 'jbd': 'other', # + 'juk': 'other', # + 'kded_kmilod.so': 'other', # + 'kdeinit': 'other', # + 'kernel_read': 'other', # fs/exec.c, include/linux/fs.h, + 'kfree' : 'bufmgt', # mm/slab.c, include/linux/slab.h, + 'kfree_skbmem' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + 'kill_fasync': 'other', # fs/fcntl.c, include/linux/fs.h, + 'kill_proc_info' : 'other', # kernel/signal.c, include/linux/sched.h, + 'kill_something_info' : 'other', # kernel/signal.c, + 'kmap': 'bufmgt', # include/asm-i386/highmem.h, + 'kmap_atomic': 'bufmgt', # include/linux/highmem.h, include/asm-i386/highmem.h, + 'kmap_high': 'bufmgt', # mm/highmem.c, + 'kmem_cache_alloc' : 'bufmgt', # mm/slab.c, include/linux/slab.h, + 'kmem_cache_free' : 'bufmgt', # mm/slab.c, include/linux/slab.h, + 'kmem_flagcheck' : 'bufmgt', # mm/slab.c, + 'kmem_freepages' : 'bufmgt', # mm/slab.c, + 'kmem_getpages' : 'bufmgt', # mm/slab.c, + 'kobject_get' : 'other', # lib/kobject.c, include/linux/kobject.h, + 'kobject_put' : 'other', # lib/kobject.c, include/linux/kobject.h, + 'kref_get': 'other', # lib/kref.c, include/linux/kref.h, + 'kscd': 'other', # + 'ksoftirqd' : 'interrupt', # kernel/softirq.c, + 'ksysguardd': 'other', # + 'kthread_should_stop' : 'other', # kernel/kthread.c, include/linux/kthread.h, + 'kunmap': 'bufmgt', # include/linux/highmem.h, include/asm-i386/highmem.h, + 'kunmap_atomic': 'bufmgt', # include/linux/highmem.h, include/asm-i386/highmem.h, + 'kunmap_high': 'bufmgt', # mm/highmem.c, + 'kwrapper': 'other', # + 'ld-2.3.2.so': 'other', # + 'lease_get_mtime' : 'other', # fs/locks.c, include/linux/fs.h, + 'libORBit-2.so.0.0.0': 'other', # + 'libX11.so.6.2': 'other', # + 'libXext.so.6.4': 'other', # + 'libXft.so.2.1.1': 'other', # + 'libXrender.so.1.2.2': 'other', # + 'libacl.so.1.1.0': 'other', # + 'libarts.so': 'other', # + 'libartsdsp.so.0.0.0': 'other', # + 'libartsflow.so.1.0.0': 'other', # + 'libartsmidi.so.0.0.0': 'other', # + 'libattr.so.1.1.0': 'other', # + 'libc-2.3.2.so' : 'user', + 'libcdaudio.so': 'other', # + 'libcrypt-2.3.2.so': 'other', # + 'libcrypto.so.0.9.7': 'other', # + 'libdb3.so.3.0.2': 'other', # + 'libdl-2.3.2.so': 'other', # + 'libgcc_s.so.1': 'other', # + 'libgconf-2.so.4.1.0': 'other', # + 'libgcrypt.so.11.1.1': 'other', # + 'libgdk-1.2.so.0.9.1': 'other', # + 'libgdk-x11-2.0.so.0.400.13': 'other', # + 'libgfx_gtk.so': 'other', # + 'libgkgfx.so': 'other', # + 'libgklayout.so': 'other', # + 'libglib-1.2.so.0.0.10': 'other', # + 'libglib-2.0.so.0.400.8': 'other', # + 'libgnutls.so.11.1.16': 'other', # + 'libgobject-2.0.so.0.400.8': 'other', # + 'libgthread-2.0.so.0.400.8': 'other', # + 'libgtk-x11-2.0.so.0.400.13': 'other', # + 'libhtmlpars.so': 'other', # + 'libimglib2.so': 'other', # + 'libkdecore.so.4.2.0': 'other', # + 'libkdefx.so.4.2.0': 'other', # + 'libkdeinit_kded.so': 'other', # + 'libkdeinit_kdesktop.so': 'other', # + 'libkdeinit_kicker.so': 'other', # + 'libkdeinit_klauncher.so': 'other', # + 'libkdeinit_klipper.so': 'other', # + 'libkdeui.so.4.2.0': 'other', # + 'libksgrd.so.1.2.0': 'other', # + 'libm-2.3.2.so': 'other', # + 'libmcop.so.1.0.0': 'other', # + 'libmcop_mt.so.1.0.0': 'other', # + 'libmikmod.so': 'other', # + 'libmpg123.so': 'other', # + 'libncurses.so.5.4': 'other', # + 'libnecko.so': 'other', # + 'libnsl-2.3.2.so': 'other', # + 'libnspr4.so': 'other', # + 'libnss_compat-2.3.2.so': 'other', # + 'libnss_files-2.3.2.so': 'other', # + 'libnss_nis-2.3.2.so': 'other', # + 'libpcre.so.3.10.0': 'other', # + 'libplc4.so': 'other', # + 'libplds4.so': 'other', # + 'libpref.so': 'other', # + 'libpthread-0.10.so': 'user', + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libpthread-0.60.so': 'other', # + 'libqt-mt.so.3.3.3': 'other', # + 'libqtmcop.so.1.0.0': 'other', # + 'librdf.so': 'other', # + 'libresolv-2.3.2.so': 'other', # + 'librt-2.3.2.so': 'other', # + 'libstdc++.so.5.0.7': 'other', # + 'libtasn1.so.2.0.10': 'other', # + 'libuconv.so': 'other', # + 'libwidget_gtk2.so': 'other', # + 'libwrap.so.0.7.6': 'other', # + 'libxmms.so.1.3.1': 'other', # + 'libxpcom.so': 'other', # + 'link_path_walk' : 'other', # fs/namei.c, + 'll_back_merge_fn' : 'other', # drivers/block/ll_rw_blk.c, + 'll_front_merge_fn' : 'other', # drivers/block/ll_rw_blk.c, + 'll_merge_requests_fn' : 'other', # drivers/block/ll_rw_blk.c, + 'll_rw_block' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'llc_rcv': 'stack', # net/llc/llc_input.c, + 'llc_sap_find': 'stack', # net/llc/llc_core.c, + 'load_balance' : 'other', # kernel/sched.c, + 'load_balance_newidle' : 'other', # kernel/sched.c, + 'load_elf_binary': 'other', # fs/binfmt_elf.c, fs/binfmt_elf.c, + 'load_elf_interp': 'other', # fs/binfmt_elf.c, + 'load_script': 'other', # fs/binfmt_script.c, + 'local_bh_enable' : 'interrupt', # kernel/softirq.c, include/linux/interrupt.h, + 'lock_sock' : 'stack', # net/core/sock.c, + 'lockfile-create': 'other', # + 'lockfile-remove': 'other', # + 'locks_remove_flock' : 'other', # fs/locks.c, include/linux/fs.h, + 'locks_remove_posix' : 'other', # fs/locks.c, include/linux/fs.h, + 'lookup_create': 'other', # fs/namei.c, include/linux/dcache.h, + 'lookup_hash': 'other', # fs/namei.c, include/linux/namei.h, + 'lookup_mnt' : 'other', # fs/namespace.c, include/linux/dcache.h, + 'loop' : 'interrupt', # + 'loopback_xmit': 'driver', + 'lru_add_drain' : 'bufmgt', # mm/swap.c, include/linux/swap.h, + 'lru_cache_add' : 'bufmgt', # mm/swap.c, + 'lru_cache_add_active': 'bufmgt', # mm/swap.c, + 'lru_put_front' : 'other', # fs/nfsd/nfscache.c, + 'ls': 'driver', # drivers/fc4/fc.c, + 'mail': 'other', # + 'mapping_tagged' : 'bufmgt', # mm/page-writeback.c, include/linux/fs.h, + 'mark_buffer_dirty' : 'other', # fs/buffer.c, + 'mark_buffer_dirty_inode' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'mark_offset_pmtmr': 'interrupt', # + 'mark_page_accessed' : 'bufmgt', # mm/swap.c, + 'mask_and_ack_level_ioapic_vector': 'interrupt', # include/asm-i386/io_apic.h, + 'math_state_restore': 'interrupt', # + 'mawk': 'other', # + 'max_sane_readahead': 'bufmgt', # mm/readahead.c, include/linux/mm.h, + 'max_select_fd': 'other', # fs/select.c, + 'may_open': 'other', # fs/namei.c, include/linux/fs.h, + 'memcmp' : 'copy', # lib/string.c, + 'memcpy' : 'copy', # lib/string.c, arch/alpha/lib/memcpy.c, arch/alpha/kernel/alpha_ksyms.c, include/asm-alpha/string.h, include/asm-alpha/string.h, + 'memcpy_fromiovec': 'copy', # net/core/iovec.c, include/linux/socket.h, + 'memcpy_fromiovecend': 'copy', # net/core/iovec.c, include/linux/socket.h, + 'memcpy_toiovec' : 'copy', # net/core/iovec.c, include/linux/socket.h, + 'meminfo_read_proc': 'other', # fs/proc/proc_misc.c, + 'memmove' : 'copy', # lib/string.c, include/asm-alpha/string.h, + 'mempool_alloc' : 'bufmgt', # mm/mempool.c, include/linux/mempool.h, + 'mempool_alloc_slab' : 'bufmgt', # mm/mempool.c, include/linux/mempool.h, + 'mempool_free' : 'bufmgt', # mm/mempool.c, include/linux/mempool.h, + 'mempool_free_slab' : 'bufmgt', # mm/mempool.c, include/linux/mempool.h, + 'memscan' : 'copy', # lib/string.c, + 'mkdir': 'other', # + 'mm_alloc': 'bufmgt', # kernel/fork.c, include/linux/sched.h, + 'mm_init': 'driver', # drivers/block/umem.c, kernel/fork.c, + 'mm_release': 'other', # kernel/fork.c, include/linux/sched.h, + 'mmput': 'other', # kernel/fork.c, include/linux/sched.h, + 'mod_timer' : 'other', # kernel/timer.c, include/linux/timer.h, + 'move_addr_to_user' : 'copy', # net/socket.c, include/linux/socket.h, + 'move_one_page': 'bufmgt', # mm/mremap.c, + 'move_vma': 'bufmgt', # mm/mremap.c, + 'mpage_alloc' : 'other', # fs/mpage.c, + 'mpage_bio_submit' : 'other', # fs/mpage.c, + 'mpage_end_io_write' : 'other', # fs/mpage.c, + 'mpage_readpage': 'other', # fs/mpage.c, include/linux/mpage.h, + 'mpage_readpages': 'other', # fs/mpage.c, include/linux/mpage.h, + 'mpage_writepage' : 'other', # fs/mpage.c, + 'mpage_writepages' : 'other', # fs/mpage.c, include/linux/mpage.h, + 'mv': 'other', # + 'n_tty_chars_in_buffer': 'driver', # drivers/char/n_tty.c, + 'n_tty_receive_buf': 'driver', # drivers/char/n_tty.c, + 'n_tty_receive_room': 'driver', # drivers/char/n_tty.c, + 'need_resched': 'driver', # include/linux/sched.h, drivers/char/tipar.c, + 'neigh_lookup': 'stack', # net/core/neighbour.c, + 'neigh_periodic_timer': 'stack', # net/core/neighbour.c, + 'neigh_resolve_output' : 'stack', # net/core/neighbour.c, + 'neigh_timer_handler': 'stack', # net/core/neighbour.c, net/core/neighbour.c, + 'neigh_update': 'stack', # net/core/neighbour.c, + 'net_rx_action' : 'driver', # net/core/dev.c, + 'net_tx_action' : 'driver', # net/core/dev.c, + 'netif_receive_skb' : 'driver', # net/core/dev.c, include/linux/netdevice.h, + 'netif_rx' : 'driver', # net/core/dev.c, include/linux/netdevice.h, + 'netperf' : 'user', + 'netserver': 'user', + 'new_inode' : 'other', # fs/inode.c, include/linux/fs.h, + 'next_signal' : 'other', # kernel/signal.c, + 'next_thread': 'other', # kernel/exit.c, + 'nf_hook_slow' : 'stack', # net/core/netfilter.c, include/linux/netfilter.h, + 'nf_iterate' : 'stack', # net/core/netfilter.c, + 'nfs3svc_decode_commitargs' : 'other', # fs/nfsd/nfs3xdr.c, include/linux/nfsd/xdr3.h, + 'nfs3svc_decode_writeargs' : 'other', # fs/nfsd/nfs3xdr.c, include/linux/nfsd/xdr3.h, + 'nfs3svc_encode_commitres' : 'other', # fs/nfsd/nfs3xdr.c, include/linux/nfsd/xdr3.h, + 'nfs3svc_encode_writeres' : 'other', # fs/nfsd/nfs3xdr.c, include/linux/nfsd/xdr3.h, + 'nfs3svc_release_fhandle' : 'other', # fs/nfsd/nfs3xdr.c, include/linux/nfsd/xdr3.h, + 'nfsd' : 'other', # fs/nfsd/nfssvc.c, fs/nfsd/nfssvc.c, + 'nfsd3_proc_commit' : 'other', # fs/nfsd/nfs3proc.c, + 'nfsd3_proc_write' : 'other', # fs/nfsd/nfs3proc.c, + 'nfsd_acceptable' : 'other', # fs/nfsd/nfsfh.c, + 'nfsd_cache_append' : 'other', # fs/nfsd/nfscache.c, fs/nfsd/nfscache.c, + 'nfsd_cache_lookup' : 'other', # fs/nfsd/nfscache.c, include/linux/nfsd/cache.h, + 'nfsd_cache_update' : 'other', # fs/nfsd/nfscache.c, include/linux/nfsd/cache.h, + 'nfsd_close' : 'other', # fs/nfsd/vfs.c, include/linux/nfsd/nfsd.h, + 'nfsd_commit' : 'other', # fs/nfsd/vfs.c, include/linux/nfsd/nfsd.h, + 'nfsd_dispatch' : 'other', # fs/nfsd/nfssvc.c, include/linux/nfsd/nfsd.h, + 'nfsd_open' : 'other', # fs/nfsd/vfs.c, include/linux/nfsd/nfsd.h, + 'nfsd_permission' : 'other', # fs/nfsd/vfs.c, include/linux/nfsd/nfsd.h, + 'nfsd_setuser' : 'other', # fs/nfsd/auth.c, include/linux/nfsd/auth.h, + 'nfsd_sync' : 'other', # fs/nfsd/vfs.c, + 'nfsd_write' : 'other', # fs/nfsd/vfs.c, include/linux/nfsd/nfsd.h, + 'no_pm_change_10_' : 'interrupt', # + 'no_quad' : 'interrupt', # + 'nonseekable_open' : 'other', # fs/open.c, include/linux/fs.h, + 'normal_int' : 'other', # + 'normal_poll': 'driver', # drivers/char/n_tty.c, + 'note_interrupt': 'interrupt', # + 'notifier_call_chain': 'other', # kernel/sys.c, include/linux/notifier.h, + 'notify_change': 'other', # fs/attr.c, include/linux/fs.h, + 'nr_blockdev_pages': 'other', # fs/block_dev.c, include/linux/blkdev.h, + 'nr_free_pages': 'bufmgt', # mm/page_alloc.c, include/linux/swap.h, + 'nr_running': 'other', # kernel/sched.c, include/linux/sched.h, + 'ns83820': 'driver', + 'ns83820_do_isr' : 'driver', + 'ns83820_hard_start_xmit' : 'driver', + 'ns83820_irq' : 'driver', + 'ns83820_rx_kick' : 'driver', + 'ns83820_tx_watch' : 'driver', + 'ns83821_do_isr' : 'driver', # + 'ns83821_hard_start_xmit' : 'driver', # + 'ns83821_irq' : 'driver', # + 'ns83821_rx_kick' : 'driver', # + 'number' : 'interrupt', # lib/vsprintf.c, arch/alpha/kernel/srm_env.c, + 'nvidia': 'other', # + 'old_mmap': 'interrupt', # + 'open_exec': 'other', # fs/exec.c, include/linux/fs.h, + 'open_namei' : 'user', # fs/namei.c, include/linux/fs.h, used to by syscall + 'open_private_file' : 'user', # fs/file_table.c, include/linux/fs.h, used to by syscall + 'oprofile': 'other', # + 'oprofiled': 'other', # + 'osf_brk': 'user', + 'osf_mmap': 'user', + 'osf_sigprocmask' : 'other', # + 'osync_buffers_list' : 'other', # fs/buffer.c, + 'padzero': 'other', # fs/binfmt_elf.c, + 'page_add_anon_rmap' : 'bufmgt', # mm/rmap.c, include/linux/rmap.h, + 'page_add_file_rmap': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, + 'page_address': 'bufmgt', # mm/highmem.c, include/linux/mm.h, include/linux/mm.h, include/linux/mm.h, + 'page_cache_readahead': 'bufmgt', # mm/readahead.c, include/linux/mm.h, + 'page_fault': 'interrupt', # + 'page_remove_rmap': 'bufmgt', # mm/rmap.c, include/linux/rmap.h, + 'page_slot': 'bufmgt', # mm/highmem.c, + 'page_symlink' : 'other', # fs/namei.c, include/linux/fs.h, + 'page_waitqueue' : 'bufmgt', # mm/filemap.c, + 'pagevec_lookup': 'bufmgt', # mm/swap.c, include/linux/pagevec.h, + 'pagevec_lookup_tag' : 'bufmgt', # mm/swap.c, include/linux/pagevec.h, + 'pal_dtb_ldq' : 'interrupt', # + 'pal_itb_ldq' : 'interrupt', # + 'pal_post_interrupt' : 'interrupt', # + 'path_lookup' : 'user', # fs/namei.c, used to by syscall + 'path_release' : 'user', # fs/namei.c, include/linux/namei.h, used to by syscall + 'pci_bus_read_config_word': 'driver', # include/linux/pci.h, + 'pci_conf1_read': 'driver', # + 'pci_dac_dma_supported' : 'driver', # arch/alpha/kernel/pci_iommu.c, include/asm-alpha/pci.h, + 'pci_map_page' : 'driver', # arch/alpha/kernel/pci_iommu.c, include/asm-generic/pci-dma-compat.h, include/asm-alpha/pci.h, + 'pci_map_single' : 'driver', # arch/alpha/kernel/pci_iommu.c, arch/alpha/kernel/pci-noop.c, include/asm-generic/pci-dma-compat.h, drivers/net/wan/wanxl.c, drivers/net/wan/wanxl.c, drivers/scsi/aic7xxx/aic79xx_osm.h, drivers/scsi/aic7xxx/aic7xxx_osm.h, include/asm-alpha/pci.h, + 'pci_map_single_1' : 'driver', # arch/alpha/kernel/pci_iommu.c, + 'pci_read': 'driver', # + 'pci_unmap_page' : 'driver', # arch/alpha/kernel/pci_iommu.c, include/asm-generic/pci-dma-compat.h, include/asm-alpha/pci.h, + 'pci_unmap_single' : 'driver', # arch/alpha/kernel/pci_iommu.c, arch/alpha/kernel/pci-noop.c, include/asm-generic/pci-dma-compat.h, drivers/scsi/aic7xxx/aic79xx_osm.h, drivers/scsi/aic7xxx/aic7xxx_osm.h, include/asm-alpha/pci.h, + 'percpu_counter_mod' : 'bufmgt', # mm/swap.c, include/linux/percpu_counter.h, + 'perl': 'other', # + 'permission' : 'user', # fs/namei.c, include/linux/fs.h, used to be syscall + 'pfifo_fast_dequeue' : 'stack', # net/sched/sch_generic.c, + 'pfifo_fast_enqueue' : 'stack', # net/sched/sch_generic.c, + 'pgd_alloc': 'bufmgt', # arch/alpha/mm/init.c, include/asm-alpha/pgalloc.h, include/asm-i386/pgalloc.h, + 'pgd_ctor': 'bufmgt', # include/asm-i386/pgtable.h, + 'pgd_free': 'bufmgt', # include/asm-alpha/pgalloc.h, include/asm-i386/pgalloc.h, + 'pipe_ioctl': 'other', # fs/pipe.c, + 'pipe_new': 'other', # fs/pipe.c, include/linux/pipe_fs_i.h, + 'pipe_poll': 'other', # fs/pipe.c, + 'pipe_read': 'other', # fs/pipe.c, + 'pipe_read_release': 'other', # fs/pipe.c, + 'pipe_readv': 'other', # fs/pipe.c, + 'pipe_release': 'other', # fs/pipe.c, + 'pipe_wait': 'other', # fs/pipe.c, include/linux/pipe_fs_i.h, + 'pipe_write': 'other', # fs/pipe.c, + 'pipe_write_fasync': 'other', # fs/pipe.c, + 'pipe_write_release': 'other', # fs/pipe.c, + 'pipe_writev': 'other', # fs/pipe.c, + 'pipefs_delete_dentry': 'other', # fs/pipe.c, + 'place_in_hashes' : 'stack', # net/ipv4/netfilter/ip_nat_core.c, include/linux/netfilter_ipv4/ip_nat_core.h, + 'poll_freewait' : 'other', # fs/select.c, include/linux/poll.h, + 'poll_idle': 'idle', # + 'poll_initwait' : 'other', # fs/select.c, include/linux/poll.h, + 'portmap': 'other', # + 'preempt_schedule': 'other', # kernel/sched.c, include/linux/preempt.h, + 'prep_new_page' : 'bufmgt', # mm/page_alloc.c, + 'prepare_binprm': 'other', # fs/exec.c, include/linux/binfmts.h, + 'prepare_to_copy': 'interrupt', # include/asm-alpha/processor.h, include/asm-i386/processor.h, + 'prepare_to_wait' : 'other', # kernel/fork.c, + 'prio_tree_expand': 'bufmgt', # mm/prio_tree.c, + 'prio_tree_insert': 'bufmgt', # mm/prio_tree.c, + 'prio_tree_remove': 'bufmgt', # mm/prio_tree.c, + 'prio_tree_replace': 'bufmgt', # mm/prio_tree.c, + 'proc_alloc_inode': 'other', # fs/proc/inode.c, + 'proc_calc_metrics': 'other', # fs/proc/proc_misc.c, + 'proc_delete_inode': 'other', # fs/proc/inode.c, + 'proc_destroy_inode': 'other', # fs/proc/inode.c, + 'proc_file_read': 'other', # fs/proc/generic.c, fs/proc/generic.c, + 'proc_get_inode': 'other', # fs/proc/inode.c, include/linux/proc_fs.h, + 'proc_lookup': 'other', # fs/proc/generic.c, include/linux/proc_fs.h, + 'proc_pid_unhash': 'other', # fs/proc/base.c, include/linux/proc_fs.h, + 'proc_pident_lookup': 'other', # fs/proc/base.c, + 'proc_root_lookup': 'other', # fs/proc/root.c, + 'process_backlog' : 'stack', # net/core/dev.c, + 'process_timeout': 'other', # kernel/timer.c, + 'profile_hit': 'other', # + 'profile_hook': 'other', # kernel/profile.c, include/linux/profile.h, include/linux/profile.h, + 'profile_munmap': 'other', # + 'profile_task_exit': 'other', # + 'profile_tick': 'other', # + 'pskb_expand_head': 'stack', # net/core/skbuff.c, include/linux/skbuff.h, + 'pte_alloc_map': 'bufmgt', # mm/memory.c, + 'pte_alloc_one': 'bufmgt', # include/asm-alpha/pgalloc.h, include/asm-i386/pgalloc.h, + 'ptrace_cancel_bpt' : 'user', # arch/alpha/kernel/ptrace.c, arch/alpha/kernel/proto.h, used to be syscall + 'pty_chars_in_buffer': 'driver', # drivers/char/pty.c, + 'pty_open': 'driver', # drivers/char/pty.c, + 'pty_write_room': 'driver', # drivers/char/pty.c, + 'put_device' : 'driver', # drivers/base/core.c, include/linux/device.h, + 'put_files_struct': 'other', # kernel/exit.c, + 'put_filp': 'other', # fs/file_table.c, include/linux/file.h, + 'put_io_context' : 'driver', # drivers/block/ll_rw_blk.c, include/linux/blkdev.h, + 'put_unused_fd' : 'other', # fs/open.c, + 'qdisc_restart' : 'stack', # net/sched/sch_generic.c, + 'queue_delayed_work': 'other', # kernel/workqueue.c, + 'queue_me': 'other', # kernel/futex.c, + 'quiesce' : 'idle', # + 'radix_tree_delete': 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_extend': 'other', # lib/radix-tree.c, + 'radix_tree_gang_lookup': 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_gang_lookup_tag' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_insert' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_lookup' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_node_alloc' : 'other', # lib/radix-tree.c, + 'radix_tree_preload' : 'other', # lib/radix-tree.c, lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_tag_clear' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_tag_set' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'radix_tree_tagged' : 'other', # lib/radix-tree.c, include/linux/radix-tree.h, + 'raise_softirq' : 'interrupt', # kernel/softirq.c, + 'raise_softirq_irqoff' : 'interrupt', # kernel/softirq.c, + 'rb_erase' : 'bufmgt', # lib/rbtree.c, include/linux/rbtree.h, + 'rb_insert_color' : 'bufmgt', # lib/rbtree.c, include/linux/rbtree.h, + 'rb_next' : 'bufmgt', # lib/rbtree.c, fs/jffs2/nodelist.h, include/linux/rbtree.h, + 'rb_prev' : 'bufmgt', # lib/rbtree.c, fs/jffs2/nodelist.h, include/linux/rbtree.h, + 'rcu_check_callbacks' : 'other', # kernel/rcupdate.c, include/linux/rcupdate.h, + 'rcu_check_quiescent_state' : 'other', # kernel/rcupdate.c, + 'rcu_do_batch' : 'other', # kernel/rcupdate.c, + 'rcu_process_callbacks' : 'other', # kernel/rcupdate.c, + 'rcu_start_batch' : 'other', # kernel/rcupdate.c, + 'read_block_bitmap' : 'other', # fs/udf/balloc.c, fs/ext2/balloc.c, fs/ext3/balloc.c, + 'real_lookup': 'other', # fs/namei.c, + 'rebalance_tick' : 'other', # kernel/sched.c, + 'recalc_bh_state' : 'other', # fs/buffer.c, + 'recalc_sigpending' : 'interrupt', # kernel/signal.c, include/linux/sched.h, + 'recalc_sigpending_tsk' : 'interrupt', # kernel/signal.c, + 'recalc_task_prio' : 'other', # kernel/sched.c, + 'release_blocks' : 'other', # fs/ext2/balloc.c, + 'release_pages' : 'bufmgt', # mm/swap.c, include/linux/pagemap.h, + 'release_sock' : 'stack', # net/core/sock.c, + 'release_task': 'other', # kernel/exit.c, include/linux/sched.h, + 'release_thread': 'interrupt', # arch/alpha/kernel/process.c, include/asm-um/processor-generic.h, include/asm-alpha/processor.h, include/asm-i386/processor.h, + 'release_x86_irqs': 'interrupt', # include/asm-i386/irq.h, + 'remove_arg_zero': 'other', # fs/exec.c, include/linux/binfmts.h, + 'remove_from_page_cache': 'bufmgt', # mm/filemap.c, include/linux/pagemap.h, + 'remove_suid' : 'bufmgt', # mm/filemap.c, include/linux/fs.h, + 'remove_vm_struct': 'bufmgt', # mm/mmap.c, + 'remove_wait_queue' : 'other', # kernel/fork.c, + 'resched_task' : 'other', # kernel/sched.c, + 'reserve_blocks' : 'other', # fs/ext2/balloc.c, + 'restore_all' : 'other', # + 'restore_fpu': 'interrupt', # include/asm-i386/i387.h, + 'restore_i387': 'interrupt', # include/asm-i386/i387.h, + 'restore_i387_fxsave': 'interrupt', # + 'restore_sigcontext' : 'interrupt', # arch/alpha/kernel/signal.c, + 'resume_kernel': 'interrupt', # + 'resume_userspace': 'other', # + 'ret_from_exception': 'other', # + 'ret_from_intr': 'interrupt', # + 'ret_from_reschedule' : 'other', # + 'ret_from_sys_call' : 'user', # arch/alpha/kernel/signal.c, used to be syscall + 'rm': 'other', # + 'rm_from_queue': 'other', # kernel/signal.c, + 'rmqueue_bulk' : 'bufmgt', # mm/page_alloc.c, + 'rt_check_expire': 'stack', # net/ipv4/route.c, + 'rt_hash_code' : 'stack', # net/ipv4/route.c, + 'rt_intern_hash': 'stack', # net/ipv4/route.c, net/ipv4/route.c, + 'rt_may_expire': 'stack', # net/ipv4/route.c, + 'rtc_enable_disable' : 'interrupt', # arch/alpha/kernel/irq_alpha.c, + 'rti_to_kern' : 'interrupt', # + 'rti_to_user' : 'user', # used to be syscall + 'run-parts': 'other', # + 'run_local_timers' : 'other', # kernel/timer.c, include/linux/timer.h, + 'run_timer_softirq' : 'other', # kernel/timer.c, + 'rx_action' : 'driver', # drivers/net/ns83820.c, + 'rx_irq' : 'driver', # drivers/net/ns83820.c, + 'rx_refill_atomic' : 'driver', # drivers/net/ns83820.c, + 'save_i387': 'interrupt', # include/asm-i386/i387.h, + 'save_i387_fxsave': 'interrupt', # + 'sched_clock' : 'user', # arch/alpha/kernel/time.c, include/linux/sched.h, used to be syscall + 'sched_exit': 'other', # kernel/sched.c, + 'sched_fork': 'other', # kernel/sched.c, + 'schedule' : 'other', # kernel/sched.c, include/linux/sched.h, + 'schedule_delayed_work': 'other', # kernel/workqueue.c, + 'schedule_tail': 'other', # kernel/sched.c, + 'schedule_timeout' : 'other', # kernel/timer.c, sound/oss/cs4281/cs4281m.c, + 'scheduler_tick' : 'other', # kernel/sched.c, include/linux/sched.h, + 'scsi_add_timer' : 'other', # drivers/scsi/scsi_error.c, + 'scsi_alloc_sgtable' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_cmd_ioctl': 'driver', # drivers/block/scsi_ioctl.c, include/linux/blkdev.h, + 'scsi_decide_disposition' : 'other', # drivers/scsi/scsi_error.c, drivers/scsi/scsi_priv.h, + 'scsi_delete_timer' : 'other', # drivers/scsi/scsi_error.c, + 'scsi_device_unbusy' : 'other', # drivers/scsi/scsi_lib.c, drivers/scsi/scsi_priv.h, + 'scsi_dispatch_cmd' : 'other', # drivers/scsi/scsi.c, drivers/scsi/scsi_priv.h, + 'scsi_done' : 'other', # drivers/scsi/scsi.c, drivers/scsi/scsi_priv.h, + 'scsi_end_request' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_finish_command' : 'other', # drivers/scsi/scsi.c, + 'scsi_free_sgtable' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_get_command' : 'other', # drivers/scsi/scsi.c, + 'scsi_init_cmd_errh' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_init_io' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_io_completion' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_mod': 'driver', + 'scsi_next_command' : 'other', # drivers/scsi/scsi_lib.c, drivers/scsi/scsi_priv.h, + 'scsi_prep_fn' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_put_command' : 'other', # drivers/scsi/scsi.c, + 'scsi_request_fn' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_run_queue' : 'other', # drivers/scsi/scsi_lib.c, + 'scsi_softirq' : 'other', # drivers/scsi/scsi.c, + 'sd_init_command' : 'other', # drivers/scsi/sd.c, drivers/scsi/sd.c, + 'sd_rw_intr' : 'other', # drivers/scsi/sd.c, drivers/scsi/sd.c, + 'search_binary_handler': 'other', # fs/exec.c, include/linux/binfmts.h, + 'second_overflow': 'interrupt', # kernel/timer.c, + 'secure_tcp_sequence_number' : 'stack', # drivers/char/random.c, include/linux/random.h, + 'sed': 'other', # + 'select_bits_alloc': 'other', # fs/compat.c, fs/select.c, + 'select_bits_free': 'other', # fs/compat.c, fs/select.c, + 'send_group_sig_info': 'other', # kernel/signal.c, include/linux/sched.h, + 'send_signal' : 'user', # kernel/signal.c, used to be syscall + 'seq_read': 'other', # fs/seq_file.c, include/linux/seq_file.h, + 'set_bh_page' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'set_binfmt': 'other', # fs/exec.c, include/linux/binfmts.h, + 'set_brk': 'user', # fs/binfmt_aout.c, fs/binfmt_elf.c, + 'set_current_groups' : 'other', # kernel/sys.c, include/linux/sched.h, + 'set_page_address': 'bufmgt', # mm/highmem.c, include/linux/mm.h, include/linux/mm.h, include/linux/mm.h, + 'set_page_dirty': 'bufmgt', # mm/page-writeback.c, + 'set_slab_attr' : 'bufmgt', # mm/slab.c, + 'set_task_comm': 'other', # + 'setfl' : 'user', # fs/fcntl.c, used to be syscall + 'setup_arg_pages': 'other', # fs/exec.c, include/linux/binfmts.h, + 'setup_frame' : 'interrupt', # arch/alpha/kernel/signal.c, + 'setup_sigcontext' : 'interrupt', # arch/alpha/kernel/signal.c, + 'show_stat': 'other', # fs/proc/proc_misc.c, + 'si_swapinfo': 'bufmgt', # mm/swapfile.c, include/linux/swap.h, include/linux/swap.h, + 'sig_ignored' : 'other', # kernel/signal.c, + 'signal_wake_up' : 'other', # kernel/signal.c, include/linux/sched.h, + 'sigprocmask' : 'other', # kernel/signal.c, include/linux/signal.h, + 'single_open': 'other', # fs/seq_file.c, include/linux/seq_file.h, + 'sk_alloc' : 'bufmgt', # net/core/sock.c, + 'sk_free' : 'bufmgt', # net/core/sock.c, + 'sk_reset_timer' : 'bufmgt', # net/core/sock.c, + 'sk_stop_timer' : 'bufmgt', # net/core/sock.c, + 'sk_stream_kill_queues' : 'bufmgt', # net/core/stream.c, + 'sk_stream_mem_schedule' : 'bufmgt', # net/core/stream.c, + 'sk_stream_rfree' : 'bufmgt', # net/core/stream.c, + 'sk_stream_wait_close' : 'bufmgt', # net/core/stream.c, + 'sk_stream_wait_memory' : 'bufmgt', # net/core/stream.c, + 'sk_stream_write_space' : 'bufmgt', # net/core/stream.c, + 'sk_wait_data' : 'bufmgt', # net/core/sock.c, + 'skb_checksum': 'stack', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_checksum_help': 'stack', # net/core/dev.c, include/linux/netdevice.h, + 'skb_clone' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_copy_and_csum_bits' : 'copy', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_copy_and_csum_datagram':'copy', + 'skb_copy_bits' : 'copy', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_copy_datagram_iovec' : 'copy', # net/core/datagram.c, include/linux/skbuff.h, + 'skb_dequeue' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_drop_fraglist' : 'bufmgt', # net/core/skbuff.c, + 'skb_free_datagram' : 'bufmgt', # net/core/datagram.c, include/linux/skbuff.h, + 'skb_queue_head': 'stack', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_queue_tail' : 'bufmgt', # net/core/skbuff.c, include/linux/skbuff.h, + 'skb_read_and_csum_bits' : 'bufmgt', # net/sunrpc/xprt.c, + 'skb_recv_datagram' : 'bufmgt', # net/core/datagram.c, include/linux/skbuff.h, + 'skb_release_data' : 'bufmgt', # net/core/skbuff.c, net/core/dev.c, + 'skip_atoi': 'other', # lib/vsprintf.c, + 'slab_destroy' : 'bufmgt', # mm/slab.c, + 'smp_apic_timer_interrupt': 'interrupt', # + 'smp_percpu_timer_interrupt' : 'interrupt', # arch/alpha/kernel/smp.c, arch/alpha/kernel/proto.h, + 'snap_rcv': 'stack', # net/802/psnap.c, + 'sock_aio_read' : 'stack', # net/socket.c, net/socket.c, + 'sock_aio_write': 'stack', # net/socket.c, net/socket.c, + 'sock_alloc' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_alloc_inode' : 'user', # net/socket.c, used to be syscall + 'sock_alloc_send_pskb' : 'user', # net/core/sock.c, used to be syscall + 'sock_alloc_send_skb' : 'user', # net/core/sock.c, used to be syscall + 'sock_close' : 'user', # net/socket.c, net/socket.c, used to be syscall + 'sock_common_recvmsg' : 'user', # net/core/sock.c, used to be syscall + 'sock_def_readable' : 'user', # net/core/sock.c, used to be syscall + 'sock_def_wakeup' : 'user', # net/core/sock.c, used to be syscall + 'sock_destroy_inode' : 'user', # net/socket.c, used to be syscall + 'sock_disable_timestamp' : 'user', # net/core/sock.c, used to be syscall + 'sock_fasync' : 'user', # net/socket.c, net/socket.c, used to be syscall + 'sock_init_data': 'stack', # net/core/sock.c, + 'sock_ioctl': 'stack', # net/socket.c, net/socket.c, + 'sock_map_fd' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_poll' : 'user', # net/socket.c, net/socket.c, used to be syscall + 'sock_readv': 'stack', # net/socket.c, net/socket.c, + 'sock_readv_writev' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_recvmsg' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_release' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_rfree' : 'user', # net/core/sock.c, used to be syscall + 'sock_sendmsg' : 'user', # net/socket.c, include/linux/net.h, used to be syscall + 'sock_wfree' : 'user', # net/core/sock.c, used to be syscall + 'sock_wmalloc' : 'user', # net/core/sock.c, used to be syscall + 'sock_writev' : 'user', # net/socket.c, net/socket.c, used to be syscall + 'sockfd_lookup' : 'user', # net/socket.c, net/sched/sch_atm.c, include/linux/net.h, used to be syscall + 'sockfs_delete_dentry' : 'user', # net/socket.c, used to be syscall + 'sort': 'driver', # drivers/scsi/eata.c, drivers/scsi/u14-34f.c, + 'split_vma': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'sprintf' : 'other', # lib/vsprintf.c, drivers/isdn/hardware/eicon/platform.h, + 'sshd': 'other', # + 'steal_locks': 'other', # fs/locks.c, include/linux/fs.h, + 'strcmp' : 'copy', # lib/string.c, + 'strlcpy': 'other', # lib/string.c, + 'strlen' : 'copy', # lib/string.c, include/asm-alpha/string.h, + 'strncpy' : 'copy', # lib/string.c, include/asm-alpha/string.h, + 'strncpy_from_user': 'copy', # include/asm-alpha/uaccess.h, include/asm-i386/uaccess.h, + 'strnlen_user': 'other', # include/asm-alpha/uaccess.h, include/asm-i386/uaccess.h, + 'submit_bh' : 'bufmgt', # fs/buffer.c, include/linux/buffer_head.h, + 'submit_bio' : 'other', # drivers/block/ll_rw_blk.c, include/linux/fs.h, + 'sunrpc': 'other', # + 'svc_authenticate' : 'other', # net/sunrpc/svcauth.c, include/linux/sunrpc/svcauth.h, + 'svc_authorise' : 'other', # net/sunrpc/svcauth.c, include/linux/sunrpc/svcauth.h, + 'svc_deferred_dequeue' : 'other', # net/sunrpc/svcsock.c, net/sunrpc/svcsock.c, + 'svc_drop' : 'other', # net/sunrpc/svcsock.c, include/linux/sunrpc/svcsock.h, + 'svc_expkey_lookup' : 'other', # fs/nfsd/export.c, + 'svc_export_put' : 'other', # fs/nfsd/export.c, include/linux/nfsd/export.h, + 'svc_process' : 'other', # net/sunrpc/svc.c, include/linux/sunrpc/svc.h, + 'svc_recv' : 'other', # net/sunrpc/svcsock.c, include/linux/sunrpc/svcsock.h, + 'svc_reserve' : 'other', # net/sunrpc/svcsock.c, include/linux/sunrpc/svc.h, + 'svc_send' : 'other', # net/sunrpc/svcsock.c, include/linux/sunrpc/svcsock.h, + 'svc_sendto' : 'other', # net/sunrpc/svcsock.c, + 'svc_sock_enqueue' : 'other', # net/sunrpc/svcsock.c, + 'svc_sock_release' : 'other', # net/sunrpc/svcsock.c, + 'svc_udp_data_ready' : 'other', # net/sunrpc/svcsock.c, net/sunrpc/svcsock.c, + 'svc_udp_recvfrom' : 'other', # net/sunrpc/svcsock.c, net/sunrpc/svcsock.c, + 'svc_udp_sendto' : 'other', # net/sunrpc/svcsock.c, net/sunrpc/svcsock.c, + 'svc_write_space' : 'other', # net/sunrpc/svcsock.c, + 'svcauth_unix_accept' : 'other', # net/sunrpc/svcauth_unix.c, + 'svcauth_unix_release' : 'other', # net/sunrpc/svcauth_unix.c, + 'switch_names': 'other', # fs/dcache.c, + 'swpctx_cont' : 'other', # + 'sync_buffer' : 'other', # fs/buffer.c, drivers/oprofile/buffer_sync.c, + 'sync_dirty_buffer' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'sync_inode' : 'other', # fs/fs-writeback.c, include/linux/fs.h, + 'sync_mapping_buffers' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'sync_sb_inodes': 'other', # fs/fs-writeback.c, + 'sync_supers': 'other', # fs/super.c, include/linux/fs.h, + 'sys_accept' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_access': 'other', # fs/open.c, include/linux/syscalls.h, + 'sys_brk': 'user', # mm/mmap.c, mm/nommu.c, include/linux/syscalls.h, + 'sys_clock_gettime': 'user', # kernel/posix-timers.c, include/linux/syscalls.h, + 'sys_clone': 'user', # include/asm-i386/unistd.h, + 'sys_close' : 'user', # fs/open.c, include/linux/syscalls.h, used to be syscall + 'sys_dup2': 'user', # fs/fcntl.c, include/linux/syscalls.h, + 'sys_execve': 'user', # include/asm-alpha/unistd.h, include/asm-i386/unistd.h, + 'sys_exit_group': 'user', # kernel/exit.c, include/linux/syscalls.h, + 'sys_fcntl' : 'user', # fs/fcntl.c, include/linux/syscalls.h, used to be syscall + 'sys_fcntl64': 'user', # fs/fcntl.c, include/linux/syscalls.h, + 'sys_fstat64': 'user', # fs/stat.c, include/linux/syscalls.h, + 'sys_ftruncate': 'user', # fs/open.c, include/linux/syscalls.h, + 'sys_futex': 'user', # kernel/futex.c, include/linux/syscalls.h, + 'sys_getdents64': 'user', + 'sys_geteuid': 'other', # kernel/timer.c, include/linux/syscalls.h, + 'sys_getgroups': 'user', # kernel/sys.c, include/linux/syscalls.h, + 'sys_getpid': 'user', # kernel/timer.c, include/linux/syscalls.h, + 'sys_getppid': 'other', # kernel/timer.c, include/linux/syscalls.h, + 'sys_getrlimit': 'other', # kernel/sys.c, include/linux/syscalls.h, + 'sys_getsockname' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_gettimeofday' : 'user', # kernel/time.c, include/linux/syscalls.h, used to be syscall + 'sys_getuid': 'user', # kernel/timer.c, include/linux/syscalls.h, + 'sys_getxpid' : 'user', # used to be syscall + 'sys_int_21' : 'interrupt', # + 'sys_int_22' : 'interrupt', # + 'sys_interrupt' : 'interrupt', # + 'sys_ioctl': 'user', # fs/ioctl.c, drivers/block/cciss.c, include/linux/syscalls.h, + 'sys_kill' : 'user', # kernel/signal.c, include/linux/syscalls.h, used to be syscall + 'sys_llseek': 'other', # fs/read_write.c, include/linux/syscalls.h, + 'sys_lseek': 'user', # fs/read_write.c, include/linux/syscalls.h, + 'sys_mkdir': 'user', # fs/namei.c, include/linux/syscalls.h, + 'sys_mmap2': 'user', # include/asm-i386/unistd.h, + 'sys_mremap': 'user', # mm/mremap.c, include/linux/syscalls.h, + 'sys_munmap': 'user', # mm/mmap.c, mm/nommu.c, include/linux/syscalls.h, + 'sys_nanosleep': 'user', # kernel/timer.c, include/linux/syscalls.h, + 'sys_newlstat' : 'user', # fs/stat.c, include/linux/syscalls.h, used to be syscall + 'sys_newstat' : 'user', # fs/stat.c, include/linux/syscalls.h, used to be syscall + 'sys_newuname': 'user', # kernel/sys.c, include/linux/syscalls.h, + 'sys_open' : 'user', # fs/open.c, include/linux/syscalls.h, used to be syscall + 'sys_pipe': 'interrupt', # include/asm-i386/unistd.h, + 'sys_poll' : 'user', # fs/select.c, include/linux/syscalls.h, used to be syscall + 'sys_read' : 'user', # fs/read_write.c, include/linux/syscalls.h, used to be syscall + 'sys_recv' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_recvfrom' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_rename': 'other', # fs/namei.c, include/linux/syscalls.h, + 'sys_rmdir': 'user', + 'sys_rt_sigaction': 'user', # arch/alpha/kernel/signal.c, kernel/signal.c, include/asm-alpha/unistd.h, include/asm-i386/unistd.h, + 'sys_rt_sigprocmask': 'user', # kernel/signal.c, include/linux/syscalls.h, + 'sys_select': 'user', # fs/select.c, include/linux/syscalls.h, + 'sys_send' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_sendto' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_set_thread_area': 'user', # + 'sys_setitimer': 'user', # kernel/itimer.c, include/linux/syscalls.h, + 'sys_shutdown' : 'user', # net/socket.c, include/linux/syscalls.h, used to be syscall + 'sys_sigreturn' : 'user', # used to be syscall + 'sys_sigsuspend' : 'user', # used to be syscall + 'sys_socketcall': 'user', # net/socket.c, include/linux/syscalls.h, + 'sys_stat64': 'user', # fs/stat.c, include/linux/syscalls.h, + 'sys_time': 'other', # kernel/time.c, include/linux/syscalls.h, + 'sys_times': 'other', # kernel/sys.c, include/linux/syscalls.h, + 'sys_umask': 'other', # kernel/sys.c, include/linux/syscalls.h, + 'sys_unlink': 'other', # fs/namei.c, include/linux/syscalls.h, + 'sys_wait4': 'user', # kernel/exit.c, include/linux/syscalls.h, + 'sys_waitpid': 'user', # kernel/exit.c, include/linux/syscalls.h, + 'sys_write' : 'user', # fs/read_write.c, include/linux/syscalls.h, used to be syscall + 'sys_writev' : 'user', # fs/read_write.c, include/linux/syscalls.h, used to be syscall + 'syscall_call': 'other', # + 'syscall_exit': 'other', # + 'sysguard_panelapplet.so': 'other', # + 'syslogd': 'other', # + 'system_call': 'interrupt', # + 'tail': 'other', # + 'task_curr' : 'other', # kernel/sched.c, include/linux/sched.h, + 'task_rq_lock' : 'other', # kernel/sched.c, + 'task_timeslice' : 'other', # kernel/sched.c, + 'tasklet_action' : 'other', # kernel/softirq.c, + 'tcp_accept' : 'stack', # net/ipv4/tcp.c, + 'tcp_ack' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_ack_no_tstamp' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_ack_update_window' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_bucket_destroy' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_check_req' : 'stack', # net/ipv4/tcp_minisocks.c, + 'tcp_child_process' : 'stack', # net/ipv4/tcp_minisocks.c, + 'tcp_clean_rtx_queue' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_clear_xmit_timers' : 'stack', # net/ipv4/tcp_timer.c, + 'tcp_close' : 'stack', # net/ipv4/tcp.c, + 'tcp_close_state' : 'stack', # net/ipv4/tcp.c, + 'tcp_copy_to_iovec' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_create_openreq_child' : 'stack', # net/ipv4/tcp_minisocks.c, + 'tcp_current_mss': 'other', # + 'tcp_cwnd_application_limited': 'stack', # net/ipv4/tcp_input.c, + 'tcp_data_queue' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_delete_keepalive_timer' : 'stack', # net/ipv4/tcp_timer.c, + 'tcp_destroy_sock' : 'stack', # net/ipv4/tcp.c, + 'tcp_enter_quickack_mode' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_event_data_recv' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_fin' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_fixup_rcvbuf' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_fixup_sndbuf' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_fragment': 'stack', # net/ipv4/tcp_output.c, + 'tcp_incr_quickack' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_init_buffer_space' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_init_metrics' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_init_xmit_timers' : 'stack', # net/ipv4/tcp_timer.c, + 'tcp_invert_tuple' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_tcp.c, + 'tcp_make_synack' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_new' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_tcp.c, + 'tcp_new_space' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_ofo_queue' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_packet' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_tcp.c, + 'tcp_parse_options' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_pkt_to_tuple' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_tcp.c, + 'tcp_poll' : 'stack', # net/ipv4/tcp.c, + 'tcp_prequeue_process' : 'stack', # net/ipv4/tcp.c, + 'tcp_push_one' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_put_port' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_queue_skb' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_rcv_established' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_rcv_rtt_update' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_rcv_space_adjust' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_rcv_state_process' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_recvmsg' : 'stack', # net/ipv4/tcp.c, + 'tcp_reset_keepalive_timer' : 'stack', # net/ipv4/tcp_timer.c, + 'tcp_rtt_estimator' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_send_ack' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_send_delayed_ack' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_send_fin' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_sendmsg' : 'stack', # net/ipv4/tcp.c, + 'tcp_set_skb_tso_segs': 'other', # + 'tcp_shutdown' : 'stack', # net/ipv4/tcp.c, + 'tcp_sync_mss' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_time_wait' : 'stack', # net/ipv4/tcp_minisocks.c, + 'tcp_transmit_skb' : 'stack', # net/ipv4/tcp_output.c, + 'tcp_trim_head': 'stack', # net/ipv4/tcp_output.c, + 'tcp_tso_acked': 'stack', # + 'tcp_tw_schedule' : 'stack', # net/ipv4/tcp_minisocks.c, + 'tcp_unhash' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_update_metrics' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_urg' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_v4_checksum_init':'stack', + 'tcp_v4_conn_request' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_connect': 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_destroy_sock' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_do_rcv' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_hnd_req' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_init_sock': 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_rcv' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_rebuild_header' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_route_req' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_search_req' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_send_check' : 'stack', # net/ipv4/tcp_ipv4.c, net/ipv4/tcp_ipv4.c, + 'tcp_v4_send_synack' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_syn_recv_sock' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_v4_synq_add' : 'stack', # net/ipv4/tcp_ipv4.c, + 'tcp_vegas_init' : 'stack', # net/ipv4/tcp_input.c, + 'tcp_write_xmit' : 'stack', # net/ipv4/tcp_output.c, + 'test_clear_page_dirty': 'bufmgt', # mm/page-writeback.c, include/linux/page-flags.h, + 'test_clear_page_writeback' : 'bufmgt', # mm/page-writeback.c, include/linux/page-flags.h, + 'test_set_page_writeback' : 'bufmgt', # mm/page-writeback.c, include/linux/page-flags.h, + 'timer_interrupt' : 'interrupt', # arch/alpha/kernel/time.c, arch/alpha/kernel/proto.h, + 'tr': 'other', # + 'truncate_complete_page': 'bufmgt', # mm/truncate.c, + 'truncate_inode_pages': 'bufmgt', # mm/truncate.c, include/linux/mm.h, + 'try_to_wake_up' : 'other', # kernel/sched.c, + 'tsunami_readb': 'driver', + 'tsunami_readl' : 'interrupt', # include/asm-alpha/core_tsunami.h, + 'tsunami_update_irq_hw' : 'interrupt', # arch/alpha/kernel/sys_dp264.c, + 'tsunami_writeb': 'driver', + 'tsunami_writel' : 'interrupt', # include/asm-alpha/core_tsunami.h, + 'tty_hung_up_p': 'driver', # drivers/char/tty_io.c, include/linux/tty.h, + 'tty_ldisc_deref': 'other', # + 'tty_ldisc_ref_wait': 'other', # + 'tty_ldisc_try': 'other', # + 'tty_open': 'driver', # drivers/char/tty_io.c, drivers/char/tty_io.c, drivers/net/wan/sdla_chdlc.c, + 'tty_poll': 'driver', # drivers/char/tty_io.c, drivers/char/tty_io.c, + 'tty_write': 'driver', # drivers/char/tty_io.c, drivers/char/tty_io.c, + 'udp_checksum_init' : 'stack', # net/ipv4/udp.c, + 'udp_ioctl': 'stack', # net/ipv4/udp.c, + 'udp_packet' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_udp.c, + 'udp_pkt_to_tuple' : 'stack', # net/ipv4/netfilter/ip_conntrack_proto_udp.c, + 'udp_push_pending_frames' : 'stack', # net/ipv4/udp.c, + 'udp_queue_rcv_skb' : 'stack', # net/ipv4/udp.c, + 'udp_rcv' : 'stack', # net/ipv4/udp.c, + 'udp_recvmsg': 'stack', # net/ipv4/udp.c, + 'udp_sendmsg' : 'stack', # net/ipv4/udp.c, + 'udp_sendpage' : 'stack', # net/ipv4/udp.c, + 'udp_v4_get_port': 'stack', # net/ipv4/udp.c, + 'udp_v4_lookup_longway' : 'stack', # net/ipv4/udp.c, + 'unalign_trap_cont' : 'alignment', + 'unalign_trap_count' : 'alignment', + 'undo_switch_stack' : 'other', # + 'unix': 'other', # + 'unlock_buffer' : 'other', # fs/buffer.c, + 'unlock_new_inode': 'other', # fs/inode.c, include/linux/fs.h, + 'unlock_page' : 'bufmgt', # mm/filemap.c, + 'unmap_mapping_range': 'bufmgt', # mm/memory.c, include/linux/mm.h, + 'unmap_page_range': 'bufmgt', # mm/memory.c, + 'unmap_region': 'bufmgt', # mm/mmap.c, + 'unmap_underlying_metadata' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'unmap_vma': 'bufmgt', # mm/mmap.c, + 'unmap_vma_list': 'bufmgt', # mm/mmap.c, + 'unmap_vmas': 'bufmgt', # mm/memory.c, include/linux/mm.h, + 'unmask_IO_APIC_irq': 'interrupt', # + 'unmask_IO_APIC_vector': 'interrupt', # + 'unqueue_me': 'other', # kernel/futex.c, + 'unshare_files': 'other', # kernel/fork.c, include/linux/fs.h, + 'up' : 'driver', # arch/alpha/kernel/semaphore.c, include/asm-alpha/semaphore.h, net/ipv4/netfilter/ip_tables.c, net/ipv6/netfilter/ip6_tables.c, drivers/video/atafb.c, include/asm-alpha/semaphore.h, + 'update_atime': 'other', # fs/inode.c, include/linux/fs.h, + 'update_one_process' : 'other', # kernel/timer.c, + 'update_process_times' : 'other', # kernel/timer.c, include/linux/sched.h, + 'update_wall_time' : 'other', # kernel/timer.c, + 'update_wall_time_one_tick' : 'other', # kernel/timer.c, + 'usbcore': 'other', # + 'vfs_create': 'other', # fs/namei.c, include/linux/fs.h, + 'vfs_fstat': 'other', # fs/stat.c, include/linux/fs.h, + 'vfs_getattr' : 'user', # fs/stat.c, include/linux/fs.h, used to be syscall + 'vfs_llseek': 'other', # fs/read_write.c, include/linux/fs.h, + 'vfs_lstat' : 'user', # fs/stat.c, include/linux/fs.h, used to be syscall + 'vfs_mkdir': 'other', # fs/namei.c, include/linux/fs.h, + 'vfs_permission' : 'user', # fs/namei.c, include/linux/fs.h, used to be syscall + 'vfs_read' : 'user', # fs/read_write.c, include/linux/fs.h, used to be syscall + 'vfs_rename': 'other', # fs/namei.c, include/linux/fs.h, + 'vfs_rename_other': 'other', # fs/namei.c, + 'vfs_stat' : 'user', # fs/stat.c, include/linux/fs.h, used to be syscall + 'vfs_unlink': 'other', # fs/namei.c, include/linux/fs.h, + 'vfs_write' : 'user', # fs/read_write.c, include/linux/fs.h, used to be syscall + 'vfs_writev' : 'user', # fs/read_write.c, include/linux/fs.h, used to be syscall + 'vma_adjust': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'vma_link': 'bufmgt', # mm/mmap.c, + 'vma_merge': 'bufmgt', # mm/mmap.c, include/linux/mm.h, + 'vma_prio_tree_add': 'bufmgt', # mm/prio_tree.c, include/linux/mm.h, + 'vma_prio_tree_insert': 'bufmgt', # mm/prio_tree.c, include/linux/mm.h, + 'vma_prio_tree_remove': 'bufmgt', # mm/prio_tree.c, include/linux/mm.h, + 'vmstat_open': 'other', # fs/proc/proc_misc.c, + 'vmstat_show': 'bufmgt', # mm/page_alloc.c, + 'vmtruncate': 'bufmgt', # mm/nommu.c, mm/memory.c, include/linux/mm.h, + 'vsnprintf' : 'other', # lib/vsprintf.c, include/linux/kernel.h, + 'vsprintf' : 'driver', # lib/vsprintf.c, arch/alpha/boot/main.c, drivers/scsi/aic7xxx_old/aic7xxx_proc.c, include/linux/kernel.h, + 'wait_for_completion': 'driver', # drivers/acorn/block/mfmhd.c, kernel/sched.c, + 'wait_on_page_writeback_range' : 'bufmgt', # mm/filemap.c, + 'wait_task_zombie': 'other', # kernel/exit.c, + 'wake_futex': 'other', # kernel/futex.c, + 'wake_up_buffer' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'wake_up_inode' : 'other', # fs/inode.c, include/linux/writeback.h, + 'wake_up_new_task': 'other', # + 'wake_up_page' : 'bufmgt', # mm/filemap.c, + 'wake_up_process' : 'other', # kernel/sched.c, + 'wake_up_state' : 'other', # kernel/sched.c, + 'wb_timer_fn': 'bufmgt', # mm/page-writeback.c, mm/page-writeback.c, + 'wc': 'other', # + 'work_notifysig': 'other', # + 'work_pending' : 'other', # + 'work_resched': 'other', # + 'worker_thread': 'other', # kernel/workqueue.c, + 'write_boundary_block' : 'other', # fs/buffer.c, include/linux/buffer_head.h, + 'write_chan': 'driver', # drivers/char/n_tty.c, + 'write_inode' : 'other', # fs/fs-writeback.c, + 'write_null': 'driver', # drivers/char/mem.c, + 'writeback_acquire': 'other', # fs/fs-writeback.c, include/linux/backing-dev.h, + 'writeback_in_progress' : 'other', # fs/fs-writeback.c, include/linux/backing-dev.h, + 'writeback_inodes': 'other', # fs/fs-writeback.c, include/linux/writeback.h, + 'xdr_partial_copy_from_skb' : 'copy', # net/sunrpc/xdr.c, include/linux/sunrpc/xdr.h, + 'xfrm_lookup' : 'stack', # net/xfrm/xfrm_policy.c, + 'xmms': 'other', # + 'zap_pmd_range': 'bufmgt', # mm/memory.c, + 'zap_pte_range': 'bufmgt', # mm/memory.c, + 'zone_statistics' : 'bufmgt' # mm/page_alloc.c, +} + +categories_re = [ +# ( re.compile('.*'), 'other' ) +] + + diff --git a/util/oprofile-top.py b/util/oprofile-top.py new file mode 100755 index 000000000..5ada86c2f --- /dev/null +++ b/util/oprofile-top.py @@ -0,0 +1,63 @@ +#! /usr/bin/env python +import sys +import re +import getopt +from categories import * + +def category(app,sym): + if re.search("vmlinux-2.6", app): + name = sym + else: + name = app + + if categories.has_key(name): + return categories[name] + for regexp, cat in categories_re: + if regexp.match(name): + return cat + print "no match for symbol %s" % name + return 'other' + +try: + (opts, files) = getopt.getopt(sys.argv[1:], 'i') +except getopt.GetoptError: + print "usage", sys.argv[0], "[-i] <files>" + sys.exit(2) + +showidle = True + +for o,v in opts: + if o == "-i": + showidle = False +print files +f = open(files.pop()) +total = 0 +prof = {} +linenum = 0 +for line in f.readlines(): + line = re.sub("\(no symbols\)", "nosym", line) + line = re.sub("anonymous.*", "nosym", line) + linenum += 1 + if linenum < 4: + continue + (count, percent, app, sym) = line.split() + #total += int(count) + cat = category(app,sym) + if cat != 'idle' or showidle: + total += int(count) + prof[cat] = prof.get(cat,0) + int(count) + +cats = ['other', 'user', 'copy', 'bufmgt', 'stack', 'driver', 'interrupt', 'alignment' ] + +if showidle: + cats.insert(0,'idle') + +#syms = [(i[1], i[0]) for i in prof.items()] +#syms.sort() +#for i in range(len(syms)): +# print "%s -- %5.1f%% " % (prof[i][1], 100 * float(prof[i][0])/float(total)) + +for d in cats: + if prof.has_key(d): + print "%s -- %5.1f%% " % (d, 100 * float(prof[d])/float(total)) + diff --git a/util/pbs/send.py b/util/pbs/send.py index b796cadbd..f8ca5209c 100755 --- a/util/pbs/send.py +++ b/util/pbs/send.py @@ -45,14 +45,16 @@ progpath = nfspath(sys.path[0]) progname = basename(sys.argv[0]) usage = """\ Usage: - %(progname)s [-c] [-e] [-f] [-q queue] [-v] <regexp> + %(progname)s [-c] [-e] [-f] [-j <jobfile>] [-q queue] [-v] <regexp> -c clean directory if job can be run -e only echo pbs command info, don't actually send the job -f force the job to run regardless of state -q <queue> submit job to the named queue + -j <jobfile> specify the jobfile (default is <basedir>/test.py) -v be verbose - %(progname)s -l [-v] <regexp> + %(progname)s [-j <jobfile>] -l [-v] <regexp> + -j <jobfile> specify the jobfile (default is <basedir>/test.py) -l list job names, don't submit -v be verbose (list job parameters) @@ -62,7 +64,7 @@ Usage: try: import getopt - opts, args = getopt.getopt(sys.argv[1:], '-cd:efhlq:v') + opts, args = getopt.getopt(sys.argv[1:], '-cd:efhj:lq:v') except getopt.GetoptError: sys.exit(usage) @@ -74,6 +76,7 @@ listonly = False queue = '' verbose = False rootdir = nfspath(os.getcwd()) +jfile = 'test.py' for opt,arg in opts: if opt == '-c': clean = True @@ -86,6 +89,8 @@ for opt,arg in opts: if opt == '-h': print usage sys.exit(0) + if opt == '-j': + jfile = arg if opt == '-l': listonly = True if opt == '-q': @@ -115,7 +120,7 @@ if not listonly and not onlyecho and isdir(linkdir): import job, jobfile, pbs -test = jobfile.JobFile(joinpath(basedir, 'test.py')) +test = jobfile.JobFile(joinpath(basedir, jfile)) joblist = [] for jobname in test.jobs: diff --git a/util/stats/display.py b/util/stats/display.py index 68a26852d..4c17d4427 100644 --- a/util/stats/display.py +++ b/util/stats/display.py @@ -68,7 +68,7 @@ class VectorDisplay: p.flags = self.flags p.precision = self.precision - if issequence(self.value): + if isinstance(self.value, (list, tuple)): if not len(self.value): return diff --git a/util/stats/info.py b/util/stats/info.py index 01d7bdb0f..3f6a8dbc3 100644 --- a/util/stats/info.py +++ b/util/stats/info.py @@ -6,9 +6,6 @@ display_run = 0 global globalTicks globalTicks = None -def issequence(t): - return isinstance(t, types.TupleType) or isinstance(t, types.ListType) - def total(f): if isinstance(f, FormulaStat): v = f.value @@ -16,7 +13,7 @@ def total(f): v = f f = FormulaStat() - if issequence(v): + if isinstance(v, (list, tuple)): f.value = reduce(operator.add, v) else: f.value = v @@ -29,7 +26,7 @@ def unaryop(op, f): else: v = f - if issequence(v): + if isinstance(v, (list, tuple)): return map(op, v) else: return op(v) @@ -109,19 +106,19 @@ def binaryop(op, lf, rf): return result def sums(x, y): - if issequence(x): + if isinstance(x, (list, tuple)): return map(lambda x, y: x + y, x, y) else: return x + y -def alltrue(list): - return reduce(lambda x, y: x and y, list) +def alltrue(seq): + return reduce(lambda x, y: x and y, seq) -def allfalse(list): - return not reduce(lambda x, y: x or y, list) +def allfalse(seq): + return not reduce(lambda x, y: x or y, seq) -def enumerate(list): - return map(None, range(len(list)), list) +def enumerate(seq): + return map(None, range(len(seq)), seq) def cmp(a, b): if a < b: @@ -323,10 +320,11 @@ class Vector(Statistic,FormulaStat): len(self.value) == len(other.value) def __eq__(self, other): - if issequence(self.value) != issequence(other.value): + if isinstance(self.value, (list, tuple)) != \ + isinstance(other.value, (list, tuple)): return False - if issequence(self.value): + if isinstance(self.value, (list, tuple)): if len(self.value) != len(other.value): return False else: @@ -348,7 +346,7 @@ class Vector(Statistic,FormulaStat): def __itruediv__(self, other): if not other: return self - if issequence(self.value): + if isinstance(self.value, (list, tuple)): for i in xrange(len(self.value)): self.value[i] /= other else: @@ -642,7 +640,8 @@ class VectorDist(Statistic): return alltrue(map(lambda x, y : x == y, self.dist, other.dist)) def __isub__(self, other): - if issequence(self.dist) and issequence(other.dist): + if isinstance(self.dist, (list, tuple)) and \ + isinstance(other.dist, (list, tuple)): for sd,od in zip(self.dist, other.dist): sd -= od else: @@ -650,7 +649,8 @@ class VectorDist(Statistic): return self def __iadd__(self, other): - if issequence(self.dist) and issequence(other.dist): + if isinstance(self.dist, (list, tuple)) and \ + isinstance(other.dist, (list, tuple)): for sd,od in zip(self.dist, other.dist): sd += od else: @@ -660,7 +660,7 @@ class VectorDist(Statistic): def __itruediv__(self, other): if not other: return self - if issequence(self.dist): + if isinstance(self.dist, (list, tuple)): for dist in self.dist: dist /= other else: diff --git a/util/stats/print.py b/util/stats/print.py index f4492cd2b..1ed50eef0 100644 --- a/util/stats/print.py +++ b/util/stats/print.py @@ -71,7 +71,7 @@ class VectorDisplay: p.flags = self.flags p.precision = self.precision - if issequence(self.value): + if isinstance(self.value, (list, tuple)): if not len(self.value): return diff --git a/util/stats/stats.py b/util/stats/stats.py index c9b7ab2ac..eedb006a0 100755 --- a/util/stats/stats.py +++ b/util/stats/stats.py @@ -19,6 +19,9 @@ Usage: %s [-E] [-F] [-d <db> ] [-g <get> ] [-h <host>] [-p] stability <pairnum> <stats> Calculated statistical info about stats stat <regex> Show stat data (only matching regex) stats [regex] List all stats (only matching regex) + + database <command> Where command is drop, init, or clean + ''' % sys.argv[0] sys.exit(1) @@ -100,7 +103,7 @@ def graphdata68(runs, options, tag, label, value): #print >>f, '#set sublabels = %s' % ' '.join(configs) print >>f, '#set sublabels = ste hte htd ocm occ ocs' - for speed,freq in zip(['s', '6', '8', 'q'],['4GHz', '6GHz','8GHz', '10GHz']): + for speed,freq in zip(['s', 'm', 'f', 'q'],['4GHz', '6GHz','8GHz', '10GHz']): print >>f, '"%s"' % freq, for conf in configs: name = '%s.%s.%s.%s.%s' % (conf, bench, dma, cache, speed) @@ -456,41 +459,41 @@ def commands(options, command, args): if command == 'usertime': import copy - kernel = copy.copy(system.full_cpu.numCycles) + kernel = copy.copy(system.full0.numCycles) kernel.bins = 'kernel' - user = copy.copy(system.full_cpu.numCycles) + user = copy.copy(system.full0.numCycles) user.bins = 'user' if options.graph: graphdata(runs, options, 'usertime', 'User Fraction', - user / system.full_cpu.numCycles) + user / system.full0.numCycles) else: - printdata(runs, user / system.full_cpu.numCycles) + printdata(runs, user / system.full0.numCycles) return if command == 'ticks': if options.binned: print 'kernel ticks' - system.full_cpu.numCycles.bins = 'kernel' - printdata(runs, system.full_cpu.numCycles) + system.full0.numCycles.bins = 'kernel' + printdata(runs, system.full0.numCycles) print 'idle ticks' - system.full_cpu.numCycles.bins = 'idle' - printdata(runs, system.full_cpu.numCycles) + system.full0.numCycles.bins = 'idle' + printdata(runs, system.full0.numCycles) print 'user ticks' - system.full_cpu.numCycles.bins = 'user' - printdata(runs, system.full_cpu.numCycles) + system.full0.numCycles.bins = 'user' + printdata(runs, system.full0.numCycles) print 'total ticks' - system.full_cpu.numCycles.bins = None - printdata(runs, system.full_cpu.numCycles) + system.full0.numCycles.bins = None + printdata(runs, system.full0.numCycles) return if command == 'packets': - packets = system.tsunami.etherdev.rxPackets + packets = system.tsunami.etherdev0.rxPackets if options.graph: graphdata(runs, options, 'packets', 'Packets', packets) else: @@ -498,12 +501,12 @@ def commands(options, command, args): return if command == 'ppt' or command == 'tpp': - ppt = system.tsunami.etherdev.rxPackets / sim_ticks + ppt = system.tsunami.etherdev0.rxPackets / sim_ticks printdata(runs, ppt, command == 'tpp') return if command == 'pps': - pps = system.tsunami.etherdev.rxPackets / sim_seconds + pps = system.tsunami.etherdev0.rxPackets / sim_seconds if options.graph: graphdata(runs, options, 'pps', 'Packets/s', pps) else: @@ -511,7 +514,7 @@ def commands(options, command, args): return if command == 'bpt' or command == 'tpb': - bytes = system.tsunami.etherdev.rxBytes + system.tsunami.etherdev.txBytes + bytes = system.tsunami.etherdev0.rxBytes + system.tsunami.etherdev0.txBytes bpt = bytes / sim_ticks * 8 if options.graph: graphdata(runs, options, 'bpt', 'bps / Hz', bpt) @@ -520,7 +523,7 @@ def commands(options, command, args): return if command == 'bptb' or command == 'tpbb': - bytes = system.tsunami.etherdev.rxBytes + system.tsunami.etherdev.txBytes + bytes = system.tsunami.etherdev0.rxBytes + system.tsunami.etherdev0.txBytes print 'kernel stats' bytes.bins = 'kernel' @@ -537,7 +540,7 @@ def commands(options, command, args): return if command == 'bytes': - stat = system.tsunami.etherdev.rxBytes + system.tsunami.etherdev.txBytes + stat = system.tsunami.etherdev0.rxBytes + system.tsunami.etherdev0.txBytes if options.binned: print '%s kernel stats' % stat.name @@ -559,7 +562,7 @@ def commands(options, command, args): return if command == 'rxbps': - gbps = system.tsunami.etherdev.rxBandwidth / 1e9 + gbps = system.tsunami.etherdev0.rxBandwidth / 1e9 if options.graph: graphdata(runs, options, 'rxbps', 'Bandwidth (Gbps)', gbps) else: @@ -567,7 +570,7 @@ def commands(options, command, args): return if command == 'txbps': - gbps = system.tsunami.etherdev.txBandwidth / 1e9 + gbps = system.tsunami.etherdev0.txBandwidth / 1e9 if options.graph: graphdata(runs, options, 'txbps', 'Bandwidth (Gbps)', gbps) else: @@ -575,8 +578,8 @@ def commands(options, command, args): return if command == 'bps': - rxbps = system.tsunami.etherdev.rxBandwidth - txbps = system.tsunami.etherdev.txBandwidth + rxbps = system.tsunami.etherdev0.rxBandwidth + txbps = system.tsunami.etherdev0.txBandwidth gbps = (rxbps + txbps) / 1e9 if options.graph: graphdata(runs, options, 'bps', 'Bandwidth (Gbps)', gbps) @@ -585,7 +588,7 @@ def commands(options, command, args): return if command == 'misses': - stat = system.L2.overall_mshr_misses + stat = system.l2.overall_mshr_misses if options.binned: print '%s kernel stats' % stat.name stat.bins = 'kernel' @@ -609,9 +612,9 @@ def commands(options, command, args): return if command == 'mpkb': - misses = system.L2.overall_mshr_misses - rxbytes = system.tsunami.etherdev.rxBytes - txbytes = system.tsunami.etherdev.txBytes + misses = system.l2.overall_mshr_misses + rxbytes = system.tsunami.etherdev0.rxBytes + txbytes = system.tsunami.etherdev0.txBytes if options.binned: print 'mpkb kernel stats' @@ -640,9 +643,9 @@ def commands(options, command, args): return if command == 'ipkb': - interrupts = system.full_cpu.kern.faults[4] - rxbytes = system.tsunami.etherdev.rxBytes - txbytes = system.tsunami.etherdev.txBytes + interrupts = system.full0.kern.faults[4] + rxbytes = system.tsunami.etherdev0.rxBytes + txbytes = system.tsunami.etherdev0.txBytes if options.binned: print 'ipkb kernel stats' @@ -671,19 +674,19 @@ def commands(options, command, args): return if command == 'execute': - printdata(runs, system.full_cpu.ISSUE__count) + printdata(runs, system.full0.ISSUE__count) return if command == 'commit': - printdata(runs, system.full_cpu.COM__count) + printdata(runs, system.full0.COM__count) return if command == 'fetch': - printdata(runs, system.full_cpu.FETCH__count) + printdata(runs, system.full0.FETCH__count) return if command == 'bpp': - ed = system.tsunami.etherdev + ed = system.tsunami.etherdev0 bpp = (ed.rxBytes + ed.txBytes) / (ed.rxPackets + ed.txPackets) if options.graph: graphdata(runs, options, 'bpp', 'Bytes / Packet', bpp) @@ -692,7 +695,7 @@ def commands(options, command, args): return if command == 'rxbpp': - bpp = system.tsunami.etherdev.rxBytes / system.tsunami.etherdev.rxPackets + bpp = system.tsunami.etherdev0.rxBytes / system.tsunami.etherdev0.rxPackets if options.graph: graphdata(runs, options, 'rxbpp', 'Receive Bytes / Packet', bpp) else: @@ -700,7 +703,7 @@ def commands(options, command, args): return if command == 'txbpp': - bpp = system.tsunami.etherdev.txBytes / system.tsunami.etherdev.txPackets + bpp = system.tsunami.etherdev0.txBytes / system.tsunami.etherdev0.txPackets if options.graph: graphdata(runs, options, 'txbpp', 'Transmit Bytes / Packet', bpp) else: @@ -708,7 +711,7 @@ def commands(options, command, args): return if command == 'rtp': - rtp = system.tsunami.etherdev.rxPackets / system.tsunami.etherdev.txPackets + rtp = system.tsunami.etherdev0.rxPackets / system.tsunami.etherdev0.txPackets if options.graph: graphdata(runs, options, 'rtp', 'rxPackets / txPackets', rtp) else: @@ -716,7 +719,7 @@ def commands(options, command, args): return if command == 'rtb': - rtb = system.tsunami.etherdev.rxBytes / system.tsunami.etherdev.txBytes + rtb = system.tsunami.etherdev0.rxBytes / system.tsunami.etherdev0.txBytes if options.graph: graphdata(runs, options, 'rtb', 'rxBytes / txBytes', rtb) else: diff --git a/util/tracediff b/util/tracediff index 402abbe55..87210f1ed 100755 --- a/util/tracediff +++ b/util/tracediff @@ -51,12 +51,15 @@ $sim2 = shift; # be given to both invocations $simargs = '"' . join('" "', @ARGV) . '"'; -# Redirect config output to cout so that gets diffed too (in case -# that's the source of the problem). -$simargs .= " --root:config_output_file=cout"; +# Run individual invocations in separate dirs so output and intermediate +# files (particularly config.py and config.ini) don't conflict. +$dir1 = "tracediff-$$-1"; +$dir2 = "tracediff-$$-2"; +mkdir($dir1) or die "Can't create dir $dir1\n"; +mkdir($dir2) or die "Can't create dir $dir2\n"; -$cmd1 = "$sim1 $simargs --stats:text_file=tracediff-$$-1.stats 2>&1 |"; -$cmd2 = "$sim2 $simargs --stats:text_file=tracediff-$$-2.stats 2>&1 |"; +$cmd1 = "$sim1 $simargs -d $dir1 2>&1 |"; +$cmd2 = "$sim2 $simargs -d $dir2 2>&1 |"; # This only works if you have rundiff in your path. I just edit it # with an explicit path if necessary. |