PLITEST サブルーチン

目的

デバッガーをプログラム内の設定ポイントにアタッチして一連のコマンドを実行します。

構文

CALL PLITEST(Debug_Commands, Display Address, plitest_flags, plitest_debugger, plitest_string, plitest_host);

パラメーター

plitest_string は、デバッグ セッションをルーティングする IP アドレスおよびポートを表す文字列です。リモート デバッグに役立ちます。

plitest_debugger は、CodeWatch デバッガーのタイプを表す数値です。
  • 0 = コマンド ライン版の CodeWatch を使用
  • 1 = GUI 版の CodeWatch を使用

pltest_host は、IP およびポートの名前指示子です。

説明

PLITEST は、ユーザー プログラムから呼び出される API で、デバッガーを起動してユーザー プログラムにアタッチし、デバッガーに一連のコマンドを実行させてからユーザーに制御を渡します。通常、PLITEST の呼び出しはユーザー アプリケーションに挿入され、デバッグは、そのアプリケーションにおける実行フロー内の特定のポイントで開始されます。

PLITEST を使用すると、CICS 下で動作する PL/I プログラムをデバッグできますが、これは -optexecオプションの plitest パラメーターを使用した場合でも同様です。詳細については、「コンパイラ オプション」および「Debugging PL/I Programs Under CICS」を参照してください。

この例では、コンパイル時に -bigendian オプションを使用した場合の PLITEST の使用法を示しています。

dcl plitest entry(CHAR(1024) varying native,  char(100) varying native, fixed bin(31) native );

dcl plitest_strings  char(1024) varying native
    init('shlib myprog.so;env myprog;br mylabel;c');

dcl plitest_host char(100) varying native init('10.24.11.80:0');

dcl plitest_debugger   fixed bin(31) init(1);
/*1 = Use codewatch GUI debugger interface*/ 

call PLITEST(plitest_strings, plitest_host, plitest_debugger);

この例では、plitest_stringplitest_debugger、およびplitest_host を使用してデバッガーを起動します。

dcl plitest_string            char(1024) varying native static init(
       'shlib mqplidrv.dll;env mqplidrv;br plitest_label;br %exit[det;q];c');  
dcl plitest_debugger          fixed bin(31) native static init(0);  
dcl plitest_host              char(100) varying native static init('');  
call PLITEST(plitest_string, plitest_host, plitest_debugger);

制限事項

ユーザー プログラムを UNIX/Linux サーバーで実行しながら GUI 版の CodeWatch を Windows マシンで表示する場合は、Micro Focus ViewNow などの X Window Server が必要です。