Handle cycles.