aboutsummaryrefslogtreecommitdiff
path: root/src/tutorial
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2007-06-17 23:39:28 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2007-06-17 23:39:28 +0000
commit011b51cb7e912af2674ee6685a51651182ceab4f (patch)
treea20466763833d3b4db93a2264e3c0900af67bb36 /src/tutorial
parent6775c0108039a13458004d893e4a17b4ae3fae9d (diff)
downloadpostgresql-011b51cb7e912af2674ee6685a51651182ceab4f.tar.gz
postgresql-011b51cb7e912af2674ee6685a51651182ceab4f.zip
Marginal hacking to improve the speed of COPY OUT. I had found in a bit of
profiling that CopyAttributeOutText was taking an unreasonable fraction of the backend run time (like 66%!) on the following trivial test case: $ time psql -c "copy (select repeat('xyzzy',50) from generate_series(1,10000000)) to stdout" regression >/dev/null The time is all being spent on scanning the string for characters to be escaped, which most of the time there aren't any of. Some tweaking to take as many tests as possible out of the inner loop reduced the runtime of this example by more than 10%. In a real-world case it wouldn't be as useful a speedup, but it still seems worth adding a few lines here.
Diffstat (limited to 'src/tutorial')
0 files changed, 0 insertions, 0 deletions