[Webkit-unassigned] [Bug 107444] Add error checking into OpenCL version of SVG filters.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Jan 28 00:56:42 PST 2013
https://bugs.webkit.org/show_bug.cgi?id=107444
Zoltan Herczeg <zherczeg at webkit.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #184446|review?, commit-queue? |review-, commit-queue-
Flag| |
--- Comment #7 from Zoltan Herczeg <zherczeg at webkit.org> 2013-01-28 00:58:38 PST ---
(From update of attachment 184446)
Nice patch, but some minor fixes are needed:
View in context: https://bugs.webkit.org/attachment.cgi?id=184446&action=review
> Source/WebCore/ChangeLog:3
> + Add error checking into OpenCL version of SVG filters.
Could you add a little more description what this patch does?
> Source/WebCore/platform/graphics/filters/FilterEffect.cpp:484
> + int errorCode;
Is this error code set to 0 if an error occures?
> Source/WebCore/platform/graphics/filters/FilterEffect.cpp:515
> + if (context->inError())
> + return;
> context->openCLTransformColorSpace(m_openCLImageResult, absolutePaintRect(), m_resultColorSpace, dstColorSpace);
I think this error check should be done by openCLTransformColorSpace.
> Source/WebCore/platform/graphics/gpu/opencl/FilterContextOpenCL.cpp:96
> + deleteResource(m_matrixOperation);
freeResource?
> Source/WebCore/platform/graphics/gpu/opencl/FilterContextOpenCL.cpp:112
> + deleteResource(m_transformColorSpaceKernel);
> + deleteResource(m_transformColorSpaceProgram);
> +
Extra newline
> Source/WebCore/platform/graphics/gpu/opencl/FilterContextOpenCL.cpp:183
> + m_transformColorSpaceCompileStatus = openclCompileSuccessful;
What about partially completed compilations? I think the 3 states of these status flags are not necessary anymore after we introduced the error status of the context. They should be simply bools, and tell whether the compilation was attempted.
> Source/WebCore/platform/graphics/gpu/opencl/FilterContextOpenCL.h:173
> + static void deleteResource(cl_kernel);
> + static void deleteResource(cl_program);
Shouldn't these accept references? (cl_kernel& and cl_program&) Otherwise the = 0 has no effect. Furthermore these fuctions should be inline.
> Source/WebCore/platform/graphics/gpu/opencl/OpenCLFETurbulence.cpp:176
> + if (inError())
> + return;
> +
> if (m_turbulenceCompileStatus != openclNotCompiledYet)
> - return m_turbulenceCompileStatus == openclCompileSuccessful;
> + return;
These two can be combined together, and likely the first one is not needed at all.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list