mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
SILOptimizer: Add some FIXMEs and a cleanup
This commit is contained in:
@@ -365,6 +365,7 @@ computeNewArgInterfaceTypes(SILFunction *F,
|
||||
assert(paramBoxTy->getLayout()->getFields().size() == 1
|
||||
&& "promoting compound box not implemented yet");
|
||||
auto paramBoxedTy = paramBoxTy->getFieldType(F->getModule(), 0);
|
||||
// FIXME: Expansion
|
||||
auto ¶mTL = Types.getTypeLowering(paramBoxedTy,
|
||||
ResilienceExpansion::Minimal);
|
||||
ParameterConvention convention;
|
||||
|
||||
@@ -339,6 +339,7 @@ bool ObjectOutliner::optimizeObjectAllocation(
|
||||
<< ARI->getFunction()->getName() << '\n');
|
||||
|
||||
SILModule *Module = &ARI->getFunction()->getModule();
|
||||
// FIXME: Expansion
|
||||
assert(!Cl->isResilient(Module->getSwiftModule(),
|
||||
ResilienceExpansion::Minimal) &&
|
||||
"constructor call of resilient class should prevent static allocation");
|
||||
@@ -448,6 +449,7 @@ void ObjectOutliner::replaceFindStringCall(ApplyInst *FindStringCall) {
|
||||
return;
|
||||
|
||||
|
||||
// FIXME: Expansion
|
||||
assert(!cacheDecl->isResilient(Module->getSwiftModule(),
|
||||
ResilienceExpansion::Minimal));
|
||||
|
||||
|
||||
@@ -695,8 +695,7 @@ bool swift::canDevirtualizeClassMethod(FullApplySite AI,
|
||||
}
|
||||
|
||||
// We need to disable the “effectively final” opt if a function is inlinable
|
||||
if (isEffectivelyFinalMethod && AI.getFunction()->getResilienceExpansion() ==
|
||||
ResilienceExpansion::Minimal) {
|
||||
if (isEffectivelyFinalMethod && AI.getFunction()->isSerialized()) {
|
||||
LLVM_DEBUG(llvm::dbgs() << " FAIL: Could not optimize function "
|
||||
"because it is an effectively-final inlinable: "
|
||||
<< AI.getFunction()->getName() << "\n");
|
||||
|
||||
Reference in New Issue
Block a user