summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-11-03 11:29:10 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-11-03 11:39:33 +0100
commit5c47f33a640816ef1859e6f3b53aaafcdbce5e5c (patch)
tree9ac36985de0d23cfa15bdfbab561d0c54551939b
parent9ce9011230a97f3fe4fcd2f8d761781c4300772b (diff)
improve find-can-be-private script
add progress display and cleanup child processes Change-Id: I86cc13dee17f6d1ea2874f0ebe178426fbc82076 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124634 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--bin/find-can-be-private-symbols.classes.results46
-rwxr-xr-xbin/find-can-be-private-symbols.py14
-rw-r--r--sc/source/ui/inc/datatransformation.hxx2
3 files changed, 20 insertions, 42 deletions
diff --git a/bin/find-can-be-private-symbols.classes.results b/bin/find-can-be-private-symbols.classes.results
index b831d7ffbfbe..95ae4f12901d 100644
--- a/bin/find-can-be-private-symbols.classes.results
+++ b/bin/find-can-be-private-symbols.classes.results
@@ -5,7 +5,6 @@ BitmapEmbossGreyFilter
BitmapMedianFilter
BitmapMonochromeFilter
BitmapMosaicFilter
-BitmapPalette
BitmapPopArtFilter
BitmapSepiaFilter
BitmapShadowFilter
@@ -24,7 +23,6 @@ E3dCompoundObject
EditUndo
FmDesignModeChangedHint
FocusListenerMultiplexer
-FontSelectPattern
FontSubsetInfo
GalleryBinaryStorageLocations
GalleryStorageLocations
@@ -34,6 +32,7 @@ GrBackendSurfaceMutableState
GrBackendTexture
GrContextThreadSafeProxy
GrContext_Base
+GrDirectContext::DirectContextID
GrImageContext
GrRecordingContext
GrVkExtensions
@@ -51,22 +50,21 @@ MenuBarUpdateIconManager
MetaAction
MetaEPSAction
MetaGradientExAction
+MetaPointAction
MouseListenerMultiplexer
MouseMotionListenerMultiplexer
MyThes
NotifyEvent
OpenGLZone
PaintListenerMultiplexer
-PhysicalFontFamily
ProcessData
-Qt5SvpGraphics
+QtSvpGraphics
SalData
SalDisplay
SalInfoPrinter
SalPrinter
SalSystem
SbClassModuleObject
-ScChart2DataProvider
ScFormatEntry
ScMultiBlockUndo
ScPaintHint
@@ -82,7 +80,6 @@ SdOptionsLayout
SdOptionsMisc
SdOptionsPrint
SdOptionsSnap
-SdXImpressDocument
SdrCaptionEscDirItem
SdrCaptionTypeItem
SdrEdgeNode1HorzDistItem
@@ -118,29 +115,20 @@ SfxStyleSheetModifiedHint
SfxViewFrameItem
SfxVisibilityItem
SpinListenerMultiplexer
-SvtCompatibilityEntry
SvxPrintItem
SvxRsidItem
SvxShowText
SvxTPage
SwAnchoredObject
SwAuthenticator
-SwAutoCorrect
-SwBaseShell
SwColExample
SwConnectionListener
SwContrastGrf
-SwDocFac
SwDocShell::LockAllViewsGuard_Impl
SwDrawFrameFormat
SwDrawModeGrf
-SwDrawTextInfo
-SwEditWin
-SwEnvItem
SwExtraRedline
-SwExtraRedlineTable
SwFltRedline
-SwFlyFrame
SwFormatEditInReadonly
SwFormatEndAtTextEnd
SwFormatFollowTextFlow
@@ -148,38 +136,23 @@ SwFormatFootnoteAtTextEnd
SwFormatLayoutSplit
SwFormatNoBalancedColumns
SwFormatRowSplit
-SwFrame
SwGammaGrf
-SwHHCWrapper
-SwHTMLWriter
SwHeaderAndFooterEatSpacingItem
-SwHyphWrapper
SwLayoutFrame
SwLuminanceGrf
SwMirrorGrf
SwNumRuleItem
SwPagePreview
-SwReader
-SwReaderWriter
SwRect
SwRedlineExtraData
SwRedlineExtraData_FormatColl
-SwRootFrame
SwShellCursor
-SwSortedObjs
-SwSpellPopup
SwTableCellInfo::Impl
SwTableCellRedline
SwTableRowRedline
SwTestItem
-SwTextFrame
-SwTextShell
-SwTransferable
-SwUnoCursorHelper
-SwVisibleCursor
SwWebDocShell
SwWebView
-SwWriter
SwWrtShellItem
SwXTextRange::Impl
SwXTextTableCursor
@@ -235,6 +208,7 @@ covariant return thunk to ScEditWindow
dbtools::param::ParameterWrapper
desktop::CallbackFlushHandler
desktop::CallbackFlushHandler::CallbackData
+desktop::CallbackFlushHandler::TimeoutIdle
desktop::LibLODocument_Impl
desktop::LibLibreOffice_Impl
dp_misc::AbortChannel
@@ -279,23 +253,17 @@ oox::ole::AxTabStripModel
oox::ole::AxToggleButtonModel
oox::ole::AxUserFormModel
sc::CopyFromClipContext
-sc::DeleteRowTransformation
-sc::FindReplaceTransformation
-sc::FormulaGroupInterpreter
+sc::SwapRowsTransformation
sd::DrawView
sdr::SelectionController
sdr::ViewSelection
sdr::animation::primitiveAnimator
sdr::contact::ObjectContactPainter
+sk_app::WindowContext
svx::CommonStyleManager
svx::PropertyValueProvider
-sw::AccessibilityCheck
sw::BroadcastingModify
-sw::IndexingExport
-sw::ModelTraverser
-sw::UndoManager
sw::UnoCursorHint
-sw::search::SearchResultLocator
ucbhelper::ActiveDataSink
ucbhelper::InteractionAbort
ucbhelper::InteractionApprove
@@ -304,6 +272,7 @@ ucbhelper::InteractionRetry
ucbhelper::InteractionSupplyAuthentication
utl::OInputStreamHelper
vcl::ExtOutDevData
+vcl::ScriptRun
vcl::filter::PDFBooleanElement
vcl::filter::PDFCommentElement
vcl::filter::PDFEndObjectElement
@@ -311,6 +280,7 @@ vcl::filter::PDFEndStreamElement
vcl::filter::PDFHexStringElement
vcl::filter::PDFLiteralStringElement
vcl::filter::PDFNullElement
+vcl::printer::Options
writerperfect::DirectoryStream::Impl
xmloff::OControlBorderHandler
xmloff::OFontWidthHandler
diff --git a/bin/find-can-be-private-symbols.py b/bin/find-can-be-private-symbols.py
index 664c6bf4851b..a5e2459a4a01 100755
--- a/bin/find-can-be-private-symbols.py
+++ b/bin/find-can-be-private-symbols.py
@@ -53,6 +53,7 @@ with subprocess_find.stdout as txt:
if line_regex.match(line2):
sym = line2.split(" ")[2]
exported_symbols.add(sym)
+ subprocess_nm.terminate()
# look for imported symbols
subprocess_objdump = subprocess.Popen(b"objdump -T " + sharedlib, stdout=subprocess.PIPE, shell=True)
with subprocess_objdump.stdout as txt2:
@@ -65,10 +66,11 @@ with subprocess_find.stdout as txt:
# 0000000000000000 DF *UND* 0000000000000000 _ZN16FilterConfigItem10WriteInt32ERKN3rtl8OUStringEi
for line2_bytes in txt2:
line2 = line2_bytes.strip().decode("utf-8")
+ if not("*UND*"in line2): continue
tokens = line2.split(" ")
- if len(tokens) < 7 or not(tokens[7].startswith("*UND*")): continue
sym = tokens[len(tokens)-1]
imported_symbols.add(sym)
+ subprocess_objdump.terminate()
subprocess_find.terminate()
# look for imported symbols in executables
@@ -92,7 +94,10 @@ print("exported = " + str(len(exported_symbols)))
print("imported = " + str(len(imported_symbols)))
print("diff = " + str(len(diff)))
-for sym in exported_symbols:
+progress = 0;
+for sym in sorted(exported_symbols):
+ progress += 1
+ if (progress % 128 == 0): print( str(int(progress * 100 / len(exported_symbols))) + "%")
filtered_sym = subprocess.check_output(["c++filt", sym]).strip().decode("utf-8")
if filtered_sym.startswith("non-virtual thunk to "): filtered_sym = filtered_sym[21:]
elif filtered_sym.startswith("virtual thunk to "): filtered_sym = filtered_sym[17:]
@@ -107,7 +112,10 @@ for sym in exported_symbols:
# find standalone functions which are exported but not imported
if not(sym in imported_symbols): unused_function_exports.add(func)
-for sym in imported_symbols:
+progress = 0;
+for sym in sorted(imported_symbols):
+ progress += 1
+ if (progress % 128 == 0): print( str(int(progress * 100 / len(imported_symbols))) + "%")
filtered_sym = subprocess.check_output(["c++filt", sym]).strip().decode("utf-8")
if filtered_sym.startswith("non-virtual thunk to "): filtered_sym = filtered_sym[21:]
elif filtered_sym.startswith("virtual thunk to "): filtered_sym = filtered_sym[17:]
diff --git a/sc/source/ui/inc/datatransformation.hxx b/sc/source/ui/inc/datatransformation.hxx
index 2b7c611cf96a..e69b21f423e4 100644
--- a/sc/source/ui/inc/datatransformation.hxx
+++ b/sc/source/ui/inc/datatransformation.hxx
@@ -212,7 +212,7 @@ class DeleteRowTransformation : public DataTransformation
const OUString & getFindString() const;
};
-class SC_DLLPUBLIC SwapRowsTransformation : public DataTransformation
+class SwapRowsTransformation : public DataTransformation
{
SCROW mxRow, nxRow;