ARM Technical Support Knowledge Articles

WARNING 16 (UNCALLED SEGMENT, IGNORED FOR OVERLAY ...)

Applies to: BL51 Code-banking Linker/Locator

Answer


Information in this article applies to:


QUESTION

When I build my project, the linker generates a warning:

Warning L16: UNCALLED SEGMENT - IGNORED FOR OVERLAY PROCESS

with a segment name ?CO?modulename. I have a source file called modulename.c, but how can I tell which function is not being called?

ANSWER

The ?CO? that was prepended to the modulename indicates that the segment is a "CO"nstant data segment, not a code segment - thus, the warning is referring to any global constant data declared in MODULENAME.C. Likely culprits are arrays or tables declared with a "CODE" memory class, such as

code unsigned char bob[] = "This string is located in code space.";

The warning in this case is insignificant and can be ignored. However, the linker doesn't know that and generates this warning everytime that you build your project. The best solution to this problem is to insert a reference to this constant data somewhere in your code to make the linker happy. For example:

unsigned char x = bob[0];

eliminates the warning in this case.

MORE INFORMATION

SEE ALSO

Article last edited on: 2007-11-16 15:34:11

Rate this article

[Bad]
|
|
[Good]
Disagree? Move your mouse over the bar and click

Did you find this article helpful? Yes No

How can we improve this article?

Link to this article
Copyright © 2011 ARM Limited. All rights reserved. External (Open), Non-Confidential