aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2023-09-23 15:06:27 +0200
committerRon Evans <[email protected]>2024-01-05 21:13:30 +0100
commit6984af43a08b7fa1c1020700c42ce8c417d1f542 (patch)
tree79e9b9bfe07c1d9a67913585a39ec17321715ce4
parent81c56c3ab89fe0598361c00f03eb0498d2ea0924 (diff)
downloadtinygo-6984af43a08b7fa1c1020700c42ce8c417d1f542.tar.gz
tinygo-6984af43a08b7fa1c1020700c42ce8c417d1f542.zip
all: statically link to LLVM 17 instead of LLVM 16
We can now finally do it, now that Espressif has updated their fork.
-rw-r--r--.circleci/config.yml4
-rw-r--r--.github/workflows/build-macos.yml4
-rw-r--r--.github/workflows/docker.yml2
-rw-r--r--.github/workflows/linux.yml12
-rw-r--r--.github/workflows/nix.yml2
-rw-r--r--.github/workflows/sizediff.yml2
-rw-r--r--.github/workflows/windows.yml4
-rw-r--r--GNUmakefile2
-rw-r--r--builder/cc1as.cpp23
-rw-r--r--builder/cc1as.h10
-rw-r--r--builder/clang.cpp2
-rw-r--r--builder/lld.cpp29
-rw-r--r--builder/sizes_test.go4
-rw-r--r--builder/tools-builtin.go31
-rw-r--r--compileopts/target.go22
-rw-r--r--targets/esp32.json2
-rw-r--r--targets/esp32c3.json2
-rw-r--r--targets/fe310.json2
-rw-r--r--targets/k210.json2
-rw-r--r--targets/nintendoswitch.json2
-rw-r--r--targets/riscv-qemu.json2
21 files changed, 83 insertions, 82 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index e97d89000..24000821c 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -10,12 +10,12 @@ commands:
steps:
- restore_cache:
keys:
- - llvm-source-16-v3
+ - llvm-source-17-v1
- run:
name: "Fetch LLVM source"
command: make llvm-source
- save_cache:
- key: llvm-source-16-v3
+ key: llvm-source-17-v1
paths:
- llvm-project/clang/lib/Headers
- llvm-project/clang/include
diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml
index 53bde4521..230603bb1 100644
--- a/.github/workflows/build-macos.yml
+++ b/.github/workflows/build-macos.yml
@@ -33,7 +33,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-macos-v1
+ key: llvm-source-17-macos-v1
path: |
llvm-project/clang/lib/Headers
llvm-project/clang/include
@@ -58,7 +58,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-build
with:
- key: llvm-build-16-macos-v1
+ key: llvm-build-17-macos-v1
path: llvm-build
- name: Build LLVM
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml
index 1425d808f..6918cec08 100644
--- a/.github/workflows/docker.yml
+++ b/.github/workflows/docker.yml
@@ -61,7 +61,7 @@ jobs:
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
- build-contexts: tinygo-llvm-build=docker-image://tinygo/llvm-16
+ build-contexts: tinygo-llvm-build=docker-image://tinygo/llvm-17
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Trigger Drivers repo build on Github Actions
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml
index 76ebaba54..fc2f9ae1f 100644
--- a/.github/workflows/linux.yml
+++ b/.github/workflows/linux.yml
@@ -43,7 +43,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-linux-alpine-v1
+ key: llvm-source-17-linux-alpine-v1
path: |
llvm-project/clang/lib/Headers
llvm-project/clang/include
@@ -68,7 +68,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-build
with:
- key: llvm-build-16-linux-alpine-v1
+ key: llvm-build-17-linux-alpine-v1
path: llvm-build
- name: Build LLVM
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
@@ -194,7 +194,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-linux-asserts-v1
+ key: llvm-source-17-linux-asserts-v1
path: |
llvm-project/clang/lib/Headers
llvm-project/clang/include
@@ -219,7 +219,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-build
with:
- key: llvm-build-16-linux-asserts-v1
+ key: llvm-build-17-linux-asserts-v1
path: llvm-build
- name: Build LLVM
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
@@ -307,7 +307,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-linux-v1
+ key: llvm-source-17-linux-v1
path: |
llvm-project/clang/lib/Headers
llvm-project/clang/include
@@ -332,7 +332,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-build
with:
- key: llvm-build-16-linux-${{ matrix.goarch }}-v1
+ key: llvm-build-17-linux-${{ matrix.goarch }}-v1
path: llvm-build
- name: Build LLVM
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml
index 740de79f1..71c25360f 100644
--- a/.github/workflows/nix.yml
+++ b/.github/workflows/nix.yml
@@ -24,7 +24,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-linux-nix-v1
+ key: llvm-source-17-linux-nix-v1
path: |
llvm-project/compiler-rt
- name: Download LLVM source
diff --git a/.github/workflows/sizediff.yml b/.github/workflows/sizediff.yml
index 6af0ba032..df7340771 100644
--- a/.github/workflows/sizediff.yml
+++ b/.github/workflows/sizediff.yml
@@ -36,7 +36,7 @@ jobs:
uses: actions/cache@v3
id: cache-llvm-source
with:
- key: llvm-source-16-sizediff-v1
+ key: llvm-source-17-sizediff-v1
path: |
llvm-project/compiler-rt
- name: Download LLVM source
diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml
index b7f59479c..65a232c58 100644
--- a/.github/workflows/windows.yml
+++ b/.github/workflows/windows.yml
@@ -41,7 +41,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-source
with:
- key: llvm-source-16-windows-v1
+ key: llvm-source-17-windows-v1
path: |
llvm-project/clang/lib/Headers
llvm-project/clang/include
@@ -66,7 +66,7 @@ jobs:
uses: actions/cache/restore@v3
id: cache-llvm-build
with:
- key: llvm-build-16-windows-v2
+ key: llvm-build-17-windows-v1
path: llvm-build
- name: Build LLVM
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
diff --git a/GNUmakefile b/GNUmakefile
index 730bd99f7..5241d5919 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -238,7 +238,7 @@ gen-device-renesas: build/gen-device-svd
# Get LLVM sources.
$(LLVM_PROJECTDIR)/llvm:
- git clone -b xtensa_release_16.x --depth=1 https://github.com/espressif/llvm-project $(LLVM_PROJECTDIR)
+ git clone -b xtensa_release_17.0.1 --depth=1 https://github.com/espressif/llvm-project $(LLVM_PROJECTDIR)
llvm-source: $(LLVM_PROJECTDIR)/llvm
# Configure LLVM.
diff --git a/builder/cc1as.cpp b/builder/cc1as.cpp
index 8b28426b0..9f9e377fa 100644
--- a/builder/cc1as.cpp
+++ b/builder/cc1as.cpp
@@ -1,5 +1,12 @@
//go:build byollvm
+// Source: https://github.com/llvm/llvm-project/blob/main/clang/tools/driver/cc1as_main.cpp
+// This file needs to be updated each LLVM release.
+// There are a few small modifications to make, like:
+// * ExecuteAssembler is made non-static.
+// * The struct AssemblerImplementation is moved to cc1as.h so it can be
+// included elsewhere.
+
//===-- cc1as.cpp - Clang Assembler --------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
@@ -21,8 +28,8 @@
#include "clang/Frontend/TextDiagnosticPrinter.h"
#include "clang/Frontend/Utils.h"
#include "llvm/ADT/STLExtras.h"
+#include "llvm/ADT/StringExtras.h"
#include "llvm/ADT/StringSwitch.h"
-#include "llvm/ADT/Triple.h"
#include "llvm/IR/DataLayout.h"
#include "llvm/MC/MCAsmBackend.h"
#include "llvm/MC/MCAsmInfo.h"
@@ -46,7 +53,6 @@
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/FileSystem.h"
#include "llvm/Support/FormattedStream.h"
-#include "llvm/Support/Host.h"
#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/Process.h"
@@ -55,6 +61,8 @@
#include "llvm/Support/TargetSelect.h"
#include "llvm/Support/Timer.h"
#include "llvm/Support/raw_ostream.h"
+#include "llvm/TargetParser/Host.h"
+#include "llvm/TargetParser/Triple.h"
#include <memory>
#include <optional>
#include <system_error>
@@ -151,8 +159,7 @@ bool AssemblerInvocation::CreateFromArgs(AssemblerInvocation &Opts,
for (const auto &Arg : Args.getAllArgValues(OPT_fdebug_prefix_map_EQ)) {
auto Split = StringRef(Arg).split('=');
- Opts.DebugPrefixMap.insert(
- {std::string(Split.first), std::string(Split.second)});
+ Opts.DebugPrefixMap.emplace_back(Split.first, Split.second);
}
// Frontend Options
@@ -225,6 +232,9 @@ bool AssemblerInvocation::CreateFromArgs(AssemblerInvocation &Opts,
.Case("default", EmitDwarfUnwindType::Default);
}
+ Opts.EmitCompactUnwindNonCanonical =
+ Args.hasArg(OPT_femit_compact_unwind_non_canonical);
+
Opts.AsSecureLogFile = Args.getLastArgValue(OPT_as_secure_log_file);
return Success;
@@ -260,8 +270,8 @@ static bool ExecuteAssemblerImpl(AssemblerInvocation &Opts,
MemoryBuffer::getFileOrSTDIN(Opts.InputFile, /*IsText=*/true);
if (std::error_code EC = Buffer.getError()) {
- Error = EC.message();
- return Diags.Report(diag::err_fe_error_reading) << Opts.InputFile;
+ return Diags.Report(diag::err_fe_error_reading)
+ << Opts.InputFile << EC.message();
}
SourceMgr SrcMgr;
@@ -278,6 +288,7 @@ static bool ExecuteAssemblerImpl(AssemblerInvocation &Opts,
MCTargetOptions MCOptions;
MCOptions.EmitDwarfUnwind = Opts.EmitDwarfUnwind;
+ MCOptions.EmitCompactUnwindNonCanonical = Opts.EmitCompactUnwindNonCanonical;
MCOptions.AsSecureLogFile = Opts.AsSecureLogFile;
std::unique_ptr<MCAsmInfo> MAI(
diff --git a/builder/cc1as.h b/builder/cc1as.h
index 955ded119..4b22fc3e8 100644
--- a/builder/cc1as.h
+++ b/builder/cc1as.h
@@ -1,3 +1,6 @@
+// Source: https://github.com/llvm/llvm-project/blob/main/clang/tools/driver/cc1as_main.cpp
+// See cc1as.cpp for details.
+
//===-- cc1as.h - Clang Assembler ----------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
@@ -44,7 +47,7 @@ struct AssemblerInvocation {
std::string DwarfDebugFlags;
std::string DwarfDebugProducer;
std::string DebugCompilationDir;
- std::map<const std::string, const std::string> DebugPrefixMap;
+ llvm::SmallVector<std::pair<std::string, std::string>, 0> DebugPrefixMap;
llvm::DebugCompressionType CompressDebugSections =
llvm::DebugCompressionType::None;
std::string MainFileName;
@@ -89,6 +92,10 @@ struct AssemblerInvocation {
/// Whether to emit DWARF unwind info.
EmitDwarfUnwindType EmitDwarfUnwind;
+ // Whether to emit compact-unwind for non-canonical entries.
+ // Note: maybe overriden by other constraints.
+ unsigned EmitCompactUnwindNonCanonical : 1;
+
/// The name of the relocation model to use.
std::string RelocationModel;
@@ -128,6 +135,7 @@ public:
DwarfVersion = 0;
EmbedBitcode = 0;
EmitDwarfUnwind = EmitDwarfUnwindType::Default;
+ EmitCompactUnwindNonCanonical = false;
}
static bool CreateFromArgs(AssemblerInvocation &Res,
diff --git a/builder/clang.cpp b/builder/clang.cpp
index e51d69338..6ffe75e3e 100644
--- a/builder/clang.cpp
+++ b/builder/clang.cpp
@@ -11,7 +11,7 @@
#include <clang/FrontendTool/Utils.h>
#include <llvm/ADT/IntrusiveRefCntPtr.h>
#include <llvm/Option/Option.h>
-#include <llvm/Support/Host.h>
+#include <llvm/TargetParser/Host.h>
using namespace llvm;
using namespace clang;
diff --git a/builder/lld.cpp b/builder/lld.cpp
index 6cecbebe8..734c5703c 100644
--- a/builder/lld.cpp
+++ b/builder/lld.cpp
@@ -5,7 +5,11 @@
#include <lld/Common/Driver.h>
#include <llvm/Support/Parallel.h>
-extern "C" {
+LLD_HAS_DRIVER(coff)
+LLD_HAS_DRIVER(elf)
+LLD_HAS_DRIVER(mingw)
+LLD_HAS_DRIVER(macho)
+LLD_HAS_DRIVER(wasm)
static void configure() {
#if _WIN64
@@ -16,28 +20,13 @@ static void configure() {
#endif
}
-bool tinygo_link_elf(int argc, char **argv) {
- configure();
- std::vector<const char*> args(argv, argv + argc);
- return lld::elf::link(args, llvm::outs(), llvm::errs(), false, false);
-}
-
-bool tinygo_link_macho(int argc, char **argv) {
- configure();
- std::vector<const char*> args(argv, argv + argc);
- return lld::macho::link(args, llvm::outs(), llvm::errs(), false, false);
-}
-
-bool tinygo_link_mingw(int argc, char **argv) {
- configure();
- std::vector<const char*> args(argv, argv + argc);
- return lld::mingw::link(args, llvm::outs(), llvm::errs(), false, false);
-}
+extern "C" {
-bool tinygo_link_wasm(int argc, char **argv) {
+bool tinygo_link(int argc, char **argv) {
configure();
std::vector<const char*> args(argv, argv + argc);
- return lld::wasm::link(args, llvm::outs(), llvm::errs(), false, false);
+ lld::Result r = lld::lldMain(args, llvm::outs(), llvm::errs(), LLD_ALL_DRIVERS);
+ return !r.retCode;
}
} // external "C"
diff --git a/builder/sizes_test.go b/builder/sizes_test.go
index dc45898ec..429e3f3e9 100644
--- a/builder/sizes_test.go
+++ b/builder/sizes_test.go
@@ -41,9 +41,9 @@ func TestBinarySize(t *testing.T) {
// This is a small number of very diverse targets that we want to test.
tests := []sizeTest{
// microcontrollers
- {"hifive1b", "examples/echo", 4484, 280, 0, 2252},
+ {"hifive1b", "examples/echo", 4476, 280, 0, 2252},
{"microbit", "examples/serial", 2724, 388, 8, 2256},
- {"wioterminal", "examples/pininterrupt", 6000, 1484, 116, 6816},
+ {"wioterminal", "examples/pininterrupt", 5996, 1484, 116, 6816},
// TODO: also check wasm. Right now this is difficult, because
// wasm binaries are run through wasm-opt and therefore the
diff --git a/builder/tools-builtin.go b/builder/tools-builtin.go
index 2b3cba618..4169ebc61 100644
--- a/builder/tools-builtin.go
+++ b/builder/tools-builtin.go
@@ -12,10 +12,7 @@ import (
#include <stdbool.h>
#include <stdlib.h>
bool tinygo_clang_driver(int argc, char **argv);
-bool tinygo_link_elf(int argc, char **argv);
-bool tinygo_link_macho(int argc, char **argv);
-bool tinygo_link_mingw(int argc, char **argv);
-bool tinygo_link_wasm(int argc, char **argv);
+bool tinygo_link(int argc, char **argv);
*/
import "C"
@@ -26,16 +23,7 @@ const hasBuiltinTools = true
// This version actually runs the tools because TinyGo was compiled while
// linking statically with LLVM (with the byollvm build tag).
func RunTool(tool string, args ...string) error {
- linker := "elf"
- if tool == "ld.lld" && len(args) >= 2 {
- if args[0] == "-m" && (args[1] == "i386pep" || args[1] == "arm64pe") {
- linker = "mingw"
- } else if args[0] == "-flavor" {
- linker = args[1]
- args = args[2:]
- }
- }
- args = append([]string{"tinygo:" + tool}, args...)
+ args = append([]string{tool}, args...)
var cflag *C.char
buf := C.calloc(C.size_t(len(args)), C.size_t(unsafe.Sizeof(cflag)))
@@ -51,19 +39,8 @@ func RunTool(tool string, args ...string) error {
switch tool {
case "clang":
ok = C.tinygo_clang_driver(C.int(len(args)), (**C.char)(buf))
- case "ld.lld":
- switch linker {
- case "darwin":
- ok = C.tinygo_link_macho(C.int(len(args)), (**C.char)(buf))
- case "elf":
- ok = C.tinygo_link_elf(C.int(len(args)), (**C.char)(buf))
- case "mingw":
- ok = C.tinygo_link_mingw(C.int(len(args)), (**C.char)(buf))
- default:
- return errors.New("unknown linker: " + linker)
- }
- case "wasm-ld":
- ok = C.tinygo_link_wasm(C.int(len(args)), (**C.char)(buf))
+ case "ld.lld", "wasm-ld":
+ ok = C.tinygo_link(C.int(len(args)), (**C.char)(buf))
default:
return errors.New("unknown tool: " + tool)
}
diff --git a/compileopts/target.go b/compileopts/target.go
index f7b8a065f..66f44b7cc 100644
--- a/compileopts/target.go
+++ b/compileopts/target.go
@@ -301,10 +301,10 @@ func defaultTarget(goos, goarch, triple string) (*TargetSpec, error) {
switch goarch {
case "386":
spec.CPU = "pentium4"
- spec.Features = "+cx8,+fxsr,+mmx,+sse,+sse2,+x87"
+ spec.Features = "+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87"
case "amd64":
spec.CPU = "x86-64"
- spec.Features = "+cx8,+fxsr,+mmx,+sse,+sse2,+x87"
+ spec.Features = "+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87"
case "arm":
spec.CPU = "generic"
spec.CFlags = append(spec.CFlags, "-fno-unwind-tables", "-fno-asynchronous-unwind-tables")
@@ -320,8 +320,10 @@ func defaultTarget(goos, goarch, triple string) (*TargetSpec, error) {
spec.CPU = "generic"
if goos == "darwin" {
spec.Features = "+neon"
- } else { // windows, linux
+ } else if goos == "windows" {
spec.Features = "+neon,-fmv"
+ } else { // linux
+ spec.Features = "+neon,-fmv,-outline-atomics"
}
case "wasm":
spec.CPU = "generic"
@@ -349,6 +351,20 @@ func defaultTarget(goos, goarch, triple string) (*TargetSpec, error) {
spec.RTLib = "compiler-rt"
spec.Libc = "musl"
spec.LDFlags = append(spec.LDFlags, "--gc-sections")
+ if goarch == "arm64" {
+ // Disable outline atomics. For details, see:
+ // https://cpufun.substack.com/p/atomics-in-aarch64
+ // A better way would be to fully support outline atomics, which
+ // makes atomics slightly more efficient on systems with many cores.
+ // But the instructions are only supported on newer aarch64 CPUs, so
+ // this feature is normally put in a system library which does
+ // feature detection for you.
+ // We take the lazy way out and simply disable this feature, instead
+ // of enabling it in compiler-rt (which is a bit more complicated).
+ // We don't really need this feature anyway as we don't even support
+ // proper threading.
+ spec.CFlags = append(spec.CFlags, "-mno-outline-atomics")
+ }
} else if goos == "windows" {
spec.Linker = "ld.lld"
spec.Libc = "mingw-w64"
diff --git a/targets/esp32.json b/targets/esp32.json
index c0b0f76a6..f49282fdd 100644
--- a/targets/esp32.json
+++ b/targets/esp32.json
@@ -1,7 +1,7 @@
{
"inherits": ["xtensa"],
"cpu": "esp32",
- "features": "+atomctl,+bool,+coprocessor,+debug,+density,+dfpaccel,+div32,+exception,+fp,+highpriinterrupts,+interrupt,+loop,+mac16,+memctl,+miscsr,+mul32,+mul32high,+nsa,+prid,+regprotect,+rvector,+s32c1i,+sext,+threadptr,+timerint,+windowed",
+ "features": "+atomctl,+bool,+clamps,+coprocessor,+debug,+density,+dfpaccel,+div32,+exception,+fp,+highpriinterrupts,+interrupt,+loop,+mac16,+memctl,+minmax,+miscsr,+mul32,+mul32high,+nsa,+prid,+regprotect,+rvector,+s32c1i,+sext,+threadptr,+timerint,+windowed",
"build-tags": ["esp32", "esp"],
"scheduler": "tasks",
"serial": "uart",
diff --git a/targets/esp32c3.json b/targets/esp32c3.json
index 8cdb278f9..5a1e70626 100644
--- a/targets/esp32c3.json
+++ b/targets/esp32c3.json
@@ -1,6 +1,6 @@
{
"inherits": ["riscv32"],
- "features": "+32bit,+c,+m,-64bit,-a,-d,-e,-experimental-zawrs,-experimental-zca,-experimental-zcd,-experimental-zcf,-experimental-zihintntl,-experimental-ztso,-experimental-zvfh,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xtheadvdot,-xventanacondops,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zihintpause,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
+ "features": "+32bit,+c,+m,-a,-d,-e,-experimental-smaia,-experimental-ssaia,-experimental-zacas,-experimental-zfa,-experimental-zfbfmin,-experimental-zicond,-experimental-zihintntl,-experimental-ztso,-experimental-zvbb,-experimental-zvbc,-experimental-zvfbfmin,-experimental-zvfbfwma,-experimental-zvkg,-experimental-zvkn,-experimental-zvknc,-experimental-zvkned,-experimental-zvkng,-experimental-zvknha,-experimental-zvknhb,-experimental-zvks,-experimental-zvksc,-experimental-zvksed,-experimental-zvksg,-experimental-zvksh,-experimental-zvkt,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xcvbitmanip,-xcvmac,-xsfcie,-xsfvcp,-xtheadba,-xtheadbb,-xtheadbs,-xtheadcmo,-xtheadcondmov,-xtheadfmemidx,-xtheadmac,-xtheadmemidx,-xtheadmempair,-xtheadsync,-xtheadvdot,-xventanacondops,-zawrs,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zca,-zcb,-zcd,-zce,-zcf,-zcmp,-zcmt,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zicntr,-zicsr,-zifencei,-zihintpause,-zihpm,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvfh,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
"build-tags": ["esp32c3", "esp"],
"serial": "usb",
"rtlib": "compiler-rt",
diff --git a/targets/fe310.json b/targets/fe310.json
index 37bd5a4c2..a51488358 100644
--- a/targets/fe310.json
+++ b/targets/fe310.json
@@ -1,6 +1,6 @@
{
"inherits": ["riscv32"],
"cpu": "sifive-e31",
- "features": "+32bit,+a,+c,+m,-64bit,-d,-e,-experimental-zawrs,-experimental-zca,-experimental-zcd,-experimental-zcf,-experimental-zihintntl,-experimental-ztso,-experimental-zvfh,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xtheadvdot,-xventanacondops,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zihintpause,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
+ "features": "+32bit,+a,+c,+m,-d,-e,-experimental-smaia,-experimental-ssaia,-experimental-zacas,-experimental-zfa,-experimental-zfbfmin,-experimental-zicond,-experimental-zihintntl,-experimental-ztso,-experimental-zvbb,-experimental-zvbc,-experimental-zvfbfmin,-experimental-zvfbfwma,-experimental-zvkg,-experimental-zvkn,-experimental-zvknc,-experimental-zvkned,-experimental-zvkng,-experimental-zvknha,-experimental-zvknhb,-experimental-zvks,-experimental-zvksc,-experimental-zvksed,-experimental-zvksg,-experimental-zvksh,-experimental-zvkt,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xcvbitmanip,-xcvmac,-xsfcie,-xsfvcp,-xtheadba,-xtheadbb,-xtheadbs,-xtheadcmo,-xtheadcondmov,-xtheadfmemidx,-xtheadmac,-xtheadmemidx,-xtheadmempair,-xtheadsync,-xtheadvdot,-xventanacondops,-zawrs,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zca,-zcb,-zcd,-zce,-zcf,-zcmp,-zcmt,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zicntr,-zicsr,-zifencei,-zihintpause,-zihpm,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvfh,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
"build-tags": ["fe310", "sifive"]
}
diff --git a/targets/k210.json b/targets/k210.json
index 347ffe35b..778e403c6 100644
--- a/targets/k210.json
+++ b/targets/k210.json
@@ -1,6 +1,6 @@
{
"inherits": ["riscv64"],
- "features": "+64bit,+a,+c,+d,+f,+m,-e,-experimental-zawrs,-experimental-zca,-experimental-zcd,-experimental-zcf,-experimental-zihintntl,-experimental-ztso,-experimental-zvfh,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xtheadvdot,-xventanacondops,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zihintpause,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
+ "features": "+64bit,+a,+c,+d,+f,+m,+zicsr,+zifencei,-e,-experimental-smaia,-experimental-ssaia,-experimental-zacas,-experimental-zfa,-experimental-zfbfmin,-experimental-zicond,-experimental-zihintntl,-experimental-ztso,-experimental-zvbb,-experimental-zvbc,-experimental-zvfbfmin,-experimental-zvfbfwma,-experimental-zvkg,-experimental-zvkn,-experimental-zvknc,-experimental-zvkned,-experimental-zvkng,-experimental-zvknha,-experimental-zvknhb,-experimental-zvks,-experimental-zvksc,-experimental-zvksed,-experimental-zvksg,-experimental-zvksh,-experimental-zvkt,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xcvbitmanip,-xcvmac,-xsfcie,-xsfvcp,-xtheadba,-xtheadbb,-xtheadbs,-xtheadcmo,-xtheadcondmov,-xtheadfmemidx,-xtheadmac,-xtheadmemidx,-xtheadmempair,-xtheadsync,-xtheadvdot,-xventanacondops,-zawrs,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zca,-zcb,-zcd,-zce,-zcf,-zcmp,-zcmt,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zicntr,-zihintpause,-zihpm,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvfh,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
"build-tags": ["k210", "kendryte"],
"code-model": "medium"
}
diff --git a/targets/nintendoswitch.json b/targets/nintendoswitch.json
index 5efede411..e86cfc171 100644
--- a/targets/nintendoswitch.json
+++ b/targets/nintendoswitch.json
@@ -1,7 +1,7 @@
{
"llvm-target": "aarch64",
"cpu": "cortex-a57",
- "features": "+aes,+crc,+crypto,+fp-armv8,+neon,+sha2,+v8a,-fmv",
+ "features": "+aes,+crc,+fp-armv8,+neon,+sha2,+v8a,-fmv",
"build-tags": ["nintendoswitch", "arm64"],
"scheduler": "tasks",
"goos": "linux",
diff --git a/targets/riscv-qemu.json b/targets/riscv-qemu.json
index 1a920282c..7f9c5e395 100644
--- a/targets/riscv-qemu.json
+++ b/targets/riscv-qemu.json
@@ -1,6 +1,6 @@
{
"inherits": ["riscv32"],
- "features": "+32bit,+a,+c,+m,-64bit,-d,-e,-experimental-zawrs,-experimental-zca,-experimental-zcd,-experimental-zcf,-experimental-zihintntl,-experimental-ztso,-experimental-zvfh,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xtheadvdot,-xventanacondops,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zihintpause,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
+ "features": "+32bit,+a,+c,+m,-d,-e,-experimental-smaia,-experimental-ssaia,-experimental-zacas,-experimental-zfa,-experimental-zfbfmin,-experimental-zicond,-experimental-zihintntl,-experimental-ztso,-experimental-zvbb,-experimental-zvbc,-experimental-zvfbfmin,-experimental-zvfbfwma,-experimental-zvkg,-experimental-zvkn,-experimental-zvknc,-experimental-zvkned,-experimental-zvkng,-experimental-zvknha,-experimental-zvknhb,-experimental-zvks,-experimental-zvksc,-experimental-zvksed,-experimental-zvksg,-experimental-zvksh,-experimental-zvkt,-f,-h,-relax,-save-restore,-svinval,-svnapot,-svpbmt,-v,-xcvbitmanip,-xcvmac,-xsfcie,-xsfvcp,-xtheadba,-xtheadbb,-xtheadbs,-xtheadcmo,-xtheadcondmov,-xtheadfmemidx,-xtheadmac,-xtheadmemidx,-xtheadmempair,-xtheadsync,-xtheadvdot,-xventanacondops,-zawrs,-zba,-zbb,-zbc,-zbkb,-zbkc,-zbkx,-zbs,-zca,-zcb,-zcd,-zce,-zcf,-zcmp,-zcmt,-zdinx,-zfh,-zfhmin,-zfinx,-zhinx,-zhinxmin,-zicbom,-zicbop,-zicboz,-zicntr,-zicsr,-zifencei,-zihintpause,-zihpm,-zk,-zkn,-zknd,-zkne,-zknh,-zkr,-zks,-zksed,-zksh,-zkt,-zmmul,-zve32f,-zve32x,-zve64d,-zve64f,-zve64x,-zvfh,-zvl1024b,-zvl128b,-zvl16384b,-zvl2048b,-zvl256b,-zvl32768b,-zvl32b,-zvl4096b,-zvl512b,-zvl64b,-zvl65536b,-zvl8192b",
"build-tags": ["virt", "qemu"],
"default-stack-size": 4096,
"linkerscript": "targets/riscv-qemu.ld",