Always use extern crate std in cranelift-codegen
This commit is contained in:
@@ -28,7 +28,7 @@ use crate::ir::{
|
||||
use crate::isa::TargetIsa;
|
||||
use crate::legalizer::split::{isplit, vsplit};
|
||||
use log::debug;
|
||||
use std::vec::Vec;
|
||||
use alloc::vec::Vec;
|
||||
|
||||
/// Legalize all the function signatures in `func`.
|
||||
///
|
||||
|
||||
@@ -4,7 +4,7 @@ use crate::ir;
|
||||
use crate::ir::{get_libcall_funcref, InstBuilder};
|
||||
use crate::isa::{CallConv, TargetIsa};
|
||||
use crate::legalizer::boundary::legalize_libcall_signature;
|
||||
use std::vec::Vec;
|
||||
use alloc::vec::Vec;
|
||||
|
||||
/// Try to expand `inst` as a library call, returning true is successful.
|
||||
pub fn expand_as_libcall(inst: ir::Inst, func: &mut ir::Function, isa: &dyn TargetIsa) -> bool {
|
||||
|
||||
@@ -21,8 +21,8 @@ use crate::ir::{self, InstBuilder, MemFlags};
|
||||
use crate::isa::TargetIsa;
|
||||
use crate::predicates;
|
||||
use crate::timing;
|
||||
use std::collections::BTreeSet;
|
||||
use std::vec::Vec;
|
||||
use alloc::collections::BTreeSet;
|
||||
use alloc::vec::Vec;
|
||||
|
||||
mod boundary;
|
||||
mod call;
|
||||
@@ -373,7 +373,7 @@ fn expand_br_table_conds(
|
||||
let table_size = func.jump_tables[table].len();
|
||||
let mut cond_failed_ebb = vec![];
|
||||
if table_size >= 1 {
|
||||
cond_failed_ebb = std::vec::Vec::with_capacity(table_size - 1);
|
||||
cond_failed_ebb = alloc::vec::Vec::with_capacity(table_size - 1);
|
||||
for _ in 0..table_size - 1 {
|
||||
cond_failed_ebb.push(func.dfg.make_ebb());
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ use crate::flowgraph::{BasicBlock, ControlFlowGraph};
|
||||
use crate::ir::{self, Ebb, Inst, InstBuilder, InstructionData, Opcode, Type, Value, ValueDef};
|
||||
use core::iter;
|
||||
use smallvec::SmallVec;
|
||||
use std::vec::Vec;
|
||||
use alloc::vec::Vec;
|
||||
|
||||
/// Split `value` into two values using the `isplit` semantics. Do this by reusing existing values
|
||||
/// if possible.
|
||||
|
||||
Reference in New Issue
Block a user