IAR Information Center for Microchip AVR

Recent manual updates for IAR XLINK version 6.6.1.103

This document is a supplement to the XLINK Release Notes, and contains recent changes to the XLINK manual. Each section or sub-section is marked with the XLINK version of its most recent change. No attempt is made to represent a history of changes in this file. It documents only the current state of affairs.

If you are using XLINK in the Embedded Workbench integrated development environment, you may need a newer version of the Embedded Workbench for the relevant target in order to take full advantage of recently added features.

Added output formats

IEEE-695 details

XCOFF78K details

Checksums and fillers (-H -J -h)

Revised segment placement

ELF details

Address expressions

UBROF versions

Address translation

COFF details

Scatter loading (-Q)

Diagnostics control (-w)

Relocation areas (-V)

Range errors

Address space sharing (-U)

Stack Usage Analysis (--enable_stack_usage)

MISRA C

New diagnostics

New errors

New warnings

  • 6.4.0.80 - Introduced

       83 Segment part number label information in the
          module module description contains stack usage
          information despite being empty. Empty segment parts cannot
          affect the stack depth so the information will be ignored.
    
    The stack usage in the specified segment part will be ignored. If the file was compiler generated this should be considered to be erroneous output (equivalent to incorrect stack usage information). If the file was produced from assembler source code the code should be rewritten (typically the empty segment part should be merged with the immediately succeeding segment part).

  • 6.3.3.4 - Introduced

       80 Modules have different stack names for index index
          The module "module" uses "stack name", and the module
          "module" uses "stack name"
    
    The name and indicies of all involved stacks must match accross all involved modules. No stack usage information is reliable in this case as the information potentially can use an incorrect stack index. This is most likely a compiler error and should be reported as a problem.

       79 [stack usage analysis] The segment part number in
          module module contains incorrect stack usage
          information. The caller name is invalid.
    
    The stack usage information for the function in the specified segment part is corrupt (the name is not available so no information from the function will be used). If the module was assembler generated there is probably a problem with the name of the function. If the module was compiler generated this is an error and should be reported as a problem.

       78 [stack usage analysis] The function function is defined
          in both the application and the .suc file. Use the override
          keyword, remove the function directive from the .suc-file or
          remove the function from the application.
    
    Use the override keyword or remove the function directive.

       77 [stack usage analysis] The module module (file)
          has references to some functons that are not listed as being
          called in the stack usage control file: file
    
    There are functions that are not listed as being called in the .suc-file. Update the .suc-file with the relevant information or rewrite the referring code in the module(s) in question to remove the calls to the code for which there is no information.

  • 5.3.0.22 - Introduced

       76 The checksum command checksum_command contains more than
          one specification of checksum unit size. You should use a single W
          or L flag.
    
    The specified checksum command cannot have both a W and an L flag.

  • 5.0.2.5 - Introduced

       75 The program does not contain any content. If this is not the intent
          use the content control linker options (-g and -s) or make content
          __root to ensure that it is included.
    
    The link job resulted in a completely empty program. XLINK will remove all content that is not referenced and in this case there were no references to the program.

    References can be specified on the command line through the -g option (for any symbol) or -s (for the start symbol of the program).

    It is also possible to specify that a certain function or variable should always be present in the program by making it __root (in C with the IAR extensions enabled).

    A program usually contains something (like an interrupt table) that is always included (made root or referenced through -g or -s) which in turns refers to the startup code which in turn refers to main which in turn refers to the rest of the program.

  • 4.61S - Introduced

       74 The checksum polynomial polynomial is unsuitable for use
          with the bytewise initial value #initial value as the
          polynomial can not always generate a bitwise equivalent for the
          bytewise initial value. Use a bitwise initial value or use a
          polynomial with the least significant bit set.
    
    The specified polynomial does not have its least significant bit set. When the least significant bit is not set it is not always possible to convert a bytewise initial value into a bitwise initial value. This has no real effect on the checksum that XLINK generates but it can matter in cases where the verification step uses bitwise initial values. As some bytewise initial values lack a corresponding bitwise initial value for this polynomial it can prove impossible to get the checksums to match.

  • 4.61P - Introduced

       73 Total number of warnings for unsupported line numbers: number
          of warnings
    
    This warning is tightly coupled to warning 72 (see below). It is mainly intended for the case that you have many (hundreds) functions that reside on line numbers that can't be represented in the chosen output format and do not want to list them all in every link job (so you suppress warning 72) but still want to know if the number of warnings change.

       72 The 'format' output format does not support line numbers above
          number. All line numbers above this limit will be set to
          number. Source information for such functions will not be
          available. This will affect the following functions: list of
          function names, their segment part numbers, in which module and
          file they were defined
    
    The chosen output format can not represent line numbers as great as the ones in the specified files. You have three options, choose a different output format, edit the source code file(s) so that no function that you wish to debug resides on line number above the specifed limit (move the function or split the file into two or more smaller files), or accept that you won't be able to debug the specified functions on the C-level (assembly level debugging and variable information will still be available).

  • 4.61O - Introduced

       71 Use of the -! comment is deprecated. Recognition of -! will
          eventually be removed from XLINK.
    
    Use "// comment" or "/* comment */" instead of "-! comment -!"
  • 4.61L - Introduced

       70 The segment "segment" on address address overlaps
          previous content in the raw-binary output file. The previously
          content will be overwritten.
    
    The program contains at least one overlap between segments with content. Use the overlap diagnostics to locate and correct those overlaps.
  • 4.61I - Introduced

       69 Address translation (-M, -b# or -b@) has no effect on the output
          format 'format'.  The output file will be generated but
          no address translation will be performed.
    
    Address translation is not supported for the format output format. Output files in the format output format will be generated without address translation but output files in a format for which address translation is supported will use translated addresses.
  • 4.61G - Introduced

       68 The option to ignore overlaps in SFR-areas has been specified
          but the `processor` processor does not have an
          SFR-area. The option has no effect for this processor.
    
    The processor you are using does not have a dedicated SFR-area (an address range in an address space that can only contain SFR:s). You can not use the -zs option to suppress segment overlap errors when using this processor.
  • 4.61F - Updated

       23 limitation specific warning
    
    Due to some limitation in the chosen output format, or in the debug information available, XLINK cannot produce correct debug output for this program. This only affects the debug information; the generated code remains the same as in an output format where the debug information can be expressed. Only one warning for each specific limitation is given.
  • 4.61A - Updated

       20 The absolute segment on the address address range in the module
          module (file) overlaps the segment segment name
          (from module module, address [address range])
    
    An absolute segment overlaps a relocatable segment. You need to move either the absolute segment or the relocatable segment. You move absolute segments by modifying the source code. You move relocatable segments by modifying the segment placement command.
       21 The absolute segment on the address address range in the module
          module (file) overlaps the absolute segment on the address
          address range in the module module (file)
    
    Two absolute segments overlap. You need to move at least one of them. You move absolute segments by modifying the source code.
  • 4.60D - Introduced

       67 Using "-r" causes XLINK to select modules that are adapted for
          use with the C-SPY debugger. This affects all output files, including
          those generated by -O.
    
    The command line option -r has two effects. It causes XLINK to select modules from the IAR standard library designed to work with the IAR C-Spy debugger and makes XLINK use the IAR UBROF object format for its main output file. The first of these also changes the contents of any extra output files produced by the use of the -O command line option. Depending on the circumstances, this may not be what you want. If you need extra output files not meant for use with the IAR C-Spy debugger, you need to run XLINK separately, without the -r command line option.
  • 4.60B - Introduced

       66 There is a gap between the addresses address and address.
          This gap of gap size bytes will be padded with zeroes. Raw-binary
          might not be the format you want for this particular image.
    
    There is a huge "hole" in the image. This might result in an unnecessarily large file. A format that uses address records (like intel-extended, motorola or simple-code) might be a better choice for this particular image.
  • 4.59U - Introduced

       65 There are both MULTWEAK and PUBWEAK definitions for the symbol named
          "name". This does not work in the general case. PUBWEAK
          definitions occur in the module(s) modules. MULTWEAK definitions
          occur in the module(s) modules.
    
    MULTWEAK definitions were introduced for purposes of ARM/Thumb Relay Function Optimization in ICCARM 3.41. PUBWEAK definitions were used for the same purposes in earlier versions of the ICCARM. In order to avoid this problem ensure that all modules are built for use with the same Relay Function model.

  • 4.59R - Introduced

       64 The address space used in the command segment placement
          command is incompatible with the address space of the
          ranges 'ranges' that were inherited from previous
          placements. Address ranges can only be inherited from
          compatible address spaces.
    
    Addresses should not be inherited from previous placement commands if those previous placement commands placed segments in an incompatible address space. This was sometimes used in older IAR tools to make sure that segments in placed in overlapping address spaces did not overlap each other. Since the introduction of the -U option in XLINK 4.56B that is no longer necessary, so inheriting from incompatible address spaces is now deprecated.
  • 4.59L - Introduced

       63 No debug information will be generated for the function
          "function" in the module "module" as no debug
          information could be found.
    
    This likely due to a rename entry operation in XLIB.

  • 4.59K - Introduced

       62 The struct "name" is too large for the 'format'
          format, debug information will only be available for the
          first maxium size bytes.
    
    The program contains a class/struct/union that is too large to represent in the chosen debug format. Debug information will be generated for as many bytes as the format can represent.

       61 The 'format' output format is not supported for this cpu.
    
    Support for the chosen output format is experimental for this cpu.

       60 The entry point label "label" was not found in any input file
          The image will not have an entry point.
    
    The chosen entry point label could not be found in any input file. Chose an entry point that exists in the program or make sure that that the file that contains the entry pointed is included in the input files.

  • 4.56H - Introduced

        59 Too many COFF format line number records (number) needed. All
           in excess of 65535 will not be accessible.
    
           There are too many line number records in one COFF
           section. This can cause a drastic loss of debugging usability
           if the number of records greatly exceeds 65535.
    
           One way to avoid this is to put code in more than one segment,
           as one COFF section is output for each segment.
    
           This problem is most likely to occur in the MPLAB debugger for
           the PIC processor, as one line number records is needed for
           each instruction in the code in that case.
        
        58 The name "name" was too long (more than number characters)
           and has been truncated to fit the chosen output format.
           This warning is only issued once.
    
           Normally, this will not affect debugging to any great extend,
           but if two or more long names are truncated to the same
           255-character string, a loss of debuggability may occur.
    
           The most common case where long names occur is when C++ names
           are flattened into simple strings, which occurs when
           translating into UBROF version 7 or older, or into other debug
           formats with a limit on symbol name length.
    
  • 4.55G

       57 The file filename is empty and will be ignored.
    
          The file is completely empty (0 bytes). This is not a valid UBROF file
          but some IAR assemblers generate completely empty files instead of
          a valid UBROF file with no content. This file will be ignored. If this
          file is not generated by an IAR assembler you should find out why the
          file is empty.
    
  • 4.52A

       56 A long filename may cause MPLAB to fail to display the source
          file: 'pathname'
    
          When outputting COFF output for the PIC and PIC18 processors on
          a Windows host the output file contains a reference to a source
          file that needs long filenames in order to work. MPLAB cannot
          handle long filenames.
    
       55 No source level debug information will be generated for modules
          using the UBROF object format version 8 or earlier. One such
          module is module ( file )
    
          When generating UBROF 9 output, essential debug information is
          not present in input files using UBROF 8 or earlier. For these
          files all debug information will be suppressed in the output
          file.
    
  • 4.51S

    The warning about long filenames (warning 56) is warning 55 in XLINK 4.51S and XLINK 4.51T.

  • 4.51E

       53 Some untranslated addresses overlap translation ranges. Example:
          Address addr1 (untranslated) conflicts with logical address
          addr2 (translated to addr1)
    
          This can be caused by something like this:
    
            -Z(CODE)SEG1=1000-1FFF
            -Z(CODE)SEG2=2000-2FFF
            -M(CODE)1000=2000
    
          This will place SEG1 at logical address 1000 and SEG2 at logical
          address 2000. However, the translation of logical address 1000
          to physical address 2000 and the absence of any translation for
          logical address 1000 will mean that in the output file, both
          SEG1 and SEG2 will appear at physical address 1000.
    
  • 4.51D

       52 More than one definition for the byte at address address in
          common segment segment
    
          The most probable cause of this is that more than one module
          defines the same interrupt vector.
    
       51 Some source reference debug info was lost when translating to
          UBROF 5 (example: statements in "function" in module module)
    
          UBROF 6 file references can handle source code in more than one
          source file for a module. This is not possible in UBROF 5
          embedded source, so any references to files not included have
          been removed.
    
       50 There was a problem when trying to embed the source file "source"
          in the object file
    
          This warning is given if the file source could not be found or
          if there was an error reading from it. XLINK searches for source
          files in the same places it searches for object files, so
          including the directory where the source file is located in the
          XLINK include directories ("-I" command line option) could solve
          the first problem.
    
  • 4.51A

       49 Using SFB/SFE in module module ( file ) for segment
          segment, which has no included segment parts
    
          SFB/SFE (assembler directives for getting the start or end of a
          segment) has been used on a segment for which no segment parts
          were included.
    
       48 Corrupt input file: "symptom" in module module ( file )
    
          The input file indicated appears to be corrupt. This warning is
          used in preference to Error 113 when the problem is not serious,
          and is unlikely to cause trouble.
    
  • 4.50A

       47 Range error in module module ( file ), segment segment at
          address address. Value value, in tag tag, is out of bounds
          bounds
    
          This replaces error 18 when -Rw is specified.
    
       46 External function function in module module ( file ) has
          no global definition
    
          This replaces error 68.
    
       45 Memory attribute info mismatch between modules module1 (
          file1 ) and module2 ( file2 )
    
          The UBROF 7 memory attribute information in the given modules is
          not the same.
    
  • 4.49E

       44 C library routine localtime failed. Timestamps will be wrong
    
          XLINK is unable to determine the correct time. This primarily
          affects the dates in the list file. This problem has been
          observed on one host platform if the date is after the year
          2038.
    
  • 4.49C

       43 The function function in module module ( file ) is
          indirectly called but is not mentioned in the right part of any
          -a# declaration
    
          If any -a# indirect call options are given they must, taken
          together, specify the complete picture.
    
       41 The function function in module module ( file ) makes
          indirect calls but is not mentioned in the left part of any -a#
          declaration
    
          If any -a# indirect call options are given they must, taken
          together, specify the complete picture.
    
       40 The module module contains obsolete type information that will
          not be checked by the linker
    
          This kind of type information was replaced in 1988.
    
       39 The function function in module module ( file ) does not
          appear to be called. No static overlay area will be allocated
          for its params and locals
    
          As far as XLINK can tell, there are no callers for the function,
          so no space is needed for its params and locals. To make XLINK
          allocate space anyway use -a(function).
    
       38 There are indirect calls both from interrupts and from the main
          program. This can make the static overlay system
          unreliable. Using -ai will avoid this
    
          If a function is called from an interrupt while it is already
          running its params and locals will be overwritten.
    
       37 More than one interrupt function makes indirect calls. This can
          make the static overlay system unreliable. Using -ai will avoid
          this
    
          If a function is called from an interrupt while it is already
          running its params and locals will be overwritten.
    
       36 There are indirectly called functions doing indirect calls. This
          can make the static overlay system unreliable
    
          XLINK does not know what functions can call what functions in
          this case, which means that it cannot make sure static overlays
          are safe.
    
  • 4.48J

       35 There is more than one definition for the struct/union type with
          tag tag
    
          Two or more different structure/union types with the same tag
          exist in the program. If these types were meant to be the same,
          it is likely that the declarations differ slightly. There will
          then also very likely be one or more warnings about type
          conflicts (warning 6). If they were not meant to be the same,
          consider turning off this warning.
    
       34 The 20 bit segmented variant of the INTEL EXTENDED format cannot
          represent the addresses specified. Consider using -Y1 (32 bit
          linear addressing).
    
          The program uses addresses higher than 0xFFFFF, and the
          segmented variant of the chosen format cannot handle this. The
          linear addressing variant can handle full 32 bit addresses.
    
       33 Using "-r" overrides format option. Using UBROF
    
          The "-r" option specifies UBROF format and C-SPY library
          modules. It overrides any "-F" (format) option
    
       32 Format option set more than once. Using format format
    
          The format option can only be given once. The linker uses the
          format format.
    
  • 4.48G

       31 Modules have been compiled with possibly incompatible settings:
          more info
    
          According to the contents of the modules, they are not
          compatible.
    
       30 Module name is compiled for cpu1, expected cpu2
    
          You are building an executable for cpu cpu2, but module name
          is compiled for cpu cpu1.
    
       29 Parts of segment name are inited, even though it is of type
          type
    
          Initing DATA memory is not useful if the result of linking is to
          be promable.
    
       28 Parts of segment name are inited, parts not
    
          This is not useful if the result of linking is to be promable.
    
       27 No code at start address found in reset vector
    
          Failed in determining the LOCATION setting for XCOFF output
          format for the 78400 processor, because no code was found at the
          address specified in the reset vector.
    
       26 No reset vector found
    
          Failed in determining the LOCATION setting for XCOFF output
          format for the 78400 processor, because no reset vector was
          found.
    
       25 Using "-Y#" discards and distorts debug information. Use with
          care. If possible, find an updated debugger that can read modern
          UBROF
    
          Using the UBROF format modifier -Y# is not recommended.
    
       24 num counts of 'warning' total
    
          For each warning of type 23 actually emitted, a summary is
          provided at the end.
    

    Log of minor changes