diff options
author | Sanjoy Das <sanjoy@playingwithpointers.com> | 2016-04-19 05:24:47 +0000 |
---|---|---|
committer | Sanjoy Das <sanjoy@playingwithpointers.com> | 2016-04-19 05:24:47 +0000 |
commit | c0441c29df6498257eca59d41d9ccaf6d5a9adf3 (patch) | |
tree | 50847e0c84b62a0efe0b8078f1ff6ca9b1c97d11 /llvm/lib/CodeGen/CodeGen.cpp | |
parent | 28d8d0465733b4363461c27cbf58721e1163d763 (diff) | |
download | bcm5719-llvm-c0441c29df6498257eca59d41d9ccaf6d5a9adf3.tar.gz bcm5719-llvm-c0441c29df6498257eca59d41d9ccaf6d5a9adf3.zip |
Introduce a "patchable-function" function attribute
Summary:
The `"patchable-function"` attribute can be used by an LLVM client to
influence LLVM's code generation in ways that makes the generated code
easily patchable at runtime (for instance, to redirect control).
Right now only one patchability scheme is supported,
`"prologue-short-redirect"`, but this can be expanded in the future.
Reviewers: joker.eph, rnk, echristo, dberris
Subscribers: joker.eph, echristo, mcrosier, llvm-commits
Differential Revision: http://reviews.llvm.org/D19046
llvm-svn: 266715
Diffstat (limited to 'llvm/lib/CodeGen/CodeGen.cpp')
-rw-r--r-- | llvm/lib/CodeGen/CodeGen.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/CodeGen.cpp b/llvm/lib/CodeGen/CodeGen.cpp index 3c2dc85df59..2613f5e4eda 100644 --- a/llvm/lib/CodeGen/CodeGen.cpp +++ b/llvm/lib/CodeGen/CodeGen.cpp @@ -55,6 +55,7 @@ void llvm::initializeCodeGen(PassRegistry &Registry) { initializeMachineSchedulerPass(Registry); initializeMachineSinkingPass(Registry); initializeMachineVerifierPassPass(Registry); + initializePatchableFunctionPass(Registry); initializeOptimizePHIsPass(Registry); initializePEIPass(Registry); initializePHIEliminationPass(Registry); |