On 04.05.22 17:12, Jakub Jelinek via Gcc-patches wrote:
Though, there is one gotcha, if we had code where we parsed some var first and another one later and there was interdependence between the two, in environ they can appear in any order.
I think for interdependence it depends whether in a first step, only a flag or the string is stored or whether the data is fully evaluated. Especially for some 'global' entries, storing pointer to the string and evaluating it later makes sense. In some cases, evaluation the values (e.g. convert to integer) could be done early while checking the range could be done later. – In any case, OMP_DISPLAY_ENV needs to be handled last – but it can be parsed early (e.g. by setting a simple flag). Tobias PS: For completeness, I want to point out that in the current nonpublic draft (will show up as TR11 or OpenMP 6.0, I guess), some fixes related to one ICV (default-device-var → global; issue #2740) and to the _DEV rules (priority of variants, _all, fine-print, cleanup; PR #3175) was done. Those clarifications were found and discussed while the patch was written and, hence, are incorporated and should be nonsurprising. PPS: An example of an ICV which has to be evaluated before another is the to-be-added available-devices-icv that surely have to be evaluated before default-device-icv (→PR #3198; useful, fancy & overengeneered). But that one is surely not a GCC 13 topic. ----------------- Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht München, HRB 106955