ARM Technical Support Knowledge Articles

REMOVING LINKER WARNING L16 (UNCALLED SEGMENT)

Applies to: C51 C Compiler

Answer


Information in this article applies to:


QUESTION

I have some unused functions in my program which generate linker warnings. Because the functions enterdata and myfunc are not used, the following warning is generated:

*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
    SEGMENT: ?PR?ENTERDATA?X

*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
    SEGMENT: ?PR?MYFUNC?X

I know that the data overlaying is incomplete and might be inefficient, but is there some way to remove these linker warnings?

ANSWER

Yes, you may use the linker overlay directive. This directive allows you to add dummy calls and the linker thinks that the function is called. The following command removes the linker warnings:

OVERLAY (* ! (enterdata, myfunc))

uVision allows you to enter the OVERLAY directive under Project - Options for Target - Lx51 Misc - Overlay:

* ! (enterdata, myfunc)

MORE INFORMATION

SEE ALSO

Article last edited on: 2006-01-31 18:19:27

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