Skip to content

Instantly share code, notes, and snippets.

@jdoerfert
Last active October 17, 2019 21:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jdoerfert/f58dda857d36abbe66284ac4065f7b53 to your computer and use it in GitHub Desktop.
Save jdoerfert/f58dda857d36abbe66284ac4065f7b53 to your computer and use it in GitHub Desktop.
./bin/opt -attributor --attributor-disable=false poster.ll -S
; ModuleID = 'poster.ll'
source_filename = "poster.ll"
@G = common global i32 0
; Function Attrs: nofree nosync nounwind willreturn writeonly
define internal i32 @local(i32* nocapture nonnull writeonly align 32 dereferenceable(4) %P) #0 {
store i32 41, i32* %P, align 32
br label %end
end: ; preds = %0
ret i32 undef
}
; Function Attrs: nofree nosync nounwind willreturn writeonly
define i32 @visible(i32* nocapture nonnull writeonly align 32 dereferenceable(4) %P) #0 {
%r = call i32 @local(i32* nocapture nonnull writeonly align 32 dereferenceable(4) %P) #0
ret i32 41
}
attributes #0 = { nofree nosync nounwind willreturn writeonly }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment