This paper provides an overview of cognitive radio (CR) networks, with focus on the recent advances in resource allocation techniques and the CR networks architectural design. The contribution of this work is threefold. First, a systematic way to study the resource allocation problem is presented; various design approaches are introduced, such as signal-to-interference-and-noise ratio (SINR) or transmission power-based, and centralized or distributed methods. Second, CR optimization methods are presented, accompanied by a comprehensive study of the resource allocation problem formulations. Furthermore, quality of service criteria of the physical or/and the medium access control layers are investigated. Third, challenges in spectrum assignment are discussed, focusing on dynamic spectrum allocation, spectrum aggregation and frequency mobility. Such approaches constitute an emerging trend in efficient spectrum sharing and affect the performance of resource allocation techniques. The open issues for future research in this area are finally discussed, including adaptability-reconfigurability, dual accessibility, and energy efficiency.