core: add DEBUG feature