The simplescalar tool set, version 2.0(7)
时间:2025-03-09
时间:2025-03-09
under Contract DABT63-95-C-0127 and ARPA order no. D346. The current support for this work comes from a variety of sources, all of to which we are indebted.
patternhistory
2-bit
predictors
branchbranchprediction
Figure 6. 2-level adaptive predictor structure
-bpred:ras <size>
set the return stack size to <size> (0 entriesmeans to return stack). The default is 8.entries.
-bpred:btb <sets> <assoc>
con gure the BTB to have <sets> sets and an
associativity of <assoc>. The defaults are512 sets and an associativity of 4.
-bpred:spec_update <stage>
allow speculative updates of the branch pre-dictor in the decode or writeback stages(<stage> = [ID|WB]). The default is non-speculative updates in the commit stage.Visualization-pcstat <stat>
record statistic <stat> by text address; described in Section4.3.
-ptrace < le> <range>
pipeline tracing, described in Section5.
4.5 Simulator code le descriptions
The following list describes the functionality of the C code les in thesimplesim-2.0/ directory, which are used by allof the simulators. bitmap.h: Contains support macros for performing bit-map manipulation. bpred.[c,h]: Handles the creation, functionality, and
updates of the branch predictors.bpred_create(), bpred_lookup(), andbpred_update() are the keyinterface functions.
cache.[c,h]: Contains general functions to support
multiple cache types (e.g., TLBs, instruction and data
caches). Uses a linked-list for tag comparisons in caches oflow associativity (less than or equal to four), and a hashtable for tag comparisons in higher-associativity caches.The important interfaces arecache_create(),cache_access(),cache_probe(),
cache_flush(), andcache_flush_addr().
dlite.[c,h]: Contains the code for DLite!, the source-level target program debugger.
endian.[c,h]: De nes a few simple functions to deter-mine byte- and word-order on the host and target platforms.eval.[c,h]: Contains code to evaluate expressions, usedin DLite!.
eventq.[c,h]: De nes functions and macros to handleordered event queues (used for ordering writebacks). Theimportant interface functions areeventq_queue() andeventq_service_events().
loader.[c,h]: Loads the target program into memory,sets up the segment sizes and addresses, sets up the initialcall stack, and obtains the target program entry point. Theinterface isld_load_prog().
main.c: Performs all initialization and launches the mainsimulator function. The key functions are
sim_options(),sim_config(),sim_main(),andsim_stats().
memory.[c,h]: Contains functions for reading from,writing to, initializing, and dumping the contents of the tar-get main memory. Memory is implemented as a large atspace, each portion of which is allocated on demand.mem_access() is the important interface function.misc.[c,h]: Contains numerous useful support func-tions, such asfatal(),panic(),warn(),info(),debug(),getcore(), andelapsed_time().
options.[c,h]: Contains the SimpleScalar optionspackage code, used to process command-line argumentsand/or option speci cations from con g les. Options areregistered with an option database (see the functions calledopt_reg_*()).opt_print_help() generates a helplisting, andopt_print_options() prints the currentoptions’ state.
ptrace.[c,h]: Contains code to collect and producepipeline traces fromsim-outorder.
range.[c,h]: Holds code that interprets program rangecommands used in DLite!.
regs.[c,h]: Contains functions to initialize the register les and dump their contents.
resource.[c,h]: Contains code to manage functionalunit resources, divided up into classes. The three de nedfunctions create the resource pools and busy tables(res_create_pool()), return a resource from the spec-i ed pool if available (reg_get()), and dump the con-tents of a pool (res_dump()).
sim.h: Contains a few extern variable declarations andfunction prototypes.
stats.[c,h]: Contains routines to handle statistics mea-suring target program behavior. As with the options pack-
…… 此处隐藏:1902字,全部文档内容请下载后查看。喜欢就下载吧 ……上一篇:农历闰月的推算
下一篇:职业技能鉴定试题(数控车)