]> granicus.if.org Git - clang/commit
[RISCV] Define __riscv_cmodel_medlow and __riscv_cmodel_medany correctly
authorKito Cheng <kito.cheng@gmail.com>
Tue, 17 Sep 2019 08:09:56 +0000 (08:09 +0000)
committerKito Cheng <kito.cheng@gmail.com>
Tue, 17 Sep 2019 08:09:56 +0000 (08:09 +0000)
commit4f5495d1369407d0798c577d0c47d5d2ce990d45
tree48dfca4b7a1cf714f678be4c0bc09e8a7e265e5e
parent8fd910d9ac66af41e21108958988a7b5ffadf737
[RISCV] Define __riscv_cmodel_medlow and __riscv_cmodel_medany correctly

RISC-V LLVM was only implement small/medlow code model, so it defined
__riscv_cmodel_medlow directly without check.

Now, we have medium/medany code model in RISC-V back-end, it should
define according the actually code model.

Reviewed By: lewis-revill

Differential Revision: https://reviews.llvm.org/D67065

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@372078 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Basic/Targets/RISCV.cpp
test/Preprocessor/riscv-cmodel.c [new file with mode: 0644]