Changeset 15418 in vbox
- Timestamp:
- Dec 13, 2008 6:39:03 AM (16 years ago)
- Location:
- trunk/src/VBox/VMM/VMMAll
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/EMAll.cpp
r15413 r15418 2942 2942 && pCpu->pCurInstr->opcode != OP_XCHG 2943 2943 # ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 2944 && pCpu->pCurInstr->opcode != OP_CMPXCHG 2944 && pCpu->pCurInstr->opcode != OP_CMPXCHG /* solaris */ 2945 && pCpu->pCurInstr->opcode != OP_AND /* windows */ 2946 && pCpu->pCurInstr->opcode != OP_OR /* windows */ 2947 && pCpu->pCurInstr->opcode != OP_XOR 2945 2948 # endif 2946 2949 ) -
trunk/src/VBox/VMM/VMMAll/EMAllA.asm
r15413 r15418 50 50 %ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 51 51 %define CAN_DO_8_BYTE_OP 1 52 %define MY_PTR_REG64 rcx 52 53 %endif 53 54 … … 156 157 157 158 ; switch on size 158 %ifdef RT_ARCH_AMD64159 %ifdef CAN_DO_8_BYTE_OP 159 160 cmp al, 8 160 161 je short .do_qword ; 8 bytes variant … … 191 192 pop MY_RET_REG 192 193 retn 194 195 %ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 196 .do_qword: 197 db 0xea ; jmp far .sixtyfourbit_mode 198 dd .sixtyfourbit_mode, NAME(SUPR0Abs64bitKernelCS) 199 BITS 64 200 .sixtyfourbit_mode: 201 and esp, 0ffffffffh 202 and MY_PTR_REG, 0ffffffffh 203 mov rdx, qword [rsp + 08h] ; rdx = second parameter 204 and [MY_PTR_REG64], rdx ; do 8 bytes AND 205 jmp far [.fpret wrt rip] 206 .fpret: ; 16:32 Pointer to .done. 207 dd .done, NAME(SUPR0AbsKernelCS) 208 BITS 32 209 %endif ; VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 193 210 ENDPROC EMEmulateAnd 194 211 … … 221 238 222 239 ; switch on size 223 %ifdef RT_ARCH_AMD64240 %ifdef CAN_DO_8_BYTE_OP 224 241 cmp al, 8 225 242 je short .do_qword ; 8 bytes variant … … 256 273 pop MY_RET_REG 257 274 retn 275 276 %ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 277 .do_qword: 278 db 0xea ; jmp far .sixtyfourbit_mode 279 dd .sixtyfourbit_mode, NAME(SUPR0Abs64bitKernelCS) 280 BITS 64 281 .sixtyfourbit_mode: 282 and esp, 0ffffffffh 283 and MY_PTR_REG, 0ffffffffh 284 mov rdx, qword [rsp + 08h] ; rdx = second parameter 285 or [MY_PTR_REG64], rdx ; do 8 bytes OR 286 jmp far [.fpret wrt rip] 287 .fpret: ; 16:32 Pointer to .done. 288 dd .done, NAME(SUPR0AbsKernelCS) 289 BITS 32 290 %endif ; VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 258 291 ENDPROC EMEmulateOr 259 292 … … 286 319 287 320 ; switch on size 288 %ifdef RT_ARCH_AMD64321 %ifdef CAN_DO_8_BYTE_OP 289 322 cmp al, 8 290 323 je short .do_qword ; 8 bytes variant … … 333 366 retn 334 367 368 %ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 369 .do_qword: 370 db 0xea ; jmp far .sixtyfourbit_mode 371 dd .sixtyfourbit_mode, NAME(SUPR0Abs64bitKernelCS) 372 BITS 64 373 .sixtyfourbit_mode: 374 and esp, 0ffffffffh 375 and MY_PTR_REG, 0ffffffffh 376 mov rdx, qword [rsp + 08h] ; rdx = second parameter 377 lock or [MY_PTR_REG64], rdx ; do 8 bytes OR 378 jmp far [.fpret wrt rip] 379 .fpret: ; 16:32 Pointer to .done. 380 dd .done, NAME(SUPR0AbsKernelCS) 381 BITS 32 382 %endif ; VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 383 384 335 385 %ifdef IN_RC 336 386 ; #PF resume point. … … 370 420 371 421 ; switch on size 372 %ifdef RT_ARCH_AMD64422 %ifdef CAN_DO_8_BYTE_OP 373 423 cmp al, 8 374 424 je short .do_qword ; 8 bytes variant … … 405 455 pop MY_RET_REG 406 456 retn 457 458 %ifdef VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 459 .do_qword: 460 db 0xea ; jmp far .sixtyfourbit_mode 461 dd .sixtyfourbit_mode, NAME(SUPR0Abs64bitKernelCS) 462 BITS 64 463 .sixtyfourbit_mode: 464 and esp, 0ffffffffh 465 and MY_PTR_REG, 0ffffffffh 466 mov rdx, qword [rsp + 08h] ; rdx = second parameter 467 xor [MY_PTR_REG64], rdx ; do 8 bytes XOR 468 jmp far [.fpret wrt rip] 469 .fpret: ; 16:32 Pointer to .done. 470 dd .done, NAME(SUPR0AbsKernelCS) 471 BITS 32 472 %endif ; VBOX_WITH_HYBRID_32BIT_KERNEL_IN_R0 407 473 ENDPROC EMEmulateXor 408 474
Note:
See TracChangeset
for help on using the changeset viewer.