Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 324917

Summary: Enable metaonly modules to declare generated fxns to avoid removal from configuro whole_program optimization
Product: [Technology] RTSC Reporter: Chris Ring <cring>
Component: CoreAssignee: Dave Russo <d-russo>
Status: RESOLVED WONTFIX QA Contact:
Severity: enhancement    
Priority: P3 CC: dfriedland
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: All   
Whiteboard: target:3.30

Description Chris Ring CLA 2010-09-09 20:21:01 EDT
If a metaonly module contributes a template (via @Template) for the generated C file, and that template generates a fxn, and the configuro flow is used on a TI target, _and_ a whole_program profile is used <phew!>, the fxn will be optimized out of the pre-linked library.  When that prelinked lib is linked into an app, the generated fxns won't be there when someone (like the app) tries to call them, and a linker error will result.

TI toolchains provide a #pragma FUNC_EXT_CALLED() to keep a fxn even though there are no external references to it.  If the metaonly module declares these 'extern fxns' in the .xdc file, XDC could use this pragma to keep these fxns in the pre-linked lib.
Comment 1 Dave Russo CLA 2014-01-22 17:32:25 EST
whole program support has been deferred indefinitely and when it comes back there may be better way to create "partial links" of libraries.