* [xiang:lz4-macros 1/1] lib/lz4/lz4hc_compress.c:86:15: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
@ 2025-01-14 12:36 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-01-14 12:36 UTC (permalink / raw)
To: Gao Xiang; +Cc: llvm, oe-kbuild-all, Xiang Gao
tree: https://git.kernel.org/pub/scm/linux/kernel/git/xiang/linux.git lz4-macros
head: cc151de616805bc027b30cfc99853989274e2a2d
commit: cc151de616805bc027b30cfc99853989274e2a2d [1/1] include/linux/lz4.h: add some missing macros
config: arm-randconfig-002-20250114 (https://download.01.org/0day-ci/archive/20250114/202501142005.DqdNQGKc-lkp@intel.com/config)
compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project f5cd181ffbb7cb61d582fe130d46580d5969d47a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250114/202501142005.DqdNQGKc-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/202501142005.DqdNQGKc-lkp@intel.com/
All errors (new ones prefixed by >>):
>> lib/lz4/lz4hc_compress.c:86:15: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
86 | if (delta > MAX_DISTANCE)
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
lib/lz4/lz4hc_compress.c:87:12: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
87 | delta = MAX_DISTANCE;
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
2 errors generated.
--
>> lib/lz4/lz4_compress.c:287:17: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
287 | : (match + MAX_DISTANCE < ip))
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
lib/lz4/lz4_compress.c:416:16: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
416 | && (match + MAX_DISTANCE >= ip)
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
lib/lz4/lz4_compress.c:597:16: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
597 | : (match + MAX_DISTANCE < ip))
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
lib/lz4/lz4_compress.c:676:16: error: use of undeclared identifier 'LZ4_MAX_DISTANCE'
676 | if ((match + MAX_DISTANCE >= ip)
| ^
lib/lz4/lz4defs.h:96:22: note: expanded from macro 'MAX_DISTANCE'
96 | #define MAX_DISTANCE LZ4_MAX_DISTANCE
| ^
4 errors generated.
vim +/LZ4_MAX_DISTANCE +86 lib/lz4/lz4hc_compress.c
c72ac7a1a926db Chanho Min 2013-07-08 71
c72ac7a1a926db Chanho Min 2013-07-08 72 /* Update chains up to ip (excluded) */
4e1a33b105ddf2 Sven Schmidt 2017-02-24 73 static FORCE_INLINE void LZ4HC_Insert(LZ4HC_CCtx_internal *hc4,
4e1a33b105ddf2 Sven Schmidt 2017-02-24 74 const BYTE *ip)
c72ac7a1a926db Chanho Min 2013-07-08 75 {
4e1a33b105ddf2 Sven Schmidt 2017-02-24 76 U16 * const chainTable = hc4->chainTable;
4e1a33b105ddf2 Sven Schmidt 2017-02-24 77 U32 * const hashTable = hc4->hashTable;
c72ac7a1a926db Chanho Min 2013-07-08 78 const BYTE * const base = hc4->base;
4e1a33b105ddf2 Sven Schmidt 2017-02-24 79 U32 const target = (U32)(ip - base);
4e1a33b105ddf2 Sven Schmidt 2017-02-24 80 U32 idx = hc4->nextToUpdate;
4e1a33b105ddf2 Sven Schmidt 2017-02-24 81
4e1a33b105ddf2 Sven Schmidt 2017-02-24 82 while (idx < target) {
4e1a33b105ddf2 Sven Schmidt 2017-02-24 83 U32 const h = LZ4HC_hashPtr(base + idx);
4e1a33b105ddf2 Sven Schmidt 2017-02-24 84 size_t delta = idx - hashTable[h];
c72ac7a1a926db Chanho Min 2013-07-08 85
c72ac7a1a926db Chanho Min 2013-07-08 @86 if (delta > MAX_DISTANCE)
c72ac7a1a926db Chanho Min 2013-07-08 87 delta = MAX_DISTANCE;
c72ac7a1a926db Chanho Min 2013-07-08 88
4e1a33b105ddf2 Sven Schmidt 2017-02-24 89 DELTANEXTU16(idx) = (U16)delta;
c72ac7a1a926db Chanho Min 2013-07-08 90
4e1a33b105ddf2 Sven Schmidt 2017-02-24 91 hashTable[h] = idx;
4e1a33b105ddf2 Sven Schmidt 2017-02-24 92 idx++;
c72ac7a1a926db Chanho Min 2013-07-08 93 }
4e1a33b105ddf2 Sven Schmidt 2017-02-24 94
4e1a33b105ddf2 Sven Schmidt 2017-02-24 95 hc4->nextToUpdate = target;
c72ac7a1a926db Chanho Min 2013-07-08 96 }
c72ac7a1a926db Chanho Min 2013-07-08 97
:::::: The code at line 86 was first introduced by commit
:::::: c72ac7a1a926dbffb59daf0f275450e5eecce16f lib: add lz4 compressor module
:::::: TO: Chanho Min <chanho.min@lge.com>
:::::: CC: Linus Torvalds <torvalds@linux-foundation.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-01-14 12:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-14 12:36 [xiang:lz4-macros 1/1] lib/lz4/lz4hc_compress.c:86:15: error: use of undeclared identifier 'LZ4_MAX_DISTANCE' 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.