add compat module
use compat.atomic in unit test