• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. How to execute skill commands in background ?

Stats

  • Locked Locked
  • Replies 6
  • Subscribers 144
  • Views 18245
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to execute skill commands in background ?

Amar Kumar
Amar Kumar over 9 years ago

Hey There,

I want to excecute some skill commands in background which was my main purpose & display results to user.

For which i wrote,

ipcId = ipcBeginProcess("virtuoso -nograph -replay skillFile.il -log myLogFile.log")

"skillFile.il" file creates some file in my working directory.Its taking around 5mins.But i am not able to know when those file creation are completed.

I just want to execute some more skill commands in my current virtuoso only if those files are created.

 

So is there any command which will check in background the "ipcId" functions are executed or still under execution ?

I could have use ipcWait(ipcId) to wait ,but it hangs my current virtuoso or i can check after 5mins through "ipcIsAliveProcess(ipcId)".

But i dont want my current virtuoso to be hang or also dont want to check again or press another bindkey after 5 mins.

Please help me if there is any command which will check automatically after 5 mins in the background if icpId is alive or not.

 

Thanks In Advance,

Amar Kumar

 

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 9 years ago

    Amar,

    ipcBeginProcess can also be run with some callbacks which are invoked when there is output, error output or when the process finishes. This is the "asynchronous" usage of ipcBeginProcess and so you can have a SKILL function called when it finishes.

    There have been recent posts on this (so it should be easy to find them in the forums) plus it is in the documentation.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Amar Kumar
    Amar Kumar over 9 years ago
    Hi Andrew,

    I am writing below.

    procedure(MyDisplayStuff(cid data) printf("%s" data))
    procedure(MyExitHandler(cid status) printf("%s" status))
    ipcBeginProcess("virtuoso -nograph -replay skillFile.il -log myLogFile.log" 'MyDisplayStuff 'MyDisplayStuff "printf(\"MyIpcDone\")")

    I just wanted to print "MyIpcDone" after my ipc function ends.But it is not printing anything.
    Please help reagrding this.

    Thanks,
    Amar
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 9 years ago

    You can't put a callback string as the argument to ipcBeginProcess. It has to be the name of a function (the documentation is fairly clear on this). If you had passed 'MyExitHandler it would have not worked because the status is an integer, not a string, so the printf would have failed. SKILL traps any errors in the exit handler, so maybe that's why you didn't notice it working.

    If you'd done:

    procedure(MyExitHandler(cid status)
      printf("MyIpcDone\n")
    )

    ipcBeginProcess("virtuoso -nograph -replay skillFile.il -log myLogFile.log" 'MyDisplayStuff 'MyDisplayStuff 'MyExitHandler)

    It probably would have been fine.

    Regards,

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Amar Kumar
    Amar Kumar over 9 years ago
    Thanks Andrew,It worked great.
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • saurabh96
    saurabh96 over 4 years ago in reply to Andrew Beckett

    Andrew, how can we ran a process in which output shouldn't display on CIW 

    In below case when am running my job...the log file output is printing on ciw. how can i do when job starts stdout shouldnot comes on ciw

    procedure(Runform(form)
    let((cmdPid abcStdout)

    cmdPid = ipcBeginProcess("./abc.sh")
    ipcWait(cmdPid)
    while(abcStdout=ipcReadProcess(cmdPid)
    printf("%s" abcStdout ) ;
    )
    if(!ipcGetExitStatus(cmdPid) == 0 then
    error("abc: couldnot run\n")

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to saurabh96
    saurabh96 said:

    Andrew, how can we ran a process in which output shouldn't display on CIW 

    I'm not sure why you're posting in the middle of a 5-year old thread with a piece of code that is incomplete. Did you not read the Forum Guidelines?

    Also, if you don't want the output to appear in the CIW, the first thing would be not to actually print the output to the CIW (which is what your code is doing in the while loop)! Isn't that obvious?

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information