Giter VIP home page Giter VIP logo

shioyadan / konata Goto Github PK

View Code? Open in Web Editor NEW
367.0 12.0 32.0 1.14 MB

Konata is an instruction pipeline visualizer for Onikiri2-Kanata/Gem5-O3PipeView formats. You can download the pre-built binaries from https://github.com/shioyadan/Konata/releases

License: BSD 3-Clause "New" or "Revised" License

JavaScript 74.03% Makefile 0.30% HTML 22.40% CSS 2.78% Dockerfile 0.17% VBScript 0.08% Shell 0.14% Batchfile 0.09%

konata's Introduction

Konata

  • Konata is an instruction pipeline visualizer for Onikiri2-Kanata/Gem5-O3PipeView formats.
  • ASPLOS 2018 learning gem5 tutorial presentation is here
  • The Onikiri2-Kanata format is described in here. It can represent a more detailed pipeline behavior than Gem5-O3PipeView.

demo

Installation

There are two ways to launch Konata. If you fail to launch a pre-built binary, please try the second way.

  1. Extract an archive and launch an executable file (konata.exe or konata).
    • Pre-built binaries are available from here.
  2. Launch from this repository.
    1. Install node.js from https://nodejs.org
    2. Clone this repository.
    3. Launch install.bat (Windows) or install.sh (Linux/MacOS).
    4. Launch Konata from konata.vbs (Windows) or konata.sh (Linux/MacOS).

Usage

Basic

  1. Generate a trace log from gem5 with the O3 CPU model
    $ ./build/ARM/gem5.opt \
        --debug-flags=O3PipeView \
        --debug-start=<first tick of interest> \
        --debug-file=trace.out \
        configs/example/se.py \
        --cpu-type=detailed \
        --caches -c <path to binary> \
        -m <last cycle of interest>
    
  2. Load a generated "trace.out" to Konata
    • from a menu in a window or using drag&drop
  3. If you use O3CPUAll as well as O3PipeView as follows, Konata shows more detailed CPU log and visualizes dependency between instructions.
    --debug-flags=O3PipeView,O3CPUAll
    

Keyboard

  • mouse wheel up, key up: scroll up
  • mouse wheel down, key down: scroll down
  • ctrl + mouse wheel up, key "+", ctrl+key up: zoom in
  • ctrl + mouse wheel down, key "-", ctrl+key down: zoom out
  • ctrl + f, F3, shift+F3: find a string
  • F1, ctrl+shift+p: open a command palette

Tips

  • If you miss pipelines in a right pane, you can move to pipelines by click "Adjust position" in a right-click menu.
  • You can visually compare two traces as follows:
    1. Load two trace files
    2. Right-click and select "Synchronized school" & "Transparent mode"
    3. Right-click and select a color scheme
    4. Move to another tab and adjust a position with the transparent mode
  • If you cannot launch Konata, try to install the following runtimes (or try to install the latest Google Chrome, because it uses the same runtimes).
    sudo apt install \
        libgconf-2-4 \
        libgtk-3-0 \
        libxss1 \
        libnss3 \
        libasound2 \
        libx11-xcb1 \
        libcanberra-gtk3-module \
        libgbm-dev
    
  • In O3CPUAll mode, Konata associates each line in trace.out with each instruction by tracking [sn:<serial number>]. If you output custom log with the above serial information, Konata shows your custom log.

Development

  • Install dependent runtimes as follows or use Dockerfile included in a source tree
    # Install node.js/npm
    sudo apt install nodejs
    
    # Install electron/electron-packager
    # Since electron is huge, they are installed globally.
    npm -g install electron
    npm -g install electron-packager
    
    # Run and build
    make init   # Setup libraries
    make        # Run Konata
    make pack   # Build & pack Konata for Windows/Linux/Mac
    

License

Copyright (C) 2016-2022 Ryota Shioya [email protected]

This application is released under the 3-Clause BSD License, see LICENSE.md. This application bundles ELECTRON and many third-party packages in accordance with the licenses presented in THIRD-PARTY-LICENSES.md.

konata's People

Contributors

powerjg avatar reo-pon avatar shioyadan avatar taichi-ishitani avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

konata's Issues

gem5 retire and store completion stages

Hello,

Could you please clarify whether Konata supports displaying of retire and store completion stages like gem5 trace viewer?

At quick glance on Konata gem5 parser I see that the code is aware about "retire" and "mem_complete" stages . But I don't see these stages - no "mem_complete" for store operations and no "retire" for all operations (please see attached screenshot).

gem5 version is v22.1
Konata version is v0.39

Снимок

Please provide guide to install konata

Hi,
I have downloaded the Linux zip file. Readme says run the file named Konata, but I dont have an application that can run it. Since I am a newbie,I do not know the command to execute it in terminal.
Please tell me what command to use to run the file and install konata
Regards,
Thanks

Stages visibility with E and R commands

Hello,
Noticed that when S and E or R commands are in one cycle then it will not be visible in Konata.

E.g.

I    0    0    0
...
C    1
S    0    0    Rt
R    0    0    0
C    1

Here, Rt stage will not be displayed.
It can be OK with Retire stage, but i ran into problems with flushed instructions

In my case, it is possible to Fetch an instruction and flush it in the same cycle

...
C    1
I    0    0    0
S    0    0    F
R    0    0    1
C    1
...

So instruction will not be visible at all, only if you hover the cursor over it on the left, you can see that it actually existed and was flushed.
image

What i wanted to see here is:
image

I'm dumping stages to kanata trace "on fly" when simulator works, and I only know the moment at which the instruction enters the stage, but not when it leaves it. This forces to create some buffers for R and E stages to be printed on the next cycle, which doesn't seem to be a good option for me.

So the question is, is there a particular reason for not displaying these instructions?
And is it possible to display them? Maybe with some new option.

Konata version is v0.39

How to theme change

Hello. Could you help me? I'm newbie and don't know how to theme change. I've tried to change config.js (this.theme = "light"; ), but it does not work

Colouring based on ThreadID not working

Hello,
I noticed that when choosing to colour instructions based on ThreadID, all instructions have the same colour regardless of the thread. Moreover, when hovering to any instruction in the left pane, the TID field is always 0.

For example the following inst (sn: 5250) belongs to thread 1 as we can see from the O3CPUAll log:

5504500: global: DynInst: [sn:5250] Instruction created. Instcount for system.cpu = 33
5504500: system.cpu.fetch: [tid:1] Instruction PC (0x101ce=>0x101d0).(0=>1) created [sn:5250].
5504500: system.cpu.fetch: [tid:1] Instruction is: c_addi a5, 8

But in Konata is it displayed as if it was belonging to thread 0:

image

Let me know if I'm missing anything. Thanks!

A instruction with only one stage "fetch" will not show in the window

Hello, I found a problem that Konata will ignore the chart about an "only a fetch stage" instruction.
Is this a bug?
image

O3PipeView:fetch:199000:0x00010100:0:45:c_bnez a5, 12
O3PipeView:decode:0
O3PipeView:rename:0
O3PipeView:dispatch:0
O3PipeView:issue:0
O3PipeView:complete:0
O3PipeView:retire:0:store:0

Does W command work?

Could you help me - it seems like W command does not work, i don't see any arrows. What am I doing wrong?

//--------------------------------------
I	3	4	0
L	3	0	main_comment: test_3
S	3	0	st_3
C	5			
R	3	104	0
I	4	4	0	
L	4	0	main_comment: test_4
S	4	1	st_4
I	5	5	0	
L	5	0	main_comment: test_5
S	5	2	st_5
I	6	6	0	
L	6	0	main_comment: test_6
C	2
S	6	3	st_6
R	5	191	1
C	7
E	5	2	st_5

W	5	6	0  // arrows???

C	6

gem5 dependency arrow

Hello,

I am using the latest gem5 release (v22.1) and the latest pre-built Konata (v0.38).
I see that "View->Dependency arrow" menu option is available but it doesn't change displaying in any way.
The trace was collected with "--debug-flags=O3PipeView,O3CPUAll".

Could you please clarify what is the proper way to enable dependency arrow for gem5 trace (maybe some additional options, patches should be applied)?

Suggestion: Adding a comment to an instruction

Hi,

Like in a disassembler, we work with hundreds, thousands, even millions lines of code in a simple window. And like in main disassembler, it will be super helpful to have the possibility to annotate the code, with some kinds comments, for example in the left-panel.

This is just a suggestion. Hope it's appreciate!

P.S. : Thanks for the great work, Konata is very useful!

Suggest adding a vertical ruler when clicking some pipe stage

Hello,

This is really awesome tool, but I found a bit incovenient when I try to check how many cycles b/w one instrctuction and some distant instructions else, e.g. in below figure, the first and next retired.

Consider to add some vertical cursor(s) when clicking on a pipe stage? even 2 or more and a diff can automatically show on statusbar, somewhat like waveform tools such as synopsys VERDI. :-)

2023-04-21_10-26

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.