Git Product home page Git Product logo

c-strider's Introduction

c-strider

C-strider is a framework for writing C heap traversals and transformations. Writing a basic C-strider service requires implementing only four callbacks; C-strider then generates a program-specific traversal that invokes the callbacks as each heap location is visited. Critically, C-strider is type aware—it tracks types as it walks the heap, so every callback is supplied with the exact type of the associated location

See our paper for full description

Requires ocaml...tested with "The OCaml toplevel, version 4.00.1"

Files to look at first:

  1. The API header: src/cstrider_api.h ( from figure 5 of paper)
  2. Template callback functions to fill out: src/transform.c
  3. Examples of how to use: examples/*
  4. Code generator: tools/ocaml-src/tools/cstridgen.ml (the user doesn't need to edit this file, but this file is the guts of cstrider's type-based traversal generation

Known limitations:

  1. Our Cil (1.3.7) code might infinite loop with Ocaml >4.02
    • Also, Cil 1.3.7 can't handle some 64 bit stuff such as UINT64_C(0x0000000000000000)
  2. Since C-strider takes the address of struct fields to process them, it can't handle bit fields (Ex: unsigned type:4;)
  3. Does not automatically traverse static variables...you must call "visit" on them while in scope.

c-strider's People

Watchers

James Cloos 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.