diff options
author | Werner Zeh <werner.zeh@siemens.com> | 2019-02-19 13:34:12 +0100 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2019-02-26 11:14:41 +0000 |
commit | bd660e23382a74b399fa25ca01b9a9cd9c7683e9 (patch) | |
tree | 7caf9845c770b379dba2cab680c214bf38f9bbea /src/soc/intel | |
parent | 38b6ccfed9d0a9ff0605f2def02033cc9523ee94 (diff) |
commonlib: Add Bubble sort algorithm
Add an implementation for Bubble sort. For now, only integers can be
sorted in an ascending or descending order. It can be later simply
extended to cover other datasets like strings if needed.
The reasons for choosing bubble sort are:
* it is a simple algorithm
* bubble sort is stable, i.e. it does not exchange entries which are not
needed to be sorted as they are already in order
Change-Id: I2c5e0b5685a907243b58ebe6682078272d316bf6
Signed-off-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-on: https://review.coreboot.org/c/31544
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Diffstat (limited to 'src/soc/intel')
0 files changed, 0 insertions, 0 deletions