let ty = opaque_type context in
insist (define_type_name "delete_type" ty m);
delete_type_name "delete_type" m;
+
+ (* RUN: grep {type_name.*opaque} < %t.ll
+ *)
+ group "type_name"; begin
+ let ty = opaque_type context in
+ insist (define_type_name "type_name" ty m);
+ insist ((type_by_name m "type_name") = Some ty)
+ end;
(* RUN: grep -v {recursive_type.*recursive_type} < %t.ll
*)
group "all ones";
let c = const_all_ones i64_type in
ignore (define_global "const_all_ones" c m);
+
+ group "pointer null"; begin
+ (* RUN: grep {const_pointer_null = global i64\\* null} < %t.ll
+ *)
+ let c = const_pointer_null (pointer_type i64_type) in
+ ignore (define_global "const_pointer_null" c m);
+ end;
(* RUN: grep {const_undef.*undef} < %t.ll
*)
ignore (define_global "const_shufflevector" (const_shufflevector
(const_vector [| zero; one |])
(const_vector [| one; zero |])
- (const_bitcast foldbomb (vector_type i32_type 2))) m)
+ (const_bitcast foldbomb (vector_type i32_type 2))) m);
+
+ group "asm"; begin
+ let ft = function_type void_type [| i32_type; i32_type; i32_type |] in
+ ignore (const_inline_asm
+ ft
+ ""
+ "{cx},{ax},{di},~{dirflag},~{fpsr},~{flags},~{edi},~{ecx}"
+ true
+ false)
+ end
(*===-- Global Values -----------------------------------------------------===*)