1
Fork 0

Rollup merge of #75457 - Mark-Simulacrum:llvm-clean, r=cuviper

Remove some dead variants in LLVM FFI

r? @nikic or @cuviper
This commit is contained in:
Yuki Okushi 2020-08-13 11:05:44 +09:00 committed by GitHub
commit 4cf55a67dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 0 additions and 25 deletions

View file

@ -975,7 +975,6 @@ pub unsafe fn with_llvm_pmb(
(llvm::CodeGenOptLevel::Default, ..) => {
llvm::LLVMPassManagerBuilderUseInlinerWithThreshold(builder, 225);
}
(llvm::CodeGenOptLevel::Other, ..) => bug!("CodeGenOptLevel::Other selected"),
}
f(builder);

View file

@ -337,9 +337,6 @@ impl AtomicOrdering {
#[derive(Copy, Clone)]
#[repr(C)]
pub enum SynchronizationScope {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
SingleThread,
CrossThread,
}
@ -347,7 +344,6 @@ pub enum SynchronizationScope {
impl SynchronizationScope {
pub fn from_generic(sc: rustc_codegen_ssa::common::SynchronizationScope) -> Self {
match sc {
rustc_codegen_ssa::common::SynchronizationScope::Other => SynchronizationScope::Other,
rustc_codegen_ssa::common::SynchronizationScope::SingleThread => {
SynchronizationScope::SingleThread
}
@ -362,9 +358,6 @@ impl SynchronizationScope {
#[derive(Copy, Clone)]
#[repr(C)]
pub enum FileType {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
AssemblyFile,
ObjectFile,
}
@ -391,9 +384,6 @@ pub enum MetadataType {
#[derive(Copy, Clone)]
#[repr(C)]
pub enum AsmDialect {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
Att,
Intel,
}
@ -411,9 +401,6 @@ impl AsmDialect {
#[derive(Copy, Clone, PartialEq)]
#[repr(C)]
pub enum CodeGenOptLevel {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
None,
Less,
Default,
@ -513,9 +500,6 @@ pub enum DiagnosticLevel {
#[derive(Copy, Clone)]
#[repr(C)]
pub enum ArchiveKind {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
K_GNU,
K_BSD,
K_DARWIN,

View file

@ -72,9 +72,6 @@ pub enum AtomicOrdering {
}
pub enum SynchronizationScope {
// FIXME: figure out if this variant is needed at all.
#[allow(dead_code)]
Other,
SingleThread,
CrossThread,
}

View file

@ -35,7 +35,6 @@ struct RustArchiveIterator {
};
enum class LLVMRustArchiveKind {
Other,
GNU,
BSD,
DARWIN,

View file

@ -311,7 +311,6 @@ static Optional<CodeModel::Model> fromRust(LLVMRustCodeModel Model) {
}
enum class LLVMRustCodeGenOptLevel {
Other,
None,
Less,
Default,
@ -597,7 +596,6 @@ extern "C" void LLVMRustSetLLVMOptions(int Argc, char **Argv) {
}
enum class LLVMRustFileType {
Other,
AssemblyFile,
ObjectFile,
};

View file

@ -366,7 +366,6 @@ LLVMRustBuildAtomicCmpXchg(LLVMBuilderRef B, LLVMValueRef Target,
}
enum class LLVMRustSynchronizationScope {
Other,
SingleThread,
CrossThread,
};
@ -389,7 +388,6 @@ LLVMRustBuildAtomicFence(LLVMBuilderRef B, LLVMAtomicOrdering Order,
}
enum class LLVMRustAsmDialect {
Other,
Att,
Intel,
};