tmedicci commented on issue #15755:
URL: https://github.com/apache/nuttx/issues/15755#issuecomment-2637412461

   > > [@yamt](https://github.com/yamt) , do you recall how did you test the 
compiler's definition (as stated by 
[c18f074](https://github.com/apache/nuttx/commit/c18f0748303a236cc2b55969e20082c03452b0c5))?
   > 
   > i don't remember what exactly i used. i guess it was `xtensa-esp32-elf-gcc 
-dM -E - < /dev/null | grep INT32_TYPE` or something like that.
   > 
   > it seems that the esp-provided compiler has changed its configuration at 
some point. i guess you or your colleagues can have a better idea about it than 
i have.
   > 
   > ```
   > spacetanuki% 
.espressif.old/tools/xtensa-esp32-elf/esp-2020r3-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
 --version
   > xtensa-esp32-elf-gcc (crosstool-NG esp-2020r3) 8.4.0
   > Copyright (C) 2018 Free Software Foundation, Inc.
   > This is free software; see the source for copying conditions.  There is NO
   > warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
   > 
   > spacetanuki% 
.espressif.old/tools/xtensa-esp32-elf/esp-2020r3-8.4.0/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
 -dM -E - < /dev/null|grep INT32_TYPE
   > #define __INT32_TYPE__ int
   > #define __UINT32_TYPE__ unsigned int
   > spacetanuki% 
   > ```
   > 
   > ```
   > (venv) spacetanuki% xtensa-esp32-elf-gcc --version
   > xtensa-esp32-elf-gcc (crosstool-NG esp-12.2.0_20230208) 12.2.0
   > Copyright (C) 2022 Free Software Foundation, Inc.
   > This is free software; see the source for copying conditions.  There is NO
   > warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
   > 
   > (venv) spacetanuki% xtensa-esp32-elf-gcc -dM -E - < /dev/null|grep 
INT32_TYPE
   > #define __INT32_TYPE__ long int
   > #define __UINT32_TYPE__ long unsigned int
   > (venv) spacetanuki% 
   > ```
   > 
   > > What should we do? Try to fix them all?
   > 
   > adapt to the configuration used by the latest esp toolchain? ie. make it 
long.
   
   Thanks for the information!
   
   > or, restore the toolchain configuration if the change was not intentional.
   
   I don't think it's an option. Check 
https://docs.espressif.com/projects/esp-idf/en/stable/esp32/migration-guides/release-5.x/5.0/gcc.html#espressif-toolchain-changes
 for the associated information:
   
   > This change now matches upstream GCC which long integers for int32_t and 
uint32_t on Xtensa, RISC-V, and other architectures.
   
   So, I think we should change it on NuttX and provide a compiler's version 
check.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to