[PATCH] libdebugger: Fix for ARMv7-M with -O0 optimization

Sebastian Huber sebastian.huber at embedded-brains.de
Wed Mar 20 08:54:40 UTC 2019


On 26/02/2019 07:29, Sebastian Huber wrote:
> On 25/02/2019 22:46, Chris Johns wrote:
>> Hi,
>>
>> The patch looks like it is masking something but I am not sure.
>>
>> What are the errors at -O0 the patch is attempting to resolve?
>>
>> Which BSP is showing the issue?
>> What is the multilib ARM arch?
>
> The ARMv7-M is affected by this.
>
>>
>> Are these errors seen at -O2 and if not why does -O0 cause them?
>
> With -O2 the assembler doesn't see the offending machine instructions, 
> they are optimized away. See the useless local variables in 
> rtems_debugger_target_set_vectors().
>
>>
>> The intention is for the ARM back end to work on more than the 
>> CortexA9 so I am
>> concerned with making the whole of `target_exception` dependent on CP15.
>
> I just removed the useless assignment to local variables in 
> rtems_debugger_target_set_vectors() and expanded the scope of the 
> ARM_CP15 block. There is no functional change.
>

It would be good to get this issue fixed. A working -O0 build is 
important since debugging -O2 code is no real fun.

-- 
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.



More information about the devel mailing list