[all-commits] [llvm/llvm-project] 9250d4: [ValueTracking] Extend computeConstantRange for ad...
Guy David via All-commits
all-commits at lists.llvm.org
Thu Feb 12 01:43:05 PST 2026
Branch: refs/heads/users/guy-david/value-tracking-constant-range
Home: https://github.com/llvm/llvm-project
Commit: 9250d4e7e4f5274db96fab5ee8faa76a594178b9
https://github.com/llvm/llvm-project/commit/9250d4e7e4f5274db96fab5ee8faa76a594178b9
Author: Guy David <guyda96 at gmail.com>
Date: 2026-02-12 (Thu, 12 Feb 2026)
Changed paths:
M llvm/lib/Analysis/ValueTracking.cpp
M llvm/test/Analysis/BasicAA/range.ll
M llvm/unittests/Analysis/ValueTrackingTest.cpp
Log Message:
-----------
[ValueTracking] Extend computeConstantRange for add/sub, sext/zext/trunc
Recursively compute operand ranges for add/sub and propagate ranges
through sext/zext/trunc.
For add/sub, the computed range is intersected with any existing range
from setLimitsForBinOp, and NSW/NUW flags are used via addWithNoWrap/
subWithNoWrap to tighten bounds.
The motivation is to enable further folding of reduce.add expressions
in comparisons, where the result range can be bounded by the input
element ranges.
Compile-time impact on llvm-test-suite is <0.1% mean.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list