[RISCV] Fix CFA when doing split sp adjustment with fp
authorLuís Marques <luismarques@lowrisc.org>
Sun, 10 Nov 2019 16:04:43 +0000 (16:04 +0000)
committerLuís Marques <luismarques@lowrisc.org>
Sun, 10 Nov 2019 16:09:14 +0000 (16:09 +0000)
commit1c737f54bee9df81c63ddf6ee2ad1d23a93c0ba0
tree308604f3e58ad353833b7aa69754ce83ad7e0cfb
parentbe0fead7bffbf65c519ca50c89584e65dcf18793
[RISCV] Fix CFA when doing split sp adjustment with fp

Summary: When using the split sp adjustment and using the frame-pointer
we were still emitting CFI CFA directives based on the sp value. The
final sp-based offset also didn't reflect the two-stage sp adjust. There
remain CFI issues that aren't related to the split sp adjustment, and
thus will be addressed in a separate patch.

Reviewers: asb, lenary, shiva0217
Reviewed By: lenary, shiva0217
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D69385
llvm/lib/Target/RISCV/RISCVFrameLowering.cpp
llvm/test/CodeGen/RISCV/large-stack.ll
llvm/test/CodeGen/RISCV/vararg.ll