Arm Community
Site
Search
User
Site
Search
User
Groups
Arm Research
DesignStart
Education Hub
Graphics and Gaming
High Performance Computing
Innovation
Multimedia
Open Source Software and Platforms
Physical
Processors
Security
System
Software Tools
TrustZone for Armv8-M
中文社区
Blog
Announcements
Artificial Intelligence
Automotive
Healthcare
HPC
Infrastructure
Innovation
Internet of Things
Machine Learning
Mobile
Smart Homes
Wearables
Forums
All developer forums
IP Product forums
Tool & Software forums
Support
Open a support case
Documentation
Downloads
Training
Arm Approved program
Arm Design Reviews
Community Help
More
Cancel
Developer Community
Tools and Software
Software Tools
Jump...
Cancel
Software Tools
Arm Development Studio forum
OMAP3: encountered a blocking structure assignment, occurring only on OMAP3 processors
Tools, Software and IDEs blog
Forums
Videos & Files
Help
Jump...
Cancel
New
Replies
6 replies
Subscribers
126 subscribers
Views
2221 views
Users
0 members are here
Related
OMAP3: encountered a blocking structure assignment, occurring only on OMAP3 processors
Offline
Wolfgang Hauser
over 7 years ago
Parents
Offline
Peter Harris
over 7 years ago
Note: This was originally posted on 1st August 2012 at
http://forums.arm.com
This will "probably work" because most memcpy implementations include alignment checks, and fall back to a slower copy if src and/or dst are unaligned. However you still end up with a structure with incorrect alignment in memory. If you try and use that later as a real structure then you may well hit other problems. The compiler could use LDRD/STRD to read or write the 64-bit fields, for example, and as these require 64-bit alignment, you would hit the same problem.
A quick and dirty approximation of binary compatibility across memory systems - if you align base pointers for any structure on an 8-byte boundary you are unlikely to hit a problem on any commonly used architecture.
Cancel
Up
0
Down
Reply
Cancel
Reply
Offline
Peter Harris
over 7 years ago
Note: This was originally posted on 1st August 2012 at
http://forums.arm.com
This will "probably work" because most memcpy implementations include alignment checks, and fall back to a slower copy if src and/or dst are unaligned. However you still end up with a structure with incorrect alignment in memory. If you try and use that later as a real structure then you may well hit other problems. The compiler could use LDRD/STRD to read or write the 64-bit fields, for example, and as these require 64-bit alignment, you would hit the same problem.
A quick and dirty approximation of binary compatibility across memory systems - if you align base pointers for any structure on an 8-byte boundary you are unlikely to hit a problem on any commonly used architecture.
Cancel
Up
0
Down
Reply
Cancel
Children
No data
More questions in this forum
By title
By date
By reply count
By view count
By most asked
By votes
By quality
Descending
Ascending
All recent questions
Unread questions
Questions you've participated in
Questions you've asked
Unanswered questions
Answered questions
Questions with suggested answers
Questions with no replies
Answered
How to view SFRs in DS during debugging?
+1
2878
views
1
reply
Latest
3 months ago
by
Ronan Synnott
Answered
Dual-core debugging in DS
0
5733
views
2
replies
Latest
3 months ago
by
Ivan Savvateev
Answered
DS52020.0 connection to Musca-A/B boards not working
+1
Arm Development Studio
Musca-A
7529
views
4
replies
Latest
3 months ago
by
Daniel Oliveira
Answered
Positioning a function in a Position Independent Executable for ARMV8
+1
8285
views
3
replies
Latest
4 months ago
by
Stephen Theobald
Answered
Link a pure binary file to image with scatter file
0
8248
views
3
replies
Latest
4 months ago
by
Ronan Synnott
<
>
View all questions in Arm Development Studio forum