Created attachment 559364 [details] [diff] [review] move innards of gfxAlphaBoxBlur to mozilla::gfx::AlphaBoxBlur In order to implement shadows in the Cairo Azure backend, we need to have Gaussian blur support. The easiest way to do that is to to make the innards of gfxAlphaBoxBlur into their own class that uses it. This patch does that, creating mozilla::gfx::AlphaBoxBlur.
Backed out for leaking (see Bug 703125). https://hg.mozilla.org/mozilla-central/rev/b62e6ee5ba9b
With next psuh don't forget bug 702683 patch
Stupid bugzilla - was only adding myself and if closed - Reopening
Created attachment 575377 [details] [diff] [review] work around compiler bug It seems that MSVC has a compiler bug that's triggered by AlphaBoxBlur being in the namespace mozilla::gfx. Due to link-time optimization, instead of calling an nsAutoPtr destructor that calls |delete ptr|, it calls a destructor that calls |delete ptr|, which doesn't call AlphaBoxBlur's destructor at all. If we move AlphaBoxBlur to the global namespace, the bug doesn't manifest itself. And since we don't want to do that, if we change from nsAutoPtr to a raw ptr, and call delete on it manually in gfxBlur's destructor, this bug also disappears. This is an interdiff, on top of the previous patch.
I've just pushed the combined patches on this bug, as well as the fix to bug 702683, to inbound: https://hg.mozilla.org/integration/mozilla-inbound/rev/5549f4202af8
Joe, can you file a separate bug on investigating if there are any other uses of nsAutoPtr being miscompiled by MSVC?
(In reply to Joe Drew (:JOEDREW!) from comment #6) > I've just pushed the combined patches on this bug, as well as the fix to bug > 702683, to inbound: > https://hg.mozilla.org/integration/mozilla-inbound/rev/5549f4202af8 https://hg.mozilla.org/mozilla-central/rev/5549f4202af8 (But don't forget comment 8 :-))
(In reply to Kyle Huey [:khuey] (email@example.com) from comment #8) > Joe, can you file a separate bug on investigating if there are any other > uses of nsAutoPtr being miscompiled by MSVC? This is (mentored) bug 704304.
I think fixed-point division introduced by Bug 633627 has been returned again to integer division by the patch of this bug. Isn't this a regression?
(In reply to Tetsuro Kato (Tete) from comment #11) > I think fixed-point division introduced by Bug 633627 has been returned > again to integer division by the patch of this bug. Isn't this a regression? Yes it is, can you file a new bug for it?
Fired a new bug. https://bugzilla.mozilla.org/show_bug.cgi?id=739969