[ECOS] Operator new fails for Coldfire MCF5282

Uwe Kindler uwe_kindler@web.de
Mon Apr 25 19:46:00 GMT 2005


Hello,

I have got the eCosPro 2.0.10 starterkit for SSV DNP/5280 with Coldfire MCF5282. I installed Cygwin with m68k-elf toolchain and eCos from the starter kit CD. I buildet the eCos library and ran some tests without any problems. Then I coded a simple eCos C++ application with dynamic object creation with operator new. As soon as the new operator is called, the debugger receives a SIGTRAP. In order to check C++ support I buildet and executed the cxxsupp test - the same problem occured. Then I single stepped the operator new in cxxsupp an gdb displayed the follwing assembler instructions in assembly view:

0x180c8 <operator new(unsigned long)>: linkw %fp,#-60
0x180cc <operator new(unsigned long)+4> fmovemx %fp2-%fp7,%sp@-

The second instruction fmovemx causes the trouble. I think this is a floating point instruction - at least this instruction is not contained in the MCF5200 programming manual. I used the standard compiler and linker flags settings and the default template for building the eCos library - so I do not know why this problem occures because I did not change anything.

Does someone know what is going wrong here? Did eCosCentric sucessfully tested the C++ support with cxxsupp for MCF5282? Maybe it would be possible to send me the ecc file so that I can rebuild the library with the working settings.

Here are the compiler and linker flags used for building the library:

Compiler:
-m5200 -malign-int -Wall -Wpointer-arith -Wstrict-prototypes -Winline -Wundef -Woverloaded-virtual -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -fvtable-thunks=3 -finit-priority -fomit-frame-pointer

Linker:
-m5200 -g -nostdlib -Wl,--gc-sections -Wl,-static

Thank you in advance, Uwe Kindler 
______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list