Strange structure alignment problem with armv6 but not armv7
Strange structure alignment problem with armv6 but not armv7
- Subject: Strange structure alignment problem with armv6 but not armv7
- From: Eyal Redler <email@hidden>
- Date: Thu, 02 Sep 2010 18:21:26 +0300
Hi,
My iPhone program constantly crashes on armv6 devices (it also crashes when I set the active architecture to armv7 and run it on my 3GS). Looking at the crash site using a debugger I found that the program crashes because it misinterprets a data structure which is packed inside a buffer (I'm accessing OpenType font tables, if that makes any difference).
The misinterpretation manifests itself like this. When I'm reading from the structure, I'm getting the wrong value, when I'm writing, I'm writing to the correct position.
The particular structure I'm seeing this with looks like this
UInt32 fTag;
UInt16 fOffset;
I'm having trouble accessing fOffset.
The data structures I'm accessing are defined under #pragma options align=mac68k and this code works wonderfully well on Mac (Intel and power PC) iPad and iPhone 3GS. I'm pretty sure that this is the result of some bad setting I made somewhere but so far I haven't been able to find one.
Any suggestions would be very appreciated.
Eyal Redler
------------------------------------------------------------------------------------------------
"If Uri Geller bends spoons with divine powers, then he's doing it the hard way."
--James Randi
www.eyalredler.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden