Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use n32:64 in RISC-V data layout #7175

Merged
merged 2 commits into from
Nov 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/LLVM_Headers.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
#include <llvm/Analysis/TargetTransformInfo.h>
#include <llvm/Bitcode/BitcodeReader.h>
#include <llvm/Bitcode/BitcodeWriter.h>
#include <llvm/ExecutionEngine/JITEventListener.h>
#include <llvm/ExecutionEngine/Orc/LLJIT.h>
#include <llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h>
#include <llvm/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.h>
Expand Down
4 changes: 4 additions & 0 deletions src/LLVM_Runtime_Linker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,11 @@ llvm::DataLayout get_data_layout_for_target(Target target) {
if (target.bits == 32) {
return llvm::DataLayout("e-m:e-p:32:32-i64:64-n32-S128");
} else {
#if LLVM_VERSION >= 160
return llvm::DataLayout("e-m:e-p:64:64-i64:64-i128:128-n32:64-S128");
#else
return llvm::DataLayout("e-m:e-p:64:64-i64:64-i128:128-n64-S128");
#endif
}
} else {
internal_error << "Bad target arch: " << target.arch << "\n";
Expand Down