[PATCH] Remove gc.roots performCustomLowering
Philip Reames
listmail at philipreames.com
Tue Jan 27 18:02:13 PST 2015
Hi whitequark, mjacob, artagnon,
This is a refactoring to restructure the single user of performCustomLowering as a specific lowering pass and remove the custom lowering hook entirely.
Before this change, the LowerIntrinsics pass (note to self: rename!) was essentially acting as a pass manager, but without being structured in terms of passes. Instead, it proxied calls to a set of GCStrategies internally. This adds a lot of conceptual complexity (i.e. GCStrategies are stateful!) for very little benefit. Since there's been interest in keeping the ShadowStackGC working, I extracting it's custom lowering pass into a dedicated pass and just added that to the pass order. It will only run for functions which opt-in to that gc.
I wasn't able to find an easy way to preserve the runtime registration of custom lowering functionality. Given that no user of this exists that I'm aware of, I made the choice to just remove that. If someone really cares, we can look at restoring it via dynamic pass registration in the future.
Note that despite the large diff, none of the lowering code actual changes. I added the framing needed to make it a pass and rename the class, but that's it.
http://reviews.llvm.org/D7218
Files:
docs/GarbageCollection.rst
include/llvm/CodeGen/GCStrategy.h
include/llvm/CodeGen/Passes.h
include/llvm/InitializePasses.h
lib/CodeGen/GCRootLowering.cpp
lib/CodeGen/Passes.cpp
lib/CodeGen/ShadowStackGC.cpp
lib/CodeGen/ShadowStackGCLowering.cpp
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7218.18871.patch
Type: text/x-patch
Size: 43539 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150128/caea4e77/attachment.bin>
More information about the llvm-commits
mailing list