core: fix missing blocks in loop region