[Dwarf-Discuss] DWARF for DSP like processors with multiple memories

Anthony Berent anthony.berent at arm.com
Mon Nov 24 09:20:38 PST 2008


Hi,
 
I am looking for some advice on the correct use of DWARF for describing code
running on an ARM Data Engine. ARM Data Engines are DSPs with multiple
memories (not just data and instruction, but multiple data memories), each
independently addressed. The C source code used to program the Data Engines
uses pragmas to assign variables to particular memories, and to qualify
pointers with the targeted memory. The addresses used within the processors
never include an explicit memory identifier, instead there are different
instructions to access each memory.
 
At the moment our DWARF description uses segment attributes (DW_AT_SEGMENT)
to describe the allocation of variables to memories, but we are not sure if
this is a correct use of DWARF. In particular:

1.	Is this a reasonable use of DW_AT_segment, which was, I believe,
originally created for processors with segmented memory of the sort
implemented in small-mode x86?

2.	Is anybody currently using DW_AT_segment in a similar way, or
solving a similar problem in a different way? If so, for which
architectures?

3.	How should we describe which memory is targeted by pointers? Is
using the DW_AT_address_class the right way to do this?

4.	Is there any way of describing in DWARF which memories contain the
stack? I can't see any way of including segment information in DWARF 3 call
frames, and, if I am reading it correctly the DWARF 4 draft I have seen this
only supports segment information in the PC value in call frames.
	*	I say memories (plural) because some ARM Data Engines only
allow certain registers to be saved in particular memories, so we sometimes
need multiple stacks.

Many thanks for any advice anybody can give.

- Anthony Berent
ARM Ltd





More information about the Dwarf-Discuss mailing list