use caching to reduce cpu load