#
083e035c |
| 07-Dec-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Unify boolean marshalling
Use lambdas with captures to replace the redundant infrastructure for marshalling of two boolean flags that control the same keypath.
Reviewed By: dexonsmith
[clang][cli] Unify boolean marshalling
Use lambdas with captures to replace the redundant infrastructure for marshalling of two boolean flags that control the same keypath.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D92773
show more ...
|
#
6627a3c2 |
| 03-Dec-2020 |
Marek Kurdej <marek.kurdej@gmail.com> |
[c++2b] Add option -std=c++2b to enable support for potential C++2b features.
Reviewed By: rsmith
Differential Revision: https://reviews.llvm.org/D92547
|
#
acb6f80d |
| 25-Nov-2020 |
Yaxun (Sam) Liu <yaxun.liu@amd.com> |
[CUDA][HIP] Fix overloading resolution
This patch implements correct hostness based overloading resolution in isBetterOverloadCandidate.
Based on hostness, if one candidate is emittable whereas the
[CUDA][HIP] Fix overloading resolution
This patch implements correct hostness based overloading resolution in isBetterOverloadCandidate.
Based on hostness, if one candidate is emittable whereas the other candidate is not emittable, the emittable candidate is better.
If both candidates are emittable, or neither is emittable based on hostness, then other rules should be used to determine which is better. This is because hostness based overloading resolution is mostly for determining viability of a function. If two functions are both viable, other factors should take precedence in preference.
If other rules cannot determine which is better, CUDA preference will be used again to determine which is better.
However, correct hostness based overloading resolution requires overloading resolution diagnostics to be deferred, which is not on by default. The rationale is that deferring overloading resolution diagnostics may hide overloading reslolutions issues in header files.
An option -fgpu-exclude-wrong-side-overloads is added, which is off by default.
When -fgpu-exclude-wrong-side-overloads is off, keep the original behavior, that is, exclude wrong side overloads only if there are same side overloads. This may result in incorrect overloading resolution when there are no same side candates, but is sufficient for most CUDA/HIP applications.
When -fgpu-exclude-wrong-side-overloads is on, enable deferring overloading resolution diagnostics and enable correct hostness based overloading resolution, i.e., always exclude wrong side overloads.
Differential Revision: https://reviews.llvm.org/D80450
show more ...
|
#
aafb3662 |
| 25-Nov-2020 |
Arthur Eubanks <aeubanks@google.com> |
Reland [CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/
This allows us to use its value everywhere, rather than just clang. Some other places, like opt and lld, will use its value
Reland [CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/
This allows us to use its value everywhere, rather than just clang. Some other places, like opt and lld, will use its value soon.
Rename it internally to LLVM_ENABLE_NEW_PASS_MANAGER.
The #define for it is now in llvm-config.h.
The initial land accidentally set the value of LLVM_ENABLE_NEW_PASS_MANAGER to the string ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER instead of its value.
Reviewed By: rnk, hans
Differential Revision: https://reviews.llvm.org/D92072
show more ...
|
#
806a76c0 |
| 01-Dec-2020 |
Arthur Eubanks <aeubanks@google.com> |
Revert "[CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/"
The new pass manager was accidentally enabled by default with this change.
This reverts commit a36bd4c90dcca82be9b64f65d
Revert "[CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/"
The new pass manager was accidentally enabled by default with this change.
This reverts commit a36bd4c90dcca82be9b64f65dbd22e921b6485ef.
show more ...
|
#
a36bd4c9 |
| 25-Nov-2020 |
Arthur Eubanks <aeubanks@google.com> |
[CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/
This allows us to use its value everywhere, rather than just clang. Some other places, like opt and lld, will use its value soon.
[CMake][NewPM] Move ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER into llvm/
This allows us to use its value everywhere, rather than just clang. Some other places, like opt and lld, will use its value soon.
The #define for it is now in llvm-config.h.
Reviewed By: rnk, hans
Differential Revision: https://reviews.llvm.org/D92072
show more ...
|
#
398b7292 |
| 01-Dec-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port HeaderSearch option flags to new option parsing system
Depends on D83697.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.
[clang][cli] Port HeaderSearch option flags to new option parsing system
Depends on D83697.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83940
show more ...
|
#
8e41a688 |
| 20-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port DependencyOutput option flags to new option parsing system
Depends on D91861.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.l
[clang][cli] Port DependencyOutput option flags to new option parsing system
Depends on D91861.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83694
show more ...
|
#
2b84efa0 |
| 20-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port Frontend option flags to new option parsing system
Depends on D91861.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/
[clang][cli] Port Frontend option flags to new option parsing system
Depends on D91861.
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83697
show more ...
|
#
88ab3844 |
| 20-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Split DefaultAnyOf into a default value and ImpliedByAnyOf
This makes the options API composable, allows boolean flags to imply non-boolean values and makes the code more logical (IMO).
[clang][cli] Split DefaultAnyOf into a default value and ImpliedByAnyOf
This makes the options API composable, allows boolean flags to imply non-boolean values and makes the code more logical (IMO).
Differential Revision: https://reviews.llvm.org/D91861
show more ...
|
#
97384368 |
| 20-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Factor out call to EXTRACTOR in generateCC1CommandLine (NFC)
Reviewed By: Bigcheese, dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D832
[clang][cli] Factor out call to EXTRACTOR in generateCC1CommandLine (NFC)
Reviewed By: Bigcheese, dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83211
show more ...
|
#
93dc1b5b |
| 17-Nov-2020 |
Wei Wang <apollo.mobility@gmail.com> |
[Remarks][2/2] Expand remarks hotness threshold option support in more tools
This is the #2 of 2 changes that make remarks hotness threshold option available in more tools. The changes also allow th
[Remarks][2/2] Expand remarks hotness threshold option support in more tools
This is the #2 of 2 changes that make remarks hotness threshold option available in more tools. The changes also allow the threshold to sync with hotness threshold from profile summary with special value 'auto'.
This change expands remarks hotness threshold option -fdiagnostics-hotness-threshold in clang and *-remarks-hotness-threshold in other tools to utilize hotness threshold from profile summary.
Remarks hotness filtering relies on several driver options. Table below lists how different options are correlated and affect final remarks outputs:
| profile | hotness | threshold | remarks printed | |---------|---------|-----------|-----------------| | No | No | No | All | | No | No | Yes | None | | No | Yes | No | All | | No | Yes | Yes | None | | Yes | No | No | All | | Yes | No | Yes | None | | Yes | Yes | No | All | | Yes | Yes | Yes | >=threshold |
In the presence of profile summary, it is often more desirable to directly use the hotness threshold from profile summary. The new argument value 'auto' indicates threshold will be synced with hotness threshold from profile summary during compilation. The "auto" threshold relies on the availability of profile summary. In case of missing such information, no remarks will be generated.
Differential Revision: https://reviews.llvm.org/D85808
show more ...
|
#
c083fede |
| 18-Aug-2020 |
Hongtao Yu <hoy@fb.com> |
[CSSPGO] A Clang switch -fpseudo-probe-for-profiling for pseudo-probe instrumentation.
This change introduces a new clang switch `-fpseudo-probe-for-profiling` to enable AutoFDO with pseudo instrume
[CSSPGO] A Clang switch -fpseudo-probe-for-profiling for pseudo-probe instrumentation.
This change introduces a new clang switch `-fpseudo-probe-for-profiling` to enable AutoFDO with pseudo instrumentation. Please refer to https://reviews.llvm.org/D86193 for the whole story.
One implication from pseudo-probe instrumentation is that the profile is now sensitive to CFG changes. We perform the pseudo instrumentation very early in the pre-LTO pipeline, before any CFG transformation. This ensures that the CFG instrumented and annotated is stable and optimization-resilient.
The early instrumentation also allows the inliner to duplicate probes for inlined instances. When a probe along with the other instructions of a callee function are inlined into its caller function, the GUID of the callee function goes with the probe. This allows samples collected on inlined probes to be reported for the original callee function.
Reviewed By: wmi
Differential Revision: https://reviews.llvm.org/D86502
show more ...
|
#
a3258566 |
| 24-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port Target option flags to new option parsing system
Depends on D83697
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83698
|
#
c92f29b0 |
| 24-Nov-2020 |
Zarko Todorovski <zarko@ca.ibm.com> |
[AIX] Add mabi=vec-extabi options to enable the AIX extended and default vector ABIs.
Added support for the options mabi=vec-extabi and mabi=vec-default which are analogous to qvecnvol and qnovecnvo
[AIX] Add mabi=vec-extabi options to enable the AIX extended and default vector ABIs.
Added support for the options mabi=vec-extabi and mabi=vec-default which are analogous to qvecnvol and qnovecnvol when using XL on AIX. The extended Altivec ABI on AIX is enabled using mabi=vec-extabi in clang and vec-extabi in llc.
Reviewed By: Xiangling_L, DiggerLin
Differential Revision: https://reviews.llvm.org/D89684
show more ...
|
#
cb08558c |
| 23-Oct-2020 |
Yaxun (Sam) Liu <yaxun.liu@amd.com> |
[HIP] Fix regressions due to fp contract change
Recently HIP toolchain made a change to use clang instead of opt/llc to do compilation (https://reviews.llvm.org/D81861). The intention is to make HIP
[HIP] Fix regressions due to fp contract change
Recently HIP toolchain made a change to use clang instead of opt/llc to do compilation (https://reviews.llvm.org/D81861). The intention is to make HIP toolchain canonical like other toolchains.
However, this change introduced an unintentional change regarding backend fp fuse option, which caused regressions in some HIP applications.
Basically before the change, HIP toolchain used clang to generate bitcode, then use opt/llc to optimize bitcode and generate ISA. As such, the amdgpu backend takes the default fp fuse mode which is 'Standard'. This mode respect contract flag of fmul/fadd instructions and do not fuse fmul/fadd instructions without contract flag.
However, after the change, HIP toolchain now use clang to generate IR, do optimization, and generate ISA as one process. Now amdgpu backend fp fuse option is determined by -ffp-contract option, which is 'fast' by default. And this -ffp-contract=fast language option is translated to 'Fast' fp fuse option in backend. Suddenly backend starts to fuse fmul/fadd instructions without contract flag.
This causes wrong result for some device library functions, e.g. tan(-1e20), which should return 0.8446, now returns -0.933. What is worse is that since backend with 'Fast' fp fuse option does not respect contract flag, there is no way to use #pragma clang fp contract directive to enforce fp contract requirements.
This patch fixes the regression by introducing a new value 'fast-honor-pragmas' for -ffp-contract and use it for HIP by default. 'fast-honor-pragmas' is equivalent to 'fast' in frontend but let the backend to use 'Standard' fp fuse option. 'fast-honor-pragmas' is useful since 'Fast' fp fuse option in backend does not honor contract flag, it is of little use to HIP applications since all code with #pragma STDC FP_CONTRACT or any IR from a source compiled with -ffp-contract=on is broken.
Differential Revision: https://reviews.llvm.org/D90174
show more ...
|
#
b1444edb |
| 23-Nov-2020 |
Haojian Wu <hokein.wu@gmail.com> |
[AST] Build recovery expression by default for all language.
The dependency mechanism for C has been implemented, and we have rolled out this to all internal users, didn't see crashy issues, we cons
[AST] Build recovery expression by default for all language.
The dependency mechanism for C has been implemented, and we have rolled out this to all internal users, didn't see crashy issues, we consider it is stable enough.
Differential Revision: https://reviews.llvm.org/D89046
show more ...
|
#
15a3ae1a |
| 18-Nov-2020 |
Zequan Wu <zequanwu@google.com> |
[Clang] Add __STDCPP_THREADS__ to standard predefine macros
According to https://eel.is/c++draft/cpp.predefined#2.6, `__STDCPP_THREADS__` is a predefined macro.
Differential Revision: https://revie
[Clang] Add __STDCPP_THREADS__ to standard predefine macros
According to https://eel.is/c++draft/cpp.predefined#2.6, `__STDCPP_THREADS__` is a predefined macro.
Differential Revision: https://reviews.llvm.org/D91747
show more ...
|
#
7a0ea120 |
| 18-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port analyzer flags to new option parsing system
Depends on D83691
Reviewed By: dexonsmith
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83693
|
#
1e6fc2fa |
| 18-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Port Migrator option flags to new option parsing system
Depends on D83406
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D8
[clang][cli] Port Migrator option flags to new option parsing system
Depends on D83406
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83690
show more ...
|
#
5e696d89 |
| 16-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Remove NormalizerRetTy and use the decltype of the KeyPath instead
Depends on D83315
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.
[clang][cli] Remove NormalizerRetTy and use the decltype of the KeyPath instead
Depends on D83315
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83406
show more ...
|
#
05eeda97 |
| 16-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Turn arcmt-* options into a single option
- The new option, -arcmt-action, is a simple enum based option. - The driver is modified to translate the existing -ccc-acmt-* options accordin
[clang][cli] Turn arcmt-* options into a single option
- The new option, -arcmt-action, is a simple enum based option. - The driver is modified to translate the existing -ccc-acmt-* options accordingly Depends on D83298
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83315
show more ...
|
#
2be56987 |
| 16-Nov-2020 |
Jan Svoboda <jan_svoboda@apple.com> |
[clang][cli] Add ability to make fixups to CompilerInvocation after option parsing
Depends on D83211
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://revie
[clang][cli] Add ability to make fixups to CompilerInvocation after option parsing
Depends on D83211
Reviewed By: Bigcheese
Original patch by Daniel Grumberg.
Differential Revision: https://reviews.llvm.org/D83298
show more ...
|
#
6a89cb81 |
| 18-Nov-2020 |
Artem Dergachev <artem.dergachev@gmail.com> |
Revert "Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis."""
This reverts commit 41bcc05e2a4e3062eb12ac6e071bc835decc38f5.
|
#
41bcc05e |
| 16-Nov-2020 |
Artem Dergachev <artem.dergachev@gmail.com> |
Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis.""
This reverts commit 77bb3ebebbca13f0648beb433fbd1b06ba95a19c.
|