Skip to content

Commit 8aa15c1

Browse files
committed
LLVM and SPIRV-LLVM-Translator pulldown (WW06)
LLVM: llvm/llvm-project@8ce99dadb007 SPIRV-LLVM-Translator: KhronosGroup/SPIRV-LLVM-Translator@fb2dd0e
2 parents 01f3fc7 + dc05829 commit 8aa15c1

File tree

4,234 files changed

+140316
-125453
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

4,234 files changed

+140316
-125453
lines changed

.clang-tidy

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,5 @@ CheckOptions:
1818
value: 1
1919
- key: readability-redundant-member-init.IgnoreBaseInCopyConstructors
2020
value: 1
21+
- key: modernize-use-default-member-init.UseAssignment
22+
value: 1

bolt/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,10 @@ add_subdirectory(lib)
9191
add_subdirectory(tools)
9292

9393
if (BOLT_INCLUDE_TESTS)
94+
if (EXISTS ${LLVM_MAIN_SRC_DIR}/utils/unittest/googletest/include/gtest/gtest.h)
95+
add_subdirectory(unittests)
96+
list(APPEND BOLT_TEST_DEPS BoltUnitTests)
97+
endif()
9498
add_subdirectory(test)
9599
endif()
96100

bolt/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,14 @@ compiler option. Since GCC8 enables this option by default, you have to
3030
explicitly disable it by adding `-fno-reorder-blocks-and-partition` flag if
3131
you are compiling with GCC8 or above.
3232

33+
NOTE2: DWARF v5 is the new debugging format generated by the latest LLVM and GCC
34+
compilers. It offers several benefits over the previous DWARF v4. Currently, the
35+
support for v5 is a work in progress for BOLT. While you will be able to
36+
optimize binaries produced by the latest compilers, until the support is
37+
complete, you will not be able to update the debug info with
38+
`-update-debug-sections`. To temporarily work around the issue, we recommend
39+
compiling binaries with `-gdwarf-4` option that forces DWARF v4 output.
40+
3341
PIE and .so support has been added recently. Please report bugs if you
3442
encounter any issues.
3543

bolt/include/bolt/Core/BinaryContext.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,12 @@
2828
#include "llvm/MC/MCAsmInfo.h"
2929
#include "llvm/MC/MCCodeEmitter.h"
3030
#include "llvm/MC/MCContext.h"
31-
#include "llvm/MC/MCDwarf.h"
32-
#include "llvm/MC/MCInstrInfo.h"
3331
#include "llvm/MC/MCObjectFileInfo.h"
3432
#include "llvm/MC/MCObjectWriter.h"
3533
#include "llvm/MC/MCPseudoProbe.h"
3634
#include "llvm/MC/MCSectionELF.h"
3735
#include "llvm/MC/MCSectionMachO.h"
36+
#include "llvm/MC/MCStreamer.h"
3837
#include "llvm/MC/MCSymbol.h"
3938
#include "llvm/MC/TargetRegistry.h"
4039
#include "llvm/Support/ErrorOr.h"

bolt/include/bolt/Core/BinaryData.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#define BOLT_CORE_BINARY_DATA_H
1717

1818
#include "llvm/ADT/Twine.h"
19-
#include "llvm/MC/MCStreamer.h"
2019
#include "llvm/MC/MCSymbol.h"
2120
#include "llvm/Support/raw_ostream.h"
2221
#include <algorithm>

bolt/include/bolt/Core/DebugData.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#ifndef BOLT_CORE_DEBUG_DATA_H
1515
#define BOLT_CORE_DEBUG_DATA_H
1616

17-
#include "llvm/ADT/MapVector.h"
1817
#include "llvm/ADT/SmallVector.h"
1918
#include "llvm/DebugInfo/DWARF/DWARFContext.h"
2019
#include "llvm/MC/MCDwarf.h"
@@ -33,8 +32,6 @@
3332

3433
namespace llvm {
3534

36-
class DWARFAbbreviationDeclarationSet;
37-
3835
namespace bolt {
3936

4037
class BinaryContext;

bolt/include/bolt/Core/MCPlusBuilder.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1898,6 +1898,14 @@ class MCPlusBuilder {
18981898
}
18991899
};
19001900

1901+
MCPlusBuilder *createX86MCPlusBuilder(const MCInstrAnalysis *,
1902+
const MCInstrInfo *,
1903+
const MCRegisterInfo *);
1904+
1905+
MCPlusBuilder *createAArch64MCPlusBuilder(const MCInstrAnalysis *,
1906+
const MCInstrInfo *,
1907+
const MCRegisterInfo *);
1908+
19011909
} // namespace bolt
19021910
} // namespace llvm
19031911

bolt/include/bolt/Passes/AllocCombiner.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313

1414
namespace llvm {
1515
namespace bolt {
16-
class DataflowInfoManager;
17-
class FrameAnalysis;
1816

1917
class AllocCombinerPass : public BinaryFunctionPass {
2018
/// Stats aggregating variables

bolt/include/bolt/Rewrite/DWARFRewriter.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,10 @@
1010
#define BOLT_REWRITE_DWARF_REWRITER_H
1111

1212
#include "bolt/Core/DebugData.h"
13-
#include "bolt/Rewrite/RewriteInstance.h"
1413
#include <cstdint>
15-
#include <map>
1614
#include <memory>
1715
#include <mutex>
16+
#include <set>
1817
#include <unordered_map>
1918
#include <vector>
2019

bolt/include/bolt/Rewrite/RewriteInstance.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,11 @@ class RewriteInstance {
545545
friend class RewriteInstanceDiff;
546546
};
547547

548+
MCPlusBuilder *createMCPlusBuilder(const Triple::ArchType Arch,
549+
const MCInstrAnalysis *Analysis,
550+
const MCInstrInfo *Info,
551+
const MCRegisterInfo *RegInfo);
552+
548553
} // namespace bolt
549554
} // namespace llvm
550555

0 commit comments

Comments
 (0)