@@ -90,6 +90,18 @@ entry:
9090 ret void
9191}
9292
93+ ; Function Attrs: nounwind
94+ define hidden ptr @main.doesHeapAlloc (ptr %context ) unnamed_addr #1 {
95+ entry:
96+ %stackalloc = alloca i8 , align 1
97+ %new = call align 4 dereferenceable (4 ) ptr @runtime.alloc_noheap (i32 4 , ptr nonnull inttoptr (i32 3 to ptr ), ptr undef ) #10
98+ call void @runtime.trackPointer (ptr nonnull %new , ptr nonnull %stackalloc , ptr undef ) #10
99+ ret ptr %new
100+ }
101+
102+ ; Function Attrs: allockind("alloc,zeroed") allocsize(0)
103+ declare noalias nonnull ptr @runtime.alloc_noheap (i32 , ptr , ptr ) #9
104+
93105attributes #0 = { "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" }
94106attributes #1 = { nounwind "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" }
95107attributes #2 = { nounwind "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" "wasm-export-name" ="extern_func" }
@@ -99,3 +111,5 @@ attributes #5 = { noinline nounwind "target-features"="+bulk-memory,+bulk-memory
99111attributes #6 = { "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" "wasm-import-module" ="modulename" "wasm-import-name" ="import1" }
100112attributes #7 = { "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" "wasm-import-module" ="foobar" "wasm-import-name" ="imported" }
101113attributes #8 = { nounwind "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" "wasm-export-name" ="exported" }
114+ attributes #9 = { allockind("alloc,zeroed" ) allocsize(0 ) "alloc-family" ="runtime.alloc" "target-features" ="+bulk-memory,+bulk-memory-opt,+call-indirect-overlong,+mutable-globals,+nontrapping-fptoint,+sign-ext,-multivalue,-reference-types" }
115+ attributes #10 = { nounwind }
0 commit comments