[SOLVED] Possible to set the armv7 chip into using unaligned, memory accesses?
[SOLVED] Possible to set the armv7 chip into using unaligned, memory accesses?
- Subject: [SOLVED] Possible to set the armv7 chip into using unaligned, memory accesses?
- From: David Hoerl <email@hidden>
- Date: Wed, 11 Jan 2012 15:52:04 -0500
I omitted from the original post that the code worked fine in the
simulator, but crashed on the iPhone with an access violation message.
Turns out that for many data types, ARMv7 permits unaligned access
(though with serious performance issues).
In looking further what I found was that the crashes happened when the
library was trying to access unaligned doubles (8 bytes). I then
searched around and found many posts claiming that the instruction used
to load doubles (and probably long longs) only works on aligned data.
So, I switched all 8 byte casts to use memcpy, and everything fell into
place.
The end result is DHlibxls on github, a ObjectiveC static library to
read Excel .xls files (its a long story...) - based on the now ARMv7
clean open source library libxls on sourceforge.
Thanks to all who commented!
David
_______________________________________________
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