mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-25 16:24:23 +00:00
Fix a dagcombine to not generate loads of non-round integer types,
as its comment says, even in the case where it will be generating extending loads. This fixes PR3216. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62557 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -3343,7 +3343,7 @@ SDValue DAGCombiner::ReduceLoadWidth(SDNode *N) {
|
||||
|
||||
// Do not generate loads of non-round integer types since these can
|
||||
// be expensive (and would be wrong if the type is not byte sized).
|
||||
if (isa<LoadSDNode>(N0) && N0.hasOneUse() && VT.isRound() &&
|
||||
if (isa<LoadSDNode>(N0) && N0.hasOneUse() && EVT.isRound() &&
|
||||
cast<LoadSDNode>(N0)->getMemoryVT().getSizeInBits() > EVTBits &&
|
||||
// Do not change the width of a volatile load.
|
||||
!cast<LoadSDNode>(N0)->isVolatile()) {
|
||||
|
Reference in New Issue
Block a user