<commit_before>; RUN: llvm-as < %s | opt -addreadattrs | llvm-dis | grep readnone | count 2

define i32 @f() {
entry:
	%tmp = call i32 @e( )		; <i32> [#uses=1]
	ret i32 %tmp
}

declare i32 @e() readnone<commit_msg>Add test for improvement of readonly to readnone, and non-demotion of readnone to readonly.<commit_after>; RUN: llvm-as < %s | opt -addreadattrs | llvm-dis | grep readnone | count 4
@x = global i32 0

declare i32 @e() readnone

define i32 @f() {
	%tmp = call i32 @e( )		; <i32> [#uses=1]
	ret i32 %tmp
}

define i32 @g() readonly {
	ret i32 0
}

define i32 @h() readnone {
	%tmp = load i32* @x		; <i32> [#uses=1]
	ret i32 %tmp
}
{'fraction_non_alphanumeric': 0.1526479750778816, 'fraction_numerical': 0.06386292834890965, 'mean_word_length': 3.528169014084507, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4664407', 'n_tokens_mistral': 292, 'n_tokens_neox': 265, 'n_words': 91}