Skip to content

Commit e2721f7

Browse files
committed
Remove InvalidateStructLayoutInfo from the ocaml bindings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136582 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent 21384c4 commit e2721f7

File tree

4 files changed

+0
-17
lines changed

4 files changed

+0
-17
lines changed

bindings/ocaml/target/llvm_target.ml

-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ module TargetData = struct
2020
external add : t -> [<Llvm.PassManager.any] Llvm.PassManager.t -> unit
2121
= "llvm_targetdata_add"
2222
external as_string : t -> string = "llvm_targetdata_as_string"
23-
external invalidate_struct_layout : t -> Llvm.lltype -> unit
24-
= "llvm_targetdata_invalidate_struct_layout"
2523
external dispose : t -> unit = "llvm_targetdata_dispose"
2624
end
2725

bindings/ocaml/target/llvm_target.mli

-7
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,6 @@ module TargetData : sig
3535
See the constructor llvm::TargetData::TargetData. *)
3636
external as_string : t -> string = "llvm_targetdata_as_string"
3737

38-
(** Struct layouts are speculatively cached. If a TargetDataRef is alive when
39-
types are being refined and removed, this method must be called whenever a
40-
struct type is removed to avoid a dangling pointer in this cache.
41-
See the method llvm::TargetData::InvalidateStructLayoutInfo. *)
42-
external invalidate_struct_layout : t -> Llvm.lltype -> unit
43-
= "llvm_targetdata_invalidate_struct_layout"
44-
4538
(** Deallocates a TargetData.
4639
See the destructor llvm::TargetData::~TargetData. *)
4740
external dispose : t -> unit = "llvm_targetdata_dispose"

bindings/ocaml/target/target_ocaml.c

-7
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,6 @@ CAMLprim value llvm_targetdata_as_string(LLVMTargetDataRef TD) {
3737
return Copy;
3838
}
3939

40-
/* TargetData.t -> Llvm.lltype -> unit */
41-
CAMLprim value llvm_targetdata_invalidate_struct_layout(LLVMTargetDataRef TD,
42-
LLVMTypeRef Ty) {
43-
LLVMInvalidateStructLayout(TD, Ty);
44-
return Val_unit;
45-
}
46-
4740
/* TargetData.t -> unit */
4841
CAMLprim value llvm_targetdata_dispose(LLVMTargetDataRef TD) {
4942
LLVMDisposeTargetData(TD);

test/Bindings/Ocaml/target.ml

-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ let test_target_data () =
3737
let sty = struct_type context [| i32_type; i64_type |] in
3838

3939
ignore (TargetData.as_string td);
40-
ignore (TargetData.invalidate_struct_layout td sty);
4140
ignore (byte_order td);
4241
ignore (pointer_size td);
4342
ignore (intptr_type td);

0 commit comments

Comments
 (0)