Rev 2465 | Rev 3908 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2465 | Rev 3500 | ||
---|---|---|---|
Line 3... | Line 3... | ||
3 | ;; Copyright (C) KolibriOS team 2004-2012. All rights reserved. ;; |
3 | ;; Copyright (C) KolibriOS team 2004-2012. All rights reserved. ;; |
4 | ;; Distributed under terms of the GNU General Public License ;; |
4 | ;; Distributed under terms of the GNU General Public License ;; |
5 | ;; ;; |
5 | ;; ;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 7... | Line 7... | ||
7 | 7 | ||
Line 8... | Line 8... | ||
8 | $Revision: 2465 $ |
8 | $Revision: 3500 $ |
9 | 9 | ||
10 | 10 | ||
Line 152... | Line 152... | ||
152 | mov [edi+block_size], 4096*sizeof.MEM_BLOCK |
152 | mov [edi+block_size], 4096*sizeof.MEM_BLOCK |
153 | mov [edi+block_flags], USED_BLOCK |
153 | mov [edi+block_flags], USED_BLOCK |
Line 154... | Line 154... | ||
154 | 154 | ||
155 | mov [ecx+block_next], eax |
155 | mov [ecx+block_next], eax |
156 | mov [ecx+block_prev], ebx |
156 | mov [ecx+block_prev], ebx |
157 | mov [edi+list_fd], eax |
157 | mov [ecx+list_fd], eax |
158 | mov [edi+list_bk], eax |
158 | mov [ecx+list_bk], eax |
159 | mov [edi+block_base], eax |
159 | mov [ecx+block_base], eax |
160 | mov [edi+block_size], eax |
160 | mov [ecx+block_size], eax |
Line 161... | Line 161... | ||
161 | mov [edi+block_flags], USED_BLOCK |
161 | mov [ecx+block_flags], USED_BLOCK |
162 | 162 | ||
163 | mov [ebx+block_next], ecx |
163 | mov [ebx+block_next], ecx |
Line 438... | Line 438... | ||
438 | 438 | ||
439 | lea edx, [mem_block_list+ecx*8] |
439 | lea edx, [mem_block_list+ecx*8] |
440 | cmp edx, [edx] |
440 | cmp edx, [edx] |
441 | jne .add_block |
441 | jne .add_block |
- | 442 | btr [mem_block_mask], ecx |
|
442 | btr [mem_block_mask], ecx |
443 | |
443 | .add_block: |
444 | .add_block: |
444 | bts [mem_block_mask], eax |
445 | bts [mem_block_mask], eax |
445 | lea edx, [mem_block_list+eax*8] |
446 | lea edx, [mem_block_list+eax*8] |
446 | list_add edi, edx |
447 | list_add edi, edx |
Line 756... | Line 757... | ||
756 | .fill: |
757 | .fill: |
757 | mov dword [page_tabs+ebx*4], 2 |
758 | mov dword [page_tabs+ebx*4], 2 |
758 | inc ebx |
759 | inc ebx |
759 | dec eax |
760 | dec eax |
760 | jnz .fill |
761 | jnz .fill |
- | 762 | ||
761 | .second_nofill: |
763 | .second_nofill: |
762 | sub ecx, edx |
764 | sub ecx, edx |
763 | jz .nothird |
765 | jz .nothird |
764 | or cl, FREE_BLOCK |
766 | or cl, FREE_BLOCK |
765 | mov [page_tabs+ebx*4], ecx |
767 | mov [page_tabs+ebx*4], ecx |
- | 768 | ||
766 | .nothird: |
769 | .nothird: |
Line 767... | Line 770... | ||
767 | 770 | ||
768 | mov edx, [current_slot] |
771 | mov edx, [current_slot] |
769 | mov ebx, [alloc_size] |
772 | mov ebx, [alloc_size] |
Line 820... | Line 823... | ||
820 | invlpg [eax] |
823 | invlpg [eax] |
821 | @@: |
824 | @@: |
822 | inc esi |
825 | inc esi |
823 | dec ecx |
826 | dec ecx |
824 | jnz .release |
827 | jnz .release |
- | 828 | ||
825 | .released: |
829 | .released: |
826 | push edi |
830 | push edi |
Line 827... | Line 831... | ||
827 | 831 | ||
828 | mov edx, [current_slot] |
832 | mov edx, [current_slot] |