Skip to content

Commit

Permalink
Fix load alignment being applied to load result
Browse files Browse the repository at this point in the history
  • Loading branch information
sapir committed Aug 7, 2024
1 parent fb95096 commit 1241e75
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,7 @@ impl<'a, 'gcc, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'gcc, 'tcx> {
let deref = ptr.dereference(self.location).to_rvalue();
let loaded_value = function.new_local(
self.location,
aligned_type,
pointee_ty,
&format!("loadedValue{}", self.next_value_counter()),
);
block.add_assignment(self.location, loaded_value, deref);
Expand Down

0 comments on commit 1241e75

Please sign in to comment.