Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

arm: Profile/variation detection improvements

* Detection of 64-bit Arm v8-a
* Proper detection of integer division support
* always on v7-m, v8-a, v9-a, v8-m.main
* sometimes on v7-a, v7-r, v8-r
* never on v8-m.base v6-m, v6 and older "classic"
* tl;dr: Rely on toolchain preprocessor definition

For the most part these additional variations won't acutally work
for native target builds, but sane -A detection is needed for
"local" builds now. -R detection is left out as it's not likely
to matter.

Change-Id: I8f6a52edc4d14490fc00e2f487406eca701eef02

+30 -90
+5 -8
firmware/export/config.h
··· 711 711 /* define for all cpus from ARM family */ 712 712 #if ARCH == ARCH_ARM 713 713 #define CPU_ARM 714 - #define ARM_ARCH ARCH_VERSION /* ARMv{4,5,6,7} */ 715 - #define ARM_PROFILE ARCH_PROFILE /* Classic, Microcontroller */ 714 + #define ARM_ARCH ARCH_VERSION /* ARMv{4,5,6,7,8,9} */ 715 + #define ARM_PROFILE ARCH_PROFILE /* Classic, Microcontroller, Application [,Realtime] */ 716 716 # if ARM_PROFILE == ARM_PROFILE_MICRO 717 717 # define CPU_ARM_MICRO 718 - # if (ARM_ARCH >= 7) 719 - # define ARM_HAVE_HW_DIV 720 - # endif 721 718 # elif ARM_PROFILE == ARM_PROFILE_CLASSIC 722 719 # define CPU_ARM_CLASSIC 723 720 # elif ARM_PROFILE == ARM_PROFILE_APPLICATION 724 721 # define CPU_ARM_APPLICATION 725 - # if defined(__ARM_FEATURE_IDIV) // Some v7-a, all v8-a 726 - # define ARM_HAVE_HW_DIV 727 - # endif 728 722 # endif 723 + #if defined(__ARM_FEATURE_IDIV) 724 + # define ARM_HAVE_HW_DIV 725 + #endif 729 726 # if (CONFIG_PLATFORM & PLATFORM_NATIVE) && !defined(ARM_HAVE_HW_DIV) 730 727 # define ARM_NEED_DIV0 731 728 # endif
-2
lib/rbcodec/codecs/libwmavoice/libavutil/bswap.h
··· 40 40 # include "avr32/bswap.h" 41 41 #elif ARCH_BFIN 42 42 # include "bfin/bswap.h" 43 - #elif ARCH_SH4 44 - # include "sh4/bswap.h" 45 43 #elif ARCH_X86 46 44 # include "x86/bswap.h" 47 45 #endif
+25 -6
tools/configure
··· 4760 4760 ;; 4761 4761 *) 4762 4762 # On classic ARM we expect an empty string, so only warn if it's nonempty 4763 - if [ -n "$arch_profile" ]; then 4764 - echo "Warning: Cannot determine target ARM profile, assuming classic" 4763 + if [ -z "$arch_profile" ]; then 4764 + arch_profile=classic 4765 + else 4766 + echo "Error: Unsupported target ARM profile ($arch_profile)" 4767 + exit 1 4765 4768 fi 4766 - 4767 - arch_profile=classic 4769 + ;; 4770 + esac 4771 + elif [ -n "$(echo $cpp_defines | grep -w __aarch64__)" ]; then 4772 + arch="arm64" 4773 + # cpp defines like "#define __ARM_ARCH_8A__ 1" (where we want to extract the 8) 4774 + arch_version="$(echo $cpp_defines | tr ' ' '\012' | grep __ARM_ARCH | sed -e 's,.*\([0-9]\).*,\1,' | grep -v __ARM_ARCH | head -1)" 4775 + arch_profile="$(echo "$cpp_defines" | grep 'define __ARM_ARCH_PROFILE' | sed -e 's,.* \([0-9]\+\)$,\1,')" 4776 + if test "$gccnum" -ge "800"; then 4777 + # GCC8+ can natively emit unified asm syntax 4778 + GCCOPTS="$GCCOPTS -masm-syntax-unified" 4779 + fi 4780 + case "$arch_profile" in 4781 + 65) # Cortex-A 4782 + arch_profile=application 4783 + ;; 4784 + *) 4785 + echo "Error: Unsupported target AARCH64 profile ($arch_profile)" 4786 + exit 1 4768 4787 ;; 4769 4788 esac 4770 4789 elif [ -n "$(echo $cpp_defines | grep -w __mips__)" ]; then ··· 4840 4859 #define arch_none 0 4841 4860 #define ARCH_NONE 0 4842 4861 4843 - #define arch_sh 1 4844 - #define ARCH_SH 1 4862 + #define arch_arm64 1 4863 + #define ARCH_ARM64 1 4845 4864 4846 4865 #define arch_m68k 2 4847 4866 #define ARCH_M68K 2
-74
utils/mks5lboot/dualboot/autoconf.h
··· 1 - /*************************************************************************** 2 - * __________ __ ___. 3 - * Open \______ \ ____ ____ | | _\_ |__ _______ ___ 4 - * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / 5 - * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < 6 - * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ 7 - * \/ \/ \/ \/ \/ 8 - * $Id:$ 9 - * 10 - * Copyright (C) 2012 by Andrew Ryabinin 11 - * 12 - * This program is free software; you can redistribute it and/or 13 - * modify it under the terms of the GNU General Public License 14 - * as published by the Free Software Foundation; either version 2 15 - * of the License, or (at your option) any later version. 16 - * 17 - * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY 18 - * KIND, either express or implied. 19 - * 20 - ****************************************************************************/ 21 - #ifndef __BUILD_AUTOCONF_H 22 - #define __BUILD_AUTOCONF_H 23 - 24 - /* lower case names match the what's exported in the Makefile 25 - * upper case name looks nicer in the code */ 26 - 27 - #define arch_none 0 28 - #define ARCH_NONE 0 29 - 30 - #define arch_sh 1 31 - #define ARCH_SH 1 32 - 33 - #define arch_m68k 2 34 - #define ARCH_M68K 2 35 - 36 - #define arch_arm 3 37 - #define ARCH_ARM 3 38 - 39 - #define arch_mips 4 40 - #define ARCH_MIPS 4 41 - 42 - #define arch_x86 5 43 - #define ARCH_X86 5 44 - 45 - #define arch_amd64 6 46 - #define ARCH_AMD64 6 47 - 48 - /* Define target machine architecture */ 49 - #define ARCH arch_arm 50 - /* Optionally define architecture version */ 51 - #define ARCH_VERSION 5 52 - 53 - /* Define endianess for the target or simulator platform */ 54 - #define ROCKBOX_LITTLE_ENDIAN 1 55 - 56 - /* Define this if you build rockbox to support the logf logging and display */ 57 - #undef ROCKBOX_HAS_LOGF 58 - 59 - /* Define this if you want logf to output to the serial port */ 60 - #undef LOGF_SERIAL 61 - 62 - /* Define this to record a chart with timings for the stages of boot */ 63 - #undef DO_BOOTCHART 64 - 65 - /* the threading backend we use */ 66 - #define ASSEMBLER_THREADS 67 - 68 - /* root of Rockbox */ 69 - #define ROCKBOX_DIR "/.rockbox" 70 - #define ROCKBOX_SHARE_PATH "" 71 - #define ROCKBOX_BINARY_PATH "" 72 - #define ROCKBOX_LIBRARY_PATH "" 73 - 74 - #endif /* __BUILD_AUTOCONF_H */