You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
David Howells
690d137f44
Reduce the number of expensive division instructions done by _parse_integer()
...
_parse_integer() does one or two division instructions (which are slow)
per digit parsed to perform the overflow check.
Furthermore, these are particularly expensive examples of division
instruction as the number of clock cycles required to complete them may
go up with the position of the most significant set bit in the dividend:
if (*res > div_u64(ULLONG_MAX - val, base))
which is as maximal as possible.
Worse, on 32-bit arches, more than one of these division instructions
may be required per digit.
So, assuming we don't support a base of more than 16, skip the check if the
top nibble of the result is not set at this point.
Signed-off-by: David Howells <dhowells@redhat.com>
[ Changed it to not dereference the pointer all the time - even if the
compiler can and does optimize it away, the code just looks cleaner.
And edited the top nybble test slightly to make the code generated on
x86-64 better in the loop - test against a hoisted constant instead of
shifting and testing the result ]
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
13 years ago
..
lzo
…
mpi
lib: Fix 32-bit sparc udiv_qrnnd() definition in mpilib's longlong.h
13 years ago
raid6
md: Add in export.h for files using EXPORT_SYMBOL
13 years ago
reed_solomon
…
xz
…
zlib_deflate
…
zlib_inflate
…
.gitignore
…
Kconfig
arch: fix ioport mapping on mips,sh
13 years ago
Kconfig.debug
kmemleak: Add support for memory hotplug
13 years ago
Kconfig.kgdb
…
Kconfig.kmemcheck
…
Makefile
lib: Fix multiple definitions of clz_tab
13 years ago
argv_split.c
…
atomic64.c
…
atomic64_test.c
…
audit.c
…
average.c
…
bcd.c
…
bch.c
…
bitmap.c
lib/bitmap.c: quiet sparse noise about address space
13 years ago
bitrev.c
…
bsearch.c
…
btree.c
btree: export btree_get_prev() so modules can use btree_for_each
13 years ago
bug.c
bugs, x86: Fix printk levels for panic, softlockups and stack dumps
13 years ago
bust_spinlocks.c
…
check_signature.c
…
checksum.c
…
clz_tab.c
lib: Fix multiple definitions of clz_tab
13 years ago
cmdline.c
…
cordic.c
Docs: wording: functions -> algorithm
13 years ago
cpu-notifier-error-inject.c
…
cpu_rmap.c
…
cpumask.c
…
crc-ccitt.c
…
crc-itu-t.c
…
crc-t10dif.c
…
crc7.c
…
crc8.c
…
crc16.c
…
crc32.c
crc32: optimize inner loop
13 years ago
crc32defs.h
…
ctype.c
…
debug_locks.c
…
debugobjects.c
debugobjects: Extend to assert that an object is initialized
13 years ago
dec_and_lock.c
…
decompress.c
…
decompress_bunzip2.c
decompress_bunzip2: remove invalid vi modeline
13 years ago
decompress_inflate.c
…
decompress_unlzma.c
treewide: Fix comment and string typo 'bufer'
13 years ago
decompress_unlzo.c
unlzo: fix input buffer free
13 years ago
decompress_unxz.c
…
devres.c
Merge branch 'linux-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci
13 years ago
digsig.c
lib/digsig: checks for NULL return value
13 years ago
div64.c
…
dma-debug.c
Fix comparison using wrong pointer variable in dma debug code
13 years ago
dump_stack.c
…
dynamic_debug.c
Merge branch 'driver-core-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
13 years ago
dynamic_queue_limits.c
dql: Dynamic queue limits
13 years ago
extable.c
…
fault-inject.c
switch debugfs to umode_t
13 years ago
find_last_bit.c
…
find_next_bit.c
…
flex_array.c
…
gcd.c
…
gen_crc32table.c
…
genalloc.c
…
halfmd4.c
…
hexdump.c
…
hweight.c
…
idr.c
ida: make ida_simple_get/put() IRQ safe
13 years ago
inflate.c
…
int_sqrt.c
…
iomap.c
lib: add GENERIC_PCI_IOMAP
13 years ago
iomap_copy.c
…
iommu-helper.c
…
ioremap.c
…
irq_regs.c
…
is_single_threaded.c
…
kasprintf.c
…
klist.c
…
kobject.c
kobject: remove kset_find_obj_hinted()
13 years ago
kobject_uevent.c
driver-core: skip uevent generation when nobody is listening
13 years ago
kstrtox.c
Reduce the number of expensive division instructions done by _parse_integer()
13 years ago
kstrtox.h
lib/kstrtox: common code between kstrto*() and simple_strto*() functions
13 years ago
lcm.c
…
libcrc32c.c
…
list_debug.c
…
list_sort.c
…
llist.c
…
locking-selftest-hardirq.h
…
locking-selftest-mutex.h
…
locking-selftest-rlock-hardirq.h
…
locking-selftest-rlock-softirq.h
…
locking-selftest-rlock.h
…
locking-selftest-rsem.h
…
locking-selftest-softirq.h
…
locking-selftest-spin-hardirq.h
…
locking-selftest-spin-softirq.h
…
locking-selftest-spin.h
…
locking-selftest-wlock-hardirq.h
…
locking-selftest-wlock-softirq.h
…
locking-selftest-wlock.h
…
locking-selftest-wsem.h
…
locking-selftest.c
…
lru_cache.c
…
md5.c
…
nlattr.c
netlink: validate NLA_MSECS length
13 years ago
parser.c
…
pci_iomap.c
lib: add NO_GENERIC_PCI_IOPORT_MAP
13 years ago
percpu_counter.c
lib/percpu_counter.c: enclose hotplug only variables in hotplug ifdef
13 years ago
plist.c
…
prio_heap.c
…
prio_tree.c
…
proportions.c
…
radix-tree.c
radix_tree: take radix_tree_path off stack
13 years ago
random32.c
…
ratelimit.c
…
rational.c
…
rbtree.c
…
reciprocal_div.c
sch_red: Adaptative RED AQM
13 years ago
rwsem-spinlock.c
…
rwsem.c
…
scatterlist.c
…
sha1.c
…
show_mem.c
…
smp_processor_id.c
…
sort.c
…
spinlock_debug.c
lib/spinlock_debug.c: print owner on spinlock lockup
13 years ago
string.c
lib/string.c: fix strim() semantics for strings that have only blanks
13 years ago
string_helpers.c
…
swiotlb.c
swiotlb: Expose swiotlb_nr_tlb function to modules
13 years ago
syscall.c
…
test-kstrtox.c
…
textsearch.c
…
timerqueue.c
…
ts_bm.c
…
ts_fsm.c
…
ts_kmp.c
…
uuid.c
…
vsprintf.c
net: introduce and use netdev_features_t for device features sets
13 years ago