File tree 1 file changed +9
-3
lines changed
1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -567,9 +567,9 @@ pub struct TrapContext {
567
567
568
568
---
569
569
#### 控制流
570
- - 程序的控制流 (Flow of Control or Control Flow) --编译原理
570
+ - ** 程序的控制流** (Flow of Control or Control Flow) --编译原理
571
571
- 以一个程序的指令、语句或基本块为单位的** 执行序列** 。
572
- - 处理器的控制流 --计算机组成原理
572
+ - ** 处理器的控制流** --计算机组成原理
573
573
- 处理器中程序计数器的** 控制转移序列** 。
574
574
---
575
575
#### 普通控制流:从应用程序员的角度来看控制流
@@ -667,7 +667,14 @@ pub struct TrapContext {
667
667
- 调用 ` __switch() ` 之后直到它返回前的这段时间,原 Trap 控制流 A 会先被** 暂停** 并被切换出去, CPU 转而** 运行** 另一个应用在内核中的 Trap 控制流 B 。
668
668
![ bg right 95%] ( figs/task-context.png )
669
669
670
+ ---
671
+ #### [ Möbius strip] ( https://www.snexplores.org/article/scientists-say-mobius-strip-definition-pronunciation )
672
+
673
+ a Möbius strip has only one surface.
670
674
675
+ ![ bg right 95%] ( figs/mobius-strip.png )
676
+ <!--
677
+ -->
671
678
---
672
679
#### Trap控制流切换:恢复运行
673
680
- 一个特殊的函数` __switch() `
@@ -676,7 +683,6 @@ pub struct TrapContext {
676
683
从实现的角度讲, ` __switch() ` 函数和一个普通的函数之间的核心差别仅仅是它会** 换栈** 。
677
684
![ bg right 95%] ( figs/task-context.png )
678
685
679
-
680
686
---
681
687
#### Trap控制流切换函数` __switch() `
682
688
![ w:800] ( figs/switch.png )
You can’t perform that action at this time.
0 commit comments