• 5星
4.5MB GJZGRB 2021-04-13 10:37:48
• 5星
29KB m0_52957036 2020-04-29 07:50:59
• 5星
47KB m0_52957036 2020-04-29 07:50:55
• 一、详细释义：adj.(人)懈怠的，懒惰的例句：An idle person is the devil’s cushion. ——Robert Burton懒惰的人是魔鬼的安慰。——伯顿例句：Idle folks lack no excuses.懒汉借口多。(机器、工厂等)闲置的例句：...

一、详细释义：
(人)懈怠的，懒惰的
例句：
An idle person is the devil’s cushion. ——Robert Burton
懒惰的人是魔鬼的安慰。——伯顿
例句：
Idle folks lack no excuses.
懒汉借口多。
(机器、工厂等)闲置的
例句：
Empiri-cally, the distinction between active and idle balances is elusive.
在实际生活中，活动余额和闲置余额的区别是难以捉摸的。
例句：
The factory machines lay idle during the workers' strike.
在工人罢工期间, 工厂的机器都闲置着. 。
(人)没有工作的，闲散的
例句：
If you make idle, dissipated people your companions, you're sure to go the bad.
假若你结交上闲散、挥霍的人，你一定会堕落。
例句：
No matter how rich, one shall not live an idle life.
不管一个人多么富有，都不应该过着闲散的生活 。
漫无目的的，无效的，无用的
例句：
The idle, useless man, no matter to what extent his life may be prolonged, merely vegetates.
懒惰无用的人，不管寿命多长，也不过是饱食终日，虚度一生。
例句：
This is far from an idle suggestion.
这决不是无用的提议。
空闲的
例句：
To be idle sometimes is agreeable, but to be idle all the time might become monotonous.
一段时间空闲是令人愉快的，整日无所事事可能就单调乏味了。
例句：
After years of teaching, I have many memories to dwell on in idle moments.
过了许多年的教学生涯，我空闲时缅怀的往事很多。
v.
混时间，闲荡，无所事事 [I,T]
例句：
He spends his time running idle.
他整天无所事事。
例句：
I will rather work than remain idle .
我宁可参加工作不可终日无所事事。
(发动机)空转，挂空档，未熄火 [I]
例句：
The engine is running idle.
发动机在空转着。
例句：
When making the sewing machine run idle, remove the bobbin case and the bobbin since there is the possibility that thread is entangled in the hook.
缝纫机空转时，有可能机线空绕而卷绕不到旋锁上，因此请卸下梭壳和梭芯。
(尤指暂时地)关闭工厂，使(工人)闲着 [T]
例句：
These machines have lain idle since the factory closed.
这些机器自工厂关闭以来一直闲置着。
例句：
I have seen the closed factories and the stalled assembly lines of Anderson, Indiana and South Gate, California, and I have seen too many, far too many idle men and women desperate to work.
我看到了印第安纳州安德森和加利福尼亚州南盖特关闭的工厂和停工的生产线，我看到太多太多的人渴望工作。
二、词义辨析：
idle,lazy
这两个形容词均有“闲散，懒惰”之意。
idle通常指不忙，无事可干，一般不含应责备之意。
lazy指好逸恶劳，贪闲偷懒，或不愿学习或工作等，常含应受责备之意。
三、相关短语：
idle talk
n. 闲谈
idle pulley
空转轮
idle wheel
空转轮
四、参考例句：
Idle folks lack no excuses.
懒汉借口多。
不要虚度光阴。
Don't idle away your precious time.
不要把大好时光浪费掉。
I hate you to idle about.
我不喜欢你游手好闲。
I will rather work than remain idle .
我宁可参加工作不可终日无所事事。
He often spent time in idle dalliance.
他经常浪荡地消磨时间。
An idle soul shall suffer hunger.
懒惰之人必受饥饿之苦。
This is far from an idle suggestion.
这决不是无用的提议。
Many elderly people live an idle life.
许多老年人过着悠闲的生活。
Many people were idle during the depression. .
在经济不景气时期，很多人都无事可做。

展开全文
weixin_35615322 2021-01-17 17:54:10
• 一、生活有时会逼迫你，不得不交出权力，不得不放走机遇，甚至不得不抛下爱情。...Sometimes life forces you to surrender power, to let go of opportunities, and even to abandon love. You c...

一、生活有时会逼迫你，不得不交出权力，不得不放走机遇，甚至不得不抛下爱情。你不可能什么都得到，生活中应该学会放弃。放弃会使你显得豁达豪爽。放弃会使你冷静主动，放弃会让你变得更聪明和更有气力。Sometimes life forces you to surrender power, to let go of opportunities, and even to abandon love. You can't get everything. You should learn to give up in life. Giving up will make you seem open-minded and forthright. Giving up will make you calm and active. Giving up will make you smarter and more powerful.
二、我们都会在生活中跌跌撞撞，这就是为什么有人牵你的手的时候，会让你这么安心。从遇见你的那一天起，我所走的每一步，都是为了接近你。你之所以活得累，在于你只有心理上的不断自责，没有行动上的立即改变。, we all stumble in our lives. That's why it reassures you when someone holds your hand. From the day I met you, every step I took was to get close to you. The reason why you are tired of living is that you have to constantly blame yourself psychologically, without immediate change in action.

三、总是会有那么一个人，每天都会想起你，总是会有那么一个人，会像爱自己一样爱你。人的一生的灵魂伴侣，就是那个你在他面前，他可以做个最真实自己的人，人生都在找那个另一半。will always have such a person, think of you every day, there will always be such a person, will love you as yourself. The soul mate of a person's life is the one you are in front of, he can be the most real person of his own, life is looking for the other half.
四、如果有一天，你找不到我了。千万不要难过，不是我不爱你了。也不是你错过我了，而是我终于有了勇气离开。但请你记得，在这之前，我真的有傻傻的等过。If one day, you can't find me. Don't be sad, it's not that I don't love you anymore. Not that you missed me, but that I finally had the courage to leave. But please remember, before that, I really had a silly wait.

五、 两个人一起久了，女的会越来越爱男的，男的越来越随便。男的会说女老是胡思乱想，女的就说男已经变了不像以前那么宠她……其实大家都没变，只是时间变了，因为彼此关系变亲密了，习惯对方，所以不会再像热恋那样，女的会胡想，无论如何请不要对爱情偷懒，否则只有平淡。然后矛盾争吵再到分手。two people together for a long time, women will love men more and more, men more and more casual. Men will say that women are always fantastic, women will say that men have changed not as spoiled her as before…… In fact, everyone has not changed, but the time has changed, because the relationship between each other has become intimate, accustomed to each other, so will not be as passionate as love, women will dream, no matter what, please don't be lazy about love, otherwise only plain. Then they argue and break up.
六、只要你的心是晴的，人生就没有雨天。就像好事情总是发生在那些微笑着的人身上。调整心情，保持微笑。瑞典有一句谚语：“无论你转身多少次，你的屁股还是在你后面。”是什么意思呢？就是无论你怎么做，都会有人说你不对。若能明白这一点，听到跟自己相反的声音，不要让沮丧、恼怒左右你的心情，而应觉得这很正常。反而，如果没有这些，才不正常。As long as your heart is clear, there will be no rain in life. It's like good things always happen to those who are smiling. Adjust your mood and keep smiling. Sweden has a proverb: "No matter how many times you turn around, your ass is still behind you." What does that mean? No matter what you do, someone will say you're wrong. If you understand this, don't let frustration and anger control your mood when you hear the opposite voice from yourself, but feel that it's normal. On the contrary, it would be abnormal if there were no such things.

七、有些伤痕，划在手上，愈合后就成了往事；有些伤痕，划在心上，那怕划得很轻，也会留驻于心；有些人，近在咫尺，却是一生无缘。 感情这个词真的是很吸引人的吧，毕竟我也曾不甘一切为它潦倒，错综复杂的过程让人说不清也道不明，番番纠缠离恨，最后啊，被现实打败，也不过成了一幕曲折陈旧的故事，听了心酸看了泪流，久了也会乏味，就好比我，终于被磨成了无喜无悲之人。Some scars, scratched on the hand, heal and become the past; some scars, scratched on the heart, even if very light, will stay in the heart; some people, close to each other, but not for a lifetime. Emotion is really a very attractive word, after all, I have been unwilling to fall for it all. The complicated process makes people unclear and unclear, entangled with each other and hatred. Finally, being defeated by the reality has become a tortuous and old story. After listening to the sad tears, it will be dull for a long time, just like me, it has finally been worn into a person without joy or sorrow.
八、知世故而不世故，才是最善良的成熟。愿你趟过世俗浑水，仍能不沾染那一身的世故。说话聊天游戏相伴，是人与人之间拉近距离，获得信任的最好方法。平和是待人处事的一种态度，也是做人酌一种美德。平和既是一种修养，又是一种工作方法。平和的人，从不被忙碌所萦绕，闲时吃紧，忙里悠闲。待人不严，教人勿高。宽严得宜，分寸得体。身心自在，能享受生活之乐趣。平和的人生，是和谐的人生，健康的人生。knows the world but not the world, which is the most kind maturity. I hope you can go through muddy water and still not be contaminated with the worldly wisdom of that person. Speaking and chatting games are the best way to get close and trust between people. Peace is not only an attitude towards people, but also a virtue for people. Peace is not only a kind of self-cultivation, but also a way of working. Peaceful people are never haunted by busyness. They are busy when they are idle. Be strict with others and teach others not to be tall. Be lenient, strict and appropriate. Physical and mental comfort, can enjoy the pleasure of life. A peaceful life is a harmonious life and a healthy life.

九、生气，就是拿别人的过错来惩罚自己。原谅别人，就是善待自己。一个人的努力，永远也没办法决定两个人的关系。不是你的枕边人，也做不成你的心头爱。三餐，四季，不必太匆忙，毕竟我有一生的时间要和你浪费。's anger is to punish oneself with the fault of others. To forgive others is to be kind to oneself. One person's efforts can never determine the relationship between two people. Not your pillow person, also can not do your heart love. Three meals, four seasons, don't rush, after all, I have a lifetime to waste with you. The appearance of some people in
十、生命中有的人的出现，只是刹那间的一次掠影，又何必去挽留？不如放手！何必将其紧紧锁于回忆的长河里，就当是朦胧的梦一场！总有一场雨，让你猝不及防，狼狈不堪。总有一个人，让你不知所措，遍体鳞伤。我们认识到了岁月的残酷，接受了时光的流逝，却仍对过去无法释怀。's life is just a glimpse of the moment. Why should we keep it? Better let go! Why should it be locked tightly in the long river of memories, it should be a hazy dream! There will always be a rain, so that you can't be caught off guard, embarrassed. There will always be someone who makes you feel overwhelmed and bruised. We recognize the cruelty of time, accept the passage of time, but still can not let go of the past.

十一、看过流星飞驰而过，天空中有过它的痕迹，隐隐的在作响，给予此时一个美好的期望。从此出发，永不言弃，坚持下去，一直以来都属于不可被磨灭的信念和原则。当每次学着放下的时候，发现它欺骗了你，但其实并没有欺骗，而是故作谎言般的理由，让自己相信那便是真实的。has seen meteors flying by, there have been traces of it in the sky, faintly sounding, giving a good expectation at this time. From then on, never give up and stick to it. It has always been an indelible belief and principle. Every time I learn to put it down, I find that it deceives you, but in fact it does not deceive, but pretends to be a lie, so that I can believe that it is true. < br/>
十二、不论你愿不愿意承认，一生爱过的人，大部分都会从陌生变得熟悉、又再从熟悉变得陌生，渐渐的，打动我们的不再是那句我爱你，而是一句我陪你。爱情不是终点，陪伴才是归宿。Whether you want to admit it or not, most of the people you have loved in your life will change from strangeness to familiarity, and then from familiarity to strangeness. Gradually, what touches us is not that I love you, but that I accompany you. Love is not the end, companionship is the end.

十三、别把我的忍让当成应该。 我不怕你什么，不欠你什么，不图你什么，我只是不想计较太多，活得太累。一次次的让步，是我大度； 一次次的被让，是你贪图。我不花你一分一毫，不用你一针一线、请你别蹬鼻子上脸，把自己看得大于天。don't take my tolerance for granted. I'm not afraid of what you do, what I owe you, what I don't want you to do. I just don't want to worry too much and live too tired. One concession after another is my magnanimity; one concession after another is your greed. I don't need you for a penny. I don't need you for a thread. Please don't push your nose on your face and see yourself as bigger than the sky. The difference between
十四、 爱和喜欢的区别很简单，如果你爱花，你会给它浇水，喜欢则会摘下它。同理：爱一个人就会悉心呵护她，喜欢则想要不择手段占有她。重新面临当初的选择，重新与酸涩发胀的年少岁月对峙。love and like is very simple. If you love flowers, you will water them and pick them if you like them. Similarly: If you love someone, you will take good care of her. If you like her, you want to possess her by any means. Re-face the original choice, and re-confront the sour and bloated youth. The choice

十五、做与不做的选择，决定了人生的方向；人生就像是一张不能涂改的答卷，上面布满了选择题，也许你选择的这个答案会让你前途无限光明；也许你选择的这个答案也可能会让你走向深渊，使你再想回到原点，却发现自己已经回不去了。makes or does not make determines the direction of life; life is like an irrevocable answer sheet, full of choice questions, maybe the answer you choose will make your future infinitely bright; maybe the answer you choose will also make you go to the abyss, make you want to return to the origin, but find that you have already. I can't go back. There are two things in
十六、这世上有两样东西是别人抢不走的，一是藏在心中的梦想，二是读进大脑里的书，年轻时吃读书的苦，不算苦，那是财富，得有那么一件事，你热爱，你坚持，你的人生有奔头，生活因此而紧凑。that people can't take away. One is the dream hidden in their hearts, the other is the book read into their brains. When they are young, they suffer from reading, not suffering. That's wealth. There must be one thing. You love, you insist, your life has a rush, so life is compact.

十七、乐观是失意后的坦然，乐观是平淡中的自信，乐观是挫折后的不屈，乐观是困苦艰难中的从容。谁拥有乐观，谁就拥有了透视人生的眼睛。谁拥有乐观，谁就拥有了力量。谁拥有乐观，谁就拥有了希望的渡船，谁拥有乐观，谁就拥有艰难中敢于拼搏的精神，只要活着就有力量，建造自己辉煌的明天！optimism is calm after disappointment, optimism is self-confidence in plain, optimism is indomitable after setbacks, optimism is calm in hardship. Who has optimism, who has the perspective of life eyes. Who has optimism, who has strength. Who has optimism, who has the ferry of hope, who has optimism, who has the spirit of daring to struggle in hardship, as long as you live, you have the strength to build your own brilliant tomorrow!
十八、当然，普通并不等于庸俗。他也许一辈子就是个普通人，但他要做一个不平庸的人。在许许多多平平常常的事情中，应该表现出不平常的看法和做法来。 当你毫无保留地信任一个人，最终只会有这两种结果，不是生命中的那个人，就是生命中的一堂课。, of course, is not vulgar. He may be an ordinary person all his life, but he should be an unequal person. In many ordinary things, we should show unusual views and practices. When you trust a person unreservedly, there will only be two results in the end, either the person in your life or a lesson in your life.

展开全文
weixin_33680447 2021-01-17 17:54:11
• I'm running into a bit of a problem. What I'm doing: I've got a ListView which has got some images in ... To make the scrolling smoother I've disabled the images to show up when scrolling. Now there s...


I'm running into a bit of a problem. What I'm doing: I've got a ListView which has got some images in it. To make the scrolling smoother I've disabled the images to show up when scrolling. Now there seems to be a bug in Android which sometimes causes the scroll state to not change back from SCROLL_STATE_FLING back to SCROLL_STATE_IDLE, which causes my images to not show up again.
My first thought was to set an onTouchListener and check when I get ACTION_UP, but that doesn't help because the SCROLL_STATE_FLING state is obviously being set after that. So now I've thought I could start a timer when the SCROLL_STATE_FLING state is being set and check after some time if the state is still in fling mode and then invalidate my view. But I don't think that's a very good solution.
Does anyone have a better idea on how I could do that? I've seen this reply but I need a solution for API level < 9 (plus it also sometimes happen when it's not overscrolling)
Here's my code for that:
mList.setOnScrollListener(new OnScrollListener() {
@Override
public void onScrollStateChanged(AbsListView view, int scrollState) {
Log.i(this, "scrollStateChanged" + scrollState);
if (scrollState == SCROLL_STATE_IDLE) {
mList.invalidateViews();
}
}
@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount) {
}
});
Thanks,
Maria
解决方案
I had the same problem, so my solution was to just detect if the scrollview position has reached the last page and in that case always load the images regardless of the scroll state (since the problem seems to always occur when the user flings to the end of the listview). So modifying your code you would have:
mList.setOnScrollListener(new OnScrollListener() {
@Override
public void onScrollStateChanged(AbsListView view, int scrollState) {
Log.i(this, "scrollStateChanged" + scrollState);
int first = view.getFirstVisiblePosition();
int count = view.getChildCount();
if (scrollState == SCROLL_STATE_IDLE || (first + count > mListAdapter.getCount()) ) {
mList.invalidateViews();
}
}
@Override
public void onScroll(AbsListView view, int firstVisibleItem, int visibleItemCount, int totalItemCount) {
}
});

展开全文
weixin_42512903 2021-07-19 19:01:31
• ## [power]一 Idle management retention

讲解ARM当前idle management的来龙去脉。
Many ARM systems are mobile devices and powered by batteries. In such systems, optimization of power use, and total energy use, is a key design constraint. Programmers often spend significant amounts of time trying to save battery life in such systems.
Power-saving can also be of concern even in systems that do not use batteries. For example, you might want to minimize energy use for reduction of electricity costs to the consumer, for environmental reasons, or to minimize the heat that the device generates.
Built into ARM cores are many hardware design methods aimed at reducing power use.
Energy use can be divided into two components:
static power：Static power consumption, also often called leakage, occurs whenever the core logic or RAM blocks have power applied to them. In general terms, the leakage currents are proportional to the total silicon area, meaning that the bigger the chip, the higher the leakage. The proportion of power consumption from leakage gets significantly higher as you move to smaller fabrication geometries.dynamic power：Dynamic power consumption occurs because of transistor switching and is a function of the core clock speed and the numbers of transistors that change state per cycle. Clearly, higher clock speeds and more complex cores consume more power.
所以对于power的计算存在静态功耗和动态功耗的差异。整体的系统功耗包括静态功耗和动态功耗。通过上面的理解如下：
静态功耗是由于core logic/RAM blocks还供着点导致的，比如说在系统suspend的时候，基本耗电就是静态功耗了。以CPU core为例子，当CPU运行在不同的频率点的时候，其本身带来的静态功耗也是随着CPU频率变大而变大的，但是没有CPU频率升高带来的动态功耗增加的快和大动态功耗一般是core 时钟频率变化和晶体管状态发生了变化导致的。比如我们常说CPU频率很高，功耗也很高，很多时候就是特指其动态功耗很高。当前在kernel5.4 EAS中只计算了动态功耗。
Power management-aware operating systems dynamically change the power states of cores, balancing the available compute capacity to the current workload, while attempting to use the minimum amount of power. Some of these techniques dynamically switch cores on and off, or place them into quiescent states, where they no longer perform computation. This means that they consume very little power. The main examples of these techniques are:
Idle managementDynamic voltage and frequency scaling
When a core is idle, the Operating System Power Management (OSPM) transitions it into a low-power state. Typically, a choice of states is available, with different entry and exit latencies, and different levels of power consumption, associated with each state. The state that is used typically depends on how quickly the core is required again. The power states that can be used at any one time might also depend on the activity of other components in an SoC, beside the cores. Each state is defined by the set of components that are clock-gated or power-gated when the state is entered.
The time required to move from a low-power state to a running state, known as the wakeup latency, is longer in deeper states. Although idle power management is driven by thread behavior on a core, the OSPM can place the platform into states that affect many other components beyond the core itself. If the last core in a cluster becomes idle, the OSPM can target power states that affect the whole cluster. Equally, if the last core in an SoC becomes idle, the OSPM can target power states that affect the whole SoC. The choice is also driven by the use of other components in the system. A typical example is placing memory in self-refresh when all cores, and any other bus masters, are idle.
The OSPM has to provide the necessary power management software infrastructure to determine the correct choice of state. In idle management, when a core or cluster has been placed into a low-power state, it can be reactivated at any time by a core wakeup event. That is, an event that can wake up a core from a low-power state, such as an interrupt. No explicit command is required by the OSPM to bring the core or cluster back into operation. The OSPM considers the affected core or cores to be available at all times even if they are currently in a low-power state. 上面的意思大致如下：
Idle management有几种可选的power状态进入和退出，每种power state的进入和退出时延都是不相同的。都会对性能有影响。Power state越深，即save power越多，时延越大。对于CPU来说，每个core的单独管理自己的power state，当所有的core变为idle的话，那么这个cluster都会变成idle state。最终影响整个SoC。也就是说，系统的省电多少都是一个level一个level层层推进的。最终达到最省电level。那么如何才能进入到不同的省电level呢？需要power management software来来检测系统行为进入决策进入哪个power state。
Power and clocking
One way that can reduce energy use is to remove power, which removes both dynamic and static currents (sometimes called power-gating), or to stop the clock of the core which removes dynamic power consumption only and can be referred to as clock-gating. ARM cores typically support several levels of power management, as follows:
StandbyRetentionPower downDormant modeHotplug
For certain operations, there is a requirement to save and restore the state before and after removing power. Both the time taken to do the save and restore, and the power consumed by this extra work can be an important factor in software selection of the appropriate power management activity. 对于某些power state，需要保存进入这个level的系统状态，当退出这个level时候，就需要恢复当时的系统状态。
The SoC device that includes the core can have additional low-power states, with names such as STOP and Deep sleep. These refer to the ability for the hardware Phase Locked Loop (PLL) and voltage regulators to be controlled by power management software.
Standby
In the standby mode of operation, the core is left powered-up, but most of its clocks are stopped, or clock-gated. This means that almost all parts of the core are in a static state and the only power drawn is because of leakage currents and the clocking of the small amount of logic that looks out for the wake-up condition.
This mode is entered using either the WFI (Wait For Interrupt) or WFE (Wait For Event) instructions. ARM recommends the use of a Data Synchronization Barrier (DSB) instruction before WFI or WFE, to ensure that pending memory transactions complete before changing state.
If a debug channel is active, it remains active. The core stops execution until a wakeup event is detected. The wakeup condition is dependent on the entry instruction. For WFI, an interrupt or external debug request wakes the core. For WFE, a number of specified events exist, including another core in the cluster executing the SEV instruction.
A request from the Snoop Control Unit (SCU) can also wake up the clock for a cache coherency operation in a multi-core system. This means that the cache of a core that is in standby state continues to be coherent with caches of other cores (but the core in standby does not necessarily execute the next instruction). A core reset always forces the core to exit from the standby condition.
Various forms of dynamic clock gating can also be implemented in hardware. For example, the SCU, GIC, timers, instruction pipeline or NEON blocks can be automatically clock gated when an idle condition is detected, to save power.
Standby mode can be entered and exited quickly (typically in two-clock-cycles). It therefore has an almost negligible effect on the latency and responsiveness of the core.
To an OSPM, a standby state is mostly indistinguishable from a retention state. The difference is evident to an external debugger and in hardware implementation, but not evident to the idle management subsystem of an operating system.
Retention
The core state, including the debug settings, is preserved in low-power structures, enabling the core to be at least partially turned off. Changing from low-power retention to running operation does not require a reset of the core. The saved core state is restored on changing from low-power retention state to running operation. From an operating system point of view, there is no difference between a retention state and standby state, other than method of entry, latency and use-related constraints. However, from an external debugger point of view, the states differ as External Debug Request debug events stay pending and debug registers in the core power domain cannot be accessed.
Standby和retention power state，几乎没有什么不同，不同点进入和退出的条件不同。但是它们的退出时延几乎可以忽略，对性能的影响很小很小。
Power down
In this state, the core is powered off. Software on the device must save all core state, so that it can be preserved over the power-down. Changing from power-down to running operation must include:
A reset of the core, after the power level has been restored.Restoring the saved core state.
The defining characteristic of power down states is that they are destructive of context. This affects all the components that are switched off in a given state, including the core, and in deeper states other components of the system such as the GIC or platform-specific IP. Depending on how debug and trace power domains are organized, one or both of debug and trace context might be lost in some power-down states. Mechanisms must be provided to enable the operating system to perform the relevant context saving and restoring for each given state. Resumption of execution starts at the reset vector, and after this each OS must restore its context.
Dormant mode
Dormant mode is an implementation of a power-down state. In dormant mode, the core logic is powered down, but the cache RAMs are left powered up. Often the RAMs are held in a low-power retention state where they hold their contents but are not otherwise functional. This provides a far faster restart than complete shutdown, as live data and code persists in the caches. Again, in a multi-core system, individual cores can be placed in dormant mode.
In a multi-core system that permits individual cores within the cluster to go into dormant mode, there is no scope for maintaining coherency while the core has its power removed. Such cores must therefore first isolate themselves from the coherence domain. They clean all dirty data before doing this and are typically woken up using another core signaling the external logic to re-apply power.
The woken core must then restore the original core state before rejoining the coherency domain. Because the memory state might have changed while the core was in dormant mode, it might have to invalidate the caches anyway. Dormant mode is therefore much more likely to be useful in a single core environment rather than in a cluster. This is because of the additional expense of leaving and rejoining the coherency domain. In a cluster, dormant mode is typically likely to be used only by the last core when the other cores have already been shut down. Dormant mode是power down状态的另一种实现，在这个模式，core logic被下电，但是cache RAM还处于上电状态。并且其使用场合也是不相同的，如果core处于dormant mode，需要其他处于active core恢复dormant mode的core，会导致额外昂贵的离开/重新加入coherency domain的时延。所以使用场合是当某个cluster只剩下一个core，其他core都处于power down状态，则可以考虑进入dormant mode。
Hotplug
CPU hotplug is a technique that can dynamically switch cores on or off. Hotplug can be used by the OSPM to change available compute capacity based on current compute requirements. Hotplug is also sometimes used for reliability reasons. There are a number of differences between hotplug and use of a power-down state for idle:
When a core is hot unplugged, the supervisory software stops all use of that core in interrupt and thread processing. The core is no longer considered to be available by the calling OS.The OSPM has to issue an explicit command to bring a core back online, that is, hotplug a core. The appropriate supervisory software only starts scheduling on or enabling interrupts to that core after this command.
Operating systems typically perform much of the kernel boot process on one primary core, bringing secondary cores online at a later stage. Secondary boot behaves very similarly to hotplugging a core into the system. The operations in both cases are almost identical.
Hotplug目前在动态省功耗中已经很少使用了：
在动态场景中，使用isolate CPU代替，因为hotplug热插拔时延太大，在10ms+级别以上。在suspend中，使用suspend_to_idle代替，但是对于省电效果，与suspend拔除core的效果是否一致，待确定。影响手机亮屏时间。
上面五种power state进入和退出时延都是递增关系，对性能的影响大小也是递增的。所以如何进入不同的idle level state是power management核心。
对于CPU的idle power management的策略是cpuidle governor。
展开全文
wuming_422103632 2020-05-01 23:16:48
• weixin_39897758 2020-12-26 05:06:59
• weixin_39791386 2020-11-23 13:24:18
• weixin_34729012 2021-07-16 12:51:15
• weixin_33549415 2021-07-16 12:18:08
• weixin_33340636 2021-01-17 17:54:10
• weixin_39916479 2020-11-24 08:38:03
• weixin_28884213 2021-01-17 17:54:02
• weixin_33717595 2021-02-06 13:52:47
• weixin_29168393 2021-01-17 17:54:10
• weixin_42298225 2021-01-31 23:06:26
• weixin_39616565 2020-12-06 03:09:38
• weixin_29408063 2021-01-17 17:53:59
• weixin_29113371 2021-02-06 13:52:46
• weixin_39586526 2021-02-06 13:52:46
• weixin_39555320 2021-01-17 17:54:09
• weixin_29171087 2021-02-06 13:52:46
• KISSMonX 2013-07-08 10:21:45
• 5星
3.46MB hdceshi 2009-11-09 08:37:22
• qq_26222859 2018-06-20 00:46:09

louisjh 2018-12-26 16:02:50
• sch0120 2015-07-24 15:04:37
• ## Java - Introduction to Thread Pools Java

chimomo 2019-11-05 18:02:02
• Scythe666 2018-09-14 10:38:17
• weixin_30920091 2018-12-10 04:41:00
• weixin_34283445 2017-11-22 15:30:00
• lianshaohua 2021-03-10 17:56:21

...