Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training




Loading

GCC 4.8 and TivaTM4C1231

Posted by simon--r on October 22, 2015

Hi all FreeRTOS: 7.2.0 MCU: TM4C1231 Memory alloc: heap_4

My application works when compiled with GCC 4.7. I’ve updated to GCC 4.8 and the same application is unstable, and reports unreasonably large numbers from xPortGetFreeHeapSize, e.g.: GCC 4.7.1 7800 bytes
GCC 4.8.3 33537864 bytes

I’ve tried updating to FreeRTOS 8.2.3 but this makes no difference. I have a task StackOverflowHook installed but it is not being called.

I would appreciate any suggestions/ideas. Unfortunately the JTAG port on my hardware isn’t easily accessible for debugging. Thanks


GCC 4.8 and TivaTM4C1231

Posted by rtel on October 22, 2015

Did you look at the release notes for the compiler to see what was different? Could it be the libraries that are the biggest difference?


GCC 4.8 and TivaTM4C1231

Posted by heinbali01 on October 22, 2015

Is there a higher gcc version available ( >= 4.9.1 ? ) for the TM4C1231 ? In 4.8, for the first time, the gcc compiler is compiled by a C++ compiler. It is not unthinkable that some regression has taken place.

Did you try different levels of optimisation already? -O0, -O1, -O2 and (my favourite) -Os ?

It is a pity that embedded debugging is difficult. If not I would definitely check the value of 'xFreeBytesRemaining', see why and when it becomes extremely high.

Do you have a listing ( main.lss mixed with C-code ) of the functions in heap_4.c ?

~~~~ void vPortFree( void *pv ); static void prvHeapInit( void ); static void prvInsertBlockIntoFreeList( BlockLinkt *pxBlockToInsert ); void *pvPortMalloc( sizet xWantedSize ); ~~~~

You write you have 'StackOverflowHook' installed, I assume that you also have this define?

~~~~ #define configCHECKFORSTACK_OVERFLOW 2 ~~~~

Please let us know your findings.

Regards.


GCC 4.8 and TivaTM4C1231

Posted by simon--r on October 29, 2015

Thanks for your suggestions. I'm still investigating, but I think that my problem is a bug in our linker script, and changing the compiler has made the problem show up. So it's not a FreeRTOS fault.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists