1 / 13

Very Very Brief Introduction to PTLsim

Very Very Brief Introduction to PTLsim. 2008.5.19. PTLsim. 特点 x86_64 Architecture Cycle Accurate Full System simulator. Language. 使用 C++ 编写 但只使用了 C++ 的部分特性:模板, STL (自己实现的,没有用 C++ 提供的 STL 库) 号称可以轻松添加各种模型,只需在 PTLsim 里注册一个 C++ 类并重新编译

todd-riggs
Télécharger la présentation

Very Very Brief Introduction to PTLsim

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Very Very Brief Introduction to PTLsim 2008.5.19

  2. PTLsim • 特点 • x86_64 Architecture • Cycle Accurate • Full System simulator

  3. Language • 使用C++编写 • 但只使用了C++的部分特性:模板,STL(自己实现的,没有用C++提供的STL库) • 号称可以轻松添加各种模型,只需在PTLsim里注册一个C++类并重新编译 • 已经实现的模型包括superscalar out of order core, SMT version of ooo core, in-order sequential core

  4. Simulation • 分成两种: • Userspace version:单线程 • Full system version:cycle accurate,SMT(Simultaneously Multi-thread)模型,支持多处理器

  5. Native Mode • 将二进制代码直接放到本地机器上运行 • 模拟速度快 • Trace Driven? • 号称精度很高,将AMD64的硬件Performance Counter得到的数据跟PTLsim模拟结果比对,误差在5%以内

  6. Xen • Linux下的虚拟机 • 结构复杂,尚未清楚其用法 • 但是Xen本身就支持虚拟多处理器(Virtual CPU),怀疑PTLsim仅仅是对Xen进行扩展 • 确实可以在Xen上跑一个操作系统,但是该操作系统需要重新编译(没法跑windows),因为毕竟Xen虚拟的x86和真正的x86还是有差别

  7. SMT • Simultaneous multithreading is a processor design that combines hardware multithreading with superscalar processor technology to allow multiple threads to issue instructions each cycle • 同时多线程:结合硬件多线程和超标量处理器技术,使得每个周期能有多个线程发射指令

  8. Compilation • 使用最新版本的GCC 4.3在编译的时候需要对源码的某些地方进行修改(GCC 4.3的语法规则又变了) • 其他遇到的问题还有链接的问题,可以通过修改Makefile文件解决 • 最后生成一个ptlsim和ptlstats可执行文件

  9. Run • ./ptlsim打印出一堆参数信息 • 但是使用它运行二进制可执行文件却没有输出 • ./ptlsim /bin/ls • 没有输出 • 需要看User Manual

  10. Temperature and Power • 暂时没搜到基于PTLsim的温度和功耗模型的信息 • 作者认为他们接下去的工作是 • 1.建立一个详细的多处理器互联模型(使用MOESI Cache一致性协议) • 2.扩展PTLsim使之支持Xen的HVM(Hardware Accelerated Virtualization),可以使得任意的操作系统都能在上面跑(难道他们想在上面跑windows vista???)

  11. Problems • 仍需要进一步的调研 • Ptlsim的程序虽然编译好了但是不知道怎么用,需要看user manual • Xen还没有跑起来,估计要搭好环境会比较麻烦 • X86的架构跟体系结构上学到的知识还是有很多不同,看论文时许多术语看得头疼

  12. Well Known x86 Simulators • 已知的一些x86模拟器 • Bochs:开源,速度慢(约5-10Mhz) • QEMU:支持多种体系结构 • Simics:非开源,支持多种体系结构 • 均不支持对x86指令以下的级别进行建模 • MYSim:基于SESC和Bochs,似乎还没做出来

  13. Up to date? • http://hpc.cs.tsinghua.edu.cn/wwwarch/tools.html • 包括很多模拟器,工具,benchmark

More Related