Merge the preliminary Super-H support from /branches/Super-H.
author"Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Wed Jan 16 22:06:15 2008 +0000 (2008-01-16)
changeset 41335952da8c80b
parent 412 e1cc03fb2794
child 414 12919d5777fb
Merge the preliminary Super-H support from /branches/Super-H.
arch/sh/config.in
arch/sh/functions
config/target.in
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/arch/sh/config.in	Wed Jan 16 22:06:15 2008 +0000
     1.3 @@ -0,0 +1,27 @@
     1.4 +# Super-H specific configuration file
     1.5 +
     1.6 +comment "Super-H specific configuration"
     1.7 +
     1.8 +choice
     1.9 +    bool
    1.10 +    prompt "Variant"
    1.11 +
    1.12 +config ARCH_SH_SH3
    1.13 +    bool
    1.14 +    prompt "sh3"
    1.15 +
    1.16 +config ARCH_SH_SH4
    1.17 +    bool
    1.18 +    prompt "sh4"
    1.19 +
    1.20 +config ARCH_SH_SH4A
    1.21 +    bool
    1.22 +    prompt "sh4a"
    1.23 +
    1.24 +endchoice
    1.25 +
    1.26 +config ARCH_SH_VARIANT
    1.27 +    string
    1.28 +    default "sh3"   if ARCH_SH_SH3
    1.29 +    default "sh4"   if ARCH_SH_SH4
    1.30 +    default "sh4a"  if ARCH_SH_SH4A
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/arch/sh/functions	Wed Jan 16 22:06:15 2008 +0000
     2.3 @@ -0,0 +1,32 @@
     2.4 +# Compute sh-specific values
     2.5 +
     2.6 +CT_DoArchValues () {
     2.7 +    # The architecture part of the tuple:
     2.8 +    CT_TARGET_ARCH="${CT_ARCH_SH_VARIANT}${target_endian_eb}"
     2.9 +
    2.10 +    # gcc ./configure flags
    2.11 +    CT_ARCH_WITH_ARCH=
    2.12 +    CT_ARCH_WITH_ABI=
    2.13 +    CT_ARCH_WITH_CPU=
    2.14 +    CT_ARCH_WITH_TUNE=
    2.15 +    CT_ARCH_WITH_FPU=
    2.16 +    CT_ARCH_WITH_FLOAT=
    2.17 +
    2.18 +    # Endianness stuff
    2.19 +    case "${CT_ARCH_BE},${CT_ARCH_LE}" in
    2.20 +        y,) CT_ARCH_ENDIAN_CFLAG=-mb;;
    2.21 +        ,y) CT_ARCH_ENDIAN_CFLAG=-ml;;
    2.22 +    esac
    2.23 +
    2.24 +    # CFLAGS
    2.25 +    case "${CT_ARCH_SH_VARIENT}" in
    2.26 +        sh3)    CT_ARCH_ARCH_CFLAG=-m3;;
    2.27 +        sh4*)
    2.28 +            case "${CT_ARCH_FLOAT_HW},${CT_ARCH_FLOAT_SW}" in
    2.29 +                y,) CT_ARCH_ARCH_CFLAG="-m4${CT_ARCH_SH_VARIANT##sh?}";;
    2.30 +                ,y) CT_ARCH_ARCH_CFLAG="-m4${CT_ARCH_SH_VARIANT##sh?}-nofpu";;
    2.31 +            esac
    2.32 +            ;;
    2.33 +    esac
    2.34 +    CT_ARCH_FLOAT_CFLAG=
    2.35 +}
     3.1 --- a/config/target.in	Wed Jan 16 21:51:18 2008 +0000
     3.2 +++ b/config/target.in	Wed Jan 16 22:06:15 2008 +0000
     3.3 @@ -9,6 +9,7 @@
     3.4      default "arm"     if ARCH_ARM
     3.5      default "ia64"    if ARCH_IA64
     3.6      default "mips"    if ARCH_MIPS
     3.7 +    default "sh"      if ARCH_SH
     3.8      default "x86"     if ARCH_x86
     3.9      default "x86_64"  if ARCH_x86_64
    3.10  
    3.11 @@ -29,6 +30,13 @@
    3.12      depends on EXPERIMENTAL
    3.13      select ARCH_SUPPORTS_BOTH_ENDIAN
    3.14  
    3.15 +config ARCH_SH
    3.16 +    bool
    3.17 +    prompt "sh (EXPERIMENTAL)"
    3.18 +    depends on EXPERIMENTAL
    3.19 +    select ARCH_SUPPORTS_BOTH_ENDIAN
    3.20 +    select ARCH_DEFAULT_LE
    3.21 +
    3.22  config ARCH_MIPS
    3.23      bool
    3.24      prompt "mips"
    3.25 @@ -84,6 +92,9 @@
    3.26  if ARCH_MIPS
    3.27  source config/arch/mips/config.in
    3.28  endif
    3.29 +if ARCH_SH
    3.30 +source config/arch/sh/config.in
    3.31 +endif
    3.32  if ARCH_x86
    3.33  source config/arch/x86/config.in
    3.34  endif