optimized topkeys implementation
optimized topkeys implementation

Use of binaries speeds it up, but not by much. Slightly less than 10%
in my testing.

Change-Id: Id84b0b89b2f05042004f1d6180d16444b1f8ddce
Reviewed-on: http://review.couchbase.org/38890
Tested-by: Aliaksey Kandratsenka <340b8e09ca65cd3fc686427fcfed17e87eaf61e2@gmail.com>
Reviewed-by: Aliaksey Artamonau <3c875bcfb3adf2a65b2ae7686ca921e6c9433147@gmail.com>

membase/ns_server,ceejatec/ns_server,t3rm1n4l/ns_server,nimishzynga/ns_server,membase/ns_server,ceejatec/ns_server,mschoch/ns_server,ceejatec/ns_server,t3rm1n4l/ns_server,mschoch/ns_server,mschoch/ns_server,nimishzynga/ns_server,nimishzynga/ns_server,nimishzynga/ns_server,mschoch/ns_server,membase/ns_server,nimishzynga/ns_server,ceejatec/ns_server,mschoch/ns_server,nimishzynga/ns_server,membase/ns_server,membase/ns_server,membase/ns_server,t3rm1n4l/ns_server,t3rm1n4l/ns_server,mschoch/ns_server,ceejatec/ns_server,t3rm1n4l/ns_server,ceejatec/ns_server