All Forums
 Microsoft Windows CE
 General CE
 IAGM and CE 4.2 issues
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Author Topic  

jjmackay

24 Posts

Posted - 11 May 2006 :  15:14:36  Show Profile  Email Poster
Hi,

I am using a GCPlus with boot loader 1.84 and Windows CE 4.20.26 along the IAGM SDK (for CE 4.1).

The application runs successfully on CE 3.0. I have convert the workspace for EVC 4.0 SP4 with IAGM SDK. I have encounter many strange problems and gonna do my best to explains.

First situation:
In release mode: During decryption (not using any Windows specific encryption APIs); I get a Fatal error. Exception 0x80000002.This piece of code is working in Debug mode, so I have insert some trace code that output to the COM3 all the time. Depending where these trace are, the place in code where it failed is different. As an example: I see that it crashed in a "for" loop, so I have put a trace in it so see values. But it will then crash later in the code (in another function).

Second situation:
I have remove all encryption code and can now runs successfully in Release mode. But I get problem in Debug mode. At some point, a file IO operations hangs. It just hangs on a fopen call. But that same codes works well in Release mode AND in Debug mode if the debugger is NOT attached (Executed from Evc, but not debugged). Depending of where and how many trace I have, the problem will still happens but from a different calls in the code.

Memory available at that time is about 300K after the apps is loaded and running in Debug and 1MB for Release. Where the Reserved area of RAM for the WinCe image is 12 MB + 2MB as recommanded.

I have try many things to find the problem and am now clueless. Is someone have seen this strange behavior before? Can it be a memory problem on my GCPlus or incompatibility between the IAGM SDK and Ce 4.20.26 build ?

Can you be of any help?
Thanks

akidder

1519 Posts

Posted - 11 May 2006 :  16:21:57  Show Profile  Email Poster
I'll check in with other CE developers, but there are a few, general ideas I have:
- Have you tried out Entrek's CodeSnitch application? It's good for finding memory problems, which can cause intermittent app failures.
- Have you tried creating a new (default) project and pulling the files in? That would clear out any odd project settings that might have gotten set during the project transition.

Since the code was working in 3.0, there may be something more obvious.

If you can email us the debug output when the app crashes, we might be able to give you more detail about what is happening.
Go to Top of Page

akidder

1519 Posts

Posted - 11 May 2006 :  17:01:19  Show Profile  Email Poster
This from a member of our development team:

Referencing uninitialized local variables, especially pointers, is a typical cause of this kind of behavior. You may experience different results between release and debug builds and between running the debugger and running the debug build by itself.

Release and debug builds treat uninitialized local variables differently: Release builds don't change the contents of memory, while debug builds initialize local variables to a certain value (e.g. 0xcc).
Go to Top of Page

jjmackay

24 Posts

Posted - 14 Feb 2008 :  08:23:03  Show Profile  Email Poster
I am also seeing strange behavior while running my software with the GCPlus with boot loader 1.84 and Windows CE 4.20.26 along the IAGM SDK (for CE 4.1).
The software seems to hang on stdio calls, specifically fopen, fwrite, fclose and even other system calls such as MoveFile().

I wrote a small test app that does nothing except for calling fopen, fseek, fread, fwrite, and fclose. A few seconds into the program one of the stdio calls will hang.

Any ideas?
- Gil

Go to Top of Page

jjmackay

24 Posts

Posted - 18 Feb 2008 :  10:13:30  Show Profile  Email Poster
Problem solved:

Microsoft has released patch 5483 for "eMbedded Visual C++ 4.0" that address this issue.

It can be downloaded from this URL: http://www.microsoft.com/downloads/details.aspx?FamilyID=2c095739-217f-4d5d-b74f-379e6e2d879d&DisplayLang=en

- Gil
Go to Top of Page
  Topic  
 Forum Locked
 Send Topic to a Friend
 Printer Friendly
Jump To:
Eurotech Support Forums © Eurotech Inc. Go To Top Of Page
This page was generated in 0.03 seconds. Snitz Forums 2000