diff options
| author | Nuno Lopes <nunoplopes@sapo.pt> | 2009-11-12 15:10:33 +0000 |
|---|---|---|
| committer | Nuno Lopes <nunoplopes@sapo.pt> | 2009-11-12 15:10:33 +0000 |
| commit | f8fcac7470793ac2315873a12bec6c98778f8724 (patch) | |
| tree | 79e8ef7561deb67f659b2f72e91bfdd21e7c8ff5 /llvm/lib/Support/ConstantRange.cpp | |
| parent | 60d5b1cfdbfff556492282317bfaf8cc5aa44920 (diff) | |
| download | bcm5719-llvm-f8fcac7470793ac2315873a12bec6c98778f8724.tar.gz bcm5719-llvm-f8fcac7470793ac2315873a12bec6c98778f8724.zip | |
fix crash in my previous patch
llvm-svn: 86987
Diffstat (limited to 'llvm/lib/Support/ConstantRange.cpp')
| -rw-r--r-- | llvm/lib/Support/ConstantRange.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Support/ConstantRange.cpp b/llvm/lib/Support/ConstantRange.cpp index 4593eb9dff9..e427f820c44 100644 --- a/llvm/lib/Support/ConstantRange.cpp +++ b/llvm/lib/Support/ConstantRange.cpp @@ -618,7 +618,7 @@ ConstantRange::shl(const ConstantRange &Amount) const { APInt max = getUnsignedMax() << Amount.getUnsignedMax(); // there's no overflow! - APInt Zeros(sizeof(unsigned)*8, getUnsignedMax().countLeadingZeros()); + APInt Zeros(getBitWidth(), getUnsignedMax().countLeadingZeros()); if (Zeros.uge(Amount.getUnsignedMax())) return ConstantRange(min, max); |

