[all-commits] [llvm/llvm-project] b0abd4: [llvm] Add missing StringExtras.h includes
Elliot Goodrich via All-commits
all-commits at lists.llvm.org
Sun Jun 25 07:52:57 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b0abd4893fa1bfae7f71b6b6e98770c9b1c07620
https://github.com/llvm/llvm-project/commit/b0abd4893fa1bfae7f71b6b6e98770c9b1c07620
Author: Elliot Goodrich <elliotgoodrich at gmail.com>
Date: 2023-06-25 (Sun, 25 Jun 2023)
Changed paths:
M clang-tools-extra/clangd/ConfigCompile.cpp
M clang-tools-extra/clangd/FileDistance.cpp
M clang-tools-extra/clangd/Protocol.cpp
M clang-tools-extra/clangd/index/SymbolID.cpp
M clang-tools-extra/clangd/unittests/TestIndex.cpp
M clang/include/clang/ASTMatchers/ASTMatchers.h
M clang/lib/AST/ExprConstant.cpp
M clang/lib/AST/JSONNodeDumper.cpp
M clang/lib/Basic/Sarif.cpp
M clang/lib/Driver/Job.cpp
M clang/lib/Driver/ToolChains/AIX.cpp
M clang/lib/Driver/ToolChains/AMDGPU.cpp
M clang/lib/Sema/SemaCast.cpp
M clang/lib/Sema/SemaChecking.cpp
M clang/lib/Sema/SemaDecl.cpp
M clang/lib/Sema/SemaExprCXX.cpp
M clang/lib/Sema/SemaInit.cpp
M clang/lib/Sema/SemaModule.cpp
M clang/lib/Sema/SemaStmt.cpp
M clang/lib/Sema/SemaStmtAsm.cpp
M clang/lib/Sema/SemaTemplateInstantiate.cpp
M clang/lib/Sema/SemaType.cpp
M clang/lib/StaticAnalyzer/Core/CheckerContext.cpp
M clang/tools/clang-offload-packager/ClangOffloadPackager.cpp
M clang/tools/driver/cc1as_main.cpp
M lld/COFF/Chunks.cpp
M lld/COFF/DebugTypes.cpp
M lld/COFF/DriverUtils.cpp
M lld/Common/Strings.cpp
M lld/Common/Timer.cpp
M lld/ELF/AArch64ErrataFix.cpp
M lld/ELF/InputSection.h
M lld/ELF/Target.h
M lld/wasm/WriterUtils.cpp
M llvm/examples/OrcV2Examples/LLJITWithRemoteDebugging/RemoteJITUtils.cpp
M llvm/include/llvm/DebugInfo/DWARF/DWARFAcceleratorTable.h
M llvm/include/llvm/DebugInfo/DWARF/DWARFContext.h
M llvm/include/llvm/DebugInfo/GSYM/FunctionInfo.h
M llvm/include/llvm/Debuginfod/HTTPClient.h
M llvm/include/llvm/ProfileData/GCOV.h
M llvm/lib/Analysis/AliasSetTracker.cpp
M llvm/lib/Analysis/CallGraphSCCPass.cpp
M llvm/lib/Analysis/InlineAdvisor.cpp
M llvm/lib/Analysis/ScalarEvolution.cpp
M llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
M llvm/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
M llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.h
M llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
M llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp
M llvm/lib/CodeGen/MachineBasicBlock.cpp
M llvm/lib/CodeGen/MachineCheckDebugify.cpp
M llvm/lib/CodeGen/RegisterBankInfo.cpp
M llvm/lib/DWARFLinker/DWARFLinker.cpp
M llvm/lib/DWARFLinker/DWARFLinkerCompileUnit.cpp
M llvm/lib/DWARFLinkerParallel/DWARFLinkerUnit.h
M llvm/lib/DebugInfo/CodeView/CodeViewRecordIO.cpp
M llvm/lib/DebugInfo/DWARF/DWARFExpression.cpp
M llvm/lib/DebugInfo/PDB/Native/InputFile.cpp
M llvm/lib/DebugInfo/PDB/Native/NativeEnumInjectedSources.cpp
M llvm/lib/DebugInfo/PDB/Native/NativeSession.cpp
M llvm/lib/DebugInfo/PDB/Native/NativeSourceFile.cpp
M llvm/lib/DebugInfo/PDB/Native/PDBFileBuilder.cpp
M llvm/lib/ExecutionEngine/JITLink/JITLink.cpp
M llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFAArch64.h
M llvm/lib/ExecutionEngine/RuntimeDyld/Targets/RuntimeDyldCOFFThumb.h
M llvm/lib/FileCheck/FileCheck.cpp
M llvm/lib/IR/DIBuilder.cpp
M llvm/lib/MC/ELFObjectWriter.cpp
M llvm/lib/MC/MCAsmInfo.cpp
M llvm/lib/MC/MCParser/ELFAsmParser.cpp
M llvm/lib/MC/MCParser/WasmAsmParser.cpp
M llvm/lib/ObjCopy/COFF/COFFObjcopy.cpp
M llvm/lib/Object/Decompressor.cpp
M llvm/lib/Object/ELF.cpp
M llvm/lib/ProfileData/Coverage/CoverageMappingWriter.cpp
M llvm/lib/Remarks/YAMLRemarkParser.cpp
M llvm/lib/Support/BinaryStreamWriter.cpp
M llvm/lib/Support/DataExtractor.cpp
M llvm/lib/Support/JSON.cpp
M llvm/lib/Support/Path.cpp
M llvm/lib/Target/AMDGPU/AMDGPUPrintfRuntimeBinding.cpp
M llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.h
M llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp
M llvm/lib/Target/Hexagon/MCTargetDesc/HexagonShuffler.cpp
M llvm/lib/Target/LoongArch/LoongArchISelLowering.cpp
M llvm/lib/Target/NVPTX/NVPTXCtorDtorLowering.cpp
M llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
M llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
M llvm/lib/Target/PowerPC/PPCISelLowering.cpp
M llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
M llvm/lib/Target/SystemZ/AsmParser/SystemZAsmParser.cpp
M llvm/lib/Target/SystemZ/SystemZAsmPrinter.cpp
M llvm/lib/Target/X86/X86MCInstLower.cpp
M llvm/lib/Target/X86/X86PreAMXConfig.cpp
M llvm/lib/Transforms/IPO/AttributorAttributes.cpp
M llvm/lib/Transforms/IPO/OpenMPOpt.cpp
M llvm/lib/Transforms/Utils/AMDGPUEmitPrintf.cpp
M llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp
M llvm/lib/Transforms/Vectorize/VPlan.cpp
M llvm/tools/llvm-cov/CoverageReport.cpp
M llvm/tools/llvm-debuginfod-find/llvm-debuginfod-find.cpp
M llvm/tools/llvm-objcopy/ObjcopyOptions.cpp
M llvm/tools/llvm-opt-report/OptReport.cpp
M llvm/tools/llvm-pdbutil/DumpOutputStyle.cpp
M llvm/tools/llvm-pdbutil/MinimalSymbolDumper.cpp
M llvm/tools/llvm-pdbutil/MinimalTypeDumper.cpp
M llvm/tools/llvm-pdbutil/PrettyCompilandDumper.cpp
M llvm/tools/llvm-rc/ResourceScriptParser.cpp
M llvm/tools/llvm-strings/llvm-strings.cpp
M llvm/tools/llvm-tapi-diff/DiffEngine.cpp
M llvm/unittests/ADT/APFloatTest.cpp
M llvm/unittests/DebugInfo/CodeView/GUIDFormatTest.cpp
M llvm/unittests/DebugInfo/DWARF/DWARFDebugInfoTest.cpp
M llvm/unittests/DebugInfo/DWARF/DWARFFormValueTest.cpp
M llvm/unittests/DebugInfo/DWARF/DwarfGenerator.h
M llvm/unittests/DebugInfo/PDB/HashTableTest.cpp
M llvm/unittests/MC/DwarfLineTables.cpp
M llvm/unittests/Support/DataExtractorTest.cpp
M mlir/lib/Tools/lsp-server-support/Protocol.cpp
M mlir/lib/Tools/lsp-server-support/SourceMgrUtils.cpp
M mlir/lib/Tools/mlir-lsp-server/MLIRServer.cpp
M polly/lib/Analysis/ScopInfo.cpp
Log Message:
-----------
[llvm] Add missing StringExtras.h includes
In preparation for removing the `#include "llvm/ADT/StringExtras.h"`
from the header to source file of `llvm/Support/Error.h`, first add in
all the missing includes that were previously included transitively
through this header.
Commit: 2fa0dbd7bf353db98b27b56137cced0a67de2748
https://github.com/llvm/llvm-project/commit/2fa0dbd7bf353db98b27b56137cced0a67de2748
Author: Elliot Goodrich <elliotgoodrich at gmail.com>
Date: 2023-06-25 (Sun, 25 Jun 2023)
Changed paths:
M llvm/include/llvm/Support/Error.h
M llvm/lib/Support/Error.cpp
Log Message:
-----------
[llvm] Move StringExtras.h include from Error.h to Error.cpp
Move the implementation of the `toString` function from
`llvm/Support/Error.h` to the source file, which allows us to move
`#include "llvm/ADT/StringExtras.h"` to the source file as well.
As `Error.h` is present in a large number of translation units this
means we are unnecessarily bringing in the contents of
`StringExtras.h` - itself a large file with lots of includes - and
slowing down compilation.
Also move the `#include "llvm/ADT/SmallVector.h"` directive to the
source file as it's no longer needed, but this does not give as much of
a benefit.
This reduces the total number of preprocessing tokens across the LLVM
source files in lib from (roughly) 1,920,413,050 to 1,903,629,230 - a
reduction of ~0.87%. This should result in a small improvement in
compilation time.
Differential Revision: https://reviews.llvm.org/D153229
Compare: https://github.com/llvm/llvm-project/compare/54210573ae91...2fa0dbd7bf35
More information about the All-commits
mailing list