Commit Graph

6 Commits

Author SHA1 Message Date
Michael Gottesman
f30b2c9b9f [pa-combiner] Change worklist iteration to use a more canonical worklist form.
We generally do not use a for loop for worklist iteration since one runs into
weird issues around always needing to recompute the worklist size since it may
change per iteration. In contrast, using the while loop approach that just pops
off the back avoids such implicit weirdness.
2019-12-13 13:31:15 -08:00
Michael Gottesman
89ff110c0d [pa-combiner] Use llvm::any_of instead of a for loop. 2019-12-13 13:31:15 -08:00
Michael Gottesman
5acb59aea4 [pa-combiner] Simplify some cleanup code by using FullApplySite::insertAfterFullInvocation. 2019-12-13 12:51:04 -08:00
Michael Gottesman
e4e48e81f1 [pa-combiner] Modernize some appending code to use a range instead of iterators. NFC. 2019-12-12 09:52:28 -08:00
Michael Gottesman
0d88ff1432 [pa-combiner] Some further updates for supporting ossa.
Specifically:

1. I converted a bunch of cases where we were emitting releases/unqualified
loads to use instead the *Operation commands that work in both modes.
2. I renamed some methods/variables that referred to releases to instead refer
to destroys.
2019-12-12 09:52:28 -08:00
Michael Gottesman
113c22a680 [sil] Move partial apply combiner code from SILCombiner into InstOptUtils.h/SILCombinerApplyVisitor.cpp.
This is in preparation for moving this into the mandatory combiner.
2019-12-11 14:48:19 -08:00