ScInterpreter::Interpret() backtraces during ODS import

Kohei Yoshida kohei.yoshida at gmail.com
Fri Jun 29 08:39:29 PDT 2012


On Thu, Jun 28, 2012 at 11:16 AM, Eike Rathke <erack at redhat.com> wrote:
> Hi Daniel,
>
> On Wednesday, 2012-06-27 16:34:38 -0500, Daniel Bankston wrote:
>
>> When ScInterpreter::Interpret()
>> is called multiple times, I assume that each call is for each
>> formula cell, although I have not thoroughly verified this.
>
> Your assumption is correct.
>
>> Does this mean we are indeed unnecessarily recalculating formula
>> results even though we have imported formula results at our
>> disposal?
>
> As discussed on IRC yesterday, yes and no.. unnecessarily if we could
> trust all results are identical to what we would calculate, including
> modifications that might had been done by other processors and
> differences that may result from improved algorithms / changed behavior
> in our own code.
>
> So, a possible solution could be to set formula cells dirty only if the
> content of the <meta:generator> element differs from the current office
> version.

What I think we should do eventually is to prompt the user on whether
or not to do a full re-calc when the generator and the loader and
their versions differ.  I'm sure we all agree that, using the cached
formula results is safe if the generator and the loader (and their
versions) match.  But doing a full re-calc in *all* other cases
unconditionally to me is an over-kill. We should leave that decision
up to the user, with a sensible default for those who don't really
care.

That said, doing what Eike suggests will be a good intermediate step
even if we decide to prompt the user in the end.

Kohei


More information about the LibreOffice mailing list