- Timestamp:
- Jan 24, 2024 12:50:12 AM (11 months ago)
- Location:
- trunk/src/VBox/Runtime
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/common/zip/zip.cpp
r98103 r103013 1770 1770 if ( cbSrc == _4K 1771 1771 && !((uintptr_t)pvSrc & 15) 1772 && ASMMemIsZero Page(pvSrc))1772 && ASMMemIsZero(pvSrc, _4K)) 1773 1773 { 1774 1774 if (RT_UNLIKELY(cbDst < sizeof(s_abZero4K))) -
trunk/src/VBox/Runtime/testcase/tstRTInlineAsm.cpp
r103005 r103013 2398 2398 if (pPage->ab[i]) 2399 2399 RTTestFailed(g_hTest, "ASMMemZeroPage didn't clear byte at offset %#x!\n", i); 2400 if (ASMMemIsZero Page(pPage) != true)2401 RTTestFailed(g_hTest, "ASMMemIsZero Pagereturns false after ASMMemZeroPage!\n");2400 if (ASMMemIsZero(pPage, RT_ASM_PAGE_SIZE) != true) 2401 RTTestFailed(g_hTest, "ASMMemIsZero/RT_ASM_PAGE_SIZE returns false after ASMMemZeroPage!\n"); 2402 2402 if (ASMMemFirstMismatchingU32(pPage, sizeof(pPage), 0) != NULL) 2403 2403 RTTestFailed(g_hTest, "ASMMemFirstMismatchingU32(,,0) returns non-NULL after ASMMemZeroPage!\n"); … … 2410 2410 RTTestISub("ASMMemZeroPage"); 2411 2411 DO_SIMPLE_TEST_NO_SUB_NO_STACK(tstASMMemZeroPageWorker, TSTPAGE); 2412 }2413 2414 2415 static void tstASMMemIsZeroPage(RTTEST hTest)2416 {2417 RTTestSub(hTest, "ASMMemIsZeroPage");2418 2419 void *pvPage1 = RTTestGuardedAllocHead(hTest, PAGE_SIZE);2420 void *pvPage2 = RTTestGuardedAllocTail(hTest, PAGE_SIZE);2421 RTTESTI_CHECK_RETV(pvPage1 && pvPage2);2422 2423 memset(pvPage1, 0, PAGE_SIZE);2424 memset(pvPage2, 0, PAGE_SIZE);2425 RTTESTI_CHECK(ASMMemIsZeroPage(pvPage1));2426 RTTESTI_CHECK(ASMMemIsZeroPage(pvPage2));2427 2428 memset(pvPage1, 0xff, PAGE_SIZE);2429 memset(pvPage2, 0xff, PAGE_SIZE);2430 RTTESTI_CHECK(!ASMMemIsZeroPage(pvPage1));2431 RTTESTI_CHECK(!ASMMemIsZeroPage(pvPage2));2432 2433 memset(pvPage1, 0, PAGE_SIZE);2434 memset(pvPage2, 0, PAGE_SIZE);2435 for (unsigned off = 0; off < PAGE_SIZE; off++)2436 {2437 ((uint8_t *)pvPage1)[off] = 1;2438 RTTESTI_CHECK(!ASMMemIsZeroPage(pvPage1));2439 ((uint8_t *)pvPage1)[off] = 0;2440 2441 ((uint8_t *)pvPage2)[off] = 0x80;2442 RTTESTI_CHECK(!ASMMemIsZeroPage(pvPage2));2443 ((uint8_t *)pvPage2)[off] = 0;2444 }2445 2446 RTTestSubDone(hTest);2447 2412 } 2448 2413 … … 3333 3298 3334 3299 tstASMMemZeroPage(); 3335 tstASMMemIsZeroPage(g_hTest);3336 3300 tstASMMemFirstMismatchingU8(g_hTest); 3337 3301 tstASMMemZero32();
Note:
See TracChangeset
for help on using the changeset viewer.