Skip to content

Commit 10d3f8a

Browse files
committed
Move rustllvm into rustc_llvm
1 parent d92155b commit 10d3f8a

File tree

17 files changed

+23
-27
lines changed

17 files changed

+23
-27
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ __pycache__/
3333
/mingw-build/
3434
# Created by default with `src/ci/docker/run.sh`:
3535
/obj/
36-
/rustllvm/
3736
/unicode-downloads
3837
/target
3938
# Generated by compiletest for incremental:

compiler/rustc_codegen_llvm/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ rustc_fs_util = { path = "../rustc_fs_util" }
2525
rustc_hir = { path = "../rustc_hir" }
2626
rustc_incremental = { path = "../rustc_incremental" }
2727
rustc_index = { path = "../rustc_index" }
28-
rustc_llvm = { path = "../../src/librustc_llvm" }
28+
rustc_llvm = { path = "../rustc_llvm" }
2929
rustc_session = { path = "../rustc_session" }
3030
rustc_serialize = { path = "../rustc_serialize" }
3131
rustc_target = { path = "../rustc_target" }

compiler/rustc_codegen_llvm/src/llvm/ffi.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ pub enum DLLStorageClass {
9696
DllExport = 2, // Function to be accessible from DLL.
9797
}
9898

99-
/// Matches LLVMRustAttribute in rustllvm.h
99+
/// Matches LLVMRustAttribute in LLVMWrapper.h
100100
/// Semantically a subset of the C++ enum llvm::Attribute::AttrKind,
101101
/// though it is not ABI compatible (since it's a C++ enum)
102102
#[repr(C)]
@@ -1705,7 +1705,7 @@ extern "C" {
17051705
PM: &PassManager<'_>,
17061706
);
17071707

1708-
// Stuff that's in rustllvm/ because it's not upstream yet.
1708+
// Stuff that's in llvm-wrapper/ because it's not upstream yet.
17091709

17101710
/// Opens an object file.
17111711
pub fn LLVMCreateObjectFile(

src/librustc_llvm/Cargo.toml renamed to compiler/rustc_llvm/Cargo.toml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,6 @@ name = "rustc_llvm"
44
version = "0.0.0"
55
edition = "2018"
66

7-
[lib]
8-
path = "lib.rs"
9-
107
[features]
118
static-libstdcpp = []
129
emscripten = []
@@ -15,5 +12,5 @@ emscripten = []
1512
libc = "0.2.73"
1613

1714
[build-dependencies]
18-
build_helper = { path = "../build_helper" }
15+
build_helper = { path = "../../src/build_helper" }
1916
cc = "1.0.58"

src/librustc_llvm/build.rs renamed to compiler/rustc_llvm/build.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -175,15 +175,15 @@ fn main() {
175175
cfg.debug(false);
176176
}
177177

178-
build_helper::rerun_if_changed_anything_in_dir(Path::new("../rustllvm"));
179-
cfg.file("../rustllvm/PassWrapper.cpp")
180-
.file("../rustllvm/RustWrapper.cpp")
181-
.file("../rustllvm/ArchiveWrapper.cpp")
182-
.file("../rustllvm/CoverageMappingWrapper.cpp")
183-
.file("../rustllvm/Linker.cpp")
178+
build_helper::rerun_if_changed_anything_in_dir(Path::new("llvm-wrapper"));
179+
cfg.file("llvm-wrapper/PassWrapper.cpp")
180+
.file("llvm-wrapper/RustWrapper.cpp")
181+
.file("llvm-wrapper/ArchiveWrapper.cpp")
182+
.file("llvm-wrapper/CoverageMappingWrapper.cpp")
183+
.file("llvm-wrapper/Linker.cpp")
184184
.cpp(true)
185185
.cpp_link_stdlib(None) // we handle this below
186-
.compile("rustllvm");
186+
.compile("llvm-wrapper");
187187

188188
let (llvm_kind, llvm_link_arg) = detect_llvm_link();
189189

@@ -259,7 +259,7 @@ fn main() {
259259
}
260260

261261
// Some LLVM linker flags (-L and -l) may be needed even when linking
262-
// librustc_llvm, for example when using static libc++, we may need to
262+
// rustc_llvm, for example when using static libc++, we may need to
263263
// manually specify the library search path and -ldl -lpthread as link
264264
// dependencies.
265265
let llvm_linker_flags = tracked_env_var_os("LLVM_LINKER_FLAGS");

src/rustllvm/ArchiveWrapper.cpp renamed to compiler/rustc_llvm/llvm-wrapper/ArchiveWrapper.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#include "rustllvm.h"
1+
#include "LLVMWrapper.h"
22

33
#include "llvm/Object/Archive.h"
44
#include "llvm/Object/ArchiveWriter.h"

src/rustllvm/CoverageMappingWrapper.cpp renamed to compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#include "rustllvm.h"
1+
#include "LLVMWrapper.h"
22
#include "llvm/ProfileData/Coverage/CoverageMapping.h"
33
#include "llvm/ProfileData/Coverage/CoverageMappingWriter.h"
44
#include "llvm/ProfileData/InstrProf.h"

src/rustllvm/Linker.cpp renamed to compiler/rustc_llvm/llvm-wrapper/Linker.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#include "llvm/Linker/Linker.h"
22

3-
#include "rustllvm.h"
3+
#include "LLVMWrapper.h"
44

55
using namespace llvm;
66

0 commit comments

Comments
 (0)