Zoltan Ivanfi has posted comments on this change. Change subject: IMPALA-3973: add position and occurrence to instr() ......................................................................
Patch Set 8: (3 comments) http://gerrit.cloudera.org:8080/#/c/4094/6/be/src/runtime/string-search.h File be/src/runtime/string-search.h: Line 102: > This was accidental, will remove. Done PS6, Line 102: : for (int i = 0; i <= mlast; ++i) { : BloomAdd(pattern_->ptr[i]); : if (pattern_->ptr[i] == pattern_->ptr[mlast] && i != mlast) { : skip_ = mlast - i - 1; : } > Nice catch, thanks. I think we may be able to do better than the Python imp Done http://gerrit.cloudera.org:8080/#/c/4094/8/be/src/runtime/string-search.h File be/src/runtime/string-search.h: Line 227: int skip_; I changed skip_ to be int, since we use int-s to calculate it. Alternatively, I can keep it as int64 and change all int-s to int64-s. The question is, do we want to support strings bigger than 2GB? -- To view, visit http://gerrit.cloudera.org:8080/4094 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ie9648de458d243306fa14adc5e7f7002bf6f67fd Gerrit-PatchSet: 8 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Zoltan Ivanfi <[email protected]> Gerrit-Reviewer: Internal Jenkins Gerrit-Reviewer: Lars Volker <[email protected]> Gerrit-Reviewer: Matthew Jacobs <[email protected]> Gerrit-Reviewer: Zoltan Ivanfi <[email protected]> Gerrit-HasComments: Yes
