summaryrefslogtreecommitdiffstats
path: root/contrib/libs/llvm12/include
diff options
context:
space:
mode:
authormonster <[email protected]>2022-07-07 14:41:37 +0300
committermonster <[email protected]>2022-07-07 14:41:37 +0300
commit06e5c21a835c0e923506c4ff27929f34e00761c2 (patch)
tree75efcbc6854ef9bd476eb8bf00cc5c900da436a2 /contrib/libs/llvm12/include
parent03f024c4412e3aa613bb543cf1660176320ba8f4 (diff)
fix ya.make
Diffstat (limited to 'contrib/libs/llvm12/include')
-rw-r--r--contrib/libs/llvm12/include/.yandex_meta/licenses.list.txt458
-rw-r--r--contrib/libs/llvm12/include/llvm-c/module.modulemap4
-rw-r--r--contrib/libs/llvm12/include/llvm/ADT/ImmutableList.h257
-rw-r--r--contrib/libs/llvm12/include/llvm/ADT/ImmutableMap.h377
-rw-r--r--contrib/libs/llvm12/include/llvm/ADT/ImmutableSet.h1195
-rw-r--r--contrib/libs/llvm12/include/llvm/ADT/TypeSwitch.h187
-rw-r--r--contrib/libs/llvm12/include/llvm/ADT/Waymarking.h336
-rw-r--r--contrib/libs/llvm12/include/llvm/Bitcode/BitcodeConvenience.h497
-rw-r--r--contrib/libs/llvm12/include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h83
-rw-r--r--contrib/libs/llvm12/include/llvm/CodeGen/MachORelocation.h66
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/AsmParsers.def.in29
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/AsmPrinters.def.in29
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/Disassemblers.def.in29
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/Targets.def.in28
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/abi-breaking.h.cmake62
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/config.h.cmake353
-rw-r--r--contrib/libs/llvm12/include/llvm/Config/llvm-config.h.cmake97
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/FunctionId.h66
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h46
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIADataStream.h44
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h47
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumFrameData.h46
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumInjectedSources.h46
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumLineNumbers.h46
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSectionContribs.h49
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSourceFiles.h48
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSymbols.h48
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumTables.h46
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAError.h61
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAFrameData.h49
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAInjectedSource.h48
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIALineNumber.h50
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIARawSymbol.h244
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASectionContrib.h65
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASession.h104
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASourceFile.h51
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASupport.h44
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIATable.h42
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAUtils.h41
-rw-r--r--contrib/libs/llvm12/include/llvm/DebugInfo/PDB/Native/Formatters.h55
-rw-r--r--contrib/libs/llvm12/include/llvm/ExecutionEngine/OProfileWrapper.h134
-rw-r--r--contrib/libs/llvm12/include/llvm/ExecutionEngine/OrcMCJITReplacement.h48
-rw-r--r--contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMP.inc3507
-rw-r--r--contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMPGridValues.h142
-rw-r--r--contrib/libs/llvm12/include/llvm/IR/FixedPointBuilder.h476
-rw-r--r--contrib/libs/llvm12/include/llvm/IR/MatrixBuilder.h247
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/AMDHSAKernelDescriptor.h223
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/Base64.h67
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/Capacity.h42
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/Solaris/sys/regset.h49
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/TaskQueue.h149
-rw-r--r--contrib/libs/llvm12/include/llvm/Support/raw_sha1_ostream.h57
-rw-r--r--contrib/libs/llvm12/include/llvm/TableGen/Automaton.td95
-rw-r--r--contrib/libs/llvm12/include/llvm/Testing/Support/Annotations.h103
-rw-r--r--contrib/libs/llvm12/include/llvm/Testing/Support/Error.h217
-rw-r--r--contrib/libs/llvm12/include/llvm/Testing/Support/SupportHelpers.h259
-rw-r--r--contrib/libs/llvm12/include/llvm/WindowsResource/ResourceProcessor.h61
-rw-r--r--contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptToken.h69
-rw-r--r--contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptTokenList.h45
-rw-r--r--contrib/libs/llvm12/include/llvm/XRay/FDRLogBuilder.h51
-rw-r--r--contrib/libs/llvm12/include/llvm/module.extern.modulemap5
-rw-r--r--contrib/libs/llvm12/include/llvm/module.modulemap436
-rw-r--r--contrib/libs/llvm12/include/llvm/module.modulemap.build13
63 files changed, 0 insertions, 11968 deletions
diff --git a/contrib/libs/llvm12/include/.yandex_meta/licenses.list.txt b/contrib/libs/llvm12/include/.yandex_meta/licenses.list.txt
deleted file mode 100644
index 478e11b1f33..00000000000
--- a/contrib/libs/llvm12/include/.yandex_meta/licenses.list.txt
+++ /dev/null
@@ -1,458 +0,0 @@
-====================Apache-2.0 WITH LLVM-exception====================
- * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
- * See https://llvm.org/LICENSE.txt for license information.
-
-
-====================Apache-2.0 WITH LLVM-exception====================
- * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-/* Part of the LLVM Project, under the Apache License v2.0 with LLVM */
-/* Exceptions. */
-/* See https://llvm.org/LICENSE.txt for license information. */
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-/* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception */
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-/// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-/// See https://llvm.org/LICENSE.txt for license information.
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-/// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
-|* Exceptions. *|
-|* See https://llvm.org/LICENSE.txt for license information. *|
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-|* See https://llvm.org/LICENSE.txt for license information.
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-
-
-====================Apache-2.0 WITH LLVM-exception====================
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
-
-
-====================BSD-2-Clause====================
- BSD 2-Clause License (http://www.opensource.org/licenses/bsd-license.php)
-
-
-====================BSD-2-Clause====================
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
- * Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- * Redistributions in binary form must reproduce the above
- copyright notice, this list of conditions and the following disclaimer
- in the documentation and/or other materials provided with the
- distribution.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-====================COPYRIGHT====================
- Copyright (C) 2012-2016, Yann Collet.
-
-
-====================COPYRIGHT====================
- static bool isChar6(char C) { return isAlnum(C) || C == '.' || C == '_'; }
- static unsigned EncodeChar6(char C) {
- if (C >= 'a' && C <= 'z') return C-'a';
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2004 Unicode, Inc.
-
-
-====================COPYRIGHT====================
- * This software was written by Alexander Peslyak in 2001. No copyright is
- * claimed, and the software is hereby placed in the public domain.
- * In case this attempt to disclaim copyright and place the software in the
- * public domain is deemed null and void, then the software is
- * Copyright (c) 2001 Alexander Peslyak and it is hereby released to the
- * general public under the following terms:
-
-
-====================COPYRIGHT====================
-Copyright (c) 2004 eXtensible Systems, Inc.
-
-====================File: LICENSE.TXT====================
-==============================================================================
-The LLVM Project is under the Apache License v2.0 with LLVM Exceptions:
-==============================================================================
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
-
----- LLVM Exceptions to the Apache 2.0 License ----
-
-As an exception, if, as a result of your compiling your source code, portions
-of this Software are embedded into an Object form of such source code, you
-may redistribute such embedded portions in such Object form without complying
-with the conditions of Sections 4(a), 4(b) and 4(d) of the License.
-
-In addition, if you combine or link compiled forms of this Software with
-software that is licensed under the GPLv2 ("Combined Software") and if a
-court of competent jurisdiction determines that the patent provision (Section
-3), the indemnity provision (Section 9) or other Section of the License
-conflicts with the conditions of the GPLv2, you may retroactively and
-prospectively choose to deem waived or otherwise exclude such Section(s) of
-the License, but only in their entirety and only with respect to the Combined
-Software.
-
-==============================================================================
-Software from third parties included in the LLVM Project:
-==============================================================================
-The LLVM Project contains third party software which is under different license
-terms. All such code will be identified clearly using at least one of two
-mechanisms:
-1) It will be in a separate directory tree with its own `LICENSE.txt` or
- `LICENSE` file at the top containing the specific license and restrictions
- which apply to that software, or
-2) It will contain specific license and restriction terms at the top of every
- file.
-
-==============================================================================
-Legacy LLVM License (https://llvm.org/docs/DeveloperPolicy.html#legacy):
-==============================================================================
-University of Illinois/NCSA
-Open Source License
-
-Copyright (c) 2003-2019 University of Illinois at Urbana-Champaign.
-All rights reserved.
-
-Developed by:
-
- LLVM Team
-
- University of Illinois at Urbana-Champaign
-
- http://llvm.org
-
-Permission is hereby granted, free of charge, to any person obtaining a copy of
-this software and associated documentation files (the "Software"), to deal with
-the Software without restriction, including without limitation the rights to
-use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
-of the Software, and to permit persons to whom the Software is furnished to do
-so, subject to the following conditions:
-
- * Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimers.
-
- * Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimers in the
- documentation and/or other materials provided with the distribution.
-
- * Neither the names of the LLVM Team, University of Illinois at
- Urbana-Champaign, nor the names of its contributors may be used to
- endorse or promote products derived from this Software without specific
- prior written permission.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
-FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE
-SOFTWARE.
-
-
-
-====================File: include/llvm/Support/LICENSE.TXT====================
-LLVM System Interface Library
--------------------------------------------------------------------------------
-The LLVM System Interface Library is licensed under the Illinois Open Source
-License and has the following additional copyright:
-
-Copyright (C) 2004 eXtensible Systems, Inc.
-
-
-====================NCSA====================
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-
-
-====================NCSA====================
-The LLVM System Interface Library is licensed under the Illinois Open Source
-
-
-====================NCSA====================
-The LLVM System Interface Library is licensed under the Illinois Open Source
-License and has the following additional copyright:
-
-
-====================Public-Domain====================
- * Homepage:
- * http://openwall.info/wiki/people/solar/software/public-domain-source-code/md5
- *
- * Author:
- * Alexander Peslyak, better known as Solar Designer <solar at openwall.com>
- *
- * This software was written by Alexander Peslyak in 2001. No copyright is
- * claimed, and the software is hereby placed in the public domain.
- * In case this attempt to disclaim copyright and place the software in the
- * public domain is deemed null and void, then the software is
- * Copyright (c) 2001 Alexander Peslyak and it is hereby released to the
- * general public under the following terms:
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted.
- *
- * There's ABSOLUTELY NO WARRANTY, express or implied.
-
-
-====================Public-Domain====================
-// This code is taken from public domain
-
-
-====================Unicode-Mappings====================
- * Disclaimer
- *
- * This source code is provided as is by Unicode, Inc. No claims are
- * made as to fitness for any particular purpose. No warranties of any
- * kind are expressed or implied. The recipient agrees to determine
- * applicability of information provided. If this file has been
- * purchased on magnetic or optical media from Unicode, Inc., the
- * sole remedy for any claim will be exchange of defective media
- * within 90 days of receipt.
- *
- * Limitations on Rights to Redistribute This Code
- *
- * Unicode, Inc. hereby grants the right to freely use the information
- * supplied in this file in the creation of products supporting the
- * Unicode Standard, and to make copies of this file in any form
- * for internal or external distribution as long as this notice
- * remains attached.
diff --git a/contrib/libs/llvm12/include/llvm-c/module.modulemap b/contrib/libs/llvm12/include/llvm-c/module.modulemap
deleted file mode 100644
index a456119595c..00000000000
--- a/contrib/libs/llvm12/include/llvm-c/module.modulemap
+++ /dev/null
@@ -1,4 +0,0 @@
-module LLVM_C {
- umbrella "."
- module * { export * }
-}
diff --git a/contrib/libs/llvm12/include/llvm/ADT/ImmutableList.h b/contrib/libs/llvm12/include/llvm/ADT/ImmutableList.h
deleted file mode 100644
index 0efab4a6664..00000000000
--- a/contrib/libs/llvm12/include/llvm/ADT/ImmutableList.h
+++ /dev/null
@@ -1,257 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==--- ImmutableList.h - Immutable (functional) list interface --*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the ImmutableList class.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_ADT_IMMUTABLELIST_H
-#define LLVM_ADT_IMMUTABLELIST_H
-
-#include "llvm/ADT/FoldingSet.h"
-#include "llvm/Support/Allocator.h"
-#include <cassert>
-#include <cstdint>
-#include <new>
-
-namespace llvm {
-
-template <typename T> class ImmutableListFactory;
-
-template <typename T>
-class ImmutableListImpl : public FoldingSetNode {
- friend class ImmutableListFactory<T>;
-
- T Head;
- const ImmutableListImpl* Tail;
-
- template <typename ElemT>
- ImmutableListImpl(ElemT &&head, const ImmutableListImpl *tail = nullptr)
- : Head(std::forward<ElemT>(head)), Tail(tail) {}
-
-public:
- ImmutableListImpl(const ImmutableListImpl &) = delete;
- ImmutableListImpl &operator=(const ImmutableListImpl &) = delete;
-
- const T& getHead() const { return Head; }
- const ImmutableListImpl* getTail() const { return Tail; }
-
- static inline void Profile(FoldingSetNodeID& ID, const T& H,
- const ImmutableListImpl* L){
- ID.AddPointer(L);
- ID.Add(H);
- }
-
- void Profile(FoldingSetNodeID& ID) {
- Profile(ID, Head, Tail);
- }
-};
-
-/// ImmutableList - This class represents an immutable (functional) list.
-/// It is implemented as a smart pointer (wraps ImmutableListImpl), so it
-/// it is intended to always be copied by value as if it were a pointer.
-/// This interface matches ImmutableSet and ImmutableMap. ImmutableList
-/// objects should almost never be created directly, and instead should
-/// be created by ImmutableListFactory objects that manage the lifetime
-/// of a group of lists. When the factory object is reclaimed, all lists
-/// created by that factory are released as well.
-template <typename T>
-class ImmutableList {
-public:
- using value_type = T;
- using Factory = ImmutableListFactory<T>;
-
- static_assert(std::is_trivially_destructible<T>::value,
- "T must be trivially destructible!");
-
-private:
- const ImmutableListImpl<T>* X;
-
-public:
- // This constructor should normally only be called by ImmutableListFactory<T>.
- // There may be cases, however, when one needs to extract the internal pointer
- // and reconstruct a list object from that pointer.
- ImmutableList(const ImmutableListImpl<T>* x = nullptr) : X(x) {}
-
- const ImmutableListImpl<T>* getInternalPointer() const {
- return X;
- }
-
- class iterator {
- const ImmutableListImpl<T>* L = nullptr;
-
- public:
- iterator() = default;
- iterator(ImmutableList l) : L(l.getInternalPointer()) {}
-
- iterator& operator++() { L = L->getTail(); return *this; }
- bool operator==(const iterator& I) const { return L == I.L; }
- bool operator!=(const iterator& I) const { return L != I.L; }
- const value_type& operator*() const { return L->getHead(); }
- const typename std::remove_reference<value_type>::type* operator->() const {
- return &L->getHead();
- }
-
- ImmutableList getList() const { return L; }
- };
-
- /// begin - Returns an iterator referring to the head of the list, or
- /// an iterator denoting the end of the list if the list is empty.
- iterator begin() const { return iterator(X); }
-
- /// end - Returns an iterator denoting the end of the list. This iterator
- /// does not refer to a valid list element.
- iterator end() const { return iterator(); }
-
- /// isEmpty - Returns true if the list is empty.
- bool isEmpty() const { return !X; }
-
- bool contains(const T& V) const {
- for (iterator I = begin(), E = end(); I != E; ++I) {
- if (*I == V)
- return true;
- }
- return false;
- }
-
- /// isEqual - Returns true if two lists are equal. Because all lists created
- /// from the same ImmutableListFactory are uniqued, this has O(1) complexity
- /// because it the contents of the list do not need to be compared. Note
- /// that you should only compare two lists created from the same
- /// ImmutableListFactory.
- bool isEqual(const ImmutableList& L) const { return X == L.X; }
-
- bool operator==(const ImmutableList& L) const { return isEqual(L); }
-
- /// getHead - Returns the head of the list.
- const T& getHead() const {
- assert(!isEmpty() && "Cannot get the head of an empty list.");
- return X->getHead();
- }
-
- /// getTail - Returns the tail of the list, which is another (possibly empty)
- /// ImmutableList.
- ImmutableList getTail() const {
- return X ? X->getTail() : nullptr;
- }
-
- void Profile(FoldingSetNodeID& ID) const {
- ID.AddPointer(X);
- }
-};
-
-template <typename T>
-class ImmutableListFactory {
- using ListTy = ImmutableListImpl<T>;
- using CacheTy = FoldingSet<ListTy>;
-
- CacheTy Cache;
- uintptr_t Allocator;
-
- bool ownsAllocator() const {
- return (Allocator & 0x1) == 0;
- }
-
- BumpPtrAllocator& getAllocator() const {
- return *reinterpret_cast<BumpPtrAllocator*>(Allocator & ~0x1);
- }
-
-public:
- ImmutableListFactory()
- : Allocator(reinterpret_cast<uintptr_t>(new BumpPtrAllocator())) {}
-
- ImmutableListFactory(BumpPtrAllocator& Alloc)
- : Allocator(reinterpret_cast<uintptr_t>(&Alloc) | 0x1) {}
-
- ~ImmutableListFactory() {
- if (ownsAllocator()) delete &getAllocator();
- }
-
- template <typename ElemT>
- LLVM_NODISCARD ImmutableList<T> concat(ElemT &&Head, ImmutableList<T> Tail) {
- // Profile the new list to see if it already exists in our cache.
- FoldingSetNodeID ID;
- void* InsertPos;
-
- const ListTy* TailImpl = Tail.getInternalPointer();
- ListTy::Profile(ID, Head, TailImpl);
- ListTy* L = Cache.FindNodeOrInsertPos(ID, InsertPos);
-
- if (!L) {
- // The list does not exist in our cache. Create it.
- BumpPtrAllocator& A = getAllocator();
- L = (ListTy*) A.Allocate<ListTy>();
- new (L) ListTy(std::forward<ElemT>(Head), TailImpl);
-
- // Insert the new list into the cache.
- Cache.InsertNode(L, InsertPos);
- }
-
- return L;
- }
-
- template <typename ElemT>
- LLVM_NODISCARD ImmutableList<T> add(ElemT &&Data, ImmutableList<T> L) {
- return concat(std::forward<ElemT>(Data), L);
- }
-
- template <typename ...CtorArgs>
- LLVM_NODISCARD ImmutableList<T> emplace(ImmutableList<T> Tail,
- CtorArgs &&...Args) {
- return concat(T(std::forward<CtorArgs>(Args)...), Tail);
- }
-
- ImmutableList<T> getEmptyList() const {
- return ImmutableList<T>(nullptr);
- }
-
- template <typename ElemT>
- ImmutableList<T> create(ElemT &&Data) {
- return concat(std::forward<ElemT>(Data), getEmptyList());
- }
-};
-
-//===----------------------------------------------------------------------===//
-// Partially-specialized Traits.
-//===----------------------------------------------------------------------===//
-
-template<typename T> struct DenseMapInfo;
-template<typename T> struct DenseMapInfo<ImmutableList<T>> {
- static inline ImmutableList<T> getEmptyKey() {
- return reinterpret_cast<ImmutableListImpl<T>*>(-1);
- }
-
- static inline ImmutableList<T> getTombstoneKey() {
- return reinterpret_cast<ImmutableListImpl<T>*>(-2);
- }
-
- static unsigned getHashValue(ImmutableList<T> X) {
- uintptr_t PtrVal = reinterpret_cast<uintptr_t>(X.getInternalPointer());
- return (unsigned((uintptr_t)PtrVal) >> 4) ^
- (unsigned((uintptr_t)PtrVal) >> 9);
- }
-
- static bool isEqual(ImmutableList<T> X1, ImmutableList<T> X2) {
- return X1 == X2;
- }
-};
-
-} // end namespace llvm
-
-#endif // LLVM_ADT_IMMUTABLELIST_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ADT/ImmutableMap.h b/contrib/libs/llvm12/include/llvm/ADT/ImmutableMap.h
deleted file mode 100644
index e51e0bb4987..00000000000
--- a/contrib/libs/llvm12/include/llvm/ADT/ImmutableMap.h
+++ /dev/null
@@ -1,377 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- ImmutableMap.h - Immutable (functional) map interface --*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the ImmutableMap class.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_ADT_IMMUTABLEMAP_H
-#define LLVM_ADT_IMMUTABLEMAP_H
-
-#include "llvm/ADT/FoldingSet.h"
-#include "llvm/ADT/ImmutableSet.h"
-#include "llvm/Support/Allocator.h"
-#include <utility>
-
-namespace llvm {
-
-/// ImutKeyValueInfo -Traits class used by ImmutableMap. While both the first
-/// and second elements in a pair are used to generate profile information,
-/// only the first element (the key) is used by isEqual and isLess.
-template <typename T, typename S>
-struct ImutKeyValueInfo {
- using value_type = const std::pair<T,S>;
- using value_type_ref = const value_type&;
- using key_type = const T;
- using key_type_ref = const T&;
- using data_type = const S;
- using data_type_ref = const S&;
-
- static inline key_type_ref KeyOfValue(value_type_ref V) {
- return V.first;
- }
-
- static inline data_type_ref DataOfValue(value_type_ref V) {
- return V.second;
- }
-
- static inline bool isEqual(key_type_ref L, key_type_ref R) {
- return ImutContainerInfo<T>::isEqual(L,R);
- }
- static inline bool isLess(key_type_ref L, key_type_ref R) {
- return ImutContainerInfo<T>::isLess(L,R);
- }
-
- static inline bool isDataEqual(data_type_ref L, data_type_ref R) {
- return ImutContainerInfo<S>::isEqual(L,R);
- }
-
- static inline void Profile(FoldingSetNodeID& ID, value_type_ref V) {
- ImutContainerInfo<T>::Profile(ID, V.first);
- ImutContainerInfo<S>::Profile(ID, V.second);
- }
-};
-
-template <typename KeyT, typename ValT,
- typename ValInfo = ImutKeyValueInfo<KeyT,ValT>>
-class ImmutableMap {
-public:
- using value_type = typename ValInfo::value_type;
- using value_type_ref = typename ValInfo::value_type_ref;
- using key_type = typename ValInfo::key_type;
- using key_type_ref = typename ValInfo::key_type_ref;
- using data_type = typename ValInfo::data_type;
- using data_type_ref = typename ValInfo::data_type_ref;
- using TreeTy = ImutAVLTree<ValInfo>;
-
-protected:
- IntrusiveRefCntPtr<TreeTy> Root;
-
-public:
- /// Constructs a map from a pointer to a tree root. In general one
- /// should use a Factory object to create maps instead of directly
- /// invoking the constructor, but there are cases where make this
- /// constructor public is useful.
- explicit ImmutableMap(const TreeTy *R) : Root(const_cast<TreeTy *>(R)) {}
-
- class Factory {
- typename TreeTy::Factory F;
- const bool Canonicalize;
-
- public:
- Factory(bool canonicalize = true) : Canonicalize(canonicalize) {}
-
- Factory(BumpPtrAllocator &Alloc, bool canonicalize = true)
- : F(Alloc), Canonicalize(canonicalize) {}
-
- Factory(const Factory &) = delete;
- Factory &operator=(const Factory &) = delete;
-
- ImmutableMap getEmptyMap() { return ImmutableMap(F.getEmptyTree()); }
-
- LLVM_NODISCARD ImmutableMap add(ImmutableMap Old, key_type_ref K,
- data_type_ref D) {
- TreeTy *T = F.add(Old.Root.get(), std::pair<key_type, data_type>(K, D));
- return ImmutableMap(Canonicalize ? F.getCanonicalTree(T): T);
- }
-
- LLVM_NODISCARD ImmutableMap remove(ImmutableMap Old, key_type_ref K) {
- TreeTy *T = F.remove(Old.Root.get(), K);
- return ImmutableMap(Canonicalize ? F.getCanonicalTree(T): T);
- }
-
- typename TreeTy::Factory *getTreeFactory() const {
- return const_cast<typename TreeTy::Factory *>(&F);
- }
- };
-
- bool contains(key_type_ref K) const {
- return Root ? Root->contains(K) : false;
- }
-
- bool operator==(const ImmutableMap &RHS) const {
- return Root && RHS.Root ? Root->isEqual(*RHS.Root.get()) : Root == RHS.Root;
- }
-
- bool operator!=(const ImmutableMap &RHS) const {
- return Root && RHS.Root ? Root->isNotEqual(*RHS.Root.get())
- : Root != RHS.Root;
- }
-
- TreeTy *getRoot() const {
- if (Root) { Root->retain(); }
- return Root.get();
- }
-
- TreeTy *getRootWithoutRetain() const { return Root.get(); }
-
- void manualRetain() {
- if (Root) Root->retain();
- }
-
- void manualRelease() {
- if (Root) Root->release();
- }
-
- bool isEmpty() const { return !Root; }
-
- //===--------------------------------------------------===//
- // Foreach - A limited form of map iteration.
- //===--------------------------------------------------===//
-
-private:
- template <typename Callback>
- struct CBWrapper {
- Callback C;
-
- void operator()(value_type_ref V) { C(V.first,V.second); }
- };
-
- template <typename Callback>
- struct CBWrapperRef {
- Callback &C;
-
- CBWrapperRef(Callback& c) : C(c) {}
-
- void operator()(value_type_ref V) { C(V.first,V.second); }
- };
-
-public:
- template <typename Callback>
- void foreach(Callback& C) {
- if (Root) {
- CBWrapperRef<Callback> CB(C);
- Root->foreach(CB);
- }
- }
-
- template <typename Callback>
- void foreach() {
- if (Root) {
- CBWrapper<Callback> CB;
- Root->foreach(CB);
- }
- }
-
- //===--------------------------------------------------===//
- // For testing.
- //===--------------------------------------------------===//
-
- void verify() const { if (Root) Root->verify(); }
-
- //===--------------------------------------------------===//
- // Iterators.
- //===--------------------------------------------------===//
-
- class iterator : public ImutAVLValueIterator<ImmutableMap> {
- friend class ImmutableMap;
-
- iterator() = default;
- explicit iterator(TreeTy *Tree) : iterator::ImutAVLValueIterator(Tree) {}
-
- public:
- key_type_ref getKey() const { return (*this)->first; }
- data_type_ref getData() const { return (*this)->second; }
- };
-
- iterator begin() const { return iterator(Root.get()); }
- iterator end() const { return iterator(); }
-
- data_type* lookup(key_type_ref K) const {
- if (Root) {
- TreeTy* T = Root->find(K);
- if (T) return &T->getValue().second;
- }
-
- return nullptr;
- }
-
- /// getMaxElement - Returns the <key,value> pair in the ImmutableMap for
- /// which key is the highest in the ordering of keys in the map. This
- /// method returns NULL if the map is empty.
- value_type* getMaxElement() const {
- return Root ? &(Root->getMaxElement()->getValue()) : nullptr;
- }
-
- //===--------------------------------------------------===//
- // Utility methods.
- //===--------------------------------------------------===//
-
- unsigned getHeight() const { return Root ? Root->getHeight() : 0; }
-
- static inline void Profile(FoldingSetNodeID& ID, const ImmutableMap& M) {
- ID.AddPointer(M.Root.get());
- }
-
- inline void Profile(FoldingSetNodeID& ID) const {
- return Profile(ID,*this);
- }
-};
-
-// NOTE: This will possibly become the new implementation of ImmutableMap some day.
-template <typename KeyT, typename ValT,
-typename ValInfo = ImutKeyValueInfo<KeyT,ValT>>
-class ImmutableMapRef {
-public:
- using value_type = typename ValInfo::value_type;
- using value_type_ref = typename ValInfo::value_type_ref;
- using key_type = typename ValInfo::key_type;
- using key_type_ref = typename ValInfo::key_type_ref;
- using data_type = typename ValInfo::data_type;
- using data_type_ref = typename ValInfo::data_type_ref;
- using TreeTy = ImutAVLTree<ValInfo>;
- using FactoryTy = typename TreeTy::Factory;
-
-protected:
- IntrusiveRefCntPtr<TreeTy> Root;
- FactoryTy *Factory;
-
-public:
- /// Constructs a map from a pointer to a tree root. In general one
- /// should use a Factory object to create maps instead of directly
- /// invoking the constructor, but there are cases where make this
- /// constructor public is useful.
- ImmutableMapRef(const TreeTy *R, FactoryTy *F)
- : Root(const_cast<TreeTy *>(R)), Factory(F) {}
-
- ImmutableMapRef(const ImmutableMap<KeyT, ValT> &X,
- typename ImmutableMap<KeyT, ValT>::Factory &F)
- : Root(X.getRootWithoutRetain()), Factory(F.getTreeFactory()) {}
-
- static inline ImmutableMapRef getEmptyMap(FactoryTy *F) {
- return ImmutableMapRef(0, F);
- }
-
- void manualRetain() {
- if (Root) Root->retain();
- }
-
- void manualRelease() {
- if (Root) Root->release();
- }
-
- ImmutableMapRef add(key_type_ref K, data_type_ref D) const {
- TreeTy *NewT =
- Factory->add(Root.get(), std::pair<key_type, data_type>(K, D));
- return ImmutableMapRef(NewT, Factory);
- }
-
- ImmutableMapRef remove(key_type_ref K) const {
- TreeTy *NewT = Factory->remove(Root.get(), K);
- return ImmutableMapRef(NewT, Factory);
- }
-
- bool contains(key_type_ref K) const {
- return Root ? Root->contains(K) : false;
- }
-
- ImmutableMap<KeyT, ValT> asImmutableMap() const {
- return ImmutableMap<KeyT, ValT>(Factory->getCanonicalTree(Root.get()));
- }
-
- bool operator==(const ImmutableMapRef &RHS) const {
- return Root && RHS.Root ? Root->isEqual(*RHS.Root.get()) : Root == RHS.Root;
- }
-
- bool operator!=(const ImmutableMapRef &RHS) const {
- return Root && RHS.Root ? Root->isNotEqual(*RHS.Root.get())
- : Root != RHS.Root;
- }
-
- bool isEmpty() const { return !Root; }
-
- //===--------------------------------------------------===//
- // For testing.
- //===--------------------------------------------------===//
-
- void verify() const {
- if (Root)
- Root->verify();
- }
-
- //===--------------------------------------------------===//
- // Iterators.
- //===--------------------------------------------------===//
-
- class iterator : public ImutAVLValueIterator<ImmutableMapRef> {
- friend class ImmutableMapRef;
-
- iterator() = default;
- explicit iterator(TreeTy *Tree) : iterator::ImutAVLValueIterator(Tree) {}
-
- public:
- key_type_ref getKey() const { return (*this)->first; }
- data_type_ref getData() const { return (*this)->second; }
- };
-
- iterator begin() const { return iterator(Root.get()); }
- iterator end() const { return iterator(); }
-
- data_type *lookup(key_type_ref K) const {
- if (Root) {
- TreeTy* T = Root->find(K);
- if (T) return &T->getValue().second;
- }
-
- return nullptr;
- }
-
- /// getMaxElement - Returns the <key,value> pair in the ImmutableMap for
- /// which key is the highest in the ordering of keys in the map. This
- /// method returns NULL if the map is empty.
- value_type* getMaxElement() const {
- return Root ? &(Root->getMaxElement()->getValue()) : 0;
- }
-
- //===--------------------------------------------------===//
- // Utility methods.
- //===--------------------------------------------------===//
-
- unsigned getHeight() const { return Root ? Root->getHeight() : 0; }
-
- static inline void Profile(FoldingSetNodeID &ID, const ImmutableMapRef &M) {
- ID.AddPointer(M.Root.get());
- }
-
- inline void Profile(FoldingSetNodeID &ID) const { return Profile(ID, *this); }
-};
-
-} // end namespace llvm
-
-#endif // LLVM_ADT_IMMUTABLEMAP_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ADT/ImmutableSet.h b/contrib/libs/llvm12/include/llvm/ADT/ImmutableSet.h
deleted file mode 100644
index dfbf8b0156c..00000000000
--- a/contrib/libs/llvm12/include/llvm/ADT/ImmutableSet.h
+++ /dev/null
@@ -1,1195 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- ImmutableSet.h - Immutable (functional) set interface --*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the ImutAVLTree and ImmutableSet classes.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_ADT_IMMUTABLESET_H
-#define LLVM_ADT_IMMUTABLESET_H
-
-#include "llvm/ADT/DenseMap.h"
-#include "llvm/ADT/FoldingSet.h"
-#include "llvm/ADT/IntrusiveRefCntPtr.h"
-#include "llvm/ADT/SmallVector.h"
-#include "llvm/ADT/iterator.h"
-#include "llvm/Support/Allocator.h"
-#include "llvm/Support/ErrorHandling.h"
-#include <cassert>
-#include <cstdint>
-#include <functional>
-#include <iterator>
-#include <new>
-#include <vector>
-
-namespace llvm {
-
-//===----------------------------------------------------------------------===//
-// Immutable AVL-Tree Definition.
-//===----------------------------------------------------------------------===//
-
-template <typename ImutInfo> class ImutAVLFactory;
-template <typename ImutInfo> class ImutIntervalAVLFactory;
-template <typename ImutInfo> class ImutAVLTreeInOrderIterator;
-template <typename ImutInfo> class ImutAVLTreeGenericIterator;
-
-template <typename ImutInfo >
-class ImutAVLTree {
-public:
- using key_type_ref = typename ImutInfo::key_type_ref;
- using value_type = typename ImutInfo::value_type;
- using value_type_ref = typename ImutInfo::value_type_ref;
- using Factory = ImutAVLFactory<ImutInfo>;
- using iterator = ImutAVLTreeInOrderIterator<ImutInfo>;
-
- friend class ImutAVLFactory<ImutInfo>;
- friend class ImutIntervalAVLFactory<ImutInfo>;
- friend class ImutAVLTreeGenericIterator<ImutInfo>;
-
- //===----------------------------------------------------===//
- // Public Interface.
- //===----------------------------------------------------===//
-
- /// Return a pointer to the left subtree. This value
- /// is NULL if there is no left subtree.
- ImutAVLTree *getLeft() const { return left; }
-
- /// Return a pointer to the right subtree. This value is
- /// NULL if there is no right subtree.
- ImutAVLTree *getRight() const { return right; }
-
- /// getHeight - Returns the height of the tree. A tree with no subtrees
- /// has a height of 1.
- unsigned getHeight() const { return height; }
-
- /// getValue - Returns the data value associated with the tree node.
- const value_type& getValue() const { return value; }
-
- /// find - Finds the subtree associated with the specified key value.
- /// This method returns NULL if no matching subtree is found.
- ImutAVLTree* find(key_type_ref K) {
- ImutAVLTree *T = this;
- while (T) {
- key_type_ref CurrentKey = ImutInfo::KeyOfValue(T->getValue());
- if (ImutInfo::isEqual(K,CurrentKey))
- return T;
- else if (ImutInfo::isLess(K,CurrentKey))
- T = T->getLeft();
- else
- T = T->getRight();
- }
- return nullptr;
- }
-
- /// getMaxElement - Find the subtree associated with the highest ranged
- /// key value.
- ImutAVLTree* getMaxElement() {
- ImutAVLTree *T = this;
- ImutAVLTree *Right = T->getRight();
- while (Right) { T = Right; Right = T->getRight(); }
- return T;
- }
-
- /// size - Returns the number of nodes in the tree, which includes
- /// both leaves and non-leaf nodes.
- unsigned size() const {
- unsigned n = 1;
- if (const ImutAVLTree* L = getLeft())
- n += L->size();
- if (const ImutAVLTree* R = getRight())
- n += R->size();
- return n;
- }
-
- /// begin - Returns an iterator that iterates over the nodes of the tree
- /// in an inorder traversal. The returned iterator thus refers to the
- /// the tree node with the minimum data element.
- iterator begin() const { return iterator(this); }
-
- /// end - Returns an iterator for the tree that denotes the end of an
- /// inorder traversal.
- iterator end() const { return iterator(); }
-
- bool isElementEqual(value_type_ref V) const {
- // Compare the keys.
- if (!ImutInfo::isEqual(ImutInfo::KeyOfValue(getValue()),
- ImutInfo::KeyOfValue(V)))
- return false;
-
- // Also compare the data values.
- if (!ImutInfo::isDataEqual(ImutInfo::DataOfValue(getValue()),
- ImutInfo::DataOfValue(V)))
- return false;
-
- return true;
- }
-
- bool isElementEqual(const ImutAVLTree* RHS) const {
- return isElementEqual(RHS->getValue());
- }
-
- /// isEqual - Compares two trees for structural equality and returns true
- /// if they are equal. This worst case performance of this operation is
- // linear in the sizes of the trees.
- bool isEqual(const ImutAVLTree& RHS) const {
- if (&RHS == this)
- return true;
-
- iterator LItr = begin(), LEnd = end();
- iterator RItr = RHS.begin(), REnd = RHS.end();
-
- while (LItr != LEnd && RItr != REnd) {
- if (&*LItr == &*RItr) {
- LItr.skipSubTree();
- RItr.skipSubTree();
- continue;
- }
-
- if (!LItr->isElementEqual(&*RItr))
- return false;
-
- ++LItr;
- ++RItr;
- }
-
- return LItr == LEnd && RItr == REnd;
- }
-
- /// isNotEqual - Compares two trees for structural inequality. Performance
- /// is the same is isEqual.
- bool isNotEqual(const ImutAVLTree& RHS) const { return !isEqual(RHS); }
-
- /// contains - Returns true if this tree contains a subtree (node) that
- /// has an data element that matches the specified key. Complexity
- /// is logarithmic in the size of the tree.
- bool contains(key_type_ref K) { return (bool) find(K); }
-
- /// foreach - A member template the accepts invokes operator() on a functor
- /// object (specified by Callback) for every node/subtree in the tree.
- /// Nodes are visited using an inorder traversal.
- template <typename Callback>
- void foreach(Callback& C) {
- if (ImutAVLTree* L = getLeft())
- L->foreach(C);
-
- C(value);
-
- if (ImutAVLTree* R = getRight())
- R->foreach(C);
- }
-
- /// validateTree - A utility method that checks that the balancing and
- /// ordering invariants of the tree are satisfied. It is a recursive
- /// method that returns the height of the tree, which is then consumed
- /// by the enclosing validateTree call. External callers should ignore the
- /// return value. An invalid tree will cause an assertion to fire in
- /// a debug build.
- unsigned validateTree() const {
- unsigned HL = getLeft() ? getLeft()->validateTree() : 0;
- unsigned HR = getRight() ? getRight()->validateTree() : 0;
- (void) HL;
- (void) HR;
-
- assert(getHeight() == ( HL > HR ? HL : HR ) + 1
- && "Height calculation wrong");
-
- assert((HL > HR ? HL-HR : HR-HL) <= 2
- && "Balancing invariant violated");
-
- assert((!getLeft() ||
- ImutInfo::isLess(ImutInfo::KeyOfValue(getLeft()->getValue()),
- ImutInfo::KeyOfValue(getValue()))) &&
- "Value in left child is not less that current value");
-
- assert((!getRight() ||
- ImutInfo::isLess(ImutInfo::KeyOfValue(getValue()),
- ImutInfo::KeyOfValue(getRight()->getValue()))) &&
- "Current value is not less that value of right child");
-
- return getHeight();
- }
-
- //===----------------------------------------------------===//
- // Internal values.
- //===----------------------------------------------------===//
-
-private:
- Factory *factory;
- ImutAVLTree *left;
- ImutAVLTree *right;
- ImutAVLTree *prev = nullptr;
- ImutAVLTree *next = nullptr;
-
- unsigned height : 28;
- bool IsMutable : 1;
- bool IsDigestCached : 1;
- bool IsCanonicalized : 1;
-
- value_type value;
- uint32_t digest = 0;
- uint32_t refCount = 0;
-
- //===----------------------------------------------------===//
- // Internal methods (node manipulation; used by Factory).
- //===----------------------------------------------------===//
-
-private:
- /// ImutAVLTree - Internal constructor that is only called by
- /// ImutAVLFactory.
- ImutAVLTree(Factory *f, ImutAVLTree* l, ImutAVLTree* r, value_type_ref v,
- unsigned height)
- : factory(f), left(l), right(r), height(height), IsMutable(true),
- IsDigestCached(false), IsCanonicalized(false), value(v)
- {
- if (left) left->retain();
- if (right) right->retain();
- }
-
- /// isMutable - Returns true if the left and right subtree references
- /// (as well as height) can be changed. If this method returns false,
- /// the tree is truly immutable. Trees returned from an ImutAVLFactory
- /// object should always have this method return true. Further, if this
- /// method returns false for an instance of ImutAVLTree, all subtrees
- /// will also have this method return false. The converse is not true.
- bool isMutable() const { return IsMutable; }
-
- /// hasCachedDigest - Returns true if the digest for this tree is cached.
- /// This can only be true if the tree is immutable.
- bool hasCachedDigest() const { return IsDigestCached; }
-
- //===----------------------------------------------------===//
- // Mutating operations. A tree root can be manipulated as
- // long as its reference has not "escaped" from internal
- // methods of a factory object (see below). When a tree
- // pointer is externally viewable by client code, the
- // internal "mutable bit" is cleared to mark the tree
- // immutable. Note that a tree that still has its mutable
- // bit set may have children (subtrees) that are themselves
- // immutable.
- //===----------------------------------------------------===//
-
- /// markImmutable - Clears the mutable flag for a tree. After this happens,
- /// it is an error to call setLeft(), setRight(), and setHeight().
- void markImmutable() {
- assert(isMutable() && "Mutable flag already removed.");
- IsMutable = false;
- }
-
- /// markedCachedDigest - Clears the NoCachedDigest flag for a tree.
- void markedCachedDigest() {
- assert(!hasCachedDigest() && "NoCachedDigest flag already removed.");
- IsDigestCached = true;
- }
-
- /// setHeight - Changes the height of the tree. Used internally by
- /// ImutAVLFactory.
- void setHeight(unsigned h) {
- assert(isMutable() && "Only a mutable tree can have its height changed.");
- height = h;
- }
-
- static uint32_t computeDigest(ImutAVLTree *L, ImutAVLTree *R,
- value_type_ref V) {
- uint32_t digest = 0;
-
- if (L)
- digest += L->computeDigest();
-
- // Compute digest of stored data.
- FoldingSetNodeID ID;
- ImutInfo::Profile(ID,V);
- digest += ID.ComputeHash();
-
- if (R)
- digest += R->computeDigest();
-
- return digest;
- }
-
- uint32_t computeDigest() {
- // Check the lowest bit to determine if digest has actually been
- // pre-computed.
- if (hasCachedDigest())
- return digest;
-
- uint32_t X = computeDigest(getLeft(), getRight(), getValue());
- digest = X;
- markedCachedDigest();
- return X;
- }
-
- //===----------------------------------------------------===//
- // Reference count operations.
- //===----------------------------------------------------===//
-
-public:
- void retain() { ++refCount; }
-
- void release() {
- assert(refCount > 0);
- if (--refCount == 0)
- destroy();
- }
-
- void destroy() {
- if (left)
- left->release();
- if (right)
- right->release();
- if (IsCanonicalized) {
- if (next)
- next->prev = prev;
-
- if (prev)
- prev->next = next;
- else
- factory->Cache[factory->maskCacheIndex(computeDigest())] = next;
- }
-
- // We need to clear the mutability bit in case we are
- // destroying the node as part of a sweep in ImutAVLFactory::recoverNodes().
- IsMutable = false;
- factory->freeNodes.push_back(this);
- }
-};
-
-template <typename ImutInfo>
-struct IntrusiveRefCntPtrInfo<ImutAVLTree<ImutInfo>> {
- static void retain(ImutAVLTree<ImutInfo> *Tree) { Tree->retain(); }
- static void release(ImutAVLTree<ImutInfo> *Tree) { Tree->release(); }
-};
-
-//===----------------------------------------------------------------------===//
-// Immutable AVL-Tree Factory class.
-//===----------------------------------------------------------------------===//
-
-template <typename ImutInfo >
-class ImutAVLFactory {
- friend class ImutAVLTree<ImutInfo>;
-
- using TreeTy = ImutAVLTree<ImutInfo>;
- using value_type_ref = typename TreeTy::value_type_ref;
- using key_type_ref = typename TreeTy::key_type_ref;
- using CacheTy = DenseMap<unsigned, TreeTy*>;
-
- CacheTy Cache;
- uintptr_t Allocator;
- std::vector<TreeTy*> createdNodes;
- std::vector<TreeTy*> freeNodes;
-
- bool ownsAllocator() const {
- return (Allocator & 0x1) == 0;
- }
-
- BumpPtrAllocator& getAllocator() const {
- return *reinterpret_cast<BumpPtrAllocator*>(Allocator & ~0x1);
- }
-
- //===--------------------------------------------------===//
- // Public interface.
- //===--------------------------------------------------===//
-
-public:
- ImutAVLFactory()
- : Allocator(reinterpret_cast<uintptr_t>(new BumpPtrAllocator())) {}
-
- ImutAVLFactory(BumpPtrAllocator& Alloc)
- : Allocator(reinterpret_cast<uintptr_t>(&Alloc) | 0x1) {}
-
- ~ImutAVLFactory() {
- if (ownsAllocator()) delete &getAllocator();
- }
-
- TreeTy* add(TreeTy* T, value_type_ref V) {
- T = add_internal(V,T);
- markImmutable(T);
- recoverNodes();
- return T;
- }
-
- TreeTy* remove(TreeTy* T, key_type_ref V) {
- T = remove_internal(V,T);
- markImmutable(T);
- recoverNodes();
- return T;
- }
-
- TreeTy* getEmptyTree() const { return nullptr; }
-
-protected:
- //===--------------------------------------------------===//
- // A bunch of quick helper functions used for reasoning
- // about the properties of trees and their children.
- // These have succinct names so that the balancing code
- // is as terse (and readable) as possible.
- //===--------------------------------------------------===//
-
- bool isEmpty(TreeTy* T) const { return !T; }
- unsigned getHeight(TreeTy* T) const { return T ? T->getHeight() : 0; }
- TreeTy* getLeft(TreeTy* T) const { return T->getLeft(); }
- TreeTy* getRight(TreeTy* T) const { return T->getRight(); }
- value_type_ref getValue(TreeTy* T) const { return T->value; }
-
- // Make sure the index is not the Tombstone or Entry key of the DenseMap.
- static unsigned maskCacheIndex(unsigned I) { return (I & ~0x02); }
-
- unsigned incrementHeight(TreeTy* L, TreeTy* R) const {
- unsigned hl = getHeight(L);
- unsigned hr = getHeight(R);
- return (hl > hr ? hl : hr) + 1;
- }
-
- static bool compareTreeWithSection(TreeTy* T,
- typename TreeTy::iterator& TI,
- typename TreeTy::iterator& TE) {
- typename TreeTy::iterator I = T->begin(), E = T->end();
- for ( ; I!=E ; ++I, ++TI) {
- if (TI == TE || !I->isElementEqual(&*TI))
- return false;
- }
- return true;
- }
-
- //===--------------------------------------------------===//
- // "createNode" is used to generate new tree roots that link
- // to other trees. The function may also simply move links
- // in an existing root if that root is still marked mutable.
- // This is necessary because otherwise our balancing code
- // would leak memory as it would create nodes that are
- // then discarded later before the finished tree is
- // returned to the caller.
- //===--------------------------------------------------===//
-
- TreeTy* createNode(TreeTy* L, value_type_ref V, TreeTy* R) {
- BumpPtrAllocator& A = getAllocator();
- TreeTy* T;
- if (!freeNodes.empty()) {
- T = freeNodes.back();
- freeNodes.pop_back();
- assert(T != L);
- assert(T != R);
- } else {
- T = (TreeTy*) A.Allocate<TreeTy>();
- }
- new (T) TreeTy(this, L, R, V, incrementHeight(L,R));
- createdNodes.push_back(T);
- return T;
- }
-
- TreeTy* createNode(TreeTy* newLeft, TreeTy* oldTree, TreeTy* newRight) {
- return createNode(newLeft, getValue(oldTree), newRight);
- }
-
- void recoverNodes() {
- for (unsigned i = 0, n = createdNodes.size(); i < n; ++i) {
- TreeTy *N = createdNodes[i];
- if (N->isMutable() && N->refCount == 0)
- N->destroy();
- }
- createdNodes.clear();
- }
-
- /// balanceTree - Used by add_internal and remove_internal to
- /// balance a newly created tree.
- TreeTy* balanceTree(TreeTy* L, value_type_ref V, TreeTy* R) {
- unsigned hl = getHeight(L);
- unsigned hr = getHeight(R);
-
- if (hl > hr + 2) {
- assert(!isEmpty(L) && "Left tree cannot be empty to have a height >= 2");
-
- TreeTy *LL = getLeft(L);
- TreeTy *LR = getRight(L);
-
- if (getHeight(LL) >= getHeight(LR))
- return createNode(LL, L, createNode(LR,V,R));
-
- assert(!isEmpty(LR) && "LR cannot be empty because it has a height >= 1");
-
- TreeTy *LRL = getLeft(LR);
- TreeTy *LRR = getRight(LR);
-
- return createNode(createNode(LL,L,LRL), LR, createNode(LRR,V,R));
- }
-
- if (hr > hl + 2) {
- assert(!isEmpty(R) && "Right tree cannot be empty to have a height >= 2");
-
- TreeTy *RL = getLeft(R);
- TreeTy *RR = getRight(R);
-
- if (getHeight(RR) >= getHeight(RL))
- return createNode(createNode(L,V,RL), R, RR);
-
- assert(!isEmpty(RL) && "RL cannot be empty because it has a height >= 1");
-
- TreeTy *RLL = getLeft(RL);
- TreeTy *RLR = getRight(RL);
-
- return createNode(createNode(L,V,RLL), RL, createNode(RLR,R,RR));
- }
-
- return createNode(L,V,R);
- }
-
- /// add_internal - Creates a new tree that includes the specified
- /// data and the data from the original tree. If the original tree
- /// already contained the data item, the original tree is returned.
- TreeTy* add_internal(value_type_ref V, TreeTy* T) {
- if (isEmpty(T))
- return createNode(T, V, T);
- assert(!T->isMutable());
-
- key_type_ref K = ImutInfo::KeyOfValue(V);
- key_type_ref KCurrent = ImutInfo::KeyOfValue(getValue(T));
-
- if (ImutInfo::isEqual(K,KCurrent))
- return createNode(getLeft(T), V, getRight(T));
- else if (ImutInfo::isLess(K,KCurrent))
- return balanceTree(add_internal(V, getLeft(T)), getValue(T), getRight(T));
- else
- return balanceTree(getLeft(T), getValue(T), add_internal(V, getRight(T)));
- }
-
- /// remove_internal - Creates a new tree that includes all the data
- /// from the original tree except the specified data. If the
- /// specified data did not exist in the original tree, the original
- /// tree is returned.
- TreeTy* remove_internal(key_type_ref K, TreeTy* T) {
- if (isEmpty(T))
- return T;
-
- assert(!T->isMutable());
-
- key_type_ref KCurrent = ImutInfo::KeyOfValue(getValue(T));
-
- if (ImutInfo::isEqual(K,KCurrent)) {
- return combineTrees(getLeft(T), getRight(T));
- } else if (ImutInfo::isLess(K,KCurrent)) {
- return balanceTree(remove_internal(K, getLeft(T)),
- getValue(T), getRight(T));
- } else {
- return balanceTree(getLeft(T), getValue(T),
- remove_internal(K, getRight(T)));
- }
- }
-
- TreeTy* combineTrees(TreeTy* L, TreeTy* R) {
- if (isEmpty(L))
- return R;
- if (isEmpty(R))
- return L;
- TreeTy* OldNode;
- TreeTy* newRight = removeMinBinding(R,OldNode);
- return balanceTree(L, getValue(OldNode), newRight);
- }
-
- TreeTy* removeMinBinding(TreeTy* T, TreeTy*& Noderemoved) {
- assert(!isEmpty(T));
- if (isEmpty(getLeft(T))) {
- Noderemoved = T;
- return getRight(T);
- }
- return balanceTree(removeMinBinding(getLeft(T), Noderemoved),
- getValue(T), getRight(T));
- }
-
- /// markImmutable - Clears the mutable bits of a root and all of its
- /// descendants.
- void markImmutable(TreeTy* T) {
- if (!T || !T->isMutable())
- return;
- T->markImmutable();
- markImmutable(getLeft(T));
- markImmutable(getRight(T));
- }
-
-public:
- TreeTy *getCanonicalTree(TreeTy *TNew) {
- if (!TNew)
- return nullptr;
-
- if (TNew->IsCanonicalized)
- return TNew;
-
- // Search the hashtable for another tree with the same digest, and
- // if find a collision compare those trees by their contents.
- unsigned digest = TNew->computeDigest();
- TreeTy *&entry = Cache[maskCacheIndex(digest)];
- do {
- if (!entry)
- break;
- for (TreeTy *T = entry ; T != nullptr; T = T->next) {
- // Compare the Contents('T') with Contents('TNew')
- typename TreeTy::iterator TI = T->begin(), TE = T->end();
- if (!compareTreeWithSection(TNew, TI, TE))
- continue;
- if (TI != TE)
- continue; // T has more contents than TNew.
- // Trees did match! Return 'T'.
- if (TNew->refCount == 0)
- TNew->destroy();
- return T;
- }
- entry->prev = TNew;
- TNew->next = entry;
- }
- while (false);
-
- entry = TNew;
- TNew->IsCanonicalized = true;
- return TNew;
- }
-};
-
-//===----------------------------------------------------------------------===//
-// Immutable AVL-Tree Iterators.
-//===----------------------------------------------------------------------===//
-
-template <typename ImutInfo>
-class ImutAVLTreeGenericIterator
- : public std::iterator<std::bidirectional_iterator_tag,
- ImutAVLTree<ImutInfo>> {
- SmallVector<uintptr_t,20> stack;
-
-public:
- enum VisitFlag { VisitedNone=0x0, VisitedLeft=0x1, VisitedRight=0x3,
- Flags=0x3 };
-
- using TreeTy = ImutAVLTree<ImutInfo>;
-
- ImutAVLTreeGenericIterator() = default;
- ImutAVLTreeGenericIterator(const TreeTy *Root) {
- if (Root) stack.push_back(reinterpret_cast<uintptr_t>(Root));
- }
-
- TreeTy &operator*() const {
- assert(!stack.empty());
- return *reinterpret_cast<TreeTy *>(stack.back() & ~Flags);
- }
- TreeTy *operator->() const { return &*this; }
-
- uintptr_t getVisitState() const {
- assert(!stack.empty());
- return stack.back() & Flags;
- }
-
- bool atEnd() const { return stack.empty(); }
-
- bool atBeginning() const {
- return stack.size() == 1 && getVisitState() == VisitedNone;
- }
-
- void skipToParent() {
- assert(!stack.empty());
- stack.pop_back();
- if (stack.empty())
- return;
- switch (getVisitState()) {
- case VisitedNone:
- stack.back() |= VisitedLeft;
- break;
- case VisitedLeft:
- stack.back() |= VisitedRight;
- break;
- default:
- llvm_unreachable("Unreachable.");
- }
- }
-
- bool operator==(const ImutAVLTreeGenericIterator &x) const {
- return stack == x.stack;
- }
-
- bool operator!=(const ImutAVLTreeGenericIterator &x) const {
- return !(*this == x);
- }
-
- ImutAVLTreeGenericIterator &operator++() {
- assert(!stack.empty());
- TreeTy* Current = reinterpret_cast<TreeTy*>(stack.back() & ~Flags);
- assert(Current);
- switch (getVisitState()) {
- case VisitedNone:
- if (TreeTy* L = Current->getLeft())
- stack.push_back(reinterpret_cast<uintptr_t>(L));
- else
- stack.back() |= VisitedLeft;
- break;
- case VisitedLeft:
- if (TreeTy* R = Current->getRight())
- stack.push_back(reinterpret_cast<uintptr_t>(R));
- else
- stack.back() |= VisitedRight;
- break;
- case VisitedRight:
- skipToParent();
- break;
- default:
- llvm_unreachable("Unreachable.");
- }
- return *this;
- }
-
- ImutAVLTreeGenericIterator &operator--() {
- assert(!stack.empty());
- TreeTy* Current = reinterpret_cast<TreeTy*>(stack.back() & ~Flags);
- assert(Current);
- switch (getVisitState()) {
- case VisitedNone:
- stack.pop_back();
- break;
- case VisitedLeft:
- stack.back() &= ~Flags; // Set state to "VisitedNone."
- if (TreeTy* L = Current->getLeft())
- stack.push_back(reinterpret_cast<uintptr_t>(L) | VisitedRight);
- break;
- case VisitedRight:
- stack.back() &= ~Flags;
- stack.back() |= VisitedLeft;
- if (TreeTy* R = Current->getRight())
- stack.push_back(reinterpret_cast<uintptr_t>(R) | VisitedRight);
- break;
- default:
- llvm_unreachable("Unreachable.");
- }
- return *this;
- }
-};
-
-template <typename ImutInfo>
-class ImutAVLTreeInOrderIterator
- : public std::iterator<std::bidirectional_iterator_tag,
- ImutAVLTree<ImutInfo>> {
- using InternalIteratorTy = ImutAVLTreeGenericIterator<ImutInfo>;
-
- InternalIteratorTy InternalItr;
-
-public:
- using TreeTy = ImutAVLTree<ImutInfo>;
-
- ImutAVLTreeInOrderIterator(const TreeTy* Root) : InternalItr(Root) {
- if (Root)
- ++*this; // Advance to first element.
- }
-
- ImutAVLTreeInOrderIterator() : InternalItr() {}
-
- bool operator==(const ImutAVLTreeInOrderIterator &x) const {
- return InternalItr == x.InternalItr;
- }
-
- bool operator!=(const ImutAVLTreeInOrderIterator &x) const {
- return !(*this == x);
- }
-
- TreeTy &operator*() const { return *InternalItr; }
- TreeTy *operator->() const { return &*InternalItr; }
-
- ImutAVLTreeInOrderIterator &operator++() {
- do ++InternalItr;
- while (!InternalItr.atEnd() &&
- InternalItr.getVisitState() != InternalIteratorTy::VisitedLeft);
-
- return *this;
- }
-
- ImutAVLTreeInOrderIterator &operator--() {
- do --InternalItr;
- while (!InternalItr.atBeginning() &&
- InternalItr.getVisitState() != InternalIteratorTy::VisitedLeft);
-
- return *this;
- }
-
- void skipSubTree() {
- InternalItr.skipToParent();
-
- while (!InternalItr.atEnd() &&
- InternalItr.getVisitState() != InternalIteratorTy::VisitedLeft)
- ++InternalItr;
- }
-};
-
-/// Generic iterator that wraps a T::TreeTy::iterator and exposes
-/// iterator::getValue() on dereference.
-template <typename T>
-struct ImutAVLValueIterator
- : iterator_adaptor_base<
- ImutAVLValueIterator<T>, typename T::TreeTy::iterator,
- typename std::iterator_traits<
- typename T::TreeTy::iterator>::iterator_category,
- const typename T::value_type> {
- ImutAVLValueIterator() = default;
- explicit ImutAVLValueIterator(typename T::TreeTy *Tree)
- : ImutAVLValueIterator::iterator_adaptor_base(Tree) {}
-
- typename ImutAVLValueIterator::reference operator*() const {
- return this->I->getValue();
- }
-};
-
-//===----------------------------------------------------------------------===//
-// Trait classes for Profile information.
-//===----------------------------------------------------------------------===//
-
-/// Generic profile template. The default behavior is to invoke the
-/// profile method of an object. Specializations for primitive integers
-/// and generic handling of pointers is done below.
-template <typename T>
-struct ImutProfileInfo {
- using value_type = const T;
- using value_type_ref = const T&;
-
- static void Profile(FoldingSetNodeID &ID, value_type_ref X) {
- FoldingSetTrait<T>::Profile(X,ID);
- }
-};
-
-/// Profile traits for integers.
-template <typename T>
-struct ImutProfileInteger {
- using value_type = const T;
- using value_type_ref = const T&;
-
- static void Profile(FoldingSetNodeID &ID, value_type_ref X) {
- ID.AddInteger(X);
- }
-};
-
-#define PROFILE_INTEGER_INFO(X)\
-template<> struct ImutProfileInfo<X> : ImutProfileInteger<X> {};
-
-PROFILE_INTEGER_INFO(char)
-PROFILE_INTEGER_INFO(unsigned char)
-PROFILE_INTEGER_INFO(short)
-PROFILE_INTEGER_INFO(unsigned short)
-PROFILE_INTEGER_INFO(unsigned)
-PROFILE_INTEGER_INFO(signed)
-PROFILE_INTEGER_INFO(long)
-PROFILE_INTEGER_INFO(unsigned long)
-PROFILE_INTEGER_INFO(long long)
-PROFILE_INTEGER_INFO(unsigned long long)
-
-#undef PROFILE_INTEGER_INFO
-
-/// Profile traits for booleans.
-template <>
-struct ImutProfileInfo<bool> {
- using value_type = const bool;
- using value_type_ref = const bool&;
-
- static void Profile(FoldingSetNodeID &ID, value_type_ref X) {
- ID.AddBoolean(X);
- }
-};
-
-/// Generic profile trait for pointer types. We treat pointers as
-/// references to unique objects.
-template <typename T>
-struct ImutProfileInfo<T*> {
- using value_type = const T*;
- using value_type_ref = value_type;
-
- static void Profile(FoldingSetNodeID &ID, value_type_ref X) {
- ID.AddPointer(X);
- }
-};
-
-//===----------------------------------------------------------------------===//
-// Trait classes that contain element comparison operators and type
-// definitions used by ImutAVLTree, ImmutableSet, and ImmutableMap. These
-// inherit from the profile traits (ImutProfileInfo) to include operations
-// for element profiling.
-//===----------------------------------------------------------------------===//
-
-/// ImutContainerInfo - Generic definition of comparison operations for
-/// elements of immutable containers that defaults to using
-/// std::equal_to<> and std::less<> to perform comparison of elements.
-template <typename T>
-struct ImutContainerInfo : public ImutProfileInfo<T> {
- using value_type = typename ImutProfileInfo<T>::value_type;
- using value_type_ref = typename ImutProfileInfo<T>::value_type_ref;
- using key_type = value_type;
- using key_type_ref = value_type_ref;
- using data_type = bool;
- using data_type_ref = bool;
-
- static key_type_ref KeyOfValue(value_type_ref D) { return D; }
- static data_type_ref DataOfValue(value_type_ref) { return true; }
-
- static bool isEqual(key_type_ref LHS, key_type_ref RHS) {
- return std::equal_to<key_type>()(LHS,RHS);
- }
-
- static bool isLess(key_type_ref LHS, key_type_ref RHS) {
- return std::less<key_type>()(LHS,RHS);
- }
-
- static bool isDataEqual(data_type_ref, data_type_ref) { return true; }
-};
-
-/// ImutContainerInfo - Specialization for pointer values to treat pointers
-/// as references to unique objects. Pointers are thus compared by
-/// their addresses.
-template <typename T>
-struct ImutContainerInfo<T*> : public ImutProfileInfo<T*> {
- using value_type = typename ImutProfileInfo<T*>::value_type;
- using value_type_ref = typename ImutProfileInfo<T*>::value_type_ref;
- using key_type = value_type;
- using key_type_ref = value_type_ref;
- using data_type = bool;
- using data_type_ref = bool;
-
- static key_type_ref KeyOfValue(value_type_ref D) { return D; }
- static data_type_ref DataOfValue(value_type_ref) { return true; }
-
- static bool isEqual(key_type_ref LHS, key_type_ref RHS) { return LHS == RHS; }
-
- static bool isLess(key_type_ref LHS, key_type_ref RHS) { return LHS < RHS; }
-
- static bool isDataEqual(data_type_ref, data_type_ref) { return true; }
-};
-
-//===----------------------------------------------------------------------===//
-// Immutable Set
-//===----------------------------------------------------------------------===//
-
-template <typename ValT, typename ValInfo = ImutContainerInfo<ValT>>
-class ImmutableSet {
-public:
- using value_type = typename ValInfo::value_type;
- using value_type_ref = typename ValInfo::value_type_ref;
- using TreeTy = ImutAVLTree<ValInfo>;
-
-private:
- IntrusiveRefCntPtr<TreeTy> Root;
-
-public:
- /// Constructs a set from a pointer to a tree root. In general one
- /// should use a Factory object to create sets instead of directly
- /// invoking the constructor, but there are cases where make this
- /// constructor public is useful.
- explicit ImmutableSet(TreeTy *R) : Root(R) {}
-
- class Factory {
- typename TreeTy::Factory F;
- const bool Canonicalize;
-
- public:
- Factory(bool canonicalize = true)
- : Canonicalize(canonicalize) {}
-
- Factory(BumpPtrAllocator& Alloc, bool canonicalize = true)
- : F(Alloc), Canonicalize(canonicalize) {}
-
- Factory(const Factory& RHS) = delete;
- void operator=(const Factory& RHS) = delete;
-
- /// getEmptySet - Returns an immutable set that contains no elements.
- ImmutableSet getEmptySet() {
- return ImmutableSet(F.getEmptyTree());
- }
-
- /// add - Creates a new immutable set that contains all of the values
- /// of the original set with the addition of the specified value. If
- /// the original set already included the value, then the original set is
- /// returned and no memory is allocated. The time and space complexity
- /// of this operation is logarithmic in the size of the original set.
- /// The memory allocated to represent the set is released when the
- /// factory object that created the set is destroyed.
- LLVM_NODISCARD ImmutableSet add(ImmutableSet Old, value_type_ref V) {
- TreeTy *NewT = F.add(Old.Root.get(), V);
- return ImmutableSet(Canonicalize ? F.getCanonicalTree(NewT) : NewT);
- }
-
- /// remove - Creates a new immutable set that contains all of the values
- /// of the original set with the exception of the specified value. If
- /// the original set did not contain the value, the original set is
- /// returned and no memory is allocated. The time and space complexity
- /// of this operation is logarithmic in the size of the original set.
- /// The memory allocated to represent the set is released when the
- /// factory object that created the set is destroyed.
- LLVM_NODISCARD ImmutableSet remove(ImmutableSet Old, value_type_ref V) {
- TreeTy *NewT = F.remove(Old.Root.get(), V);
- return ImmutableSet(Canonicalize ? F.getCanonicalTree(NewT) : NewT);
- }
-
- BumpPtrAllocator& getAllocator() { return F.getAllocator(); }
-
- typename TreeTy::Factory *getTreeFactory() const {
- return const_cast<typename TreeTy::Factory *>(&F);
- }
- };
-
- friend class Factory;
-
- /// Returns true if the set contains the specified value.
- bool contains(value_type_ref V) const {
- return Root ? Root->contains(V) : false;
- }
-
- bool operator==(const ImmutableSet &RHS) const {
- return Root && RHS.Root ? Root->isEqual(*RHS.Root.get()) : Root == RHS.Root;
- }
-
- bool operator!=(const ImmutableSet &RHS) const {
- return Root && RHS.Root ? Root->isNotEqual(*RHS.Root.get())
- : Root != RHS.Root;
- }
-
- TreeTy *getRoot() {
- if (Root) { Root->retain(); }
- return Root.get();
- }
-
- TreeTy *getRootWithoutRetain() const { return Root.get(); }
-
- /// isEmpty - Return true if the set contains no elements.
- bool isEmpty() const { return !Root; }
-
- /// isSingleton - Return true if the set contains exactly one element.
- /// This method runs in constant time.
- bool isSingleton() const { return getHeight() == 1; }
-
- template <typename Callback>
- void foreach(Callback& C) { if (Root) Root->foreach(C); }
-
- template <typename Callback>
- void foreach() { if (Root) { Callback C; Root->foreach(C); } }
-
- //===--------------------------------------------------===//
- // Iterators.
- //===--------------------------------------------------===//
-
- using iterator = ImutAVLValueIterator<ImmutableSet>;
-
- iterator begin() const { return iterator(Root.get()); }
- iterator end() const { return iterator(); }
-
- //===--------------------------------------------------===//
- // Utility methods.
- //===--------------------------------------------------===//
-
- unsigned getHeight() const { return Root ? Root->getHeight() : 0; }
-
- static void Profile(FoldingSetNodeID &ID, const ImmutableSet &S) {
- ID.AddPointer(S.Root.get());
- }
-
- void Profile(FoldingSetNodeID &ID) const { return Profile(ID, *this); }
-
- //===--------------------------------------------------===//
- // For testing.
- //===--------------------------------------------------===//
-
- void validateTree() const { if (Root) Root->validateTree(); }
-};
-
-// NOTE: This may some day replace the current ImmutableSet.
-template <typename ValT, typename ValInfo = ImutContainerInfo<ValT>>
-class ImmutableSetRef {
-public:
- using value_type = typename ValInfo::value_type;
- using value_type_ref = typename ValInfo::value_type_ref;
- using TreeTy = ImutAVLTree<ValInfo>;
- using FactoryTy = typename TreeTy::Factory;
-
-private:
- IntrusiveRefCntPtr<TreeTy> Root;
- FactoryTy *Factory;
-
-public:
- /// Constructs a set from a pointer to a tree root. In general one
- /// should use a Factory object to create sets instead of directly
- /// invoking the constructor, but there are cases where make this
- /// constructor public is useful.
- ImmutableSetRef(TreeTy *R, FactoryTy *F) : Root(R), Factory(F) {}
-
- static ImmutableSetRef getEmptySet(FactoryTy *F) {
- return ImmutableSetRef(0, F);
- }
-
- ImmutableSetRef add(value_type_ref V) {
- return ImmutableSetRef(Factory->add(Root.get(), V), Factory);
- }
-
- ImmutableSetRef remove(value_type_ref V) {
- return ImmutableSetRef(Factory->remove(Root.get(), V), Factory);
- }
-
- /// Returns true if the set contains the specified value.
- bool contains(value_type_ref V) const {
- return Root ? Root->contains(V) : false;
- }
-
- ImmutableSet<ValT> asImmutableSet(bool canonicalize = true) const {
- return ImmutableSet<ValT>(
- canonicalize ? Factory->getCanonicalTree(Root.get()) : Root.get());
- }
-
- TreeTy *getRootWithoutRetain() const { return Root.get(); }
-
- bool operator==(const ImmutableSetRef &RHS) const {
- return Root && RHS.Root ? Root->isEqual(*RHS.Root.get()) : Root == RHS.Root;
- }
-
- bool operator!=(const ImmutableSetRef &RHS) const {
- return Root && RHS.Root ? Root->isNotEqual(*RHS.Root.get())
- : Root != RHS.Root;
- }
-
- /// isEmpty - Return true if the set contains no elements.
- bool isEmpty() const { return !Root; }
-
- /// isSingleton - Return true if the set contains exactly one element.
- /// This method runs in constant time.
- bool isSingleton() const { return getHeight() == 1; }
-
- //===--------------------------------------------------===//
- // Iterators.
- //===--------------------------------------------------===//
-
- using iterator = ImutAVLValueIterator<ImmutableSetRef>;
-
- iterator begin() const { return iterator(Root.get()); }
- iterator end() const { return iterator(); }
-
- //===--------------------------------------------------===//
- // Utility methods.
- //===--------------------------------------------------===//
-
- unsigned getHeight() const { return Root ? Root->getHeight() : 0; }
-
- static void Profile(FoldingSetNodeID &ID, const ImmutableSetRef &S) {
- ID.AddPointer(S.Root.get());
- }
-
- void Profile(FoldingSetNodeID &ID) const { return Profile(ID, *this); }
-
- //===--------------------------------------------------===//
- // For testing.
- //===--------------------------------------------------===//
-
- void validateTree() const { if (Root) Root->validateTree(); }
-};
-
-} // end namespace llvm
-
-#endif // LLVM_ADT_IMMUTABLESET_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ADT/TypeSwitch.h b/contrib/libs/llvm12/include/llvm/ADT/TypeSwitch.h
deleted file mode 100644
index c0a47352b47..00000000000
--- a/contrib/libs/llvm12/include/llvm/ADT/TypeSwitch.h
+++ /dev/null
@@ -1,187 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- TypeSwitch.h - Switch functionality for RTTI casting -*- C++ -*-----===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file implements the TypeSwitch template, which mimics a switch()
-// statement whose cases are type names.
-//
-//===-----------------------------------------------------------------------===/
-
-#ifndef LLVM_ADT_TYPESWITCH_H
-#define LLVM_ADT_TYPESWITCH_H
-
-#include "llvm/ADT/Optional.h"
-#include "llvm/ADT/STLExtras.h"
-#include "llvm/Support/Casting.h"
-
-namespace llvm {
-namespace detail {
-
-template <typename DerivedT, typename T> class TypeSwitchBase {
-public:
- TypeSwitchBase(const T &value) : value(value) {}
- TypeSwitchBase(TypeSwitchBase &&other) : value(other.value) {}
- ~TypeSwitchBase() = default;
-
- /// TypeSwitchBase is not copyable.
- TypeSwitchBase(const TypeSwitchBase &) = delete;
- void operator=(const TypeSwitchBase &) = delete;
- void operator=(TypeSwitchBase &&other) = delete;
-
- /// Invoke a case on the derived class with multiple case types.
- template <typename CaseT, typename CaseT2, typename... CaseTs,
- typename CallableT>
- DerivedT &Case(CallableT &&caseFn) {
- DerivedT &derived = static_cast<DerivedT &>(*this);
- return derived.template Case<CaseT>(caseFn)
- .template Case<CaseT2, CaseTs...>(caseFn);
- }
-
- /// Invoke a case on the derived class, inferring the type of the Case from
- /// the first input of the given callable.
- /// Note: This inference rules for this overload are very simple: strip
- /// pointers and references.
- template <typename CallableT> DerivedT &Case(CallableT &&caseFn) {
- using Traits = function_traits<std::decay_t<CallableT>>;
- using CaseT = std::remove_cv_t<std::remove_pointer_t<
- std::remove_reference_t<typename Traits::template arg_t<0>>>>;
-
- DerivedT &derived = static_cast<DerivedT &>(*this);
- return derived.template Case<CaseT>(std::forward<CallableT>(caseFn));
- }
-
-protected:
- /// Trait to check whether `ValueT` provides a 'dyn_cast' method with type
- /// `CastT`.
- template <typename ValueT, typename CastT>
- using has_dyn_cast_t =
- decltype(std::declval<ValueT &>().template dyn_cast<CastT>());
-
- /// Attempt to dyn_cast the given `value` to `CastT`. This overload is
- /// selected if `value` already has a suitable dyn_cast method.
- template <typename CastT, typename ValueT>
- static auto castValue(
- ValueT value,
- typename std::enable_if_t<
- is_detected<has_dyn_cast_t, ValueT, CastT>::value> * = nullptr) {
- return value.template dyn_cast<CastT>();
- }
-
- /// Attempt to dyn_cast the given `value` to `CastT`. This overload is
- /// selected if llvm::dyn_cast should be used.
- template <typename CastT, typename ValueT>
- static auto castValue(
- ValueT value,
- typename std::enable_if_t<
- !is_detected<has_dyn_cast_t, ValueT, CastT>::value> * = nullptr) {
- return dyn_cast<CastT>(value);
- }
-
- /// The root value we are switching on.
- const T value;
-};
-} // end namespace detail
-
-/// This class implements a switch-like dispatch statement for a value of 'T'
-/// using dyn_cast functionality. Each `Case<T>` takes a callable to be invoked
-/// if the root value isa<T>, the callable is invoked with the result of
-/// dyn_cast<T>() as a parameter.
-///
-/// Example:
-/// Operation *op = ...;
-/// LogicalResult result = TypeSwitch<Operation *, LogicalResult>(op)
-/// .Case<ConstantOp>([](ConstantOp op) { ... })
-/// .Default([](Operation *op) { ... });
-///
-template <typename T, typename ResultT = void>
-class TypeSwitch : public detail::TypeSwitchBase<TypeSwitch<T, ResultT>, T> {
-public:
- using BaseT = detail::TypeSwitchBase<TypeSwitch<T, ResultT>, T>;
- using BaseT::BaseT;
- using BaseT::Case;
- TypeSwitch(TypeSwitch &&other) = default;
-
- /// Add a case on the given type.
- template <typename CaseT, typename CallableT>
- TypeSwitch<T, ResultT> &Case(CallableT &&caseFn) {
- if (result)
- return *this;
-
- // Check to see if CaseT applies to 'value'.
- if (auto caseValue = BaseT::template castValue<CaseT>(this->value))
- result = caseFn(caseValue);
- return *this;
- }
-
- /// As a default, invoke the given callable within the root value.
- template <typename CallableT>
- LLVM_NODISCARD ResultT Default(CallableT &&defaultFn) {
- if (result)
- return std::move(*result);
- return defaultFn(this->value);
- }
-
- LLVM_NODISCARD
- operator ResultT() {
- assert(result && "Fell off the end of a type-switch");
- return std::move(*result);
- }
-
-private:
- /// The pointer to the result of this switch statement, once known,
- /// null before that.
- Optional<ResultT> result;
-};
-
-/// Specialization of TypeSwitch for void returning callables.
-template <typename T>
-class TypeSwitch<T, void>
- : public detail::TypeSwitchBase<TypeSwitch<T, void>, T> {
-public:
- using BaseT = detail::TypeSwitchBase<TypeSwitch<T, void>, T>;
- using BaseT::BaseT;
- using BaseT::Case;
- TypeSwitch(TypeSwitch &&other) = default;
-
- /// Add a case on the given type.
- template <typename CaseT, typename CallableT>
- TypeSwitch<T, void> &Case(CallableT &&caseFn) {
- if (foundMatch)
- return *this;
-
- // Check to see if any of the types apply to 'value'.
- if (auto caseValue = BaseT::template castValue<CaseT>(this->value)) {
- caseFn(caseValue);
- foundMatch = true;
- }
- return *this;
- }
-
- /// As a default, invoke the given callable within the root value.
- template <typename CallableT> void Default(CallableT &&defaultFn) {
- if (!foundMatch)
- defaultFn(this->value);
- }
-
-private:
- /// A flag detailing if we have already found a match.
- bool foundMatch = false;
-};
-} // end namespace llvm
-
-#endif // LLVM_ADT_TYPESWITCH_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ADT/Waymarking.h b/contrib/libs/llvm12/include/llvm/ADT/Waymarking.h
deleted file mode 100644
index e71ab24f14b..00000000000
--- a/contrib/libs/llvm12/include/llvm/ADT/Waymarking.h
+++ /dev/null
@@ -1,336 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- Waymarking.h - Array waymarking algorithm ----------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// Utility to backtrace an array's head, from a pointer into it. For the
-// backtrace to work, we use "Waymarks", which are special tags embedded into
-// the array's elements.
-//
-// A Tag of n-bits (in size) is composed as follows:
-//
-// bits: | n-1 | n-2 ... 0 |
-// .---------.------------------------------------.
-// |Stop Mask|(2^(n-1))-ary numeric system - digit|
-// '---------'------------------------------------'
-//
-// Backtracing is done as follows:
-// Walk back (starting from a given pointer to an element into the array), until
-// a tag with a "Stop Mask" is reached. Then start calculating the "Offset" from
-// the array's head, by picking up digits along the way, until another stop is
-// reached. The "Offset" is then subtracted from the current pointer, and the
-// result is the array's head.
-// A special case - if we first encounter a Tag with a Stop and a zero digit,
-// then this is already the head.
-//
-// For example:
-// In case of 2 bits:
-//
-// Tags:
-// x0 - binary digit 0
-// x1 - binary digit 1
-// 1x - stop and calculate (s)
-//
-// Array:
-// .---.---.---.---.---.---.---.---.---.---.---.---.---.---.---.---.
-// head -> |s0 |s1 | 0 |s1 | 0 | 0 |s1 | 1 | 1 |s1 | 0 | 1 | 0 |s1 | 0 | 1 |
-// '---'---'---'---'---'---'---'---'---'---'---'---'---'---'---'---'
-// |-1 |-2 |-4 |-7 |-10 |-14
-// <_ | | | | | |
-// <_____ | | | | |
-// <_____________ | | | |
-// <_________________________ | | |
-// <_____________________________________ | |
-// <_____________________________________________________ |
-//
-//
-// In case of 3 bits:
-//
-// Tags:
-// x00 - quaternary digit 0
-// x01 - quaternary digit 1
-// x10 - quaternary digit 2
-// x11 - quaternary digit 3
-// 1xy - stop and calculate (s)
-//
-// Array:
-// .---.---.---.---.---.---.---.---.---.---.---.---.---.---.---.---.
-// head -> |s0 |s1 |s2 |s3 | 0 |s1 | 2 |s1 | 0 |s2 | 2 |s2 | 0 |s3 | 2 |s3 |
-// '---'---'---'---'---'---'---'---'---'---'---'---'---'---'---'---'
-// |-1 |-2 |-3 |-4 |-6 |-8 |-10 |-12 |-14 |-16
-// <_ | | | | | | | | | |
-// <_____ | | | | | | | | |
-// <_________ | | | | | | | |
-// <_____________ | | | | | | |
-// <_____________________ | | | | | |
-// <_____________________________ | | | | |
-// <_____________________________________ | | | |
-// <_____________________________________________ | | |
-// <_____________________________________________________ | |
-// <_____________________________________________________________ |
-//
-//
-// The API introduce 2 functions:
-// 1. fillWaymarks
-// 2. followWaymarks
-//
-// Example:
-// int N = 10;
-// int M = 5;
-// int **A = new int *[N + M]; // Define the array.
-// for (int I = 0; I < N + M; ++I)
-// A[I] = new int(I);
-//
-// fillWaymarks(A, A + N); // Set the waymarks for the first N elements
-// // of the array.
-// // Note that it must be done AFTER we fill
-// // the array's elements.
-//
-// ... // Elements which are not in the range
-// // [A, A+N) will not be marked, and we won't
-// // be able to call followWaymarks on them.
-//
-// ... // Elements which will be changed after the
-// // call to fillWaymarks, will have to be
-// // retagged.
-//
-// fillWaymarks(A + N, A + N + M, N); // Set the waymarks of the remaining M
-// // elements.
-// ...
-// int **It = A + N + 1;
-// int **B = followWaymarks(It); // Find the head of the array containing It.
-// assert(B == A);
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_ADT_WAYMARKING_H
-#define LLVM_ADT_WAYMARKING_H
-
-#include "llvm/ADT/STLExtras.h"
-#include "llvm/Support/PointerLikeTypeTraits.h"
-
-namespace llvm {
-
-namespace detail {
-
-template <unsigned NumBits> struct WaymarkingTraits {
- enum : unsigned {
- // The number of bits of a Waymarking Tag.
- NUM_BITS = NumBits,
-
- // A Tag is composed from a Mark and a Stop mask.
- MARK_SIZE = NUM_BITS - 1,
- STOP_MASK = (1 << MARK_SIZE),
- MARK_MASK = (STOP_MASK - 1),
- TAG_MASK = (MARK_MASK | STOP_MASK),
-
- // The number of pre-computed tags (for fast fill).
- NUM_STATIC_TAGS = 32
- };
-
-private:
- // Add a new tag, calculated from Count and Stop, to the Vals pack, while
- // continuing recursively to decrease Len down to 0.
- template <unsigned Len, bool Stop, unsigned Count, uint8_t... Vals>
- struct AddTag;
-
- // Delegate to the specialized AddTag according to the need of a Stop mask.
- template <unsigned Len, unsigned Count, uint8_t... Vals> struct GenTag {
- typedef
- typename AddTag<Len, (Count <= MARK_MASK), Count, Vals...>::Xdata Xdata;
- };
-
- // Start adding tags while calculating the next Count, which is actually the
- // number of already calculated tags (equivalent to the position in the
- // array).
- template <unsigned Len, uint8_t... Vals> struct GenOffset {
- typedef typename GenTag<Len, sizeof...(Vals), Vals...>::Xdata Xdata;
- };
-
- // Add the tag and remove it from Count.
- template <unsigned Len, unsigned Count, uint8_t... Vals>
- struct AddTag<Len, false, Count, Vals...> {
- typedef typename GenTag<Len - 1, (Count >> MARK_SIZE), Vals...,
- Count & MARK_MASK>::Xdata Xdata;
- };
-
- // We have reached the end of this Count, so start with a new Count.
- template <unsigned Len, unsigned Count, uint8_t... Vals>
- struct AddTag<Len, true, Count, Vals...> {
- typedef typename GenOffset<Len - 1, Vals...,
- (Count & MARK_MASK) | STOP_MASK>::Xdata Xdata;
- };
-
- template <unsigned Count, uint8_t... Vals> struct TagsData {
- // The remaining number for calculating the next tag, following the last one
- // in Values.
- static const unsigned Remain = Count;
-
- // The array of ordered pre-computed Tags.
- static const uint8_t Values[sizeof...(Vals)];
- };
-
- // Specialize the case when Len equals 0, as the recursion stop condition.
- template <unsigned Count, uint8_t... Vals>
- struct AddTag<0, false, Count, Vals...> {
- typedef TagsData<Count, Vals...> Xdata;
- };
-
- template <unsigned Count, uint8_t... Vals>
- struct AddTag<0, true, Count, Vals...> {
- typedef TagsData<Count, Vals...> Xdata;
- };
-
-public:
- typedef typename GenOffset<NUM_STATIC_TAGS>::Xdata Tags;
-};
-
-template <unsigned NumBits>
-template <unsigned Count, uint8_t... Vals>
-const uint8_t WaymarkingTraits<NumBits>::TagsData<
- Count, Vals...>::Values[sizeof...(Vals)] = {Vals...};
-
-} // end namespace detail
-
-/// This class is responsible for tagging (and retrieving the tag of) a given
-/// element of type T.
-template <class T, class WTraits = detail::WaymarkingTraits<
- PointerLikeTypeTraits<T>::NumLowBitsAvailable>>
-struct Waymarker {
- using Traits = WTraits;
- static void setWaymark(T &N, unsigned Tag) { N.setWaymark(Tag); }
- static unsigned getWaymark(const T &N) { return N.getWaymark(); }
-};
-
-template <class T, class WTraits> struct Waymarker<T *, WTraits> {
- using Traits = WTraits;
- static void setWaymark(T *&N, unsigned Tag) {
- reinterpret_cast<uintptr_t &>(N) |= static_cast<uintptr_t>(Tag);
- }
- static unsigned getWaymark(const T *N) {
- return static_cast<unsigned>(reinterpret_cast<uintptr_t>(N)) &
- Traits::TAG_MASK;
- }
-};
-
-/// Sets up the waymarking algorithm's tags for a given range [Begin, End).
-///
-/// \param Begin The beginning of the range to mark with tags (inclusive).
-/// \param End The ending of the range to mark with tags (exclusive).
-/// \param Offset The position in the supposed tags array from which to start
-/// marking the given range.
-template <class TIter, class Marker = Waymarker<
- typename std::iterator_traits<TIter>::value_type>>
-void fillWaymarks(TIter Begin, TIter End, size_t Offset = 0) {
- if (Begin == End)
- return;
-
- size_t Count = Marker::Traits::Tags::Remain;
- if (Offset <= Marker::Traits::NUM_STATIC_TAGS) {
- // Start by filling the pre-calculated tags, starting from the given offset.
- while (Offset != Marker::Traits::NUM_STATIC_TAGS) {
- Marker::setWaymark(*Begin, Marker::Traits::Tags::Values[Offset]);
-
- ++Offset;
- ++Begin;
-
- if (Begin == End)
- return;
- }
- } else {
- // The given offset is larger than the number of pre-computed tags, so we
- // must do it the hard way.
- // Calculate the next remaining Count, as if we have filled the tags up to
- // the given offset.
- size_t Off = Marker::Traits::NUM_STATIC_TAGS;
- do {
- ++Off;
-
- unsigned Tag = Count & Marker::Traits::MARK_MASK;
-
- // If the count can fit into the tag, then the counting must stop.
- if (Count <= Marker::Traits::MARK_MASK) {
- Tag |= Marker::Traits::STOP_MASK;
- Count = Off;
- } else
- Count >>= Marker::Traits::MARK_SIZE;
- } while (Off != Offset);
- }
-
- // By now, we have the matching remaining Count for the current offset.
- do {
- ++Offset;
-
- unsigned Tag = Count & Marker::Traits::MARK_MASK;
-
- // If the count can fit into the tag, then the counting must stop.
- if (Count <= Marker::Traits::MARK_MASK) {
- Tag |= Marker::Traits::STOP_MASK;
- Count = Offset;
- } else
- Count >>= Marker::Traits::MARK_SIZE;
-
- Marker::setWaymark(*Begin, Tag);
- ++Begin;
- } while (Begin != End);
-}
-
-/// Sets up the waymarking algorithm's tags for a given range.
-///
-/// \param Range The range to mark with tags.
-/// \param Offset The position in the supposed tags array from which to start
-/// marking the given range.
-template <typename R, class Marker = Waymarker<typename std::remove_reference<
- decltype(*std::begin(std::declval<R &>()))>::type>>
-void fillWaymarks(R &&Range, size_t Offset = 0) {
- return fillWaymarks<decltype(std::begin(std::declval<R &>())), Marker>(
- adl_begin(Range), adl_end(Range), Offset);
-}
-
-/// Retrieves the element marked with tag of only STOP_MASK, by following the
-/// waymarks. This is the first element in a range passed to a previous call to
-/// \c fillWaymarks with \c Offset 0.
-///
-/// For the trivial usage of calling \c fillWaymarks(Array), and \I is an
-/// iterator inside \c Array, this function retrieves the head of \c Array, by
-/// following the waymarks.
-///
-/// \param I The iterator into an array which was marked by the waymarking tags
-/// (by a previous call to \c fillWaymarks).
-template <class TIter, class Marker = Waymarker<
- typename std::iterator_traits<TIter>::value_type>>
-TIter followWaymarks(TIter I) {
- unsigned Tag;
- do
- Tag = Marker::getWaymark(*I--);
- while (!(Tag & Marker::Traits::STOP_MASK));
-
- // Special case for the first Use.
- if (Tag != Marker::Traits::STOP_MASK) {
- ptrdiff_t Offset = Tag & Marker::Traits::MARK_MASK;
- while (!((Tag = Marker::getWaymark(*I)) & Marker::Traits::STOP_MASK)) {
- Offset = (Offset << Marker::Traits::MARK_SIZE) + Tag;
- --I;
- }
- I -= Offset;
- }
- return ++I;
-}
-
-} // end namespace llvm
-
-#endif // LLVM_ADT_WAYMARKING_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Bitcode/BitcodeConvenience.h b/contrib/libs/llvm12/include/llvm/Bitcode/BitcodeConvenience.h
deleted file mode 100644
index a0b837d3ffc..00000000000
--- a/contrib/libs/llvm12/include/llvm/Bitcode/BitcodeConvenience.h
+++ /dev/null
@@ -1,497 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- llvm/Bitcode/BitcodeConvenience.h - Convenience Wrappers -*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-///
-/// \file Convenience wrappers for the LLVM bitcode format and bitstream APIs.
-///
-/// This allows you to use a sort of DSL to declare and use bitcode
-/// abbreviations and records. Example:
-///
-/// \code
-/// using Metadata = BCRecordLayout<
-/// METADATA_ID, // ID
-/// BCFixed<16>, // Module format major version
-/// BCFixed<16>, // Module format minor version
-/// BCBlob // misc. version information
-/// >;
-/// Metadata metadata(Out);
-/// metadata.emit(ScratchRecord, VERSION_MAJOR, VERSION_MINOR, Data);
-/// \endcode
-///
-/// For details on the bitcode format, see
-/// http://llvm.org/docs/BitCodeFormat.html
-///
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_BITCODE_BITCODECONVENIENCE_H
-#define LLVM_BITCODE_BITCODECONVENIENCE_H
-
-#include "llvm/Bitstream/BitCodes.h"
-#include "llvm/Bitstream/BitstreamWriter.h"
-#include <cstdint>
-
-namespace llvm {
-namespace detail {
-/// Convenience base for all kinds of bitcode abbreviation fields.
-///
-/// This just defines common properties queried by the metaprogramming.
-template <bool Compound = false> class BCField {
-public:
- static const bool IsCompound = Compound;
-
- /// Asserts that the given data is a valid value for this field.
- template <typename T> static void assertValid(const T &data) {}
-
- /// Converts a raw numeric representation of this value to its preferred
- /// type.
- template <typename T> static T convert(T rawValue) { return rawValue; }
-};
-} // namespace detail
-
-/// Represents a literal operand in a bitcode record.
-///
-/// The value of a literal operand is the same for all instances of the record,
-/// so it is only emitted in the abbreviation definition.
-///
-/// Note that because this uses a compile-time template, you cannot have a
-/// literal operand that is fixed at run-time without dropping down to the
-/// raw LLVM APIs.
-template <uint64_t Value> class BCLiteral : public detail::BCField<> {
-public:
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(Value));
- }
-
- template <typename T> static void assertValid(const T &data) {
- assert(data == Value && "data value does not match declared literal value");
- }
-};
-
-/// Represents a fixed-width value in a bitcode record.
-///
-/// Note that the LLVM bitcode format only supports unsigned values.
-template <unsigned Width> class BCFixed : public detail::BCField<> {
-public:
- static_assert(Width <= 64, "fixed-width field is too large");
-
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Fixed, Width));
- }
-
- static void assertValid(const bool &data) {
- assert(llvm::isUInt<Width>(data) &&
- "data value does not fit in the given bit width");
- }
-
- template <typename T> static void assertValid(const T &data) {
- assert(data >= 0 && "cannot encode signed integers");
- assert(llvm::isUInt<Width>(data) &&
- "data value does not fit in the given bit width");
- }
-};
-
-/// Represents a variable-width value in a bitcode record.
-///
-/// The \p Width parameter should include the continuation bit.
-///
-/// Note that the LLVM bitcode format only supports unsigned values.
-template <unsigned Width> class BCVBR : public detail::BCField<> {
- static_assert(Width >= 2, "width does not have room for continuation bit");
-
-public:
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::VBR, Width));
- }
-
- template <typename T> static void assertValid(const T &data) {
- assert(data >= 0 && "cannot encode signed integers");
- }
-};
-
-/// Represents a character encoded in LLVM's Char6 encoding.
-///
-/// This format is suitable for encoding decimal numbers (without signs or
-/// exponents) and C identifiers (without dollar signs), but not much else.
-///
-/// \sa http://llvm.org/docs/BitCodeFormat.html#char6-encoded-value
-class BCChar6 : public detail::BCField<> {
-public:
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Char6));
- }
-
- template <typename T> static void assertValid(const T &data) {
- assert(llvm::BitCodeAbbrevOp::isChar6(data) && "invalid Char6 data");
- }
-
- template <typename T> char convert(T rawValue) {
- return static_cast<char>(rawValue);
- }
-};
-
-/// Represents an untyped blob of bytes.
-///
-/// If present, this must be the last field in a record.
-class BCBlob : public detail::BCField<true> {
-public:
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Blob));
- }
-};
-
-/// Represents an array of some other type.
-///
-/// If present, this must be the last field in a record.
-template <typename ElementTy> class BCArray : public detail::BCField<true> {
- static_assert(!ElementTy::IsCompound, "arrays can only contain scalar types");
-
-public:
- static void emitOp(llvm::BitCodeAbbrev &abbrev) {
- abbrev.Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Array));
- ElementTy::emitOp(abbrev);
- }
-};
-
-namespace detail {
-/// Attaches the last field to an abbreviation.
-///
-/// This is the base case for \c emitOps.
-///
-/// \sa BCRecordLayout::emitAbbrev
-template <typename FieldTy> static void emitOps(llvm::BitCodeAbbrev &abbrev) {
- FieldTy::emitOp(abbrev);
-}
-
-/// Attaches fields to an abbreviation.
-///
-/// This is the recursive case for \c emitOps.
-///
-/// \sa BCRecordLayout::emitAbbrev
-template <typename FieldTy, typename Next, typename... Rest>
-static void emitOps(llvm::BitCodeAbbrev &abbrev) {
- static_assert(!FieldTy::IsCompound,
- "arrays and blobs may not appear in the middle of a record");
- FieldTy::emitOp(abbrev);
- emitOps<Next, Rest...>(abbrev);
-}
-
-/// Helper class for dealing with a scalar element in the middle of a record.
-///
-/// \sa BCRecordLayout
-template <typename ElementTy, typename... Fields> class BCRecordCoding {
-public:
- template <typename BufferTy, typename ElementDataTy, typename... DataTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, ElementDataTy element, DataTy &&...data) {
- static_assert(!ElementTy::IsCompound,
- "arrays and blobs may not appear in the middle of a record");
- ElementTy::assertValid(element);
- buffer.push_back(element);
- BCRecordCoding<Fields...>::emit(Stream, buffer, code,
- std::forward<DataTy>(data)...);
- }
-
- template <typename T, typename ElementDataTy, typename... DataTy>
- static void read(ArrayRef<T> buffer, ElementDataTy &element,
- DataTy &&...data) {
- assert(!buffer.empty() && "too few elements in buffer");
- element = ElementTy::convert(buffer.front());
- BCRecordCoding<Fields...>::read(buffer.slice(1),
- std::forward<DataTy>(data)...);
- }
-
- template <typename T, typename... DataTy>
- static void read(ArrayRef<T> buffer, NoneType, DataTy &&...data) {
- assert(!buffer.empty() && "too few elements in buffer");
- BCRecordCoding<Fields...>::read(buffer.slice(1),
- std::forward<DataTy>(data)...);
- }
-};
-
-/// Helper class for dealing with a scalar element at the end of a record.
-///
-/// This has a separate implementation because up until now we've only been
-/// \em building the record (into a data buffer), and now we need to hand it
-/// off to the BitstreamWriter to be emitted.
-///
-/// \sa BCRecordLayout
-template <typename ElementTy> class BCRecordCoding<ElementTy> {
-public:
- template <typename BufferTy, typename DataTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, const DataTy &data) {
- static_assert(!ElementTy::IsCompound,
- "arrays and blobs need special handling");
- ElementTy::assertValid(data);
- buffer.push_back(data);
- Stream.EmitRecordWithAbbrev(code, buffer);
- }
-
- template <typename T, typename DataTy>
- static void read(ArrayRef<T> buffer, DataTy &data) {
- assert(buffer.size() == 1 && "record data does not match layout");
- data = ElementTy::convert(buffer.front());
- }
-
- template <typename T> static void read(ArrayRef<T> buffer, NoneType) {
- assert(buffer.size() == 1 && "record data does not match layout");
- (void)buffer;
- }
-
- template <typename T> static void read(ArrayRef<T> buffer) = delete;
-};
-
-/// Helper class for dealing with an array at the end of a record.
-///
-/// \sa BCRecordLayout::emitRecord
-template <typename ElementTy> class BCRecordCoding<BCArray<ElementTy>> {
-public:
- template <typename BufferTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, StringRef data) {
- // TODO: validate array data.
- Stream.EmitRecordWithArray(code, buffer, data);
- }
-
- template <typename BufferTy, typename ArrayTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, const ArrayTy &array) {
-#ifndef NDEBUG
- for (auto &element : array)
- ElementTy::assertValid(element);
-#endif
- buffer.reserve(buffer.size() + std::distance(array.begin(), array.end()));
- std::copy(array.begin(), array.end(), std::back_inserter(buffer));
- Stream.EmitRecordWithAbbrev(code, buffer);
- }
-
- template <typename BufferTy, typename ElementDataTy, typename... DataTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, ElementDataTy element, DataTy... data) {
- std::array<ElementDataTy, 1 + sizeof...(data)> array{{element, data...}};
- emit(Stream, buffer, code, array);
- }
-
- template <typename BufferTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &Buffer,
- unsigned code, NoneType) {
- Stream.EmitRecordWithAbbrev(code, Buffer);
- }
-
- template <typename T>
- static void read(ArrayRef<T> Buffer, ArrayRef<T> &rawData) {
- rawData = Buffer;
- }
-
- template <typename T, typename ArrayTy>
- static void read(ArrayRef<T> buffer, ArrayTy &array) {
- array.append(llvm::map_iterator(buffer.begin(), T::convert),
- llvm::map_iterator(buffer.end(), T::convert));
- }
-
- template <typename T> static void read(ArrayRef<T> buffer, NoneType) {
- (void)buffer;
- }
-
- template <typename T> static void read(ArrayRef<T> buffer) = delete;
-};
-
-/// Helper class for dealing with a blob at the end of a record.
-///
-/// \sa BCRecordLayout
-template <> class BCRecordCoding<BCBlob> {
-public:
- template <typename BufferTy>
- static void emit(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned code, StringRef data) {
- Stream.EmitRecordWithBlob(code, buffer, data);
- }
-
- template <typename T> static void read(ArrayRef<T> buffer) { (void)buffer; }
-
- /// Blob data is not stored in the buffer if you are using the correct
- /// accessor; this method should not be used.
- template <typename T, typename DataTy>
- static void read(ArrayRef<T> buffer, DataTy &data) = delete;
-};
-
-/// A type trait whose \c type field is the last of its template parameters.
-template <typename Head, typename... Tail> struct last_type {
- using type = typename last_type<Tail...>::type;
-};
-
-template <typename Head> struct last_type<Head> { using type = Head; };
-
-/// A type trait whose \c value field is \c true if the last type is BCBlob.
-template <typename... Types>
-using has_blob = std::is_same<BCBlob, typename last_type<int, Types...>::type>;
-
-/// A type trait whose \c value field is \c true if the given type is a
-/// BCArray (of any element kind).
-template <typename T> struct is_array {
-private:
- template <typename E> static bool check(BCArray<E> *);
- static int check(...);
-
-public:
- typedef bool value_type;
- static constexpr bool value = !std::is_same<decltype(check((T *)nullptr)),
- decltype(check(false))>::value;
-};
-
-/// A type trait whose \c value field is \c true if the last type is a
-/// BCArray (of any element kind).
-template <typename... Types>
-using has_array = is_array<typename last_type<int, Types...>::type>;
-} // namespace detail
-
-/// Represents a single bitcode record type.
-///
-/// This class template is meant to be instantiated and then given a name,
-/// so that from then on that name can be used.
-template <typename IDField, typename... Fields> class BCGenericRecordLayout {
- llvm::BitstreamWriter &Stream;
-
-public:
- /// The abbreviation code used for this record in the current block.
- ///
- /// Note that this is not the same as the semantic record code, which is the
- /// first field of the record.
- const unsigned AbbrevCode;
-
- /// Create a layout and register it with the given bitstream writer.
- explicit BCGenericRecordLayout(llvm::BitstreamWriter &Stream)
- : Stream(Stream), AbbrevCode(emitAbbrev(Stream)) {}
-
- /// Emit a record to the bitstream writer, using the given buffer for scratch
- /// space.
- ///
- /// Note that even fixed arguments must be specified here.
- template <typename BufferTy, typename... Data>
- void emit(BufferTy &buffer, unsigned id, Data &&...data) const {
- emitRecord(Stream, buffer, AbbrevCode, id, std::forward<Data>(data)...);
- }
-
- /// Registers this record's layout with the bitstream reader.
- ///
- /// eturns The abbreviation code for the newly-registered record type.
- static unsigned emitAbbrev(llvm::BitstreamWriter &Stream) {
- auto Abbrev = std::make_shared<llvm::BitCodeAbbrev>();
- detail::emitOps<IDField, Fields...>(*Abbrev);
- return Stream.EmitAbbrev(std::move(Abbrev));
- }
-
- /// Emit a record identified by \p abbrCode to bitstream reader \p Stream,
- /// using \p buffer for scratch space.
- ///
- /// Note that even fixed arguments must be specified here. Blobs are passed
- /// as StringRefs, while arrays can be passed inline, as aggregates, or as
- /// pre-encoded StringRef data. Skipped values and empty arrays should use
- /// the special Nothing value.
- template <typename BufferTy, typename... Data>
- static void emitRecord(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned abbrCode, unsigned recordID, Data &&...data) {
- static_assert(sizeof...(data) <= sizeof...(Fields) ||
- detail::has_array<Fields...>::value,
- "Too many record elements");
- static_assert(sizeof...(data) >= sizeof...(Fields),
- "Too few record elements");
- buffer.clear();
- detail::BCRecordCoding<IDField, Fields...>::emit(
- Stream, buffer, abbrCode, recordID, std::forward<Data>(data)...);
- }
-
- /// Extract record data from \p buffer into the given data fields.
- ///
- /// Note that even fixed arguments must be specified here. Pass \c Nothing
- /// if you don't care about a particular parameter. Blob data is not included
- /// in the buffer and should be handled separately by the caller.
- template <typename ElementTy, typename... Data>
- static void readRecord(ArrayRef<ElementTy> buffer, Data &&...data) {
- static_assert(sizeof...(data) <= sizeof...(Fields),
- "Too many record elements");
- static_assert(sizeof...(Fields) <=
- sizeof...(data) + detail::has_blob<Fields...>::value,
- "Too few record elements");
- return detail::BCRecordCoding<Fields...>::read(buffer,
- std::forward<Data>(data)...);
- }
-
- /// Extract record data from \p buffer into the given data fields.
- ///
- /// Note that even fixed arguments must be specified here. Pass \c Nothing
- /// if you don't care about a particular parameter. Blob data is not included
- /// in the buffer and should be handled separately by the caller.
- template <typename BufferTy, typename... Data>
- static void readRecord(BufferTy &buffer, Data &&...data) {
- return readRecord(llvm::makeArrayRef(buffer), std::forward<Data>(data)...);
- }
-};
-
-/// A record with a fixed record code.
-template <unsigned RecordCode, typename... Fields>
-class BCRecordLayout
- : public BCGenericRecordLayout<BCLiteral<RecordCode>, Fields...> {
- using Base = BCGenericRecordLayout<BCLiteral<RecordCode>, Fields...>;
-
-public:
- enum : unsigned {
- /// The record code associated with this layout.
- Code = RecordCode
- };
-
- /// Create a layout and register it with the given bitstream writer.
- explicit BCRecordLayout(llvm::BitstreamWriter &Stream) : Base(Stream) {}
-
- /// Emit a record to the bitstream writer, using the given buffer for scratch
- /// space.
- ///
- /// Note that even fixed arguments must be specified here.
- template <typename BufferTy, typename... Data>
- void emit(BufferTy &buffer, Data &&...data) const {
- Base::emit(buffer, RecordCode, std::forward<Data>(data)...);
- }
-
- /// Emit a record identified by \p abbrCode to bitstream reader \p Stream,
- /// using \p buffer for scratch space.
- ///
- /// Note that even fixed arguments must be specified here. Currently, arrays
- /// and blobs can only be passed as StringRefs.
- template <typename BufferTy, typename... Data>
- static void emitRecord(llvm::BitstreamWriter &Stream, BufferTy &buffer,
- unsigned abbrCode, Data &&...data) {
- Base::emitRecord(Stream, buffer, abbrCode, RecordCode,
- std::forward<Data>(data)...);
- }
-};
-
-/// RAII object to pair entering and exiting a sub-block.
-class BCBlockRAII {
- llvm::BitstreamWriter &Stream;
-
-public:
- BCBlockRAII(llvm::BitstreamWriter &Stream, unsigned block, unsigned abbrev)
- : Stream(Stream) {
- Stream.EnterSubblock(block, abbrev);
- }
-
- ~BCBlockRAII() { Stream.ExitBlock(); }
-};
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h b/contrib/libs/llvm12/include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h
deleted file mode 100644
index 149c5eb7c46..00000000000
--- a/contrib/libs/llvm12/include/llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h
+++ /dev/null
@@ -1,83 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- llvm/CodeGen/GlobalISel/ConstantFoldingMIRBuilder.h --*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-/// \file
-/// This file implements a version of MachineIRBuilder which does trivial
-/// constant folding.
-//===----------------------------------------------------------------------===//
-#include "llvm/CodeGen/GlobalISel/MachineIRBuilder.h"
-#include "llvm/CodeGen/GlobalISel/Utils.h"
-
-namespace llvm {
-
-/// An MIRBuilder which does trivial constant folding of binary ops.
-/// Calls to buildInstr will also try to constant fold binary ops.
-class ConstantFoldingMIRBuilder : public MachineIRBuilder {
-public:
- // Pull in base class constructors.
- using MachineIRBuilder::MachineIRBuilder;
-
- virtual ~ConstantFoldingMIRBuilder() = default;
-
- // Try to provide an overload for buildInstr for binary ops in order to
- // constant fold.
- MachineInstrBuilder buildInstr(unsigned Opc, ArrayRef<DstOp> DstOps,
- ArrayRef<SrcOp> SrcOps,
- Optional<unsigned> Flags = None) override {
- switch (Opc) {
- default:
- break;
- case TargetOpcode::G_ADD:
- case TargetOpcode::G_AND:
- case TargetOpcode::G_ASHR:
- case TargetOpcode::G_LSHR:
- case TargetOpcode::G_MUL:
- case TargetOpcode::G_OR:
- case TargetOpcode::G_SHL:
- case TargetOpcode::G_SUB:
- case TargetOpcode::G_XOR:
- case TargetOpcode::G_UDIV:
- case TargetOpcode::G_SDIV:
- case TargetOpcode::G_UREM:
- case TargetOpcode::G_SREM: {
- assert(DstOps.size() == 1 && "Invalid dst ops");
- assert(SrcOps.size() == 2 && "Invalid src ops");
- const DstOp &Dst = DstOps[0];
- const SrcOp &Src0 = SrcOps[0];
- const SrcOp &Src1 = SrcOps[1];
- if (auto MaybeCst =
- ConstantFoldBinOp(Opc, Src0.getReg(), Src1.getReg(), *getMRI()))
- return buildConstant(Dst, MaybeCst->getSExtValue());
- break;
- }
- case TargetOpcode::G_SEXT_INREG: {
- assert(DstOps.size() == 1 && "Invalid dst ops");
- assert(SrcOps.size() == 2 && "Invalid src ops");
- const DstOp &Dst = DstOps[0];
- const SrcOp &Src0 = SrcOps[0];
- const SrcOp &Src1 = SrcOps[1];
- if (auto MaybeCst =
- ConstantFoldExtOp(Opc, Src0.getReg(), Src1.getImm(), *getMRI()))
- return buildConstant(Dst, MaybeCst->getSExtValue());
- break;
- }
- }
- return MachineIRBuilder::buildInstr(Opc, DstOps, SrcOps);
- }
-};
-} // namespace llvm
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/CodeGen/MachORelocation.h b/contrib/libs/llvm12/include/llvm/CodeGen/MachORelocation.h
deleted file mode 100644
index 20b31a21f48..00000000000
--- a/contrib/libs/llvm12/include/llvm/CodeGen/MachORelocation.h
+++ /dev/null
@@ -1,66 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//=== MachORelocation.h - Mach-O Relocation Info ----------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the MachORelocation class.
-//
-//===----------------------------------------------------------------------===//
-
-
-#ifndef LLVM_CODEGEN_MACHORELOCATION_H
-#define LLVM_CODEGEN_MACHORELOCATION_H
-
-#include "llvm/Support/DataTypes.h"
-
-namespace llvm {
-
- /// MachORelocation - This struct contains information about each relocation
- /// that needs to be emitted to the file.
- /// see <mach-o/reloc.h>
- class MachORelocation {
- uint32_t r_address; // offset in the section to what is being relocated
- uint32_t r_symbolnum; // symbol index if r_extern == 1 else section index
- bool r_pcrel; // was relocated pc-relative already
- uint8_t r_length; // length = 2 ^ r_length
- bool r_extern; //
- uint8_t r_type; // if not 0, machine-specific relocation type.
- bool r_scattered; // 1 = scattered, 0 = non-scattered
- int32_t r_value; // the value the item to be relocated is referring
- // to.
- public:
- uint32_t getPackedFields() const {
- if (r_scattered)
- return (1 << 31) | (r_pcrel << 30) | ((r_length & 3) << 28) |
- ((r_type & 15) << 24) | (r_address & 0x00FFFFFF);
- else
- return (r_symbolnum << 8) | (r_pcrel << 7) | ((r_length & 3) << 5) |
- (r_extern << 4) | (r_type & 15);
- }
- uint32_t getAddress() const { return r_scattered ? r_value : r_address; }
- uint32_t getRawAddress() const { return r_address; }
-
- MachORelocation(uint32_t addr, uint32_t index, bool pcrel, uint8_t len,
- bool ext, uint8_t type, bool scattered = false,
- int32_t value = 0) :
- r_address(addr), r_symbolnum(index), r_pcrel(pcrel), r_length(len),
- r_extern(ext), r_type(type), r_scattered(scattered), r_value(value) {}
- };
-
-} // end llvm namespace
-
-#endif // LLVM_CODEGEN_MACHORELOCATION_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Config/AsmParsers.def.in b/contrib/libs/llvm12/include/llvm/Config/AsmParsers.def.in
deleted file mode 100644
index 2e5fa33ace2..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/AsmParsers.def.in
+++ /dev/null
@@ -1,29 +0,0 @@
-/*===- llvm/Config/AsmParsers.def - LLVM Assembly Parsers -------*- C++ -*-===*\
-|* *|
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
-|* Exceptions. *|
-|* See https://llvm.org/LICENSE.txt for license information. *|
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
-|* *|
-|*===----------------------------------------------------------------------===*|
-|* *|
-|* This file enumerates all of the assembly-language parsers *|
-|* supported by this build of LLVM. Clients of this file should define *|
-|* the LLVM_ASM_PARSER macro to be a function-like macro with a *|
-|* single parameter (the name of the target whose assembly can be *|
-|* generated); including this file will then enumerate all of the *|
-|* targets with assembly parsers. *|
-|* *|
-|* The set of targets supported by LLVM is generated at configuration *|
-|* time, at which point this header is generated. Do not modify this *|
-|* header directly. *|
-|* *|
-\*===----------------------------------------------------------------------===*/
-
-#ifndef LLVM_ASM_PARSER
-# error Please define the macro LLVM_ASM_PARSER(TargetName)
-#endif
-
-@LLVM_ENUM_ASM_PARSERS@
-
-#undef LLVM_ASM_PARSER
diff --git a/contrib/libs/llvm12/include/llvm/Config/AsmPrinters.def.in b/contrib/libs/llvm12/include/llvm/Config/AsmPrinters.def.in
deleted file mode 100644
index 56419d9c147..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/AsmPrinters.def.in
+++ /dev/null
@@ -1,29 +0,0 @@
-/*===- llvm/Config/AsmPrinters.def - LLVM Assembly Printers -----*- C++ -*-===*\
-|* *|
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
-|* Exceptions. *|
-|* See https://llvm.org/LICENSE.txt for license information. *|
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
-|* *|
-|*===----------------------------------------------------------------------===*|
-|* *|
-|* This file enumerates all of the assembly-language printers *|
-|* supported by this build of LLVM. Clients of this file should define *|
-|* the LLVM_ASM_PRINTER macro to be a function-like macro with a *|
-|* single parameter (the name of the target whose assembly can be *|
-|* generated); including this file will then enumerate all of the *|
-|* targets with assembly printers. *|
-|* *|
-|* The set of targets supported by LLVM is generated at configuration *|
-|* time, at which point this header is generated. Do not modify this *|
-|* header directly. *|
-|* *|
-\*===----------------------------------------------------------------------===*/
-
-#ifndef LLVM_ASM_PRINTER
-# error Please define the macro LLVM_ASM_PRINTER(TargetName)
-#endif
-
-@LLVM_ENUM_ASM_PRINTERS@
-
-#undef LLVM_ASM_PRINTER
diff --git a/contrib/libs/llvm12/include/llvm/Config/Disassemblers.def.in b/contrib/libs/llvm12/include/llvm/Config/Disassemblers.def.in
deleted file mode 100644
index b110b1588d3..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/Disassemblers.def.in
+++ /dev/null
@@ -1,29 +0,0 @@
-/*===- llvm/Config/Disassemblers.def - LLVM Assembly Parsers ----*- C++ -*-===*\
-|* *|
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
-|* Exceptions. *|
-|* See https://llvm.org/LICENSE.txt for license information. *|
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
-|* *|
-|*===----------------------------------------------------------------------===*|
-|* *|
-|* This file enumerates all of the assembly-language parsers *|
-|* supported by this build of LLVM. Clients of this file should define *|
-|* the LLVM_DISASSEMBLER macro to be a function-like macro with a *|
-|* single parameter (the name of the target whose assembly can be *|
-|* generated); including this file will then enumerate all of the *|
-|* targets with assembly parsers. *|
-|* *|
-|* The set of targets supported by LLVM is generated at configuration *|
-|* time, at which point this header is generated. Do not modify this *|
-|* header directly. *|
-|* *|
-\*===----------------------------------------------------------------------===*/
-
-#ifndef LLVM_DISASSEMBLER
-# error Please define the macro LLVM_DISASSEMBLER(TargetName)
-#endif
-
-@LLVM_ENUM_DISASSEMBLERS@
-
-#undef LLVM_DISASSEMBLER
diff --git a/contrib/libs/llvm12/include/llvm/Config/Targets.def.in b/contrib/libs/llvm12/include/llvm/Config/Targets.def.in
deleted file mode 100644
index 0da9b948c9f..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/Targets.def.in
+++ /dev/null
@@ -1,28 +0,0 @@
-/*===- llvm/Config/Targets.def - LLVM Target Architectures ------*- C++ -*-===*\
-|* *|
-|* Part of the LLVM Project, under the Apache License v2.0 with LLVM *|
-|* Exceptions. *|
-|* See https://llvm.org/LICENSE.txt for license information. *|
-|* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception *|
-|* *|
-|*===----------------------------------------------------------------------===*|
-|* *|
-|* This file enumerates all of the target architectures supported by *|
-|* this build of LLVM. Clients of this file should define the *|
-|* LLVM_TARGET macro to be a function-like macro with a single *|
-|* parameter (the name of the target); including this file will then *|
-|* enumerate all of the targets. *|
-|* *|
-|* The set of targets supported by LLVM is generated at configuration *|
-|* time, at which point this header is generated. Do not modify this *|
-|* header directly. *|
-|* *|
-\*===----------------------------------------------------------------------===*/
-
-#ifndef LLVM_TARGET
-# error Please define the macro LLVM_TARGET(TargetName)
-#endif
-
-@LLVM_ENUM_TARGETS@
-
-#undef LLVM_TARGET
diff --git a/contrib/libs/llvm12/include/llvm/Config/abi-breaking.h.cmake b/contrib/libs/llvm12/include/llvm/Config/abi-breaking.h.cmake
deleted file mode 100644
index 2d27e02b1d5..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/abi-breaking.h.cmake
+++ /dev/null
@@ -1,62 +0,0 @@
-/*===------- llvm/Config/abi-breaking.h - llvm configuration -------*- C -*-===*/
-/* */
-/* Part of the LLVM Project, under the Apache License v2.0 with LLVM */
-/* Exceptions. */
-/* See https://llvm.org/LICENSE.txt for license information. */
-/* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception */
-/* */
-/*===----------------------------------------------------------------------===*/
-
-/* This file controls the C++ ABI break introduced in LLVM public header. */
-
-#ifndef LLVM_ABI_BREAKING_CHECKS_H
-#define LLVM_ABI_BREAKING_CHECKS_H
-
-/* Define to enable checks that alter the LLVM C++ ABI */
-#cmakedefine01 LLVM_ENABLE_ABI_BREAKING_CHECKS
-
-/* Define to enable reverse iteration of unordered llvm containers */
-#cmakedefine01 LLVM_ENABLE_REVERSE_ITERATION
-
-/* Allow selectively disabling link-time mismatch checking so that header-only
- ADT content from LLVM can be used without linking libSupport. */
-#if !defined(LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING) || !LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING
-
-// ABI_BREAKING_CHECKS protection: provides link-time failure when clients build
-// mismatch with LLVM
-#if defined(_MSC_VER)
-// Use pragma with MSVC
-#define LLVM_XSTR(s) LLVM_STR(s)
-#define LLVM_STR(s) #s
-#pragma detect_mismatch("LLVM_ENABLE_ABI_BREAKING_CHECKS", LLVM_XSTR(LLVM_ENABLE_ABI_BREAKING_CHECKS))
-#undef LLVM_XSTR
-#undef LLVM_STR
-#elif defined(_WIN32) || defined(__CYGWIN__) // Win32 w/o #pragma detect_mismatch
-// FIXME: Implement checks without weak.
-#elif defined(__cplusplus)
-#if !(defined(_AIX) && defined(__GNUC__) && !defined(__clang__))
-#define LLVM_HIDDEN_VISIBILITY __attribute__ ((visibility("hidden")))
-#else
-// GCC on AIX does not support visibility attributes. Symbols are not
-// exported by default on AIX.
-#define LLVM_HIDDEN_VISIBILITY
-#endif
-namespace llvm {
-#if LLVM_ENABLE_ABI_BREAKING_CHECKS
-extern int EnableABIBreakingChecks;
-LLVM_HIDDEN_VISIBILITY
-__attribute__((weak)) int *VerifyEnableABIBreakingChecks =
- &EnableABIBreakingChecks;
-#else
-extern int DisableABIBreakingChecks;
-LLVM_HIDDEN_VISIBILITY
-__attribute__((weak)) int *VerifyDisableABIBreakingChecks =
- &DisableABIBreakingChecks;
-#endif
-}
-#undef LLVM_HIDDEN_VISIBILITY
-#endif // _MSC_VER
-
-#endif // LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING
-
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Config/config.h.cmake b/contrib/libs/llvm12/include/llvm/Config/config.h.cmake
deleted file mode 100644
index 6664ad33558..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/config.h.cmake
+++ /dev/null
@@ -1,353 +0,0 @@
-#ifndef CONFIG_H
-#define CONFIG_H
-
-// Include this header only under the llvm source tree.
-// This is a private header.
-
-/* Exported configuration */
-#include "llvm/Config/llvm-config.h"
-
-/* Bug report URL. */
-#define BUG_REPORT_URL "${BUG_REPORT_URL}"
-
-/* Define to 1 to enable backtraces, and to 0 otherwise. */
-#cmakedefine01 ENABLE_BACKTRACES
-
-/* Define to 1 to enable crash overrides, and to 0 otherwise. */
-#cmakedefine01 ENABLE_CRASH_OVERRIDES
-
-/* Define to 1 to enable crash memory dumps, and to 0 otherwise. */
-#cmakedefine01 LLVM_ENABLE_CRASH_DUMPS
-
-/* Define to 1 if you have the `backtrace' function. */
-#cmakedefine HAVE_BACKTRACE ${HAVE_BACKTRACE}
-
-#define BACKTRACE_HEADER <${BACKTRACE_HEADER}>
-
-/* Define to 1 if you have the <CrashReporterClient.h> header file. */
-#cmakedefine HAVE_CRASHREPORTERCLIENT_H
-
-/* can use __crashreporter_info__ */
-#cmakedefine01 HAVE_CRASHREPORTER_INFO
-
-/* Define to 1 if you have the declaration of `arc4random', and to 0 if you
- don't. */
-#cmakedefine01 HAVE_DECL_ARC4RANDOM
-
-/* Define to 1 if you have the declaration of `FE_ALL_EXCEPT', and to 0 if you
- don't. */
-#cmakedefine01 HAVE_DECL_FE_ALL_EXCEPT
-
-/* Define to 1 if you have the declaration of `FE_INEXACT', and to 0 if you
- don't. */
-#cmakedefine01 HAVE_DECL_FE_INEXACT
-
-/* Define to 1 if you have the declaration of `strerror_s', and to 0 if you
- don't. */
-#cmakedefine01 HAVE_DECL_STRERROR_S
-
-/* Define to 1 if you have the DIA SDK installed, and to 0 if you don't. */
-#cmakedefine01 LLVM_ENABLE_DIA_SDK
-
-/* Define to 1 if you have the <dlfcn.h> header file. */
-#cmakedefine HAVE_DLFCN_H ${HAVE_DLFCN_H}
-
-/* Define if dlopen() is available on this platform. */
-#cmakedefine HAVE_DLOPEN ${HAVE_DLOPEN}
-
-/* Define if dladdr() is available on this platform. */
-#cmakedefine HAVE_DLADDR ${HAVE_DLADDR}
-
-/* Define to 1 if we can register EH frames on this platform. */
-#cmakedefine HAVE_REGISTER_FRAME ${HAVE_REGISTER_FRAME}
-
-/* Define to 1 if we can deregister EH frames on this platform. */
-#cmakedefine HAVE_DEREGISTER_FRAME ${HAVE_DEREGISTER_FRAME}
-
-/* Define to 1 if you have the <errno.h> header file. */
-#cmakedefine HAVE_ERRNO_H ${HAVE_ERRNO_H}
-
-/* Define to 1 if you have the <fcntl.h> header file. */
-#cmakedefine HAVE_FCNTL_H ${HAVE_FCNTL_H}
-
-/* Define to 1 if you have the <fenv.h> header file. */
-#cmakedefine HAVE_FENV_H ${HAVE_FENV_H}
-
-/* Define if libffi is available on this platform. */
-#cmakedefine HAVE_FFI_CALL ${HAVE_FFI_CALL}
-
-/* Define to 1 if you have the <ffi/ffi.h> header file. */
-#cmakedefine HAVE_FFI_FFI_H ${HAVE_FFI_FFI_H}
-
-/* Define to 1 if you have the <ffi.h> header file. */
-#cmakedefine HAVE_FFI_H ${HAVE_FFI_H}
-
-/* Define to 1 if you have the `futimens' function. */
-#cmakedefine HAVE_FUTIMENS ${HAVE_FUTIMENS}
-
-/* Define to 1 if you have the `futimes' function. */
-#cmakedefine HAVE_FUTIMES ${HAVE_FUTIMES}
-
-/* Define to 1 if you have the `getpagesize' function. */
-#cmakedefine HAVE_GETPAGESIZE ${HAVE_GETPAGESIZE}
-
-/* Define to 1 if you have the `getrlimit' function. */
-#cmakedefine HAVE_GETRLIMIT ${HAVE_GETRLIMIT}
-
-/* Define to 1 if you have the `getrusage' function. */
-#cmakedefine HAVE_GETRUSAGE ${HAVE_GETRUSAGE}
-
-/* Define to 1 if you have the `isatty' function. */
-#cmakedefine HAVE_ISATTY 1
-
-/* Define to 1 if you have the `edit' library (-ledit). */
-#cmakedefine HAVE_LIBEDIT ${HAVE_LIBEDIT}
-
-/* Define to 1 if you have the `pfm' library (-lpfm). */
-#cmakedefine HAVE_LIBPFM ${HAVE_LIBPFM}
-
-/* Define to 1 if the `perf_branch_entry' struct has field cycles. */
-#cmakedefine LIBPFM_HAS_FIELD_CYCLES ${LIBPFM_HAS_FIELD_CYCLES}
-
-/* Define to 1 if you have the `psapi' library (-lpsapi). */
-#cmakedefine HAVE_LIBPSAPI ${HAVE_LIBPSAPI}
-
-/* Define to 1 if you have the `pthread' library (-lpthread). */
-#cmakedefine HAVE_LIBPTHREAD ${HAVE_LIBPTHREAD}
-
-/* Define to 1 if you have the `pthread_getname_np' function. */
-#cmakedefine HAVE_PTHREAD_GETNAME_NP ${HAVE_PTHREAD_GETNAME_NP}
-
-/* Define to 1 if you have the `pthread_setname_np' function. */
-#cmakedefine HAVE_PTHREAD_SETNAME_NP ${HAVE_PTHREAD_SETNAME_NP}
-
-/* Define to 1 if you have the <link.h> header file. */
-#cmakedefine HAVE_LINK_H ${HAVE_LINK_H}
-
-/* Define to 1 if you have the `lseek64' function. */
-#cmakedefine HAVE_LSEEK64 ${HAVE_LSEEK64}
-
-/* Define to 1 if you have the <mach/mach.h> header file. */
-#cmakedefine HAVE_MACH_MACH_H ${HAVE_MACH_MACH_H}
-
-/* Define to 1 if you have the `mallctl' function. */
-#cmakedefine HAVE_MALLCTL ${HAVE_MALLCTL}
-
-/* Define to 1 if you have the `mallinfo' function. */
-#cmakedefine HAVE_MALLINFO ${HAVE_MALLINFO}
-
-/* Define to 1 if you have the <malloc/malloc.h> header file. */
-#cmakedefine HAVE_MALLOC_MALLOC_H ${HAVE_MALLOC_MALLOC_H}
-
-/* Define to 1 if you have the `malloc_zone_statistics' function. */
-#cmakedefine HAVE_MALLOC_ZONE_STATISTICS ${HAVE_MALLOC_ZONE_STATISTICS}
-
-/* Define to 1 if you have the `posix_fallocate' function. */
-#cmakedefine HAVE_POSIX_FALLOCATE ${HAVE_POSIX_FALLOCATE}
-
-/* Define to 1 if you have the `posix_spawn' function. */
-#cmakedefine HAVE_POSIX_SPAWN ${HAVE_POSIX_SPAWN}
-
-/* Define to 1 if you have the `pread' function. */
-#cmakedefine HAVE_PREAD ${HAVE_PREAD}
-
-/* Have pthread_getspecific */
-#cmakedefine HAVE_PTHREAD_GETSPECIFIC ${HAVE_PTHREAD_GETSPECIFIC}
-
-/* Define to 1 if you have the <pthread.h> header file. */
-#cmakedefine HAVE_PTHREAD_H ${HAVE_PTHREAD_H}
-
-/* Have pthread_mutex_lock */
-#cmakedefine HAVE_PTHREAD_MUTEX_LOCK ${HAVE_PTHREAD_MUTEX_LOCK}
-
-/* Have pthread_rwlock_init */
-#cmakedefine HAVE_PTHREAD_RWLOCK_INIT ${HAVE_PTHREAD_RWLOCK_INIT}
-
-/* Define to 1 if you have the `sbrk' function. */
-#cmakedefine HAVE_SBRK ${HAVE_SBRK}
-
-/* Define to 1 if you have the `setenv' function. */
-#cmakedefine HAVE_SETENV ${HAVE_SETENV}
-
-/* Define to 1 if you have the `setrlimit' function. */
-#cmakedefine HAVE_SETRLIMIT ${HAVE_SETRLIMIT}
-
-/* Define to 1 if you have the `sigaltstack' function. */
-#cmakedefine HAVE_SIGALTSTACK ${HAVE_SIGALTSTACK}
-
-/* Define to 1 if you have the <signal.h> header file. */
-#cmakedefine HAVE_SIGNAL_H ${HAVE_SIGNAL_H}
-
-/* Define to 1 if you have the `strerror' function. */
-#cmakedefine HAVE_STRERROR ${HAVE_STRERROR}
-
-/* Define to 1 if you have the `strerror_r' function. */
-#cmakedefine HAVE_STRERROR_R ${HAVE_STRERROR_R}
-
-/* Define to 1 if you have the `sysconf' function. */
-#cmakedefine HAVE_SYSCONF ${HAVE_SYSCONF}
-
-/* Define to 1 if you have the <sys/ioctl.h> header file. */
-#cmakedefine HAVE_SYS_IOCTL_H ${HAVE_SYS_IOCTL_H}
-
-/* Define to 1 if you have the <sys/mman.h> header file. */
-#cmakedefine HAVE_SYS_MMAN_H ${HAVE_SYS_MMAN_H}
-
-/* Define to 1 if you have the <sys/param.h> header file. */
-#cmakedefine HAVE_SYS_PARAM_H ${HAVE_SYS_PARAM_H}
-
-/* Define to 1 if you have the <sys/resource.h> header file. */
-#cmakedefine HAVE_SYS_RESOURCE_H ${HAVE_SYS_RESOURCE_H}
-
-/* Define to 1 if you have the <sys/stat.h> header file. */
-#cmakedefine HAVE_SYS_STAT_H ${HAVE_SYS_STAT_H}
-
-/* Define to 1 if you have the <sys/time.h> header file. */
-#cmakedefine HAVE_SYS_TIME_H ${HAVE_SYS_TIME_H}
-
-/* Define to 1 if stat struct has st_mtimespec member .*/
-#cmakedefine HAVE_STRUCT_STAT_ST_MTIMESPEC_TV_NSEC ${HAVE_STRUCT_STAT_ST_MTIMESPEC_TV_NSEC}
-
-/* Define to 1 if stat struct has st_mtim member. */
-#cmakedefine HAVE_STRUCT_STAT_ST_MTIM_TV_NSEC ${HAVE_STRUCT_STAT_ST_MTIM_TV_NSEC}
-
-/* Define to 1 if you have the <sys/types.h> header file. */
-#cmakedefine HAVE_SYS_TYPES_H ${HAVE_SYS_TYPES_H}
-
-/* Define if the setupterm() function is supported this platform. */
-#cmakedefine LLVM_ENABLE_TERMINFO ${LLVM_ENABLE_TERMINFO}
-
-/* Define if the xar_open() function is supported this platform. */
-#cmakedefine HAVE_LIBXAR ${HAVE_LIBXAR}
-
-/* Define to 1 if you have the <termios.h> header file. */
-#cmakedefine HAVE_TERMIOS_H ${HAVE_TERMIOS_H}
-
-/* Define to 1 if you have the <unistd.h> header file. */
-#cmakedefine HAVE_UNISTD_H ${HAVE_UNISTD_H}
-
-/* Define to 1 if you have the <valgrind/valgrind.h> header file. */
-#cmakedefine HAVE_VALGRIND_VALGRIND_H ${HAVE_VALGRIND_VALGRIND_H}
-
-/* Have host's _alloca */
-#cmakedefine HAVE__ALLOCA ${HAVE__ALLOCA}
-
-/* Define to 1 if you have the `_chsize_s' function. */
-#cmakedefine HAVE__CHSIZE_S ${HAVE__CHSIZE_S}
-
-/* Define to 1 if you have the `_Unwind_Backtrace' function. */
-#cmakedefine HAVE__UNWIND_BACKTRACE ${HAVE__UNWIND_BACKTRACE}
-
-/* Have host's __alloca */
-#cmakedefine HAVE___ALLOCA ${HAVE___ALLOCA}
-
-/* Have host's __ashldi3 */
-#cmakedefine HAVE___ASHLDI3 ${HAVE___ASHLDI3}
-
-/* Have host's __ashrdi3 */
-#cmakedefine HAVE___ASHRDI3 ${HAVE___ASHRDI3}
-
-/* Have host's __chkstk */
-#cmakedefine HAVE___CHKSTK ${HAVE___CHKSTK}
-
-/* Have host's __chkstk_ms */
-#cmakedefine HAVE___CHKSTK_MS ${HAVE___CHKSTK_MS}
-
-/* Have host's __cmpdi2 */
-#cmakedefine HAVE___CMPDI2 ${HAVE___CMPDI2}
-
-/* Have host's __divdi3 */
-#cmakedefine HAVE___DIVDI3 ${HAVE___DIVDI3}
-
-/* Have host's __fixdfdi */
-#cmakedefine HAVE___FIXDFDI ${HAVE___FIXDFDI}
-
-/* Have host's __fixsfdi */
-#cmakedefine HAVE___FIXSFDI ${HAVE___FIXSFDI}
-
-/* Have host's __floatdidf */
-#cmakedefine HAVE___FLOATDIDF ${HAVE___FLOATDIDF}
-
-/* Have host's __lshrdi3 */
-#cmakedefine HAVE___LSHRDI3 ${HAVE___LSHRDI3}
-
-/* Have host's __main */
-#cmakedefine HAVE___MAIN ${HAVE___MAIN}
-
-/* Have host's __moddi3 */
-#cmakedefine HAVE___MODDI3 ${HAVE___MODDI3}
-
-/* Have host's __udivdi3 */
-#cmakedefine HAVE___UDIVDI3 ${HAVE___UDIVDI3}
-
-/* Have host's __umoddi3 */
-#cmakedefine HAVE___UMODDI3 ${HAVE___UMODDI3}
-
-/* Have host's ___chkstk */
-#cmakedefine HAVE____CHKSTK ${HAVE____CHKSTK}
-
-/* Have host's ___chkstk_ms */
-#cmakedefine HAVE____CHKSTK_MS ${HAVE____CHKSTK_MS}
-
-/* Linker version detected at compile time. */
-#cmakedefine HOST_LINK_VERSION "${HOST_LINK_VERSION}"
-
-/* Target triple LLVM will generate code for by default */
-/* Doesn't use `cmakedefine` because it is allowed to be empty. */
-#define LLVM_DEFAULT_TARGET_TRIPLE "${LLVM_DEFAULT_TARGET_TRIPLE}"
-
-/* Define if zlib compression is available */
-#cmakedefine01 LLVM_ENABLE_ZLIB
-
-/* Define if overriding target triple is enabled */
-#cmakedefine LLVM_TARGET_TRIPLE_ENV "${LLVM_TARGET_TRIPLE_ENV}"
-
-/* LLVM version information */
-#cmakedefine LLVM_VERSION_INFO "${LLVM_VERSION_INFO}"
-
-/* Whether tools show host and target info when invoked with --version */
-#cmakedefine01 LLVM_VERSION_PRINTER_SHOW_HOST_TARGET_INFO
-
-/* Define if libxml2 is supported on this platform. */
-#cmakedefine LLVM_ENABLE_LIBXML2 ${LLVM_ENABLE_LIBXML2}
-
-/* Define to the extension used for shared libraries, say, ".so". */
-#cmakedefine LTDL_SHLIB_EXT "${LTDL_SHLIB_EXT}"
-
-/* Define to the address where bug reports for this package should be sent. */
-#cmakedefine PACKAGE_BUGREPORT "${PACKAGE_BUGREPORT}"
-
-/* Define to the full name of this package. */
-#cmakedefine PACKAGE_NAME "${PACKAGE_NAME}"
-
-/* Define to the full name and version of this package. */
-#cmakedefine PACKAGE_STRING "${PACKAGE_STRING}"
-
-/* Define to the version of this package. */
-#cmakedefine PACKAGE_VERSION "${PACKAGE_VERSION}"
-
-/* Define to the vendor of this package. */
-#cmakedefine PACKAGE_VENDOR "${PACKAGE_VENDOR}"
-
-/* Define as the return type of signal handlers (`int' or `void'). */
-#cmakedefine RETSIGTYPE ${RETSIGTYPE}
-
-/* Define if std::is_trivially_copyable is supported */
-#cmakedefine HAVE_STD_IS_TRIVIALLY_COPYABLE ${HAVE_STD_IS_TRIVIALLY_COPYABLE}
-
-/* Define to a function implementing stricmp */
-#cmakedefine stricmp ${stricmp}
-
-/* Define to a function implementing strdup */
-#cmakedefine strdup ${strdup}
-
-/* Whether GlobalISel rule coverage is being collected */
-#cmakedefine01 LLVM_GISEL_COV_ENABLED
-
-/* Define to the default GlobalISel coverage file prefix */
-#cmakedefine LLVM_GISEL_COV_PREFIX "${LLVM_GISEL_COV_PREFIX}"
-
-/* Whether Timers signpost passes in Xcode Instruments */
-#cmakedefine01 LLVM_SUPPORT_XCODE_SIGNPOSTS
-
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Config/llvm-config.h.cmake b/contrib/libs/llvm12/include/llvm/Config/llvm-config.h.cmake
deleted file mode 100644
index b5fa20f789a..00000000000
--- a/contrib/libs/llvm12/include/llvm/Config/llvm-config.h.cmake
+++ /dev/null
@@ -1,97 +0,0 @@
-/*===------- llvm/Config/llvm-config.h - llvm configuration -------*- C -*-===*/
-/* */
-/* Part of the LLVM Project, under the Apache License v2.0 with LLVM */
-/* Exceptions. */
-/* See https://llvm.org/LICENSE.txt for license information. */
-/* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception */
-/* */
-/*===----------------------------------------------------------------------===*/
-
-/* This file enumerates variables from the LLVM configuration so that they
- can be in exported headers and won't override package specific directives.
- This is a C header that can be included in the llvm-c headers. */
-
-#ifndef LLVM_CONFIG_H
-#define LLVM_CONFIG_H
-
-/* Define if LLVM_ENABLE_DUMP is enabled */
-#cmakedefine LLVM_ENABLE_DUMP
-
-/* Target triple LLVM will generate code for by default */
-#cmakedefine LLVM_DEFAULT_TARGET_TRIPLE "${LLVM_DEFAULT_TARGET_TRIPLE}"
-
-/* Define if threads enabled */
-#cmakedefine01 LLVM_ENABLE_THREADS
-
-/* Has gcc/MSVC atomic intrinsics */
-#cmakedefine01 LLVM_HAS_ATOMICS
-
-/* Host triple LLVM will be executed on */
-#cmakedefine LLVM_HOST_TRIPLE "${LLVM_HOST_TRIPLE}"
-
-/* LLVM architecture name for the native architecture, if available */
-#cmakedefine LLVM_NATIVE_ARCH ${LLVM_NATIVE_ARCH}
-
-/* LLVM name for the native AsmParser init function, if available */
-#cmakedefine LLVM_NATIVE_ASMPARSER LLVMInitialize${LLVM_NATIVE_ARCH}AsmParser
-
-/* LLVM name for the native AsmPrinter init function, if available */
-#cmakedefine LLVM_NATIVE_ASMPRINTER LLVMInitialize${LLVM_NATIVE_ARCH}AsmPrinter
-
-/* LLVM name for the native Disassembler init function, if available */
-#cmakedefine LLVM_NATIVE_DISASSEMBLER LLVMInitialize${LLVM_NATIVE_ARCH}Disassembler
-
-/* LLVM name for the native Target init function, if available */
-#cmakedefine LLVM_NATIVE_TARGET LLVMInitialize${LLVM_NATIVE_ARCH}Target
-
-/* LLVM name for the native TargetInfo init function, if available */
-#cmakedefine LLVM_NATIVE_TARGETINFO LLVMInitialize${LLVM_NATIVE_ARCH}TargetInfo
-
-/* LLVM name for the native target MC init function, if available */
-#cmakedefine LLVM_NATIVE_TARGETMC LLVMInitialize${LLVM_NATIVE_ARCH}TargetMC
-
-/* Define if this is Unixish platform */
-#cmakedefine LLVM_ON_UNIX ${LLVM_ON_UNIX}
-
-/* Define if we have the Intel JIT API runtime support library */
-#cmakedefine01 LLVM_USE_INTEL_JITEVENTS
-
-/* Define if we have the oprofile JIT-support library */
-#cmakedefine01 LLVM_USE_OPROFILE
-
-/* Define if we have the perf JIT-support library */
-#cmakedefine01 LLVM_USE_PERF
-
-/* Major version of the LLVM API */
-#define LLVM_VERSION_MAJOR ${LLVM_VERSION_MAJOR}
-
-/* Minor version of the LLVM API */
-#define LLVM_VERSION_MINOR ${LLVM_VERSION_MINOR}
-
-/* Patch version of the LLVM API */
-#define LLVM_VERSION_PATCH ${LLVM_VERSION_PATCH}
-
-/* LLVM version string */
-#define LLVM_VERSION_STRING "${PACKAGE_VERSION}"
-
-/* Whether LLVM records statistics for use with GetStatistics(),
- * PrintStatistics() or PrintStatisticsJSON()
- */
-#cmakedefine01 LLVM_FORCE_ENABLE_STATS
-
-/* Define if we have z3 and want to build it */
-#cmakedefine LLVM_WITH_Z3 ${LLVM_WITH_Z3}
-
-/* Define if LLVM was built with a dependency to the libtensorflow dynamic library */
-#cmakedefine LLVM_HAVE_TF_API
-
-/* Define if LLVM was built with a dependency to the tensorflow compiler */
-#cmakedefine LLVM_HAVE_TF_AOT
-
-/* Define to 1 if you have the <sysexits.h> header file. */
-#cmakedefine HAVE_SYSEXITS_H ${HAVE_SYSEXITS_H}
-
-/* Define to 1 to enable the experimental new pass manager by default */
-#cmakedefine01 LLVM_ENABLE_NEW_PASS_MANAGER
-
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/FunctionId.h b/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/FunctionId.h
deleted file mode 100644
index 8de994911ba..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/FunctionId.h
+++ /dev/null
@@ -1,66 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- FunctionId.h ---------------------------------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_CODEVIEW_FUNCTIONID_H
-#define LLVM_DEBUGINFO_CODEVIEW_FUNCTIONID_H
-
-#include <cinttypes>
-
-namespace llvm {
-namespace codeview {
-
-class FunctionId {
-public:
- FunctionId() : Index(0) {}
-
- explicit FunctionId(uint32_t Index) : Index(Index) {}
-
- uint32_t getIndex() const { return Index; }
-
-private:
- uint32_t Index;
-};
-
-inline bool operator==(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() == B.getIndex();
-}
-
-inline bool operator!=(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() != B.getIndex();
-}
-
-inline bool operator<(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() < B.getIndex();
-}
-
-inline bool operator<=(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() <= B.getIndex();
-}
-
-inline bool operator>(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() > B.getIndex();
-}
-
-inline bool operator>=(const FunctionId &A, const FunctionId &B) {
- return A.getIndex() >= B.getIndex();
-}
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h b/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h
deleted file mode 100644
index 9500bdb0880..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/CodeView/TypeSymbolEmitter.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- TypeSymbolEmitter.h --------------------------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_CODEVIEW_TYPESYMBOLEMITTER_H
-#define LLVM_DEBUGINFO_CODEVIEW_TYPESYMBOLEMITTER_H
-
-namespace llvm {
-class StringRef;
-
-namespace codeview {
-class TypeIndex;
-
-class TypeSymbolEmitter {
-private:
- TypeSymbolEmitter(const TypeSymbolEmitter &) = delete;
- TypeSymbolEmitter &operator=(const TypeSymbolEmitter &) = delete;
-
-protected:
- TypeSymbolEmitter() {}
-
-public:
- virtual ~TypeSymbolEmitter() {}
-
-public:
- virtual void writeUserDefinedType(TypeIndex TI, StringRef Name) = 0;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIADataStream.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIADataStream.h
deleted file mode 100644
index f9a0fe94331..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIADataStream.h
+++ /dev/null
@@ -1,44 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIADataStream.h - DIA implementation of IPDBDataStream ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIADATASTREAM_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIADATASTREAM_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBDataStream.h"
-
-namespace llvm {
-namespace pdb {
-class DIADataStream : public IPDBDataStream {
-public:
- explicit DIADataStream(CComPtr<IDiaEnumDebugStreamData> DiaStreamData);
-
- uint32_t getRecordCount() const override;
- std::string getName() const override;
- llvm::Optional<RecordType> getItemAtIndex(uint32_t Index) const override;
- bool getNext(RecordType &Record) override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumDebugStreamData> StreamData;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h
deleted file mode 100644
index 7b0bdd2384e..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumDebugStreams.h
+++ /dev/null
@@ -1,47 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumDebugStreams.h - DIA Debug Stream Enumerator impl ---*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMDEBUGSTREAMS_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMDEBUGSTREAMS_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBDataStream.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-
-namespace llvm {
-namespace pdb {
-
-class IPDBDataStream;
-
-class DIAEnumDebugStreams : public IPDBEnumChildren<IPDBDataStream> {
-public:
- explicit DIAEnumDebugStreams(CComPtr<IDiaEnumDebugStreams> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumDebugStreams> Enumerator;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumFrameData.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumFrameData.h
deleted file mode 100644
index ccaccaa8878..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumFrameData.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumFrameData.h --------------------------------------- -*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMFRAMEDATA_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMFRAMEDATA_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBFrameData.h"
-
-namespace llvm {
-namespace pdb {
-
-class DIAEnumFrameData : public IPDBEnumChildren<IPDBFrameData> {
-public:
- explicit DIAEnumFrameData(CComPtr<IDiaEnumFrameData> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumFrameData> Enumerator;
-};
-
-} // namespace pdb
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumInjectedSources.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumInjectedSources.h
deleted file mode 100644
index 4776d02f478..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumInjectedSources.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumInjectedSources.h - DIA Injected Sources Enumerator -*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMINJECTEDSOURCES_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMINJECTEDSOURCES_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBInjectedSource.h"
-
-namespace llvm {
-namespace pdb {
-
-class DIAEnumInjectedSources : public IPDBEnumChildren<IPDBInjectedSource> {
-public:
- explicit DIAEnumInjectedSources(
- CComPtr<IDiaEnumInjectedSources> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumInjectedSources> Enumerator;
-};
-} // namespace pdb
-} // namespace llvm
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIAENUMINJECTEDSOURCES_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumLineNumbers.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumLineNumbers.h
deleted file mode 100644
index 21dbc4b1276..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumLineNumbers.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumLineNumbers.h - DIA Line Number Enumerator impl -----*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMLINENUMBERS_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMLINENUMBERS_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBLineNumber.h"
-
-namespace llvm {
-namespace pdb {
-class IPDBLineNumber;
-
-class DIAEnumLineNumbers : public IPDBEnumChildren<IPDBLineNumber> {
-public:
- explicit DIAEnumLineNumbers(CComPtr<IDiaEnumLineNumbers> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumLineNumbers> Enumerator;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSectionContribs.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSectionContribs.h
deleted file mode 100644
index 2e44bb48ac6..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSectionContribs.h
+++ /dev/null
@@ -1,49 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumSectionContribs.h --------------------------------- -*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMSECTIONCONTRIBS_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMSECTIONCONTRIBS_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBSectionContrib.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIAEnumSectionContribs : public IPDBEnumChildren<IPDBSectionContrib> {
-public:
- explicit DIAEnumSectionContribs(
- const DIASession &PDBSession,
- CComPtr<IDiaEnumSectionContribs> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- const DIASession &Session;
- CComPtr<IDiaEnumSectionContribs> Enumerator;
-};
-} // namespace pdb
-} // namespace llvm
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIAENUMSECTIONCONTRIBS_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSourceFiles.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSourceFiles.h
deleted file mode 100644
index 43ea2df3833..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSourceFiles.h
+++ /dev/null
@@ -1,48 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumSourceFiles.h - DIA Source File Enumerator impl -----*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMSOURCEFILES_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMSOURCEFILES_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBSourceFile.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIAEnumSourceFiles : public IPDBEnumChildren<IPDBSourceFile> {
-public:
- explicit DIAEnumSourceFiles(const DIASession &PDBSession,
- CComPtr<IDiaEnumSourceFiles> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- ChildTypePtr getChildAtIndex(uint32_t Index) const override;
- ChildTypePtr getNext() override;
- void reset() override;
-
-private:
- const DIASession &Session;
- CComPtr<IDiaEnumSourceFiles> Enumerator;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSymbols.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSymbols.h
deleted file mode 100644
index d8df6776652..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumSymbols.h
+++ /dev/null
@@ -1,48 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- DIAEnumSymbols.h - DIA Symbol Enumerator impl --------------*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMSYMBOLS_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMSYMBOLS_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/PDBSymbol.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIAEnumSymbols : public IPDBEnumChildren<PDBSymbol> {
-public:
- explicit DIAEnumSymbols(const DIASession &Session,
- CComPtr<IDiaEnumSymbols> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- std::unique_ptr<PDBSymbol> getChildAtIndex(uint32_t Index) const override;
- std::unique_ptr<PDBSymbol> getNext() override;
- void reset() override;
-
-private:
- const DIASession &Session;
- CComPtr<IDiaEnumSymbols> Enumerator;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumTables.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumTables.h
deleted file mode 100644
index b4d41eb3923..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAEnumTables.h
+++ /dev/null
@@ -1,46 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIAEnumTables.h - DIA Tables Enumerator Impl -------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAENUMTABLES_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAENUMTABLES_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
-#include "llvm/DebugInfo/PDB/IPDBTable.h"
-
-namespace llvm {
-namespace pdb {
-class IPDBTable;
-
-class DIAEnumTables : public IPDBEnumChildren<IPDBTable> {
-public:
- explicit DIAEnumTables(CComPtr<IDiaEnumTables> DiaEnumerator);
-
- uint32_t getChildCount() const override;
- std::unique_ptr<IPDBTable> getChildAtIndex(uint32_t Index) const override;
- std::unique_ptr<IPDBTable> getNext() override;
- void reset() override;
-
-private:
- CComPtr<IDiaEnumTables> Enumerator;
-};
-}
-}
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIAENUMTABLES_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAError.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAError.h
deleted file mode 100644
index 0c3342967e1..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAError.h
+++ /dev/null
@@ -1,61 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIAError.h - Error extensions for PDB DIA implementation -*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAERROR_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAERROR_H
-
-#include "llvm/ADT/StringRef.h"
-#include "llvm/Support/Error.h"
-
-namespace llvm {
-namespace pdb {
-enum class dia_error_code {
- unspecified = 1,
- could_not_create_impl,
- invalid_file_format,
- invalid_parameter,
- already_loaded,
- debug_info_mismatch,
-};
-} // namespace pdb
-} // namespace llvm
-
-namespace std {
-template <>
-struct is_error_code_enum<llvm::pdb::dia_error_code> : std::true_type {};
-} // namespace std
-
-namespace llvm {
-namespace pdb {
-const std::error_category &DIAErrCategory();
-
-inline std::error_code make_error_code(dia_error_code E) {
- return std::error_code(static_cast<int>(E), DIAErrCategory());
-}
-
-/// Base class for errors originating in DIA SDK, e.g. COM calls
-class DIAError : public ErrorInfo<DIAError, StringError> {
-public:
- using ErrorInfo<DIAError, StringError>::ErrorInfo;
- DIAError(const Twine &S) : ErrorInfo(S, dia_error_code::unspecified) {}
- static char ID;
-};
-} // namespace pdb
-} // namespace llvm
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAFrameData.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAFrameData.h
deleted file mode 100644
index 104017577f2..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAFrameData.h
+++ /dev/null
@@ -1,49 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIAFrameData.h - DIA Impl. of IPDBFrameData ---------------- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAFRAMEDATA_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAFRAMEDATA_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBFrameData.h"
-
-namespace llvm {
-namespace pdb {
-
-class DIASession;
-
-class DIAFrameData : public IPDBFrameData {
-public:
- explicit DIAFrameData(CComPtr<IDiaFrameData> DiaFrameData);
-
- uint32_t getAddressOffset() const override;
- uint32_t getAddressSection() const override;
- uint32_t getLengthBlock() const override;
- std::string getProgram() const override;
- uint32_t getRelativeVirtualAddress() const override;
- uint64_t getVirtualAddress() const override;
-
-private:
- CComPtr<IDiaFrameData> FrameData;
-};
-
-} // namespace pdb
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAInjectedSource.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAInjectedSource.h
deleted file mode 100644
index fd1732f8111..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAInjectedSource.h
+++ /dev/null
@@ -1,48 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIAInjectedSource.h - DIA impl for IPDBInjectedSource ----*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAINJECTEDSOURCE_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAINJECTEDSOURCE_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBInjectedSource.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIAInjectedSource : public IPDBInjectedSource {
-public:
- explicit DIAInjectedSource(CComPtr<IDiaInjectedSource> DiaSourceFile);
-
- uint32_t getCrc32() const override;
- uint64_t getCodeByteSize() const override;
- std::string getFileName() const override;
- std::string getObjectFileName() const override;
- std::string getVirtualFileName() const override;
- uint32_t getCompression() const override;
- std::string getCode() const override;
-
-private:
- CComPtr<IDiaInjectedSource> SourceFile;
-};
-} // namespace pdb
-} // namespace llvm
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIAINJECTEDSOURCE_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIALineNumber.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIALineNumber.h
deleted file mode 100644
index 42db84a6ea9..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIALineNumber.h
+++ /dev/null
@@ -1,50 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIALineNumber.h - DIA implementation of IPDBLineNumber ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIALINENUMBER_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIALINENUMBER_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBLineNumber.h"
-
-namespace llvm {
-namespace pdb {
-class DIALineNumber : public IPDBLineNumber {
-public:
- explicit DIALineNumber(CComPtr<IDiaLineNumber> DiaLineNumber);
-
- uint32_t getLineNumber() const override;
- uint32_t getLineNumberEnd() const override;
- uint32_t getColumnNumber() const override;
- uint32_t getColumnNumberEnd() const override;
- uint32_t getAddressSection() const override;
- uint32_t getAddressOffset() const override;
- uint32_t getRelativeVirtualAddress() const override;
- uint64_t getVirtualAddress() const override;
- uint32_t getLength() const override;
- uint32_t getSourceFileId() const override;
- uint32_t getCompilandId() const override;
- bool isStatement() const override;
-
-private:
- CComPtr<IDiaLineNumber> LineNumber;
-};
-}
-}
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIARawSymbol.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIARawSymbol.h
deleted file mode 100644
index 0b3c91431b7..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIARawSymbol.h
+++ /dev/null
@@ -1,244 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIARawSymbol.h - DIA implementation of IPDBRawSymbol ----*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIARAWSYMBOL_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIARAWSYMBOL_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBRawSymbol.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-class DIARawSymbol : public IPDBRawSymbol {
-public:
- DIARawSymbol(const DIASession &PDBSession, CComPtr<IDiaSymbol> DiaSymbol);
-
- void dump(raw_ostream &OS, int Indent, PdbSymbolIdField ShowIdFields,
- PdbSymbolIdField RecurseIdFields) const override;
-
- CComPtr<IDiaSymbol> getDiaSymbol() const { return Symbol; }
-
- std::unique_ptr<IPDBEnumSymbols>
- findChildren(PDB_SymType Type) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findChildren(PDB_SymType Type, StringRef Name,
- PDB_NameSearchFlags Flags) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findChildrenByAddr(PDB_SymType Type, StringRef Name,
- PDB_NameSearchFlags Flags,
- uint32_t Section, uint32_t Offset) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findChildrenByVA(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags,
- uint64_t VA) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findChildrenByRVA(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags,
- uint32_t RVA) const override;
-
- std::unique_ptr<IPDBEnumSymbols>
- findInlineFramesByAddr(uint32_t Section, uint32_t Offset) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findInlineFramesByRVA(uint32_t RVA) const override;
- std::unique_ptr<IPDBEnumSymbols>
- findInlineFramesByVA(uint64_t VA) const override;
-
- std::unique_ptr<IPDBEnumLineNumbers> findInlineeLines() const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findInlineeLinesByAddr(uint32_t Section, uint32_t Offset,
- uint32_t Length) const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findInlineeLinesByRVA(uint32_t RVA, uint32_t Length) const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findInlineeLinesByVA(uint64_t VA, uint32_t Length) const override;
-
- void getDataBytes(llvm::SmallVector<uint8_t, 32> &bytes) const override;
- void getFrontEndVersion(VersionInfo &Version) const override;
- void getBackEndVersion(VersionInfo &Version) const override;
- PDB_MemberAccess getAccess() const override;
- uint32_t getAddressOffset() const override;
- uint32_t getAddressSection() const override;
- uint32_t getAge() const override;
- SymIndexId getArrayIndexTypeId() const override;
- uint32_t getBaseDataOffset() const override;
- uint32_t getBaseDataSlot() const override;
- SymIndexId getBaseSymbolId() const override;
- PDB_BuiltinType getBuiltinType() const override;
- uint32_t getBitPosition() const override;
- PDB_CallingConv getCallingConvention() const override;
- SymIndexId getClassParentId() const override;
- std::string getCompilerName() const override;
- uint32_t getCount() const override;
- uint32_t getCountLiveRanges() const override;
- PDB_Lang getLanguage() const override;
- SymIndexId getLexicalParentId() const override;
- std::string getLibraryName() const override;
- uint32_t getLiveRangeStartAddressOffset() const override;
- uint32_t getLiveRangeStartAddressSection() const override;
- uint32_t getLiveRangeStartRelativeVirtualAddress() const override;
- codeview::RegisterId getLocalBasePointerRegisterId() const override;
- SymIndexId getLowerBoundId() const override;
- uint32_t getMemorySpaceKind() const override;
- std::string getName() const override;
- uint32_t getNumberOfAcceleratorPointerTags() const override;
- uint32_t getNumberOfColumns() const override;
- uint32_t getNumberOfModifiers() const override;
- uint32_t getNumberOfRegisterIndices() const override;
- uint32_t getNumberOfRows() const override;
- std::string getObjectFileName() const override;
- uint32_t getOemId() const override;
- SymIndexId getOemSymbolId() const override;
- uint32_t getOffsetInUdt() const override;
- PDB_Cpu getPlatform() const override;
- uint32_t getRank() const override;
- codeview::RegisterId getRegisterId() const override;
- uint32_t getRegisterType() const override;
- uint32_t getRelativeVirtualAddress() const override;
- uint32_t getSamplerSlot() const override;
- uint32_t getSignature() const override;
- uint32_t getSizeInUdt() const override;
- uint32_t getSlot() const override;
- std::string getSourceFileName() const override;
- std::unique_ptr<IPDBLineNumber> getSrcLineOnTypeDefn() const override;
- uint32_t getStride() const override;
- SymIndexId getSubTypeId() const override;
- std::string getSymbolsFileName() const override;
- SymIndexId getSymIndexId() const override;
- uint32_t getTargetOffset() const override;
- uint32_t getTargetRelativeVirtualAddress() const override;
- uint64_t getTargetVirtualAddress() const override;
- uint32_t getTargetSection() const override;
- uint32_t getTextureSlot() const override;
- uint32_t getTimeStamp() const override;
- uint32_t getToken() const override;
- SymIndexId getTypeId() const override;
- uint32_t getUavSlot() const override;
- std::string getUndecoratedName() const override;
- std::string getUndecoratedNameEx(PDB_UndnameFlags Flags) const override;
- SymIndexId getUnmodifiedTypeId() const override;
- SymIndexId getUpperBoundId() const override;
- Variant getValue() const override;
- uint32_t getVirtualBaseDispIndex() const override;
- uint32_t getVirtualBaseOffset() const override;
- SymIndexId getVirtualTableShapeId() const override;
- std::unique_ptr<PDBSymbolTypeBuiltin>
- getVirtualBaseTableType() const override;
- PDB_DataKind getDataKind() const override;
- PDB_SymType getSymTag() const override;
- codeview::GUID getGuid() const override;
- int32_t getOffset() const override;
- int32_t getThisAdjust() const override;
- int32_t getVirtualBasePointerOffset() const override;
- PDB_LocType getLocationType() const override;
- PDB_Machine getMachineType() const override;
- codeview::ThunkOrdinal getThunkOrdinal() const override;
- uint64_t getLength() const override;
- uint64_t getLiveRangeLength() const override;
- uint64_t getVirtualAddress() const override;
- PDB_UdtType getUdtKind() const override;
- bool hasConstructor() const override;
- bool hasCustomCallingConvention() const override;
- bool hasFarReturn() const override;
- bool isCode() const override;
- bool isCompilerGenerated() const override;
- bool isConstType() const override;
- bool isEditAndContinueEnabled() const override;
- bool isFunction() const override;
- bool getAddressTaken() const override;
- bool getNoStackOrdering() const override;
- bool hasAlloca() const override;
- bool hasAssignmentOperator() const override;
- bool hasCTypes() const override;
- bool hasCastOperator() const override;
- bool hasDebugInfo() const override;
- bool hasEH() const override;
- bool hasEHa() const override;
- bool hasInlAsm() const override;
- bool hasInlineAttribute() const override;
- bool hasInterruptReturn() const override;
- bool hasFramePointer() const override;
- bool hasLongJump() const override;
- bool hasManagedCode() const override;
- bool hasNestedTypes() const override;
- bool hasNoInlineAttribute() const override;
- bool hasNoReturnAttribute() const override;
- bool hasOptimizedCodeDebugInfo() const override;
- bool hasOverloadedOperator() const override;
- bool hasSEH() const override;
- bool hasSecurityChecks() const override;
- bool hasSetJump() const override;
- bool hasStrictGSCheck() const override;
- bool isAcceleratorGroupSharedLocal() const override;
- bool isAcceleratorPointerTagLiveRange() const override;
- bool isAcceleratorStubFunction() const override;
- bool isAggregated() const override;
- bool isIntroVirtualFunction() const override;
- bool isCVTCIL() const override;
- bool isConstructorVirtualBase() const override;
- bool isCxxReturnUdt() const override;
- bool isDataAligned() const override;
- bool isHLSLData() const override;
- bool isHotpatchable() const override;
- bool isIndirectVirtualBaseClass() const override;
- bool isInterfaceUdt() const override;
- bool isIntrinsic() const override;
- bool isLTCG() const override;
- bool isLocationControlFlowDependent() const override;
- bool isMSILNetmodule() const override;
- bool isMatrixRowMajor() const override;
- bool isManagedCode() const override;
- bool isMSILCode() const override;
- bool isMultipleInheritance() const override;
- bool isNaked() const override;
- bool isNested() const override;
- bool isOptimizedAway() const override;
- bool isPacked() const override;
- bool isPointerBasedOnSymbolValue() const override;
- bool isPointerToDataMember() const override;
- bool isPointerToMemberFunction() const override;
- bool isPureVirtual() const override;
- bool isRValueReference() const override;
- bool isRefUdt() const override;
- bool isReference() const override;
- bool isRestrictedType() const override;
- bool isReturnValue() const override;
- bool isSafeBuffers() const override;
- bool isScoped() const override;
- bool isSdl() const override;
- bool isSingleInheritance() const override;
- bool isSplitted() const override;
- bool isStatic() const override;
- bool hasPrivateSymbols() const override;
- bool isUnalignedType() const override;
- bool isUnreached() const override;
- bool isValueUdt() const override;
- bool isVirtual() const override;
- bool isVirtualBaseClass() const override;
- bool isVirtualInheritance() const override;
- bool isVolatileType() const override;
- bool wasInlined() const override;
- std::string getUnused() const override;
-
-private:
- const DIASession &Session;
- CComPtr<IDiaSymbol> Symbol;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASectionContrib.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASectionContrib.h
deleted file mode 100644
index af2d7b788af..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASectionContrib.h
+++ /dev/null
@@ -1,65 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIASectionContrib.h - DIA Impl. of IPDBSectionContrib ------ C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIASECTIONCONTRIB_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIASECTIONCONTRIB_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBSectionContrib.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIASectionContrib : public IPDBSectionContrib {
-public:
- explicit DIASectionContrib(const DIASession &PDBSession,
- CComPtr<IDiaSectionContrib> DiaSection);
-
- std::unique_ptr<PDBSymbolCompiland> getCompiland() const override;
- uint32_t getAddressSection() const override;
- uint32_t getAddressOffset() const override;
- uint32_t getRelativeVirtualAddress() const override;
- uint64_t getVirtualAddress() const override;
- uint32_t getLength() const override;
- bool isNotPaged() const override;
- bool hasCode() const override;
- bool hasCode16Bit() const override;
- bool hasInitializedData() const override;
- bool hasUninitializedData() const override;
- bool isRemoved() const override;
- bool hasComdat() const override;
- bool isDiscardable() const override;
- bool isNotCached() const override;
- bool isShared() const override;
- bool isExecutable() const override;
- bool isReadable() const override;
- bool isWritable() const override;
- uint32_t getDataCrc32() const override;
- uint32_t getRelocationsCrc32() const override;
- uint32_t getCompilandId() const override;
-
-private:
- const DIASession &Session;
- CComPtr<IDiaSectionContrib> Section;
-};
-} // namespace pdb
-} // namespace llvm
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIASECTIONCONTRIB_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASession.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASession.h
deleted file mode 100644
index 48b167843f4..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASession.h
+++ /dev/null
@@ -1,104 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIASession.h - DIA implementation of IPDBSession ---------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIASESSION_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIASESSION_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBSession.h"
-#include "llvm/Support/Error.h"
-
-#include <system_error>
-
-namespace llvm {
-class StringRef;
-
-namespace pdb {
-class DIASession : public IPDBSession {
-public:
- explicit DIASession(CComPtr<IDiaSession> DiaSession);
-
- static Error createFromPdb(StringRef Path,
- std::unique_ptr<IPDBSession> &Session);
- static Error createFromExe(StringRef Path,
- std::unique_ptr<IPDBSession> &Session);
-
- uint64_t getLoadAddress() const override;
- bool setLoadAddress(uint64_t Address) override;
- std::unique_ptr<PDBSymbolExe> getGlobalScope() override;
- std::unique_ptr<PDBSymbol> getSymbolById(SymIndexId SymbolId) const override;
-
- bool addressForVA(uint64_t VA, uint32_t &Section,
- uint32_t &Offset) const override;
- bool addressForRVA(uint32_t RVA, uint32_t &Section,
- uint32_t &Offset) const override;
-
- std::unique_ptr<PDBSymbol> findSymbolByAddress(uint64_t Address,
- PDB_SymType Type) override;
- std::unique_ptr<PDBSymbol> findSymbolByRVA(uint32_t RVA,
- PDB_SymType Type) override;
- std::unique_ptr<PDBSymbol> findSymbolBySectOffset(uint32_t Section,
- uint32_t Offset,
- PDB_SymType Type) override;
-
- std::unique_ptr<IPDBEnumLineNumbers>
- findLineNumbers(const PDBSymbolCompiland &Compiland,
- const IPDBSourceFile &File) const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findLineNumbersByAddress(uint64_t Address, uint32_t Length) const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findLineNumbersByRVA(uint32_t RVA, uint32_t Length) const override;
- std::unique_ptr<IPDBEnumLineNumbers>
- findLineNumbersBySectOffset(uint32_t Section, uint32_t Offset,
- uint32_t Length) const override;
-
- std::unique_ptr<IPDBEnumSourceFiles>
- findSourceFiles(const PDBSymbolCompiland *Compiland, llvm::StringRef Pattern,
- PDB_NameSearchFlags Flags) const override;
- std::unique_ptr<IPDBSourceFile>
- findOneSourceFile(const PDBSymbolCompiland *Compiland,
- llvm::StringRef Pattern,
- PDB_NameSearchFlags Flags) const override;
- std::unique_ptr<IPDBEnumChildren<PDBSymbolCompiland>>
- findCompilandsForSourceFile(llvm::StringRef Pattern,
- PDB_NameSearchFlags Flags) const override;
- std::unique_ptr<PDBSymbolCompiland>
- findOneCompilandForSourceFile(llvm::StringRef Pattern,
- PDB_NameSearchFlags Flags) const override;
- std::unique_ptr<IPDBEnumSourceFiles> getAllSourceFiles() const override;
- std::unique_ptr<IPDBEnumSourceFiles> getSourceFilesForCompiland(
- const PDBSymbolCompiland &Compiland) const override;
- std::unique_ptr<IPDBSourceFile>
- getSourceFileById(uint32_t FileId) const override;
-
- std::unique_ptr<IPDBEnumDataStreams> getDebugStreams() const override;
-
- std::unique_ptr<IPDBEnumTables> getEnumTables() const override;
-
- std::unique_ptr<IPDBEnumInjectedSources> getInjectedSources() const override;
-
- std::unique_ptr<IPDBEnumSectionContribs> getSectionContribs() const override;
-
- std::unique_ptr<IPDBEnumFrameData> getFrameData() const override;
-private:
- CComPtr<IDiaSession> Session;
-};
-} // namespace pdb
-} // namespace llvm
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASourceFile.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASourceFile.h
deleted file mode 100644
index 46e1a2b96c3..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASourceFile.h
+++ /dev/null
@@ -1,51 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIASourceFile.h - DIA implementation of IPDBSourceFile ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIASOURCEFILE_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIASOURCEFILE_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBSourceFile.h"
-
-namespace llvm {
-namespace pdb {
-class DIASession;
-
-class DIASourceFile : public IPDBSourceFile {
-public:
- explicit DIASourceFile(const DIASession &Session,
- CComPtr<IDiaSourceFile> DiaSourceFile);
-
- std::string getFileName() const override;
- uint32_t getUniqueId() const override;
- std::string getChecksum() const override;
- PDB_Checksum getChecksumType() const override;
- std::unique_ptr<IPDBEnumChildren<PDBSymbolCompiland>>
- getCompilands() const override;
-
- CComPtr<IDiaSourceFile> getDiaFile() const { return SourceFile; }
-
-private:
- const DIASession &Session;
- CComPtr<IDiaSourceFile> SourceFile;
-};
-}
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASupport.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASupport.h
deleted file mode 100644
index c04f4070382..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIASupport.h
+++ /dev/null
@@ -1,44 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIASupport.h - Common header includes for DIA ------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-// Common defines and header includes for all LLVMDebugInfoPDBDIA. The
-// definitions here configure the necessary #defines and include system headers
-// in the proper order for using DIA.
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIASUPPORT_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIASUPPORT_H
-
-// Require at least Vista
-#define NTDDI_VERSION NTDDI_VISTA
-#define _WIN32_WINNT _WIN32_WINNT_VISTA
-#define WINVER _WIN32_WINNT_VISTA
-#ifndef NOMINMAX
-#define NOMINMAX
-#endif
-
-// atlbase.h has to come before windows.h
-#include <atlbase.h>
-#include <windows.h>
-
-// DIA headers must come after windows headers.
-#include <cvconst.h>
-#include <dia2.h>
-#include <diacreate.h>
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIASUPPORT_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIATable.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIATable.h
deleted file mode 100644
index 97085ae5c95..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIATable.h
+++ /dev/null
@@ -1,42 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIATable.h - DIA implementation of IPDBTable -------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIATABLE_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIATABLE_H
-
-#include "DIASupport.h"
-#include "llvm/DebugInfo/PDB/IPDBTable.h"
-
-namespace llvm {
-namespace pdb {
-class DIATable : public IPDBTable {
-public:
- explicit DIATable(CComPtr<IDiaTable> DiaTable);
-
- uint32_t getItemCount() const override;
- std::string getName() const override;
- PDB_TableType getTableType() const override;
-
-private:
- CComPtr<IDiaTable> Table;
-};
-}
-}
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIATABLE_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAUtils.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAUtils.h
deleted file mode 100644
index fe0bd1b612b..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/DIA/DIAUtils.h
+++ /dev/null
@@ -1,41 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- DIAUtils.h - Utility functions for working with DIA ------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_DIA_DIAUTILS_H
-#define LLVM_DEBUGINFO_PDB_DIA_DIAUTILS_H
-
-#include "llvm/ADT/ArrayRef.h"
-#include "llvm/Support/ConvertUTF.h"
-
-template <typename Obj>
-std::string invokeBstrMethod(Obj &Object,
- HRESULT (__stdcall Obj::*Func)(BSTR *)) {
- CComBSTR Str16;
- HRESULT Result = (Object.*Func)(&Str16);
- if (S_OK != Result)
- return std::string();
-
- std::string Str8;
- llvm::ArrayRef<char> StrBytes(reinterpret_cast<char *>(Str16.m_str),
- Str16.ByteLength());
- llvm::convertUTF16ToUTF8String(StrBytes, Str8);
- return Str8;
-}
-
-#endif // LLVM_DEBUGINFO_PDB_DIA_DIAUTILS_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/Native/Formatters.h b/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/Native/Formatters.h
deleted file mode 100644
index d5fd6a83d0a..00000000000
--- a/contrib/libs/llvm12/include/llvm/DebugInfo/PDB/Native/Formatters.h
+++ /dev/null
@@ -1,55 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- Formatters.h ---------------------------------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_DEBUGINFO_PDB_NATIVE_FORMATTERS_H
-#define LLVM_DEBUGINFO_PDB_NATIVE_FORMATTERS_H
-
-#include "llvm/ADT/ArrayRef.h"
-#include "llvm/ADT/StringRef.h"
-#include "llvm/DebugInfo/CodeView/Formatters.h"
-#include "llvm/DebugInfo/PDB/Native/RawConstants.h"
-#include "llvm/DebugInfo/PDB/Native/RawTypes.h"
-#include "llvm/Support/FormatProviders.h"
-
-#define FORMAT_CASE(Value, Name) \
- case Value: \
- Stream << Name; \
- break;
-
-namespace llvm {
-template <> struct format_provider<pdb::PdbRaw_ImplVer> {
- static void format(const pdb::PdbRaw_ImplVer &V, llvm::raw_ostream &Stream,
- StringRef Style) {
- switch (V) {
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC110, "VC110")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC140, "VC140")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC2, "VC2")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC4, "VC4")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC41, "VC41")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC50, "VC50")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC70, "VC70")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC70Dep, "VC70Dep")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC80, "VC80")
- FORMAT_CASE(pdb::PdbRaw_ImplVer::PdbImplVC98, "VC98")
- }
- }
-};
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ExecutionEngine/OProfileWrapper.h b/contrib/libs/llvm12/include/llvm/ExecutionEngine/OProfileWrapper.h
deleted file mode 100644
index 8993cf64a61..00000000000
--- a/contrib/libs/llvm12/include/llvm/ExecutionEngine/OProfileWrapper.h
+++ /dev/null
@@ -1,134 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- OProfileWrapper.h - OProfile JIT API Wrapper ------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-// This file defines a OProfileWrapper object that detects if the oprofile
-// daemon is running, and provides wrappers for opagent functions used to
-// communicate with the oprofile JIT interface. The dynamic library libopagent
-// does not need to be linked directly as this object lazily loads the library
-// when the first op_ function is called.
-//
-// See http://oprofile.sourceforge.net/doc/devel/jit-interface.html for the
-// definition of the interface.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_EXECUTIONENGINE_OPROFILEWRAPPER_H
-#define LLVM_EXECUTIONENGINE_OPROFILEWRAPPER_H
-
-#include "llvm/Support/DataTypes.h"
-#include <opagent.h>
-
-namespace llvm {
-
-
-class OProfileWrapper {
- typedef op_agent_t (*op_open_agent_ptr_t)();
- typedef int (*op_close_agent_ptr_t)(op_agent_t);
- typedef int (*op_write_native_code_ptr_t)(op_agent_t,
- const char*,
- uint64_t,
- void const*,
- const unsigned int);
- typedef int (*op_write_debug_line_info_ptr_t)(op_agent_t,
- void const*,
- size_t,
- struct debug_line_info const*);
- typedef int (*op_unload_native_code_ptr_t)(op_agent_t, uint64_t);
-
- // Also used for op_minor_version function which has the same signature
- typedef int (*op_major_version_ptr_t)();
-
- // This is not a part of the opagent API, but is useful nonetheless
- typedef bool (*IsOProfileRunningPtrT)();
-
-
- op_agent_t Agent;
- op_open_agent_ptr_t OpenAgentFunc;
- op_close_agent_ptr_t CloseAgentFunc;
- op_write_native_code_ptr_t WriteNativeCodeFunc;
- op_write_debug_line_info_ptr_t WriteDebugLineInfoFunc;
- op_unload_native_code_ptr_t UnloadNativeCodeFunc;
- op_major_version_ptr_t MajorVersionFunc;
- op_major_version_ptr_t MinorVersionFunc;
- IsOProfileRunningPtrT IsOProfileRunningFunc;
-
- bool Initialized;
-
-public:
- OProfileWrapper();
-
- // For testing with a mock opagent implementation, skips the dynamic load and
- // the function resolution.
- OProfileWrapper(op_open_agent_ptr_t OpenAgentImpl,
- op_close_agent_ptr_t CloseAgentImpl,
- op_write_native_code_ptr_t WriteNativeCodeImpl,
- op_write_debug_line_info_ptr_t WriteDebugLineInfoImpl,
- op_unload_native_code_ptr_t UnloadNativeCodeImpl,
- op_major_version_ptr_t MajorVersionImpl,
- op_major_version_ptr_t MinorVersionImpl,
- IsOProfileRunningPtrT MockIsOProfileRunningImpl = 0)
- : OpenAgentFunc(OpenAgentImpl),
- CloseAgentFunc(CloseAgentImpl),
- WriteNativeCodeFunc(WriteNativeCodeImpl),
- WriteDebugLineInfoFunc(WriteDebugLineInfoImpl),
- UnloadNativeCodeFunc(UnloadNativeCodeImpl),
- MajorVersionFunc(MajorVersionImpl),
- MinorVersionFunc(MinorVersionImpl),
- IsOProfileRunningFunc(MockIsOProfileRunningImpl),
- Initialized(true)
- {
- }
-
- // Calls op_open_agent in the oprofile JIT library and saves the returned
- // op_agent_t handle internally so it can be used when calling all the other
- // op_* functions. Callers of this class do not need to keep track of
- // op_agent_t objects.
- bool op_open_agent();
-
- int op_close_agent();
- int op_write_native_code(const char* name,
- uint64_t addr,
- void const* code,
- const unsigned int size);
- int op_write_debug_line_info(void const* code,
- size_t num_entries,
- struct debug_line_info const* info);
- int op_unload_native_code(uint64_t addr);
- int op_major_version();
- int op_minor_version();
-
- // Returns true if the oprofiled process is running, the opagent library is
- // loaded and a connection to the agent has been established, and false
- // otherwise.
- bool isAgentAvailable();
-
-private:
- // Loads the libopagent library and initializes this wrapper if the oprofile
- // daemon is running
- bool initialize();
-
- // Searches /proc for the oprofile daemon and returns true if the process if
- // found, or false otherwise.
- bool checkForOProfileProcEntry();
-
- bool isOProfileRunning();
-};
-
-} // namespace llvm
-
-#endif // LLVM_EXECUTIONENGINE_OPROFILEWRAPPER_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/ExecutionEngine/OrcMCJITReplacement.h b/contrib/libs/llvm12/include/llvm/ExecutionEngine/OrcMCJITReplacement.h
deleted file mode 100644
index 5e55a7aa1d9..00000000000
--- a/contrib/libs/llvm12/include/llvm/ExecutionEngine/OrcMCJITReplacement.h
+++ /dev/null
@@ -1,48 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===---- OrcMCJITReplacement.h - Orc-based MCJIT replacement ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file forces OrcMCJITReplacement to link in on certain operating systems.
-// (Windows).
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_EXECUTIONENGINE_ORCMCJITREPLACEMENT_H
-#define LLVM_EXECUTIONENGINE_ORCMCJITREPLACEMENT_H
-
-#include "llvm/ExecutionEngine/ExecutionEngine.h"
-#include <cstdlib>
-
-extern "C" void LLVMLinkInOrcMCJITReplacement();
-
-namespace {
- struct ForceOrcMCJITReplacementLinking {
- ForceOrcMCJITReplacementLinking() {
- // We must reference OrcMCJITReplacement in such a way that compilers will
- // not delete it all as dead code, even with whole program optimization,
- // yet is effectively a NO-OP. As the compiler isn't smart enough to know
- // that getenv() never returns -1, this will do the job.
- if (std::getenv("bar") != (char*) -1)
- return;
-
- LLVMLinkInOrcMCJITReplacement();
- }
- } ForceOrcMCJITReplacementLinking;
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMP.inc b/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMP.inc
deleted file mode 100644
index 390fac5410c..00000000000
--- a/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMP.inc
+++ /dev/null
@@ -1,3507 +0,0 @@
-#ifdef GEN_FLANG_DIRECTIVE_CLAUSE_SETS
-#undef GEN_FLANG_DIRECTIVE_CLAUSE_SETS
-
-namespace llvm {
-namespace omp {
-
- // Sets for allocate
-
- static OmpClauseSet allowedClauses_OMPD_allocate {
- llvm::omp::Clause::OMPC_allocator,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_allocate {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_allocate {
- };
-
- static OmpClauseSet requiredClauses_OMPD_allocate {
- };
-
- // Sets for assumes
-
- static OmpClauseSet allowedClauses_OMPD_assumes {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_assumes {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_assumes {
- };
-
- static OmpClauseSet requiredClauses_OMPD_assumes {
- };
-
- // Sets for atomic
-
- static OmpClauseSet allowedClauses_OMPD_atomic {
- llvm::omp::Clause::OMPC_read,
- llvm::omp::Clause::OMPC_write,
- llvm::omp::Clause::OMPC_update,
- llvm::omp::Clause::OMPC_capture,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_atomic {
- llvm::omp::Clause::OMPC_seq_cst,
- llvm::omp::Clause::OMPC_acq_rel,
- llvm::omp::Clause::OMPC_acquire,
- llvm::omp::Clause::OMPC_release,
- llvm::omp::Clause::OMPC_relaxed,
- llvm::omp::Clause::OMPC_hint,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_atomic {
- };
-
- static OmpClauseSet requiredClauses_OMPD_atomic {
- };
-
- // Sets for barrier
-
- static OmpClauseSet allowedClauses_OMPD_barrier {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_barrier {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_barrier {
- };
-
- static OmpClauseSet requiredClauses_OMPD_barrier {
- };
-
- // Sets for begin assumes
-
- static OmpClauseSet allowedClauses_OMPD_begin_assumes {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_begin_assumes {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_begin_assumes {
- };
-
- static OmpClauseSet requiredClauses_OMPD_begin_assumes {
- };
-
- // Sets for begin declare variant
-
- static OmpClauseSet allowedClauses_OMPD_begin_declare_variant {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_begin_declare_variant {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_begin_declare_variant {
- };
-
- static OmpClauseSet requiredClauses_OMPD_begin_declare_variant {
- };
-
- // Sets for cancel
-
- static OmpClauseSet allowedClauses_OMPD_cancel {
- llvm::omp::Clause::OMPC_if,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_cancel {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_cancel {
- };
-
- static OmpClauseSet requiredClauses_OMPD_cancel {
- };
-
- // Sets for cancellation point
-
- static OmpClauseSet allowedClauses_OMPD_cancellation_point {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_cancellation_point {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_cancellation_point {
- };
-
- static OmpClauseSet requiredClauses_OMPD_cancellation_point {
- };
-
- // Sets for critical
-
- static OmpClauseSet allowedClauses_OMPD_critical {
- llvm::omp::Clause::OMPC_hint,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_critical {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_critical {
- };
-
- static OmpClauseSet requiredClauses_OMPD_critical {
- };
-
- // Sets for declare mapper
-
- static OmpClauseSet allowedClauses_OMPD_declare_mapper {
- llvm::omp::Clause::OMPC_map,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_declare_mapper {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_declare_mapper {
- };
-
- static OmpClauseSet requiredClauses_OMPD_declare_mapper {
- };
-
- // Sets for declare reduction
-
- static OmpClauseSet allowedClauses_OMPD_declare_reduction {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_declare_reduction {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_declare_reduction {
- };
-
- static OmpClauseSet requiredClauses_OMPD_declare_reduction {
- };
-
- // Sets for declare simd
-
- static OmpClauseSet allowedClauses_OMPD_declare_simd {
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_uniform,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_declare_simd {
- llvm::omp::Clause::OMPC_simdlen,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_declare_simd {
- llvm::omp::Clause::OMPC_inbranch,
- llvm::omp::Clause::OMPC_notinbranch,
- };
-
- static OmpClauseSet requiredClauses_OMPD_declare_simd {
- };
-
- // Sets for declare target
-
- static OmpClauseSet allowedClauses_OMPD_declare_target {
- llvm::omp::Clause::OMPC_to,
- llvm::omp::Clause::OMPC_link,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_declare_target {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_declare_target {
- };
-
- static OmpClauseSet requiredClauses_OMPD_declare_target {
- };
-
- // Sets for declare variant
-
- static OmpClauseSet allowedClauses_OMPD_declare_variant {
- llvm::omp::Clause::OMPC_match,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_declare_variant {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_declare_variant {
- };
-
- static OmpClauseSet requiredClauses_OMPD_declare_variant {
- };
-
- // Sets for depobj
-
- static OmpClauseSet allowedClauses_OMPD_depobj {
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_destroy,
- llvm::omp::Clause::OMPC_update,
- llvm::omp::Clause::OMPC_depobj,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_depobj {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_depobj {
- };
-
- static OmpClauseSet requiredClauses_OMPD_depobj {
- };
-
- // Sets for distribute
-
- static OmpClauseSet allowedClauses_OMPD_distribute {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute {
- };
-
- // Sets for distribute parallel do
-
- static OmpClauseSet allowedClauses_OMPD_distribute_parallel_do {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_linear,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute_parallel_do {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute_parallel_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute_parallel_do {
- };
-
- // Sets for distribute parallel do simd
-
- static OmpClauseSet allowedClauses_OMPD_distribute_parallel_do_simd {
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute_parallel_do_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute_parallel_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute_parallel_do_simd {
- };
-
- // Sets for distribute parallel for
-
- static OmpClauseSet allowedClauses_OMPD_distribute_parallel_for {
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute_parallel_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute_parallel_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute_parallel_for {
- };
-
- // Sets for distribute parallel for simd
-
- static OmpClauseSet allowedClauses_OMPD_distribute_parallel_for_simd {
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute_parallel_for_simd {
- };
-
- // Sets for distribute simd
-
- static OmpClauseSet allowedClauses_OMPD_distribute_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_distribute_simd {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_distribute_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_distribute_simd {
- };
-
- // Sets for do
-
- static OmpClauseSet allowedClauses_OMPD_do {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_reduction,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_do {
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_do {
- };
-
- // Sets for do simd
-
- static OmpClauseSet allowedClauses_OMPD_do_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_reduction,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_do_simd {
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_do_simd {
- };
-
- // Sets for end assumes
-
- static OmpClauseSet allowedClauses_OMPD_end_assumes {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_assumes {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_assumes {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_assumes {
- };
-
- // Sets for end declare target
-
- static OmpClauseSet allowedClauses_OMPD_end_declare_target {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_declare_target {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_declare_target {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_declare_target {
- };
-
- // Sets for end declare variant
-
- static OmpClauseSet allowedClauses_OMPD_end_declare_variant {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_declare_variant {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_declare_variant {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_declare_variant {
- };
-
- // Sets for end do
-
- static OmpClauseSet allowedClauses_OMPD_end_do {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_do {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_do {
- };
-
- // Sets for end do simd
-
- static OmpClauseSet allowedClauses_OMPD_end_do_simd {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_do_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_do_simd {
- };
-
- // Sets for end sections
-
- static OmpClauseSet allowedClauses_OMPD_end_sections {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_sections {
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_sections {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_sections {
- };
-
- // Sets for end single
-
- static OmpClauseSet allowedClauses_OMPD_end_single {
- llvm::omp::Clause::OMPC_copyprivate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_single {
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_single {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_single {
- };
-
- // Sets for end workshare
-
- static OmpClauseSet allowedClauses_OMPD_end_workshare {
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_end_workshare {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_end_workshare {
- };
-
- static OmpClauseSet requiredClauses_OMPD_end_workshare {
- };
-
- // Sets for flush
-
- static OmpClauseSet allowedClauses_OMPD_flush {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_flush {
- llvm::omp::Clause::OMPC_acq_rel,
- llvm::omp::Clause::OMPC_acquire,
- llvm::omp::Clause::OMPC_release,
- llvm::omp::Clause::OMPC_flush,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_flush {
- };
-
- static OmpClauseSet requiredClauses_OMPD_flush {
- };
-
- // Sets for for
-
- static OmpClauseSet allowedClauses_OMPD_for {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_for {
- };
-
- // Sets for for simd
-
- static OmpClauseSet allowedClauses_OMPD_for_simd {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_for_simd {
- };
-
- // Sets for master
-
- static OmpClauseSet allowedClauses_OMPD_master {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_master {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_master {
- };
-
- static OmpClauseSet requiredClauses_OMPD_master {
- };
-
- // Sets for master taskloop
-
- static OmpClauseSet allowedClauses_OMPD_master_taskloop {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_priority,
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_num_tasks,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_in_reduction,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_master_taskloop {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_master_taskloop {
- };
-
- static OmpClauseSet requiredClauses_OMPD_master_taskloop {
- };
-
- // Sets for master taskloop simd
-
- static OmpClauseSet allowedClauses_OMPD_master_taskloop_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_priority,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_num_tasks,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_in_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_master_taskloop_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_master_taskloop_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_master_taskloop_simd {
- };
-
- // Sets for ordered
-
- static OmpClauseSet allowedClauses_OMPD_ordered {
- llvm::omp::Clause::OMPC_threads,
- llvm::omp::Clause::OMPC_simd,
- llvm::omp::Clause::OMPC_depend,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_ordered {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_ordered {
- };
-
- static OmpClauseSet requiredClauses_OMPD_ordered {
- };
-
- // Sets for parallel
-
- static OmpClauseSet allowedClauses_OMPD_parallel {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel {
- };
-
- // Sets for parallel do
-
- static OmpClauseSet allowedClauses_OMPD_parallel_do {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_do {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_collapse,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_do {
- };
-
- // Sets for parallel do simd
-
- static OmpClauseSet allowedClauses_OMPD_parallel_do_simd {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_do_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_do_simd {
- };
-
- // Sets for parallel for
-
- static OmpClauseSet allowedClauses_OMPD_parallel_for {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_for {
- };
-
- // Sets for parallel for simd
-
- static OmpClauseSet allowedClauses_OMPD_parallel_for_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_for_simd {
- };
-
- // Sets for parallel master
-
- static OmpClauseSet allowedClauses_OMPD_parallel_master {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_master {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_master {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_master {
- };
-
- // Sets for parallel master taskloop
-
- static OmpClauseSet allowedClauses_OMPD_parallel_master_taskloop {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_priority,
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_num_tasks,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_copyin,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_master_taskloop {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_master_taskloop {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_master_taskloop {
- };
-
- // Sets for parallel master taskloop simd
-
- static OmpClauseSet allowedClauses_OMPD_parallel_master_taskloop_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_priority,
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_num_tasks,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_master_taskloop_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_master_taskloop_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_master_taskloop_simd {
- };
-
- // Sets for parallel sections
-
- static OmpClauseSet allowedClauses_OMPD_parallel_sections {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_sections {
- llvm::omp::Clause::OMPC_num_threads,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_sections {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_sections {
- };
-
- // Sets for parallel workshare
-
- static OmpClauseSet allowedClauses_OMPD_parallel_workshare {
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_shared,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_parallel_workshare {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_parallel_workshare {
- };
-
- static OmpClauseSet requiredClauses_OMPD_parallel_workshare {
- };
-
- // Sets for requires
-
- static OmpClauseSet allowedClauses_OMPD_requires {
- llvm::omp::Clause::OMPC_unified_address,
- llvm::omp::Clause::OMPC_unified_shared_memory,
- llvm::omp::Clause::OMPC_reverse_offload,
- llvm::omp::Clause::OMPC_dynamic_allocators,
- llvm::omp::Clause::OMPC_atomic_default_mem_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_requires {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_requires {
- };
-
- static OmpClauseSet requiredClauses_OMPD_requires {
- };
-
- // Sets for scan
-
- static OmpClauseSet allowedClauses_OMPD_scan {
- llvm::omp::Clause::OMPC_inclusive,
- llvm::omp::Clause::OMPC_exclusive,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_scan {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_scan {
- };
-
- static OmpClauseSet requiredClauses_OMPD_scan {
- };
-
- // Sets for section
-
- static OmpClauseSet allowedClauses_OMPD_section {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_section {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_section {
- };
-
- static OmpClauseSet requiredClauses_OMPD_section {
- };
-
- // Sets for sections
-
- static OmpClauseSet allowedClauses_OMPD_sections {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_sections {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_sections {
- };
-
- static OmpClauseSet requiredClauses_OMPD_sections {
- };
-
- // Sets for simd
-
- static OmpClauseSet allowedClauses_OMPD_simd {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_simd {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_if,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_simd {
- };
-
- // Sets for single
-
- static OmpClauseSet allowedClauses_OMPD_single {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_copyprivate,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_single {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_single {
- };
-
- static OmpClauseSet requiredClauses_OMPD_single {
- };
-
- // Sets for target
-
- static OmpClauseSet allowedClauses_OMPD_target {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target {
- };
-
- // Sets for target data
-
- static OmpClauseSet allowedClauses_OMPD_target_data {
- llvm::omp::Clause::OMPC_use_device_ptr,
- llvm::omp::Clause::OMPC_use_device_addr,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_data {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_if,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_data {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_data {
- llvm::omp::Clause::OMPC_map,
- };
-
- // Sets for target enter data
-
- static OmpClauseSet allowedClauses_OMPD_target_enter_data {
- llvm::omp::Clause::OMPC_depend,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_enter_data {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_enter_data {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_enter_data {
- llvm::omp::Clause::OMPC_map,
- };
-
- // Sets for target exit data
-
- static OmpClauseSet allowedClauses_OMPD_target_exit_data {
- llvm::omp::Clause::OMPC_depend,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_exit_data {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_exit_data {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_exit_data {
- llvm::omp::Clause::OMPC_map,
- };
-
- // Sets for target parallel
-
- static OmpClauseSet allowedClauses_OMPD_target_parallel {
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_parallel {
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_parallel {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_parallel {
- };
-
- // Sets for target parallel do
-
- static OmpClauseSet allowedClauses_OMPD_target_parallel_do {
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_allocator,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_copyin,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_parallel_do {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_nowait,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_parallel_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_parallel_do {
- };
-
- // Sets for target parallel do simd
-
- static OmpClauseSet allowedClauses_OMPD_target_parallel_do_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_parallel_do_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_parallel_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_parallel_do_simd {
- };
-
- // Sets for target parallel for
-
- static OmpClauseSet allowedClauses_OMPD_target_parallel_for {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_parallel_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_parallel_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_parallel_for {
- };
-
- // Sets for target parallel for simd
-
- static OmpClauseSet allowedClauses_OMPD_target_parallel_for_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_parallel_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_parallel_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_parallel_for_simd {
- };
-
- // Sets for target simd
-
- static OmpClauseSet allowedClauses_OMPD_target_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_simd {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_schedule,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_simd {
- };
-
- // Sets for target teams
-
- static OmpClauseSet allowedClauses_OMPD_target_teams {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- llvm::omp::Clause::OMPC_shared,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams {
- };
-
- // Sets for target teams distribute
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_lastprivate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute {
- };
-
- // Sets for target teams distribute parallel do
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute_parallel_do {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute_parallel_do {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute_parallel_do {
- };
-
- // Sets for target teams distribute parallel do simd
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute_parallel_do_simd {
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_uses_allocators,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_nontemporal,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute_parallel_do_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute_parallel_do_simd {
- };
-
- // Sets for target teams distribute parallel for
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute_parallel_for {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute_parallel_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute_parallel_for {
- };
-
- // Sets for target teams distribute parallel for simd
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute_parallel_for_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute_parallel_for_simd {
- };
-
- // Sets for target teams distribute simd
-
- static OmpClauseSet allowedClauses_OMPD_target_teams_distribute_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_is_device_ptr,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_map,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_uses_allocators,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_teams_distribute_simd {
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_defaultmap,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_teams_distribute_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_teams_distribute_simd {
- };
-
- // Sets for target update
-
- static OmpClauseSet allowedClauses_OMPD_target_update {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_device,
- llvm::omp::Clause::OMPC_to,
- llvm::omp::Clause::OMPC_from,
- llvm::omp::Clause::OMPC_nowait,
- llvm::omp::Clause::OMPC_depend,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_target_update {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_target_update {
- };
-
- static OmpClauseSet requiredClauses_OMPD_target_update {
- };
-
- // Sets for task
-
- static OmpClauseSet allowedClauses_OMPD_task {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_depend,
- llvm::omp::Clause::OMPC_in_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_detach,
- llvm::omp::Clause::OMPC_affinity,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_task {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_priority,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_task {
- };
-
- static OmpClauseSet requiredClauses_OMPD_task {
- };
-
- // Sets for taskgroup
-
- static OmpClauseSet allowedClauses_OMPD_taskgroup {
- llvm::omp::Clause::OMPC_task_reduction,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_taskgroup {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_taskgroup {
- };
-
- static OmpClauseSet requiredClauses_OMPD_taskgroup {
- };
-
- // Sets for taskloop
-
- static OmpClauseSet allowedClauses_OMPD_taskloop {
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_untied,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_in_reduction,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_taskloop {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_priority,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_taskloop {
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_num_tasks,
- };
-
- static OmpClauseSet requiredClauses_OMPD_taskloop {
- };
-
- // Sets for taskloop simd
-
- static OmpClauseSet allowedClauses_OMPD_taskloop_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_in_reduction,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_mergeable,
- llvm::omp::Clause::OMPC_nogroup,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_untied,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_taskloop_simd {
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_final,
- llvm::omp::Clause::OMPC_priority,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_taskloop_simd {
- llvm::omp::Clause::OMPC_grainsize,
- llvm::omp::Clause::OMPC_num_tasks,
- };
-
- static OmpClauseSet requiredClauses_OMPD_taskloop_simd {
- };
-
- // Sets for taskwait
-
- static OmpClauseSet allowedClauses_OMPD_taskwait {
- llvm::omp::Clause::OMPC_depend,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_taskwait {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_taskwait {
- };
-
- static OmpClauseSet requiredClauses_OMPD_taskwait {
- };
-
- // Sets for taskyield
-
- static OmpClauseSet allowedClauses_OMPD_taskyield {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_taskyield {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_taskyield {
- };
-
- static OmpClauseSet requiredClauses_OMPD_taskyield {
- };
-
- // Sets for teams
-
- static OmpClauseSet allowedClauses_OMPD_teams {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams {
- };
-
- // Sets for teams distribute
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_allocate,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute {
- };
-
- // Sets for teams distribute parallel do
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute_parallel_do {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_linear,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute_parallel_do {
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_ordered,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute_parallel_do {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute_parallel_do {
- };
-
- // Sets for teams distribute parallel do simd
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute_parallel_do_simd {
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_nontemporal,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute_parallel_do_simd {
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_if,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute_parallel_do_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute_parallel_do_simd {
- };
-
- // Sets for teams distribute parallel for
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute_parallel_for {
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_copyin,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute_parallel_for {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute_parallel_for {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute_parallel_for {
- };
-
- // Sets for teams distribute parallel for simd
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute_parallel_for_simd {
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_threads,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_proc_bind,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_shared,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_schedule,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_thread_limit,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute_parallel_for_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute_parallel_for_simd {
- };
-
- // Sets for teams distribute simd
-
- static OmpClauseSet allowedClauses_OMPD_teams_distribute_simd {
- llvm::omp::Clause::OMPC_aligned,
- llvm::omp::Clause::OMPC_allocate,
- llvm::omp::Clause::OMPC_firstprivate,
- llvm::omp::Clause::OMPC_lastprivate,
- llvm::omp::Clause::OMPC_linear,
- llvm::omp::Clause::OMPC_nontemporal,
- llvm::omp::Clause::OMPC_order,
- llvm::omp::Clause::OMPC_private,
- llvm::omp::Clause::OMPC_reduction,
- llvm::omp::Clause::OMPC_shared,
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_teams_distribute_simd {
- llvm::omp::Clause::OMPC_collapse,
- llvm::omp::Clause::OMPC_default,
- llvm::omp::Clause::OMPC_dist_schedule,
- llvm::omp::Clause::OMPC_if,
- llvm::omp::Clause::OMPC_num_teams,
- llvm::omp::Clause::OMPC_safelen,
- llvm::omp::Clause::OMPC_simdlen,
- llvm::omp::Clause::OMPC_thread_limit,
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_teams_distribute_simd {
- };
-
- static OmpClauseSet requiredClauses_OMPD_teams_distribute_simd {
- };
-
- // Sets for threadprivate
-
- static OmpClauseSet allowedClauses_OMPD_threadprivate {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_threadprivate {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_threadprivate {
- };
-
- static OmpClauseSet requiredClauses_OMPD_threadprivate {
- };
-
- // Sets for unknown
-
- static OmpClauseSet allowedClauses_OMPD_unknown {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_unknown {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_unknown {
- };
-
- static OmpClauseSet requiredClauses_OMPD_unknown {
- };
-
- // Sets for workshare
-
- static OmpClauseSet allowedClauses_OMPD_workshare {
- };
-
- static OmpClauseSet allowedOnceClauses_OMPD_workshare {
- };
-
- static OmpClauseSet allowedExclusiveClauses_OMPD_workshare {
- };
-
- static OmpClauseSet requiredClauses_OMPD_workshare {
- };
-} // namespace omp
-} // namespace llvm
-
-#endif // GEN_FLANG_DIRECTIVE_CLAUSE_SETS
-
-#ifdef GEN_FLANG_DIRECTIVE_CLAUSE_MAP
-#undef GEN_FLANG_DIRECTIVE_CLAUSE_MAP
-
-{
- {llvm::omp::Directive::OMPD_allocate,
- {
- llvm::omp::allowedClauses_OMPD_allocate,
- llvm::omp::allowedOnceClauses_OMPD_allocate,
- llvm::omp::allowedExclusiveClauses_OMPD_allocate,
- llvm::omp::requiredClauses_OMPD_allocate,
- }
- },
- {llvm::omp::Directive::OMPD_assumes,
- {
- llvm::omp::allowedClauses_OMPD_assumes,
- llvm::omp::allowedOnceClauses_OMPD_assumes,
- llvm::omp::allowedExclusiveClauses_OMPD_assumes,
- llvm::omp::requiredClauses_OMPD_assumes,
- }
- },
- {llvm::omp::Directive::OMPD_atomic,
- {
- llvm::omp::allowedClauses_OMPD_atomic,
- llvm::omp::allowedOnceClauses_OMPD_atomic,
- llvm::omp::allowedExclusiveClauses_OMPD_atomic,
- llvm::omp::requiredClauses_OMPD_atomic,
- }
- },
- {llvm::omp::Directive::OMPD_barrier,
- {
- llvm::omp::allowedClauses_OMPD_barrier,
- llvm::omp::allowedOnceClauses_OMPD_barrier,
- llvm::omp::allowedExclusiveClauses_OMPD_barrier,
- llvm::omp::requiredClauses_OMPD_barrier,
- }
- },
- {llvm::omp::Directive::OMPD_begin_assumes,
- {
- llvm::omp::allowedClauses_OMPD_begin_assumes,
- llvm::omp::allowedOnceClauses_OMPD_begin_assumes,
- llvm::omp::allowedExclusiveClauses_OMPD_begin_assumes,
- llvm::omp::requiredClauses_OMPD_begin_assumes,
- }
- },
- {llvm::omp::Directive::OMPD_begin_declare_variant,
- {
- llvm::omp::allowedClauses_OMPD_begin_declare_variant,
- llvm::omp::allowedOnceClauses_OMPD_begin_declare_variant,
- llvm::omp::allowedExclusiveClauses_OMPD_begin_declare_variant,
- llvm::omp::requiredClauses_OMPD_begin_declare_variant,
- }
- },
- {llvm::omp::Directive::OMPD_cancel,
- {
- llvm::omp::allowedClauses_OMPD_cancel,
- llvm::omp::allowedOnceClauses_OMPD_cancel,
- llvm::omp::allowedExclusiveClauses_OMPD_cancel,
- llvm::omp::requiredClauses_OMPD_cancel,
- }
- },
- {llvm::omp::Directive::OMPD_cancellation_point,
- {
- llvm::omp::allowedClauses_OMPD_cancellation_point,
- llvm::omp::allowedOnceClauses_OMPD_cancellation_point,
- llvm::omp::allowedExclusiveClauses_OMPD_cancellation_point,
- llvm::omp::requiredClauses_OMPD_cancellation_point,
- }
- },
- {llvm::omp::Directive::OMPD_critical,
- {
- llvm::omp::allowedClauses_OMPD_critical,
- llvm::omp::allowedOnceClauses_OMPD_critical,
- llvm::omp::allowedExclusiveClauses_OMPD_critical,
- llvm::omp::requiredClauses_OMPD_critical,
- }
- },
- {llvm::omp::Directive::OMPD_declare_mapper,
- {
- llvm::omp::allowedClauses_OMPD_declare_mapper,
- llvm::omp::allowedOnceClauses_OMPD_declare_mapper,
- llvm::omp::allowedExclusiveClauses_OMPD_declare_mapper,
- llvm::omp::requiredClauses_OMPD_declare_mapper,
- }
- },
- {llvm::omp::Directive::OMPD_declare_reduction,
- {
- llvm::omp::allowedClauses_OMPD_declare_reduction,
- llvm::omp::allowedOnceClauses_OMPD_declare_reduction,
- llvm::omp::allowedExclusiveClauses_OMPD_declare_reduction,
- llvm::omp::requiredClauses_OMPD_declare_reduction,
- }
- },
- {llvm::omp::Directive::OMPD_declare_simd,
- {
- llvm::omp::allowedClauses_OMPD_declare_simd,
- llvm::omp::allowedOnceClauses_OMPD_declare_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_declare_simd,
- llvm::omp::requiredClauses_OMPD_declare_simd,
- }
- },
- {llvm::omp::Directive::OMPD_declare_target,
- {
- llvm::omp::allowedClauses_OMPD_declare_target,
- llvm::omp::allowedOnceClauses_OMPD_declare_target,
- llvm::omp::allowedExclusiveClauses_OMPD_declare_target,
- llvm::omp::requiredClauses_OMPD_declare_target,
- }
- },
- {llvm::omp::Directive::OMPD_declare_variant,
- {
- llvm::omp::allowedClauses_OMPD_declare_variant,
- llvm::omp::allowedOnceClauses_OMPD_declare_variant,
- llvm::omp::allowedExclusiveClauses_OMPD_declare_variant,
- llvm::omp::requiredClauses_OMPD_declare_variant,
- }
- },
- {llvm::omp::Directive::OMPD_depobj,
- {
- llvm::omp::allowedClauses_OMPD_depobj,
- llvm::omp::allowedOnceClauses_OMPD_depobj,
- llvm::omp::allowedExclusiveClauses_OMPD_depobj,
- llvm::omp::requiredClauses_OMPD_depobj,
- }
- },
- {llvm::omp::Directive::OMPD_distribute,
- {
- llvm::omp::allowedClauses_OMPD_distribute,
- llvm::omp::allowedOnceClauses_OMPD_distribute,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute,
- llvm::omp::requiredClauses_OMPD_distribute,
- }
- },
- {llvm::omp::Directive::OMPD_distribute_parallel_do,
- {
- llvm::omp::allowedClauses_OMPD_distribute_parallel_do,
- llvm::omp::allowedOnceClauses_OMPD_distribute_parallel_do,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute_parallel_do,
- llvm::omp::requiredClauses_OMPD_distribute_parallel_do,
- }
- },
- {llvm::omp::Directive::OMPD_distribute_parallel_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_distribute_parallel_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_distribute_parallel_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute_parallel_do_simd,
- llvm::omp::requiredClauses_OMPD_distribute_parallel_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_distribute_parallel_for,
- {
- llvm::omp::allowedClauses_OMPD_distribute_parallel_for,
- llvm::omp::allowedOnceClauses_OMPD_distribute_parallel_for,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute_parallel_for,
- llvm::omp::requiredClauses_OMPD_distribute_parallel_for,
- }
- },
- {llvm::omp::Directive::OMPD_distribute_parallel_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_distribute_parallel_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_distribute_parallel_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute_parallel_for_simd,
- llvm::omp::requiredClauses_OMPD_distribute_parallel_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_distribute_simd,
- {
- llvm::omp::allowedClauses_OMPD_distribute_simd,
- llvm::omp::allowedOnceClauses_OMPD_distribute_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_distribute_simd,
- llvm::omp::requiredClauses_OMPD_distribute_simd,
- }
- },
- {llvm::omp::Directive::OMPD_do,
- {
- llvm::omp::allowedClauses_OMPD_do,
- llvm::omp::allowedOnceClauses_OMPD_do,
- llvm::omp::allowedExclusiveClauses_OMPD_do,
- llvm::omp::requiredClauses_OMPD_do,
- }
- },
- {llvm::omp::Directive::OMPD_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_do_simd,
- llvm::omp::requiredClauses_OMPD_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_end_assumes,
- {
- llvm::omp::allowedClauses_OMPD_end_assumes,
- llvm::omp::allowedOnceClauses_OMPD_end_assumes,
- llvm::omp::allowedExclusiveClauses_OMPD_end_assumes,
- llvm::omp::requiredClauses_OMPD_end_assumes,
- }
- },
- {llvm::omp::Directive::OMPD_end_declare_target,
- {
- llvm::omp::allowedClauses_OMPD_end_declare_target,
- llvm::omp::allowedOnceClauses_OMPD_end_declare_target,
- llvm::omp::allowedExclusiveClauses_OMPD_end_declare_target,
- llvm::omp::requiredClauses_OMPD_end_declare_target,
- }
- },
- {llvm::omp::Directive::OMPD_end_declare_variant,
- {
- llvm::omp::allowedClauses_OMPD_end_declare_variant,
- llvm::omp::allowedOnceClauses_OMPD_end_declare_variant,
- llvm::omp::allowedExclusiveClauses_OMPD_end_declare_variant,
- llvm::omp::requiredClauses_OMPD_end_declare_variant,
- }
- },
- {llvm::omp::Directive::OMPD_end_do,
- {
- llvm::omp::allowedClauses_OMPD_end_do,
- llvm::omp::allowedOnceClauses_OMPD_end_do,
- llvm::omp::allowedExclusiveClauses_OMPD_end_do,
- llvm::omp::requiredClauses_OMPD_end_do,
- }
- },
- {llvm::omp::Directive::OMPD_end_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_end_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_end_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_end_do_simd,
- llvm::omp::requiredClauses_OMPD_end_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_end_sections,
- {
- llvm::omp::allowedClauses_OMPD_end_sections,
- llvm::omp::allowedOnceClauses_OMPD_end_sections,
- llvm::omp::allowedExclusiveClauses_OMPD_end_sections,
- llvm::omp::requiredClauses_OMPD_end_sections,
- }
- },
- {llvm::omp::Directive::OMPD_end_single,
- {
- llvm::omp::allowedClauses_OMPD_end_single,
- llvm::omp::allowedOnceClauses_OMPD_end_single,
- llvm::omp::allowedExclusiveClauses_OMPD_end_single,
- llvm::omp::requiredClauses_OMPD_end_single,
- }
- },
- {llvm::omp::Directive::OMPD_end_workshare,
- {
- llvm::omp::allowedClauses_OMPD_end_workshare,
- llvm::omp::allowedOnceClauses_OMPD_end_workshare,
- llvm::omp::allowedExclusiveClauses_OMPD_end_workshare,
- llvm::omp::requiredClauses_OMPD_end_workshare,
- }
- },
- {llvm::omp::Directive::OMPD_flush,
- {
- llvm::omp::allowedClauses_OMPD_flush,
- llvm::omp::allowedOnceClauses_OMPD_flush,
- llvm::omp::allowedExclusiveClauses_OMPD_flush,
- llvm::omp::requiredClauses_OMPD_flush,
- }
- },
- {llvm::omp::Directive::OMPD_for,
- {
- llvm::omp::allowedClauses_OMPD_for,
- llvm::omp::allowedOnceClauses_OMPD_for,
- llvm::omp::allowedExclusiveClauses_OMPD_for,
- llvm::omp::requiredClauses_OMPD_for,
- }
- },
- {llvm::omp::Directive::OMPD_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_for_simd,
- llvm::omp::requiredClauses_OMPD_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_master,
- {
- llvm::omp::allowedClauses_OMPD_master,
- llvm::omp::allowedOnceClauses_OMPD_master,
- llvm::omp::allowedExclusiveClauses_OMPD_master,
- llvm::omp::requiredClauses_OMPD_master,
- }
- },
- {llvm::omp::Directive::OMPD_master_taskloop,
- {
- llvm::omp::allowedClauses_OMPD_master_taskloop,
- llvm::omp::allowedOnceClauses_OMPD_master_taskloop,
- llvm::omp::allowedExclusiveClauses_OMPD_master_taskloop,
- llvm::omp::requiredClauses_OMPD_master_taskloop,
- }
- },
- {llvm::omp::Directive::OMPD_master_taskloop_simd,
- {
- llvm::omp::allowedClauses_OMPD_master_taskloop_simd,
- llvm::omp::allowedOnceClauses_OMPD_master_taskloop_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_master_taskloop_simd,
- llvm::omp::requiredClauses_OMPD_master_taskloop_simd,
- }
- },
- {llvm::omp::Directive::OMPD_ordered,
- {
- llvm::omp::allowedClauses_OMPD_ordered,
- llvm::omp::allowedOnceClauses_OMPD_ordered,
- llvm::omp::allowedExclusiveClauses_OMPD_ordered,
- llvm::omp::requiredClauses_OMPD_ordered,
- }
- },
- {llvm::omp::Directive::OMPD_parallel,
- {
- llvm::omp::allowedClauses_OMPD_parallel,
- llvm::omp::allowedOnceClauses_OMPD_parallel,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel,
- llvm::omp::requiredClauses_OMPD_parallel,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_do,
- {
- llvm::omp::allowedClauses_OMPD_parallel_do,
- llvm::omp::allowedOnceClauses_OMPD_parallel_do,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_do,
- llvm::omp::requiredClauses_OMPD_parallel_do,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_parallel_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_parallel_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_do_simd,
- llvm::omp::requiredClauses_OMPD_parallel_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_for,
- {
- llvm::omp::allowedClauses_OMPD_parallel_for,
- llvm::omp::allowedOnceClauses_OMPD_parallel_for,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_for,
- llvm::omp::requiredClauses_OMPD_parallel_for,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_parallel_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_parallel_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_for_simd,
- llvm::omp::requiredClauses_OMPD_parallel_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_master,
- {
- llvm::omp::allowedClauses_OMPD_parallel_master,
- llvm::omp::allowedOnceClauses_OMPD_parallel_master,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_master,
- llvm::omp::requiredClauses_OMPD_parallel_master,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_master_taskloop,
- {
- llvm::omp::allowedClauses_OMPD_parallel_master_taskloop,
- llvm::omp::allowedOnceClauses_OMPD_parallel_master_taskloop,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_master_taskloop,
- llvm::omp::requiredClauses_OMPD_parallel_master_taskloop,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_master_taskloop_simd,
- {
- llvm::omp::allowedClauses_OMPD_parallel_master_taskloop_simd,
- llvm::omp::allowedOnceClauses_OMPD_parallel_master_taskloop_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_master_taskloop_simd,
- llvm::omp::requiredClauses_OMPD_parallel_master_taskloop_simd,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_sections,
- {
- llvm::omp::allowedClauses_OMPD_parallel_sections,
- llvm::omp::allowedOnceClauses_OMPD_parallel_sections,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_sections,
- llvm::omp::requiredClauses_OMPD_parallel_sections,
- }
- },
- {llvm::omp::Directive::OMPD_parallel_workshare,
- {
- llvm::omp::allowedClauses_OMPD_parallel_workshare,
- llvm::omp::allowedOnceClauses_OMPD_parallel_workshare,
- llvm::omp::allowedExclusiveClauses_OMPD_parallel_workshare,
- llvm::omp::requiredClauses_OMPD_parallel_workshare,
- }
- },
- {llvm::omp::Directive::OMPD_requires,
- {
- llvm::omp::allowedClauses_OMPD_requires,
- llvm::omp::allowedOnceClauses_OMPD_requires,
- llvm::omp::allowedExclusiveClauses_OMPD_requires,
- llvm::omp::requiredClauses_OMPD_requires,
- }
- },
- {llvm::omp::Directive::OMPD_scan,
- {
- llvm::omp::allowedClauses_OMPD_scan,
- llvm::omp::allowedOnceClauses_OMPD_scan,
- llvm::omp::allowedExclusiveClauses_OMPD_scan,
- llvm::omp::requiredClauses_OMPD_scan,
- }
- },
- {llvm::omp::Directive::OMPD_section,
- {
- llvm::omp::allowedClauses_OMPD_section,
- llvm::omp::allowedOnceClauses_OMPD_section,
- llvm::omp::allowedExclusiveClauses_OMPD_section,
- llvm::omp::requiredClauses_OMPD_section,
- }
- },
- {llvm::omp::Directive::OMPD_sections,
- {
- llvm::omp::allowedClauses_OMPD_sections,
- llvm::omp::allowedOnceClauses_OMPD_sections,
- llvm::omp::allowedExclusiveClauses_OMPD_sections,
- llvm::omp::requiredClauses_OMPD_sections,
- }
- },
- {llvm::omp::Directive::OMPD_simd,
- {
- llvm::omp::allowedClauses_OMPD_simd,
- llvm::omp::allowedOnceClauses_OMPD_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_simd,
- llvm::omp::requiredClauses_OMPD_simd,
- }
- },
- {llvm::omp::Directive::OMPD_single,
- {
- llvm::omp::allowedClauses_OMPD_single,
- llvm::omp::allowedOnceClauses_OMPD_single,
- llvm::omp::allowedExclusiveClauses_OMPD_single,
- llvm::omp::requiredClauses_OMPD_single,
- }
- },
- {llvm::omp::Directive::OMPD_target,
- {
- llvm::omp::allowedClauses_OMPD_target,
- llvm::omp::allowedOnceClauses_OMPD_target,
- llvm::omp::allowedExclusiveClauses_OMPD_target,
- llvm::omp::requiredClauses_OMPD_target,
- }
- },
- {llvm::omp::Directive::OMPD_target_data,
- {
- llvm::omp::allowedClauses_OMPD_target_data,
- llvm::omp::allowedOnceClauses_OMPD_target_data,
- llvm::omp::allowedExclusiveClauses_OMPD_target_data,
- llvm::omp::requiredClauses_OMPD_target_data,
- }
- },
- {llvm::omp::Directive::OMPD_target_enter_data,
- {
- llvm::omp::allowedClauses_OMPD_target_enter_data,
- llvm::omp::allowedOnceClauses_OMPD_target_enter_data,
- llvm::omp::allowedExclusiveClauses_OMPD_target_enter_data,
- llvm::omp::requiredClauses_OMPD_target_enter_data,
- }
- },
- {llvm::omp::Directive::OMPD_target_exit_data,
- {
- llvm::omp::allowedClauses_OMPD_target_exit_data,
- llvm::omp::allowedOnceClauses_OMPD_target_exit_data,
- llvm::omp::allowedExclusiveClauses_OMPD_target_exit_data,
- llvm::omp::requiredClauses_OMPD_target_exit_data,
- }
- },
- {llvm::omp::Directive::OMPD_target_parallel,
- {
- llvm::omp::allowedClauses_OMPD_target_parallel,
- llvm::omp::allowedOnceClauses_OMPD_target_parallel,
- llvm::omp::allowedExclusiveClauses_OMPD_target_parallel,
- llvm::omp::requiredClauses_OMPD_target_parallel,
- }
- },
- {llvm::omp::Directive::OMPD_target_parallel_do,
- {
- llvm::omp::allowedClauses_OMPD_target_parallel_do,
- llvm::omp::allowedOnceClauses_OMPD_target_parallel_do,
- llvm::omp::allowedExclusiveClauses_OMPD_target_parallel_do,
- llvm::omp::requiredClauses_OMPD_target_parallel_do,
- }
- },
- {llvm::omp::Directive::OMPD_target_parallel_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_parallel_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_parallel_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_parallel_do_simd,
- llvm::omp::requiredClauses_OMPD_target_parallel_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_parallel_for,
- {
- llvm::omp::allowedClauses_OMPD_target_parallel_for,
- llvm::omp::allowedOnceClauses_OMPD_target_parallel_for,
- llvm::omp::allowedExclusiveClauses_OMPD_target_parallel_for,
- llvm::omp::requiredClauses_OMPD_target_parallel_for,
- }
- },
- {llvm::omp::Directive::OMPD_target_parallel_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_parallel_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_parallel_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_parallel_for_simd,
- llvm::omp::requiredClauses_OMPD_target_parallel_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_simd,
- llvm::omp::requiredClauses_OMPD_target_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams,
- {
- llvm::omp::allowedClauses_OMPD_target_teams,
- llvm::omp::allowedOnceClauses_OMPD_target_teams,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams,
- llvm::omp::requiredClauses_OMPD_target_teams,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute_parallel_do,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute_parallel_do,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute_parallel_do,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_do,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute_parallel_do,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute_parallel_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute_parallel_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute_parallel_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_do_simd,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute_parallel_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute_parallel_for,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute_parallel_for,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute_parallel_for,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_for,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute_parallel_for,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute_parallel_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute_parallel_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute_parallel_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute_parallel_for_simd,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute_parallel_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_teams_distribute_simd,
- {
- llvm::omp::allowedClauses_OMPD_target_teams_distribute_simd,
- llvm::omp::allowedOnceClauses_OMPD_target_teams_distribute_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_target_teams_distribute_simd,
- llvm::omp::requiredClauses_OMPD_target_teams_distribute_simd,
- }
- },
- {llvm::omp::Directive::OMPD_target_update,
- {
- llvm::omp::allowedClauses_OMPD_target_update,
- llvm::omp::allowedOnceClauses_OMPD_target_update,
- llvm::omp::allowedExclusiveClauses_OMPD_target_update,
- llvm::omp::requiredClauses_OMPD_target_update,
- }
- },
- {llvm::omp::Directive::OMPD_task,
- {
- llvm::omp::allowedClauses_OMPD_task,
- llvm::omp::allowedOnceClauses_OMPD_task,
- llvm::omp::allowedExclusiveClauses_OMPD_task,
- llvm::omp::requiredClauses_OMPD_task,
- }
- },
- {llvm::omp::Directive::OMPD_taskgroup,
- {
- llvm::omp::allowedClauses_OMPD_taskgroup,
- llvm::omp::allowedOnceClauses_OMPD_taskgroup,
- llvm::omp::allowedExclusiveClauses_OMPD_taskgroup,
- llvm::omp::requiredClauses_OMPD_taskgroup,
- }
- },
- {llvm::omp::Directive::OMPD_taskloop,
- {
- llvm::omp::allowedClauses_OMPD_taskloop,
- llvm::omp::allowedOnceClauses_OMPD_taskloop,
- llvm::omp::allowedExclusiveClauses_OMPD_taskloop,
- llvm::omp::requiredClauses_OMPD_taskloop,
- }
- },
- {llvm::omp::Directive::OMPD_taskloop_simd,
- {
- llvm::omp::allowedClauses_OMPD_taskloop_simd,
- llvm::omp::allowedOnceClauses_OMPD_taskloop_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_taskloop_simd,
- llvm::omp::requiredClauses_OMPD_taskloop_simd,
- }
- },
- {llvm::omp::Directive::OMPD_taskwait,
- {
- llvm::omp::allowedClauses_OMPD_taskwait,
- llvm::omp::allowedOnceClauses_OMPD_taskwait,
- llvm::omp::allowedExclusiveClauses_OMPD_taskwait,
- llvm::omp::requiredClauses_OMPD_taskwait,
- }
- },
- {llvm::omp::Directive::OMPD_taskyield,
- {
- llvm::omp::allowedClauses_OMPD_taskyield,
- llvm::omp::allowedOnceClauses_OMPD_taskyield,
- llvm::omp::allowedExclusiveClauses_OMPD_taskyield,
- llvm::omp::requiredClauses_OMPD_taskyield,
- }
- },
- {llvm::omp::Directive::OMPD_teams,
- {
- llvm::omp::allowedClauses_OMPD_teams,
- llvm::omp::allowedOnceClauses_OMPD_teams,
- llvm::omp::allowedExclusiveClauses_OMPD_teams,
- llvm::omp::requiredClauses_OMPD_teams,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute,
- llvm::omp::requiredClauses_OMPD_teams_distribute,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute_parallel_do,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute_parallel_do,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute_parallel_do,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute_parallel_do,
- llvm::omp::requiredClauses_OMPD_teams_distribute_parallel_do,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute_parallel_do_simd,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute_parallel_do_simd,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute_parallel_do_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute_parallel_do_simd,
- llvm::omp::requiredClauses_OMPD_teams_distribute_parallel_do_simd,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute_parallel_for,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute_parallel_for,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute_parallel_for,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute_parallel_for,
- llvm::omp::requiredClauses_OMPD_teams_distribute_parallel_for,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute_parallel_for_simd,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute_parallel_for_simd,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute_parallel_for_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute_parallel_for_simd,
- llvm::omp::requiredClauses_OMPD_teams_distribute_parallel_for_simd,
- }
- },
- {llvm::omp::Directive::OMPD_teams_distribute_simd,
- {
- llvm::omp::allowedClauses_OMPD_teams_distribute_simd,
- llvm::omp::allowedOnceClauses_OMPD_teams_distribute_simd,
- llvm::omp::allowedExclusiveClauses_OMPD_teams_distribute_simd,
- llvm::omp::requiredClauses_OMPD_teams_distribute_simd,
- }
- },
- {llvm::omp::Directive::OMPD_threadprivate,
- {
- llvm::omp::allowedClauses_OMPD_threadprivate,
- llvm::omp::allowedOnceClauses_OMPD_threadprivate,
- llvm::omp::allowedExclusiveClauses_OMPD_threadprivate,
- llvm::omp::requiredClauses_OMPD_threadprivate,
- }
- },
- {llvm::omp::Directive::OMPD_unknown,
- {
- llvm::omp::allowedClauses_OMPD_unknown,
- llvm::omp::allowedOnceClauses_OMPD_unknown,
- llvm::omp::allowedExclusiveClauses_OMPD_unknown,
- llvm::omp::requiredClauses_OMPD_unknown,
- }
- },
- {llvm::omp::Directive::OMPD_workshare,
- {
- llvm::omp::allowedClauses_OMPD_workshare,
- llvm::omp::allowedOnceClauses_OMPD_workshare,
- llvm::omp::allowedExclusiveClauses_OMPD_workshare,
- llvm::omp::requiredClauses_OMPD_workshare,
- }
- },
-}
-
-#endif // GEN_FLANG_DIRECTIVE_CLAUSE_MAP
-
-#ifdef GEN_FLANG_CLAUSE_PARSER_CLASSES
-#undef GEN_FLANG_CLAUSE_PARSER_CLASSES
-
-EMPTY_CLASS(AcqRel);
-EMPTY_CLASS(Acquire);
-EMPTY_CLASS(Affinity);
-WRAPPER_CLASS(Aligned, OmpAlignedClause);
-WRAPPER_CLASS(Allocate, OmpAllocateClause);
-WRAPPER_CLASS(Allocator, ScalarIntExpr);
-EMPTY_CLASS(AtomicDefaultMemOrder);
-EMPTY_CLASS(Capture);
-WRAPPER_CLASS(Collapse, ScalarIntConstantExpr);
-WRAPPER_CLASS(Copyprivate, OmpObjectList);
-WRAPPER_CLASS(Copyin, OmpObjectList);
-WRAPPER_CLASS(Default, OmpDefaultClause);
-WRAPPER_CLASS(Defaultmap, OmpDefaultmapClause);
-WRAPPER_CLASS(Depend, OmpDependClause);
-EMPTY_CLASS(Depobj);
-EMPTY_CLASS(Destroy);
-EMPTY_CLASS(Detach);
-WRAPPER_CLASS(Device, ScalarIntExpr);
-EMPTY_CLASS(DeviceType);
-WRAPPER_CLASS(DistSchedule, std::optional<ScalarIntExpr>);
-EMPTY_CLASS(DynamicAllocators);
-EMPTY_CLASS(Exclusive);
-WRAPPER_CLASS(Final, ScalarLogicalExpr);
-WRAPPER_CLASS(Firstprivate, OmpObjectList);
-EMPTY_CLASS(Flush);
-WRAPPER_CLASS(From, OmpObjectList);
-WRAPPER_CLASS(Grainsize, ScalarIntExpr);
-WRAPPER_CLASS(Hint, ConstantExpr);
-WRAPPER_CLASS(If, OmpIfClause);
-EMPTY_CLASS(InReduction);
-EMPTY_CLASS(Inbranch);
-EMPTY_CLASS(Inclusive);
-WRAPPER_CLASS(IsDevicePtr, std::list<Name>);
-WRAPPER_CLASS(Lastprivate, OmpObjectList);
-WRAPPER_CLASS(Linear, OmpLinearClause);
-WRAPPER_CLASS(Link, OmpObjectList);
-WRAPPER_CLASS(Map, OmpMapClause);
-EMPTY_CLASS(Match);
-EMPTY_CLASS(Mergeable);
-EMPTY_CLASS(Nogroup);
-EMPTY_CLASS(Nowait);
-EMPTY_CLASS(Nontemporal);
-EMPTY_CLASS(Notinbranch);
-WRAPPER_CLASS(NumTasks, ScalarIntExpr);
-WRAPPER_CLASS(NumTeams, ScalarIntExpr);
-WRAPPER_CLASS(NumThreads, ScalarIntExpr);
-EMPTY_CLASS(Order);
-WRAPPER_CLASS(Ordered, std::optional<ScalarIntConstantExpr>);
-WRAPPER_CLASS(Priority, ScalarIntExpr);
-WRAPPER_CLASS(Private, OmpObjectList);
-WRAPPER_CLASS(ProcBind, OmpProcBindClause);
-EMPTY_CLASS(Read);
-WRAPPER_CLASS(Reduction, OmpReductionClause);
-EMPTY_CLASS(Relaxed);
-EMPTY_CLASS(Release);
-EMPTY_CLASS(ReverseOffload);
-WRAPPER_CLASS(Safelen, ScalarIntConstantExpr);
-WRAPPER_CLASS(Schedule, OmpScheduleClause);
-EMPTY_CLASS(SeqCst);
-WRAPPER_CLASS(Shared, OmpObjectList);
-EMPTY_CLASS(Simd);
-WRAPPER_CLASS(Simdlen, ScalarIntConstantExpr);
-WRAPPER_CLASS(TaskReduction, OmpReductionClause);
-WRAPPER_CLASS(ThreadLimit, ScalarIntExpr);
-EMPTY_CLASS(Threadprivate);
-EMPTY_CLASS(Threads);
-WRAPPER_CLASS(To, OmpObjectList);
-EMPTY_CLASS(UnifiedAddress);
-EMPTY_CLASS(UnifiedSharedMemory);
-WRAPPER_CLASS(Uniform, std::list<Name>);
-EMPTY_CLASS(Unknown);
-EMPTY_CLASS(Untied);
-EMPTY_CLASS(Update);
-EMPTY_CLASS(UseDeviceAddr);
-WRAPPER_CLASS(UseDevicePtr, std::list<Name>);
-EMPTY_CLASS(UsesAllocators);
-EMPTY_CLASS(Write);
-
-#endif // GEN_FLANG_CLAUSE_PARSER_CLASSES
-
-#ifdef GEN_FLANG_CLAUSE_PARSER_CLASSES_LIST
-#undef GEN_FLANG_CLAUSE_PARSER_CLASSES_LIST
-
-AcqRel
-, Acquire
-, Affinity
-, Aligned
-, Allocate
-, Allocator
-, AtomicDefaultMemOrder
-, Capture
-, Collapse
-, Copyprivate
-, Copyin
-, Default
-, Defaultmap
-, Depend
-, Depobj
-, Destroy
-, Detach
-, Device
-, DeviceType
-, DistSchedule
-, DynamicAllocators
-, Exclusive
-, Final
-, Firstprivate
-, Flush
-, From
-, Grainsize
-, Hint
-, If
-, InReduction
-, Inbranch
-, Inclusive
-, IsDevicePtr
-, Lastprivate
-, Linear
-, Link
-, Map
-, Match
-, Mergeable
-, Nogroup
-, Nowait
-, Nontemporal
-, Notinbranch
-, NumTasks
-, NumTeams
-, NumThreads
-, Order
-, Ordered
-, Priority
-, Private
-, ProcBind
-, Read
-, Reduction
-, Relaxed
-, Release
-, ReverseOffload
-, Safelen
-, Schedule
-, SeqCst
-, Shared
-, Simd
-, Simdlen
-, TaskReduction
-, ThreadLimit
-, Threadprivate
-, Threads
-, To
-, UnifiedAddress
-, UnifiedSharedMemory
-, Uniform
-, Unknown
-, Untied
-, Update
-, UseDeviceAddr
-, UseDevicePtr
-, UsesAllocators
-, Write
-
-#endif // GEN_FLANG_CLAUSE_PARSER_CLASSES_LIST
-
-#ifdef GEN_FLANG_DUMP_PARSE_TREE_CLAUSES
-#undef GEN_FLANG_DUMP_PARSE_TREE_CLAUSES
-
-NODE(OmpClause, AcqRel)
-NODE(OmpClause, Acquire)
-NODE(OmpClause, Affinity)
-NODE(OmpClause, Aligned)
-NODE(OmpClause, Allocate)
-NODE(OmpClause, Allocator)
-NODE(OmpClause, AtomicDefaultMemOrder)
-NODE(OmpClause, Capture)
-NODE(OmpClause, Collapse)
-NODE(OmpClause, Copyprivate)
-NODE(OmpClause, Copyin)
-NODE(OmpClause, Default)
-NODE(OmpClause, Defaultmap)
-NODE(OmpClause, Depend)
-NODE(OmpClause, Depobj)
-NODE(OmpClause, Destroy)
-NODE(OmpClause, Detach)
-NODE(OmpClause, Device)
-NODE(OmpClause, DeviceType)
-NODE(OmpClause, DistSchedule)
-NODE(OmpClause, DynamicAllocators)
-NODE(OmpClause, Exclusive)
-NODE(OmpClause, Final)
-NODE(OmpClause, Firstprivate)
-NODE(OmpClause, Flush)
-NODE(OmpClause, From)
-NODE(OmpClause, Grainsize)
-NODE(OmpClause, Hint)
-NODE(OmpClause, If)
-NODE(OmpClause, InReduction)
-NODE(OmpClause, Inbranch)
-NODE(OmpClause, Inclusive)
-NODE(OmpClause, IsDevicePtr)
-NODE(OmpClause, Lastprivate)
-NODE(OmpClause, Linear)
-NODE(OmpClause, Link)
-NODE(OmpClause, Map)
-NODE(OmpClause, Match)
-NODE(OmpClause, Mergeable)
-NODE(OmpClause, Nogroup)
-NODE(OmpClause, Nowait)
-NODE(OmpClause, Nontemporal)
-NODE(OmpClause, Notinbranch)
-NODE(OmpClause, NumTasks)
-NODE(OmpClause, NumTeams)
-NODE(OmpClause, NumThreads)
-NODE(OmpClause, Order)
-NODE(OmpClause, Ordered)
-NODE(OmpClause, Priority)
-NODE(OmpClause, Private)
-NODE(OmpClause, ProcBind)
-NODE(OmpClause, Read)
-NODE(OmpClause, Reduction)
-NODE(OmpClause, Relaxed)
-NODE(OmpClause, Release)
-NODE(OmpClause, ReverseOffload)
-NODE(OmpClause, Safelen)
-NODE(OmpClause, Schedule)
-NODE(OmpClause, SeqCst)
-NODE(OmpClause, Shared)
-NODE(OmpClause, Simd)
-NODE(OmpClause, Simdlen)
-NODE(OmpClause, TaskReduction)
-NODE(OmpClause, ThreadLimit)
-NODE(OmpClause, Threadprivate)
-NODE(OmpClause, Threads)
-NODE(OmpClause, To)
-NODE(OmpClause, UnifiedAddress)
-NODE(OmpClause, UnifiedSharedMemory)
-NODE(OmpClause, Uniform)
-NODE(OmpClause, Unknown)
-NODE(OmpClause, Untied)
-NODE(OmpClause, Update)
-NODE(OmpClause, UseDeviceAddr)
-NODE(OmpClause, UseDevicePtr)
-NODE(OmpClause, UsesAllocators)
-NODE(OmpClause, Write)
-
-#endif // GEN_FLANG_DUMP_PARSE_TREE_CLAUSES
-
-#ifdef GEN_FLANG_CLAUSE_UNPARSE
-#undef GEN_FLANG_CLAUSE_UNPARSE
-
-void Before(const OmpClause::AcqRel &) { Word("ACQ_REL"); }
-void Before(const OmpClause::Acquire &) { Word("ACQUIRE"); }
-void Before(const OmpClause::Affinity &) { Word("AFFINITY"); }
-void Unparse(const OmpClause::Aligned &x) {
- Word("ALIGNED");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Allocate &x) {
- Word("ALLOCATE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Allocator &x) {
- Word("ALLOCATOR");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::AtomicDefaultMemOrder &) { Word("ATOMIC_DEFAULT_MEM_ORDER"); }
-void Before(const OmpClause::Capture &) { Word("CAPTURE"); }
-void Unparse(const OmpClause::Collapse &x) {
- Word("COLLAPSE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Copyprivate &x) {
- Word("COPYPRIVATE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Copyin &x) {
- Word("COPYIN");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Default &x) {
- Word("DEFAULT");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Defaultmap &x) {
- Word("DEFAULTMAP");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Depend &x) {
- Word("DEPEND");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Depobj &) { Word("DEPOBJ"); }
-void Before(const OmpClause::Destroy &) { Word("DESTROY"); }
-void Before(const OmpClause::Detach &) { Word("DETACH"); }
-void Unparse(const OmpClause::Device &x) {
- Word("DEVICE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::DeviceType &) { Word("DEVICE_TYPE"); }
-void Unparse(const OmpClause::DistSchedule &x) {
- Word("DIST_SCHEDULE");
- Walk("(", x.v, ")");
-}
-void Before(const OmpClause::DynamicAllocators &) { Word("DYNAMIC_ALLOCATORS"); }
-void Before(const OmpClause::Exclusive &) { Word("EXCLUSIVE"); }
-void Unparse(const OmpClause::Final &x) {
- Word("FINAL");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Firstprivate &x) {
- Word("FIRSTPRIVATE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Flush &) { Word("FLUSH"); }
-void Unparse(const OmpClause::From &x) {
- Word("FROM");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Grainsize &x) {
- Word("GRAINSIZE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Hint &x) {
- Word("HINT");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::If &x) {
- Word("IF");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::InReduction &) { Word("IN_REDUCTION"); }
-void Before(const OmpClause::Inbranch &) { Word("INBRANCH"); }
-void Before(const OmpClause::Inclusive &) { Word("INCLUSIVE"); }
-void Unparse(const OmpClause::IsDevicePtr &x) {
- Word("IS_DEVICE_PTR");
- Put("(");
- Walk(x.v, ",");
- Put(")");
-}
-void Unparse(const OmpClause::Lastprivate &x) {
- Word("LASTPRIVATE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Linear &x) {
- Word("LINEAR");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Link &x) {
- Word("LINK");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Map &x) {
- Word("MAP");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Match &) { Word("MATCH"); }
-void Before(const OmpClause::Mergeable &) { Word("MERGEABLE"); }
-void Before(const OmpClause::Nogroup &) { Word("NOGROUP"); }
-void Before(const OmpClause::Nowait &) { Word("NOWAIT"); }
-void Before(const OmpClause::Nontemporal &) { Word("NONTEMPORAL"); }
-void Before(const OmpClause::Notinbranch &) { Word("NOTINBRANCH"); }
-void Unparse(const OmpClause::NumTasks &x) {
- Word("NUM_TASKS");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::NumTeams &x) {
- Word("NUM_TEAMS");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::NumThreads &x) {
- Word("NUM_THREADS");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Order &) { Word("ORDER"); }
-void Unparse(const OmpClause::Ordered &x) {
- Word("ORDERED");
- Walk("(", x.v, ")");
-}
-void Unparse(const OmpClause::Priority &x) {
- Word("PRIORITY");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Private &x) {
- Word("PRIVATE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::ProcBind &x) {
- Word("PROC_BIND");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Read &) { Word("READ"); }
-void Unparse(const OmpClause::Reduction &x) {
- Word("REDUCTION");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Relaxed &) { Word("RELAXED"); }
-void Before(const OmpClause::Release &) { Word("RELEASE"); }
-void Before(const OmpClause::ReverseOffload &) { Word("REVERSE_OFFLOAD"); }
-void Unparse(const OmpClause::Safelen &x) {
- Word("SAFELEN");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::Schedule &x) {
- Word("SCHEDULE");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::SeqCst &) { Word("SEQ_CST"); }
-void Unparse(const OmpClause::Shared &x) {
- Word("SHARED");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Simd &) { Word("SIMD"); }
-void Unparse(const OmpClause::Simdlen &x) {
- Word("SIMDLEN");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::TaskReduction &x) {
- Word("TASK_REDUCTION");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Unparse(const OmpClause::ThreadLimit &x) {
- Word("THREAD_LIMIT");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::Threadprivate &) { Word("THREADPRIVATE"); }
-void Before(const OmpClause::Threads &) { Word("THREADS"); }
-void Unparse(const OmpClause::To &x) {
- Word("TO");
- Put("(");
- Walk(x.v);
- Put(")");
-}
-void Before(const OmpClause::UnifiedAddress &) { Word("UNIFIED_ADDRESS"); }
-void Before(const OmpClause::UnifiedSharedMemory &) { Word("UNIFIED_SHARED_MEMORY"); }
-void Unparse(const OmpClause::Uniform &x) {
- Word("UNIFORM");
- Put("(");
- Walk(x.v, ",");
- Put(")");
-}
-void Before(const OmpClause::Unknown &) { Word("UNKNOWN"); }
-void Before(const OmpClause::Untied &) { Word("UNTIED"); }
-void Before(const OmpClause::Update &) { Word("UPDATE"); }
-void Before(const OmpClause::UseDeviceAddr &) { Word("USE_DEVICE_ADDR"); }
-void Unparse(const OmpClause::UseDevicePtr &x) {
- Word("USE_DEVICE_PTR");
- Put("(");
- Walk(x.v, ",");
- Put(")");
-}
-void Before(const OmpClause::UsesAllocators &) { Word("USES_ALLOCATORS"); }
-void Before(const OmpClause::Write &) { Word("WRITE"); }
-
-#endif // GEN_FLANG_CLAUSE_UNPARSE
-
-#ifdef GEN_CLANG_CLAUSE_CLASS
-#undef GEN_CLANG_CLAUSE_CLASS
-
-#ifndef CLAUSE
-#define CLAUSE(Enum, Str, Implicit)
-#endif
-#ifndef CLAUSE_CLASS
-#define CLAUSE_CLASS(Enum, Str, Class)
-#endif
-#ifndef CLAUSE_NO_CLASS
-#define CLAUSE_NO_CLASS(Enum, Str)
-#endif
-
-#define __CLAUSE(Name, Class) \
- CLAUSE(OMPC_##Name, #Name, /* Implicit */ false) \
- CLAUSE_CLASS(OMPC_##Name, #Name, Class)
-#define __CLAUSE_NO_CLASS(Name) \
- CLAUSE(OMPC_##Name, #Name, /* Implicit */ false) \
- CLAUSE_NO_CLASS(OMPC_##Name, #Name)
-#define __IMPLICIT_CLAUSE_CLASS(Name, Str, Class) \
- CLAUSE(OMPC_##Name, Str, /* Implicit */ true) \
- CLAUSE_CLASS(OMPC_##Name, Str, Class)
-#define __IMPLICIT_CLAUSE_NO_CLASS(Name, Str) \
- CLAUSE(OMPC_##Name, Str, /* Implicit */ true) \
- CLAUSE_NO_CLASS(OMPC_##Name, Str)
-
-__CLAUSE(acq_rel, OMPAcqRelClause)
-__CLAUSE(acquire, OMPAcquireClause)
-__CLAUSE(affinity, OMPAffinityClause)
-__CLAUSE(aligned, OMPAlignedClause)
-__CLAUSE(allocate, OMPAllocateClause)
-__CLAUSE(allocator, OMPAllocatorClause)
-__CLAUSE(atomic_default_mem_order, OMPAtomicDefaultMemOrderClause)
-__CLAUSE(capture, OMPCaptureClause)
-__CLAUSE(collapse, OMPCollapseClause)
-__CLAUSE(copyprivate, OMPCopyprivateClause)
-__CLAUSE(copyin, OMPCopyinClause)
-__CLAUSE(default, OMPDefaultClause)
-__CLAUSE(defaultmap, OMPDefaultmapClause)
-__CLAUSE(depend, OMPDependClause)
-__IMPLICIT_CLAUSE_CLASS(depobj, "depobj", OMPDepobjClause)
-__CLAUSE(destroy, OMPDestroyClause)
-__CLAUSE(detach, OMPDetachClause)
-__CLAUSE(device, OMPDeviceClause)
-__CLAUSE_NO_CLASS(device_type)
-__CLAUSE(dist_schedule, OMPDistScheduleClause)
-__CLAUSE(dynamic_allocators, OMPDynamicAllocatorsClause)
-__CLAUSE(exclusive, OMPExclusiveClause)
-__CLAUSE(final, OMPFinalClause)
-__CLAUSE(firstprivate, OMPFirstprivateClause)
-__IMPLICIT_CLAUSE_CLASS(flush, "flush", OMPFlushClause)
-__CLAUSE(from, OMPFromClause)
-__CLAUSE(grainsize, OMPGrainsizeClause)
-__CLAUSE(hint, OMPHintClause)
-__CLAUSE(if, OMPIfClause)
-__CLAUSE(in_reduction, OMPInReductionClause)
-__CLAUSE_NO_CLASS(inbranch)
-__CLAUSE(inclusive, OMPInclusiveClause)
-__CLAUSE(is_device_ptr, OMPIsDevicePtrClause)
-__CLAUSE(lastprivate, OMPLastprivateClause)
-__CLAUSE(linear, OMPLinearClause)
-__CLAUSE_NO_CLASS(link)
-__CLAUSE(map, OMPMapClause)
-__CLAUSE_NO_CLASS(match)
-__CLAUSE(mergeable, OMPMergeableClause)
-__CLAUSE(nogroup, OMPNogroupClause)
-__CLAUSE(nowait, OMPNowaitClause)
-__CLAUSE(nontemporal, OMPNontemporalClause)
-__CLAUSE_NO_CLASS(notinbranch)
-__CLAUSE(num_tasks, OMPNumTasksClause)
-__CLAUSE(num_teams, OMPNumTeamsClause)
-__CLAUSE(num_threads, OMPNumThreadsClause)
-__CLAUSE(order, OMPOrderClause)
-__CLAUSE(ordered, OMPOrderedClause)
-__CLAUSE(priority, OMPPriorityClause)
-__CLAUSE(private, OMPPrivateClause)
-__CLAUSE(proc_bind, OMPProcBindClause)
-__CLAUSE(read, OMPReadClause)
-__CLAUSE(reduction, OMPReductionClause)
-__CLAUSE(relaxed, OMPRelaxedClause)
-__CLAUSE(release, OMPReleaseClause)
-__CLAUSE(reverse_offload, OMPReverseOffloadClause)
-__CLAUSE(safelen, OMPSafelenClause)
-__CLAUSE(schedule, OMPScheduleClause)
-__CLAUSE(seq_cst, OMPSeqCstClause)
-__CLAUSE(shared, OMPSharedClause)
-__CLAUSE(simd, OMPSIMDClause)
-__CLAUSE(simdlen, OMPSimdlenClause)
-__CLAUSE(task_reduction, OMPTaskReductionClause)
-__CLAUSE(thread_limit, OMPThreadLimitClause)
-__IMPLICIT_CLAUSE_NO_CLASS(threadprivate, "threadprivate")
-__CLAUSE(threads, OMPThreadsClause)
-__CLAUSE(to, OMPToClause)
-__CLAUSE(unified_address, OMPUnifiedAddressClause)
-__CLAUSE(unified_shared_memory, OMPUnifiedSharedMemoryClause)
-__CLAUSE_NO_CLASS(uniform)
-__IMPLICIT_CLAUSE_NO_CLASS(unknown, "unknown")
-__CLAUSE(untied, OMPUntiedClause)
-__CLAUSE(update, OMPUpdateClause)
-__CLAUSE(use_device_addr, OMPUseDeviceAddrClause)
-__CLAUSE(use_device_ptr, OMPUseDevicePtrClause)
-__CLAUSE(uses_allocators, OMPUsesAllocatorsClause)
-__CLAUSE(write, OMPWriteClause)
-
-#undef __IMPLICIT_CLAUSE_NO_CLASS
-#undef __IMPLICIT_CLAUSE_CLASS
-#undef __CLAUSE
-#undef CLAUSE_NO_CLASS
-#undef CLAUSE_CLASS
-#undef CLAUSE
-
-#endif // GEN_CLANG_CLAUSE_CLASS
-
diff --git a/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMPGridValues.h b/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMPGridValues.h
deleted file mode 100644
index da0c4d1f3fb..00000000000
--- a/contrib/libs/llvm12/include/llvm/Frontend/OpenMP/OMPGridValues.h
+++ /dev/null
@@ -1,142 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//====--- OMPGridValues.h - Language-specific address spaces --*- C++ -*-====//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-///
-/// \file
-/// \brief Provides definitions for Target specific Grid Values
-///
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_OPENMP_GRIDVALUES_H
-#define LLVM_OPENMP_GRIDVALUES_H
-
-namespace llvm {
-
-namespace omp {
-
-/// \brief Defines various target-specific GPU grid values that must be
-/// consistent between host RTL (plugin), device RTL, and clang.
-/// We can change grid values for a "fat" binary so that different
-/// passes get the correct values when generating code for a
-/// multi-target binary. Both amdgcn and nvptx values are stored in
-/// this file. In the future, should there be differences between GPUs
-/// of the same architecture, then simply make a different array and
-/// use the new array name.
-///
-/// Example usage in clang:
-/// const unsigned slot_size =
-/// ctx.GetTargetInfo().getGridValue(llvm::omp::GVIDX::GV_Warp_Size);
-///
-/// Example usage in libomptarget/deviceRTLs:
-/// #include "llvm/Frontend/OpenMP/OMPGridValues.h"
-/// #ifdef __AMDGPU__
-/// #define GRIDVAL AMDGPUGpuGridValues
-/// #else
-/// #define GRIDVAL NVPTXGpuGridValues
-/// #endif
-/// ... Then use this reference for GV_Warp_Size in the deviceRTL source.
-/// llvm::omp::GRIDVAL[llvm::omp::GVIDX::GV_Warp_Size]
-///
-/// Example usage in libomptarget hsa plugin:
-/// #include "llvm/Frontend/OpenMP/OMPGridValues.h"
-/// #define GRIDVAL AMDGPUGpuGridValues
-/// ... Then use this reference to access GV_Warp_Size in the hsa plugin.
-/// llvm::omp::GRIDVAL[llvm::omp::GVIDX::GV_Warp_Size]
-///
-/// Example usage in libomptarget cuda plugin:
-/// #include "llvm/Frontend/OpenMP/OMPGridValues.h"
-/// #define GRIDVAL NVPTXGpuGridValues
-/// ... Then use this reference to access GV_Warp_Size in the cuda plugin.
-/// llvm::omp::GRIDVAL[llvm::omp::GVIDX::GV_Warp_Size]
-///
-enum GVIDX {
- /// The maximum number of workers in a kernel.
- /// (THREAD_ABSOLUTE_LIMIT) - (GV_Warp_Size), might be issue for blockDim.z
- GV_Threads,
- /// The size reserved for data in a shared memory slot.
- GV_Slot_Size,
- /// The default value of maximum number of threads in a worker warp.
- GV_Warp_Size,
- /// Alternate warp size for some AMDGCN architectures. Same as GV_Warp_Size
- /// for NVPTX.
- GV_Warp_Size_32,
- /// The number of bits required to represent the max number of threads in warp
- GV_Warp_Size_Log2,
- /// GV_Warp_Size * GV_Slot_Size,
- GV_Warp_Slot_Size,
- /// the maximum number of teams.
- GV_Max_Teams,
- /// Global Memory Alignment
- GV_Mem_Align,
- /// (~0u >> (GV_Warp_Size - GV_Warp_Size_Log2))
- GV_Warp_Size_Log2_Mask,
- // An alternative to the heavy data sharing infrastructure that uses global
- // memory is one that uses device __shared__ memory. The amount of such space
- // (in bytes) reserved by the OpenMP runtime is noted here.
- GV_SimpleBufferSize,
- // The absolute maximum team size for a working group
- GV_Max_WG_Size,
- // The default maximum team size for a working group
- GV_Default_WG_Size,
- // This is GV_Max_WG_Size / GV_WarpSize. 32 for NVPTX and 16 for AMDGCN.
- GV_Max_Warp_Number,
- /// The slot size that should be reserved for a working warp.
- /// (~0u >> (GV_Warp_Size - GV_Warp_Size_Log2))
- GV_Warp_Size_Log2_MaskL
-};
-
-/// For AMDGPU GPUs
-static constexpr unsigned AMDGPUGpuGridValues[] = {
- 448, // GV_Threads
- 256, // GV_Slot_Size
- 64, // GV_Warp_Size
- 32, // GV_Warp_Size_32
- 6, // GV_Warp_Size_Log2
- 64 * 256, // GV_Warp_Slot_Size
- 128, // GV_Max_Teams
- 256, // GV_Mem_Align
- 63, // GV_Warp_Size_Log2_Mask
- 896, // GV_SimpleBufferSize
- 1024, // GV_Max_WG_Size,
- 256, // GV_Defaut_WG_Size
- 1024 / 64, // GV_Max_WG_Size / GV_WarpSize
- 63 // GV_Warp_Size_Log2_MaskL
-};
-
-/// For Nvidia GPUs
-static constexpr unsigned NVPTXGpuGridValues[] = {
- 992, // GV_Threads
- 256, // GV_Slot_Size
- 32, // GV_Warp_Size
- 32, // GV_Warp_Size_32
- 5, // GV_Warp_Size_Log2
- 32 * 256, // GV_Warp_Slot_Size
- 1024, // GV_Max_Teams
- 256, // GV_Mem_Align
- (~0u >> (32 - 5)), // GV_Warp_Size_Log2_Mask
- 896, // GV_SimpleBufferSize
- 1024, // GV_Max_WG_Size
- 128, // GV_Defaut_WG_Size
- 1024 / 32, // GV_Max_WG_Size / GV_WarpSize
- 31 // GV_Warp_Size_Log2_MaskL
-};
-
-} // namespace omp
-} // namespace llvm
-
-#endif // LLVM_OPENMP_GRIDVALUES_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/IR/FixedPointBuilder.h b/contrib/libs/llvm12/include/llvm/IR/FixedPointBuilder.h
deleted file mode 100644
index 1c4b0332d11..00000000000
--- a/contrib/libs/llvm12/include/llvm/IR/FixedPointBuilder.h
+++ /dev/null
@@ -1,476 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- llvm/FixedPointBuilder.h - Builder for fixed-point ops ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the FixedPointBuilder class, which is used as a convenient
-// way to lower fixed-point arithmetic operations to LLVM IR.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_IR_FIXEDPOINTBUILDER_H
-#define LLVM_IR_FIXEDPOINTBUILDER_H
-
-#include "llvm/ADT/APFixedPoint.h"
-#include "llvm/IR/Constant.h"
-#include "llvm/IR/Constants.h"
-#include "llvm/IR/IRBuilder.h"
-#include "llvm/IR/InstrTypes.h"
-#include "llvm/IR/Instruction.h"
-#include "llvm/IR/IntrinsicInst.h"
-#include "llvm/IR/Intrinsics.h"
-#include "llvm/IR/Type.h"
-#include "llvm/IR/Value.h"
-
-namespace llvm {
-
-template <class IRBuilderTy> class FixedPointBuilder {
- IRBuilderTy &B;
-
- Value *Convert(Value *Src, const FixedPointSemantics &SrcSema,
- const FixedPointSemantics &DstSema, bool DstIsInteger) {
- unsigned SrcWidth = SrcSema.getWidth();
- unsigned DstWidth = DstSema.getWidth();
- unsigned SrcScale = SrcSema.getScale();
- unsigned DstScale = DstSema.getScale();
- bool SrcIsSigned = SrcSema.isSigned();
- bool DstIsSigned = DstSema.isSigned();
-
- Type *DstIntTy = B.getIntNTy(DstWidth);
-
- Value *Result = Src;
- unsigned ResultWidth = SrcWidth;
-
- // Downscale.
- if (DstScale < SrcScale) {
- // When converting to integers, we round towards zero. For negative
- // numbers, right shifting rounds towards negative infinity. In this case,
- // we can just round up before shifting.
- if (DstIsInteger && SrcIsSigned) {
- Value *Zero = Constant::getNullValue(Result->getType());
- Value *IsNegative = B.CreateICmpSLT(Result, Zero);
- Value *LowBits = ConstantInt::get(
- B.getContext(), APInt::getLowBitsSet(ResultWidth, SrcScale));
- Value *Rounded = B.CreateAdd(Result, LowBits);
- Result = B.CreateSelect(IsNegative, Rounded, Result);
- }
-
- Result = SrcIsSigned
- ? B.CreateAShr(Result, SrcScale - DstScale, "downscale")
- : B.CreateLShr(Result, SrcScale - DstScale, "downscale");
- }
-
- if (!DstSema.isSaturated()) {
- // Resize.
- Result = B.CreateIntCast(Result, DstIntTy, SrcIsSigned, "resize");
-
- // Upscale.
- if (DstScale > SrcScale)
- Result = B.CreateShl(Result, DstScale - SrcScale, "upscale");
- } else {
- // Adjust the number of fractional bits.
- if (DstScale > SrcScale) {
- // Compare to DstWidth to prevent resizing twice.
- ResultWidth = std::max(SrcWidth + DstScale - SrcScale, DstWidth);
- Type *UpscaledTy = B.getIntNTy(ResultWidth);
- Result = B.CreateIntCast(Result, UpscaledTy, SrcIsSigned, "resize");
- Result = B.CreateShl(Result, DstScale - SrcScale, "upscale");
- }
-
- // Handle saturation.
- bool LessIntBits = DstSema.getIntegralBits() < SrcSema.getIntegralBits();
- if (LessIntBits) {
- Value *Max = ConstantInt::get(
- B.getContext(),
- APFixedPoint::getMax(DstSema).getValue().extOrTrunc(ResultWidth));
- Value *TooHigh = SrcIsSigned ? B.CreateICmpSGT(Result, Max)
- : B.CreateICmpUGT(Result, Max);
- Result = B.CreateSelect(TooHigh, Max, Result, "satmax");
- }
- // Cannot overflow min to dest type if src is unsigned since all fixed
- // point types can cover the unsigned min of 0.
- if (SrcIsSigned && (LessIntBits || !DstIsSigned)) {
- Value *Min = ConstantInt::get(
- B.getContext(),
- APFixedPoint::getMin(DstSema).getValue().extOrTrunc(ResultWidth));
- Value *TooLow = B.CreateICmpSLT(Result, Min);
- Result = B.CreateSelect(TooLow, Min, Result, "satmin");
- }
-
- // Resize the integer part to get the final destination size.
- if (ResultWidth != DstWidth)
- Result = B.CreateIntCast(Result, DstIntTy, SrcIsSigned, "resize");
- }
- return Result;
- }
-
- /// Get the common semantic for two semantics, with the added imposition that
- /// saturated padded types retain the padding bit.
- FixedPointSemantics
- getCommonBinopSemantic(const FixedPointSemantics &LHSSema,
- const FixedPointSemantics &RHSSema) {
- auto C = LHSSema.getCommonSemantics(RHSSema);
- bool BothPadded =
- LHSSema.hasUnsignedPadding() && RHSSema.hasUnsignedPadding();
- return FixedPointSemantics(
- C.getWidth() + (unsigned)(BothPadded && C.isSaturated()), C.getScale(),
- C.isSigned(), C.isSaturated(), BothPadded);
- }
-
- /// Given a floating point type and a fixed-point semantic, return a floating
- /// point type which can accommodate the fixed-point semantic. This is either
- /// \p Ty, or a floating point type with a larger exponent than Ty.
- Type *getAccommodatingFloatType(Type *Ty, const FixedPointSemantics &Sema) {
- const fltSemantics *FloatSema = &Ty->getFltSemantics();
- while (!Sema.fitsInFloatSemantics(*FloatSema))
- FloatSema = APFixedPoint::promoteFloatSemantics(FloatSema);
- return Type::getFloatingPointTy(Ty->getContext(), *FloatSema);
- }
-
-public:
- FixedPointBuilder(IRBuilderTy &Builder) : B(Builder) {}
-
- /// Convert an integer value representing a fixed-point number from one
- /// fixed-point semantic to another fixed-point semantic.
- /// \p Src - The source value
- /// \p SrcSema - The fixed-point semantic of the source value
- /// \p DstSema - The resulting fixed-point semantic
- Value *CreateFixedToFixed(Value *Src, const FixedPointSemantics &SrcSema,
- const FixedPointSemantics &DstSema) {
- return Convert(Src, SrcSema, DstSema, false);
- }
-
- /// Convert an integer value representing a fixed-point number to an integer
- /// with the given bit width and signedness.
- /// \p Src - The source value
- /// \p SrcSema - The fixed-point semantic of the source value
- /// \p DstWidth - The bit width of the result value
- /// \p DstIsSigned - The signedness of the result value
- Value *CreateFixedToInteger(Value *Src, const FixedPointSemantics &SrcSema,
- unsigned DstWidth, bool DstIsSigned) {
- return Convert(
- Src, SrcSema,
- FixedPointSemantics::GetIntegerSemantics(DstWidth, DstIsSigned), true);
- }
-
- /// Convert an integer value with the given signedness to an integer value
- /// representing the given fixed-point semantic.
- /// \p Src - The source value
- /// \p SrcIsSigned - The signedness of the source value
- /// \p DstSema - The resulting fixed-point semantic
- Value *CreateIntegerToFixed(Value *Src, unsigned SrcIsSigned,
- const FixedPointSemantics &DstSema) {
- return Convert(Src,
- FixedPointSemantics::GetIntegerSemantics(
- Src->getType()->getScalarSizeInBits(), SrcIsSigned),
- DstSema, false);
- }
-
- Value *CreateFixedToFloating(Value *Src, const FixedPointSemantics &SrcSema,
- Type *DstTy) {
- Value *Result;
- Type *OpTy = getAccommodatingFloatType(DstTy, SrcSema);
- // Convert the raw fixed-point value directly to floating point. If the
- // value is too large to fit, it will be rounded, not truncated.
- Result = SrcSema.isSigned() ? B.CreateSIToFP(Src, OpTy)
- : B.CreateUIToFP(Src, OpTy);
- // Rescale the integral-in-floating point by the scaling factor. This is
- // lossless, except for overflow to infinity which is unlikely.
- Result = B.CreateFMul(Result,
- ConstantFP::get(OpTy, std::pow(2, -(int)SrcSema.getScale())));
- if (OpTy != DstTy)
- Result = B.CreateFPTrunc(Result, DstTy);
- return Result;
- }
-
- Value *CreateFloatingToFixed(Value *Src, const FixedPointSemantics &DstSema) {
- bool UseSigned = DstSema.isSigned() || DstSema.hasUnsignedPadding();
- Value *Result = Src;
- Type *OpTy = getAccommodatingFloatType(Src->getType(), DstSema);
- if (OpTy != Src->getType())
- Result = B.CreateFPExt(Result, OpTy);
- // Rescale the floating point value so that its significant bits (for the
- // purposes of the conversion) are in the integral range.
- Result = B.CreateFMul(Result,
- ConstantFP::get(OpTy, std::pow(2, DstSema.getScale())));
-
- Type *ResultTy = B.getIntNTy(DstSema.getWidth());
- if (DstSema.isSaturated()) {
- Intrinsic::ID IID =
- UseSigned ? Intrinsic::fptosi_sat : Intrinsic::fptoui_sat;
- Result = B.CreateIntrinsic(IID, {ResultTy, OpTy}, {Result});
- } else {
- Result = UseSigned ? B.CreateFPToSI(Result, ResultTy)
- : B.CreateFPToUI(Result, ResultTy);
- }
-
- // When saturating unsigned-with-padding using signed operations, we may
- // get negative values. Emit an extra clamp to zero.
- if (DstSema.isSaturated() && DstSema.hasUnsignedPadding()) {
- Constant *Zero = Constant::getNullValue(Result->getType());
- Result =
- B.CreateSelect(B.CreateICmpSLT(Result, Zero), Zero, Result, "satmin");
- }
-
- return Result;
- }
-
- /// Add two fixed-point values and return the result in their common semantic.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateAdd(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
- bool UseSigned = CommonSema.isSigned() || CommonSema.hasUnsignedPadding();
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- Value *Result;
- if (CommonSema.isSaturated()) {
- Intrinsic::ID IID = UseSigned ? Intrinsic::sadd_sat : Intrinsic::uadd_sat;
- Result = B.CreateBinaryIntrinsic(IID, WideLHS, WideRHS);
- } else {
- Result = B.CreateAdd(WideLHS, WideRHS);
- }
-
- return CreateFixedToFixed(Result, CommonSema,
- LHSSema.getCommonSemantics(RHSSema));
- }
-
- /// Subtract two fixed-point values and return the result in their common
- /// semantic.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateSub(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
- bool UseSigned = CommonSema.isSigned() || CommonSema.hasUnsignedPadding();
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- Value *Result;
- if (CommonSema.isSaturated()) {
- Intrinsic::ID IID = UseSigned ? Intrinsic::ssub_sat : Intrinsic::usub_sat;
- Result = B.CreateBinaryIntrinsic(IID, WideLHS, WideRHS);
- } else {
- Result = B.CreateSub(WideLHS, WideRHS);
- }
-
- // Subtraction can end up below 0 for padded unsigned operations, so emit
- // an extra clamp in that case.
- if (CommonSema.isSaturated() && CommonSema.hasUnsignedPadding()) {
- Constant *Zero = Constant::getNullValue(Result->getType());
- Result =
- B.CreateSelect(B.CreateICmpSLT(Result, Zero), Zero, Result, "satmin");
- }
-
- return CreateFixedToFixed(Result, CommonSema,
- LHSSema.getCommonSemantics(RHSSema));
- }
-
- /// Multiply two fixed-point values and return the result in their common
- /// semantic.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateMul(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
- bool UseSigned = CommonSema.isSigned() || CommonSema.hasUnsignedPadding();
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- Intrinsic::ID IID;
- if (CommonSema.isSaturated()) {
- IID = UseSigned ? Intrinsic::smul_fix_sat : Intrinsic::umul_fix_sat;
- } else {
- IID = UseSigned ? Intrinsic::smul_fix : Intrinsic::umul_fix;
- }
- Value *Result = B.CreateIntrinsic(
- IID, {WideLHS->getType()},
- {WideLHS, WideRHS, B.getInt32(CommonSema.getScale())});
-
- return CreateFixedToFixed(Result, CommonSema,
- LHSSema.getCommonSemantics(RHSSema));
- }
-
- /// Divide two fixed-point values and return the result in their common
- /// semantic.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateDiv(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
- bool UseSigned = CommonSema.isSigned() || CommonSema.hasUnsignedPadding();
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- Intrinsic::ID IID;
- if (CommonSema.isSaturated()) {
- IID = UseSigned ? Intrinsic::sdiv_fix_sat : Intrinsic::udiv_fix_sat;
- } else {
- IID = UseSigned ? Intrinsic::sdiv_fix : Intrinsic::udiv_fix;
- }
- Value *Result = B.CreateIntrinsic(
- IID, {WideLHS->getType()},
- {WideLHS, WideRHS, B.getInt32(CommonSema.getScale())});
-
- return CreateFixedToFixed(Result, CommonSema,
- LHSSema.getCommonSemantics(RHSSema));
- }
-
- /// Left shift a fixed-point value by an unsigned integer value. The integer
- /// value can be any bit width.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- Value *CreateShl(Value *LHS, const FixedPointSemantics &LHSSema, Value *RHS) {
- bool UseSigned = LHSSema.isSigned() || LHSSema.hasUnsignedPadding();
-
- RHS = B.CreateIntCast(RHS, LHS->getType(), /*IsSigned=*/false);
-
- Value *Result;
- if (LHSSema.isSaturated()) {
- Intrinsic::ID IID = UseSigned ? Intrinsic::sshl_sat : Intrinsic::ushl_sat;
- Result = B.CreateBinaryIntrinsic(IID, LHS, RHS);
- } else {
- Result = B.CreateShl(LHS, RHS);
- }
-
- return Result;
- }
-
- /// Right shift a fixed-point value by an unsigned integer value. The integer
- /// value can be any bit width.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- Value *CreateShr(Value *LHS, const FixedPointSemantics &LHSSema, Value *RHS) {
- RHS = B.CreateIntCast(RHS, LHS->getType(), false);
-
- return LHSSema.isSigned() ? B.CreateAShr(LHS, RHS) : B.CreateLShr(LHS, RHS);
- }
-
- /// Compare two fixed-point values for equality.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateEQ(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return B.CreateICmpEQ(WideLHS, WideRHS);
- }
-
- /// Compare two fixed-point values for inequality.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateNE(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return B.CreateICmpNE(WideLHS, WideRHS);
- }
-
- /// Compare two fixed-point values as LHS < RHS.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateLT(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return CommonSema.isSigned() ? B.CreateICmpSLT(WideLHS, WideRHS)
- : B.CreateICmpULT(WideLHS, WideRHS);
- }
-
- /// Compare two fixed-point values as LHS <= RHS.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateLE(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return CommonSema.isSigned() ? B.CreateICmpSLE(WideLHS, WideRHS)
- : B.CreateICmpULE(WideLHS, WideRHS);
- }
-
- /// Compare two fixed-point values as LHS > RHS.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateGT(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return CommonSema.isSigned() ? B.CreateICmpSGT(WideLHS, WideRHS)
- : B.CreateICmpUGT(WideLHS, WideRHS);
- }
-
- /// Compare two fixed-point values as LHS >= RHS.
- /// \p LHS - The left hand side
- /// \p LHSSema - The semantic of the left hand side
- /// \p RHS - The right hand side
- /// \p RHSSema - The semantic of the right hand side
- Value *CreateGE(Value *LHS, const FixedPointSemantics &LHSSema,
- Value *RHS, const FixedPointSemantics &RHSSema) {
- auto CommonSema = getCommonBinopSemantic(LHSSema, RHSSema);
-
- Value *WideLHS = CreateFixedToFixed(LHS, LHSSema, CommonSema);
- Value *WideRHS = CreateFixedToFixed(RHS, RHSSema, CommonSema);
-
- return CommonSema.isSigned() ? B.CreateICmpSGE(WideLHS, WideRHS)
- : B.CreateICmpUGE(WideLHS, WideRHS);
- }
-};
-
-} // end namespace llvm
-
-#endif // LLVM_IR_FIXEDPOINTBUILDER_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/IR/MatrixBuilder.h b/contrib/libs/llvm12/include/llvm/IR/MatrixBuilder.h
deleted file mode 100644
index c753a2031cf..00000000000
--- a/contrib/libs/llvm12/include/llvm/IR/MatrixBuilder.h
+++ /dev/null
@@ -1,247 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- llvm/MatrixBuilder.h - Builder to lower matrix ops -------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the MatrixBuilder class, which is used as a convenient way
-// to lower matrix operations to LLVM IR.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_IR_MATRIXBUILDER_H
-#define LLVM_IR_MATRIXBUILDER_H
-
-#include "llvm/IR/Constant.h"
-#include "llvm/IR/Constants.h"
-#include "llvm/IR/IRBuilder.h"
-#include "llvm/IR/InstrTypes.h"
-#include "llvm/IR/Instruction.h"
-#include "llvm/IR/IntrinsicInst.h"
-#include "llvm/IR/Type.h"
-#include "llvm/IR/Value.h"
-#include "llvm/Support/Alignment.h"
-
-namespace llvm {
-
-class Function;
-class Twine;
-class Module;
-
-template <class IRBuilderTy> class MatrixBuilder {
- IRBuilderTy &B;
- Module *getModule() { return B.GetInsertBlock()->getParent()->getParent(); }
-
- std::pair<Value *, Value *> splatScalarOperandIfNeeded(Value *LHS,
- Value *RHS) {
- assert((LHS->getType()->isVectorTy() || RHS->getType()->isVectorTy()) &&
- "One of the operands must be a matrix (embedded in a vector)");
- if (LHS->getType()->isVectorTy() && !RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(LHS->getType()) &&
- "LHS Assumed to be fixed width");
- RHS = B.CreateVectorSplat(
- cast<VectorType>(LHS->getType())->getElementCount(), RHS,
- "scalar.splat");
- } else if (!LHS->getType()->isVectorTy() && RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(RHS->getType()) &&
- "RHS Assumed to be fixed width");
- LHS = B.CreateVectorSplat(
- cast<VectorType>(RHS->getType())->getElementCount(), LHS,
- "scalar.splat");
- }
- return {LHS, RHS};
- }
-
-public:
- MatrixBuilder(IRBuilderTy &Builder) : B(Builder) {}
-
- /// Create a column major, strided matrix load.
- /// \p DataPtr - Start address of the matrix read
- /// \p Rows - Number of rows in matrix (must be a constant)
- /// \p Columns - Number of columns in matrix (must be a constant)
- /// \p Stride - Space between columns
- CallInst *CreateColumnMajorLoad(Value *DataPtr, Align Alignment,
- Value *Stride, bool IsVolatile, unsigned Rows,
- unsigned Columns, const Twine &Name = "") {
-
- // Deal with the pointer
- PointerType *PtrTy = cast<PointerType>(DataPtr->getType());
- Type *EltTy = PtrTy->getElementType();
-
- auto *RetType = FixedVectorType::get(EltTy, Rows * Columns);
-
- Value *Ops[] = {DataPtr, Stride, B.getInt1(IsVolatile), B.getInt32(Rows),
- B.getInt32(Columns)};
- Type *OverloadedTypes[] = {RetType};
-
- Function *TheFn = Intrinsic::getDeclaration(
- getModule(), Intrinsic::matrix_column_major_load, OverloadedTypes);
-
- CallInst *Call = B.CreateCall(TheFn->getFunctionType(), TheFn, Ops, Name);
- Attribute AlignAttr =
- Attribute::getWithAlignment(Call->getContext(), Alignment);
- Call->addAttribute(1, AlignAttr);
- return Call;
- }
-
- /// Create a column major, strided matrix store.
- /// \p Matrix - Matrix to store
- /// \p Ptr - Pointer to write back to
- /// \p Stride - Space between columns
- CallInst *CreateColumnMajorStore(Value *Matrix, Value *Ptr, Align Alignment,
- Value *Stride, bool IsVolatile,
- unsigned Rows, unsigned Columns,
- const Twine &Name = "") {
- Value *Ops[] = {Matrix, Ptr,
- Stride, B.getInt1(IsVolatile),
- B.getInt32(Rows), B.getInt32(Columns)};
- Type *OverloadedTypes[] = {Matrix->getType()};
-
- Function *TheFn = Intrinsic::getDeclaration(
- getModule(), Intrinsic::matrix_column_major_store, OverloadedTypes);
-
- CallInst *Call = B.CreateCall(TheFn->getFunctionType(), TheFn, Ops, Name);
- Attribute AlignAttr =
- Attribute::getWithAlignment(Call->getContext(), Alignment);
- Call->addAttribute(2, AlignAttr);
- return Call;
- }
-
- /// Create a llvm.matrix.transpose call, transposing \p Matrix with \p Rows
- /// rows and \p Columns columns.
- CallInst *CreateMatrixTranspose(Value *Matrix, unsigned Rows,
- unsigned Columns, const Twine &Name = "") {
- auto *OpType = cast<VectorType>(Matrix->getType());
- auto *ReturnType =
- FixedVectorType::get(OpType->getElementType(), Rows * Columns);
-
- Type *OverloadedTypes[] = {ReturnType};
- Value *Ops[] = {Matrix, B.getInt32(Rows), B.getInt32(Columns)};
- Function *TheFn = Intrinsic::getDeclaration(
- getModule(), Intrinsic::matrix_transpose, OverloadedTypes);
-
- return B.CreateCall(TheFn->getFunctionType(), TheFn, Ops, Name);
- }
-
- /// Create a llvm.matrix.multiply call, multiplying matrixes \p LHS and \p
- /// RHS.
- CallInst *CreateMatrixMultiply(Value *LHS, Value *RHS, unsigned LHSRows,
- unsigned LHSColumns, unsigned RHSColumns,
- const Twine &Name = "") {
- auto *LHSType = cast<VectorType>(LHS->getType());
- auto *RHSType = cast<VectorType>(RHS->getType());
-
- auto *ReturnType =
- FixedVectorType::get(LHSType->getElementType(), LHSRows * RHSColumns);
-
- Value *Ops[] = {LHS, RHS, B.getInt32(LHSRows), B.getInt32(LHSColumns),
- B.getInt32(RHSColumns)};
- Type *OverloadedTypes[] = {ReturnType, LHSType, RHSType};
-
- Function *TheFn = Intrinsic::getDeclaration(
- getModule(), Intrinsic::matrix_multiply, OverloadedTypes);
- return B.CreateCall(TheFn->getFunctionType(), TheFn, Ops, Name);
- }
-
- /// Insert a single element \p NewVal into \p Matrix at indices (\p RowIdx, \p
- /// ColumnIdx).
- Value *CreateMatrixInsert(Value *Matrix, Value *NewVal, Value *RowIdx,
- Value *ColumnIdx, unsigned NumRows) {
- return B.CreateInsertElement(
- Matrix, NewVal,
- B.CreateAdd(B.CreateMul(ColumnIdx, ConstantInt::get(
- ColumnIdx->getType(), NumRows)),
- RowIdx));
- }
-
- /// Add matrixes \p LHS and \p RHS. Support both integer and floating point
- /// matrixes.
- Value *CreateAdd(Value *LHS, Value *RHS) {
- assert(LHS->getType()->isVectorTy() || RHS->getType()->isVectorTy());
- if (LHS->getType()->isVectorTy() && !RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(LHS->getType()) &&
- "LHS Assumed to be fixed width");
- RHS = B.CreateVectorSplat(
- cast<VectorType>(LHS->getType())->getElementCount(), RHS,
- "scalar.splat");
- } else if (!LHS->getType()->isVectorTy() && RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(RHS->getType()) &&
- "RHS Assumed to be fixed width");
- LHS = B.CreateVectorSplat(
- cast<VectorType>(RHS->getType())->getElementCount(), LHS,
- "scalar.splat");
- }
-
- return cast<VectorType>(LHS->getType())
- ->getElementType()
- ->isFloatingPointTy()
- ? B.CreateFAdd(LHS, RHS)
- : B.CreateAdd(LHS, RHS);
- }
-
- /// Subtract matrixes \p LHS and \p RHS. Support both integer and floating
- /// point matrixes.
- Value *CreateSub(Value *LHS, Value *RHS) {
- assert(LHS->getType()->isVectorTy() || RHS->getType()->isVectorTy());
- if (LHS->getType()->isVectorTy() && !RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(LHS->getType()) &&
- "LHS Assumed to be fixed width");
- RHS = B.CreateVectorSplat(
- cast<VectorType>(LHS->getType())->getElementCount(), RHS,
- "scalar.splat");
- } else if (!LHS->getType()->isVectorTy() && RHS->getType()->isVectorTy()) {
- assert(!isa<ScalableVectorType>(RHS->getType()) &&
- "RHS Assumed to be fixed width");
- LHS = B.CreateVectorSplat(
- cast<VectorType>(RHS->getType())->getElementCount(), LHS,
- "scalar.splat");
- }
-
- return cast<VectorType>(LHS->getType())
- ->getElementType()
- ->isFloatingPointTy()
- ? B.CreateFSub(LHS, RHS)
- : B.CreateSub(LHS, RHS);
- }
-
- /// Multiply matrix \p LHS with scalar \p RHS or scalar \p LHS with matrix \p
- /// RHS.
- Value *CreateScalarMultiply(Value *LHS, Value *RHS) {
- std::tie(LHS, RHS) = splatScalarOperandIfNeeded(LHS, RHS);
- if (LHS->getType()->getScalarType()->isFloatingPointTy())
- return B.CreateFMul(LHS, RHS);
- return B.CreateMul(LHS, RHS);
- }
-
- /// Extracts the element at (\p RowIdx, \p ColumnIdx) from \p Matrix.
- Value *CreateExtractElement(Value *Matrix, Value *RowIdx, Value *ColumnIdx,
- unsigned NumRows, Twine const &Name = "") {
-
- unsigned MaxWidth = std::max(RowIdx->getType()->getScalarSizeInBits(),
- ColumnIdx->getType()->getScalarSizeInBits());
- Type *IntTy = IntegerType::get(RowIdx->getType()->getContext(), MaxWidth);
- RowIdx = B.CreateZExt(RowIdx, IntTy);
- ColumnIdx = B.CreateZExt(ColumnIdx, IntTy);
- Value *NumRowsV = B.getIntN(MaxWidth, NumRows);
- return B.CreateExtractElement(
- Matrix, B.CreateAdd(B.CreateMul(ColumnIdx, NumRowsV), RowIdx),
- "matext");
- }
-};
-
-} // end namespace llvm
-
-#endif // LLVM_IR_MATRIXBUILDER_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/AMDHSAKernelDescriptor.h b/contrib/libs/llvm12/include/llvm/Support/AMDHSAKernelDescriptor.h
deleted file mode 100644
index 8e1a6f688b4..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/AMDHSAKernelDescriptor.h
+++ /dev/null
@@ -1,223 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- AMDHSAKernelDescriptor.h -----------------------------*- C++ -*---===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-/// \file
-/// AMDHSA kernel descriptor definitions. For more information, visit
-/// https://llvm.org/docs/AMDGPUUsage.html#kernel-descriptor
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_SUPPORT_AMDHSAKERNELDESCRIPTOR_H
-#define LLVM_SUPPORT_AMDHSAKERNELDESCRIPTOR_H
-
-#include <cstddef>
-#include <cstdint>
-
-// Gets offset of specified member in specified type.
-#ifndef offsetof
-#define offsetof(TYPE, MEMBER) ((size_t)&((TYPE*)0)->MEMBER)
-#endif // offsetof
-
-// Creates enumeration entries used for packing bits into integers. Enumeration
-// entries include bit shift amount, bit width, and bit mask.
-#ifndef AMDHSA_BITS_ENUM_ENTRY
-#define AMDHSA_BITS_ENUM_ENTRY(NAME, SHIFT, WIDTH) \
- NAME ## _SHIFT = (SHIFT), \
- NAME ## _WIDTH = (WIDTH), \
- NAME = (((1 << (WIDTH)) - 1) << (SHIFT))
-#endif // AMDHSA_BITS_ENUM_ENTRY
-
-// Gets bits for specified bit mask from specified source.
-#ifndef AMDHSA_BITS_GET
-#define AMDHSA_BITS_GET(SRC, MSK) ((SRC & MSK) >> MSK ## _SHIFT)
-#endif // AMDHSA_BITS_GET
-
-// Sets bits for specified bit mask in specified destination.
-#ifndef AMDHSA_BITS_SET
-#define AMDHSA_BITS_SET(DST, MSK, VAL) \
- DST &= ~MSK; \
- DST |= ((VAL << MSK ## _SHIFT) & MSK)
-#endif // AMDHSA_BITS_SET
-
-namespace llvm {
-namespace amdhsa {
-
-// Floating point rounding modes. Must match hardware definition.
-enum : uint8_t {
- FLOAT_ROUND_MODE_NEAR_EVEN = 0,
- FLOAT_ROUND_MODE_PLUS_INFINITY = 1,
- FLOAT_ROUND_MODE_MINUS_INFINITY = 2,
- FLOAT_ROUND_MODE_ZERO = 3,
-};
-
-// Floating point denorm modes. Must match hardware definition.
-enum : uint8_t {
- FLOAT_DENORM_MODE_FLUSH_SRC_DST = 0,
- FLOAT_DENORM_MODE_FLUSH_DST = 1,
- FLOAT_DENORM_MODE_FLUSH_SRC = 2,
- FLOAT_DENORM_MODE_FLUSH_NONE = 3,
-};
-
-// System VGPR workitem IDs. Must match hardware definition.
-enum : uint8_t {
- SYSTEM_VGPR_WORKITEM_ID_X = 0,
- SYSTEM_VGPR_WORKITEM_ID_X_Y = 1,
- SYSTEM_VGPR_WORKITEM_ID_X_Y_Z = 2,
- SYSTEM_VGPR_WORKITEM_ID_UNDEFINED = 3,
-};
-
-// Compute program resource register 1. Must match hardware definition.
-#define COMPUTE_PGM_RSRC1(NAME, SHIFT, WIDTH) \
- AMDHSA_BITS_ENUM_ENTRY(COMPUTE_PGM_RSRC1_ ## NAME, SHIFT, WIDTH)
-enum : int32_t {
- COMPUTE_PGM_RSRC1(GRANULATED_WORKITEM_VGPR_COUNT, 0, 6),
- COMPUTE_PGM_RSRC1(GRANULATED_WAVEFRONT_SGPR_COUNT, 6, 4),
- COMPUTE_PGM_RSRC1(PRIORITY, 10, 2),
- COMPUTE_PGM_RSRC1(FLOAT_ROUND_MODE_32, 12, 2),
- COMPUTE_PGM_RSRC1(FLOAT_ROUND_MODE_16_64, 14, 2),
- COMPUTE_PGM_RSRC1(FLOAT_DENORM_MODE_32, 16, 2),
- COMPUTE_PGM_RSRC1(FLOAT_DENORM_MODE_16_64, 18, 2),
- COMPUTE_PGM_RSRC1(PRIV, 20, 1),
- COMPUTE_PGM_RSRC1(ENABLE_DX10_CLAMP, 21, 1),
- COMPUTE_PGM_RSRC1(DEBUG_MODE, 22, 1),
- COMPUTE_PGM_RSRC1(ENABLE_IEEE_MODE, 23, 1),
- COMPUTE_PGM_RSRC1(BULKY, 24, 1),
- COMPUTE_PGM_RSRC1(CDBG_USER, 25, 1),
- COMPUTE_PGM_RSRC1(FP16_OVFL, 26, 1), // GFX9+
- COMPUTE_PGM_RSRC1(RESERVED0, 27, 2),
- COMPUTE_PGM_RSRC1(WGP_MODE, 29, 1), // GFX10+
- COMPUTE_PGM_RSRC1(MEM_ORDERED, 30, 1), // GFX10+
- COMPUTE_PGM_RSRC1(FWD_PROGRESS, 31, 1), // GFX10+
-};
-#undef COMPUTE_PGM_RSRC1
-
-// Compute program resource register 2. Must match hardware definition.
-#define COMPUTE_PGM_RSRC2(NAME, SHIFT, WIDTH) \
- AMDHSA_BITS_ENUM_ENTRY(COMPUTE_PGM_RSRC2_ ## NAME, SHIFT, WIDTH)
-enum : int32_t {
- COMPUTE_PGM_RSRC2(ENABLE_PRIVATE_SEGMENT, 0, 1),
- COMPUTE_PGM_RSRC2(USER_SGPR_COUNT, 1, 5),
- COMPUTE_PGM_RSRC2(ENABLE_TRAP_HANDLER, 6, 1),
- COMPUTE_PGM_RSRC2(ENABLE_SGPR_WORKGROUP_ID_X, 7, 1),
- COMPUTE_PGM_RSRC2(ENABLE_SGPR_WORKGROUP_ID_Y, 8, 1),
- COMPUTE_PGM_RSRC2(ENABLE_SGPR_WORKGROUP_ID_Z, 9, 1),
- COMPUTE_PGM_RSRC2(ENABLE_SGPR_WORKGROUP_INFO, 10, 1),
- COMPUTE_PGM_RSRC2(ENABLE_VGPR_WORKITEM_ID, 11, 2),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_ADDRESS_WATCH, 13, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_MEMORY, 14, 1),
- COMPUTE_PGM_RSRC2(GRANULATED_LDS_SIZE, 15, 9),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_IEEE_754_FP_INVALID_OPERATION, 24, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_FP_DENORMAL_SOURCE, 25, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_IEEE_754_FP_DIVISION_BY_ZERO, 26, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_IEEE_754_FP_OVERFLOW, 27, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_IEEE_754_FP_UNDERFLOW, 28, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_IEEE_754_FP_INEXACT, 29, 1),
- COMPUTE_PGM_RSRC2(ENABLE_EXCEPTION_INT_DIVIDE_BY_ZERO, 30, 1),
- COMPUTE_PGM_RSRC2(RESERVED0, 31, 1),
-};
-#undef COMPUTE_PGM_RSRC2
-
-// Compute program resource register 3. Must match hardware definition.
-#define COMPUTE_PGM_RSRC3(NAME, SHIFT, WIDTH) \
- AMDHSA_BITS_ENUM_ENTRY(COMPUTE_PGM_RSRC3_ ## NAME, SHIFT, WIDTH)
-enum : int32_t {
- COMPUTE_PGM_RSRC3(SHARED_VGPR_COUNT, 0, 4), // GFX10+
- COMPUTE_PGM_RSRC3(RESERVED0, 4, 28),
-};
-#undef COMPUTE_PGM_RSRC3
-
-// Kernel code properties. Must be kept backwards compatible.
-#define KERNEL_CODE_PROPERTY(NAME, SHIFT, WIDTH) \
- AMDHSA_BITS_ENUM_ENTRY(KERNEL_CODE_PROPERTY_ ## NAME, SHIFT, WIDTH)
-enum : int32_t {
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_PRIVATE_SEGMENT_BUFFER, 0, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_DISPATCH_PTR, 1, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_QUEUE_PTR, 2, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_KERNARG_SEGMENT_PTR, 3, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_DISPATCH_ID, 4, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_FLAT_SCRATCH_INIT, 5, 1),
- KERNEL_CODE_PROPERTY(ENABLE_SGPR_PRIVATE_SEGMENT_SIZE, 6, 1),
- KERNEL_CODE_PROPERTY(RESERVED0, 7, 3),
- KERNEL_CODE_PROPERTY(ENABLE_WAVEFRONT_SIZE32, 10, 1), // GFX10+
- KERNEL_CODE_PROPERTY(RESERVED1, 11, 5),
-};
-#undef KERNEL_CODE_PROPERTY
-
-// Kernel descriptor. Must be kept backwards compatible.
-struct kernel_descriptor_t {
- uint32_t group_segment_fixed_size;
- uint32_t private_segment_fixed_size;
- uint8_t reserved0[8];
- int64_t kernel_code_entry_byte_offset;
- uint8_t reserved1[20];
- uint32_t compute_pgm_rsrc3; // GFX10+
- uint32_t compute_pgm_rsrc1;
- uint32_t compute_pgm_rsrc2;
- uint16_t kernel_code_properties;
- uint8_t reserved2[6];
-};
-
-enum : uint32_t {
- GROUP_SEGMENT_FIXED_SIZE_OFFSET = 0,
- PRIVATE_SEGMENT_FIXED_SIZE_OFFSET = 4,
- RESERVED0_OFFSET = 8,
- KERNEL_CODE_ENTRY_BYTE_OFFSET_OFFSET = 16,
- RESERVED1_OFFSET = 24,
- COMPUTE_PGM_RSRC3_OFFSET = 44,
- COMPUTE_PGM_RSRC1_OFFSET = 48,
- COMPUTE_PGM_RSRC2_OFFSET = 52,
- KERNEL_CODE_PROPERTIES_OFFSET = 56,
- RESERVED2_OFFSET = 58,
-};
-
-static_assert(
- sizeof(kernel_descriptor_t) == 64,
- "invalid size for kernel_descriptor_t");
-static_assert(offsetof(kernel_descriptor_t, group_segment_fixed_size) ==
- GROUP_SEGMENT_FIXED_SIZE_OFFSET,
- "invalid offset for group_segment_fixed_size");
-static_assert(offsetof(kernel_descriptor_t, private_segment_fixed_size) ==
- PRIVATE_SEGMENT_FIXED_SIZE_OFFSET,
- "invalid offset for private_segment_fixed_size");
-static_assert(offsetof(kernel_descriptor_t, reserved0) == RESERVED0_OFFSET,
- "invalid offset for reserved0");
-static_assert(offsetof(kernel_descriptor_t, kernel_code_entry_byte_offset) ==
- KERNEL_CODE_ENTRY_BYTE_OFFSET_OFFSET,
- "invalid offset for kernel_code_entry_byte_offset");
-static_assert(offsetof(kernel_descriptor_t, reserved1) == RESERVED1_OFFSET,
- "invalid offset for reserved1");
-static_assert(offsetof(kernel_descriptor_t, compute_pgm_rsrc3) ==
- COMPUTE_PGM_RSRC3_OFFSET,
- "invalid offset for compute_pgm_rsrc3");
-static_assert(offsetof(kernel_descriptor_t, compute_pgm_rsrc1) ==
- COMPUTE_PGM_RSRC1_OFFSET,
- "invalid offset for compute_pgm_rsrc1");
-static_assert(offsetof(kernel_descriptor_t, compute_pgm_rsrc2) ==
- COMPUTE_PGM_RSRC2_OFFSET,
- "invalid offset for compute_pgm_rsrc2");
-static_assert(offsetof(kernel_descriptor_t, kernel_code_properties) ==
- KERNEL_CODE_PROPERTIES_OFFSET,
- "invalid offset for kernel_code_properties");
-static_assert(offsetof(kernel_descriptor_t, reserved2) == RESERVED2_OFFSET,
- "invalid offset for reserved2");
-
-} // end namespace amdhsa
-} // end namespace llvm
-
-#endif // LLVM_SUPPORT_AMDHSAKERNELDESCRIPTOR_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/Base64.h b/contrib/libs/llvm12/include/llvm/Support/Base64.h
deleted file mode 100644
index 5eb41f0c233..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/Base64.h
+++ /dev/null
@@ -1,67 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- Base64.h - Base64 Encoder/Decoder ----------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file provides generic base64 encoder/decoder.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_SUPPORT_BASE64_H
-#define LLVM_SUPPORT_BASE64_H
-
-#include <string>
-
-namespace llvm {
-
-template <class InputBytes> std::string encodeBase64(InputBytes const &Bytes) {
- static const char Table[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
- "abcdefghijklmnopqrstuvwxyz"
- "0123456789+/";
- std::string Buffer;
- Buffer.resize(((Bytes.size() + 2) / 3) * 4);
-
- size_t i = 0, j = 0;
- for (size_t n = Bytes.size() / 3 * 3; i < n; i += 3, j += 4) {
- uint32_t x = ((unsigned char)Bytes[i] << 16) |
- ((unsigned char)Bytes[i + 1] << 8) |
- (unsigned char)Bytes[i + 2];
- Buffer[j + 0] = Table[(x >> 18) & 63];
- Buffer[j + 1] = Table[(x >> 12) & 63];
- Buffer[j + 2] = Table[(x >> 6) & 63];
- Buffer[j + 3] = Table[x & 63];
- }
- if (i + 1 == Bytes.size()) {
- uint32_t x = ((unsigned char)Bytes[i] << 16);
- Buffer[j + 0] = Table[(x >> 18) & 63];
- Buffer[j + 1] = Table[(x >> 12) & 63];
- Buffer[j + 2] = '=';
- Buffer[j + 3] = '=';
- } else if (i + 2 == Bytes.size()) {
- uint32_t x =
- ((unsigned char)Bytes[i] << 16) | ((unsigned char)Bytes[i + 1] << 8);
- Buffer[j + 0] = Table[(x >> 18) & 63];
- Buffer[j + 1] = Table[(x >> 12) & 63];
- Buffer[j + 2] = Table[(x >> 6) & 63];
- Buffer[j + 3] = '=';
- }
- return Buffer;
-}
-
-} // end namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/Capacity.h b/contrib/libs/llvm12/include/llvm/Support/Capacity.h
deleted file mode 100644
index 263a5475095..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/Capacity.h
+++ /dev/null
@@ -1,42 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- Capacity.h - Generic computation of ADT memory use -----*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the capacity function that computes the amount of
-// memory used by an ADT.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_SUPPORT_CAPACITY_H
-#define LLVM_SUPPORT_CAPACITY_H
-
-#include <cstddef>
-
-namespace llvm {
-
-template <typename T>
-static inline size_t capacity_in_bytes(const T &x) {
- // This default definition of capacity should work for things like std::vector
- // and friends. More specialized versions will work for others.
- return x.capacity() * sizeof(typename T::value_type);
-}
-
-} // end namespace llvm
-
-#endif
-
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/Solaris/sys/regset.h b/contrib/libs/llvm12/include/llvm/Support/Solaris/sys/regset.h
deleted file mode 100644
index dd564f5d148..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/Solaris/sys/regset.h
+++ /dev/null
@@ -1,49 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-/*===- llvm/Support/Solaris/sys/regset.h ------------------------*- C++ -*-===*
- *
- * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
- * See https://llvm.org/LICENSE.txt for license information.
- * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
- *
- *===----------------------------------------------------------------------===*
- *
- * This file works around excessive name space pollution from the system header
- * on Solaris hosts.
- *
- *===----------------------------------------------------------------------===*/
-
-#ifndef LLVM_SUPPORT_SOLARIS_SYS_REGSET_H
-
-#include_next <sys/regset.h>
-
-#undef CS
-#undef DS
-#undef ES
-#undef FS
-#undef GS
-#undef SS
-#undef EAX
-#undef ECX
-#undef EDX
-#undef EBX
-#undef ESP
-#undef EBP
-#undef ESI
-#undef EDI
-#undef EIP
-#undef UESP
-#undef EFL
-#undef ERR
-#undef TRAPNO
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/TaskQueue.h b/contrib/libs/llvm12/include/llvm/Support/TaskQueue.h
deleted file mode 100644
index a7ecb8f5186..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/TaskQueue.h
+++ /dev/null
@@ -1,149 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- llvm/Support/TaskQueue.h - A TaskQueue implementation ---*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines a crude C++11 based task queue.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_SUPPORT_TASK_QUEUE_H
-#define LLVM_SUPPORT_TASK_QUEUE_H
-
-#include "llvm/Config/llvm-config.h"
-#include "llvm/Support/ThreadPool.h"
-#include "llvm/Support/thread.h"
-
-#include <atomic>
-#include <cassert>
-#include <condition_variable>
-#include <deque>
-#include <functional>
-#include <future>
-#include <memory>
-#include <mutex>
-#include <utility>
-
-namespace llvm {
-/// TaskQueue executes serialized work on a user-defined Thread Pool. It
-/// guarantees that if task B is enqueued after task A, task B begins after
-/// task A completes and there is no overlap between the two.
-class TaskQueue {
- // Because we don't have init capture to use move-only local variables that
- // are captured into a lambda, we create the promise inside an explicit
- // callable struct. We want to do as much of the wrapping in the
- // type-specialized domain (before type erasure) and then erase this into a
- // std::function.
- template <typename Callable> struct Task {
- using ResultTy = std::result_of_t<Callable()>;
- explicit Task(Callable C, TaskQueue &Parent)
- : C(std::move(C)), P(std::make_shared<std::promise<ResultTy>>()),
- Parent(&Parent) {}
-
- template<typename T>
- void invokeCallbackAndSetPromise(T*) {
- P->set_value(C());
- }
-
- void invokeCallbackAndSetPromise(void*) {
- C();
- P->set_value();
- }
-
- void operator()() noexcept {
- ResultTy *Dummy = nullptr;
- invokeCallbackAndSetPromise(Dummy);
- Parent->completeTask();
- }
-
- Callable C;
- std::shared_ptr<std::promise<ResultTy>> P;
- TaskQueue *Parent;
- };
-
-public:
- /// Construct a task queue with no work.
- TaskQueue(ThreadPool &Scheduler) : Scheduler(Scheduler) { (void)Scheduler; }
-
- /// Blocking destructor: the queue will wait for all work to complete.
- ~TaskQueue() {
- Scheduler.wait();
- assert(Tasks.empty());
- }
-
- /// Asynchronous submission of a task to the queue. The returned future can be
- /// used to wait for the task (and all previous tasks that have not yet
- /// completed) to finish.
- template <typename Callable>
- std::future<std::result_of_t<Callable()>> async(Callable &&C) {
-#if !LLVM_ENABLE_THREADS
- static_assert(false,
- "TaskQueue requires building with LLVM_ENABLE_THREADS!");
-#endif
- Task<Callable> T{std::move(C), *this};
- using ResultTy = std::result_of_t<Callable()>;
- std::future<ResultTy> F = T.P->get_future();
- {
- std::lock_guard<std::mutex> Lock(QueueLock);
- // If there's already a task in flight, just queue this one up. If
- // there is not a task in flight, bypass the queue and schedule this
- // task immediately.
- if (IsTaskInFlight)
- Tasks.push_back(std::move(T));
- else {
- Scheduler.async(std::move(T));
- IsTaskInFlight = true;
- }
- }
- return F;
- }
-
-private:
- void completeTask() {
- // We just completed a task. If there are no more tasks in the queue,
- // update IsTaskInFlight to false and stop doing work. Otherwise
- // schedule the next task (while not holding the lock).
- std::function<void()> Continuation;
- {
- std::lock_guard<std::mutex> Lock(QueueLock);
- if (Tasks.empty()) {
- IsTaskInFlight = false;
- return;
- }
-
- Continuation = std::move(Tasks.front());
- Tasks.pop_front();
- }
- Scheduler.async(std::move(Continuation));
- }
-
- /// The thread pool on which to run the work.
- ThreadPool &Scheduler;
-
- /// State which indicates whether the queue currently is currently processing
- /// any work.
- bool IsTaskInFlight = false;
-
- /// Mutex for synchronizing access to the Tasks array.
- std::mutex QueueLock;
-
- /// Tasks waiting for execution in the queue.
- std::deque<std::function<void()>> Tasks;
-};
-} // namespace llvm
-
-#endif // LLVM_SUPPORT_TASK_QUEUE_H
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Support/raw_sha1_ostream.h b/contrib/libs/llvm12/include/llvm/Support/raw_sha1_ostream.h
deleted file mode 100644
index abce6b2e73d..00000000000
--- a/contrib/libs/llvm12/include/llvm/Support/raw_sha1_ostream.h
+++ /dev/null
@@ -1,57 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//==- raw_sha1_ostream.h - raw_ostream that compute SHA1 --*- C++ -*-==//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the raw_sha1_ostream class.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_SUPPORT_RAW_SHA1_OSTREAM_H
-#define LLVM_SUPPORT_RAW_SHA1_OSTREAM_H
-
-#include "llvm/ADT/ArrayRef.h"
-#include "llvm/Support/SHA1.h"
-#include "llvm/Support/raw_ostream.h"
-
-namespace llvm {
-
-/// A raw_ostream that hash the content using the sha1 algorithm.
-class raw_sha1_ostream : public raw_ostream {
- SHA1 State;
-
- /// See raw_ostream::write_impl.
- void write_impl(const char *Ptr, size_t Size) override {
- State.update(ArrayRef<uint8_t>((const uint8_t *)Ptr, Size));
- }
-
-public:
- /// Return the current SHA1 hash for the content of the stream
- StringRef sha1() {
- flush();
- return State.result();
- }
-
- /// Reset the internal state to start over from scratch.
- void resetHash() { State.init(); }
-
- uint64_t current_pos() const override { return 0; }
-};
-
-} // end llvm namespace
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/TableGen/Automaton.td b/contrib/libs/llvm12/include/llvm/TableGen/Automaton.td
deleted file mode 100644
index 13ced2a0e78..00000000000
--- a/contrib/libs/llvm12/include/llvm/TableGen/Automaton.td
+++ /dev/null
@@ -1,95 +0,0 @@
-//===- Automaton.td ----------------------------------------*- tablegen -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-//
-// This file defines the key top-level classes needed to produce a reasonably
-// generic finite-state automaton.
-//
-//===----------------------------------------------------------------------===//
-
-// Define a record inheriting from GenericAutomaton to generate a reasonably
-// generic finite-state automaton over a set of actions and states.
-//
-// This automaton is defined by:
-// 1) a state space (explicit, always bits<32>).
-// 2) a set of input symbols (actions, explicit) and
-// 3) a transition function from state + action -> state.
-//
-// A theoretical automaton is defined by <Q, S, d, q0, F>:
-// Q: A set of possible states.
-// S: (sigma) The input alphabet.
-// d: (delta) The transition function f(q in Q, s in S) -> q' in Q.
-// F: The set of final (accepting) states.
-//
-// Because generating all possible states is tedious, we instead define the
-// transition function only and crawl all reachable states starting from the
-// initial state with all inputs under all transitions until termination.
-//
-// We define F = S, that is, all valid states are accepting.
-//
-// To ensure the generation of the automaton terminates, the state transitions
-// are defined as a lattice (meaning every transitioned-to state is more
-// specific than the transitioned-from state, for some definition of specificity).
-// Concretely a transition may set one or more bits in the state that were
-// previously zero to one. If any bit was not zero, the transition is invalid.
-//
-// Instead of defining all possible states (which would be cumbersome), the user
-// provides a set of possible Transitions from state A, consuming an input
-// symbol A to state B. The Transition object transforms state A to state B and
-// acts as a predicate. This means the state space can be discovered by crawling
-// all the possible transitions until none are valid.
-//
-// This automaton is considered to be nondeterministic, meaning that multiple
-// transitions can occur from any (state, action) pair. The generated automaton
-// is determinized, meaning that is executes in O(k) time where k is the input
-// sequence length.
-//
-// In addition to a generated automaton that determines if a sequence of inputs
-// is accepted or not, a table is emitted that allows determining a plausible
-// sequence of states traversed to accept that input.
-class GenericAutomaton {
- // Name of a class that inherits from Transition. All records inheriting from
- // this class will be considered when constructing the automaton.
- string TransitionClass;
-
- // Names of fields within TransitionClass that define the action symbol. This
- // defines the action as an N-tuple.
- //
- // Each symbol field can be of class, int, string or code type.
- // If the type of a field is a class, the Record's name is used verbatim
- // in C++ and the class name is used as the C++ type name.
- // If the type of a field is a string, code or int, that is also used
- // verbatim in C++.
- //
- // To override the C++ type name for field F, define a field called TypeOf_F.
- // This should be a string that will be used verbatim in C++.
- //
- // As an example, to define a 2-tuple with an enum and a string, one might:
- // def MyTransition : Transition {
- // MyEnum S1;
- // int S2;
- // }
- // def MyAutomaton : GenericAutomaton }{
- // let TransitionClass = "Transition";
- // let SymbolFields = ["S1", "S2"];
- // let TypeOf_S1 = "MyEnumInCxxKind";
- // }
- list<string> SymbolFields;
-}
-
-// All transitions inherit from Transition.
-class Transition {
- // A transition S' = T(S) is valid if, for every set bit in NewState, the
- // corresponding bit in S is clear. That is:
- // def T(S):
- // S' = S | NewState
- // return S' if S' != S else Failure
- //
- // The automaton generator uses this property to crawl the set of possible
- // transitions from a starting state of 0b0.
- bits<32> NewState;
-}
diff --git a/contrib/libs/llvm12/include/llvm/Testing/Support/Annotations.h b/contrib/libs/llvm12/include/llvm/Testing/Support/Annotations.h
deleted file mode 100644
index 14384efbca6..00000000000
--- a/contrib/libs/llvm12/include/llvm/Testing/Support/Annotations.h
+++ /dev/null
@@ -1,103 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===--- Annotations.h - Annotated source code for tests ---------*- C++-*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-#ifndef LLVM_TESTING_SUPPORT_ANNOTATIONS_H
-#define LLVM_TESTING_SUPPORT_ANNOTATIONS_H
-
-#include "llvm/ADT/SmallVector.h"
-#include "llvm/ADT/StringMap.h"
-#include "llvm/ADT/StringRef.h"
-#include <tuple>
-#include <vector>
-
-namespace llvm {
-
-/// Annotations lets you mark points and ranges inside source code, for tests:
-///
-/// Annotations Example(R"cpp(
-/// int complete() { x.pri^ } // ^ indicates a point
-/// void err() { [["hello" == 42]]; } // [[this is a range]]
-/// $definition^class Foo{}; // points can be named: "definition"
-/// $fail[[static_assert(false, "")]] // ranges can be named too: "fail"
-/// )cpp");
-///
-/// StringRef Code = Example.code(); // annotations stripped.
-/// std::vector<size_t> PP = Example.points(); // all unnamed points
-/// size_t P = Example.point(); // there must be exactly one
-/// llvm::Range R = Example.range("fail"); // find named ranges
-///
-/// Points/ranges are coordinated into `code()` which is stripped of
-/// annotations.
-///
-/// Ranges may be nested (and points can be inside ranges), but there's no way
-/// to define general overlapping ranges.
-///
-/// FIXME: the choice of the marking syntax makes it impossible to represent
-/// some of the C++ and Objective C constructs (including common ones
-/// like C++ attributes). We can fix this by:
-/// 1. introducing an escaping mechanism for the special characters,
-/// 2. making characters for marking points and ranges configurable,
-/// 3. changing the syntax to something less commonly used,
-/// 4. ...
-class Annotations {
-public:
- /// Two offsets pointing to a continuous substring. End is not included, i.e.
- /// represents a half-open range.
- struct Range {
- size_t Begin = 0;
- size_t End = 0;
-
- friend bool operator==(const Range &L, const Range &R) {
- return std::tie(L.Begin, L.End) == std::tie(R.Begin, R.End);
- }
- friend bool operator!=(const Range &L, const Range &R) { return !(L == R); }
- };
-
- /// Parses the annotations from Text. Crashes if it's malformed.
- Annotations(llvm::StringRef Text);
-
- /// The input text with all annotations stripped.
- /// All points and ranges are relative to this stripped text.
- llvm::StringRef code() const { return Code; }
-
- /// Returns the position of the point marked by ^ (or $name^) in the text.
- /// Crashes if there isn't exactly one.
- size_t point(llvm::StringRef Name = "") const;
- /// Returns the position of all points marked by ^ (or $name^) in the text.
- /// Order matches the order within the text.
- std::vector<size_t> points(llvm::StringRef Name = "") const;
-
- /// Returns the location of the range marked by [[ ]] (or $name[[ ]]).
- /// Crashes if there isn't exactly one.
- Range range(llvm::StringRef Name = "") const;
- /// Returns the location of all ranges marked by [[ ]] (or $name[[ ]]).
- /// They are ordered by start position within the text.
- std::vector<Range> ranges(llvm::StringRef Name = "") const;
-
-private:
- std::string Code;
- llvm::StringMap<llvm::SmallVector<size_t, 1>> Points;
- llvm::StringMap<llvm::SmallVector<Range, 1>> Ranges;
-};
-
-llvm::raw_ostream &operator<<(llvm::raw_ostream &O,
- const llvm::Annotations::Range &R);
-
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Testing/Support/Error.h b/contrib/libs/llvm12/include/llvm/Testing/Support/Error.h
deleted file mode 100644
index 0b3f2fb7e64..00000000000
--- a/contrib/libs/llvm12/include/llvm/Testing/Support/Error.h
+++ /dev/null
@@ -1,217 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- llvm/Testing/Support/Error.h ---------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_TESTING_SUPPORT_ERROR_H
-#define LLVM_TESTING_SUPPORT_ERROR_H
-
-#include "llvm/ADT/Optional.h"
-#include "llvm/Support/Error.h"
-#include "llvm/Testing/Support/SupportHelpers.h"
-
-#include "gmock/gmock.h"
-#include <ostream>
-
-namespace llvm {
-namespace detail {
-ErrorHolder TakeError(Error Err);
-
-template <typename T> ExpectedHolder<T> TakeExpected(Expected<T> &Exp) {
- return {TakeError(Exp.takeError()), Exp};
-}
-
-template <typename T> ExpectedHolder<T> TakeExpected(Expected<T> &&Exp) {
- return TakeExpected(Exp);
-}
-
-template <typename T>
-class ValueMatchesMono
- : public testing::MatcherInterface<const ExpectedHolder<T> &> {
-public:
- explicit ValueMatchesMono(const testing::Matcher<T> &Matcher)
- : Matcher(Matcher) {}
-
- bool MatchAndExplain(const ExpectedHolder<T> &Holder,
- testing::MatchResultListener *listener) const override {
- if (!Holder.Success())
- return false;
-
- bool result = Matcher.MatchAndExplain(*Holder.Exp, listener);
-
- if (result)
- return result;
- *listener << "(";
- Matcher.DescribeNegationTo(listener->stream());
- *listener << ")";
- return result;
- }
-
- void DescribeTo(std::ostream *OS) const override {
- *OS << "succeeded with value (";
- Matcher.DescribeTo(OS);
- *OS << ")";
- }
-
- void DescribeNegationTo(std::ostream *OS) const override {
- *OS << "did not succeed or value (";
- Matcher.DescribeNegationTo(OS);
- *OS << ")";
- }
-
-private:
- testing::Matcher<T> Matcher;
-};
-
-template<typename M>
-class ValueMatchesPoly {
-public:
- explicit ValueMatchesPoly(const M &Matcher) : Matcher(Matcher) {}
-
- template <typename T>
- operator testing::Matcher<const ExpectedHolder<T> &>() const {
- return MakeMatcher(
- new ValueMatchesMono<T>(testing::SafeMatcherCast<T>(Matcher)));
- }
-
-private:
- M Matcher;
-};
-
-template <typename InfoT>
-class ErrorMatchesMono : public testing::MatcherInterface<const ErrorHolder &> {
-public:
- explicit ErrorMatchesMono(Optional<testing::Matcher<InfoT &>> Matcher)
- : Matcher(std::move(Matcher)) {}
-
- bool MatchAndExplain(const ErrorHolder &Holder,
- testing::MatchResultListener *listener) const override {
- if (Holder.Success())
- return false;
-
- if (Holder.Infos.size() > 1) {
- *listener << "multiple errors";
- return false;
- }
-
- auto &Info = *Holder.Infos[0];
- if (!Info.isA<InfoT>()) {
- *listener << "Error was not of given type";
- return false;
- }
-
- if (!Matcher)
- return true;
-
- return Matcher->MatchAndExplain(static_cast<InfoT &>(Info), listener);
- }
-
- void DescribeTo(std::ostream *OS) const override {
- *OS << "failed with Error of given type";
- if (Matcher) {
- *OS << " and the error ";
- Matcher->DescribeTo(OS);
- }
- }
-
- void DescribeNegationTo(std::ostream *OS) const override {
- *OS << "succeeded or did not fail with the error of given type";
- if (Matcher) {
- *OS << " or the error ";
- Matcher->DescribeNegationTo(OS);
- }
- }
-
-private:
- Optional<testing::Matcher<InfoT &>> Matcher;
-};
-
-class ErrorMessageMatches
- : public testing::MatcherInterface<const ErrorHolder &> {
-public:
- explicit ErrorMessageMatches(
- testing::Matcher<std::vector<std::string>> Matcher)
- : Matcher(std::move(Matcher)) {}
-
- bool MatchAndExplain(const ErrorHolder &Holder,
- testing::MatchResultListener *listener) const override {
- std::vector<std::string> Messages;
- for (const std::shared_ptr<ErrorInfoBase> &Info: Holder.Infos)
- Messages.push_back(Info->message());
-
- return Matcher.MatchAndExplain(Messages, listener);
- }
-
- void DescribeTo(std::ostream *OS) const override {
- *OS << "failed with Error whose message ";
- Matcher.DescribeTo(OS);
- }
-
- void DescribeNegationTo(std::ostream *OS) const override {
- *OS << "failed with an Error whose message ";
- Matcher.DescribeNegationTo(OS);
- }
-
-private:
- testing::Matcher<std::vector<std::string>> Matcher;
-};
-} // namespace detail
-
-#define EXPECT_THAT_ERROR(Err, Matcher) \
- EXPECT_THAT(llvm::detail::TakeError(Err), Matcher)
-#define ASSERT_THAT_ERROR(Err, Matcher) \
- ASSERT_THAT(llvm::detail::TakeError(Err), Matcher)
-
-#define EXPECT_THAT_EXPECTED(Err, Matcher) \
- EXPECT_THAT(llvm::detail::TakeExpected(Err), Matcher)
-#define ASSERT_THAT_EXPECTED(Err, Matcher) \
- ASSERT_THAT(llvm::detail::TakeExpected(Err), Matcher)
-
-MATCHER(Succeeded, "") { return arg.Success(); }
-MATCHER(Failed, "") { return !arg.Success(); }
-
-template <typename InfoT>
-testing::Matcher<const detail::ErrorHolder &> Failed() {
- return MakeMatcher(new detail::ErrorMatchesMono<InfoT>(None));
-}
-
-template <typename InfoT, typename M>
-testing::Matcher<const detail::ErrorHolder &> Failed(M Matcher) {
- return MakeMatcher(new detail::ErrorMatchesMono<InfoT>(
- testing::SafeMatcherCast<InfoT &>(Matcher)));
-}
-
-template <typename... M>
-testing::Matcher<const detail::ErrorHolder &> FailedWithMessage(M... Matcher) {
- static_assert(sizeof...(M) > 0, "");
- return MakeMatcher(
- new detail::ErrorMessageMatches(testing::ElementsAre(Matcher...)));
-}
-
-template <typename M>
-testing::Matcher<const detail::ErrorHolder &> FailedWithMessageArray(M Matcher) {
- return MakeMatcher(new detail::ErrorMessageMatches(Matcher));
-}
-
-template <typename M>
-detail::ValueMatchesPoly<M> HasValue(M Matcher) {
- return detail::ValueMatchesPoly<M>(Matcher);
-}
-
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/Testing/Support/SupportHelpers.h b/contrib/libs/llvm12/include/llvm/Testing/Support/SupportHelpers.h
deleted file mode 100644
index fd732dd15f2..00000000000
--- a/contrib/libs/llvm12/include/llvm/Testing/Support/SupportHelpers.h
+++ /dev/null
@@ -1,259 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- Testing/Support/SupportHelpers.h -----------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLVM_TESTING_SUPPORT_SUPPORTHELPERS_H
-#define LLVM_TESTING_SUPPORT_SUPPORTHELPERS_H
-
-#include "llvm/ADT/Optional.h"
-#include "llvm/ADT/SmallString.h"
-#include "llvm/Support/Error.h"
-#include "llvm/Support/FileSystem.h"
-#include "llvm/Support/Path.h"
-#include "llvm/Support/raw_os_ostream.h"
-#include "gmock/gmock-matchers.h"
-#include "gtest/gtest-printers.h"
-
-#include <string>
-
-namespace llvm {
-namespace detail {
-struct ErrorHolder {
- std::vector<std::shared_ptr<ErrorInfoBase>> Infos;
-
- bool Success() const { return Infos.empty(); }
-};
-
-template <typename T> struct ExpectedHolder : public ErrorHolder {
- ExpectedHolder(ErrorHolder Err, Expected<T> &Exp)
- : ErrorHolder(std::move(Err)), Exp(Exp) {}
-
- Expected<T> &Exp;
-};
-
-inline void PrintTo(const ErrorHolder &Err, std::ostream *Out) {
- raw_os_ostream OS(*Out);
- OS << (Err.Success() ? "succeeded" : "failed");
- if (!Err.Success()) {
- const char *Delim = " (";
- for (const auto &Info : Err.Infos) {
- OS << Delim;
- Delim = "; ";
- Info->log(OS);
- }
- OS << ")";
- }
-}
-
-template <typename T>
-void PrintTo(const ExpectedHolder<T> &Item, std::ostream *Out) {
- if (Item.Success()) {
- *Out << "succeeded with value " << ::testing::PrintToString(*Item.Exp);
- } else {
- PrintTo(static_cast<const ErrorHolder &>(Item), Out);
- }
-}
-
-template <class InnerMatcher> class ValueIsMatcher {
-public:
- explicit ValueIsMatcher(InnerMatcher ValueMatcher)
- : ValueMatcher(ValueMatcher) {}
-
- template <class T>
- operator ::testing::Matcher<const llvm::Optional<T> &>() const {
- return ::testing::MakeMatcher(
- new Impl<T>(::testing::SafeMatcherCast<T>(ValueMatcher)));
- }
-
- template <class T>
- class Impl : public ::testing::MatcherInterface<const llvm::Optional<T> &> {
- public:
- explicit Impl(const ::testing::Matcher<T> &ValueMatcher)
- : ValueMatcher(ValueMatcher) {}
-
- bool MatchAndExplain(const llvm::Optional<T> &Input,
- testing::MatchResultListener *L) const override {
- return Input && ValueMatcher.MatchAndExplain(Input.getValue(), L);
- }
-
- void DescribeTo(std::ostream *OS) const override {
- *OS << "has a value that ";
- ValueMatcher.DescribeTo(OS);
- }
- void DescribeNegationTo(std::ostream *OS) const override {
- *OS << "does not have a value that ";
- ValueMatcher.DescribeTo(OS);
- }
-
- private:
- testing::Matcher<T> ValueMatcher;
- };
-
-private:
- InnerMatcher ValueMatcher;
-};
-} // namespace detail
-
-/// Matches an llvm::Optional<T> with a value that conforms to an inner matcher.
-/// To match llvm::None you could use Eq(llvm::None).
-template <class InnerMatcher>
-detail::ValueIsMatcher<InnerMatcher> ValueIs(const InnerMatcher &ValueMatcher) {
- return detail::ValueIsMatcher<InnerMatcher>(ValueMatcher);
-}
-namespace unittest {
-
-SmallString<128> getInputFileDirectory(const char *Argv0);
-
-/// A RAII object that creates a temporary directory upon initialization and
-/// removes it upon destruction.
-class TempDir {
- SmallString<128> Path;
-
-public:
- /// Creates a managed temporary directory.
- ///
- /// @param Name The name of the directory to create.
- /// @param Unique If true, the directory will be created using
- /// llvm::sys::fs::createUniqueDirectory.
- explicit TempDir(StringRef Name, bool Unique = false) {
- std::error_code EC;
- if (Unique) {
- EC = llvm::sys::fs::createUniqueDirectory(Name, Path);
- if (!EC) {
- // Resolve any symlinks in the new directory.
- std::string UnresolvedPath(Path.str());
- EC = llvm::sys::fs::real_path(UnresolvedPath, Path);
- }
- } else {
- Path = Name;
- EC = llvm::sys::fs::create_directory(Path);
- }
- if (EC)
- Path.clear();
- EXPECT_FALSE(EC) << EC.message();
- }
-
- ~TempDir() {
- if (!Path.empty()) {
- EXPECT_FALSE(llvm::sys::fs::remove_directories(Path.str()));
- }
- }
-
- TempDir(const TempDir &) = delete;
- TempDir &operator=(const TempDir &) = delete;
-
- TempDir(TempDir &&) = default;
- TempDir &operator=(TempDir &&) = default;
-
- /// The path to the temporary directory.
- StringRef path() const { return Path; }
-
- /// The null-terminated C string pointing to the path.
- const char *c_str() { return Path.c_str(); }
-
- /// Creates a new path by appending the argument to the path of the managed
- /// directory using the native path separator.
- SmallString<128> path(StringRef component) const {
- SmallString<128> Result(Path);
- SmallString<128> ComponentToAppend(component);
- llvm::sys::path::native(ComponentToAppend);
- llvm::sys::path::append(Result, Twine(ComponentToAppend));
- return Result;
- }
-};
-
-/// A RAII object that creates a link upon initialization and
-/// removes it upon destruction.
-///
-/// The link may be a soft or a hard link, depending on the platform.
-class TempLink {
- SmallString<128> Path;
-
-public:
- /// Creates a managed link at path Link pointing to Target.
- TempLink(StringRef Target, StringRef Link) {
- Path = Link;
- std::error_code EC = sys::fs::create_link(Target, Link);
- if (EC)
- Path.clear();
- EXPECT_FALSE(EC);
- }
- ~TempLink() {
- if (!Path.empty()) {
- EXPECT_FALSE(llvm::sys::fs::remove(Path.str()));
- }
- }
-
- TempLink(const TempLink &) = delete;
- TempLink &operator=(const TempLink &) = delete;
-
- TempLink(TempLink &&) = default;
- TempLink &operator=(TempLink &&) = default;
-
- /// The path to the link.
- StringRef path() const { return Path; }
-};
-
-/// A RAII object that creates a file upon initialization and
-/// removes it upon destruction.
-class TempFile {
- SmallString<128> Path;
-
-public:
- /// Creates a managed file.
- ///
- /// @param Name The name of the file to create.
- /// @param Contents The string to write to the file.
- /// @param Unique If true, the file will be created using
- /// llvm::sys::fs::createTemporaryFile.
- TempFile(StringRef Name, StringRef Suffix = "", StringRef Contents = "",
- bool Unique = false) {
- std::error_code EC;
- int fd;
- if (Unique) {
- EC = llvm::sys::fs::createTemporaryFile(Name, Suffix, fd, Path);
- } else {
- Path = Name;
- if (!Suffix.empty()) {
- Path.append(".");
- Path.append(Suffix);
- }
- EC = llvm::sys::fs::openFileForWrite(Path, fd);
- }
- EXPECT_FALSE(EC);
- raw_fd_ostream OS(fd, /*shouldClose*/ true);
- OS << Contents;
- OS.flush();
- EXPECT_FALSE(OS.error());
- if (EC || OS.error())
- Path.clear();
- }
- ~TempFile() {
- if (!Path.empty()) {
- EXPECT_FALSE(llvm::sys::fs::remove(Path.str()));
- }
- }
-
- /// The path to the file.
- StringRef path() const { return Path; }
-};
-
-} // namespace unittest
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceProcessor.h b/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceProcessor.h
deleted file mode 100644
index b2c81d95966..00000000000
--- a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceProcessor.h
+++ /dev/null
@@ -1,61 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- ResourceProcessor.h -------------------------------------*- C++-*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===---------------------------------------------------------------------===//
-
-#ifndef LLVM_INCLUDE_LLVM_SUPPORT_WINDOWS_RESOURCE_PROCESSOR_H
-#define LLVM_INCLUDE_LLVM_SUPPORT_WINDOWS_RESOURCE_PROCESSOR_H
-
-#include "llvm/ADT/StringMap.h"
-#include "llvm/ADT/StringRef.h"
-#include "llvm/Support/Error.h"
-#include "llvm/Support/raw_ostream.h"
-
-#include <memory>
-#include <vector>
-
-
-namespace llvm {
-
-class WindowsResourceProcessor {
-public:
- using PathType = SmallVector<char, 64>;
-
- WindowsResourceProcessor() {}
-
- void addDefine(StringRef Key, StringRef Value = StringRef()) {
- PreprocessorDefines.emplace_back(Key, Value);
- }
- void addInclude(const PathType &IncludePath) {
- IncludeList.push_back(IncludePath);
- }
- void setVerbose(bool Verbose) { IsVerbose = Verbose; }
- void setNullAtEnd(bool NullAtEnd) { AppendNull = NullAtEnd; }
-
- Error process(StringRef InputData,
- std::unique_ptr<raw_fd_ostream> OutputStream);
-
-private:
- StringRef InputData;
- std::vector<PathType> IncludeList;
- std::vector<std::pair<StringRef, StringRef>> PreprocessorDefines;
- bool IsVerbose, AppendNull;
-};
-
-}
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptToken.h b/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptToken.h
deleted file mode 100644
index 42026a83288..00000000000
--- a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptToken.h
+++ /dev/null
@@ -1,69 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- ResourceScriptToken.h -----------------------------------*- C++-*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===---------------------------------------------------------------------===//
-//
-// This declares the .rc script tokens.
-// The list of available tokens is located at ResourceScriptTokenList.h.
-//
-// Ref: msdn.microsoft.com/en-us/library/windows/desktop/aa380599(v=vs.85).aspx
-//
-//===---------------------------------------------------------------------===//
-
-#ifndef LLVM_INCLUDE_LLVM_SUPPORT_WINDOWS_RESOURCE_SCRIPTTOKEN_H
-#define LLVM_INCLUDE_LLVM_SUPPORT_WINDOWS_RESOURCE_SCRIPTTOKEN_H
-
-#include "llvm/ADT/StringRef.h"
-
-namespace llvm {
-
-// A definition of a single resource script token. Each token has its kind
-// (declared in ResourceScriptTokenList) and holds a value - a reference
-// representation of the token.
-// RCToken does not claim ownership on its value. A memory buffer containing
-// the token value should be stored in a safe place and cannot be freed
-// nor reallocated.
-class RCToken {
-public:
- enum class Kind {
-#define TOKEN(Name) Name,
-#define SHORT_TOKEN(Name, Ch) Name,
-#include "ResourceScriptTokenList.h"
-#undef TOKEN
-#undef SHORT_TOKEN
- };
-
- RCToken(RCToken::Kind RCTokenKind, StringRef Value);
-
- // Get an integer value of the integer token.
- uint32_t intValue() const;
- bool isLongInt() const;
-
- StringRef value() const;
- Kind kind() const;
-
- // Check if a token describes a binary operator.
- bool isBinaryOp() const;
-
-private:
- Kind TokenKind;
- StringRef TokenValue;
-};
-
-} // namespace llvm
-
-#endif
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptTokenList.h b/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptTokenList.h
deleted file mode 100644
index 3e19b83fe62..00000000000
--- a/contrib/libs/llvm12/include/llvm/WindowsResource/ResourceScriptTokenList.h
+++ /dev/null
@@ -1,45 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===-- ResourceScriptTokenList.h -------------------------------*- C++-*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===---------------------------------------------------------------------===//
-//
-// This is a part of llvm-rc tokens header. It lists all the possible tokens
-// that might occur in a correct .rc script.
-//
-//===---------------------------------------------------------------------===//
-
-
-// Long tokens. They might consist of more than one character.
-TOKEN(Invalid) // Invalid token. Should not occur in a valid script.
-TOKEN(Int) // Integer (decimal, octal or hexadecimal).
-TOKEN(String) // String value.
-TOKEN(Identifier) // Script identifier (resource name or type).
-
-// Short tokens. They usually consist of exactly one character.
-// The definitions are of the form SHORT_TOKEN(TokenName, TokenChar).
-// TokenChar is the one-character token representation occuring in the correct
-// .rc scripts.
-SHORT_TOKEN(BlockBegin, '{') // Start of the script block; can also be BEGIN.
-SHORT_TOKEN(BlockEnd, '}') // End of the block; can also be END.
-SHORT_TOKEN(Comma, ',') // Comma - resource arguments separator.
-SHORT_TOKEN(Plus, '+') // Addition operator.
-SHORT_TOKEN(Minus, '-') // Subtraction operator.
-SHORT_TOKEN(Pipe, '|') // Bitwise-OR operator.
-SHORT_TOKEN(Amp, '&') // Bitwise-AND operator.
-SHORT_TOKEN(Tilde, '~') // Bitwise-NOT operator.
-SHORT_TOKEN(LeftParen, '(') // Left parenthesis in the script expressions.
-SHORT_TOKEN(RightParen, ')') // Right parenthesis.
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/XRay/FDRLogBuilder.h b/contrib/libs/llvm12/include/llvm/XRay/FDRLogBuilder.h
deleted file mode 100644
index f1305fceda8..00000000000
--- a/contrib/libs/llvm12/include/llvm/XRay/FDRLogBuilder.h
+++ /dev/null
@@ -1,51 +0,0 @@
-#pragma once
-
-#ifdef __GNUC__
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wunused-parameter"
-#endif
-
-//===- FDRLogBuilder.h - XRay FDR Log Building Utility --------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-#ifndef LLVM_INCLUDE_LLVM_XRAY_FDRLOGBUILDER_H_
-#define LLVM_INCLUDE_LLVM_XRAY_FDRLOGBUILDER_H_
-
-#include "llvm/XRay/FDRRecords.h"
-
-namespace llvm {
-namespace xray {
-
-/// The LogBuilder class allows for creating ad-hoc collections of records
-/// through the `add<...>(...)` function. An example use of this API is in
-/// crafting arbitrary sequences of records:
-///
-/// auto Records = LogBuilder()
-/// .add<BufferExtents>(256)
-/// .add<NewBufferRecord>(1)
-/// .consume();
-///
-class LogBuilder {
- std::vector<std::unique_ptr<Record>> Records;
-
-public:
- template <class R, class... T> LogBuilder &add(T &&... A) {
- Records.emplace_back(new R(std::forward<T>(A)...));
- return *this;
- }
-
- std::vector<std::unique_ptr<Record>> consume() { return std::move(Records); }
-};
-
-} // namespace xray
-} // namespace llvm
-
-#endif // LLVM_INCLUDE_LLVM_XRAY_FDRLOGBUILDER_H_
-
-#ifdef __GNUC__
-#pragma GCC diagnostic pop
-#endif
diff --git a/contrib/libs/llvm12/include/llvm/module.extern.modulemap b/contrib/libs/llvm12/include/llvm/module.extern.modulemap
deleted file mode 100644
index 8acda137e04..00000000000
--- a/contrib/libs/llvm12/include/llvm/module.extern.modulemap
+++ /dev/null
@@ -1,5 +0,0 @@
-module LLVM_Extern_Config_Def {}
-module LLVM_Extern_IR_Attributes_Gen {}
-module LLVM_Extern_IR_Intrinsics_Gen {}
-module LLVM_Extern_IR_Intrinsics_Enum {}
-module LLVM_Extern_Utils_DataTypes {}
diff --git a/contrib/libs/llvm12/include/llvm/module.modulemap b/contrib/libs/llvm12/include/llvm/module.modulemap
deleted file mode 100644
index a199f7f2d79..00000000000
--- a/contrib/libs/llvm12/include/llvm/module.modulemap
+++ /dev/null
@@ -1,436 +0,0 @@
-module LLVM_Analysis {
- requires cplusplus
- umbrella "Analysis"
- module * { export * }
-
- // This is intended for (repeated) textual inclusion.
- textual header "Analysis/TargetLibraryInfo.def"
- textual header "Analysis/VecFuncs.def"
-}
-
-module LLVM_AsmParser {
- requires cplusplus
- umbrella "AsmParser"
- module * { export * }
-}
-
-// A module covering CodeGen/ and Target/. These are intertwined
-// and codependent, and thus notionally form a single module.
-module LLVM_Backend {
- requires cplusplus
-
- module CodeGen {
- umbrella "CodeGen"
- module * { export * }
-
- // Exclude these; they're intended to be included into only a single
- // translation unit (or none) and aren't part of this module.
- exclude header "CodeGen/LinkAllAsmWriterComponents.h"
- exclude header "CodeGen/LinkAllCodegenComponents.h"
-
- // These are intended for (repeated) textual inclusion.
- textual header "CodeGen/DIEValue.def"
- textual header "CodeGen/MachinePassRegistry.def"
- }
-}
-
-// FIXME: Make this as a submodule of LLVM_Backend again.
-// Doing so causes a linker error in clang-format.
-module LLVM_Backend_Target {
- umbrella "Target"
- module * { export * }
-}
-
-module LLVM_Bitcode {
- requires cplusplus
- umbrella "Bitcode"
- module * { export * }
-}
-
-module LLVM_Bitstream {
- requires cplusplus
- umbrella "Bitstream"
- module * { export * }
-}
-
-module LLVM_BinaryFormat {
- requires cplusplus
- umbrella "BinaryFormat" module * { export * }
- textual header "BinaryFormat/Dwarf.def"
- textual header "BinaryFormat/DynamicTags.def"
- textual header "BinaryFormat/MachO.def"
- textual header "BinaryFormat/MinidumpConstants.def"
- textual header "BinaryFormat/ELFRelocs/AArch64.def"
- textual header "BinaryFormat/ELFRelocs/AMDGPU.def"
- textual header "BinaryFormat/ELFRelocs/ARM.def"
- textual header "BinaryFormat/ELFRelocs/ARC.def"
- textual header "BinaryFormat/ELFRelocs/AVR.def"
- textual header "BinaryFormat/ELFRelocs/BPF.def"
- textual header "BinaryFormat/ELFRelocs/CSKY.def"
- textual header "BinaryFormat/ELFRelocs/Hexagon.def"
- textual header "BinaryFormat/ELFRelocs/i386.def"
- textual header "BinaryFormat/ELFRelocs/Lanai.def"
- textual header "BinaryFormat/ELFRelocs/Mips.def"
- textual header "BinaryFormat/ELFRelocs/MSP430.def"
- textual header "BinaryFormat/ELFRelocs/PowerPC64.def"
- textual header "BinaryFormat/ELFRelocs/PowerPC.def"
- textual header "BinaryFormat/ELFRelocs/RISCV.def"
- textual header "BinaryFormat/ELFRelocs/Sparc.def"
- textual header "BinaryFormat/ELFRelocs/SystemZ.def"
- textual header "BinaryFormat/ELFRelocs/VE.def"
- textual header "BinaryFormat/ELFRelocs/x86_64.def"
- textual header "BinaryFormat/WasmRelocs.def"
- textual header "BinaryFormat/MsgPack.def"
-}
-
-module LLVM_Config {
- requires cplusplus
- umbrella "Config"
- extern module LLVM_Extern_Config_Def "module.extern.modulemap"
- module * { export * }
-}
-
-module LLVM_DebugInfo {
- requires cplusplus
- module DIContext { header "DebugInfo/DIContext.h" export * }
-}
-
-module LLVM_DebugInfo_DWARF {
- requires cplusplus
-
- umbrella "DebugInfo/DWARF"
- module * { export * }
-}
-
-module LLVM_DebugInfo_PDB {
- requires cplusplus
-
- umbrella "DebugInfo/PDB"
- module * { export * }
-
- // Separate out this subdirectory; it's an optional component that depends on
- // a separate library which might not be available.
- //
- // FIXME: There should be a better way to specify this.
- exclude header "DebugInfo/PDB/DIA/DIADataStream.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumDebugStreams.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumFrameData.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumInjectedSources.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumLineNumbers.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumSectionContribs.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumSourceFiles.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumSymbols.h"
- exclude header "DebugInfo/PDB/DIA/DIAEnumTables.h"
- exclude header "DebugInfo/PDB/DIA/DIAError.h"
- exclude header "DebugInfo/PDB/DIA/DIAFrameData.h"
- exclude header "DebugInfo/PDB/DIA/DIAInjectedSource.h"
- exclude header "DebugInfo/PDB/DIA/DIALineNumber.h"
- exclude header "DebugInfo/PDB/DIA/DIARawSymbol.h"
- exclude header "DebugInfo/PDB/DIA/DIASectionContrib.h"
- exclude header "DebugInfo/PDB/DIA/DIASession.h"
- exclude header "DebugInfo/PDB/DIA/DIASourceFile.h"
- exclude header "DebugInfo/PDB/DIA/DIASupport.h"
- exclude header "DebugInfo/PDB/DIA/DIATable.h"
- exclude header "DebugInfo/PDB/DIA/DIAUtils.h"
-}
-
-module LLVM_DebugInfo_PDB_DIA {
- requires cplusplus
-
- umbrella "DebugInfo/PDB/DIA"
- module * { export * }
-}
-
-module LLVM_DebugInfo_MSF {
- requires cplusplus
-
- umbrella "DebugInfo/MSF"
- module * { export * }
-}
-
-module LLVM_DebugInfo_CodeView {
- requires cplusplus
-
- umbrella "DebugInfo/CodeView"
- module * { export * }
-
- // These are intended for (repeated) textual inclusion.
- textual header "DebugInfo/CodeView/CodeViewRegisters.def"
- textual header "DebugInfo/CodeView/CodeViewTypes.def"
- textual header "DebugInfo/CodeView/CodeViewSymbols.def"
-}
-
-module LLVM_DWARFLinker {
- requires cplusplus
-
- umbrella "DWARFLinker"
- module * { export * }
-}
-
-module LLVM_ExecutionEngine {
- requires cplusplus
-
- umbrella "ExecutionEngine"
- module * { export * }
-
- // Exclude this; it's an optional component of the ExecutionEngine.
- exclude header "ExecutionEngine/OProfileWrapper.h"
-
- // Exclude these; they're intended to be included into only a single
- // translation unit (or none) and aren't part of this module.
- exclude header "ExecutionEngine/MCJIT.h"
- exclude header "ExecutionEngine/Interpreter.h"
- exclude header "ExecutionEngine/OrcMCJITReplacement.h"
-
- // FIXME: These exclude directives were added as a workaround for
- // <rdar://problem/29247092> and should be removed once it is fixed.
- exclude header "ExecutionEngine/Orc/OrcRemoteTargetRPCAPI.h"
- exclude header "ExecutionEngine/Orc/OrcRemoteTargetClient.h"
- exclude header "ExecutionEngine/Orc/OrcRemoteTargetServer.h"
- exclude header "ExecutionEngine/Orc/RemoteObjectLayer.h"
-
- // Exclude headers from LLVM_OrcSupport.
- exclude header "ExecutionEngine/Orc/Shared/OrcError.h"
- exclude header "ExecutionEngine/Orc/RPC/RPCUtils.h"
- exclude header "ExecutionEngine/Orc/RPC/RPCSerialization.h"
- exclude header "ExecutionEngine/Orc/RPC/RawByteChannel.h"
-
-}
-
-module LLVM_FileCheck {
- requires cplusplus
-
- umbrella "FileCheck"
- module * { export * }
-}
-
-// Orc utilities that don't depend only on Support (not ExecutionEngine or
-// IR). This is a workaround for ExecutionEngine's broken layering, and will
-// be removed in the future.
-module LLVM_OrcSupport {
- requires cplusplus
-
- header "ExecutionEngine/Orc/Shared/OrcError.h"
- header "ExecutionEngine/Orc/Shared/RPCUtils.h"
- header "ExecutionEngine/Orc/Shared/Serialization.h"
- header "ExecutionEngine/Orc/Shared/RawByteChannel.h"
-
- export *
-}
-
-module LLVM_Pass {
- module Pass {
- // PassSupport.h and PassAnalysisSupport.h are made available only through
- // Pass.h.
- header "Pass.h"
- textual header "PassSupport.h"
- textual header "PassAnalysisSupport.h"
- export *
- }
-
- module PassRegistry { header "PassRegistry.h" export * }
- module InitializePasses { header "InitializePasses.h" export * }
-}
-
-module LLVM_intrinsic_gen {
- requires cplusplus
-
- // Delay building the modules containing dependencies to Attributes.h and
- // Intrinsics.h because they need to be generated by tablegen first.
-
- // Attributes.h
- module IR_Argument { header "IR/Argument.h" export * }
- module IR_Attributes {
- header "IR/Attributes.h"
- extern module LLVM_Extern_IR_Attributes_Gen "module.extern.modulemap"
- export *
- }
- module IR_AbstractCallSite { header "IR/AbstractCallSite.h" export * }
- module IR_ConstantFolder { header "IR/ConstantFolder.h" export * }
- module IR_GlobalVariable { header "IR/GlobalVariable.h" export * }
- module IR_NoFolder { header "IR/NoFolder.h" export * }
- module IRBuilderFolder { header "IR/IRBuilderFolder.h" export * }
- module IR_Module { header "IR/Module.h" export * }
- module IR_ModuleSummaryIndex { header "IR/ModuleSummaryIndex.h" export * }
- module IR_ModuleSummaryIndexYAML { header "IR/ModuleSummaryIndexYAML.h" export * }
- module IR_Function { header "IR/Function.h" export * }
- module IR_InstrTypes { header "IR/InstrTypes.h" export * }
- module IR_Instructions { header "IR/Instructions.h" export * }
-
-
- // Intrinsics.h
- module IR_CFG { header "IR/CFG.h" export * }
- module IR_ConstantRange { header "IR/ConstantRange.h" export * }
- module IR_Dominators { header "IR/Dominators.h" export * }
- module IR_FixedPointBuilder { header "IR/FixedPointBuilder.h" export * }
- module Analysis_PostDominators { header "Analysis/PostDominators.h" export * }
- module Analysis_DomTreeUpdater { header "Analysis/DomTreeUpdater.h" export * }
- module IR_IRBuilder { header "IR/IRBuilder.h" export * }
- module IR_IRPrintingPasses { header "IR/IRPrintingPasses.h" export * }
- module IR_MatrixBuilder { header "IR/MatrixBuilder.h" export * }
- module IR_PassManager { header "IR/PassManager.h" export * }
- module IR_PassManagerImpl { header "IR/PassManagerImpl.h" export * }
- module IR_PredIteratorCache { header "IR/PredIteratorCache.h" export * }
- module IR_Verifier { header "IR/Verifier.h" export * }
- module IR_InstIterator { header "IR/InstIterator.h" export * }
- module IR_InstVisitor { header "IR/InstVisitor.h" export * }
- module IR_Intrinsics {
- header "IR/Intrinsics.h"
- extern module LLVM_Extern_IR_Intricsics_Gen "module.extern.modulemap"
- extern module LLVM_Extern_IR_Intrinsics_Enum "module.extern.modulemap"
- export *
- }
- module IR_IntrinsicInst { header "IR/IntrinsicInst.h" export * }
- module IR_PatternMatch { header "IR/PatternMatch.h" export * }
- module IR_SafepointIRVerifier { header "IR/SafepointIRVerifier.h" export * }
- module IR_Statepoint { header "IR/Statepoint.h" export * }
-
- export *
-}
-
-module LLVM_IR {
- requires cplusplus
-
- umbrella "IR"
- module * { export * }
-
- // These are intended for (repeated) textual inclusion.
- textual header "IR/ConstrainedOps.def"
- textual header "IR/DebugInfoFlags.def"
- textual header "IR/Instruction.def"
- textual header "IR/Metadata.def"
- textual header "IR/FixedMetadataKinds.def"
- textual header "IR/Value.def"
- textual header "IR/VPIntrinsics.def"
- textual header "IR/RuntimeLibcalls.def"
-}
-
-module LLVM_IRReader {
- requires cplusplus
- umbrella "IRReader"
- module * { export * }
-}
-
-module LLVM_LineEditor {
- requires cplusplus
- umbrella "LineEditor"
- module * { export * }
-}
-
-module LLVM_LTO {
- requires cplusplus
- umbrella "LTO"
- module * { export * }
-}
-
-module LLVM_MC {
- requires cplusplus
-
- umbrella "MC"
- module * { export * }
-}
-
-// Used by llvm-tblgen
-module LLVM_MC_TableGen {
- requires cplusplus
- module MC_LaneBitmask { header "MC/LaneBitmask.h" export * }
- module MC_FixedLenDisassembler { header "MC/MCFixedLenDisassembler.h" export * }
- module MC_InstrItineraries { header "MC/MCInstrItineraries.h" export * }
- module MC_Schedule { header "MC/MCSchedule.h" export * }
- module MC_SubtargetFeature { header "MC/SubtargetFeature.h" export * }
-}
-
-module LLVM_Object {
- requires cplusplus
- umbrella "Object"
- module * { export * }
-}
-
-module LLVM_Option {
- requires cplusplus
- umbrella "Option"
- module * { export * }
-}
-
-module LLVM_ProfileData {
- requires cplusplus
-
- umbrella "ProfileData"
- module * { export * }
-
- textual header "ProfileData/InstrProfData.inc"
-}
-
-// FIXME: Mislayered?
-module LLVM_Support_TargetRegistry {
- requires cplusplus
- header "Support/TargetRegistry.h"
- export *
-}
-
-module LLVM_TableGen {
- requires cplusplus
- umbrella "TableGen"
- module * { export * }
-}
-
-module LLVM_Transforms {
- requires cplusplus
- umbrella "Transforms"
-
- module * { export * }
-}
-
-extern module LLVM_Extern_Utils_DataTypes "module.extern.modulemap"
-
-// A module covering ADT/ and Support/. These are intertwined and
-// codependent, and notionally form a single module.
-module LLVM_Utils {
- module ADT {
- requires cplusplus
-
- umbrella "ADT"
- module * { export * }
- }
-
- module Support {
- requires cplusplus
-
- umbrella "Support"
- module * { export * }
-
- // Exclude this; it should only be used on Windows.
- exclude header "Support/Windows/WindowsSupport.h"
-
- // Exclude these; they are fundamentally non-modular.
- exclude header "Support/PluginLoader.h"
- exclude header "Support/Solaris/sys/regset.h"
-
- // These are intended for textual inclusion.
- textual header "Support/AArch64TargetParser.def"
- textual header "Support/ARMTargetParser.def"
- textual header "Support/RISCVTargetParser.def"
- textual header "Support/TargetOpcodes.def"
- textual header "Support/X86TargetParser.def"
- }
-
- // This part of the module is usable from both C and C++ code.
- module ConvertUTF {
- header "Support/ConvertUTF.h"
- export *
- }
-}
-
-// This is used for a $src == $build compilation. Otherwise we use
-// LLVM_Support_DataTypes_Build, defined in a module map that is
-// copied into the build area.
-module LLVM_Support_DataTypes_Src {
- header "llvm/Support/DataTypes.h"
- export *
-}
-
-module LLVM_WindowsManifest {
- requires cplusplus
- umbrella "WindowsManifest"
- module * { export * }
-}
diff --git a/contrib/libs/llvm12/include/llvm/module.modulemap.build b/contrib/libs/llvm12/include/llvm/module.modulemap.build
deleted file mode 100644
index 162a262a00a..00000000000
--- a/contrib/libs/llvm12/include/llvm/module.modulemap.build
+++ /dev/null
@@ -1,13 +0,0 @@
-// This is copied into the build area for a $src != $build compilation.
-module LLVM_Support_DataTypes {
- header "Support/DataTypes.h"
- export *
-}
-module LLVM_Config_ABI_Breaking {
- header "Config/abi-breaking.h"
- export *
-}
-module LLVM_Config_Config {
- header "Config/llvm-config.h"
- export *
-}