This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Is It Possible to Specify Section Properties?

Hi,

Is there a way to make tconf add section properties, such as palign(8), to the section specifications it creates?

We are using SRIO to bootload a C6445 via an Altera FPGA. It appears the the Altera RapidIO MegaCore can only perform SRIO Direct I/O transactions whose size is a multiple of 8 bytes.

We have a bootloader on our host that writes each section in turn to the C6455 but we have a problem if the section size is not a multiple of 8 bytes. Currently the section size will be padded by the bootloader to be a multiple of 8 bytes which is not always going to work!

I could solve half the problem by providing a user defined .cmd file for the compiler sections.

I could also provide a memory specification for each BIOS section but I think this would be rather ^manual^ and inflexible!

Any thoughts greatly appreciated,

Thanks,

Matt

DSP/BIOS V5.41.08.30

  • There is no way that I know of to do this.   Do you know which sections are not respecting this 8-byte size alignment?   Is it just a few?   It might be possible to override those few sections with a user .cmd file that you link ahead of the BIOS .cmd file.  If you specify the user .cmd file before the BIOS-generated .cmd file, the section placement from the first .cmd file on the link link seems to take precedence.    This might help you from having to hand-edit the generated .cmd file every time you make a .tcf change.

    Regards,
    -Karl-

  • Karl Wechsler said:
    There is no way that I know of to do this.

    Hmm, I thought you would say that! I wonder what other people using the C6455 SRIO boot have done? Surely we're not the first application to use a FPGA based SRIO implementation to boot a C6455?

    Karl Wechsler said:
    Do you know which sections are not respecting this 8-byte size alignment?   Is it just a few?

    Using the normal process I'm not specifying 8-byte size alignment. I can see sections changing their size alignment as code changes are made. The cause of this current activity were some changes that caused .gblinit to grow and then loader corrupted the .switch section that happened to follow!

    Karl Wechsler said:
    If you specify the user .cmd file before the BIOS-generated .cmd file, the section placement from the first .cmd file on the link link seems to take precedence.    This might help you from having to hand-edit the generated .cmd file every time you make a .tcf change.

    OK, thanks, I might try this. We were considering post-processing the .tcf to insert some palign(8) statements. Both approaches worry me because I don't understand what the sections are and some of them have complex attributes!

    Thanks,

    Matt

  • Just want to make sure you are aware of the "ofd6x" utility shipped with the compiler in the bin directory.   ofd6x can be used to parse .out file into .xml file.  You might be able to parse this .xml file for section information and do sanity check that all sections comply with your constraints.  If you write a utility o check the .out file, then you can catch any new instances of the problem if they crop up.  This would allow you to be conservative about which sections you override and not have to do them all.

  • Karl Wechsler said:
    This would allow you to be conservative about which sections you override and not have to do them all.

    Yeap, that's a good idea. I'll put it in the list of options as we try to improve what I'm currently doing.

    Thanks,

    Matt

  • Karl Wechsler said:
    ofd6x can be used to parse .out file into .xml file.  You might be able to parse this .xml file for section information and do sanity check that all sections comply with your constraints.  If you write a utility o check the .out file, then you can catch any new instances of the problem if they crop up.

    Examples of such utilities, including the Perl source code, can be found here.

    Thanks and regards,

    -George