revamp data structures