Giter Club home page Giter Club logo

heap_history_viewer's Introduction

A Qt/OpenGL-based implementation of a heap history visualisation UI in along the lines of Gerardo Richarte's HeapDraw (for more details, check http://actes.sstic.org/SSTIC07/Rump_sessions/SSTIC07-rump-Richarte-Heap_Massaging.pdf)

The tool had been reimplemented by various people in various places a few times, usually in a hackish / nonscalable manner. zynamics used to hand source code for a JOGL-based UI out with some of our trainings, but that tool is not easily portable to modern OpenGL or 64-bit address spaces.

Other common mistakes include:

  • Not using OpenGL to render lots of rectangles.
  • Using floats or other low-precision coordinates to represent rectangle corners and hence suffering from rounding errors.
  • Not using a language that can deal with a couple million rectangles.

The codebase in this repository has the following goals:

  • Fast and scalable to 20m+ allocations. Haven't tried, but should work.
  • As precise as possible. Use precise integer arithmetic as much as possible to avoid rounding errors shifting rectangles around.
  • Useable. This will take some time.

Instructions for the moment:

  • Build using stock QtCreator.
  • You will need: libgflags-dev mesa-common-dev libqt4-opengl-dev
  • The current trunk will simply try to load /tmp/heap.json - use the enclosed json file as an example.

A million tasks are still left to do. Useful things that should be added:

  • Code to display tooltips when the mouse hovers over a block.
  • Code to highlight a block when it is clicked / selected.
  • Code to add horizontal red lines, too.
  • Code to select all blocks that are modified between two events.
  • ...

Contributions very welcome.

Basic controls:

  • CTRL + wheel: Zoom in / out
  • Click + drag: Pan diagram
  • CTRL + shift + wheel: Squash / stretch horizontally
  • shift + wheel: Squash / stretch vertically

Cheers, Halvar Flake / Thomas Dullien

heap_history_viewer's People

Contributors

thomasdullien avatar

Watchers

 avatar

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.