In case anyone was wondering "Is shared memory really a good thing for sending bitmaps to the X server?"
I thought I'd share this comparative pair of traces.
This is the new ipdf rev 4 sending the bitmap to X. Writes 44 bytes, gets two 32 byte responses.
Code:
write(22, "\201\3\n\0\26\0\340\0%\0\340\0\0\3\247\3\0\0\0\0\0\3\247"..., 44) = 44
read(22, "\203u\226\0z\17>\2408\0\0\0\25\0\340\0\0\0\0\0\1\0\1\0"..., 32) = 32
read(22, "\1\1\230\0\0\0\0\0\25\0\340\0\234\325\1\0t:\r\0h:\r\0\274"..., 32) = 32
This is the 2.7 ipdf sending the bitmap to X. Those resource unavailable's are the X server telling the client "back off man the fire hose is choking me!"
You'll also notice it starts by trying to write 261888 bytes but X only accepts 65280 bytes due to a limit in the socket buffer size.
Code:
writev(22, [{"8\1\4\0 \0\340\0\4\0\0\0\377\377\377\0F\0\5\0\26\0\340"..., 60}, {"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 261888}], 2) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 196668}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 131388}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 66108}], 1) = 65280
writev(22, [{"\0\0\0\0\0?\277\377\377\377\377\377\377\377\377\377\377"..., 828}], 1) = 828
writev(22, [{"H\2\306\377\26\0\340\0 \0\340\0\0\3U\1\0\0X\1\0\10\340"..., 24}, {"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 261888}], 2) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 196632}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 131352}], 1) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=22, events=POLLIN|POLLOUT, revents=POLLIN}], 1, -1) = 1
ioctl(22, FIONREAD, [32]) = 0
read(22, "\203u\n\1i\230G\2408\0\0\0\25\0\340\0\0\0\0\0\1\0\1\0\1"..., 32) = 32
poll([{fd=22, events=POLLIN|POLLOUT, revents=POLLOUT}], 1, -1) = 1
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 131352}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 66072}], 1) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=22, events=POLLIN|POLLOUT, revents=POLLOUT}], 1, -1) = 1
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 66072}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 792}], 1) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=22, events=POLLIN|POLLOUT, revents=POLLOUT}], 1, -1) = 1
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 792}], 1) = 792
writev(22, [{"H\2F\271\26\0\340\0 \0\340\0\0\3\367\0\0\0\255\2\0\10\340"..., 24}, {"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 189696}], 2) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 124440}], 1) = 65280
writev(22, [{"\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., 59160}], 1) = 59160
write(22, "8\2\4\0 \0\340\0\4\0\0\0\0\0\0\0C\0\5\0\26\0\340\0 \0\340"..., 40) = 40
read(22, 0xbffff77c, 32) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=22, events=POLLIN, revents=POLLIN}], 1, -1) = 1
read(22, "\1\1\22\1\0\0\0\0\25\0\340\0@\353\1\0t:\r\0h:\r\0\2749"..., 32) = 32
That's about as night and day as "This is your brain, this is your brain on drugs."