• 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. putting 2 strings together in axlSetJobPolicy

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 143
  • Views 13087
  • 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

putting 2 strings together in axlSetJobPolicy

ejm20
ejm20 over 14 years ago

I am trying to create a script that will work with ADEXL's job policies and the script needs to build
the command line.

 Whats the correct syntax to put the 2 two togther?

This will get the command field


axlGetAttachedJobPolicy()->jobsubmitcommand


and lets say it has the following:
-J newJob

This line will replace the jobsubmitcommand:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D -C mmsim_m_2  " )

I need it to look like this:

axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand" "nc run -D -C mmsim_m_2  -J newJob " )

so how can I put the 2 togther?   strcat or something?   It looks like   axlSetJobPolicyProperty()  will not evaluate
any variable .

Thanks

  • Cancel
Parents
  • ejm20
    ejm20 over 14 years ago

    I spoke too soon, this is what it generates

     nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 -J Hclass -r+ RAM/1000

     probably because it does this for each test that ADEXL creates.   Here the bulk of the code:

     

     ;;;  tb_pnr_pg_switches
    ;;;  load "/projects/svl/882XV/882XV_A/rmattern/cds_libs/skill/ADEXL_tokenSet.il"


    ;; defining the PreRun function
    (define (PreRun session_name sdb_highandle mode_string test_name)
            (printf "Launching a new run %L %L %L %L\n" session_name sdb_highandle mode_string test_name)
           
           ;; pre run customization
           
            tests=axlGetTests(sdb_highandle)
                
        jobPolicyName=axlGetAttachedJobPolicy()->name
        
        distmethod=axlGetAttachedJobPolicy()->distributionmethod

            println( jobPolicyName )

             ;; traversing all the tests and changing the mt option as per the requirement

       foreach(  test_name cadr(tests)
          if(  axlGetEnabled(axlGetTest(sdb_highandle test_name)) then
              printf("test %s is enabled\n" test_name)
              testSession=axlGetToolSession(session_name test_name)
            
              mt_opt=testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value
              if(eq(strcmp(mt_opt "Manual")  0) printf("  Manual MT will be disabled!!! \n"))
              if(eq(strcmp(mt_opt "Disable")    0) printf("Disabled MT \n"))
              if(eq(strcmp(mt_opt "Auto")     0) printf(" Auto MT will be disabled!!! \n"))

              if(eq(strcmp(distmethod "Local") 0) then printf(" Turning off the MT options for this test \n")
                testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value="Disable" )
     
              tool_opt=testSession~>simID~>data~>env~>data~>turboOpts~>data~>uniMode~>value
          
          println( tool_opt )
             
          extraCmdOpts=axlGetAttachedJobPolicy()->jobsubmitcommand

              println( extraCmdOpts )

    ;;*********************************************************
    ;; Spectre
    ;;*********************************************************

              if(eq(strcmp(tool_opt "Spectre") 0) then printf(" Spectre run - 1 token \n")
              
             axlSetJobPolicyProperty( "ADEXL_mmsim_h" "jobsubmitcommand"  strcat("nc run -D -C mmsim_h_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )
             axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand"  strcat("nc run -D -C mmsim_m_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )
             axlSetJobPolicyProperty( "ADEXL_mmsim_l" "jobsubmitcommand"  strcat("nc run -D -C mmsim_l_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )




                 testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value="Disable"         
             ) ;if       

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • ejm20
    ejm20 over 14 years ago

    I spoke too soon, this is what it generates

     nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 nc run -D -C mmsim_h_1 -J Hclass -r+ RAM/1000

     probably because it does this for each test that ADEXL creates.   Here the bulk of the code:

     

     ;;;  tb_pnr_pg_switches
    ;;;  load "/projects/svl/882XV/882XV_A/rmattern/cds_libs/skill/ADEXL_tokenSet.il"


    ;; defining the PreRun function
    (define (PreRun session_name sdb_highandle mode_string test_name)
            (printf "Launching a new run %L %L %L %L\n" session_name sdb_highandle mode_string test_name)
           
           ;; pre run customization
           
            tests=axlGetTests(sdb_highandle)
                
        jobPolicyName=axlGetAttachedJobPolicy()->name
        
        distmethod=axlGetAttachedJobPolicy()->distributionmethod

            println( jobPolicyName )

             ;; traversing all the tests and changing the mt option as per the requirement

       foreach(  test_name cadr(tests)
          if(  axlGetEnabled(axlGetTest(sdb_highandle test_name)) then
              printf("test %s is enabled\n" test_name)
              testSession=axlGetToolSession(session_name test_name)
            
              mt_opt=testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value
              if(eq(strcmp(mt_opt "Manual")  0) printf("  Manual MT will be disabled!!! \n"))
              if(eq(strcmp(mt_opt "Disable")    0) printf("Disabled MT \n"))
              if(eq(strcmp(mt_opt "Auto")     0) printf(" Auto MT will be disabled!!! \n"))

              if(eq(strcmp(distmethod "Local") 0) then printf(" Turning off the MT options for this test \n")
                testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value="Disable" )
     
              tool_opt=testSession~>simID~>data~>env~>data~>turboOpts~>data~>uniMode~>value
          
          println( tool_opt )
             
          extraCmdOpts=axlGetAttachedJobPolicy()->jobsubmitcommand

              println( extraCmdOpts )

    ;;*********************************************************
    ;; Spectre
    ;;*********************************************************

              if(eq(strcmp(tool_opt "Spectre") 0) then printf(" Spectre run - 1 token \n")
              
             axlSetJobPolicyProperty( "ADEXL_mmsim_h" "jobsubmitcommand"  strcat("nc run -D -C mmsim_h_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )
             axlSetJobPolicyProperty( "ADEXL_mmsim_m" "jobsubmitcommand"  strcat("nc run -D -C mmsim_m_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )
             axlSetJobPolicyProperty( "ADEXL_mmsim_l" "jobsubmitcommand"  strcat("nc run -D -C mmsim_l_1 " axlGetAttachedJobPolicy()->jobsubmitcommand) )




                 testSession~>simID~>data~>env~>data~>turboOpts~>data~>mtOption~>value="Disable"         
             ) ;if       

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

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