Giter VIP home page Giter VIP logo

hilbert_kcov's Introduction

SDL-based hilbert curve visualizer for kernel coverage data.

It looks like this:

Hilbert Curve of kernel coverage

Input is a file with lines like:

0x80124415  34
0x80124419  4
0x80194415  1
0x80194416  257

Representing the number of times each kernel address was seen. Currently all kernel addresses must be in the range 0x80000000-0xFFFFFFFF (the default for 32-bit Windows systems).

Because the hilbert curve for a 2GB range of memory is quite large, the viewer just shows a view into it, initially centered on a random address. The colors (greyscale, going from black to white), represent how rare a given address is, with white being the most rare. Black means the address was never seen (yes, this is inconsistent, but worked better than having the view be mostly white all the time). Specifically the color is just 255 * (1 - frequency).

Inside the viewer, you can use the following keyboard commands:

  • Arrow keys - pan around the viewport
  • q - quit the viewer
  • r - recenter the view on a random (nonzero count) address

You can click on any part of the viewport to display the actual address and count.

Building

On OS X, assuming you have SDL 1.2 installed to /Library/Frameworks/ you should be able to just type make.

On Linux it should compile with:

g++ hilbert.cpp -o hilbert -lSDL -lbsd

On Windows, you're on your own.

Bugs

The screen starts off blank until you use the arrow keys or press "r" to move. I have no idea why and very little interest in figuring it out.

hilbert_kcov's People

Contributors

moyix avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

chubbymaggie

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.