Skip to content

Commit

Permalink
[BitCode] decode nossp fn attr
Browse files Browse the repository at this point in the history
I missed this in https://reviews.llvm.org/D87956.

Reviewed By: void

Differential Revision: https://reviews.llvm.org/D90177
  • Loading branch information
nickdesaulniers committed Oct 26, 2020
1 parent 00928a1 commit 0b11d01
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions llvm/lib/Bitcode/Reader/BitcodeReader.cpp
Expand Up @@ -1537,6 +1537,8 @@ static Attribute::AttrKind getAttrFromCode(uint64_t Code) {
return Attribute::ByRef;
case bitc::ATTR_KIND_MUSTPROGRESS:
return Attribute::MustProgress;
case bitc::ATTR_KIND_NO_STACK_PROTECT:
return Attribute::NoStackProtect;
}
}

Expand Down
7 changes: 7 additions & 0 deletions llvm/test/Bitcode/attributes.ll
Expand Up @@ -404,6 +404,12 @@ define void @f68() mustprogress
ret void
}

; CHECK; define void @f69() #42
define void @f69() nossp
{
ret void
}

; CHECK: attributes #0 = { noreturn }
; CHECK: attributes #1 = { nounwind }
; CHECK: attributes #2 = { readnone }
Expand Down Expand Up @@ -446,4 +452,5 @@ define void @f68() mustprogress
; CHECK: attributes #39 = { sanitize_memtag }
; CHECK: attributes #40 = { null_pointer_is_valid }
; CHECK: attributes #41 = { mustprogress }
; CHECK: attributes #42 = { nossp }
; CHECK: attributes #[[NOBUILTIN]] = { nobuiltin }

0 comments on commit 0b11d01

Please sign in to comment.