Re: [PATCH] arm: Fix stack alignment during interrupt handling

2022-01-13 Thread Sebastian Huber
On 13/01/2022 13:34, Sebastian Huber wrote: On a public interface, the stack pointer must be aligned on an 8-byte boundary. However, it may temporarily be only aligned on a 4-byte boundary. The interrupt handling code must ensure that the stack pointer is properly aligned before it calls a func

Re: Malloc tests

2022-01-13 Thread zack leung
There a way to get the same values used to make the calculation in malloc get usable size? Bump Il ven 7 gen 2022, 21:25 zack leung ha scritto: > I think that the malloc tests is calculated differently than alloc_size+ > allocsize mod it looks like this > *alloc_size = (uintptr_t) next_block

[PATCH] arm: Optimize interrupt handling

2022-01-13 Thread Sebastian Huber
Use the SRS (Store Return State) instruction if available. This considerably simplifies the context save and restore. --- cpukit/score/cpu/arm/arm_exc_interrupt.S | 45 +-- .../score/cpu/arm/include/rtems/score/arm.h | 1 + .../cpu/arm/include/rtems/score/cpuimpl.h | 1

[PATCH] arm: Fix stack alignment during interrupt handling

2022-01-13 Thread Sebastian Huber
On a public interface, the stack pointer must be aligned on an 8-byte boundary. However, it may temporarily be only aligned on a 4-byte boundary. The interrupt handling code must ensure that the stack pointer is properly aligned before it calls a function. See also: https://developer.arm.com/do