performance improvements for implicit flows + more test cases