# Link Register, LR, on GCC/Cortex-M3 seems to be corrupted before running the first task

**URL:** <https://forums.freertos.org/t/link-register-lr-on-gcc-cortex-m3-seems-to-be-corrupted-before-running-the-first-task/13834>\
**Category:** Kernel\
**Created:** [November 4, 2021, 5:30am UTC](https://forums.freertos.org/t/link-register-lr-on-gcc-cortex-m3-seems-to-be-corrupted-before-running-the-first-task/13834 "2021-11-04T05:30:28Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![hs2](https://avatars.discourse-cdn.com/v4/letter/h/a4c791/32.png) [@hs2](https://forums.freertos.org/u/hs2)\
**Post date:** [November 4, 2021, 6:04am UTC](https://forums.freertos.org/t/link-register-lr-on-gcc-cortex-m3-seems-to-be-corrupted-before-running-the-first-task/13834/2 "2021-11-04T06:04:23Z")

</div>

Doing this

> [@Xavier](#):
>
> ```auto
> SysTick->CTRL = SysTick_CTRL_CLKSOURCE_Msk | SysTick_CTRL_TICKINT_Msk | SysTick_CTRL_ENABLE_Msk; 
> __enable_irq();
> 
> ```

isn’t normal since this is managed by FreeRTOS by default.  
I think it might trigger the scheduler before being initialized started and can cause any weird problem…  
What if you’re omitting this part ?

---

_[View the full topic](https://forums.freertos.org/t/link-register-lr-on-gcc-cortex-m3-seems-to-be-corrupted-before-running-the-first-task/13834)._
