summaryrefslogtreecommitdiffstats
path: root/openmp/runtime/tools/lib/Platform.pm
diff options
context:
space:
mode:
authorJonas Hahnfeld <hahnjo@hahnjo.de>2019-07-25 14:36:20 +0000
committerJonas Hahnfeld <hahnjo@hahnjo.de>2019-07-25 14:36:20 +0000
commit2488ae9df155cd66253512c42aba5daef1f076be (patch)
tree42a7de40bd8a48380384478161d50659efd3fff3 /openmp/runtime/tools/lib/Platform.pm
parentd668260f1a8e85976e090207075545a2d97d39a1 (diff)
downloadbcm5719-llvm-2488ae9df155cd66253512c42aba5daef1f076be.tar.gz
bcm5719-llvm-2488ae9df155cd66253512c42aba5daef1f076be.zip
[OpenMP] RISCV64 port
This is a port of libomp for the RISC-V 64-bit Linux target. We have tested this port on a HiFive Unleashed development board using a downstream LLVM that has support for the missing bits in upstream. As of now, all tests are passing, including OMPT. Patch by Ferran Pallarès! Differential Revision: https://reviews.llvm.org/D59880 llvm-svn: 367021
Diffstat (limited to 'openmp/runtime/tools/lib/Platform.pm')
-rw-r--r--openmp/runtime/tools/lib/Platform.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/openmp/runtime/tools/lib/Platform.pm b/openmp/runtime/tools/lib/Platform.pm
index b0e10a17ad7..0ff7597e5b9 100644
--- a/openmp/runtime/tools/lib/Platform.pm
+++ b/openmp/runtime/tools/lib/Platform.pm
@@ -61,6 +61,8 @@ sub canon_arch($) {
$arch = "mips64";
} elsif ( $arch =~ m{\Amips} ) {
$arch = "mips";
+ } elsif ( $arch =~ m{\Ariscv64} ) {
+ $arch = "riscv64";
} else {
$arch = undef;
}; # if
@@ -94,6 +96,7 @@ sub canon_mic_arch($) {
"mic" => "Intel(R) Many Integrated Core Architecture",
"mips" => "MIPS",
"mips64" => "MIPS64",
+ "riscv64" => "RISC-V (64-bit)",
);
sub legal_arch($) {
@@ -220,6 +223,8 @@ sub target_options() {
$_host_arch = "mips64";
} elsif ( $hardware_platform eq "mips" ) {
$_host_arch = "mips";
+ } elsif ( $hardware_platform eq "riscv64" ) {
+ $_host_arch = "riscv64";
} else {
die "Unsupported host hardware platform: \"$hardware_platform\"; stopped";
}; # if
@@ -409,7 +414,7 @@ the script assumes host architecture is target one.
Input string is an architecture name to canonize. The function recognizes many variants, for example:
C<32e>, C<Intel64>, C<Intel(R) 64>, etc. Returned string is a canononized architecture name,
-one of: C<32>, C<32e>, C<64>, C<arm>, C<ppc64le>, C<ppc64>, C<mic>, C<mips>, C<mips64>, or C<undef> is input string is not recognized.
+one of: C<32>, C<32e>, C<64>, C<arm>, C<ppc64le>, C<ppc64>, C<mic>, C<mips>, C<mips64>, C<riscv64> or C<undef> is input string is not recognized.
=item B<legal_arch( $arch )>
OpenPOWER on IntegriCloud