Skip to content

Support for Tasking compiler toolchain #841

Open

Description

@vsplesk

Hi,

I would like to use ccache in combination with TASKING VX-toolset. This is a commercial C/C++ compiler which command line syntax is unfortunately not fully GCC compatible. See https://www.tasking.com/support/tricore/ctc_user_guide_v6.2r2.pdf for its documentation. Another toolchain coming close is from Green Hills which is listed as semi-supported on your features page.

In theory, I could hack the support into ccache but the code looks quite complicated. It would be good if someone could highlight the relevant locations to add a new compiler. Or I can offer testing a few things if needed. Please note that this compiler includes its own caching functionality already but I would like to benchmark this and ccache against each other.

Activity

  1. changed the title [-]Support of Tasking compiler toolchain[/-] [+]Support for Tasking compiler toolchain[/+] on Apr 29, 2021
  2. jrosdahl commented on May 1, 2021

    @jrosdahl
    Member

    Hi,

    There are no specific locations where you can add support for a new compiler since there is no such compiler abstraction in the code. Instead, the current (relatively small variation in) compiler-specific behavior is handled in a few different places. You can search for config.compiler_type() to find them.

    I know next to nothing about the TASKING compiler, but if you want to work on a proof of concept we could certainly have a look at it or give guidance about specific issues.

  3. louiscaron commented on Sep 18, 2021

    @louiscaron
    Contributor

    Hello @vsplesk , were you able to add support for tasking compiler in ccache ? I have tried using the tasking internal cache mechanism (--cache), but the time gain I get is so small that I am evaluating switching to ccache where I would get a better control over the cache search algorithm. Thanks for any advice!

  4. vsplesk commented on Sep 19, 2021

    @vsplesk
    ContributorAuthor

    I am sorry, I couldn't find time to work on this project. I have also found --cache option to be not very effective most of the time, i.e. greatly varying between 5% and >> 50% speedup. It's simply not reliable and not as fast as ccache used to be in regular FOSS projects (not sure about our code base, this is yet to be investigated).

    In case you start implementing this soon, please send me a note about your fork/branch and I might collaborate there.

  5. louiscaron commented on Sep 19, 2021

    @louiscaron
    Contributor
  6. vsplesk commented on Sep 19, 2021

    @vsplesk
    ContributorAuthor

    There was no demand for the preprocessor mode yet.

  7. Joldiges commented on Sep 19, 2021

    @Joldiges

    I observed ~10% improvement as well on the codebase I used for "--cache"

    In case you start implementing this soon, please send me a note about your fork/branch and I might collaborate there.

    Same here.

  8. louiscaron commented on Sep 20, 2021

    @louiscaron
    Contributor
  9. Joldiges commented on Sep 20, 2021

    @Joldiges

    I have started, but I am targeting the tasking tricore compiler (ctc and cctc), is this what you guys are waiting for?

    It is for me

  10. louiscaron commented on Oct 6, 2021

    @louiscaron
    Contributor

    I have started the development, I have submitted a first draft for initial merge so that we can start collaborating. #942

  11. louiscaron commented on Oct 11, 2021

    @louiscaron
    Contributor

    @jrosdahl : I have submitted the pull request #942 , it looks like it is waiting for some administrator action. Would you mind having a look and eventually indicating what I need to do to move forward? any advice is welcome!

  12. vsplesk commented on Nov 2, 2021

    @vsplesk
    ContributorAuthor

    I tried #942 on a few real-life projects and it worked very smoothly. Build time reduction way over 90% and no inconsistency issues observed so far. Good job!

  13. Joldiges commented on Nov 11, 2021

    @Joldiges

    @louiscaron, tried on the project i'm touching. Good news is that I also saw (unmeasured) 90% improvement.
    Unfortunately, there are compilation issues encountered when library files are included with artc component. Perhaps I'm missing something in cmake.

    CCache - Failure with artc

  14. louiscaron commented on Nov 12, 2021

    @louiscaron
    Contributor

    @Joldiges : in my tests, I have only prefixed calls to ctc and cctc with ccache, not artc . still, the error message from ccache is very strange, it probably should not fail even if you prefixed everything with ccache.

    I have two questions:

    • do you have working elements (ccache prefixing calls to ctc or cctc)?
    • can you print the artc full command so I can reproduce your error?
  15. Joldiges commented on Nov 18, 2021

    @Joldiges

    @Joldiges : in my tests, I have only prefixed calls to ctc and cctc with ccache, not artc . still, the error message from ccache is very strange, it probably should not fail even if you prefixed everything with ccache.

    I have two questions:

    • do you have working elements (ccache prefixing calls to ctc or cctc)?
    • can you print the artc full command so I can reproduce your error?

    I have identified the problem and it was specific to the CMake command I was using.
    The issue was resolved removing RULE_LAUNCH_LINK/RULE_LAUNCH_COMPILE to use CMAKE_C_COMPILER_LAUNCHER.

  16. jrosdahl commented on Aug 18, 2022

    @jrosdahl
    Member

    Just a note on the status of this feature:

  17. linked a pull request that will close this issueSupport Tricore compiler from Tasking #942on Aug 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    issue: feature

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions