mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-01 17:23:59 +00:00
Bug 1357734 - Change argument of DisplayListBuilder::PushBorder() to bypass compiler bug r=jrmuizel
Visual Studio 2015 Update 3 has a bug that PGO build generates movaps to unaligned address. The patch just bypasses the compiler bu
This commit is contained in:
parent
bea091ec98
commit
178043d1da
@ -795,15 +795,16 @@ void
|
||||
DisplayListBuilder::PushBorder(const WrRect& aBounds,
|
||||
const WrRect& aClip,
|
||||
const WrBorderWidths& aWidths,
|
||||
const WrBorderSide& aTop,
|
||||
const WrBorderSide& aRight,
|
||||
const WrBorderSide& aBottom,
|
||||
const WrBorderSide& aLeft,
|
||||
const Range<const WrBorderSide>& aSides,
|
||||
const WrBorderRadius& aRadius)
|
||||
{
|
||||
MOZ_ASSERT(aSides.length() == 4);
|
||||
if (aSides.length() != 4) {
|
||||
return;
|
||||
}
|
||||
WrClipRegionToken tok = wr_dp_push_clip_region(mWrState, aClip, nullptr, 0, nullptr);
|
||||
wr_dp_push_border(mWrState, aBounds, tok,
|
||||
aWidths, aTop, aRight, aBottom, aLeft, aRadius);
|
||||
aWidths, aSides[0], aSides[1], aSides[2], aSides[3], aRadius);
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -232,13 +232,12 @@ public:
|
||||
const WrRect& aClip,
|
||||
wr::PipelineId aPipeline);
|
||||
|
||||
// XXX WrBorderSides are passed with Range.
|
||||
// It is just to bypass compiler bug. See Bug 1357734.
|
||||
void PushBorder(const WrRect& aBounds,
|
||||
const WrRect& aClip,
|
||||
const WrBorderWidths& aWidths,
|
||||
const WrBorderSide& aTop,
|
||||
const WrBorderSide& aRight,
|
||||
const WrBorderSide& aBbottom,
|
||||
const WrBorderSide& aLeft,
|
||||
const Range<const WrBorderSide>& aSides,
|
||||
const WrBorderRadius& aRadius);
|
||||
|
||||
void PushBorderImage(const WrRect& aBounds,
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include "gfxGradientCache.h"
|
||||
#include "mozilla/layers/StackingContextHelper.h"
|
||||
#include "mozilla/layers/WebRenderDisplayItemLayer.h"
|
||||
#include "mozilla/Range.h"
|
||||
#include <algorithm>
|
||||
|
||||
using namespace mozilla;
|
||||
@ -3565,10 +3566,11 @@ nsCSSBorderRenderer::CreateWebRenderCommands(wr::DisplayListBuilder& aBuilder,
|
||||
LayerSize(mBorderRadii[1].width, mBorderRadii[1].height),
|
||||
LayerSize(mBorderRadii[3].width, mBorderRadii[3].height),
|
||||
LayerSize(mBorderRadii[2].width, mBorderRadii[2].height));
|
||||
Range<const WrBorderSide> wrsides(side, 4);
|
||||
aBuilder.PushBorder(transformedRect,
|
||||
transformedRect,
|
||||
wr::ToWrBorderWidths(mBorderWidths[0], mBorderWidths[1], mBorderWidths[2], mBorderWidths[3]),
|
||||
side[0], side[1], side[2], side[3],
|
||||
wrsides,
|
||||
borderRadius);
|
||||
}
|
||||
|
||||
|
@ -39,6 +39,7 @@
|
||||
#include "nsFrameManager.h"
|
||||
#include "nsError.h"
|
||||
#include "nsCSSFrameConstructor.h"
|
||||
#include "mozilla/Range.h"
|
||||
#include "mozilla/ServoRestyleManager.h"
|
||||
#include "mozilla/ServoStyleSet.h"
|
||||
#include "mozilla/StyleSetHandle.h"
|
||||
@ -7436,10 +7437,11 @@ BCBlockDirSeg::CreateWebRenderCommands(BCPaintBorderIterator& aIter,
|
||||
transformedRect.width,
|
||||
transformedRect.width);
|
||||
transformedRect.width *= 2.0f;
|
||||
Range<const WrBorderSide> wrsides(wrSide, 4);
|
||||
aBuilder.PushBorder(transformedRect,
|
||||
transformedRect,
|
||||
borderWidths,
|
||||
wrSide[0], wrSide[1], wrSide[2], wrSide[3],
|
||||
wrsides,
|
||||
borderRadii);
|
||||
}
|
||||
|
||||
@ -7694,10 +7696,11 @@ BCInlineDirSeg::CreateWebRenderCommands(BCPaintBorderIterator& aIter,
|
||||
transformedRect.height,
|
||||
transformedRect.height);
|
||||
transformedRect.height *= 2.0f;
|
||||
Range<const WrBorderSide> wrsides(wrSide, 4);
|
||||
aBuilder.PushBorder(transformedRect,
|
||||
transformedRect,
|
||||
borderWidths,
|
||||
wrSide[0], wrSide[1], wrSide[2], wrSide[3],
|
||||
wrsides,
|
||||
borderRadii);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user