Skip to content

Commit

Permalink
[LLVM-C] Expose the "Add Discriminators" Pass To LLVM-C
Browse files Browse the repository at this point in the history
Summary: Add bindings to create a wrapped "Add Discriminators" pass.  Now that we have debug info support, this is a handy transform to have.

Reviewers: whitequark, deadalnix

Reviewed By: whitequark

Subscribers: dblaikie, aprantl, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58624

llvm-svn: 356272
  • Loading branch information
CodaFi committed Mar 15, 2019
1 parent bbcda82 commit 2f1ebe6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions llvm/include/llvm-c/Transforms/Utils.h
Expand Up @@ -38,6 +38,9 @@ void LLVMAddLowerSwitchPass(LLVMPassManagerRef PM);
/** See llvm::createPromoteMemoryToRegisterPass function. */
void LLVMAddPromoteMemoryToRegisterPass(LLVMPassManagerRef PM);

/** See llvm::createAddDiscriminatorsPass function. */
void LLVMAddAddDiscriminatorsPass(LLVMPassManagerRef PM);

/**
* @}
*/
Expand Down
3 changes: 3 additions & 0 deletions llvm/lib/Transforms/Utils/Utils.cpp
Expand Up @@ -54,3 +54,6 @@ void LLVMAddPromoteMemoryToRegisterPass(LLVMPassManagerRef PM) {
unwrap(PM)->add(createPromoteMemoryToRegisterPass());
}

void LLVMAddAddDiscriminatorsPass(LLVMPassManagerRef PM) {
unwrap(PM)->add(createAddDiscriminatorsPass());
}

0 comments on commit 2f1ebe6

Please sign in to comment.