The /PACKF Option

Option

/PACKF[[UNCTIONS]]

The /PACKF option removes unreferenced “packaged functions.” This behavior is the default. However, if an environment variable (such as LINK or CL) includes the /NOPACKF option, you can use /PACKF to override /NOPACKF.

A packaged function is visible to the linker in the form of a COMDAT record. Packaged functions are created when you use the /Gy option on the CL command line (or, in PWB, when you choose Enable Function Level Linking in the Additional Global Options dialog box, which is available from the C or C++ Compiler Options dialog boxes). Member functions in a C++ program are automatically packaged.

If a packaged function is defined but not called, this option removes the function definition from the executable file. /PACKF is not recursive; LINK does not remove any external definitions brought in by the unused packaged function.