[all-commits] [llvm/llvm-project] 79647b: [CIR] Exclude _BitInt from fundamental integer typ...
adams381 via All-commits
all-commits at lists.llvm.org
Mon Apr 13 12:28:58 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 79647b11b2df6209cbbc80ebcf0e1cb60bd3df52
https://github.com/llvm/llvm-project/commit/79647b11b2df6209cbbc80ebcf0e1cb60bd3df52
Author: adams381 <adams at nvidia.com>
Date: 2026-04-13 (Mon, 13 Apr 2026)
Changed paths:
M clang/include/clang/CIR/Dialect/IR/CIRTypeConstraints.td
M clang/include/clang/CIR/Dialect/IR/CIRTypes.td
A clang/test/CIR/IR/invalid-bitint.cir
Log Message:
-----------
[CIR] Exclude _BitInt from fundamental integer type constraints (#191493)
Follow-up to #188113 per @erichkeane's feedback: `isFundamentalIntType`
and `isFundamental()` should not disagree.
The previous patch added `!isBitInt()` only inside
`IntType::isFundamental()`, leaving the underlying TableGen predicates
(`CIR_AnyFundamentalIntType` etc.) unaware of `_BitInt`. That meant
`isSignedFundamental()` and `isUnsignedFundamental()` were silently
wrong — a `_BitInt(32)` would pass them.
This patch adds a `CIR_IsNotBitIntPred` to the three fundamental-int
constraint defs so everything stays consistent. `isFundamental()` now
just forwards to `isFundamentalIntType()` with no extra logic.
Includes an `invalid-bitint.cir` test that checks a `_BitInt(32)` is
rejected where a fundamental unsigned int is required.
Made with [Cursor](https://cursor.com)
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