mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-25 21:18:19 +00:00
Remove gc.root's findCustomSafePoints mechanism
Searching all of the existing gc.root implementations I'm aware of (all three of them), there was exactly one use of this mechanism, and that was to implement a performance improvement that should have been applied to the default lowering. Having this function is requiring a dependency on a CodeGen class (MachineFunction), in a class which is otherwise completely independent of CodeGen. I could solve this differently, but given that I see absolutely no value in preserving this mechanism, I going to just get rid of it. Note: Tis is the first time I'm intentionally breaking previously supported gc.root functionality. Given 3.6 has branched, I believe this is a good time to do this. Differential Revision: http://reviews.llvm.org/D7004 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226305 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -76,8 +76,6 @@ namespace llvm {
|
||||
bool CustomReadBarriers; ///< Default is to insert loads.
|
||||
bool CustomWriteBarriers; ///< Default is to insert stores.
|
||||
bool CustomRoots; ///< Default is to pass through to backend.
|
||||
bool CustomSafePoints; ///< Default is to use NeededSafePoints
|
||||
///< to find safe points.
|
||||
bool InitRoots; ///< If set, roots are nulled during lowering.
|
||||
bool UsesMetadata; ///< If set, backend must emit metadata tables.
|
||||
|
||||
@@ -124,7 +122,7 @@ namespace llvm {
|
||||
/// True if safe points of any kind are required. By default, none are
|
||||
/// recorded.
|
||||
bool needsSafePoints() const {
|
||||
return CustomSafePoints || NeededSafePoints != 0;
|
||||
return NeededSafePoints != 0;
|
||||
}
|
||||
|
||||
/// True if the given kind of safe point is required. By default, none are
|
||||
@@ -137,10 +135,6 @@ namespace llvm {
|
||||
/// stack map. If true, then performCustomLowering must delete them.
|
||||
bool customRoots() const { return CustomRoots; }
|
||||
|
||||
/// By default, the GC analysis will find safe points according to
|
||||
/// NeededSafePoints. If true, then findCustomSafePoints must create them.
|
||||
bool customSafePoints() const { return CustomSafePoints; }
|
||||
|
||||
/// If set, gcroot intrinsics should initialize their allocas to null
|
||||
/// before the first use. This is necessary for most GCs and is enabled by
|
||||
/// default.
|
||||
@@ -170,14 +164,6 @@ namespace llvm {
|
||||
llvm_unreachable("GCStrategy subclass specified a configuration which"
|
||||
"requires a custom lowering without providing one");
|
||||
}
|
||||
///@}
|
||||
/// Called if customSafepoints returns true, used only by gc.root
|
||||
/// implementations.
|
||||
virtual bool findCustomSafePoints(GCFunctionInfo& FI, MachineFunction& MF) {
|
||||
llvm_unreachable("GCStrategy subclass specified a configuration which"
|
||||
"requests custom safepoint identification without"
|
||||
"providing an implementation for such");
|
||||
}
|
||||
};
|
||||
|
||||
/// Subclasses of GCStrategy are made available for use during compilation by
|
||||
|
||||
Reference in New Issue
Block a user