AK: Remove fast_u32_xxx apis from Memory.h

This commit removes the fast_u32_fill and fast_u32_copy functions,
as they were only used in one place, and are not optimal.
This commit is contained in:
R-Goc 2025-02-22 23:57:34 +01:00 committed by Alexander Kalenik
parent fe2b752083
commit 94de31ff3b
Notes: github-actions[bot] 2025-03-03 14:59:27 +00:00
2 changed files with 5 additions and 27 deletions

View file

@ -127,8 +127,12 @@ static void clear_rect(Bitmap& bitmap, IntRect const& rect, Color color)
ARGB32* dst = bitmap.scanline(intersection_rect.top()) + intersection_rect.left();
size_t const dst_skip = bitmap.pitch() / sizeof(ARGB32);
auto const value = color.value();
auto const width = intersection_rect.width();
for (int i = intersection_rect.height() - 1; i >= 0; --i) {
fast_u32_fill(dst, color.value(), intersection_rect.width());
for (ARGB32* p = dst; p < (dst + width); ++p) {
*p = value;
}
dst += dst_skip;
}
}