Add cold versions of benchmarks.

- Created macros for one and two buffer benchmarks to simplify
  addition of new benchmarks.
- Created cold versions of all benchmarks that work on buffer benchmarks.
  This means that the benchmark is given buffers that are not in the cache.
- Verified the cold versions are working as intended by
  changing it so that the same buffer is written in each loop
  instead of the strided buffer. Using this method, the cold and
  normal benchmark run at the same speed.

Merge from internal master.

(cherry-picked from 991bcd464d67c3cff76477140331619ff138aafc)

Change-Id: I4b1b55510d90cc9a941fd68244971cb08cfba553
Merge "Add cold versions of benchmarks."
am 5b1efce4: Merge "Add cold versions of benchmarks."

* commit '5b1efce4aeea83c7b18dfed5d3366d6b84874c23':
  Add cold versions of benchmarks.
ext4_utils: Yet another MMC discard pain in the ass

 * Secure discard on this device is painfully slow. Use regular
   discard until the issue is sorted out.

Change-Id: Id6cc80ea7a25410b812803425a4b6267289834fb
Merge remote-tracking branch 'aosp/kitkat-mr1-release' into kk-4.4
Avoid underflow on an unsigned int when computering bg overrun

A computation for when a block group overruns the end of an image
was consistently storing a negative number in an unsigned var,
and then checking for >0, which is always true for negative numbers.
So first check if the number will be positive before computing it.

Change-Id: Ic8cff8f9ab9f4ea8c5a4dc42143c2430fa87ba12
libpagemap: fix memory leak in pm_process_destroy()

procrank/librank not impacted because they end quickly. But other
programs that use libpagemap and last for long time can easily see this
memory leak.

Change-Id: I8c9e9444555bef9145c9d89850987a29f15a9b3b
Signed-off-by: Carton He <carton.he@marvell.com>
use BIONIC implementation of mmap64

Change-Id: Idb0c3d3bb98f22ea7d78043b786e931613377b02
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
procrank: Use %zu for size_t and %d for pid_t

Change-Id: Ic339a05a3091ec6b33b68bc5e76082de3513e9c7
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
procmem: Use size_t instead of int to remove a potential bug.

In procmem.c, num_maps and num_pages are declared as
int. Pointers (int*) to these variables are being
passed to functions pm_process_maps and pm_map_pagemap
respectively, both of which expect size_t * argument.

This will lead to problems in 64-bit systems where
size_t and int_t have different size.

To avoid the issue, num_maps and num_pages are declared
as size_t. In addition, loop counters i and j are now
declared as size_t to avoid comparison of signed int with
unsigned int.

Change-Id: I3fc51f9386c9b2d289d34808e19e3811ca4a3dae
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>