LLVMType ElTy = elty;
}
+// Match the type of another intrinsic parameter. Number is an index into the
+// list of overloaded types for the intrinsic, excluding all the fixed types.
+// The Number value must refer to a previously listed type. For example:
+// Intrinsic<[llvm_i32_ty], [llvm_i32_ty, llvm_anyfloat_ty, LLVMMatchType<0>]>
+// has two overloaded types, the 2nd and 3rd arguments. LLVMMatchType<0>
+// refers to the first overloaded type, which is the 2nd argument.
class LLVMMatchType<int num>
: LLVMType<OtherVT>{
int Number = num;
//===------------------------ Debugger Intrinsics -------------------------===//
//
-def int_dbg_stoppoint : Intrinsic<[llvm_void_ty],
- [llvm_i32_ty, llvm_i32_ty,
- llvm_descriptor_ty]>;
-def int_dbg_region_start : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
-def int_dbg_region_end : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
-def int_dbg_func_start : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
-def int_dbg_declare : Intrinsic<[llvm_void_ty],
- [llvm_descriptor_ty, llvm_descriptor_ty]>;
+// None of these intrinsics accesses memory at all...but that doesn't mean the
+// optimizers can change them aggressively. Special handling needed in a few
+// places.
+let Properties = [IntrNoMem] in {
+ def int_dbg_stoppoint : Intrinsic<[llvm_void_ty],
+ [llvm_i32_ty, llvm_i32_ty,
+ llvm_descriptor_ty]>;
+ def int_dbg_region_start : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
+ def int_dbg_region_end : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
+ def int_dbg_func_start : Intrinsic<[llvm_void_ty], [llvm_descriptor_ty]>;
+ def int_dbg_declare : Intrinsic<[llvm_void_ty],
+ [llvm_descriptor_ty, llvm_descriptor_ty]>;
+}
//===------------------ Exception Handling Intrinsics----------------------===//
//