mirror of
https://github.com/mii443/wasmer.git
synced 2025-08-24 17:29:26 +00:00
Add llvm 'readonly' attribute to calls of the memory size function.
In passing, delete a lot of dead code. Remove old VM intrinsics for memory.size, memory.grow and breakpoints.
This commit is contained in:
@ -7,6 +7,7 @@ use super::{
|
||||
state::{ControlFrame, ExtraInfo, IfElseState, State},
|
||||
};
|
||||
use inkwell::{
|
||||
attributes::AttributeLoc,
|
||||
builder::Builder,
|
||||
context::Context,
|
||||
module::{Linkage, Module},
|
||||
@ -8245,6 +8246,7 @@ impl<'ctx, 'a> LLVMFunctionCodeGenerator<'ctx, 'a> {
|
||||
],
|
||||
"",
|
||||
);
|
||||
size.add_attribute(AttributeLoc::Function, self.intrinsics.readonly);
|
||||
self.state.push1(size.try_as_basic_value().left().unwrap());
|
||||
}
|
||||
_ => {
|
||||
|
Reference in New Issue
Block a user