mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 13:27:35 +00:00
Optimize the Painter::blit() loop a bit. ~3% fewer cycles, I'll take it.
This commit is contained in:
parent
7750e6952b
commit
f651405694
4 changed files with 22 additions and 15 deletions
|
@ -20,7 +20,7 @@ ALWAYS_INLINE void fast_dword_copy(dword* dest, const dword* src, size_t count)
|
|||
#ifdef SERENITY
|
||||
asm volatile(
|
||||
"rep movsl\n"
|
||||
: "=S"(src), "=D"(dest)
|
||||
: "=S"(src), "=D"(dest), "=c"(count)
|
||||
: "S"(src), "D"(dest), "c"(count)
|
||||
: "memory"
|
||||
);
|
||||
|
@ -34,7 +34,7 @@ ALWAYS_INLINE void fast_dword_fill(dword* dest, dword value, size_t count)
|
|||
#ifdef SERENITY
|
||||
asm volatile(
|
||||
"rep stosl\n"
|
||||
: "=D"(dest)
|
||||
: "=D"(dest), "=c"(count)
|
||||
: "D"(dest), "c"(count), "a"(value)
|
||||
: "memory"
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue