The first step will be to do a refactoring to allow us to have a list of multiple block versions per basic block. I think that I will use a linked list because it's a good fit here, since each block_t object is already heap allocated.
The second step will be to implement a matching function to look for compatible block versions.