[flang-commits] [PATCH] D85937: [flang][msvc] Split class declaration and constexpr variable definition. NFC.

Peter Klausler via Phabricator via flang-commits flang-commits at lists.llvm.org
Fri Aug 14 15:42:50 PDT 2020


klausler added a comment.

In D85937#2219151 <https://reviews.llvm.org/D85937#2219151>, @DavidTruby wrote:

> In D85937#2219052 <https://reviews.llvm.org/D85937#2219052>, @Meinersbur wrote:
>
>> In D85937#2219028 <https://reviews.llvm.org/D85937#2219028>, @klausler wrote:
>>
>>> You might have to use conditional preprocessing to make this workaround specific to MSVC.
>>
>> The workaround is valid C++ and works fine with every compiler. So why add a #if maze?
>
> I also believe it will generate exactly the same code. There's no functional difference between the new proposal and the old code as far as the standard is concerned. I agree that preprocessor changes aren't necessary here.

Until somebody compiles the changed code with a real compiler and measures no significant difference in performance, we don't know that there isn't one.  (I'd be surprised as well if there were a difference in this case, of course, but the parser is quite the stressful case for C++ compilers and some innocuous-looking changes have turned out to matter.)  Is anybody benchmarking the effects of Michael's unconditional workarounds in f18's performance, or planning to do so?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85937/new/

https://reviews.llvm.org/D85937



More information about the flang-commits mailing list