Article ID: 818453 - Last Review: May 27, 2005 - Revision: 1.4

FIX: Alignment Exception When Accessing 16-bit Member

On This Page

Expand all | Collapse all

SYMPTOMS

When you use global compiler optimization with the ARM compiler (Clarm.exe), and if you access a 16-bit structure member, you receive an alignment exception error. This behavior occurs even though the structure is aligned.

RESOLUTION

Hotfix Information

A supported software update is now available from Microsoft as Windows CE 4.2 Core OS QFE 818453. To resolve this problem immediately, click the following article number for information about obtaining Windows CE Platform Builder and core operating system software updates:
837392  (http://support.microsoft.com/kb/837392/ ) How to locate core operating system fixes for Microsoft Windows CE Platform Builder products

File Information

The English version of this package has the file attributes (or later) that are listed in the following table.
   Date         Time   Version            Size    File name
   -------------------------------------------------------------------------
   12-Apr-2003  01:24  4.2.3.411         981,608  030411_wce42-q818453.exe  
The English version of this hotfix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date         Time   Version            Size    File name
   -----------------------------------------------------------
   01-Apr-2003  03:14  12.20.9773.0      884,736  C2_arm.dll

WORKAROUND

Turn off compiler global optimization by using the optimize pragma in the source code:
#pragma optimize("g", off)
   //...effected code or function
   #pragma optimize("", on)

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.

APPLIES TO
  • Microsoft Windows CE .NET 4.2
Keywords: 
kbbug kbfix kbqfe KB818453
Retired KB ArticleRetired KB Content Disclaimer
This article was written about products for which Microsoft no longer offers support. Therefore, this article is offered "as is" and will no longer be updated.
 

Article Translations