[JITLink][RISCV] ADD/SUB relocs: read value from working memory
The various ADD/SUB relocations work by reading the current value the relocation points to, transforming it, and then writing it back to memory. While the current implementation writes the value back to working memory, it reads the current value from the execution address of the relocation. This causes at least wrong results, but often crashes, when the addresses of working memory are not equal to execution addresses. This patch fixes this by reading the current value from working memory. Reviewed By: lhames Differential Revision: https://reviews.llvm.org/D147693
Loading
Please sign in to comment