[llvm] [X86] added computeKnownBits for X86ISD::GF2P8AFFINEQB (PR #194197)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 28 08:54:35 PDT 2026


RKSimon wrote:

> > > > I'm not sure if its worth trying to do this for a non-constant Matrix operands tbh - I'd expect we should just use getTargetConstantBitsFromNode() and use that with the Input operand's known bits.
> > > 
> > > 
> > > so do you suggest adding a break statement when matrix is runtime variable ? also shouldn't this be covered in test cases ?
> > 
> > 
> > what test cases? you haven't added any yet
> 
> no i am saying this behavior of runtime matrix ? should this be tested ?

My concern is the inner computeKnownBits call for the Matrix is called 8 times, which could have a considerable impact on compile time, and I'm not certain that it will improve the final result much more than a constant value will. I suppose there's GF2 expansions that have a constant Input and variable Matrix? Maybe we should consider doing the 2 cases separately?

https://github.com/llvm/llvm-project/pull/194197


More information about the llvm-commits mailing list