Skip to content

Commit ee36a1f

Browse files
committed
Remove workaround for stack_{load,store}.i128 not being implemented
1 parent 9c98027 commit ee36a1f

File tree

1 file changed

+2
-15
lines changed

1 file changed

+2
-15
lines changed

src/pointer.rs

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -168,13 +168,7 @@ impl Pointer {
168168
match self.base {
169169
PointerBase::Addr(base_addr) => fx.bcx.ins().load(ty, flags, base_addr, self.offset),
170170
PointerBase::Stack(stack_slot) => {
171-
if ty == types::I128 || ty.is_vector() {
172-
// WORKAROUND for stack_load.i128 and stack_load.iXxY not being implemented
173-
let base_addr = fx.bcx.ins().stack_addr(fx.pointer_type, stack_slot, 0);
174-
fx.bcx.ins().load(ty, flags, base_addr, self.offset)
175-
} else {
176-
fx.bcx.ins().stack_load(ty, stack_slot, self.offset)
177-
}
171+
fx.bcx.ins().stack_load(ty, stack_slot, self.offset)
178172
}
179173
PointerBase::Dangling(_align) => unreachable!(),
180174
}
@@ -191,14 +185,7 @@ impl Pointer {
191185
fx.bcx.ins().store(flags, value, base_addr, self.offset);
192186
}
193187
PointerBase::Stack(stack_slot) => {
194-
let val_ty = fx.bcx.func.dfg.value_type(value);
195-
if val_ty == types::I128 || val_ty.is_vector() {
196-
// WORKAROUND for stack_store.i128 and stack_store.iXxY not being implemented
197-
let base_addr = fx.bcx.ins().stack_addr(fx.pointer_type, stack_slot, 0);
198-
fx.bcx.ins().store(flags, value, base_addr, self.offset);
199-
} else {
200-
fx.bcx.ins().stack_store(value, stack_slot, self.offset);
201-
}
188+
fx.bcx.ins().stack_store(value, stack_slot, self.offset);
202189
}
203190
PointerBase::Dangling(_align) => unreachable!(),
204191
}

0 commit comments

Comments
 (0)