aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/AST/Mangle.cpp
AgeCommit message (Collapse)AuthorFilesLines
2025-09-09[clang][Mangle] Inject structor type into mangled name when mangling for ↵Michael Buch1-1/+36
LLDB JIT expressions (#155485) Part of https://github.com/llvm/llvm-project/pull/149827 This patch adds special handling for `AsmLabel`s created by LLDB. LLDB uses `AsmLabel`s to encode information about a function declaration to make it easier to locate function symbols when JITing C++ expressions. For constructors/destructors LLDB doesn't know at the time of creating the `AsmLabelAttr` which structor variant the expression evaluator will need to call (this is decided when compiling the expression). So we make the Clang mangler inject this information into our custom label when we're JITting the expression.
2025-08-04[clang][Attr] Remove 'literal label' form of AsmLabelAttr (#151858)Michael Buch1-2/+2
This was added purely for the needs of LLDB. However, starting with https://github.com/llvm/llvm-project/pull/151355 and https://github.com/llvm/llvm-project/pull/148877 we no longer create literal AsmLabels in LLDB either. So this is unused and we can get rid of it. In the near future LLDB will want to add special support for mangling `AsmLabel`s (specifically https://github.com/llvm/llvm-project/pull/149827).
2025-04-30[clang AST] move mangling API to namespace clang to allow calls from ↵Peter Rong1-10/+27
swift-frontend (#137884) When implementing `@objcDirect` in Swift, Swift needs to mangle a native `Decl` that is not a clang Node, which in turn don't have access to `clang::MangleContext`. Reimplementing mangling logic in Swift is redundant. This patch moves mangling logic from `clang::MangleContext` to `clang` using only basic types (`StringRef`, `std::optional`, etc.), such that Swift can we can just call Clang API: Swift depends on Clang already. We are separating this from #126639 so we can draft the proposal on the Swift side. #126639 will be worked to depend on this PR. Tests: No new tests, old ones should pass with no problem. --------- Signed-off-by: Peter Rong <PeterRong@meta.com>
2025-04-29Fix crash with -ast-dump=json (#137324)Aaron Ballman1-3/+5
When given an invalid Objective-C extension, Clang would crash when trying to emit the mangled name of the method to the JSON dump output. Fixes #137320
2025-04-08[Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (#115821)Aniket Lal1-3/+3
This feature is currently not supported in the compiler. To facilitate this we emit a stub version of each kernel function body with different name mangling scheme, and replaces the respective kernel call-sites appropriately. Fixes https://github.com/llvm/llvm-project/issues/60313 D120566 was an earlier attempt made to upstream a solution for this issue. --------- Co-authored-by: anikelal <anikelal@amd.com>
2025-03-10[Clang] Make `MangleContext::mangleMSGuidDecl()`, ↵Boaz Brickner1-3/+4
`MangleContext::mangleObjCMethodName()` and `MangleContext::mangleObjCMethodNameAsSourceName()` const methods (#130613) Unfortunately, making `MangleContext::mangleName()` would require a lot of const escapes due to lazy initialization and id creations: `Mangle.h`: * https://github.com/llvm/llvm-project/blob/dffbc030e75b758e7512518abd499a0f680addbf/clang/include/clang/AST/Mangle.h#L82-L85 * https://github.com/llvm/llvm-project/blob/dffbc030e75b758e7512518abd499a0f680addbf/clang/include/clang/AST/Mangle.h#L97-L99 `ItaniumMangle.cpp`: * https://github.com/llvm/llvm-project/blob/dffbc030e75b758e7512518abd499a0f680addbf/clang/lib/AST/ItaniumMangle.cpp#L158-L161 * https://github.com/llvm/llvm-project/blob/4508d6aa72b0f31056ae01aff0e8009a252e4683/clang/lib/AST/ItaniumMangle.cpp#L641 `MicrosoftMangle.cpp`: * https://github.com/llvm/llvm-project/blob/dffbc030e75b758e7512518abd499a0f680addbf/clang/lib/AST/MicrosoftMangle.cpp#L243-L245 * https://github.com/llvm/llvm-project/blob/dffbc030e75b758e7512518abd499a0f680addbf/clang/lib/AST/MicrosoftMangle.cpp#L284
2025-03-05[clang] Use TargetInfo to decide Mangling for C (#129920)Prabhuk1-1/+1
Instead of hardcoding the decision on what mangling scheme to use based on targets, use TargetInfo to make the decision.
2024-11-17[AST] Remove unused includes (NFC) (#116549)Kazu Hirata1-3/+2
Identified with misc-include-cleaner.
2024-09-14[clang] Nits on uses of raw_string_ostream (NFC)JOE19941-4/+4
* Don't call raw_string_ostream::flush(), which is essentially a no-op. * Strip unneeded calls to raw_string_ostream::str(), to avoid extra indirection.
2024-06-26 [clang] Implement pointer authentication for C++ virtual functions, ↵Oliver Hunt1-6/+17
v-tables, and VTTs (#94056) Virtual function pointer entries in v-tables are signed with address discrimination in addition to declaration-based discrimination, where an integer discriminator the string hash (see `ptrauth_string_discriminator`) of the mangled name of the overridden method. This notably provides diversity based on the full signature of the overridden method, including the method name and parameter types. This patch introduces ItaniumVTableContext logic to find the original declaration of the overridden method. On AArch64, these pointers are signed using the `IA` key (the process-independent code key.) V-table pointers can be signed with either no discrimination, or a similar scheme using address and decl-based discrimination. In this case, the integer discriminator is the string hash of the mangled v-table identifier of the class that originally introduced the vtable pointer. On AArch64, these pointers are signed using the `DA` key (the process-independent data key.) Not using discrimination allows attackers to simply copy valid v-table pointers from one object to another. However, using a uniform discriminator of 0 does have positive performance and code-size implications on AArch64, and diversity for the most important v-table access pattern (virtual dispatch) is already better assured by the signing schemas used on the virtual functions. It is also known that some code in practice copies objects containing v-tables with `memcpy`, and while this is not permitted formally, it is something that may be invasive to eliminate. This is controlled by: ``` -fptrauth-vtable-pointer-type-discrimination -fptrauth-vtable-pointer-address-discrimination ``` In addition, this provides fine-grained controls in the ptrauth_vtable_pointer attribute, which allows overriding the default ptrauth schema for vtable pointers on a given class hierarchy, e.g.: ``` [[clang::ptrauth_vtable_pointer(no_authentication, no_address_discrimination, no_extra_discrimination)]] [[clang::ptrauth_vtable_pointer(default_key, default_address_discrimination, custom_discrimination, 0xf00d)]] ``` The override is then mangled as a parametrized vendor extension: ``` "__vtptrauth" I <key> <addressDiscriminated> <extraDiscriminator> E ``` To support this attribute, this patch adds a small extension to the attribute-emitter tablegen backend. Note that there are known areas where signing is either missing altogether or can be strengthened. Some will be addressed in later changes (e.g., member function pointers, some RTTI). `dynamic_cast` in particular is handled by emitting an artificial v-table pointer load (in a way that always authenticates it) before the runtime call itself, as the runtime doesn't have enough information today to properly authenticate it. Instead, the runtime is currently expected to strip the v-table pointer. --------- Co-authored-by: John McCall <rjmccall@apple.com> Co-authored-by: Ahmed Bougacha <ahmed@bougacha.org>
2024-06-11[clang] Remove a redundant check in Mangle. NFC (#95071)Pavel Samolysov1-3/+2
This addresses a review comment for PR #94987 Because that PR is a big automatic change, this change was moved in a separate one.
2024-06-11[clang] Replace X && isa<Y>(X) with isa_and_nonnull<Y>(X). NFC (#94987)Pavel Samolysov1-1/+1
This addresses a clang-tidy suggestion.
2024-01-20[clang] Use SmallString::operator std::string (NFC)Kazu Hirata1-1/+1
2023-12-13[clang] Use StringRef::{starts,ends}_with (NFC) (#75149)Kazu Hirata1-1/+1
This patch replaces uses of StringRef::{starts,ends}with with StringRef::{starts,ends}_with for consistency with std::{string,string_view}::{starts,ends}_with in C++20. I'm planning to deprecate and eventually remove StringRef::{starts,ends}with.
2023-10-02[C++] Implement "Deducing this" (P0847R7)Corentin Jabot1-1/+1
This patch implements P0847R7 (partially), CWG2561 and CWG2653. Reviewed By: aaron.ballman, #clang-language-wg Differential Revision: https://reviews.llvm.org/D140828
2023-08-03[X86][Regcall] Add an option to respect regcall ABI v.4 in win64&win32Bing1 Yu1-2/+6
Reviewed By: pengfei Differential Revision: https://reviews.llvm.org/D155863
2022-11-30[clang][TargetInfo] Use LangAS for getPointer{Width,Align}()Alex Richardson1-4/+4
Mixing LLVM and Clang address spaces can result in subtle bugs, and there is no need for this hook to use the LLVM IR level address spaces. Most of this change is just replacing zero with LangAS::Default, but it also allows us to remove a few calls to getTargetAddressSpace(). This also removes a stale comment+workaround in CGDebugInfo::CreatePointerLikeType(): ASTContext::getTypeSize() does return the expected size for ReferenceType (and handles address spaces). Differential Revision: https://reviews.llvm.org/D138295
2022-08-25[HLSL] Initial codegen for SV_GroupIndexChris Bieneman1-4/+0
Semantic parameters aren't passed as actual parameters, instead they are populated from intrinsics which are generally lowered to reads from dedicated hardware registers. This change modifies clang CodeGen to emit the intrinsic calls and populate the parameter's LValue with the result of the intrinsic call for SV_GroupIndex. The result of this is to make the actual passed argument ignored, which will make it easy to clean up later in an IR pass. Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D131203
2022-08-04[HLSL] clang codeGen for HLSLShaderAttr.Xiang Li1-0/+4
Translate HLSLShaderAttr to IR level. 1. Skip mangle for hlsl entry functions. 2. Add function attribute for hlsl entry functions. Reviewed By: Anastasia Differential Revision: https://reviews.llvm.org/D124752
2022-06-15[clang][WebAssembly] Loosen restriction on `main` symbol manglingSam Clegg1-1/+1
Remove the `hasPrototype()` restriction so that old style K&R declarations of main work too. For example the following has 2 params but no prototype. ``` int main(argc, argv) int argc; char *argv[]; { return 0; } ``` Also, use `getNumParams()` over `param_size()` which seems to be a more direct way to get at the same information. Also, add missing tests for this mangling. Differential Revision: https://reviews.llvm.org/D127888
2022-06-06[WebAssembly] Remove restriction on main name manglingSam Clegg1-3/+1
Summary: Emscripten now handles/supports this new mode. Subscribers: dschuff, jgravelle-google, aheejin, sunfish, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D75277
2022-01-05[clang][#52782] Bail on incomplete parameter type in stdcall name manglingMarkus Böck1-1/+7
stdcall name mangling requires a suffix with the number equal to the sum of the byte count of all parameter types. In the case of a function prototype that has a parameter type of an incomplete type it is impossible to get the size of the type. While such a function is not callable or able to be defined in the TU, it may still be mangled when generating debug info, which would previously lead to a crash. This patch fixes that by simply bailing out of the loop and using the so far accumulated byte count. This matches GCCs behaviour as well: https://github.com/gcc-mirror/gcc/blob/bc8d6c60137f8bbf173b86ddf31b15d7ba2a33dd/gcc/config/i386/winnt.c#L203 Fixes https://github.com/llvm/llvm-project/issues/52782 Differential Revision: https://reviews.llvm.org/D116020
2021-04-27[clang/Basic] Make TargetInfo.h not use DataLayout againNico Weber1-5/+13
Reverts parts of https://reviews.llvm.org/D17183, but keeps the resetDataLayout() API and adds an assert that checks that datalayout string and user label prefix are in sync. Approach 1 in https://reviews.llvm.org/D17183#2653279 Reduces number of TUs build for 'clang-format' from 689 to 575. I also implemented approach 2 in D100764. If someone feels motivated to make us use DataLayout more, it's easy to revert this change here and go with D100764 instead. I don't plan on doing more work in this area though, so I prefer going with the smaller, more self-consistent change. Differential Revision: https://reviews.llvm.org/D100776
2021-03-05Refactor -funique-internal-linakge-names implementation.Sriraman Tallam1-0/+6
The option -funique-internal-linkage-names was added in D73307 and D78243 as a LLVM early pass to insert a unique suffix to internal linkage functions and vars. The unique suffix was the hash of the module path. However, we found that this can be done more cleanly in clang early and the fixes that need to be done later can be completely avoided. The fixes in particular are trying to modify the DW_AT_linkage_name and finding the right place to insert the pass. This patch ressurects the original implementation proposed in D73307 which was reviewed and then ditched in favor of the pass based approach. Differential Revision: https://reviews.llvm.org/D96109
2020-09-29Fix a variety of minor issues with ObjC method mangling:John McCall1-1/+33
- Fix a memory leak accidentally introduced yesterday by using CodeGen's existing mangling context instead of creating a new context afresh. - Move GNU-runtime ObjC method mangling into the AST mangler; this will eventually be necessary to support direct methods there, but is also just the right architecture. - Make the Apple-runtime method mangling work properly when given an interface declaration, fixing a bug (which had solidified into a test) where mangling a category method from the interface could cause it to be mangled as if the category name was a class name. (Category names are namespaced within their class and have no global meaning.) - Fix a code cross-reference in dsymutil. Based on a patch by Ellis Hoag.
2020-09-29This reduces code duplication between CGObjCMac.cpp and Mangle.cppEllis Hoag1-15/+25
for generating the mangled name of an Objective-C method. This has no intended functionality change. https://reviews.llvm.org/D88329
2020-06-23Mangle.cpp - fix implicit Format.h dependency. NFC.Simon Pilgrim1-0/+1
ProfileSummary was depending on other headers (notably via WithColor.h) to define format().
2020-04-15Rework how UuidAttr, CXXUuidofExpr, and GUID template arguments and ↵Richard Smith1-1/+24
constants are represented. Summary: Previously, we treated CXXUuidofExpr as quite a special case: it was the only kind of expression that could be a canonical template argument, it could be a constant lvalue base object, and so on. In addition, we represented the UUID value as a string, whose source form we did not preserve faithfully, and that we partially parsed in multiple different places. With this patch, we create an MSGuidDecl object to represent the implicit object of type 'struct _GUID' created by a UuidAttr. Each UuidAttr holds a pointer to its 'struct _GUID' and its original (as-written) UUID string. A non-value-dependent CXXUuidofExpr behaves like a DeclRefExpr denoting that MSGuidDecl object. We cache an APValue representation of the GUID on the MSGuidDecl and use it from constant evaluation where needed. This allows removing a lot of the special-case logic to handle these expressions. Unfortunately, many parts of Clang assume there are only a couple of interesting kinds of ValueDecl, so the total amount of special-case logic is not really reduced very much. This fixes a few bugs and issues: * PR38490: we now support reading from GUID objects returned from __uuidof during constant evaluation. * Our Itanium mangling for a non-instantiation-dependent template argument involving __uuidof no longer depends on which CXXUuidofExpr template argument we happened to see first. * We now predeclare ::_GUID, and permit use of __uuidof without any header inclusion, better matching MSVC's behavior. We do not predefine ::__s_GUID, though; that seems like a step too far. * Our IR representation for GUID constants now uses the correct IR type wherever possible. We will still fall back to using the {i32, i16, i16, [8 x i8]} layout if a definition of struct _GUID is not available. This is not ideal: in principle the two layouts could have different padding. Reviewers: rnk, jdoerfert Subscribers: arphaman, cfe-commits, aeubanks Tags: #clang Differential Revision: https://reviews.llvm.org/D78171
2020-03-18[hip] Revise `GlobalDecl` constructors. NFC.Michael Liao1-1/+1
Summary: - https://reviews.llvm.org/D68578 revises the `GlobalDecl` constructors to ensure all GPU kernels have `ReferenceKenelKind` initialized properly with an explicit constructor and static one. But, there are lots of places using the implicit constructor triggering the assertion on non-GPU kernels. That's found in compilation of many tests and workloads. - Fixing all of them may change more code and, more importantly, all of them assumes the default kernel reference kind. This patch changes that constructor to tell `CUDAGlobalAttr` and construct `GlobalDecl` properly. Reviewers: yaxunl Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D76344
2020-03-09[HIP] Fix device stub nameYaxun (Sam) Liu1-0/+2
HIP emits a device stub function for each kernel in host code. The HIP debugger requires device stub function to have a different unmangled name as the kernel. Currently the name of the device stub function is the mangled name with a postfix .stub. However, this does not work with the HIP debugger since the unmangled name is the same as the kernel. This patch adds prefix __device__stub__ to the unmangled name of the device stub before mangling, therefore the device stub function has a valid mangled name which is different than the device kernel name. The device side kernel name is kept unchanged. kernels with extern "C" also gets the prefix added to the corresponding device stub function. Differential Revision: https://reviews.llvm.org/D68578
2020-03-07[NFC] Let mangler accept GlobalDeclYaxun (Sam) Liu1-10/+15
Differential Revision: https://reviews.llvm.org/D75700
2020-02-27[WebAssembly] Mangle the argc/argv `main` as `__wasm_argc_argv`.Dan Gohman1-1/+18
WebAssembly enforces a rule that caller and callee signatures must match. This means that the traditional technique of passing `main` `argc` and `argv` even when it doesn't need them doesn't work. Currently the backend renames `main` to `__original_main`, however this doesn't interact well with LTO'ing libc, and the name isn't intuitive. This patch allows us to transition to `__main_argc_argv` instead. This implements the proposal in https://github.com/WebAssembly/tool-conventions/pull/134 with a flag to disable it when targeting Emscripten, though this is expected to be temporary, as discussed in the proposal comments. Differential Revision: https://reviews.llvm.org/D70700
2020-01-28Make llvm::StringRef to std::string conversions explicit.Benjamin Kramer1-1/+1
This is how it should've been and brings it more in line with std::string_view. There should be no functional change here. This is mostly mechanical from a custom clang-tidy check, with a lot of manual fixups. It uncovers a lot of minor inefficiencies. This doesn't actually modify StringRef yet, I'll do that in a follow-up.
2020-01-07[NFC] Use isX86() instead of getArch()Jim Lin1-3/+1
Summary: This is a clean up for https://reviews.llvm.org/D72247. Reviewers: MaskRay, craig.topper, jhenderson Reviewed By: MaskRay Subscribers: hiraditya, rupprecht, cfe-commits, llvm-commits Tags: #clang, #llvm Differential Revision: https://reviews.llvm.org/D72320
2019-10-07AST - silence static analyzer getAs<> null dereference warnings. NFCI.Simon Pilgrim1-1/+1
The static analyzer is warning about potential null dereferences, but in these cases we should be able to use castAs<> directly and if not assert will fire for us. llvm-svn: 373904
2019-09-25[Mangle] Add flag to asm labels to disable '\01' prefixingVedant Kumar1-3/+9
LLDB synthesizes decls using asm labels. These decls cannot have a mangle different than the one specified in the label name. I.e., the '\01' prefix should not be added. Fixes an expression evaluation failure in lldb's TestVirtual.py on iOS. rdar://45827323 Differential Revision: https://reviews.llvm.org/D67774 llvm-svn: 372903
2019-08-14[Clang] Migrate llvm::make_unique to std::make_uniqueJonas Devlieghere1-1/+1
Now that we've moved to C++14, we no longer need the llvm::make_unique implementation from STLExtras.h. This patch is a mechanical replacement of (hopefully) all the llvm::make_unique instances across the monorepo. Differential revision: https://reviews.llvm.org/D66259 llvm-svn: 368942
2019-07-16Fix parameter name comments using clang-tidy. NFC.Rui Ueyama1-1/+1
This patch applies clang-tidy's bugprone-argument-comment tool to LLVM, clang and lld source trees. Here is how I created this patch: $ git clone https://github.com/llvm/llvm-project.git $ cd llvm-project $ mkdir build $ cd build $ cmake -GNinja -DCMAKE_BUILD_TYPE=Debug \ -DLLVM_ENABLE_PROJECTS='clang;lld;clang-tools-extra' \ -DCMAKE_EXPORT_COMPILE_COMMANDS=On -DLLVM_ENABLE_LLD=On \ -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ../llvm $ ninja $ parallel clang-tidy -checks='-*,bugprone-argument-comment' \ -config='{CheckOptions: [{key: StrictMode, value: 1}]}' -fix \ ::: ../llvm/lib/**/*.{cpp,h} ../clang/lib/**/*.{cpp,h} ../lld/**/*.{cpp,h} llvm-svn: 366177
2019-06-20[clang][AST] Refactoring ASTNameGenerator to use pimpl pattern (NFC).Puyan Lotfi1-146/+168
The original pimpl pattern used between CodegenNameGenerator and CodegenNameGeneratorImpl did a good job of hiding DataLayout making it so that users of CodegenNameGenerator did not need to link with llvm core. This is an NFC change to neatly wrap ASTNameGenerator in a pimpl. Differential Revision: https://reviews.llvm.org/D63584 llvm-svn: 363908
2019-06-19[clang][AST] ASTNameGenerator: A refactoring of CodegenNameGeneratorImpl (NFC).Puyan Lotfi1-0/+183
This is a NFC refactor move of CodegenNameGeneratorImpl from clang::Index to clang:AST (and rename to ASTNameGenerator). The purpose is to make the highlevel mangling code more reusable inside of clang (say in places like clang FrontendAction). This does not affect anything in CodegenNameGenerator, except that CodegenNameGenerator will now use ASTNameGenerator (in AST). Differential Revision: https://reviews.llvm.org/D63535 llvm-svn: 363878
2019-01-19Update the file headers across all of the LLVM projects in the monorepoChandler Carruth1-4/+3
to reflect the new license. We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach. Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository. llvm-svn: 351636
2018-10-23NFC: Remove MANGLE_CHECKER from ItaniumMangle.cppErik Pilkington1-6/+0
This hasn't even compiled since 2011. It would be useful to have some test to verify that ItaniumMangle and ItaniumDemangle agree, but this isn't it. llvm-svn: 345075
2018-07-30Remove trailing spaceFangrui Song1-1/+1
sed -Ei 's/[[:space:]]+$//' include/**/*.{def,h,td} lib/**/*.{cpp,h} llvm-svn: 338291
2017-09-07[modules ts] Ensure that module linkage variables are always emitted and ↵Richard Smith1-0/+5
always have their name mangled. llvm-svn: 312684
2017-03-07[AST/ObjC] Make ObjCCategoryImplDecl consistent with ObjCCategoryDecl and ↵Argyrios Kyrtzidis1-2/+6
use the category name as its DeclName This also addresses the badness in ObjCCategoryImplDecl's API, which was hiding NamedDecl's APIs with different meaning. llvm-svn: 297131
2016-11-02regcall: Implement regcall Calling Conv in clangErich Keane1-0/+3
This patch implements the register call calling convention, which ensures as many values as possible are passed in registers. CodeGen changes were committed in https://reviews.llvm.org/rL284108. Differential Revision: https://reviews.llvm.org/D25204 llvm-svn: 285849
2016-03-04Make TargetInfo store an actual DataLayout instead of a string.James Y Knight1-3/+3
Use it to calculate UserLabelPrefix, instead of specifying it (often incorrectly). Note that the *actual* user label prefix has always come from the DataLayout, and is handled within LLVM. The main thing clang's TargetInfo::UserLabelPrefix did was to set the #define value. Having these be different from each-other is just silly. Differential Revision: http://reviews.llvm.org/D17183 llvm-svn: 262737
2016-02-14[index] Factor libclang's functionality to determing the mangled name of ↵Argyrios Kyrtzidis1-6/+10
symbols into the clangIndex library. llvm-svn: 260858
2016-01-14Update for LLVM function name change.Rui Ueyama1-3/+3
llvm-svn: 257802
2015-08-13Remove and forbid raw_svector_ostream::flush() calls.Yaron Keren1-3/+0
After r244870 flush() will only compare two null pointers and return, doing nothing but wasting run time. The call is not required any more as the stream and its SmallString are always in sync. Thanks to David Blaikie for reviewing. llvm-svn: 244928