[Profiler] NFC: Remove unnecessary parameter

`SILProfiler::create` is only ever called when
emitting a definition, so this check is redundant.
This commit is contained in:
Hamish Knight
2022-09-14 20:51:51 +01:00
parent 435af14e8e
commit 5039c1c3f1
5 changed files with 17 additions and 27 deletions

View File

@@ -322,10 +322,9 @@ void SILFunction::deleteSnapshot(int ID) {
} while ((f = f->snapshots) != nullptr);
}
void SILFunction::createProfiler(ASTNode Root, SILDeclRef forDecl,
ForDefinition_t forDefinition) {
void SILFunction::createProfiler(ASTNode Root, SILDeclRef Ref) {
assert(!Profiler && "Function already has a profiler");
Profiler = SILProfiler::create(Module, forDefinition, Root, forDecl);
Profiler = SILProfiler::create(Module, Root, Ref);
}
bool SILFunction::hasForeignBody() const {