Re: [PATCH v3 9/9] sm501: Fix and optimize overlap check

2020-06-22 Thread BALATON Zoltan
On Mon, 22 Jun 2020, Peter Maydell wrote: > On Sat, 20 Jun 2020 at 22:04, BALATON Zoltan wrote: >> >> When doing reverse blit we need to check if source and dest overlap >> but it is not trivial due to possible different base and pitch of >> source and dest. Do rectangle overlap if base and pitch

Re: [PATCH v3 9/9] sm501: Fix and optimize overlap check

2020-06-22 Thread Peter Maydell
On Sat, 20 Jun 2020 at 22:04, BALATON Zoltan wrote: > > When doing reverse blit we need to check if source and dest overlap > but it is not trivial due to possible different base and pitch of > source and dest. Do rectangle overlap if base and pitch match, > otherwise just check if memory area con

[PATCH v3 9/9] sm501: Fix and optimize overlap check

2020-06-20 Thread BALATON Zoltan
When doing reverse blit we need to check if source and dest overlap but it is not trivial due to possible different base and pitch of source and dest. Do rectangle overlap if base and pitch match, otherwise just check if memory area containing the rects overlaps so rects could possibly overlap. Si