vmw_diff_memcpy(9)
π vmw_diff_memcpy(9) β the Kernel API Manual β¨
okay so bestie, welcome to vmw_diff_memcpy(9) from the Kernel API Manual, and trust me when I say this little function is doing the most for blit tracking π
πΈ NAME πΈ
vmw_diff_memcpy β a memcpy that also builds you a cute lil bounding box of everything it just modified π
β¨ SYNOPSIS β¨
void vmw_diff_memcpy (struct vmw_diff_cpy *diff , u8 *dest , const u8
*src , size_t n );
π¦ ARGUMENTS π¦
diffβ thestruct vmw_diff_cpythat keeps track of the modified bounding box. it's literally the main character here πdestβ where the copy lands, i.e. the destination π―srcβ where the bytes come from, i.e. the source π«Άnβ how many bytes we're copying, no cap π’
π DESCRIPTION π
So here's the tea β β if you want this function to correctly track the modified content, you gotta pre-load some stuff first, bestie, and there is no skipping it:
- the field
diff->linemust be pre-loaded with the current line number π§ - the field
diff->line_offsetmust be pre-loaded with the line offset in bytes where the copy starts π - and finally the field
diff->cppneeds to be preloaded with the number of bytes per unit in the horizontal direction of the area we're examining β¨
and yeah, cpp is typically bytes per pixel β iconic of it honestly. why do we need it? because it tells us the needed granularity of the difference computing operations, and that's just facts π
bestie heads up: a higher cpp generally leads to faster execution but at the cost of bounding box width precision. so like, speed vs. precision, the classic tradeoff, pick your fighter βοΈ
π₯ SEE ALSO π₯
- Kernel file
./drivers/gpu/drm/vmwgfx/vmwgfx_blit.cπ vmw_find_first_diff(9)vmw_find_last_diff(9)vmw_memcpy(9)vmw_adjust_rect(9)struct vmw_bo_blit_line_data(9)vmw_bo_cpu_blit_line(9)vmw_bo_cpu_blit(9)
okay that's the whole page bestie, you ate that π this lil gem lives over in ./drivers/gpu/drm/vmwgfx, dated October 2026, and it's filed under vmw_diff_memcpy(9) β periodt π
β¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms