This filter is already applied to the rest of the analysis - this change simply prevents some unnecessary work.
Details
Diff Detail
Event Timeline
llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp | ||
---|---|---|
1843–1844 | I would prefer a reference type, assuming there is no possibility that it is nullptr. |
/me squints -- so if no part of the variable ends up on the stack, this is effectively early-exiting this portion of analysis?
llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp | ||
---|---|---|
1843–1844 | +1, |
Effectively yes. We already have this filter applied to the rest of the analysis; this patch just adds it to this initialisation step too.
llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp | ||
---|---|---|
1843–1844 | I have already changed VarsWithStackSlot (the parameter added in this patch) to a reference type - just checking, @jmorse are you asking for me to change FnVarLocs (not added in this patch) too? |
LGTM
llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp | ||
---|---|---|
1843–1844 | Oh, right, this patch isn't adding that parameter. That can probably be improved some other time then. |
I would prefer a reference type, assuming there is no possibility that it is nullptr.