[cairo] Cairo & pixman on PPC
cairouser at yahoo.com
Wed May 16 07:02:36 PDT 2012
Andrea Canciani wrote:
> I had started a little project to get these things out of pixman cairo.
> AFAIK it should work on most supported platforms, but I don't have
> access to a ppc box anymore.
> Would you be willing to test it on ppc (in the hope that it will some
> day be useful to replace the mutex/atomic ifdeffery in cairo/pixman)?
Funny enough, I don't have access to real PPC box either. All my PPC
testing is done under Rosetta on an Intel Mac. Then if things break -
actual PPC users will usually say something. I found that so far Rosetta
testing has been quite close, at least in terms of what will and will
not work on a real PPC. I'd be glad to test things under Rosetta, if
> Can you provide some additional details about these intrinsics on iOS?
> Are they provided by gcc or is cairo incorrectly detecting them when
> they are not available?
I think they are provided as compiler "function calls", because cairo
compiles and links OK with these enabled. However, they clearly do not
work in a sense that using any type of concurrent cairo operations (on
unrelated surfaces etc) causes almost immediate program crash due to
memory corruption or refcount errors. These crashes are solved by
switching cairo build configuration to pthreads based locking.
> If they are available, do they work? (This might be a compiler bug?)
Probably, in a sense that compiler is not properly "cleaned up" by
Apple. But it still may be worth handling it on the Cairo end.
> Should we try to detect it automatically?
> Is it only missing on ppc or on arm as well?
Only on PPC as far as I can tell. Cairo 1.10 builds on iOS without these
> PS: sorry for little activity on cairo quartz. I've been doing some
> progress (and rebasing broke the build, so I fixed it again). I'm a
> couple (maybe 3) commits away from posting a new patchset, so it
> should happen "soon".
Things have been working fine so far with your latest patches, thanks!
There is only one visible "drawing issue" (essentially draws a line
across where there shouldn't be one, probably a clipping artifact) -
that's been in Quartz backend since forever.
There is also an unrelated issue in pixman, which seems to lose surface
type on iOS/ARM - fortunately rarely, but when it does, it's permanent.
Surface is treated as 8 bit, even though it is 32 bit (so the entire
drawing is compressed into left 1/4 of screen in what looks like an old
CGA :) ). The only solution then is to kill and restart the program.
That one will probably remain unsolved, as it is virtually impossible to
replicate or track down. Just mentioning.
More information about the cairo