Skip to contentSkip to conversation

lib/crypto/mips/poly1305-core.S:95: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'

DISCUSSION kernel test robot 3 participants 4 messages Mar 20 – Mar 31

Subsystems (2)
lore
Share & tools
lore

kernel test robot

author build bot
#0 lore raw

Hi Eric,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   0e4f8f1a3d081e834be5fd0a62bdb2554fadd307
commit: 7e54e993ab8c98d912f54ad6f46bfcc9dcd65368 lib/crypto: mips: Move arch/mips/lib/crypto/ into lib/crypto/
date:   9 months ago
config: mips-randconfig-r131-20260320 (https://download.01.org/0day-ci/archive/20260321/[email protected]/config)
compiler: mips-linux-gcc (GCC) 11.5.0
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260321/[email protected]/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 <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

All errors (new ones prefixed by >>):

lib/crypto/mips/poly1305-core.S: Assembler messages:

>> lib/crypto/mips/poly1305-core.S:95: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'
   lib/crypto/mips/poly1305-core.S:96: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $9,4+3($5)'
   lib/crypto/mips/poly1305-core.S:97: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $10,8+3($5)'
   lib/crypto/mips/poly1305-core.S:98: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $11,12+3($5)'
>> lib/crypto/mips/poly1305-core.S:99: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $8,0+0($5)'
   lib/crypto/mips/poly1305-core.S:100: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $9,4+0($5)'
   lib/crypto/mips/poly1305-core.S:101: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $10,8+0($5)'
   lib/crypto/mips/poly1305-core.S:102: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $11,12+0($5)'
   lib/crypto/mips/poly1305-core.S:265: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'
   lib/crypto/mips/poly1305-core.S:266: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $9,4+3($5)'
   lib/crypto/mips/poly1305-core.S:267: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $10,8+3($5)'
   lib/crypto/mips/poly1305-core.S:268: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $11,12+3($5)'
   lib/crypto/mips/poly1305-core.S:269: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $8,0+0($5)'
   lib/crypto/mips/poly1305-core.S:270: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $9,4+0($5)'
   lib/crypto/mips/poly1305-core.S:271: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $10,8+0($5)'
   lib/crypto/mips/poly1305-core.S:272: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwr $11,12+0($5)'
>> lib/crypto/mips/poly1305-core.S:395: Error: opcode not supported on this processor: mips64r6 (mips64r6) `multu $17,$8'
>> lib/crypto/mips/poly1305-core.S:396: Error: opcode not supported on this processor: mips64r6 (mips64r6) `mflo $12'
>> lib/crypto/mips/poly1305-core.S:397: Error: opcode not supported on this processor: mips64r6 (mips64r6) `mfhi $13'

lib/crypto/mips/poly1305-core.S:402: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $23,$9' lib/crypto/mips/poly1305-core.S:403: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:404: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:410: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $22,$10' lib/crypto/mips/poly1305-core.S:411: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:412: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $24' lib/crypto/mips/poly1305-core.S:415: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $21,$11' lib/crypto/mips/poly1305-core.S:419: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:420: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:423: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $18,$8' lib/crypto/mips/poly1305-core.S:428: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:429: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $14' lib/crypto/mips/poly1305-core.S:432: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $17,$9' lib/crypto/mips/poly1305-core.S:436: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:437: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:440: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $23,$10' lib/crypto/mips/poly1305-core.S:443: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:444: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $24' lib/crypto/mips/poly1305-core.S:447: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $22,$11' lib/crypto/mips/poly1305-core.S:451: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:452: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:455: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $21,$16' lib/crypto/mips/poly1305-core.S:459: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:462: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $19,$8' lib/crypto/mips/poly1305-core.S:467: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:468: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $15' lib/crypto/mips/poly1305-core.S:471: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $18,$9' lib/crypto/mips/poly1305-core.S:474: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:475: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $24' lib/crypto/mips/poly1305-core.S:478: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $17,$10' lib/crypto/mips/poly1305-core.S:481: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:482: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:485: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $23,$11' lib/crypto/mips/poly1305-core.S:489: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:490: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $24' lib/crypto/mips/poly1305-core.S:493: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $22,$16' lib/crypto/mips/poly1305-core.S:497: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:500: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $20,$8' lib/crypto/mips/poly1305-core.S:505: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:506: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $24' lib/crypto/mips/poly1305-core.S:509: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $19,$9' lib/crypto/mips/poly1305-core.S:512: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:513: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:516: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $17,$11' lib/crypto/mips/poly1305-core.S:519: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:520: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $11' lib/crypto/mips/poly1305-core.S:523: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $18,$10' lib/crypto/mips/poly1305-core.S:527: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $1' lib/crypto/mips/poly1305-core.S:528: Error: opcode not supported on this processor: mips64r6 (mips64r6) mfhi $2' lib/crypto/mips/poly1305-core.S:531: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $23,$16' lib/crypto/mips/poly1305-core.S:535: Error: opcode not supported on this processor: mips64r6 (mips64r6) mflo $7' lib/crypto/mips/poly1305-core.S:538: Error: opcode not supported on this processor: mips64r6 (mips64r6) multu $17,$16' lib/crypto/mips/poly1305-core.S:543: Error: opcode not supported on this processor: mips64r6 (mips64r6) `mflo $16'

Signature · 2 lines
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
#1 lore raw

[+Cc linux-mips and linux-crypto]

Quoted 18 lines · kernel test robot

Hi Eric,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   0e4f8f1a3d081e834be5fd0a62bdb2554fadd307
commit: 7e54e993ab8c98d912f54ad6f46bfcc9dcd65368 lib/crypto: mips: Move arch/mips/lib/crypto/ into lib/crypto/
date:   9 months ago
config: mips-randconfig-r131-20260320 (https://download.01.org/0day-ci/archive/20260321/[email protected]/config)
compiler: mips-linux-gcc (GCC) 11.5.0
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260321/[email protected]/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 <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/

Quoted 7 lines

All errors (new ones prefixed by >>):

lib/crypto/mips/poly1305-core.S: Assembler messages:

Quoted 1 line
Quoted 1 line

lib/crypto/mips/poly1305-core.S:95: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'

lib/crypto/mips/poly1305-core.S:96: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $9,4+3($5)' lib/crypto/mips/poly1305-core.S:97: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $10,8+3($5)' lib/crypto/mips/poly1305-core.S:98: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $11,12+3($5)'

This isn't new. It was first reported in 2021:
https://lore.kernel.org/all/[email protected]/

It's caused by:

CONFIG_64BIT=n causes the 32-bit Poly1305 assembly code to be generated. That code checks the _MIPS_ARCH_MIPS32R6 macro. But, the code is actually built with -march=mips64r6, due to CONFIG_CPU_MIPS64_R6=y. Thus _MIPS_ARCH_MIPS32R6 is not defined; _MIPS_ARCH_MIPS64R6 is defined instead. So the wrong code gets built.

Maybe someone from [email protected] can confirm whether CONFIG_64BIT=n && CONFIG_CPU_MIPS64_R6=y actually makes sense?

- Eric

#2 lore raw
Quoted 13 lines · Eric Biggers
Quoted 7 lines

All errors (new ones prefixed by >>):

lib/crypto/mips/poly1305-core.S: Assembler messages:

Quoted 1 line
Quoted 1 line

lib/crypto/mips/poly1305-core.S:95: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'

lib/crypto/mips/poly1305-core.S:96: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $9,4+3($5)' lib/crypto/mips/poly1305-core.S:97: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $10,8+3($5)' lib/crypto/mips/poly1305-core.S:98: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $11,12+3($5)'

This isn't new. It was first reported in 2021:
https://lore.kernel.org/all/[email protected]/

It's caused by:

Quoted 8 lines

CONFIG_64BIT=n causes the 32-bit Poly1305 assembly code to be generated. That code checks the _MIPS_ARCH_MIPS32R6 macro. But, the code is actually built with -march=mips64r6, due to CONFIG_CPU_MIPS64_R6=y. Thus _MIPS_ARCH_MIPS32R6 is not defined; _MIPS_ARCH_MIPS64R6 is defined instead. So the wrong code gets built.

Maybe someone from [email protected] can confirm whether CONFIG_64BIT=n && CONFIG_CPU_MIPS64_R6=y actually makes sense?

Absolutely, you can build a 32-bit kernel for and run on 64-bit hardware
and we have supported it since forever across all the MIPS architecture revisions.

You probably want to check for CONFIG_CPU_MIPSR6 instead (and similarly
for CONFIG_CPU_MIPSR2, etc.).

Maciej

#3 lore raw
Quoted 24 lines · Maciej W. Rozycki
Quoted 13 lines · Eric Biggers
Quoted 7 lines

All errors (new ones prefixed by >>):

lib/crypto/mips/poly1305-core.S: Assembler messages:

Quoted 1 line
Quoted 1 line

lib/crypto/mips/poly1305-core.S:95: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $8,0+3($5)'

lib/crypto/mips/poly1305-core.S:96: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $9,4+3($5)' lib/crypto/mips/poly1305-core.S:97: Error: opcode not supported on this processor: mips64r6 (mips64r6) lwl $10,8+3($5)' lib/crypto/mips/poly1305-core.S:98: Error: opcode not supported on this processor: mips64r6 (mips64r6) `lwl $11,12+3($5)'

This isn't new. It was first reported in 2021:
https://lore.kernel.org/all/[email protected]/

It's caused by:

Quoted 8 lines

CONFIG_64BIT=n causes the 32-bit Poly1305 assembly code to be generated. That code checks the _MIPS_ARCH_MIPS32R6 macro. But, the code is actually built with -march=mips64r6, due to CONFIG_CPU_MIPS64_R6=y. Thus _MIPS_ARCH_MIPS32R6 is not defined; _MIPS_ARCH_MIPS64R6 is defined instead. So the wrong code gets built.

Maybe someone from [email protected] can confirm whether CONFIG_64BIT=n && CONFIG_CPU_MIPS64_R6=y actually makes sense?

Quoted 6 lines

Absolutely, you can build a 32-bit kernel for and run on 64-bit hardware
and we have supported it since forever across all the MIPS architecture revisions.

You probably want to check for CONFIG_CPU_MIPSR6 instead (and similarly
for CONFIG_CPU_MIPSR2, etc.).

Okay, but does it make sense to use -march=mips64r6 in that case, instead of -march=mips32r6? I guess you get something that uses the 32-bit ABI but is free to use 64-bit instructions? It looks like poly1305-mips.pl doesn't really support that combination: it just has 32-bit ABI + 32-bit instructions, and 64-bit ABI + 64-bit instructions.

Maybe it would be easiest to always compile poly1305-mips.pl with the corresponding mips32 flag when CONFIG_64BIT is unset? Note: since poly1305-mips.pl was taken from an external source
(https://github.com/dot-asm/cryptogams/blob/master/mips/poly1305-mips.pl),
modifying the build system to pass the appropriate flag might be preferable to extensive local patching of that file.

- Eric