add double buffering for the core files