* div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3'
@ 2026-03-21 4:48 kernel test robot
2026-03-21 9:24 ` David Laight
0 siblings, 1 reply; 2+ messages in thread
From: kernel test robot @ 2026-03-21 4:48 UTC (permalink / raw)
To: David Laight
Cc: oe-kbuild-all, linux-kernel, Andrew Morton,
Linux Memory Management List, Nicolas Pitre
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 42bddab0563fe67882b2722620a66dd98c8dbf33
commit: 6480241f31f543333ed0c7a209962412461f6e41 lib: add mul_u64_add_u64_div_u64() and mul_u64_u64_div_u64_roundup()
date: 4 months ago
config: mips-randconfig-r122-20260321 (https://download.01.org/0day-ci/archive/20260321/202603211216.YTKRdi1b-lkp@intel.com/config)
compiler: mips64-linux-gcc (GCC) 8.5.0
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260321/202603211216.YTKRdi1b-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603211216.YTKRdi1b-lkp@intel.com/
All errors (new ones prefixed by >>):
mips64-linux-ld: lib/math/div64.o: in function `mul_u64_add_u64_div_u64':
>> div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3'
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3'
2026-03-21 4:48 div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3' kernel test robot
@ 2026-03-21 9:24 ` David Laight
0 siblings, 0 replies; 2+ messages in thread
From: David Laight @ 2026-03-21 9:24 UTC (permalink / raw)
To: kernel test robot
Cc: oe-kbuild-all, linux-kernel, Andrew Morton,
Linux Memory Management List, Nicolas Pitre
On Sat, 21 Mar 2026 12:48:23 +0800
kernel test robot <lkp@intel.com> wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: 42bddab0563fe67882b2722620a66dd98c8dbf33
> commit: 6480241f31f543333ed0c7a209962412461f6e41 lib: add mul_u64_add_u64_div_u64() and mul_u64_u64_div_u64_roundup()
> date: 4 months ago
> config: mips-randconfig-r122-20260321 (https://download.01.org/0day-ci/archive/20260321/202603211216.YTKRdi1b-lkp@intel.com/config)
> compiler: mips64-linux-gcc (GCC) 8.5.0
> sparse: v0.6.5-rc1
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260321/202603211216.YTKRdi1b-lkp@intel.com/reproduce)
>
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202603211216.YTKRdi1b-lkp@intel.com/
>
> All errors (new ones prefixed by >>):
>
> mips64-linux-ld: lib/math/div64.o: in function `mul_u64_add_u64_div_u64':
> >> div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3'
>
I thought someone was going to change the #if so that __multi3 was defined
for compilers after (IIRC) 7.1 until at (also IIRC) 10.5.
But for __mips why worry that much - the function is quite small.
Just enable it unconditionally.
While this code only wants the 128bit product of two 64bit integers
(which is a single instruction) the full 128x128 product looks
faster than the fallback code that uses 32bit multiples.
More interesting is sparc64 - where __multi3 can also get called.
That function looks horrid - I presume it is carefully optimised!
Without any comment it is hard to see what it is doing.
(Not helped by me only knowing sparc32 from 1988.)
David
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-03-21 9:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-21 4:48 div64.c:(.text.mul_u64_add_u64_div_u64+0x40): undefined reference to `__multi3' kernel test robot
2026-03-21 9:24 ` David Laight
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox