I feel like I don't understand incremental process...
# ksp
f
I feel like I don't understand incremental processing in KSP on a basic level. Say my processor uses class
A
by annotating
A
and calling ``resolver.getSymbolsWithAnnotation`, and I change class `B`(unrelated). Why does
process
get called? surely to save time it should not be called. At first I thought that
resolver.getSymbolsWithAnnotation
will return an empty sequence if only
B
was changed and
A
has not, but it does not. I get
A
in this invocation, and, at the end of the day, no time is saved and there is nothing incremental about this. So what exactly can be done to make processing code incremental? There is no flag
stuffHasNotChanged
.
By the way, according to the logs, the file containing
A
is not dirty.
t
A possibility is that there is an aggregating output that depends (directly or indirectly) on A.
Because an aggregating output must be invalidated for any changes (that may contain new information to that output), if A participated in the generation of that output, A will also be invalidated.
f
My processor is isolating. But the thing i want to understand most is what will happen when ksp thinks a processor should not do unnecessary work. Does it simply not call procees()?
t
KSP calls process() and passes only files there are dirty / affected. It only skips process() when everything is clean.