add support for @reverse in framing algorithm