/Users/buildslave/jenkins/workspace/clang-stage2-coverage-R/llvm/lib/Target/AMDGPU/AMDGPUMachineModuleInfo.cpp
Line | Count | Source |
1 | | //===--- AMDGPUMachineModuleInfo.cpp ----------------------------*- C++ -*-===// |
2 | | // |
3 | | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
4 | | // See https://llvm.org/LICENSE.txt for license information. |
5 | | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
6 | | // |
7 | | //===----------------------------------------------------------------------===// |
8 | | // |
9 | | /// \file |
10 | | /// AMDGPU Machine Module Info. |
11 | | /// |
12 | | // |
13 | | //===----------------------------------------------------------------------===// |
14 | | |
15 | | #include "AMDGPUMachineModuleInfo.h" |
16 | | #include "llvm/IR/Module.h" |
17 | | |
18 | | namespace llvm { |
19 | | |
20 | | AMDGPUMachineModuleInfo::AMDGPUMachineModuleInfo(const MachineModuleInfo &MMI) |
21 | 2.37k | : MachineModuleInfoELF(MMI) { |
22 | 2.37k | LLVMContext &CTX = MMI.getModule()->getContext(); |
23 | 2.37k | AgentSSID = CTX.getOrInsertSyncScopeID("agent"); |
24 | 2.37k | WorkgroupSSID = CTX.getOrInsertSyncScopeID("workgroup"); |
25 | 2.37k | WavefrontSSID = CTX.getOrInsertSyncScopeID("wavefront"); |
26 | 2.37k | SystemOneAddressSpaceSSID = |
27 | 2.37k | CTX.getOrInsertSyncScopeID("one-as"); |
28 | 2.37k | AgentOneAddressSpaceSSID = |
29 | 2.37k | CTX.getOrInsertSyncScopeID("agent-one-as"); |
30 | 2.37k | WorkgroupOneAddressSpaceSSID = |
31 | 2.37k | CTX.getOrInsertSyncScopeID("workgroup-one-as"); |
32 | 2.37k | WavefrontOneAddressSpaceSSID = |
33 | 2.37k | CTX.getOrInsertSyncScopeID("wavefront-one-as"); |
34 | 2.37k | SingleThreadOneAddressSpaceSSID = |
35 | 2.37k | CTX.getOrInsertSyncScopeID("singlethread-one-as"); |
36 | 2.37k | } |
37 | | |
38 | | } // end namespace llvm |