Patent ID: 9465655
Filing Date: 2016-10-11
CPC Classification: G06F,Y02D

Claim Text:
1. A method for managing threads, suitable for an electronic device, the electronic device comprising a processor and a memory, the memory comprising a plurality of threads, the threads comprising at least one registered thread and at least one unregistered thread, the method comprising: obtaining a current time and calculating a time interval between the current time and a time for the processor to wake up next time; releasing the processor until reaching the end of the time interval; when receiving a first notice signal of the processor prior to the end of the time interval, obtaining a first newest time to update the current time, logging the current time as a basis time and respectively checking whether or not the current time satisfies a plurality of predetermined time conditions of the at least one registered thread, wherein the first notice signal indicates the processor is resumed from a power-saving mode to execute the at least one unregistered thread; and when the current time satisfies the predetermined time condition of a first registered thread among the registered threads, waking up the first registered thread.