]> sourceware.org Git - systemtap.git/commit - staptree.cxx
Unify lex_cast* and avoid string copies
authorJosh Stone <jistone@redhat.com>
Wed, 2 Sep 2009 23:14:08 +0000 (16:14 -0700)
committerJosh Stone <jistone@redhat.com>
Wed, 2 Sep 2009 23:14:08 +0000 (16:14 -0700)
commitaca66a36681ac7cbf7fcc2eac4dafc83d6559ef9
tree0e8f39ae14f5793b37b0565c4a17811b696c9f9b
parentd185503c723ded087ff987e8fa08c2418e60006b
Unify lex_cast* and avoid string copies

We always use lex_cast either to string or from string, so I made that
explicit, and got rid of some string copies in the process.  There was
also stringify(), which was redundant to lex_cast<string>.

We also always used lex_cast_hex to string, so that's now hard-coded and
again eliminated a string copy.

For lex_cast_qstring<string>, there's no need to write the streamify the
input, so a specialization now operates directly on the input.

Hopefully this is a bit cleaner, and I do measure it to be a little
faster on scripts with many probes.
14 files changed:
buildrun.cxx
dwflpp.cxx
elaborate.cxx
main.cxx
parse.cxx
staptree.cxx
tapset-mark.cxx
tapset-perfmon.cxx
tapset-procfs.cxx
tapset-timers.cxx
tapset-utrace.cxx
tapsets.cxx
translate.cxx
util.h
This page took 0.029302 seconds and 5 git commands to generate.