diff options
author | Eike Rathke <erack@redhat.com> | 2017-12-17 17:34:15 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2017-12-17 17:58:35 +0100 |
commit | 67444cbe5dae6e24db776ab712017ad063319276 (patch) | |
tree | 030fabd7916d23a28b021d1f28b84e29fa7d01b0 /sc/source/core | |
parent | 3193e78aba75c5b38d2683d9fd8593820048e8b9 (diff) |
Related: tdf#114251 disable vectorization of svDoubleRef
It doesn't work, not knowing how to handle implicit intersections
not only produces huge unnecessary matrix operations but also
delivers wrong results.
Unit test will follow as a separate commit.
Change-Id: I14982d4a53d6af57196da998e53d426502c22fec
Reviewed-on: https://gerrit.libreoffice.org/46647
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc/source/core')
-rw-r--r-- | sc/source/core/data/grouptokenconverter.cxx | 13 | ||||
-rw-r--r-- | sc/source/core/tool/token.cxx | 3 |
2 files changed, 15 insertions, 1 deletions
diff --git a/sc/source/core/data/grouptokenconverter.cxx b/sc/source/core/data/grouptokenconverter.cxx index c0818287cf33..9697b4cbe14a 100644 --- a/sc/source/core/data/grouptokenconverter.cxx +++ b/sc/source/core/data/grouptokenconverter.cxx @@ -165,6 +165,18 @@ bool ScGroupTokenConverter::convert( const ScTokenArray& rCode, sc::FormulaLogge break; case svDoubleRef: { + /* FIXME: this simply does not work, it doesn't know + * a) the context of implicit intersection, for which creating + two arrays dows not only result in huge unnecessary matrix + operations but also produces wrong results, e.g. =B:B/C:C + * b) when to keep a reference as a reference depending on the + expected parameter type, e.g. INDEX(), OFFSET() and + others (though that *may* be disabled by OpCode already). + * Until both are solved keep the reference. */ + mrGroupTokens.AddToken(*p); + break; + +#if 0 ScComplexRefData aRef = *p->GetDoubleRef(); ScRange aAbs = aRef.toAbs(mrPos); @@ -237,6 +249,7 @@ bool ScGroupTokenConverter::convert( const ScTokenArray& rCode, sc::FormulaLogge //ensure that backing storage exists for our lifetime mxFormulaGroupContext = mrDoc.GetFormulaGroupContext(); } +#endif } break; case svIndex: diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx index cd94fd31058a..d13f1a2c4308 100644 --- a/sc/source/core/tool/token.cxx +++ b/sc/source/core/tool/token.cxx @@ -1612,10 +1612,11 @@ void ScTokenArray::CheckToken( const FormulaToken& r ) // Don't change the state. break; case svSingleRef: - case svDoubleRef: // Depends on the reference state. meVectorState = FormulaVectorCheckReference; break; + case svDoubleRef: + // Does not work yet, see ScGroupTokenConverter::convert() case svError: case svEmptyCell: case svExternal: |