All of lore.kernel.org
 help / color / mirror / Atom feed
* [mips-linux:mips-next 98/101] kernel/time/test_udelay.c:57:2: error: couldn't allocate output register for constraint 'x'
@ 2021-04-21 22:58 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-04-21 22:58 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 23139 bytes --]

Hi Maciej,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mips/linux.git mips-next
head:   182dd5bad52c66a54c300fe320b772456572bf23
commit: c49f71f60754acbff37505e1d16ca796bf8a8140 [98/101] MIPS: Reinstate platform `__div64_32' handler
config: mips-randconfig-r036-20210421 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project d87b9b81ccb95217181ce75515c6c68bbb408ca4)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install mips cross compiling tool for clang build
        # apt-get install binutils-mips-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/mips/linux.git/commit/?id=c49f71f60754acbff37505e1d16ca796bf8a8140
        git remote add mips-linux https://git.kernel.org/pub/scm/linux/kernel/git/mips/linux.git
        git fetch --no-tags mips-linux mips-next
        git checkout c49f71f60754acbff37505e1d16ca796bf8a8140
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=mips 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> kernel/time/test_udelay.c:57:2: error: couldn't allocate output register for constraint 'x'
           do_div(avg, iters);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   1 error generated.
--
   kernel/time/hrtimer.c:120:21: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
           [CLOCK_REALTIME]        = HRTIMER_BASE_REALTIME,
                                     ^~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:118:27: note: previous initialization is here
           [0 ... MAX_CLOCKS - 1]  = HRTIMER_MAX_CLOCK_BASES,
                                     ^~~~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:121:22: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
           [CLOCK_MONOTONIC]       = HRTIMER_BASE_MONOTONIC,
                                     ^~~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:118:27: note: previous initialization is here
           [0 ... MAX_CLOCKS - 1]  = HRTIMER_MAX_CLOCK_BASES,
                                     ^~~~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:122:21: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
           [CLOCK_BOOTTIME]        = HRTIMER_BASE_BOOTTIME,
                                     ^~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:118:27: note: previous initialization is here
           [0 ... MAX_CLOCKS - 1]  = HRTIMER_MAX_CLOCK_BASES,
                                     ^~~~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:123:17: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
           [CLOCK_TAI]             = HRTIMER_BASE_TAI,
                                     ^~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:118:27: note: previous initialization is here
           [0 ... MAX_CLOCKS - 1]  = HRTIMER_MAX_CLOCK_BASES,
                                     ^~~~~~~~~~~~~~~~~~~~~~~
   kernel/time/hrtimer.c:276:20: warning: unused function 'is_migration_base' [-Wunused-function]
   static inline bool is_migration_base(struct hrtimer_clock_base *base)
                      ^
   kernel/time/hrtimer.c:1707:20: warning: unused function '__hrtimer_peek_ahead_timers' [-Wunused-function]
   static inline void __hrtimer_peek_ahead_timers(void)
                      ^
>> kernel/time/hrtimer.c:318:2: error: couldn't allocate output register for constraint 'x'
           do_div(tmp, (u32) div);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   6 warnings and 1 error generated.
--
   In file included from kernel/time/timekeeping.c:6:
   In file included from include/linux/timekeeper_internal.h:10:
   In file included from include/linux/clocksource.h:13:
   In file included from include/linux/timex.h:56:
   In file included from include/uapi/linux/timex.h:56:
   In file included from include/linux/time.h:6:
>> include/linux/math64.h:256:14: error: couldn't allocate output register for constraint 'x'
           rl.l.high = do_div(rh.ll, divisor);
                       ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   In file included from kernel/time/timekeeping.c:6:
   In file included from include/linux/timekeeper_internal.h:10:
   In file included from include/linux/clocksource.h:13:
   In file included from include/linux/timex.h:56:
   In file included from include/uapi/linux/timex.h:56:
   In file included from include/linux/time.h:6:
   include/linux/math64.h:259:2: error: couldn't allocate output register for constraint 'x'
           do_div(rl.ll, divisor);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
>> kernel/time/timekeeping.c:328:2: error: couldn't allocate output register for constraint 'x'
           do_div(tmp, clock->mult);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   3 errors generated.
--
>> kernel/time/clocksource.c:67:3: error: couldn't allocate output register for constraint 'x'
                   do_div(tmp, from);
                   ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   kernel/time/clocksource.c:675:2: error: couldn't allocate output register for constraint 'x'
           do_div(max_cycles, mult+maxadj);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   kernel/time/clocksource.c:869:3: error: couldn't allocate output register for constraint 'x'
                   do_div(sec, freq);
                   ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   kernel/time/clocksource.c:870:3: error: couldn't allocate output register for constraint 'x'
                   do_div(sec, scale);
                   ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   4 errors generated.
--
>> kernel/time/jiffies.c:112:2: error: couldn't allocate output register for constraint 'x'
           do_div(shift_hz, cycles_per_tick);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   kernel/time/jiffies.c:116:2: error: couldn't allocate output register for constraint 'x'
           do_div(nsec_per_tick, (u32)shift_hz);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   2 errors generated.
--
>> kernel/time/clockevents.c:72:2: error: couldn't allocate output register for constraint 'x'
           do_div(clc, evt->mult);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   1 error generated.
--
   In file included from block/partitions/core.c:12:
   In file included from include/linux/blktrace_api.h:5:
>> include/linux/blkdev.h:1499:27: error: couldn't allocate output register for constraint 'x'
           unsigned int alignment = sector_div(sector, granularity >> SECTOR_SHIFT)
                                    ^
   include/linux/math.h:121:26: note: expanded from macro 'sector_div'
   #define sector_div(a, b) do_div(a, b)
                            ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   In file included from block/partitions/core.c:12:
   In file included from include/linux/blktrace_api.h:5:
   include/linux/blkdev.h:1539:11: error: couldn't allocate output register for constraint 'x'
           offset = sector_div(sector, granularity);
                    ^
   include/linux/math.h:121:26: note: expanded from macro 'sector_div'
   #define sector_div(a, b) do_div(a, b)
                            ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   2 errors generated.
--
   In file included from drivers/mtd/mtdcore.c:32:
>> include/linux/mtd/mtd.h:572:2: error: couldn't allocate output register for constraint 'x'
           do_div(sz, mtd->erasesize);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   In file included from drivers/mtd/mtdcore.c:32:
   include/linux/mtd/mtd.h:580:9: error: couldn't allocate output register for constraint 'x'
           return do_div(sz, mtd->erasesize);
                  ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   In file included from drivers/mtd/mtdcore.c:32:
   include/linux/mtd/mtd.h:615:2: error: couldn't allocate output register for constraint 'x'
           do_div(sz, mtd->writesize);
           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   3 errors generated.
--
>> drivers/mtd/mtdconcat.c:861:7: error: couldn't allocate output register for constraint 'x'
                                                   do_div(tmp64, curr_erasesize);
                                                   ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/mtdconcat.c:842:6: error: couldn't allocate output register for constraint 'x'
                                           do_div(tmp64, curr_erasesize);
                                           ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/mtdconcat.c:880:3: error: couldn't allocate output register for constraint 'x'
                   do_div(tmp64, curr_erasesize);
                   ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/mtdconcat.c:202:7: error: couldn't allocate output register for constraint 'x'
                   if (do_div(__to, mtd->writesize) || (total_len % mtd->writesize))
                       ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   4 errors generated.
--
>> drivers/mtd/mtdpart.c:94:15: error: couldn't allocate output register for constraint 'x'
                   remainder = do_div(tmp, wr_alignment);
                               ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/mtdpart.c:176:14: error: couldn't allocate output register for constraint 'x'
           remainder = do_div(tmp, wr_alignment);
                       ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/mtdpart.c:187:14: error: couldn't allocate output register for constraint 'x'
           remainder = do_div(tmp, wr_alignment);
                       ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   3 errors generated.
--
>> drivers/mtd/sm_ftl.c:210:13: error: couldn't allocate output register for constraint 'x'
           *boffset = do_div(offset, ftl->block_size);
                      ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   drivers/mtd/sm_ftl.c:211:11: error: couldn't allocate output register for constraint 'x'
           *block = do_div(offset, ftl->max_lba);
                    ^
   include/asm-generic/div64.h:245:11: note: expanded from macro 'do_div'
                   __rem = __div64_32(&(n), __base);       \
                           ^
   arch/mips/include/asm/div64.h:74:11: note: expanded from macro '__div64_32'
                   __asm__("divu   $0, %z1, %z2"                           \
                           ^
   2 errors generated.
..


vim +57 kernel/time/test_udelay.c

e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  27  
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  28  static int udelay_test_single(struct seq_file *s, int usecs, uint32_t iters)
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  29  {
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  30  	int min = 0, max = 0, fail_count = 0;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  31  	uint64_t sum = 0;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  32  	uint64_t avg;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  33  	int i;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  34  	/* Allow udelay to be up to 0.5% fast */
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  35  	int allowed_error_ns = usecs * 5;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  36  
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  37  	for (i = 0; i < iters; ++i) {
4a19bd3d22d51a kernel/time/test_udelay.c Arnd Bergmann 2016-06-17  38  		s64 kt1, kt2;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  39  		int time_passed;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  40  
4a19bd3d22d51a kernel/time/test_udelay.c Arnd Bergmann 2016-06-17  41  		kt1 = ktime_get_ns();
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  42  		udelay(usecs);
4a19bd3d22d51a kernel/time/test_udelay.c Arnd Bergmann 2016-06-17  43  		kt2 = ktime_get_ns();
4a19bd3d22d51a kernel/time/test_udelay.c Arnd Bergmann 2016-06-17  44  		time_passed = kt2 - kt1;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  45  
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  46  		if (i == 0 || time_passed < min)
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  47  			min = time_passed;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  48  		if (i == 0 || time_passed > max)
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  49  			max = time_passed;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  50  		if ((time_passed + allowed_error_ns) / 1000 < usecs)
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  51  			++fail_count;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  52  		WARN_ON(time_passed < 0);
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  53  		sum += time_passed;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  54  	}
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  55  
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  56  	avg = sum;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16 @57  	do_div(avg, iters);
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  58  	seq_printf(s, "%d usecs x %d: exp=%d allowed=%d min=%d avg=%lld max=%d",
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  59  			usecs, iters, usecs * 1000,
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  60  			(usecs * 1000) - allowed_error_ns, min, avg, max);
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  61  	if (fail_count)
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  62  		seq_printf(s, " FAIL=%d", fail_count);
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  63  	seq_puts(s, "\n");
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  64  
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  65  	return 0;
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  66  }
e704f93af5a083 kernel/time/udelay_test.c David Riley   2014-06-16  67  

:::::: The code@line 57 was first introduced by commit
:::::: e704f93af5a083c07b8f722672d63a1d908daf55 kernel: time: Add udelay_test module to validate udelay

:::::: TO: David Riley <davidriley@chromium.org>
:::::: CC: John Stultz <john.stultz@linaro.org>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 27107 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-21 22:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-21 22:58 [mips-linux:mips-next 98/101] kernel/time/test_udelay.c:57:2: error: couldn't allocate output register for constraint 'x' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.