Overview
| Artifact ID: | c1b8459f6fb1ea6b81e5b9b96cc395ca0d57e35f |
|---|---|
| Ticket: | 3484402fffffffffffffffffffffffffffffffff
off-by-one address error in AppendUnicodeToUnicodeRep |
| User & Date: | dgp on 2012-02-09 03:47:25 |
Changes
- icomment:
So the remaining dispute is just memcpy() vs. memmove() ? Unquestionably, memmove() is as correct as memcpy(). Unquestionably, memmove() is as safe as memcpy(). If there's even a possibility of overlapping sequences, memmove() is safe where memcpy() is not. That leaves only performance as a possible reason not to use memmove(), correct? I plan to commit the patch from the bugfix branch. If there's a performance argument to change back to memcpy(), let's see the measurements to support it. On my system the memmove() implementation is faster on the STR append benchmarks. 001 STR append 5.44 5.50 002 STR append (1KB + 1KB) 1.00 1.02 003 STR append (1MB + (1b+1K+1b)*100) 168.88 173.85 004 STR append (1MB + 1KB) 129.17 129.15 005 STR append (1MB + 1KB*20) 132.90 133.15 006 STR append (1MB + 1KB*1000) 291.17 300.10 007 STR append (1MB + 1MB*3) 522.82 436.00 008 STR append (1MB + 1MB*5) 653.54 541.52 009 STR append (1MB + 2b*1000) 236.96 245.06 This is core-8-4-branch tip vs. bug-3484402.
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"