zyfeier opened a new pull request, #21208:
URL: https://github.com/apache/nuttx/pull/21208
## Summary
* Why: the TASKING VX-toolset does not accept the GCC double-underscore
keyword spellings `__asm__` and `__volatile__` (it accepts `__asm`, `asm` and
the `__asm volatile` sequence), so sources using them fail to compile with a
syntax error, e.g. the tricore hwdebug support.
* What: redirect the double-underscore spellings to `__asm` and plain
`volatile` in the TASKING branch of `include/nuttx/compiler.h`, the same way
the IAR branch already does.
* How: two preprocessor defines guarded by `__TASKING__`, no code change.
## Impact
* Is new feature added? Is existing feature changed? NO (compatibility fix
for the TASKING compiler).
* Impact on user (will user need to adapt to change)? NO
* Impact on build (will build process change)? YES -- sources using the
GCC spellings compile under TASKING; the GNU, LLVM and IAR builds are
unaffected (the block is guarded by `__TASKING__`).
* Impact on hardware (will arch(s) / board(s) / driver(s) change)? NO
* Impact on documentation (is update required / provided)? NO
* Impact on security (any sort of implications)? NO
* Impact on compatibility (backward/forward/interoperability)? NO
## Testing
I confirm that changes are verified on local setup and works as intended:
* Build Host(s): Linux x86_64
* Toolchains: tricore-elf-gcc 11.3.1; TASKING VX-toolset v6.3r1 (TC3x),
TASKING SmartCode v10.4r1 (TC4x)
* Target(s): tricore, triboard_tc4x9_com:nsh
Testing logs (GNU build of this branch, PASS):
```
tc4xx nsh (triboard_tc4x9_com, tricore-elf-gcc 11.3.1, cmake+ninja):
Linking: nuttx, 4667784 bytes
```
The TASKING effect of the mapping was verified in a local TASKING build of
the tricore port (on top of the TASKING toolchain fixes that are being
upstreamed separately): the `E208 syntax error ... __volatile__` failures in
`tricore_hwdebug.c` disappear and the full nsh configuration compiles with both
VX-toolset v6.3r1 and SmartCode v10.4r1. The tc3x boards cannot be built from
plain master yet (the iLLD v1.22 path fix is in review in #21131).
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]