Added support for basic block detection