Efficiently Measuring the Cognitive Ability of LLMs: An Adaptive Testing Perspective