On 08/09/2011 11:41 PM, Pedro Alves wrote: >>> > > >>> > > You can't do that given the descriptions specify GNU/Linux osabi. >>> > > There should be linux, and non-linux variants. >>> > > >> > >> > Can't we get rid of osabi from xml description, and use them both for >> > linux and non-linux? Similar to arm's target descriptions. > We can, but that's a bit a step backwards. arm's descriptions don't > set the osabi because the support for the osabi field element was added > after the descriptions were. Having the target tell gdb the osabi makes > a multi-target gdb (*) figure out the correct arch even if you don't > specify an executable (for attach). I see, thanks for the explanation, Pedro. > I believe that with an xi:include, the linux xml file would be minimal. I reference the i386 xml files, and do the similar for tic6x. Copy tic6x-{c62x,c64x,c64xp}.xml to tic6x-{c62x,c64x,c64xp}-linux.xml, and add osabi in tic6x-*-linux.xml files. Generate corresponding *.c files and *.data files. In the new patch, linux target descriptions are initialized in tic6x-linux-tdep.c:_initialize_tic6x_linux_tdep, and non-linux target descriptions are initialized in tic6x-tdep.c:_initialize_tic6x_tdep. -- Yao (齐尧)