Update other codegens to use tcx managed vtable allocations.

This commit is contained in:
Charles Lew
2021-06-20 17:43:25 +08:00
parent 654e3345e5
commit d3ff497bec
12 changed files with 144 additions and 250 deletions

View File

@@ -26,6 +26,8 @@ pub trait ConstMethods<'tcx>: BackendTypes {
fn const_to_opt_uint(&self, v: Self::Value) -> Option<u64>;
fn const_to_opt_u128(&self, v: Self::Value, sign_ext: bool) -> Option<u128>;
fn const_data_from_alloc(&self, alloc: &Allocation) -> Self::Value;
fn scalar_to_backend(&self, cv: Scalar, layout: &abi::Scalar, llty: Self::Type) -> Self::Value;
fn from_const_alloc(
&self,