Add support for ReportAbsolute and ReportPercentage in swap plugin

Add ReportAbsolute and ReportPercentage options to the swap plugin
so that values can be converted to percentages much like in the
df plugin

Signed-off-by: Florian Forster <octo@collectd.org>
collectd.conf(5): Document "Values{Absolute,Percentage} for the swap plugin.
swap plugin: Improvements for the percent code:

* Don't rely on the left-to-right evaluation order, i.e. move the
  division to the right.
* Avoid casting by making many of the internally used variables gauge_t.
  They were derive_t in many cases for historical reasons that no longer
  apply.
* Change the naming: Don't use the "swap" type for percentages (putting
  the information that it *is* a percentage into the type instance) and
  use "percent" instead.
src/plugin.[ch]: Implement plugin_dispatch_multivalue().
swap plugin: Switch to the new plugin_dispatch_multivalue() interface.
swap plugin: Remove left-over debugging message.
swap plugin: Use the "complex" configuration.

It's actually shorter and handles non-boolean arguments more intelligently.
src/utils_cache.c: Very minor performance improvement.

cache_compare() is one of the hottest functions in collectd. Depending how many
metrics collectd handles (how deep the tree is) it gets called an order of
magnitude or two more often than the number of metrics handled. With 100k
metrics, about 6.6% of the CPU time were spent within cache_compare(), with
this commit this reduces to 6.3% (that's, uhm, 4.7% faster?).
src/common.[ch]: Rewrite the escape_slashes() function.

Cleaner and slightly more efficient (3.8% faster) version of escape_slashes().
This function is quite hot with, depending on the configuration, between 1.2%
and 2.6% of total CPU time spent here.
swap plugin: Remove the swap_submit() function.

This function was used only by swap_submit_derive(), which was declared
conditionally. This resulted in "defined but not used" warnings, e.g. on
FreeBSD.
Merge branch 'katzj/swap'
Merge branch 'master' into katzj/memory
memory plugin: Use the new plugin_dispatch_multivalue() interface.

This takes calculation of percentages off of our hands.