Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-28 Thread Kinney, Michael D
found. > > > > Other opinions? > > > > Thanks, > > > > Mike > > > > > > > -Original Message- > > > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of > > > Felix > Poludov > > > S

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Gao, Liming
ro to global > > > variable declarations is a manual process that usually requires > > > inspection of PE/COFF images to notice that data that should have been > > > optimized > > away is still present. > > > > > > Adding the #ifndef also looks like

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Kinney, Michael D
optimized > away is still present. > > > > Adding the #ifndef also looks like a good way to adopt the /Gw switch > > in newer VS Compilers and preserve backwards compatibility with older VS > > compilers. > > > > Thanks, > > > > Mike > > >

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Felix Poludov
v > > Sent: Monday, March 27, 2017 7:59 AM > > To: Gao, Liming <liming@intel.com>; edk2-devel@lists.01.org > > Subject: Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply > > defined symbols, and MSFT/GCC tool chains. > > > > Liming, > > > >

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Kinney, Michael D
l-boun...@lists.01.org] On Behalf Of > > Felix Poludov > > Sent: Monday, March 27, 2017 7:59 AM > > To: Gao, Liming <liming@intel.com>; edk2-devel@lists.01.org > > Subject: Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply > > defined symbols, and MS

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Felix Poludov
o:edk2-devel-boun...@lists.01.org] On Behalf Of > Felix Poludov > Sent: Monday, March 27, 2017 7:59 AM > To: Gao, Liming <liming@intel.com>; edk2-devel@lists.01.org > Subject: Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply > defined symbols, and MSFT/GCC tool ch

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Andrew Fish
h older VS compilers. > > Thanks, > > Mike > > >> -Original Message- >> From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Felix >> Poludov >> Sent: Monday, March 27, 2017 7:59 AM >> To: Gao, Liming <liming....@intel.com>;

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Kinney, Michael D
.@intel.com>; edk2-devel@lists.01.org > Subject: Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined > symbols, and > MSFT/GCC tool chains. > > Liming, > > Yes surrounding GLOBAL_REMOVE_IF_UNREFERENCED with #ifndef would be an > improvement. > Can you mak

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-27 Thread Felix Poludov
Liming, Yes surrounding GLOBAL_REMOVE_IF_UNREFERENCED with #ifndef would be an improvement. Can you make this change? On the other note, don't you think that EDKII should have a generic policy regarding multiply defined symbols (whether they are allowed or not)? Today, they may or may not work

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-26 Thread Gao, Liming
Felix: This changes the default MSFT build behavior. It will impact all platforms even if this platform has no requirement to pass GCC build. I suggest to update platform DSC to enable it in MSFT tool chain if this platform needs to support MSFT and GCC both. In Base.h: I agree to define

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-24 Thread Felix Poludov
> -Original Message- > From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] > Sent: Friday, March 24, 2017 1:32 PM > To: Felix Poludov > Cc: edk2-devel@lists.01.org > Subject: Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply > defined symbols, and

Re: [edk2] [RFC] GLOBAL_REMOVE_IF_UNREFERENCED, multiply defined symbols, and MSFT/GCC tool chains.

2017-03-24 Thread Ard Biesheuvel
On 24 March 2017 at 12:53, Felix Poludov wrote: > Trying to add GCC support to projects based on MSFT tool chain, I'm keep > stumbling into multiply defined symbol errors reported by GCC linker. > An attempt to understand why the errors are not reported by the Microsoft > linker