[PATCH] D126341: Order implicitly instantiated global variable's initializer by the reverse instantiation order

Yuanfang Chen via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 25 10:45:46 PDT 2022


ychen added a comment.

In D126341#3537675 <https://reviews.llvm.org/D126341#3537675>, @aaron.ballman wrote:

> Adding the language WG as a reviewer in case others have opinions.
>
>> The underlying problem is basically wg21.link/cwg362 which has no concensus yet.
>
> According to https://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#362 this was resolved in CD1 and we track it as being not applicable to us (https://clang.llvm.org/cxx_dr_status.html#362). (Is our status actually correct for this?)
>
>> Will the reviewers be supportive if I make the original cwg362 test case work too?
>
> To me, it depends on what it does to compile times and memory overhead for the compiler when run on large projects. If the extra tracking is cheap and doesn't really impact anything, I think it's reasonable to want to match GCC's behavior. If it turns out this is expensive, I'm less keen on matching GCC.

Thanks for the opinion @aaron.ballman. I think the cost would be low. I'll get back with some numbers.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D126341



More information about the cfe-commits mailing list