The flourishing Internet of Things (IoT) technologyis bringing numerous emerging concepts intoreality, among which a striking one is the smartcity [1]. With IoT-based smart cities, massive heterogeneousIoT devices run diverse advancedservices for unprecedented intelligence and efficiencyin various domains of city life [2]. Namely,smart building, intelligent transportation, ubiquitouse-healthcare, smart home, smart energy, and smartfactory are going to significantly improve the qualityof life of residents in IoT-based smart cities [3].IoT-based smart cities are characterized by alarge number of services running over massiveend IoT devices as well as applications hosted inremote servers. Note that these services, varyingfrom virtual reality to precision healthcare, fromvideo-based surveillance to water network monitoring,may have totally different quality of service(QoS) requirements. For example, virtual reality hasa very stringent limit on tolerated delay [4]. What’smore, the number of IoT devices in smart cities isexponentially growing with disparate characteristics.Stationary IoT devices, as deployed in differentgeo-locations, may be equipped with powerfulprocessors and huge storage space [5]. On thecontrary, the battery life, processing power, andstorage capacity of highly mobile IoT devices (e.g.,smart wearables [6]) may be very limited.