Post Go back to editing

enable fixed point

Category: Software
Product Number: sc594
Software Version: yocto v3.0.0

For yocto v2.1.0  I could enable fixed point by modifying the file shown here
meta-arm/meta-arm-toolchain/recipes-devtools/gcc/gcc-cross-canadian_arm-9.2.bb
recipes-devtools/gcc/gcc-cross-canadian.inc add
-  GCCMULTILIB = "--enable-multilib"
+ GCCMULTILIB = "--enable-multilib --enable-fixed-point"

In yocto 3.0.0 the equivalent files is not used
meta-arm-toolchain/recipes-devtools/gcc/gcc-cross-canadian-aarch64.bb

How do I enable fixed point in v3.0.0 gcc compiler ?

Chris

  • Hi Chris,

    Did you try making the change in the main poky include file?

    poky/meta/recipes-devtools/gcc/gcc-cross-canadian.inc

    GCCMULTILIB = "--enable-multilib"

    or You can pass the same by using EXTRA_OECONF:append:arm in your gcc append layer.

    Thanks,

    Prasanth R

  • This command shows the recipes used

    bitbake -g adsp-sc5xx-minimal && cat pn-buildlist | grep -ve "nativ" | sort | uniq | grep gcc

    gcc
    gcc-cross-aarch64
    gcc-runtime
    gcc-source-11.2.0

    I put the enable-fixed point in all these places

    gcc-runtime.inc:EXTRA_OECONF:append:arm = " --enable-fixed-point"
    gcc-cross.inc:EXTRA_OECONF:append:arm = " --enable-fixed-point"
    gcc/0035-gentypes-genmodes-Do-not-use-__LINE__-for-maintainin.patch: /* Create a fixed-point mode by setting CL, NAME, BYTESIZE, IBIT, FBIT,
    gcc-crosssdk.inc:GCCMULTILIB = "--disable-multilib --enable-fixed-point"
    gcc-configure-common.inc:EXTRA_OECONF:append:arm = " --enable-fixed-point"

    It still failed to compile

    error: fixed-point types not supported for this target

  • Hi Chris,

    kindly share the steps or command used for compiling.

    Thanks,

    Prasanth R

  • The problem is not the build steps,
    I can build the compiler but it still doesn't know about fixed-point

    gcc.gnu.org/.../Fixed-Point.html

    If I Change the "fract" type to in32_t the application compile compiles
    #define fract _Fract
    #undef fract
    #define fract int32_t

    Adding --enable-fixed-point has either not been used or I have put it in the wrong files.

  • The problem is not the build steps,
    I can build the compiler but it still doesn't support fixed-point

    gcc.gnu.org/.../Fixed-Point.html

    If I Change the "fract" type to in32_t the application compile compiles
    #define fract _Fract
    #undef fract
    #define fract int32_t

    Adding --enable-fixed-point has either not been used or I have put it in the wrong files.

  • Hi Chris,

    Apologize for the confusion,

    I asked for the step used to compile your application using the cross-compiler. Just to confirm the flags passed to compile the application.

    I could see some references showing some compiler flags to get the fixed point.

    I will try my compiler with a simple example and let you know,

    Thanks,

    Prasanth R