Introduction to SimpleScalar (Based on SimpleScalar Tutorial) TA: Kyung Hoon Kim CSCE614 Texas A&M University

  • View
    316

  • Download
    1

Embed Size (px)

Text of Introduction to SimpleScalar (Based on SimpleScalar Tutorial) TA: Kyung Hoon Kim CSCE614 Texas...

  • Slide 1
  • Introduction to SimpleScalar (Based on SimpleScalar Tutorial) TA: Kyung Hoon Kim CSCE614 Texas A&M University
  • Slide 2
  • Overview What is an architectural simulator a tool that reproduces the behavior of a computing device Why use a simulator Leverage a faster, more flexible software development cycle Permit more design space exploration Facilitates validation before H/W becomes available Level of abstraction is tailored by design task Possible to increase/improve system instrumentation Usually less expensive than building a real system
  • Slide 3
  • Taxonomy of Simulators A simulator is categorized along multiple dimensions scope: the scope of target system a simulator models depth: the level of details a simulator can capture input: the way to obtain instructions to drive a simulator A simulator is built by integrating components of each categorization Simplescalar is featured by the colored approaches Architectural Simulator User-level Full system FunctionalCycle-Accurate Trace-driven Execution-driven Direct-Execution Input Depth Scope
  • Slide 4
  • User-level vs System-level Simulators User-level simulators implement the microarchitecture execute a user code of a benchmark on top of a simulator ignore system calls that are serviced by a host OS run a realistic application with relative simplicity and less efforts cannot measure micro-architectural impact within that system call e.g. Simplescalar, RSIM, MINT, Asim, Zesto Full-system simulators models the entire system simulates CPU, I/O, disks, and network can boot and run operating systems capture the interactions between workloads and the entire system. e.g. GEM5, Simics from Michel Dubois, Murali Annavaram, Per Stenstrm, Parallel Computer Organization and Design, p491, Cambridge University Press
  • Slide 5
  • Functional vs. Performance Simulators Functional simulators implement the architecture perform real execution implement what programmers see(e.g. register files, ISA) decouple functional modeling from the micro-architectural modeling e.g. Sim-Fast, Sim-Cache, Sim-Bpred Cycle-accurate simulators implement the microarchitecture model system resources/internals do not implement what programmers see keep track of timing so as to provide performance results e.g. Sim-Outorder from Michel Dubois, Murali Annavaram, Per Stenstrm, Parallel Computer Organization and Design, p492, Cambridge University Press
  • Slide 6
  • Trace Driven vs. Execution Driven Simulators Trace-Driven Simulator reads a trace of the instructions captured during a previous execution Easy to implement No functional components necessary No feedback to trace (eg. mis-prediction) Execution-Driven Simulator runs the program (trace-on-the-fly) Hard to implement Advantages No need to store traces Register and memory values usually are not in trace Support mis-speculation cost modeling
  • Slide 7
  • SimpleScalar Release 3.0 SimpleScalar now executes multiple instruction sets: SimpleScalar PISA (the old "SimpleScalar ISA") and Alpha AXP. All simulators now support external I/O traces (EIO traces). Generated with a new simulator (sim-eio) Support more platforms explicit fault support And many more
  • Slide 8
  • Advantages of SimpleScalar Highly flexible functional simulator + performance simulator Portable Host: virtual target runs on most Unix-like systems Target: simulators can support multiple ISAs Extensible Source is included for compiler, libraries, simulators Easy to write simulators Performance Runs codes approaching real sizes
  • Slide 9
  • Simulator Suite Sim-FastSim-SafeSim-Profile Sim-Cache Sim-BPred Sim-Outorder -300 lines -functional -4+ MIPS -350 lines -functional w/checks -900 lines -functional -Lot of stats -< 1000 lines -functional -Cache stats -Branch stats -3900 lines -performance -OoO issue -Branch pred. -Mis-spec. -ALUs -Cache -TLB -200+ KIPS Performance Detail
  • Slide 10
  • Sim-Fast Functional simulation Optimized for speed Assumes no cache Assumes no instruction checking Does not support Dlite! Does not allow command line arguments