about summary refs log tree commit diff
path: root/src/librustc_codegen_llvm/llvm
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-01-05 22:32:15 +0100
committerNikita Popov <nikita.ppv@gmail.com>2020-02-12 15:30:51 +0100
commit03a73fa2cf5688a12fa5557170945a2a7c27436e (patch)
treef1c6a93c49e1500b93cdb8dc700b89984fd23445 /src/librustc_codegen_llvm/llvm
parentcd5441faf4e56d136d7c05d5eb55b4a41396edaf (diff)
Use IRBuilder to create memset
To avoid creating memsets with outdated signature. For some reason
SROA chokes on this when using NewPM.
Diffstat (limited to 'src/librustc_codegen_llvm/llvm')
-rw-r--r--src/librustc_codegen_llvm/llvm/ffi.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/librustc_codegen_llvm/llvm/ffi.rs b/src/librustc_codegen_llvm/llvm/ffi.rs
index 146b7d3d76c..cdb55b179a3 100644
--- a/src/librustc_codegen_llvm/llvm/ffi.rs
+++ b/src/librustc_codegen_llvm/llvm/ffi.rs
@@ -1315,6 +1315,14 @@ extern "C" {
         Size: &'a Value,
         IsVolatile: bool,
     ) -> &'a Value;
+    pub fn LLVMRustBuildMemSet(
+        B: &Builder<'a>,
+        Dst: &'a Value,
+        DstAlign: c_uint,
+        Val: &'a Value,
+        Size: &'a Value,
+        IsVolatile: bool,
+    ) -> &'a Value;
     pub fn LLVMBuildSelect(
         B: &Builder<'a>,
         If: &'a Value,