search for: vram_dirty

Displaying 2 results from an estimated 2 matches for "vram_dirty".

2006 Mar 16
0
[PATCH 3a/3] Add shadow VRAM
...void intr(int sig) +{ + + sse2_ok = 0; + longjmp(sse_jbuf, 1); + return; +} + +void check_sse2(void) +{ + + if ((cpuid_edx(1) & 0x4000000) == 0) { + sse2_ok = 0; + return; + } + signal(SIGILL, intr); + if (setjmp(sse_jbuf) == 0) + __asm__("xorps %xmm0,%xmm0\n"); + return; +} + +int vram_dirty(VGAState *s, int offset, int n) +{ + __m128i *sp, *vp; + + if (s->vram_shadow == NULL) + return 1; + if (sse2_ok == 0) + return cmp_vram(s, offset, n); + vp = (__m128i *)(s->vram_ptr + offset); + sp = (__m128i *)(s->vram_shadow + offset); + while ((n -= sizeof(*vp)) >= 0) { + if (_mm...
2007 Mar 13
7
vram_dirty vs. shadow paging dirty tracking
When thinking about multithreading the device model, it occurred to me that it''s a little odd that we''re doing a memcmp to determine which portions of the VRAM has changed. Couldn''t we just use dirty page tracking in the shadow paging code? That should significantly lower the overhead of this plus I believe the infrastructure is already mostly there in the shadow2