split into util/core
x