[PATCH] D99409: [clang] Speedup line offset mapping computation
Nico Weber via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 7 07:27:01 PDT 2021
thakis added inline comments.
================
Comment at: clang/lib/Basic/SourceManager.cpp:1262
+ unsigned char n) {
+ return ((x - ~0UL / 255 * (n + 1)) & ~x &
+ (x & ~0UL / 255 * 127) + ~0UL / 255 * (127 - (m - 1))) &
----------------
UL is 32-bit on windows but 64-bit on linux/mac in 64-bit builds (LP64 vs LLP64). Maybe you want 0ULL here?
If so, then you should be able to repro this on linux by building a 32-bit clang binary there.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99409/new/
https://reviews.llvm.org/D99409
More information about the llvm-commits
mailing list