diff options
| author | Uwe Kleine-König <[email protected]> | 2024-03-03 09:24:09 +0000 |
|---|---|---|
| committer | Andrew Morton <[email protected]> | 2024-03-12 20:09:22 +0000 |
| commit | 8c86fb68ffcb0d8a5418e171c8d359d712912e9b (patch) | |
| tree | 5d19b4a82cc54d1c036f9f855691fa7946bb56ca /lib/assoc_array.c | |
| parent | kexec: copy only happens before uchunk goes to zero (diff) | |
| download | kernel-8c86fb68ffcb0d8a5418e171c8d359d712912e9b.tar.gz kernel-8c86fb68ffcb0d8a5418e171c8d359d712912e9b.zip | |
mul_u64_u64_div_u64: increase precision by conditionally swapping a and b
As indicated in the added comment, the algorithm works better if b is big.
As multiplication is commutative, a and b can be swapped. Do this if a
is bigger than b.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Uwe Kleine-König <[email protected]>
Tested-by: Biju Das <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'lib/assoc_array.c')
0 files changed, 0 insertions, 0 deletions
