Changeset 96568 in vbox
- Timestamp:
- Sep 1, 2022 8:26:32 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/common/compiler/vcc/stack-vcc.asm
r96560 r96568 124 124 ; 125 125 ; @param xAX Frame size. 126 ; @uses AMD64: Nothing (because we don't quite now the convention).127 ; x86: ESP = ESP - EAX;nothing else126 ; @uses AMD64: Probably nothing. EAX is certainly not supposed to change. 127 ; x86: ESP = ESP - EAX; EFLAGS, nothing else 128 128 ; 129 129 ALIGNCODE(64) … … 141 141 142 142 ; 143 ; Adjust eax so we can use xBP for stack addressing.144 ; 145 sub xAX, xCB *2146 jle .touch_loop_done 143 ; Adjust eax so we're relative to [xBP - xCB*2]. 144 ; 145 sub xAX, xCB * 4 146 jle .touch_loop_done ; jump if rax < xCB*4, very unlikely 147 147 148 148 ; … … 150 150 ; the touch loop if (int)xAX > 0. 151 151 ; 152 mov ebx, PAGE_SIZE - 1153 and ebx, ebp152 lea ebx, [ebp - xCB * 2] 153 and ebx, PAGE_SIZE - 1 154 154 sub xAX, xBX 155 jnl .touch_loop 155 jnl .touch_loop ; jump if pages to touch. 156 156 157 157 .touch_loop_done: … … 167 167 sub esp, eax 168 168 add esp, 4 169 jmp dword [esp + eax - 4]169 jmp dword [esp + eax - 4] 170 170 %endif 171 171 … … 175 175 .touch_loop: 176 176 sub xBX, PAGE_SIZE 177 mov [xBP + xBX], bl 177 %if 1 178 mov [xBP + xBX - xCB * 2], bl 179 %else 180 or byte [xBP + xBX - xCB * 2], 0 ; non-destructive variant... 181 %endif 178 182 sub xAX, PAGE_SIZE 179 183 jnl .touch_loop
Note:
See TracChangeset
for help on using the changeset viewer.