diff options
author | Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> | 2019-12-04 10:06:24 +0000 |
---|---|---|
committer | Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> | 2019-12-04 11:30:00 +0000 |
commit | 39b534da188063e9b561a272a48ecdc803d3f40e (patch) | |
tree | 81bd6d71c06ace97cb2b0fc75d97bfa59b28b770 /llvm/lib/Support/CommandLine.cpp | |
parent | b5f69e234ef0af43fa4b86d9977d46e0a4e442e7 (diff) | |
download | llvm-39b534da188063e9b561a272a48ecdc803d3f40e.zip llvm-39b534da188063e9b561a272a48ecdc803d3f40e.tar.gz llvm-39b534da188063e9b561a272a48ecdc803d3f40e.tar.bz2 |
Allow negative offsets in MipsMCInstLower::LowerOperand
Summary:
We rely on this in our CHERI backend to address the GOT by generating a
$pc-relative addresses. For this we emit the following code sequence:
lui $1, %pcrel_hi(_CHERI_CAPABILITY_TABLE_-8)
daddiu $1, $1, %pcrel_lo(_CHERI_CAPABILITY_TABLE_-4)
cgetpccincoffset $c1, $1
However, without this change the addend is implicitly converted to
UINT32_MAX and an invalid pointer value is generated.
Reviewers: atanasyan
Reviewed By: atanasyan
Subscribers: merge_guards_bot, sdardis, hiraditya, jrtc27, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D70953
Diffstat (limited to 'llvm/lib/Support/CommandLine.cpp')
0 files changed, 0 insertions, 0 deletions