Skip to content

Commit c9e4cbb

Browse files
nikomatsakisbrson
authored andcommitted
---
yaml --- r: 6099 b: refs/heads/master c: d3e8654 h: refs/heads/master i: 6097: f018a88 6095: c38ede3 v: v3
1 parent faa1649 commit c9e4cbb

File tree

2 files changed

+30
-30
lines changed

2 files changed

+30
-30
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: 6a0d86c75472e1d8c4ad7bfc7d5e642cec48ff4d
2+
refs/heads/master: d3e865438f65e215332311310c25f9019d26e130

trunk/src/rt/arch/i386/_context.S

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,19 @@ The registers_t variable is in (%esp)
2020
swap_registers:
2121
// save the old context
2222
movl 4(%esp), %eax
23-
//movl %eax, 0(%eax)
24-
movl %ebx, 4(%eax)
25-
movl %ecx, 8(%eax)
26-
movl %edx, 12(%eax)
27-
movl %ebp, 16(%eax)
28-
movl %esi, 20(%eax)
29-
movl %edi, 24(%eax)
30-
//movl %cs, 32(%eax)
31-
//movl %ds, 34(%eax)
32-
//movl %ss, 36(%eax)
33-
//movl %es, 38(%eax)
34-
//movl %fs, 40(%eax)
35-
//movl %gs, 42(%eax)
23+
//movl %eax, 0(%eax)
24+
movl %ebx, 4(%eax)
25+
//movl %ecx, 8(%eax)
26+
//movl %edx, 12(%eax)
27+
movl %ebp, 16(%eax)
28+
movl %esi, 20(%eax)
29+
movl %edi, 24(%eax)
30+
//movl %cs, 32(%eax)
31+
//movl %ds, 34(%eax)
32+
//movl %ss, 36(%eax)
33+
//movl %es, 38(%eax)
34+
//movl %fs, 40(%eax)
35+
//movl %gs, 42(%eax)
3636

3737
// save the flags
3838
pushf
@@ -48,29 +48,29 @@ swap_registers:
4848
// restore the new context
4949
movl 4(%esp), %eax
5050

51-
movl 4(%eax), %ebx
52-
// save ecx for later...
53-
movl 12(%eax), %edx
54-
movl 16(%eax), %ebp
55-
movl 20(%eax), %esi
56-
movl 24(%eax), %edi
57-
movl 28(%eax), %esp
58-
// We can't actually change this...
59-
//movl 32(%eax), %cs
60-
//movl 34(%eax), %ds
61-
//movl 36(%eax), %ss
62-
//movl 38(%eax), %es
63-
//movl 40(%eax), %fs
64-
//movl 42(%eax), %gs
51+
movl 4(%eax), %ebx
52+
// save ecx for later...
53+
//movl 12(%eax), %edx
54+
movl 16(%eax), %ebp
55+
movl 20(%eax), %esi
56+
movl 24(%eax), %edi
57+
movl 28(%eax), %esp
58+
// We can't actually change this...
59+
//movl 32(%eax), %cs
60+
//movl 34(%eax), %ds
61+
//movl 36(%eax), %ss
62+
//movl 38(%eax), %es
63+
//movl 40(%eax), %fs
64+
//movl 42(%eax), %gs
6565

6666
// restore the flags
6767
movl 44(%eax), %ecx
6868
push %ecx
6969
popf
7070

7171
// ok, now we can restore ecx
72-
movl 8(%eax), %ecx
73-
72+
//movl 8(%eax), %ecx
73+
7474
// Return!
7575
jmp *48(%eax)
7676

0 commit comments

Comments
 (0)