[Libreoffice-commits] core.git: opencl/inc opencl/IwyuFilter_opencl.yaml opencl/source

Gabor Kelemen (via logerrit) logerrit at kemper.freedesktop.org
Wed May 29 07:12:53 UTC 2019


 opencl/IwyuFilter_opencl.yaml        |    6 ++++++
 opencl/inc/opencl_device.hxx         |    5 +++--
 opencl/inc/opencl_device_selection.h |    3 ---
 opencl/source/opencl_device.cxx      |    4 +---
 opencl/source/openclwrapper.cxx      |    6 +-----
 5 files changed, 11 insertions(+), 13 deletions(-)

New commits:
commit 61b7525869178464e100085e0f9a66ffc008e483
Author:     Gabor Kelemen <kelemen.gabor2 at nisz.hu>
AuthorDate: Tue May 14 01:02:55 2019 +0200
Commit:     Miklos Vajna <vmiklos at collabora.com>
CommitDate: Wed May 29 09:11:52 2019 +0200

    tdf#42949 Fix IWYU warnings in opencl/
    
    Found with bin/find-unneeded-includes
    Only removal proposals are dealt with here.
    
    Change-Id: I0aedc40c49c8cb1382f45571f54873d6017ec62c
    Reviewed-on: https://gerrit.libreoffice.org/72637
    Tested-by: Jenkins
    Reviewed-by: Miklos Vajna <vmiklos at collabora.com>

diff --git a/opencl/IwyuFilter_opencl.yaml b/opencl/IwyuFilter_opencl.yaml
new file mode 100644
index 000000000000..10b5be193d18
--- /dev/null
+++ b/opencl/IwyuFilter_opencl.yaml
@@ -0,0 +1,6 @@
+---
+assumeFilename: opencl/source/opencl_device.cxx
+blacklist:
+    opencl/source/opencl_device.cxx:
+    # Avoid loplugin:unreffun error
+    - opencl_device.hxx
diff --git a/opencl/inc/opencl_device.hxx b/opencl/inc/opencl_device.hxx
index b69cbabc28a5..93cc5f7a1271 100644
--- a/opencl/inc/opencl_device.hxx
+++ b/opencl/inc/opencl_device.hxx
@@ -10,9 +10,10 @@
 #ifndef INCLUDED_OPENCL_INC_OPENCL_DEVICE_HXX
 #define INCLUDED_OPENCL_INC_OPENCL_DEVICE_HXX
 
-#include <opencl/openclwrapper.hxx>
+#include <rtl/ustring.hxx>
 
-#include "opencl_device_selection.h"
+namespace openclwrapper { struct GPUEnv; }
+struct ds_device;
 
 ds_device const & getDeviceSelection(OUString const & pFileName, bool bForceSelection);
 
diff --git a/opencl/inc/opencl_device_selection.h b/opencl/inc/opencl_device_selection.h
index 982b65a5187c..2acb67047c4e 100644
--- a/opencl/inc/opencl_device_selection.h
+++ b/opencl/inc/opencl_device_selection.h
@@ -17,9 +17,6 @@
 #include <memory>
 
 #include <float.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
 
 #include <clew/clew.h>
 #include <tools/stream.hxx>
diff --git a/opencl/source/opencl_device.cxx b/opencl/source/opencl_device.cxx
index 55f594ba713f..d6b59729c14a 100644
--- a/opencl/source/opencl_device.cxx
+++ b/opencl/source/opencl_device.cxx
@@ -7,17 +7,14 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
  */
 
-#include <math.h>
 #include <float.h>
 #include <iostream>
-#include <sstream>
 #include <memory>
 #include <vector>
 #include <algorithm>
 
 #include <comphelper/random.hxx>
 #include <opencl/openclconfig.hxx>
-#include <opencl/openclwrapper.hxx>
 #include <opencl/platforminfo.hxx>
 #include <sal/log.hxx>
 #include <rtl/math.hxx>
@@ -26,6 +23,7 @@
 #include <opencl/OpenCLZone.hxx>
 
 #include <opencl_device.hxx>
+#include <opencl_device_selection.h>
 
 #define INPUTSIZE  15360
 #define OUTPUTSIZE 15360
diff --git a/opencl/source/openclwrapper.cxx b/opencl/source/openclwrapper.cxx
index 26a5e6b7f1b8..ffb1cc788f31 100644
--- a/opencl/source/openclwrapper.cxx
+++ b/opencl/source/openclwrapper.cxx
@@ -10,6 +10,7 @@
 #include <config_folders.h>
 
 #include <opencl_device.hxx>
+#include <opencl_device_selection.h>
 
 #include <opencl/openclconfig.hxx>
 #include <opencl/openclwrapper.hxx>
@@ -24,13 +25,8 @@
 #include <opencl/OpenCLZone.hxx>
 
 #include <memory>
-#include <unicode/regex.h>
 
-#include <stdio.h>
 #include <stdlib.h>
-#include <string.h>
-
-#include <cmath>
 
 #include <officecfg/Office/Common.hxx>
 


More information about the Libreoffice-commits mailing list