Skip to content

[DAG] SimplifyDemandedBits/SimplifyDemandedVectorElts - improve handling of multiple uses of MemSDNode chain #126764

@RKSimon

Description

@RKSimon

When calling both SimplifyDemandedBits/SimplifyDemandedVectorElts, we check if the entire node has multiple uses and then set the demandedbits/elts to ALL if it does.

But for memory loads (inc. MemIntrinsicSDNode) this behaves poorly with cases if all but one of the uses are for the memory chain - we should still be able to create a new MemSDNode (with adjusted memory width etc.) if we only use the loaded result once, as long as users of the chain are updated afterward.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions