Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » Incorrect implementation of INITBLOCK (and similar macros) in case when flagBLITZ is not defined.
Re: Incorrect implementation of INITBLOCK (and similar macros) in case when flagBLITZ is not defined [message #31813 is a reply to message #31811] Tue, 29 March 2011 14:59 Go to previous messageGo to previous message
kohait00 is currently offline  kohait00
Messages: 939
Registered: July 2009
Location: Germany
Experienced Contributor
thanks mirek, for the hint.

searched a bit in forum, seems i found sth related. please verify, this might / should go to documentation.

i've got some custom init code in a package, packed into a INITBLOCK, this all resides in a cpp file with appearently no referencing from other code, simple global/static init code.

did work with BLITZ, on both MSC and GCC in debug compile however in release, MSC didnt work, since i had to turn off BLITZ. with gcc it also only works with BLITZ enabled. so turning off BLITZ may possibly break INITBLOCK sections in one's app.

solution: i renamed the cpp file with the INITBLOCK code into .icpp file and woops, it works in MSC optimal without blitz. this assures the cpp file wont get kicked out by linker, since its code is not referenced by anything from another code section in app.

is this a general behaviour? can it be considered rule of thumb to rename the INITBLOCK containing cpp file to icpp file, if there is nothing in the file which will guarantee it's presence in linker later, like i.e. referenced code. if so, maybe this should be outlined somewhere in the docu

hints in: http://www.ultimatepp.org/forum/index.php?t=msg&goto=811 8&

[Updated on: Tue, 29 March 2011 15:28]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: why not "T & Add(const T & x)" in all containers
Next Topic: ADDs: ValueMap
Goto Forum:
  


Current Time: Thu Oct 31 23:47:57 CET 2024

Total time taken to generate the page: 0.02167 seconds