[mips] Replace assertion by error message while lowering `RETURNADDR` and `FRAMEADDR`
authorSimon Atanasyan <simon@atanasyan.com>
Wed, 6 Mar 2019 22:40:28 +0000 (22:40 +0000)
committerSimon Atanasyan <simon@atanasyan.com>
Wed, 6 Mar 2019 22:40:28 +0000 (22:40 +0000)
commit83b88441ad951fe99c30402930ef3cd661f2fd2b
treebd78721dffd2ad902eb215352ad4056f37bc9472
parent3229000f63618107b9eeec6e3032c8570f854972
[mips] Replace assertion by error message while lowering `RETURNADDR` and `FRAMEADDR`

MIPS target supports lowering `RETURNADDR` and `FRAMEADDR` for a current
frame only. It's better to show an error message then crash on assertion
if `__builtin_return_address` is invoked with non-zero argument.

llvm-svn: 355558
llvm/lib/Target/Mips/MipsISelLowering.cpp
llvm/test/CodeGen/Mips/frame-address-err.ll [new file with mode: 0644]
llvm/test/CodeGen/Mips/return_address_err.ll [new file with mode: 0644]