https://git.reactos.org/?p=reactos.git;a=commitdiff;h=ed972708f319de871e989…
commit ed972708f319de871e9898a555511058fa8383ee
Author: Mark Jansen <mark.jansen(a)reactos.org>
AuthorDate: Thu Feb 2 01:54:51 2023 +0100
Commit: Mark Jansen <mark.jansen(a)reactos.org>
CommitDate: Sun Feb 5 17:53:02 2023 +0100
[ROSAPPS] Remove pice
---
.../applications/sysutils/utils/pice/loader/main.c | 1001 -----
.../sysutils/utils/pice/loader/retypes.h | 15 -
.../sysutils/utils/pice/loader/stab.def | 264 --
.../sysutils/utils/pice/loader/stab_gnu.h | 37 -
.../sysutils/utils/pice/loader/stdinc.h | 28 -
.../sysutils/utils/pice/loader/terminal.c | 430 --
.../sysutils/utils/pice/loader/terminal.h | 34 -
.../sysutils/utils/pice/module/animation.h | 2116 ----------
.../applications/sysutils/utils/pice/module/bp.c | 752 ----
.../applications/sysutils/utils/pice/module/bp.h | 62 -
.../sysutils/utils/pice/module/charset.h | 2564 ------------
.../sysutils/utils/pice/module/dblflt.c | 133 -
.../sysutils/utils/pice/module/dblflt.h | 32 -
.../sysutils/utils/pice/module/debug.c | 192 -
.../sysutils/utils/pice/module/debug.h | 47 -
.../sysutils/utils/pice/module/disassembler.c | 716 ----
.../sysutils/utils/pice/module/disassembler.h | 159 -
.../sysutils/utils/pice/module/disassemblerdata.h | 1802 ---------
.../utils/pice/module/disassemblerdefines.h | 515 ---
.../sysutils/utils/pice/module/gpfault.c | 142 -
.../sysutils/utils/pice/module/gpfault.h | 34 -
.../sysutils/utils/pice/module/hardware.c | 1020 -----
.../sysutils/utils/pice/module/hardware.h | 166 -
.../sysutils/utils/pice/module/hercules.c | 486 ---
.../sysutils/utils/pice/module/hercules.h | 32 -
.../sysutils/utils/pice/module/hooks.c | 177 -
.../sysutils/utils/pice/module/hooks.h | 49 -
.../applications/sysutils/utils/pice/module/init.c | 379 --
.../applications/sysutils/utils/pice/module/init.h | 35 -
.../sysutils/utils/pice/module/ldrsym.h | 38 -
.../applications/sysutils/utils/pice/module/logo.h | 100 -
.../sysutils/utils/pice/module/output.c | 290 --
.../sysutils/utils/pice/module/output.h | 42 -
.../sysutils/utils/pice/module/parse.c | 4102 --------------------
.../sysutils/utils/pice/module/parse.h | 182 -
.../sysutils/utils/pice/module/patch.c | 235 --
.../sysutils/utils/pice/module/patch.h | 34 -
.../sysutils/utils/pice/module/pci_ids.h | 905 -----
.../sysutils/utils/pice/module/pgflt.c | 402 --
.../sysutils/utils/pice/module/pgflt.h | 34 -
.../sysutils/utils/pice/module/pice.rc | 6 -
.../sysutils/utils/pice/module/pice_ver.h | 36 -
.../sysutils/utils/pice/module/precomp.h | 65 -
.../sysutils/utils/pice/module/privateice.c | 203 -
.../applications/sysutils/utils/pice/module/regs.h | 122 -
.../sysutils/utils/pice/module/remods.h | 33 -
.../sysutils/utils/pice/module/retypes.h | 52 -
.../sysutils/utils/pice/module/scancodes.h | 106 -
.../sysutils/utils/pice/module/serial.c | 656 ----
.../sysutils/utils/pice/module/serial.h | 36 -
.../sysutils/utils/pice/module/serial_port.h | 173 -
.../sysutils/utils/pice/module/shell.c | 1692 --------
.../sysutils/utils/pice/module/shell.h | 91 -
.../sysutils/utils/pice/module/stab.def | 265 --
.../sysutils/utils/pice/module/stab_gnu.h | 67 -
.../sysutils/utils/pice/module/symbols.c | 2984 --------------
.../sysutils/utils/pice/module/symbols.h | 88 -
.../sysutils/utils/pice/module/syscall.c | 231 --
.../sysutils/utils/pice/module/syscall.h | 35 -
.../sysutils/utils/pice/module/trace.c | 91 -
.../sysutils/utils/pice/module/trace.h | 35 -
.../sysutils/utils/pice/module/utils.c | 2430 ------------
.../sysutils/utils/pice/module/utils.h | 325 --
.../applications/sysutils/utils/pice/module/vga.c | 572 ---
.../applications/sysutils/utils/pice/module/vga.h | 32 -
.../sysutils/utils/pice/module/vga_utils.asm | 729 ----
.../applications/sysutils/utils/pice/pice.cfg | 4 -
.../applications/sysutils/utils/pice/readme.txt | 107 -
.../sysutils/utils/pice/shared/shared.h | 204 -
69 files changed, 31253 deletions(-)
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/main.c
b/modules/rosapps/applications/sysutils/utils/pice/loader/main.c
deleted file mode 100644
index d72838385cd..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/main.c
+++ /dev/null
@@ -1,1001 +0,0 @@
-/*++
-
-Copyright (c) 1998-2001 Klaus P. Gerlicher
-
-Module Name:
-
- main.c
-
-Abstract:
-
- loader/translator for pIce LINUX
-
-Environment:
-
- User mode only
-
-Author:
-
- Klaus P. Gerlicher
- ReactOS Port by Eugene Ingerman
-
-Revision History:
-
- 04-Aug-1998: created
- 15-Nov-2000: general cleanup of source files
-
-Copyright notice:
-
- This file may be distributed under the terms of the GNU Public License.
-
---*/
-
-///////////////////////////////////////////////////////////////////////////////////
-// includes
-#include "stdinc.h"
-#include <wchar.h>
-
-///////////////////////////////////////////////////////////////////////////////////
-// constant defines
-
-
-///////////////////////////////////////////////////////////////////////////////////
-// global variables
-char SrcFileNames[2048][2048];
-ULONG ulCurrentSrcFile = 0;
-
-HANDLE debugger_file;
-
-ULONG ulGlobalVerbose = 0;
-
-
-///////////////////////////////////////////////////////////////////////////////////
-// process_stabs()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void process_stabs(
- char* pExeName, // name of exe
- HANDLE fileout, // symbol file handle
- PIMAGE_SECTION_HEADER section, //Elf32_Shdr* pSHdr,
- int sectionHeadersSize, //int nSHdrSize,
- void* p, // ptr to memory where whole exe was read
- PSTAB_ENTRY pStab, // ptr to stabs
- int nStabLen, // size of stabs
- char* pStr, // ptr to stabs strings
- int nStrLen, // sizeof stabs strings
- char* pGlobals, // ptr to global symbols
- int nGlobalLen, // sizeof of globals
- char* pGlobalsStr, // ptr to global strings
- int nGlobalStrLen) // size of global strings
-{
- unsigned i,strLen;
- int nOffset=0,nNextOffset=0;
- PSTAB_ENTRY pStabCopy = pStab;
- char* pName,szCurrentPath[2048];
- PICE_SYMBOLFILE_HEADER SymbolFileHeader;
- LPSTR pSlash,pDot;
- char temp[2048];
- char* pCopyExeName = temp;
- WCHAR tempstr[64];
- DWORD wrote;
-
- //printf("LOADER: enter process_stabs()\n");
-
- //get the name of the executable file
- memset((void*)&SymbolFileHeader,0,sizeof(SymbolFileHeader));
- SymbolFileHeader.magic = PICE_MAGIC;
- strcpy(temp,pExeName);
- pSlash = strrchr(temp,'\\');
- pDot = strchr(temp,'.');
- if(pDot)
- {
- *pDot = 0;
- }
- if(pSlash)
- {
- pCopyExeName = pSlash+1;
- }
- strLen = MultiByteToWideChar(CP_ACP, NULL, pCopyExeName, -1, tempstr, 64 );
- if( !strLen )
- printf("Cannot convert string to multibyte: %s\n", pCopyExeName );
- wcscpy(SymbolFileHeader.name,tempstr);
-
- for(i=0;i<(nStabLen/sizeof(STAB_ENTRY));i++)
- {
- pName = &pStr[pStabCopy->n_strx + nOffset];
-
-#if 0
- //printf("LOADER: \n%.8x %.2x %.2x %.4x %.8x %s\n",
- pStabCopy->n_strx,
- pStabCopy->n_type,
- pStabCopy->n_other,
- pStabCopy->n_desc,
- pStabCopy->n_value,
- pName
- );
-#endif
- switch(pStabCopy->n_type)
- {
- case N_UNDF:
- nOffset += nNextOffset;
- nNextOffset = pStabCopy->n_value;
- //printf("LOADER: changing string offset %x
%x\n",nOffset,nNextOffset);
- break;
- case N_SO:
- if((strLen = strlen(pName)))
- {
- if(pName[strLen-1]!='/')
- {
- if(strlen(szCurrentPath))
- {
- //printf("LOADER:
###########################################################################\n");
- strcat(szCurrentPath,pName);
- //printf("LOADER: changing source file
%s\n",szCurrentPath);
- strcpy(SrcFileNames[ulCurrentSrcFile++],szCurrentPath);
- szCurrentPath[0]=0;
- }
- else
- {
- //printf("LOADER:
###########################################################################\n");
- //printf("LOADER: changing source file
%s\n",pName);
- strcpy(SrcFileNames[ulCurrentSrcFile++],pName);
- }
- }
- else
- strcpy(szCurrentPath,pName);
- }
- else
- {
- //printf("LOADER: END source file\n");
- //printf("LOADER:
###########################################################################\n");
- }
- break;
-/* case N_SLINE:
- //printf("LOADER: code source line number #%u for addr.
%x\n",pStabCopy->n_desc,pStabCopy->n_value);
- break;
- case N_DSLINE:
- //printf("LOADER: data source line number #%u for addr.
%x\n",pStabCopy->n_desc,pStabCopy->n_value);
- break;
- case N_BSLINE:
- //printf("LOADER: BSS source line number #%u for addr.
%x\n",pStabCopy->n_desc,pStabCopy->n_value);
- break;
- case N_GSYM:
- //printf("LOADER: global symbol %s @ addr. %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_BINCL:
- //printf("LOADER: include file %s\n",pName);
- break;
- case N_EINCL:
- break;
- case N_FUN:
- if(strlen(pName))
- //printf("LOADER: function %s @ addr. %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- else
- //printf("LOADER: text segment %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_PSYM:
- //printf("LOADER: parameter %s @ [EBP%+d]
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_RSYM:
- //printf("LOADER: register variable %s @ reg. %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_LBRAC:
- //printf("LOADER: lexical block %s @ reg. %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_RBRAC:
- //printf("LOADER: END of lexical block %s @ reg. %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_STSYM:
- //printf("LOADER: static variable %s @ %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_LCSYM:
- //printf("LOADER: BSS variable %s @ %x
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- break;
- case N_LSYM:
- if(pStabCopy->n_value)
- {
- //printf("LOADER: stack variable %s @ [EBP%+d]
(%x)\n",pName,pStabCopy->n_value,pStabCopy->n_desc);
- }
- else
- {
- //printf("LOADER: global variable %s \n",pName);
- }
- break;
-*/
- }
-
- pStabCopy++;
- }
-
- //printf("LOADER: SymbolFileHeader.ulSizeOfHeader= %x
(%x)\n",nSHdrSize,(LPSTR)pSHdr-(LPSTR)p);
- //printf("LOADER: SymbolFileHeader.ulSizeOfGlobals = %x
(%x)\n",nGlobalLen,(LPSTR)pGlobals-(LPSTR)p);
- //printf("LOADER: SymbolFileHeader.ulSizeOfGlobalsStrings = %x
(%x)\n",nGlobalStrLen,(LPSTR)pGlobalsStr-(LPSTR)p);
- //printf("LOADER: SymbolFileHeader.ulSizeOfStabs = %x
(%x)\n",nStabLen,(LPSTR)pStab-(LPSTR)p);
- //printf("LOADER: SymbolFileHeader.ulSizeOfStabsStrings = %x
(%x)\n",nStrLen,(LPSTR)pStr-(LPSTR)p);
-
- SymbolFileHeader.ulOffsetToHeaders = sizeof(PICE_SYMBOLFILE_HEADER);
- SymbolFileHeader.ulSizeOfHeader = sectionHeadersSize;
- SymbolFileHeader.ulOffsetToGlobals =
sizeof(PICE_SYMBOLFILE_HEADER)+sectionHeadersSize;
- SymbolFileHeader.ulSizeOfGlobals = nGlobalLen;
- SymbolFileHeader.ulOffsetToGlobalsStrings =
sizeof(PICE_SYMBOLFILE_HEADER)+sectionHeadersSize+nGlobalLen;
- SymbolFileHeader.ulSizeOfGlobalsStrings = nGlobalStrLen;
- SymbolFileHeader.ulOffsetToStabs =
sizeof(PICE_SYMBOLFILE_HEADER)+sectionHeadersSize+nGlobalLen+nGlobalStrLen;
- SymbolFileHeader.ulSizeOfStabs = nStabLen;
- SymbolFileHeader.ulOffsetToStabsStrings =
sizeof(PICE_SYMBOLFILE_HEADER)+sectionHeadersSize+nGlobalLen+nGlobalStrLen+nStabLen;
- SymbolFileHeader.ulSizeOfStabsStrings = nStrLen;
- SymbolFileHeader.ulOffsetToSrcFiles =
sizeof(PICE_SYMBOLFILE_HEADER)+sectionHeadersSize+nGlobalLen+nGlobalStrLen+nStabLen+nStrLen;
- SymbolFileHeader.ulNumberOfSrcFiles = ulCurrentSrcFile;
-
- printf("sectionHeaderSize: %ld, nGlobalLen: %ld, nGlobalStrLen: %ld, nStabLen: %ld,
"
- "nStrLen: %ld, ulCurrentSrcFile: %ld, ulOffsetToStabs: %ld\n",
- sectionHeadersSize, nGlobalLen, nGlobalStrLen,
- nStabLen, nStrLen, ulCurrentSrcFile, SymbolFileHeader.ulOffsetToStabs);
-
- WriteFile(fileout,&SymbolFileHeader,sizeof(PICE_SYMBOLFILE_HEADER),&wrote,
NULL);
- WriteFile(fileout,section,sectionHeadersSize,&wrote, NULL);
- WriteFile(fileout,pGlobals,nGlobalLen,&wrote, NULL);
- WriteFile(fileout,pGlobalsStr,nGlobalStrLen,&wrote, NULL);
- WriteFile(fileout,pStab,nStabLen,&wrote, NULL);
- WriteFile(fileout,pStr,nStrLen,&wrote, NULL);
-
- for(i=0;i<ulCurrentSrcFile;i++)
- {
- HANDLE file;
- int len;
- PVOID pFile;
- PICE_SYMBOLFILE_SOURCE pss;
-
- file = CreateFile(SrcFileNames[i],GENERIC_READ , 0, NULL, OPEN_EXISTING, 0, 0);
- //printf("Trying To Open: %s, result: %x\n", SrcFileNames[i], file );
-
-
- if( file == INVALID_HANDLE_VALUE ){
- //let's try win format drive:/file
- char srctmp[2048];
- strcpy(srctmp, SrcFileNames[i] );
- if(strncmp(srctmp,"//",2)==0){
- *(srctmp) = *(srctmp+2);
- *(srctmp+1) = ':';
- *(srctmp+2) = '/';
- file = CreateFile(srctmp,GENERIC_READ, 0, NULL, OPEN_EXISTING, 0, 0);
- //printf("Trying To Open: %s, handle: %x\n", srctmp, file );
- if( file == INVALID_HANDLE_VALUE )
- printf("Can't open file: %s\n", srctmp );
- }
- }
- if(file != INVALID_HANDLE_VALUE)
- {
- //printf("LOADER: [%u] opened %s as FD
%x\n",i,SrcFileNames[i],file);
-
- len = SetFilePointer(file,0,NULL,FILE_END);
- //printf("LOADER: length = %d\n",(int)len);
-
- SetFilePointer(file,0,NULL,FILE_BEGIN);
-
- strcpy(pss.filename,SrcFileNames[i]);
- pss.ulOffsetToNext = len+sizeof(PICE_SYMBOLFILE_SOURCE);
-
- pFile = malloc(len+1);
- //printf("LOADER: memory for file @ %x\n",pFile);
- if(pFile)
- {
- //printf("LOADER: reading file...\n");
- ReadFile(file,pFile,len+1,&wrote,NULL);
- //printf("read: %d, error: %d\n", wrote, GetLastError());
- WriteFile(fileout,&pss,sizeof(PICE_SYMBOLFILE_SOURCE),&wrote,
NULL);
- WriteFile(fileout,pFile,len,&wrote, NULL);
- //printf("LOADER: writing file...%d\n%s\n",wrote,pFile );
- free(pFile);
- }
-
- CloseHandle(file);
- }
-
- }
-
- //printf("LOADER: leave process_stabs()\n");
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// find_stab_sections()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void find_stab_sections(void* p,PIMAGE_SECTION_HEADER section, unsigned cSections,
- PSTAB_ENTRY* ppStab,int* pLen,char** ppStr,int* pnStabStrLen)
-{
- unsigned i;
- //printf("LOADER: enter find_stab_sections()\n");
- *ppStab = 0;
- *ppStr = 0;
-
- for ( i=1; i <= cSections; i++, section++ )
- {
-
- if(strcmp(section->Name,".stab") == 0)
- {
- *ppStab = (PSTAB_ENTRY)((int)p + section->PointerToRawData);
- *pLen = section->SizeOfRawData;
- printf("LOADER: .stab @ %x (offset %x) len =
%x\n",*ppStab,section->PointerToRawData,section->SizeOfRawData);
- }
- else
if(strncmp(section->Name,".stabstr",strlen(".stabstr")) == 0)
- {
- *ppStr = (char*)((int)p + section->PointerToRawData);
- *pnStabStrLen = section->SizeOfRawData;
- printf("LOADER: .stabstr @ %x (offset %x) len =
%x\n",*ppStab,section->PointerToRawData,section->SizeOfRawData);
- }
- }
-
- //printf("LOADER: leave find_stab_sections()\n");
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// process_pe()
-//
-///////////////////////////////////////////////////////////////////////////////////
-int process_pe(char* filename,int file,void* p,int len)
-{
-
- PIMAGE_DOS_HEADER pDosHeader;
- PIMAGE_NT_HEADERS pNTHeaders;
-
- char* pStr;
- PSTAB_ENTRY pStab;
- DWORD nStabLen,nSym;
- char* pStrTab;
- char* pSymTab;
-
- char szSymName[2048];
- HANDLE fileout;
- int nSymStrLen,nStabStrLen;
- int iRetVal = 0;
-
- pDosHeader = (PIMAGE_DOS_HEADER)p;
- pNTHeaders = (PIMAGE_NT_HEADERS)((DWORD)p + pDosHeader->e_lfanew);
-
- if ((pDosHeader->e_magic == IMAGE_DOS_SIGNATURE)
- && (pDosHeader->e_lfanew != 0L)
- && (pNTHeaders->Signature == IMAGE_NT_SIGNATURE))
- {
- if( pNTHeaders->FileHeader.PointerToSymbolTable ){
-
- pSymTab = (char*)((DWORD)p + pNTHeaders->FileHeader.PointerToSymbolTable);
- nSym = pNTHeaders->FileHeader.NumberOfSymbols;
- //string table follows immediately after symbol table. first 4 bytes give the length
of the table
- //references to string table include the first 4 bytes.
- pStrTab = (char*)((PIMAGE_SYMBOL)pSymTab + nSym);
- nSymStrLen = *((DWORD*)pStrTab);
- find_stab_sections(p,IMAGE_FIRST_SECTION(pNTHeaders),pNTHeaders->FileHeader.NumberOfSections,
- &pStab,&nStabLen,&pStr,&nStabStrLen);
-
- if(pStab && nStabLen && pStr && nStabStrLen)
- {
- LPSTR pDot;
-
- strcpy(szSymName,filename);
- //printf("LOADER: file name = %s\n",szSymName);
- if((pDot = strchr(szSymName,'.')))
- {
- *pDot = 0;
- strcat(pDot,".dbg");
- }
- else
- {
- strcat(szSymName,".dbg");
- }
- //printf("LOADER: symbol file name = %s\n",szSymName);
- printf("LOADER: creating symbol file %s for
%s\n",szSymName,filename);
-
- fileout = CreateFile(szSymName,
- GENERIC_READ | GENERIC_WRITE,
- 0,
- NULL,
- CREATE_ALWAYS,
- 0,
- 0);
-
- if(fileout != INVALID_HANDLE_VALUE)
- {
- printf("NumberOfSections: %d, size: %d\n",
pNTHeaders->FileHeader.NumberOfSections,sizeof(IMAGE_SECTION_HEADER));
- process_stabs(szSymName,
- fileout,
- IMAGE_FIRST_SECTION(pNTHeaders),
- pNTHeaders->FileHeader.NumberOfSections*sizeof(IMAGE_SECTION_HEADER),
- p,
- pStab,
- nStabLen,
- pStr,
- nStabStrLen,
- (char*)pSymTab,
- nSym*sizeof(IMAGE_SYMBOL),
- pStrTab,
- nSymStrLen);
-
- CloseHandle(fileout);
- }
- else
- {
- printf("LOADER: creation of symbol file %s
failed\n",szSymName);
- iRetVal = 2;
- }
-
- }
- else
- {
- printf("LOADER: file %s has no data inside symbol
tables\n",filename);
- if( ulGlobalVerbose )
- {
- if( !pStab || !nStabLen )
- printf("LOADER: - symbol table is empty or not
present\n");
- if( !pStr || !nStabStrLen )
- printf("LOADER: - string table is empty or not
present\n");
- }
- iRetVal = 2;
- }
- }
- else{
- printf("LOADER: file %s does not have a symbol
table\n",filename);
- iRetVal = 2;
- }
- }
- else
- {
- printf("LOADER: file %s is not an ELF binary\n",filename);
- iRetVal = 1;
- }
-
- //printf("LOADER: leave process_pe()\n");
- return iRetVal;
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// process_file()
-//
-///////////////////////////////////////////////////////////////////////////////////
-int process_file(char* filename)
-{
- int file;
- void* p;
- off_t len;
- int iRetVal=0;
-
- //printf("LOADER: enter process_file()\n");
- file = _open(filename,O_RDONLY|_O_BINARY);
- if(file>0)
- {
- //printf("LOADER: opened %s as FD %x\n",filename,file);
-
- len = _lseek(file,0,SEEK_END);
- printf("LOADER: file %s is %u bytes\n",filename,(int)len);
-
- _lseek(file,0,SEEK_SET);
-
- p = malloc(len+16);
- if(p)
- {
- long count;
- //printf("LOADER: malloc'd @ %x\n",p);
- memset(p,0,len+16);
- if(len == (count = _read(file,p,len)))
- {
- //printf("LOADER: trying ELF format\n");
- iRetVal = process_pe(filename,file,p,len);
- }
- }
- _close(file);
- }
- else
- {
- printf("LOADER: file %s could not be opened\n",filename);
- iRetVal = 1;
- }
-
- //printf("LOADER: leave process_file()\n");
- return iRetVal;
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// open_debugger()
-//
-///////////////////////////////////////////////////////////////////////////////////
-HANDLE open_debugger(void)
-{
- debugger_file =
CreateFile("\\Device\\Pice",GENERIC_READ,0,NULL,OPEN_EXISTING,NULL,NULL);
- if(debugger_file == INVALID_HANDLE_VALUE)
- {
- printf("LOADER: debugger is not loaded. Last Error: %ld\n",
GetLastError());
- }
-
- return debugger_file;
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// close_debugger()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void close_debugger(void)
-{
- if( !CloseHandle(debugger_file) ){
- printf("Error closing debugger handle: %ld\n", GetLastError());
- }
-}
-
-int ioctl( HANDLE device, DWORD ioctrlcode, PDEBUGGER_STATUS_BLOCK psb)
-{
- DEBUGGER_STATUS_BLOCK tsb;
- DWORD bytesreturned;
- if( !DeviceIoControl( device, ioctrlcode, psb, sizeof(DEBUGGER_STATUS_BLOCK),
- &tsb, sizeof(DEBUGGER_STATUS_BLOCK),&bytesreturned, NULL) ){
- printf("Error in DeviceIoControl: %ld\n", GetLastError());
- return -EINVAL;
- }
- else{
- memcpy( psb, &tsb, sizeof(DEBUGGER_STATUS_BLOCK) );
- }
- return 0;
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// banner()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void banner(void)
-{
- printf("#########################################################\n");
- printf("#### Symbols LOADER/TRANSLATOR for PICE ####\n");
- printf("#########################################################\n");
-}
-
-#define ACTION_NONE 0
-#define ACTION_LOAD 1
-#define ACTION_UNLOAD 2
-#define ACTION_TRANS 3
-#define ACTION_RELOAD 4
-#define ACTION_INSTALL 5
-#define ACTION_UNINSTALL 6
-#define ACTION_STATUS 7
-#define ACTION_BREAK 8
-#define ACTION_TERMINAL 9
-
-///////////////////////////////////////////////////////////////////////////////////
-// change_symbols()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void change_symbols(int action,char* pfilename)
-{
- int iRetVal = 0;
- DEBUGGER_STATUS_BLOCK sb;
-
- strcpy(sb.filename, pfilename);
-
- switch(action)
- {
- case ACTION_LOAD:
- printf("LOADER: loading symbols from %s\n",pfilename);
- if(open_debugger() != INVALID_HANDLE_VALUE)
- {
- iRetVal = ioctl(debugger_file,PICE_IOCTL_LOAD,&sb);
- close_debugger();
- }
- break;
- case ACTION_UNLOAD:
- printf("LOADER: unloading symbols from %s\n",pfilename);
- if(open_debugger() != INVALID_HANDLE_VALUE)
- {
- iRetVal = ioctl(debugger_file,PICE_IOCTL_UNLOAD,&sb);
- close_debugger();
- }
- break;
- case ACTION_RELOAD:
- printf("LOADER: reloading all symbols\n");
- if(open_debugger() != INVALID_HANDLE_VALUE)
- {
- ioctl(debugger_file,PICE_IOCTL_RELOAD,NULL);
- close_debugger();
- printf("LOADER: reloading DONE!\n");
- }
- break;
- default :
- printf("LOADER: an internal error has occurred at
change_symbols\n");
- }
-
- switch( iRetVal )
- {
- case -EINVAL :
- printf("LOADER: debugger return value = -EINVAL, operation has failed\n");
- break;
- case 0 :
- // success - silently proceed
- break;
- default :
- printf("LOADER: debugger return value = %i, operation possibly
failed\n",iRetVal);
- }
-}
-
-// Dynamic install to be added later
-#if 0
-///////////////////////////////////////////////////////////////////////////////////
-// tryinstall()
-//
-///////////////////////////////////////////////////////////////////////////////////
-int tryinstall(void)
-{
- char *argv[]={"/sbin/insmod","pice.o",NULL};
- int err = 0;
- int pid,status;
-
- banner();
- printf("LOADER: trying to install debugger...\n");
-
- if( open_debugger() != INVALID_HANDLE_VALUE )
- {
- printf("LOADER: debugger already installed...\n");
- close_debugger();
- return 0;
- }
-
- // create a separate thread
- pid = fork();
- switch(pid)
- {
- case -1:
- // error when forking, i.e. out E_NOMEM
- err = errno;
- printf("LOADER: fork failed for execution of '%s' (errno =
%u).\n",argv[0],err);
- break;
- case 0:
- // child process handler
- execve(argv[0],argv,NULL);
- // returns only on error, with return value -1, errno is set
- printf("LOADER: couldn't execute '%s' (errno =
%u)\n",argv[0],errno);
- exit(255);
- break;
- default:
- // parent process handler
- printf("LOADER: waiting for debugger to load...\n");
- pid = waitpid(pid, &status, 0); // suspend until child is done
- if( (pid>0) && WIFEXITED(status) && (WEXITSTATUS(status)
== 0) )
- printf("LOADER: debugger loaded!\n");
- else if( pid<=0 )
- {
- printf("LOADER: Error on loading debugger! (waitpid() =
%i)\n",pid);
- err = -1;
- }
- else if( !WIFEXITED(status) )
- {
- printf("LOADER: Error on loading debugger! (ifexited =
%i)\n",WIFEXITED(status));
- err = -1;
- }
- else
- {
- printf("LOADER: Error on loading debugger! (exitstatus =
%u)\n",WEXITSTATUS(status));
- err = WEXITSTATUS(status);
- }
- break;
- }
-
- return err;
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// tryuninstall()
-//
-///////////////////////////////////////////////////////////////////////////////////
-int tryuninstall(void)
-{
- char *argv[]={"/sbin/rmmod","pice",NULL};
- int err = 0;
- int pid,status;
-
- banner();
- printf("LOADER: trying to remove debugger...\n");
-
- // check for loaded debugger
- if(open_debugger() == INVALID_HANDLE_VALUE)
- {
- return -1;
- }
- // don't to close, else we'll have a reference count != 0
- close_debugger();
-
- // create a separate thread
- pid = fork();
- switch(pid)
- {
- case -1:
- // error when forking, i.e. out E_NOMEM
- err = errno;
- printf("LOADER: fork failed for execution of '%s'
(errno=%u).\n",argv[0],err);
- break;
- case 0:
- // child process handler
- execve(argv[0],argv,NULL);
- // returns only on error, with return value -1, errno is set
- printf("LOADER: couldn't execute '%s' (errno =
%u)\n",argv[0],errno);
- exit(255);
- break;
- default:
- // parent process handler
- printf("LOADER: waiting for debugger to unload...\n");
- pid = waitpid(pid, &status, 0); // suspend until child is done
-
- if( (pid>0) && WIFEXITED(status) && (WEXITSTATUS(status)
== 0) )
- printf("LOADER: debugger removed!\n");
- else if( pid<=0 )
- {
- printf("LOADER: Error on removing debugger! (waitpid() =
%i)\n",pid);
- err = -1;
- }
- else if( !WIFEXITED(status) )
- {
- printf("LOADER: Error on removing debugger! (ifexited =
%i)\n",WIFEXITED(status));
- err = -1;
- }
- else
- {
- printf("LOADER: Error on removing debugger! (exitstatus =
%u)\n",WEXITSTATUS(status));
- err = WEXITSTATUS(status);
- }
- break;
- }
- return err;
-}
-#endif
-
-///////////////////////////////////////////////////////////////////////////////////
-// showstatus()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void showstatus(void)
-{
- DEBUGGER_STATUS_BLOCK sb;
- int iRetVal;
-
- if(open_debugger() != INVALID_HANDLE_VALUE)
- {
- iRetVal = ioctl(debugger_file,PICE_IOCTL_STATUS,&sb);
-
- //printf("LOADER: Test = %X\n",sb.Test);
- close_debugger();
- }
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// dobreak()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void dobreak(void)
-{
- int iRetVal;
-
- if(open_debugger() != INVALID_HANDLE_VALUE)
- {
- iRetVal = ioctl(debugger_file,PICE_IOCTL_BREAK,NULL);
- close_debugger();
- }
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// doterminal()
-//
-///////////////////////////////////////////////////////////////////////////////////
-#if 0
-void doterminal(void)
-{
- if(SetupSerial(2,B115200))
- {
- DebuggerShell();
- CloseSerial();
- }
-}
-#endif
-
-///////////////////////////////////////////////////////////////////////////////////
-// process_switches()
-//
-// returns !=0 in case of a commandline error
-//
-///////////////////////////////////////////////////////////////////////////////////
-int process_switches(int argc,char* argv[])
-{
- int i;
- char* parg,*pfilename = NULL;
- int action = ACTION_NONE;
- int error = 0;
-
- // parse commandline arguments
- for(i=1;i<argc;i++)
- {
- parg = argv[i];
- if(*parg == '-')
- {
- int new_action=ACTION_NONE;
-
- parg++;
- if(strcmp(parg,"load")==0 || strcmp(parg,"l")==0)
- {
- new_action = ACTION_LOAD;
- }
- else if(strcmp(parg,"unload")==0 || strcmp(parg,"u")==0)
- {
- new_action = ACTION_UNLOAD;
- }
- else if(strcmp(parg,"trans")==0 || strcmp(parg,"t")==0)
- {
- new_action = ACTION_TRANS;
- }
- else if(strcmp(parg,"reload")==0 || strcmp(parg,"r")==0)
- {
- new_action = ACTION_RELOAD;
- }
- else if(strcmp(parg,"verbose")==0 || strcmp(parg,"v")==0)
- {
- if( ulGlobalVerbose+1 > ulGlobalVerbose )
- ulGlobalVerbose++;
- }
- else if(strcmp(parg,"install")==0 || strcmp(parg,"i")==0)
- {
- new_action = ACTION_INSTALL;
- }
- else if(strcmp(parg,"uninstall")==0 || strcmp(parg,"x")==0)
- {
- new_action = ACTION_UNINSTALL;
- }
- else if(strcmp(parg,"status")==0 || strcmp(parg,"s")==0)
- {
- new_action = ACTION_STATUS;
- }
- else if(strcmp(parg,"break")==0 || strcmp(parg,"b")==0)
- {
- new_action = ACTION_BREAK;
- }
- else if(strcmp(parg,"serial")==0 || strcmp(parg,"ser")==0)
- {
- new_action = ACTION_TERMINAL;
- }
- else
- {
- printf("LOADER: error: unknown switch %s", argv[i]);
- error = 1;
- }
-
- if( new_action != ACTION_NONE )
- {
- if( action == ACTION_NONE )
- action = new_action;
- else
- if( action == new_action )
- {
- // identical, just ignore
- }
- else
- {
- printf("LOADER: error: conflicting switch %s", argv[i]);
- error = 1;
- }
- }
- }
- else
- {
- if( pfilename )
- {
- printf("LOADER: error: additional filename %s", parg);
- error = 1;
- }
- pfilename = parg;
- }
- }
-
- // check number of required parameters
- switch( action )
- {
- case ACTION_TRANS :
- case ACTION_LOAD :
- case ACTION_UNLOAD :
- if( !pfilename )
- {
- printf("LOADER: error: missing filename\n");
- error = 1;
- }
- break;
- case ACTION_RELOAD :
- /* filename parameter is optional */
- break;
-#if 0
- case ACTION_UNINSTALL:
- close_debugger();
- tryuninstall();
- break;
- case ACTION_INSTALL:
- tryinstall();
- break;
-#endif
- case ACTION_STATUS:
- showstatus();
- break;
- case ACTION_BREAK:
- dobreak();
- break;
-#if 0
- case ACTION_TERMINAL:
- doterminal();
- break;
-#endif
- case ACTION_NONE :
- printf("LOADER: no action specified specifed on commandline\n");
- error = 1;
-
- break;
- default :
- printf("LOADER: an internal error has occurred at commandline
parsing\n");
- error = 1;
- }
-
- if( !error ) // commandline was fine, now start processing
- {
- switch( action )
- {
- case ACTION_TRANS :
- printf("LOADER: trying to translate file %s...\n",pfilename);
- if( process_file(pfilename)==0 )
- printf("LOADER: file %s has been
translated\n",pfilename);
- else
- printf("LOADER: error while translating file
%s\n",pfilename);
- break;
- case ACTION_LOAD :
- case ACTION_UNLOAD :
- case ACTION_RELOAD :
- change_symbols(action,pfilename);
- break;
- }
- }
-
- return error;
-}
-
-
-///////////////////////////////////////////////////////////////////////////////////
-// showhelp()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void showhelp(void)
-{
- banner();
- printf("LOADER: Syntax:\n");
- printf("LOADER: loader [switches] [executable/object file
path]\n");
- printf("LOADER: Switches:\n");
- printf("LOADER: -trans (-t): translate from exe to
sym\n");
- printf("LOADER: -load (-l): load symbols\n");
- printf("LOADER: -unload (-u): unload symbols\n");
- printf("LOADER: -reload (-r): reload some/all symbols\n");
- printf("LOADER: -verbose (-v): be a bit more verbose\n");
- printf("LOADER: -install (-i): install pICE debugger\n");
- printf("LOADER: -uninstall (-x): uninstall pICE debugger\n");
- printf("LOADER: -break (-b): break into debugger\n");
- printf("LOADER: -serial (-ser): start serial line
terminal\n");
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// showpermission()
-//
-///////////////////////////////////////////////////////////////////////////////////
-void showpermission(void)
-{
- banner();
- printf("LOADER: You must be superuser!\n");
-}
-
-///////////////////////////////////////////////////////////////////////////////////
-// main()
-//
-///////////////////////////////////////////////////////////////////////////////////
-int main(int argc,char* argv[])
-{
- if(argc==1 || argc>3)
- {
- showhelp();
-
- return 1;
- }
-
- return process_switches(argc,argv);
-}
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/retypes.h
b/modules/rosapps/applications/sysutils/utils/pice/loader/retypes.h
deleted file mode 100644
index 7dceba3ffb7..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/retypes.h
+++ /dev/null
@@ -1,15 +0,0 @@
-typedef unsigned int ULONG,*PULONG;
-typedef unsigned short USHORT,*PUSHORT;
-typedef unsigned char UCHAR,*PUCHAR;
-
-typedef signed int LONG,*PLONG;
-typedef signed short SHORT,*PSHORT;
-typedef signed char CHAR,*PCHAR,*LPSTR,*PSTR;
-
-typedef void VOID,*PVOID;
-
-typedef char BOOLEAN,*PBOOLEAN;
-
-#define FALSE (0==1)
-#define TRUE (1==1)
-
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/stab.def
b/modules/rosapps/applications/sysutils/utils/pice/loader/stab.def
deleted file mode 100644
index 4d1b128b44d..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/stab.def
+++ /dev/null
@@ -1,264 +0,0 @@
-/* Table of DBX symbol codes for the GNU system.
- Copyright (C) 1988, 91, 92, 93, 94, 95, 1996 Free Software Foundation, Inc.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-/* New stab from Solaris 2. This uses an n_type of 0, which in a.out files
- overlaps the N_UNDF used for ordinary symbols. In ELF files, the
- debug information is in a different file section, so there is no conflict.
- This symbol's n_value gives the size of the string section associated
- with this file. The symbol's n_strx (relative to the just-updated
- string section start address) gives the name of the source file,
- e.g. "foo.c", without any path information. The symbol's n_desc gives
- the count of upcoming symbols associated with this file (not including
- this one). */
-__define_stab (N_UNDF, 0x00, "UNDF")
-
-/* Global variable. Only the name is significant.
- To find the address, look in the corresponding external symbol. */
-__define_stab (N_GSYM, 0x20, "GSYM")
-
-/* Function name for BSD Fortran. Only the name is significant.
- To find the address, look in the corresponding external symbol. */
-__define_stab (N_FNAME, 0x22, "FNAME")
-
-/* Function name or text-segment variable for C. Value is its address.
- Desc is supposedly starting line number, but GCC doesn't set it
- and DBX seems not to miss it. */
-__define_stab (N_FUN, 0x24, "FUN")
-
-/* Data-segment variable with internal linkage. Value is its address.
- "Static Sym". */
-__define_stab (N_STSYM, 0x26, "STSYM")
-
-/* BSS-segment variable with internal linkage. Value is its address. */
-__define_stab (N_LCSYM, 0x28, "LCSYM")
-
-/* Name of main routine. Only the name is significant. */
-__define_stab (N_MAIN, 0x2a, "MAIN")
-
-/* Solaris2: Read-only data symbols. */
-__define_stab (N_ROSYM, 0x2c, "ROSYM")
-
-/* Global symbol in Pascal.
- Supposedly the value is its line number; I'm skeptical. */
-__define_stab (N_PC, 0x30, "PC")
-
-/* Number of symbols: 0, files,,funcs,lines according to Ultrix V4.0. */
-__define_stab (N_NSYMS, 0x32, "NSYMS")
-
-/* "No DST map for sym: name, ,0,type,ignored" according to Ultrix V4.0. */
-__define_stab (N_NOMAP, 0x34, "NOMAP")
-
-/* New stab from Solaris 2. Like N_SO, but for the object file. Two in
- a row provide the build directory and the relative path of the .o from it.
- Solaris2 uses this to avoid putting the stabs info into the linked
- executable; this stab goes into the ".stab.index" section, and the
debugger
- reads the real stabs directly from the .o files instead. */
-__define_stab (N_OBJ, 0x38, "OBJ")
-
-/* New stab from Solaris 2. Options for the debugger, related to the
- source language for this module. E.g. whether to use ANSI
- integral promotions or traditional integral promotions. */
-__define_stab (N_OPT, 0x3c, "OPT")
-
-/* Register variable. Value is number of register. */
-__define_stab (N_RSYM, 0x40, "RSYM")
-
-/* Modula-2 compilation unit. Can someone say what info it contains? */
-__define_stab (N_M2C, 0x42, "M2C")
-
-/* Line number in text segment. Desc is the line number;
- value is corresponding address. On Solaris2, the line number is
- relative to the start of the current function. */
-__define_stab (N_SLINE, 0x44, "SLINE")
-
-/* Similar, for data segment. */
-__define_stab (N_DSLINE, 0x46, "DSLINE")
-
-/* Similar, for bss segment. */
-__define_stab (N_BSLINE, 0x48, "BSLINE")
-
-/* Sun's source-code browser stabs. ?? Don't know what the fields are.
- Supposedly the field is "path to associated .cb file". THIS VALUE
- OVERLAPS WITH N_BSLINE! */
-__define_stab_duplicate (N_BROWS, 0x48, "BROWS")
-
-/* GNU Modula-2 definition module dependency. Value is the modification time
- of the definition file. Other is non-zero if it is imported with the
- GNU M2 keyword %INITIALIZE. Perhaps N_M2C can be used if there
- are enough empty fields? */
-__define_stab(N_DEFD, 0x4a, "DEFD")
-
-/* New in Solaris2. Function start/body/end line numbers. */
-__define_stab(N_FLINE, 0x4C, "FLINE")
-
-/* THE FOLLOWING TWO STAB VALUES CONFLICT. Happily, one is for Modula-2
- and one is for C++. Still,... */
-/* GNU C++ exception variable. Name is variable name. */
-__define_stab (N_EHDECL, 0x50, "EHDECL")
-/* Modula2 info "for imc": name,,0,0,0 according to Ultrix V4.0. */
-__define_stab_duplicate (N_MOD2, 0x50, "MOD2")
-
-/* GNU C++ `catch' clause. Value is its address. Desc is nonzero if
- this entry is immediately followed by a CAUGHT stab saying what exception
- was caught. Multiple CAUGHT stabs means that multiple exceptions
- can be caught here. If Desc is 0, it means all exceptions are caught
- here. */
-__define_stab (N_CATCH, 0x54, "CATCH")
-
-/* Structure or union element. Value is offset in the structure. */
-__define_stab (N_SSYM, 0x60, "SSYM")
-
-/* Solaris2: Last stab emitted for module. */
-__define_stab (N_ENDM, 0x62, "ENDM")
-
-/* Name of main source file.
- Value is starting text address of the compilation.
- If multiple N_SO's appear, the first to contain a trailing / is the
- compilation directory. The first to not contain a trailing / is the
- source file name, relative to the compilation directory. Others (perhaps
- resulting from cfront) are ignored.
- On Solaris2, value is undefined, but desc is a source-language code. */
-
-__define_stab (N_SO, 0x64, "SO")
-
-/* Automatic variable in the stack. Value is offset from frame pointer.
- Also used for type descriptions. */
-__define_stab (N_LSYM, 0x80, "LSYM")
-
-/* Beginning of an include file. Only Sun uses this.
- In an object file, only the name is significant.
- The Sun linker puts data into some of the other fields. */
-__define_stab (N_BINCL, 0x82, "BINCL")
-
-/* Name of sub-source file (#include file).
- Value is starting text address of the compilation. */
-__define_stab (N_SOL, 0x84, "SOL")
-
-/* Parameter variable. Value is offset from argument pointer.
- (On most machines the argument pointer is the same as the frame pointer. */
-__define_stab (N_PSYM, 0xa0, "PSYM")
-
-/* End of an include file. No name.
- This and N_BINCL act as brackets around the file's output.
- In an object file, there is no significant data in this entry.
- The Sun linker puts data into some of the fields. */
-__define_stab (N_EINCL, 0xa2, "EINCL")
-
-/* Alternate entry point. Value is its address. */
-__define_stab (N_ENTRY, 0xa4, "ENTRY")
-
-/* Beginning of lexical block.
- The desc is the nesting level in lexical blocks.
- The value is the address of the start of the text for the block.
- The variables declared inside the block *precede* the N_LBRAC symbol.
- On Solaris2, the value is relative to the start of the current function. */
-__define_stab (N_LBRAC, 0xc0, "LBRAC")
-
-/* Place holder for deleted include file. Replaces a N_BINCL and everything
- up to the corresponding N_EINCL. The Sun linker generates these when
- it finds multiple identical copies of the symbols from an include file.
- This appears only in output from the Sun linker. */
-__define_stab (N_EXCL, 0xc2, "EXCL")
-
-/* Modula-2 scope information. Can someone say what info it contains? */
-__define_stab (N_SCOPE, 0xc4, "SCOPE")
-
-/* End of a lexical block. Desc matches the N_LBRAC's desc.
- The value is the address of the end of the text for the block.
- On Solaris2, the value is relative to the start of the current function. */
-__define_stab (N_RBRAC, 0xe0, "RBRAC")
-
-/* Begin named common block. Only the name is significant. */
-__define_stab (N_BCOMM, 0xe2, "BCOMM")
-
-/* End named common block. Only the name is significant
- (and it should match the N_BCOMM). */
-__define_stab (N_ECOMM, 0xe4, "ECOMM")
-
-/* Member of a common block; value is offset within the common block.
- This should occur within a BCOMM/ECOMM pair. */
-__define_stab (N_ECOML, 0xe8, "ECOML")
-
-/* Solaris2: Pascal "with" statement: type,,0,0,offset */
-__define_stab (N_WITH, 0xea, "WITH")
-
-/* These STAB's are used on Gould systems for Non-Base register symbols
- or something like that. FIXME. I have assigned the values at random
- since I don't have a Gould here. Fixups from Gould folk welcome... */
-__define_stab (N_NBTEXT, 0xF0, "NBTEXT")
-__define_stab (N_NBDATA, 0xF2, "NBDATA")
-__define_stab (N_NBBSS, 0xF4, "NBBSS")
-__define_stab (N_NBSTS, 0xF6, "NBSTS")
-__define_stab (N_NBLCS, 0xF8, "NBLCS")
-
-/* Second symbol entry containing a length-value for the preceding entry.
- The value is the length. */
-__define_stab (N_LENG, 0xfe, "LENG")
-
-/* The above information, in matrix format.
-
- STAB MATRIX
- _________________________________________________
- | 00 - 1F are not dbx stab symbols |
- | In most cases, the low bit is the EXTernal bit|
-
- | 00 UNDEF | 02 ABS | 04 TEXT | 06 DATA |
- | 01 |EXT | 03 |EXT | 05 |EXT | 07 |EXT |
-
- | 08 BSS | 0A INDR | 0C FN_SEQ | 0E WEAKA |
- | 09 |EXT | 0B | 0D WEAKU | 0F WEAKT |
-
- | 10 WEAKD | 12 COMM | 14 SETA | 16 SETT |
- | 11 WEAKB | 13 | 15 | 17 |
-
- | 18 SETD | 1A SETB | 1C SETV | 1E WARNING|
- | 19 | 1B | 1D | 1F FN |
-
- |_______________________________________________|
- | Debug entries with bit 01 set are unused. |
- | 20 GSYM | 22 FNAME | 24 FUN | 26 STSYM |
- | 28 LCSYM | 2A MAIN | 2C ROSYM | 2E |
- | 30 PC | 32 NSYMS | 34 NOMAP | 36 |
- | 38 OBJ | 3A | 3C OPT | 3E |
- | 40 RSYM | 42 M2C | 44 SLINE | 46 DSLINE |
- | 48 BSLINE*| 4A DEFD | 4C FLINE | 4E |
- | 50 EHDECL*| 52 | 54 CATCH | 56 |
- | 58 | 5A | 5C | 5E |
- | 60 SSYM | 62 ENDM | 64 SO | 66 |
- | 68 | 6A | 6C | 6E |
- | 70 | 72 | 74 | 76 |
- | 78 | 7A | 7C | 7E |
- | 80 LSYM | 82 BINCL | 84 SOL | 86 |
- | 88 | 8A | 8C | 8E |
- | 90 | 92 | 94 | 96 |
- | 98 | 9A | 9C | 9E |
- | A0 PSYM | A2 EINCL | A4 ENTRY | A6 |
- | A8 | AA | AC | AE |
- | B0 | B2 | B4 | B6 |
- | B8 | BA | BC | BE |
- | C0 LBRAC | C2 EXCL | C4 SCOPE | C6 |
- | C8 | CA | CC | CE |
- | D0 | D2 | D4 | D6 |
- | D8 | DA | DC | DE |
- | E0 RBRAC | E2 BCOMM | E4 ECOMM | E6 |
- | E8 ECOML | EA WITH | EC | EE |
- | F0 | F2 | F4 | F6 |
- | F8 | FA | FC | FE LENG |
- +-----------------------------------------------+
- * 50 EHDECL is also MOD2.
- * 48 BSLINE is also BROWS.
- */
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/stab_gnu.h
b/modules/rosapps/applications/sysutils/utils/pice/loader/stab_gnu.h
deleted file mode 100644
index e73eb990dd0..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/stab_gnu.h
+++ /dev/null
@@ -1,37 +0,0 @@
-#ifndef __GNU_STAB__
-
-/* Indicate the GNU stab.h is in use. */
-
-#define __GNU_STAB__
-
-#define __define_stab(NAME, CODE, STRING) NAME=CODE,
-#define __define_stab_duplicate(NAME, CODE, STRING) NAME=CODE,
-
-enum __stab_debug_code
-{
-#include "stab.def"
-LAST_UNUSED_STAB_CODE
-};
-
-#undef __define_stab
-
-/* Definitions of "desc" field for N_SO stabs in Solaris2. */
-
-#define N_SO_AS 1
-#define N_SO_C 2
-#define N_SO_ANSI_C 3
-#define N_SO_CC 4 /* C++ */
-#define N_SO_FORTRAN 5
-#define N_SO_PASCAL 6
-
-/* Solaris2: Floating point type values in basic types. */
-
-#define NF_NONE 0
-#define NF_SINGLE 1 /* IEEE 32-bit */
-#define NF_DOUBLE 2 /* IEEE 64-bit */
-#define NF_COMPLEX 3 /* Fortran complex */
-#define NF_COMPLEX16 4 /* Fortran double complex */
-#define NF_COMPLEX32 5 /* Fortran complex*16 */
-#define NF_LDOUBLE 6 /* Long double (whatever that is) */
-
-#endif /* __GNU_STAB_ */
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/stdinc.h
b/modules/rosapps/applications/sysutils/utils/pice/loader/stdinc.h
deleted file mode 100644
index 06cdefe760f..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/stdinc.h
+++ /dev/null
@@ -1,28 +0,0 @@
-#include <stdio.h>
-#include <string.h>
-#include <malloc.h>
-#include <io.h>
-
-//#include <winnt.h>
-#include <windows.h>
-#include <kefuncs.h>
-
-//#include <winnt.h>
-#include <sys/types.h>
-//#include <sys/wait.h>
-//#include <sys/ioctl.h>
-//#include <sys/signal.h>
-#include <sys/stat.h>
-#include <errno.h>
-#include <fcntl.h>
-//#include <unistd.h>
-//#include <linux/unistd.h>
-
-#include "../../../../include/pe.h"
-#include "stab_gnu.h"
-//#include "retypes.h"
-//#include "terminal.h"
-//#include <termios.h>
-#include "../shared/shared.h"
-
-
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.c
b/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.c
deleted file mode 100644
index 2776451bf16..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.c
+++ /dev/null
@@ -1,430 +0,0 @@
-/*++
-
-Copyright (c) 1998-2001 Klaus P. Gerlicher
-
-Module Name:
-
- term�nal.c
-
-Abstract:
-
- serial terminal for pICE headless mode
-
-Environment:
-
- User mode only
-
-Author:
-
- Klaus P. Gerlicher
-
-Revision History:
-
- 23-Jan-2001: created
-
-Copyright notice:
-
- This file may be distributed under the terms of the GNU Public License.
-
---*/
-#if 0 //ei not ready
-#include "stdinc.h"
-#include <curses.h>
-
-
-#define CONSOLE_WIDTH (80)
-#define CONSOLE_HEIGHT (25)
-
-USHORT major_version=0xFFFF,minor_version=0xFFFF,build_number=0xFFFF;
-
-USHORT g_attr = 0;
-
-USHORT usCurX,usCurY,xSize,ySize;
-
-USHORT foreground_color_map[]=
-{
-};
-
-USHORT background_color_map[]=
-{
-};
-
-
-int fd_comm;
-struct termios oldtio;
-
-//************************************************************************
-// CheckSum()
-//
-//************************************************************************
-UCHAR CheckSum(LPSTR p,ULONG Len)
-{
- UCHAR ucCheckSum = 0;
- ULONG i;
- for(i=0;i<Len;i++)
- {
- ucCheckSum ^= *p++;
- ucCheckSum += 1;
- }
-
- return ucCheckSum;
-}
-
-///************************************************************************
-// ReadByte()
-//
-///************************************************************************
-BOOLEAN ReadByte(PUCHAR pc)
-{
- return (read(fd_comm,pc,1) > 0);
-}
-
-///************************************************************************
-// SendByte()
-//
-///************************************************************************
-BOOLEAN SendByte(UCHAR c)
-{
- return (write(fd_comm,&c,1) > 0);
-}
-
-
-///************************************************************************
-// ReadPacket()
-//
-///************************************************************************
-PSERIAL_PACKET ReadPacket(void)
-{
- ULONG i;
- PSERIAL_PACKET p;
- SERIAL_PACKET_HEADER header;
- PUCHAR pHeaderRaw,pData;
- char temp[256];
- ULONG ulCheckSum;
-
- // read a packet header
- pHeaderRaw = (PUCHAR)&header;
- for(i=0;i<sizeof(SERIAL_PACKET_HEADER);i++)
- {
-// //printf("reading()\n");
- if(! ReadByte(pHeaderRaw))
- {
- // //printf("no header byte read!\n");
- return NULL;
- }
-
- pHeaderRaw++;
- }
-
- //printf("received header!\n");
-
- ulCheckSum = header.packet_header_chksum;
- header.packet_header_chksum = 0;
-
- if(ulCheckSum != CheckSum((PUCHAR)&header,sizeof(SERIAL_PACKET_HEADER)) )
- {
- //printf("header checksum mismatch!\n");
- tcflush(fd_comm, TCIFLUSH);
- return NULL;
- }
-
- p = malloc(sizeof(SERIAL_PACKET_HEADER) + header.packet_size);
- if(!p)
- {
- //printf("out of memory!\n");
- return NULL;
- }
- PICE_memcpy(p,&header,sizeof(SERIAL_PACKET_HEADER));
-
- sprintf(temp,"size %X chksum
%x\n",header.packet_size,header.packet_chksum);
- //printf(temp);
-
- // read the attached data
- pData = (PUCHAR)p + sizeof(header);
- for(i=0;i<header.packet_size;i++)
- {
- if(! ReadByte(pData))
- {
- //printf("no data byte read!\n");
- return NULL;
- }
-
- pData++;
- }
-
- //printf("received data!\n");
-
- pData = (PUCHAR)p + sizeof(header);
- if(header.packet_chksum != CheckSum(pData,header.packet_size))
- {
- free(p);
- p = NULL;
- //printf("data checksum mismatch!\n");
- return NULL;
- }
-
- while(!SendByte(ACK));
-
- return p;
-}
-
-///************************************************************************
-// SendPacket()
-//
-///************************************************************************
-BOOLEAN SendPacket(PSERIAL_PACKET p)
-{
- return TRUE;
-}
-
-void DeletePacket(PSERIAL_PACKET p)
-{
- free(p);
-}
-
-//************************************************************************
-// SetupSerial()
-//
-//************************************************************************
-BOOLEAN SetupSerial(ULONG port,ULONG baudrate)
-{
- struct termios newtio;
- char*
ports[]={"/dev/ttyS0","/dev/ttyS1","/dev/ttyS2","/dev/ttyS3"};
-
- /*
- Open modem device for reading and writing and not as controlling tty
- because we don't want to get killed if linenoise sends CTRL-C.
- */
- //printf("opening comm %s\n",ports[port-1]);
- fd_comm = open(ports[port-1], O_RDWR | O_NOCTTY);
- if (fd_comm <0)
- {
- perror(ports[port-1]);
- exit(-1);
- }
-
- //printf("tcgetattr()\n");
- tcgetattr(fd_comm,&oldtio); /* save current modem settings */
-
- /*
- Set bps rate and hardware flow control and 8n1 (8bit,no
parity,1 stopbit).
- Also don't hangup automatically and ignore modem status.
- Finally enable receiving characters.
- */
- newtio.c_cflag = baudrate | CS8 | CLOCAL | CREAD;
-
- /*
- Ignore bytes with parity errors and make terminal raw and dumb.
- */
- newtio.c_iflag = IGNPAR;
-
- /*
- Raw output.
- */
- newtio.c_oflag = 0;
-
- /*
- Don't echo characters because if you connect to a host it or your
- modem will echo characters for you. Don't generate signals.
- */
- newtio.c_lflag = 0;
-
- /* blocking read until 1 char arrives */
- newtio.c_cc[VMIN]=0;
- newtio.c_cc[VTIME]=0;
-
- /* now clean the modem line and activate the settings for modem */
- //printf("tcflush()\n");
- tcflush(fd_comm, TCIFLUSH);
- //printf("tcsetattr()\n");
- tcsetattr(fd_comm,TCSANOW,&newtio);
-
- // NCURSES
- initscr();
- refresh();
-
- return TRUE;
-}
-
-//************************************************************************
-// CloseSerial()
-//
-//************************************************************************
-void CloseSerial(void)
-{
- // NCURSES
- endwin();
-
- tcsetattr(fd_comm,TCSANOW,&oldtio); /* save current modem settings */
- close(fd_comm);
-}
-
-//************************************************************************
-// ClrLine()
-//
-//************************************************************************
-void ClrLine(UCHAR line)
-{
- move(line,0);
-}
-
-//************************************************************************
-// InvertLine()
-//
-//************************************************************************
-void InvertLine(UCHAR line)
-{
- move(line,0);
-}
-
-//************************************************************************
-// SetCursorPosition()
-//
-//************************************************************************
-void SetCursorPosition(USHORT x, USHORT y)
-{
- move(y,x);
-}
-
-//************************************************************************
-// GetCursorPosition()
-//
-//************************************************************************
-void GetCursorPosition(PUSHORT px,PUSHORT py)
-{
-}
-
-//************************************************************************
-// SetCursorState()
-//
-//************************************************************************
-void SetCursorState(UCHAR c)
-{
-}
-
-
-//************************************************************************
-// Print()
-//
-//************************************************************************
-void Print(LPSTR p,USHORT x,USHORT y)
-{
- // save the cursor pos
- GetCursorPosition(&usCurX,&usCurY);
-
- if(y<25)
- {
- SetCursorPosition(x,y);
- refresh();
-
- addstr(p);
- refresh();
- SetCursorPosition(usCurX,usCurY);
- }
-}
-
-//************************************************************************
-// ProcessPacket()
-//
-//************************************************************************
-void ProcessPacket(PSERIAL_PACKET p)
-{
- ULONG ulSize;
- PSERIAL_DATA_PACKET pData;
-
- pData = (PSERIAL_DATA_PACKET)((PUCHAR)p + sizeof(SERIAL_PACKET_HEADER));
- ulSize = p->header.packet_size;
-
- switch(pData->type)
- {
- case PACKET_TYPE_CONNECT:
- {
- PSERIAL_DATA_PACKET_CONNECT pDataConnect =
(PSERIAL_DATA_PACKET_CONNECT)pData;
- UCHAR i;
-
- for(i=0;i<ySize;i++)
- ClrLine(i);
-
- SetCursorState(0);
- SetCursorPosition(0,0);
-//
ResizeConsole(hConsole,pDataConnect->xsize,pDataConnect->ysize);
- xSize = pDataConnect->xsize;
- ySize = pDataConnect->ysize;
- }
- break;
- case PACKET_TYPE_CLRLINE:
- {
- PSERIAL_DATA_PACKET_CLRLINE pDataClrLine =
(PSERIAL_DATA_PACKET_CLRLINE)pData;
-
- ClrLine(pDataClrLine->line);
- }
- break;
- case PACKET_TYPE_INVERTLINE:
- {
- PSERIAL_DATA_PACKET_INVERTLINE pDataInvertLine =
(PSERIAL_DATA_PACKET_INVERTLINE)pData;
-
- InvertLine(pDataInvertLine->line);
- }
- break;
- case PACKET_TYPE_PRINT:
- {
- PSERIAL_DATA_PACKET_PRINT pDataPrint =
(PSERIAL_DATA_PACKET_PRINT)pData;
-
- Print(pDataPrint->string,pDataPrint->x,pDataPrint->y);
- }
- break;
- case PACKET_TYPE_CURSOR:
- {
- PSERIAL_DATA_PACKET_CURSOR pDataCursor =
(PSERIAL_DATA_PACKET_CURSOR)pData;
-
- SetCursorPosition(pDataCursor->x,pDataCursor->y);
- SetCursorState(pDataCursor->state);
- }
- break;
- case PACKET_TYPE_POLL:
- {
- PSERIAL_DATA_PACKET_POLL pDataPoll= (PSERIAL_DATA_PACKET_POLL)pData;
-
- if( (major_version != pDataPoll->major_version) ||
- (minor_version != pDataPoll->minor_version) ||
- (build_number != pDataPoll->build_number) )
- {
- major_version = pDataPoll->major_version;
- minor_version = pDataPoll->minor_version;
- build_number = pDataPoll->build_number;
-
-// SetAppTitle();
- }
-
- }
- break;
- default:
- //printf("UNHANDLED\n");
- break;
- }
-}
-
-//************************************************************************
-// DebuggerShell()
-//
-//************************************************************************
-void DebuggerShell(void)
-{
- PSERIAL_PACKET p;
-
- //printf("DebuggerShell()\n");
- for(;;)
- {
- p = ReadPacket();
- if(p)
- {
- ProcessPacket(p);
- DeletePacket(p);
- }
- else
- {
- usleep(100*1000);
- }
- }
-}
-#endif
diff --git a/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.h
b/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.h
deleted file mode 100644
index b34991560e1..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/loader/terminal.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*++
-
-Copyright (c) 1998-2001 Klaus P. Gerlicher
-
-Module Name:
-
- term�nal.h
-
-Abstract:
-
- HEADER for terminal.c
-
-Environment:
-
- User mode only
-
-Author:
-
- Klaus P. Gerlicher
-
-Revision History:
-
- 23-Jan-2001: created
-
-Copyright notice:
-
- This file may be distributed under the terms of the GNU Public License.
-
---*/
-BOOLEAN SetupSerial(ULONG port,ULONG baudrate);
-void CloseSerial(void);
-
-
-void DebuggerShell(void);
diff --git a/modules/rosapps/applications/sysutils/utils/pice/module/animation.h
b/modules/rosapps/applications/sysutils/utils/pice/module/animation.h
deleted file mode 100644
index 6b5212fa5fc..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/module/animation.h
+++ /dev/null
@@ -1,2116 +0,0 @@
-// this file is dynamically generated: DON'T TOUCH
-
-UCHAR cAnimation[192*11]={
-0x00, // 1
-0x00, // 2
-0x00, // 3
-0x00, // 4
-0x00, // 5
-0x00, // 6
-0x00, // 7
-0x00, // 8
-0x00, // 9
-0x00, // 10
-0x00, // 11
-0x00, // 12
-0x00, // 13
-0x00, // 14
-0x00, // 15
-0x00, // 16
-0x00, // 17
-0x00, // 18
-0x00, // 19
-0x00, // 20
-0x00, // 21
-0x00, // 22
-0x00, // 23
-0x00, // 24
-0x00, // 25
-0x00, // 26
-0x00, // 27
-0x00, // 28
-0x00, // 29
-0x00, // 30
-0x00, // 31
-0x00, // 32
-0x00, // 33
-0x00, // 34
-0x00, // 35
-0x00, // 36
-0x00, // 37
-0x00, // 38
-0x00, // 39
-0x00, // 40
-0x00, // 41
-0x00, // 42
-0x00, // 43
-0x00, // 44
-0x00, // 45
-0x00, // 46
-0x00, // 47
-0x00, // 48
-0x00, // 49
-0x00, // 50
-0x00, // 51
-0x00, // 52
-0x00, // 53
-0x00, // 54
-0x00, // 55
-0x00, // 56
-0x00, // 57
-0x00, // 58
-0x00, // 59
-0x00, // 60
-0x00, // 61
-0x00, // 62
-0x00, // 63
-0x00, // 64
-0x00, // 65
-0x00, // 66
-0x00, // 67
-0x80, // 68
-0x00, // 69
-0x00, // 70
-0x00, // 71
-0x00, // 72
-0x00, // 73
-0x00, // 74
-0x00, // 75
-0xc0, // 76
-0x00, // 77
-0x00, // 78
-0x00, // 79
-0x00, // 80
-0x00, // 81
-0x00, // 82
-0x03, // 83
-0x60, // 84
-0x00, // 85
-0x00, // 86
-0x00, // 87
-0x00, // 88
-0x00, // 89
-0x00, // 90
-0x01, // 91
-0xb8, // 92
-0x00, // 93
-0x00, // 94
-0x00, // 95
-0x00, // 96
-0x00, // 97
-0x00, // 98
-0x00, // 99
-0xfe, // 100
-0x00, // 101
-0x00, // 102
-0x00, // 103
-0x00, // 104
-0x00, // 105
-0x00, // 106
-0x00, // 107
-0x42, // 108
-0x00, // 109
-0x00, // 110
-0x00, // 111
-0x00, // 112
-0x00, // 113
-0x00, // 114
-0x00, // 115
-0x43, // 116
-0x80, // 117
-0x00, // 118
-0x00, // 119
-0x00, // 120
-0x00, // 121
-0x00, // 122
-0x00, // 123
-0x76, // 124
-0xc0, // 125
-0x00, // 126
-0x00, // 127
-0x00, // 128
-0x00, // 129
-0x00, // 130
-0x02, // 131
-0x3c, // 132
-0x60, // 133
-0x00, // 134
-0x00, // 135
-0x00, // 136
-0x00, // 137
-0x00, // 138
-0x03, // 139
-0xf0, // 140
-0x20, // 141
-0x00, // 142
-0x00, // 143
-0x00, // 144
-0x00, // 145
-0x00, // 146
-0x00, // 147
-0x10, // 148
-0x20, // 149
-0x00, // 150
-0x00, // 151
-0x00, // 152
-0x00, // 153
-0x00, // 154
-0x00, // 155
-0xf8, // 156
-0x20, // 157
-0x00, // 158
-0x00, // 159
-0x00, // 160
-0x00, // 161
-0x00, // 162
-0x00, // 163
-0x1c, // 164
-0x20, // 165
-0x00, // 166
-0x00, // 167
-0x00, // 168
-0x00, // 169
-0x00, // 170
-0x00, // 171
-0x07, // 172
-0xe0, // 173
-0x00, // 174
-0x00, // 175
-0x00, // 176
-0x00, // 177
-0x00, // 178
-0x00, // 179
-0x01, // 180
-0x80, // 181
-0x00, // 182
-0x00, // 183
-0x00, // 184
-0x00, // 185
-0x00, // 186
-0x00, // 187
-0x07, // 188
-0x80, // 189
-0x00, // 190
-0x00, // 191
-0x00, // 192
-0x00, // 2
-0x00, // 4
-0x00, // 6
-0x00, // 8
-0x00, // 10
-0x00, // 12
-0x00, // 14
-0x00, // 16
-0x00, // 18
-0x00, // 20
-0x00, // 22
-0x00, // 24
-0x00, // 26
-0x00, // 28
-0x00, // 30
-0x00, // 32
-0x00, // 34
-0x00, // 36
-0x00, // 38
-0x00, // 40
-0x00, // 42
-0x00, // 44
-0x00, // 46
-0x00, // 48
-0x00, // 50
-0x00, // 52
-0x00, // 54
-0x00, // 56
-0x00, // 58
-0x00, // 60
-0x00, // 62
-0x00, // 64
-0x00, // 66
-0x00, // 68
-0x00, // 70
-0x00, // 72
-0x00, // 74
-0x00, // 76
-0x00, // 78
-0x00, // 80
-0x00, // 82
-0x00, // 84
-0x00, // 86
-0x00, // 88
-0x00, // 90
-0x00, // 92
-0x00, // 94
-0x00, // 96
-0x00, // 98
-0x00, // 100
-0x00, // 102
-0x00, // 104
-0x00, // 106
-0x00, // 108
-0x00, // 110
-0x00, // 112
-0x00, // 114
-0x00, // 116
-0x00, // 118
-0x00, // 120
-0x00, // 122
-0x00, // 124
-0x00, // 126
-0x00, // 128
-0x00, // 130
-0x00, // 132
-0x01, // 134
-0x10, // 136
-0x00, // 138
-0x00, // 140
-0x00, // 142
-0x00, // 144
-0x00, // 146
-0x00, // 148
-0x01, // 150
-0x90, // 152
-0x00, // 154
-0x00, // 156
-0x00, // 158
-0x00, // 160
-0x00, // 162
-0x00, // 164
-0x00, // 166
-0x90, // 168
-0x00, // 170
-0x00, // 172
-0x00, // 174
-0x00, // 176
-0x00, // 178
-0x00, // 180
-0x00, // 182
-0x90, // 184
-0x00, // 186
-0x00, // 188
-0x00, // 190
-0x00, // 192
-0x00, // 194
-0x00, // 196
-0x00, // 198
-0xfe, // 200
-0x00, // 202
-0x00, // 204
-0x00, // 206
-0x00, // 208
-0x00, // 210
-0x00, // 212
-0x00, // 214
-0x42, // 216
-0x40, // 218
-0x00, // 220
-0x00, // 222
-0x00, // 224
-0x00, // 226
-0x00, // 228
-0x00, // 230
-0x43, // 232
-0xc0, // 234
-0x00, // 236
-0x00, // 238
-0x00, // 240
-0x00, // 242
-0x00, // 244
-0x00, // 246
-0x76, // 248
-0xc8, // 250
-0x00, // 252
-0x00, // 254
-0x00, // 256
-0x00, // 258
-0x00, // 260
-0x00, // 262
-0x3c, // 264
-0x78, // 266
-0x00, // 268
-0x00, // 270
-0x00, // 272
-0x00, // 274
-0x00, // 276
-0x01, // 278
-0xf0, // 280
-0x20, // 282
-0x00, // 284
-0x00, // 286
-0x00, // 288
-0x00, // 290
-0x00, // 292
-0x00, // 294
-0x10, // 296
-0x20, // 298
-0x00, // 300
-0x00, // 302
-0x00, // 304
-0x00, // 306
-0x00, // 308
-0x01, // 310
-0xf8, // 312
-0x20, // 314
-0x00, // 316
-0x00, // 318
-0x00, // 320
-0x00, // 322
-0x00, // 324
-0x03, // 326
-0x1c, // 328
-0x20, // 330
-0x00, // 332
-0x00, // 334
-0x00, // 336
-0x00, // 338
-0x00, // 340
-0x00, // 342
-0x07, // 344
-0xe0, // 346
-0x00, // 348
-0x00, // 350
-0x00, // 352
-0x00, // 354
-0x00, // 356
-0x00, // 358
-0x01, // 360
-0x80, // 362
-0x00, // 364
-0x00, // 366
-0x00, // 368
-0x00, // 370
-0x00, // 372
-0x00, // 374
-0x07, // 376
-0x80, // 378
-0x00, // 380
-0x00, // 382
-0x00, // 384
-0x00, // 3
-0x00, // 6
-0x00, // 9
-0x00, // 12
-0x00, // 15
-0x00, // 18
-0x00, // 21
-0x00, // 24
-0x00, // 27
-0x00, // 30
-0x00, // 33
-0x00, // 36
-0x00, // 39
-0x00, // 42
-0x00, // 45
-0x00, // 48
-0x00, // 51
-0x00, // 54
-0x00, // 57
-0x00, // 60
-0x00, // 63
-0x00, // 66
-0x00, // 69
-0x00, // 72
-0x00, // 75
-0x00, // 78
-0x00, // 81
-0x00, // 84
-0x00, // 87
-0x00, // 90
-0x00, // 93
-0x00, // 96
-0x00, // 99
-0x00, // 102
-0x00, // 105
-0x00, // 108
-0x00, // 111
-0x00, // 114
-0x00, // 117
-0x00, // 120
-0x00, // 123
-0x00, // 126
-0x00, // 129
-0x00, // 132
-0x00, // 135
-0x00, // 138
-0x00, // 141
-0x00, // 144
-0x00, // 147
-0x00, // 150
-0x00, // 153
-0x00, // 156
-0x00, // 159
-0x00, // 162
-0x00, // 165
-0x00, // 168
-0x00, // 171
-0x00, // 174
-0x00, // 177
-0x08, // 180
-0x00, // 183
-0x00, // 186
-0x00, // 189
-0x00, // 192
-0x00, // 195
-0x00, // 198
-0x00, // 201
-0x08, // 204
-0x00, // 207
-0x00, // 210
-0x00, // 213
-0x00, // 216
-0x00, // 219
-0x00, // 222
-0x00, // 225
-0x88, // 228
-0x00, // 231
-0x00, // 234
-0x00, // 237
-0x00, // 240
-0x00, // 243
-0x00, // 246
-0x00, // 249
-0x88, // 252
-0x00, // 255
-0x00, // 258
-0x00, // 261
-0x00, // 264
-0x00, // 267
-0x00, // 270
-0x00, // 273
-0x8e, // 276
-0x00, // 279
-0x00, // 282
-0x00, // 285
-0x00, // 288
-0x00, // 291
-0x00, // 294
-0x00, // 297
-0xdb, // 300
-0x00, // 303
-0x00, // 306
-0x00, // 309
-0x00, // 312
-0x00, // 315
-0x00, // 318
-0x00, // 321
-0x71, // 324
-0x10, // 327
-0x00, // 330
-0x00, // 333
-0x00, // 336
-0x00, // 339
-0x00, // 342
-0x00, // 345
-0x23, // 348
-0xb0, // 351
-0x00, // 354
-0x00, // 357
-0x00, // 360
-0x00, // 363
-0x00, // 366
-0x00, // 369
-0x36, // 372
-0xc0, // 375
-0x00, // 378
-0x00, // 381
-0x00, // 384
-0x00, // 387
-0x00, // 390
-0x00, // 393
-0x3c, // 396
-0x6c, // 399
-0x00, // 402
-0x00, // 405
-0x00, // 408
-0x00, // 411
-0x00, // 414
-0x01, // 417
-0xf0, // 420
-0x38, // 423
-0x00, // 426
-0x00, // 429
-0x00, // 432
-0x00, // 435
-0x00, // 438
-0x03, // 441
-0x10, // 444
-0x30, // 447
-0x00, // 450
-0x00, // 453
-0x00, // 456
-0x00, // 459
-0x00, // 462
-0x06, // 465
-0x38, // 468
-0x10, // 471
-0x00, // 474
-0x00, // 477
-0x00, // 480
-0x00, // 483
-0x00, // 486
-0x04, // 489
-0x7c, // 492
-0x30, // 495
-0x00, // 498
-0x00, // 501
-0x00, // 504
-0x00, // 507
-0x00, // 510
-0x00, // 513
-0x46, // 516
-0x20, // 519
-0x00, // 522
-0x00, // 525
-0x00, // 528
-0x00, // 531
-0x00, // 534
-0x00, // 537
-0x01, // 540
-0xe0, // 543
-0x00, // 546
-0x00, // 549
-0x00, // 552
-0x00, // 555
-0x00, // 558
-0x00, // 561
-0x07, // 564
-0x80, // 567
-0x00, // 570
-0x00, // 573
-0x00, // 576
-0x00, // 4
-0x00, // 8
-0x00, // 12
-0x00, // 16
-0x00, // 20
-0x00, // 24
-0x00, // 28
-0x00, // 32
-0x00, // 36
-0x00, // 40
-0x00, // 44
-0x00, // 48
-0x00, // 52
-0x00, // 56
-0x00, // 60
-0x00, // 64
-0x00, // 68
-0x00, // 72
-0x00, // 76
-0x00, // 80
-0x00, // 84
-0x00, // 88
-0x00, // 92
-0x00, // 96
-0x00, // 100
-0x00, // 104
-0x00, // 108
-0x00, // 112
-0x00, // 116
-0x00, // 120
-0x00, // 124
-0x00, // 128
-0x00, // 132
-0x00, // 136
-0x00, // 140
-0x00, // 144
-0x00, // 148
-0x00, // 152
-0x00, // 156
-0x00, // 160
-0x00, // 164
-0x00, // 168
-0x00, // 172
-0x00, // 176
-0x00, // 180
-0x00, // 184
-0x00, // 188
-0x00, // 192
-0x00, // 196
-0x00, // 200
-0x00, // 204
-0x00, // 208
-0x00, // 212
-0x00, // 216
-0x00, // 220
-0x00, // 224
-0x00, // 228
-0x00, // 232
-0x00, // 236
-0x00, // 240
-0x00, // 244
-0x00, // 248
-0x00, // 252
-0x00, // 256
-0x00, // 260
-0x00, // 264
-0x01, // 268
-0x10, // 272
-0x00, // 276
-0x00, // 280
-0x00, // 284
-0x00, // 288
-0x00, // 292
-0x00, // 296
-0x01, // 300
-0x90, // 304
-0x00, // 308
-0x00, // 312
-0x00, // 316
-0x00, // 320
-0x00, // 324
-0x00, // 328
-0x00, // 332
-0x90, // 336
-0x00, // 340
-0x00, // 344
-0x00, // 348
-0x00, // 352
-0x00, // 356
-0x00, // 360
-0x00, // 364
-0x90, // 368
-0x00, // 372
-0x00, // 376
-0x00, // 380
-0x00, // 384
-0x00, // 388
-0x00, // 392
-0x00, // 396
-0xfe, // 400
-0x00, // 404
-0x00, // 408
-0x00, // 412
-0x00, // 416
-0x00, // 420
-0x00, // 424
-0x00, // 428
-0x42, // 432
-0x40, // 436
-0x00, // 440
-0x00, // 444
-0x00, // 448
-0x00, // 452
-0x00, // 456
-0x00, // 460
-0x43, // 464
-0xc0, // 468
-0x00, // 472
-0x00, // 476
-0x00, // 480
-0x00, // 484
-0x00, // 488
-0x00, // 492
-0x76, // 496
-0xc8, // 500
-0x00, // 504
-0x00, // 508
-0x00, // 512
-0x00, // 516
-0x00, // 520
-0x00, // 524
-0x3c, // 528
-0x78, // 532
-0x00, // 536
-0x00, // 540
-0x00, // 544
-0x00, // 548
-0x00, // 552
-0x01, // 556
-0xf0, // 560
-0x20, // 564
-0x00, // 568
-0x00, // 572
-0x00, // 576
-0x00, // 580
-0x00, // 584
-0x00, // 588
-0x10, // 592
-0x20, // 596
-0x00, // 600
-0x00, // 604
-0x00, // 608
-0x00, // 612
-0x00, // 616
-0x01, // 620
-0xf8, // 624
-0x20, // 628
-0x00, // 632
-0x00, // 636
-0x00, // 640
-0x00, // 644
-0x00, // 648
-0x03, // 652
-0x1c, // 656
-0x20, // 660
-0x00, // 664
-0x00, // 668
-0x00, // 672
-0x00, // 676
-0x00, // 680
-0x00, // 684
-0x07, // 688
-0xe0, // 692
-0x00, // 696
-0x00, // 700
-0x00, // 704
-0x00, // 708
-0x00, // 712
-0x00, // 716
-0x01, // 720
-0x80, // 724
-0x00, // 728
-0x00, // 732
-0x00, // 736
-0x00, // 740
-0x00, // 744
-0x00, // 748
-0x07, // 752
-0x80, // 756
-0x00, // 760
-0x00, // 764
-0x00, // 768
-0x00, // 5
-0x00, // 10
-0x00, // 15
-0x00, // 20
-0x00, // 25
-0x00, // 30
-0x00, // 35
-0x00, // 40
-0x00, // 45
-0x00, // 50
-0x00, // 55
-0x00, // 60
-0x00, // 65
-0x00, // 70
-0x00, // 75
-0x00, // 80
-0x00, // 85
-0x00, // 90
-0x00, // 95
-0x00, // 100
-0x00, // 105
-0x00, // 110
-0x00, // 115
-0x00, // 120
-0x00, // 125
-0x00, // 130
-0x00, // 135
-0x00, // 140
-0x00, // 145
-0x00, // 150
-0x00, // 155
-0x00, // 160
-0x00, // 165
-0x00, // 170
-0x00, // 175
-0x00, // 180
-0x00, // 185
-0x00, // 190
-0x00, // 195
-0x00, // 200
-0x00, // 205
-0x00, // 210
-0x00, // 215
-0x00, // 220
-0x00, // 225
-0x00, // 230
-0x00, // 235
-0x00, // 240
-0x00, // 245
-0x00, // 250
-0x00, // 255
-0x00, // 260
-0x00, // 265
-0x00, // 270
-0x00, // 275
-0x00, // 280
-0x00, // 285
-0x00, // 290
-0x00, // 295
-0x00, // 300
-0x00, // 305
-0x00, // 310
-0x00, // 315
-0x00, // 320
-0x00, // 325
-0x00, // 330
-0x00, // 335
-0x80, // 340
-0x00, // 345
-0x00, // 350
-0x00, // 355
-0x00, // 360
-0x00, // 365
-0x00, // 370
-0x00, // 375
-0xc0, // 380
-0x00, // 385
-0x00, // 390
-0x00, // 395
-0x00, // 400
-0x00, // 405
-0x00, // 410
-0x03, // 415
-0x60, // 420
-0x00, // 425
-0x00, // 430
-0x00, // 435
-0x00, // 440
-0x00, // 445
-0x00, // 450
-0x01, // 455
-0xb8, // 460
-0x00, // 465
-0x00, // 470
-0x00, // 475
-0x00, // 480
-0x00, // 485
-0x00, // 490
-0x00, // 495
-0xfe, // 500
-0x00, // 505
-0x00, // 510
-0x00, // 515
-0x00, // 520
-0x00, // 525
-0x00, // 530
-0x00, // 535
-0x42, // 540
-0x00, // 545
-0x00, // 550
-0x00, // 555
-0x00, // 560
-0x00, // 565
-0x00, // 570
-0x00, // 575
-0x43, // 580
-0x80, // 585
-0x00, // 590
-0x00, // 595
-0x00, // 600
-0x00, // 605
-0x00, // 610
-0x00, // 615
-0x76, // 620
-0xc0, // 625
-0x00, // 630
-0x00, // 635
-0x00, // 640
-0x00, // 645
-0x00, // 650
-0x02, // 655
-0x3c, // 660
-0x60, // 665
-0x00, // 670
-0x00, // 675
-0x00, // 680
-0x00, // 685
-0x00, // 690
-0x03, // 695
-0xf0, // 700
-0x20, // 705
-0x00, // 710
-0x00, // 715
-0x00, // 720
-0x00, // 725
-0x00, // 730
-0x00, // 735
-0x10, // 740
-0x20, // 745
-0x00, // 750
-0x00, // 755
-0x00, // 760
-0x00, // 765
-0x00, // 770
-0x00, // 775
-0xf8, // 780
-0x20, // 785
-0x00, // 790
-0x00, // 795
-0x00, // 800
-0x00, // 805
-0x00, // 810
-0x00, // 815
-0x1c, // 820
-0x20, // 825
-0x00, // 830
-0x00, // 835
-0x00, // 840
-0x00, // 845
-0x00, // 850
-0x00, // 855
-0x07, // 860
-0xe0, // 865
-0x00, // 870
-0x00, // 875
-0x00, // 880
-0x00, // 885
-0x00, // 890
-0x00, // 895
-0x01, // 900
-0x80, // 905
-0x00, // 910
-0x00, // 915
-0x00, // 920
-0x00, // 925
-0x00, // 930
-0x00, // 935
-0x07, // 940
-0x80, // 945
-0x00, // 950
-0x00, // 955
-0x00, // 960
-0x00, // 6
-0x00, // 12
-0x00, // 18
-0x00, // 24
-0x00, // 30
-0x00, // 36
-0x00, // 42
-0x00, // 48
-0x00, // 54
-0x00, // 60
-0x00, // 66
-0x00, // 72
-0x00, // 78
-0x00, // 84
-0x00, // 90
-0x00, // 96
-0x00, // 102
-0x00, // 108
-0x00, // 114
-0x00, // 120
-0x00, // 126
-0x00, // 132
-0x00, // 138
-0x00, // 144
-0x00, // 150
-0x00, // 156
-0x00, // 162
-0x00, // 168
-0x00, // 174
-0x00, // 180
-0x00, // 186
-0x00, // 192
-0x00, // 198
-0x00, // 204
-0x00, // 210
-0x00, // 216
-0x00, // 222
-0x00, // 228
-0x00, // 234
-0x00, // 240
-0x00, // 246
-0x00, // 252
-0x00, // 258
-0x00, // 264
-0x00, // 270
-0x00, // 276
-0x00, // 282
-0x00, // 288
-0x00, // 294
-0x00, // 300
-0x00, // 306
-0x00, // 312
-0x00, // 318
-0x00, // 324
-0x00, // 330
-0x00, // 336
-0x00, // 342
-0x00, // 348
-0x00, // 354
-0x08, // 360
-0x00, // 366
-0x00, // 372
-0x00, // 378
-0x00, // 384
-0x00, // 390
-0x00, // 396
-0x00, // 402
-0x08, // 408
-0x00, // 414
-0x00, // 420
-0x00, // 426
-0x00, // 432
-0x00, // 438
-0x00, // 444
-0x00, // 450
-0x88, // 456
-0x00, // 462
-0x00, // 468
-0x00, // 474
-0x00, // 480
-0x00, // 486
-0x00, // 492
-0x00, // 498
-0x88, // 504
-0x00, // 510
-0x00, // 516
-0x00, // 522
-0x00, // 528
-0x00, // 534
-0x00, // 540
-0x00, // 546
-0x8e, // 552
-0x00, // 558
-0x00, // 564
-0x00, // 570
-0x00, // 576
-0x00, // 582
-0x00, // 588
-0x00, // 594
-0xdb, // 600
-0x00, // 606
-0x00, // 612
-0x00, // 618
-0x00, // 624
-0x00, // 630
-0x00, // 636
-0x00, // 642
-0x71, // 648
-0x10, // 654
-0x00, // 660
-0x00, // 666
-0x00, // 672
-0x00, // 678
-0x00, // 684
-0x00, // 690
-0x23, // 696
-0xb0, // 702
-0x00, // 708
-0x00, // 714
-0x00, // 720
-0x00, // 726
-0x00, // 732
-0x00, // 738
-0x36, // 744
-0xc0, // 750
-0x00, // 756
-0x00, // 762
-0x00, // 768
-0x00, // 774
-0x00, // 780
-0x00, // 786
-0x3c, // 792
-0x6c, // 798
-0x00, // 804
-0x00, // 810
-0x00, // 816
-0x00, // 822
-0x00, // 828
-0x01, // 834
-0xf0, // 840
-0x38, // 846
-0x00, // 852
-0x00, // 858
-0x00, // 864
-0x00, // 870
-0x00, // 876
-0x03, // 882
-0x10, // 888
-0x30, // 894
-0x00, // 900
-0x00, // 906
-0x00, // 912
-0x00, // 918
-0x00, // 924
-0x06, // 930
-0x38, // 936
-0x10, // 942
-0x00, // 948
-0x00, // 954
-0x00, // 960
-0x00, // 966
-0x00, // 972
-0x04, // 978
-0x7c, // 984
-0x30, // 990
-0x00, // 996
-0x00, // 1002
-0x00, // 1008
-0x00, // 1014
-0x00, // 1020
-0x00, // 1026
-0x46, // 1032
-0x20, // 1038
-0x00, // 1044
-0x00, // 1050
-0x00, // 1056
-0x00, // 1062
-0x00, // 1068
-0x00, // 1074
-0x01, // 1080
-0xe0, // 1086
-0x00, // 1092
-0x00, // 1098
-0x00, // 1104
-0x00, // 1110
-0x00, // 1116
-0x00, // 1122
-0x07, // 1128
-0x80, // 1134
-0x00, // 1140
-0x00, // 1146
-0x00, // 1152
-0x00, // 7
-0x00, // 14
-0x00, // 21
-0x00, // 28
-0x00, // 35
-0x00, // 42
-0x00, // 49
-0x00, // 56
-0x00, // 63
-0x00, // 70
-0x00, // 77
-0x00, // 84
-0x00, // 91
-0x00, // 98
-0x00, // 105
-0x00, // 112
-0x00, // 119
-0x00, // 126
-0x00, // 133
-0x00, // 140
-0x00, // 147
-0x00, // 154
-0x00, // 161
-0x00, // 168
-0x00, // 175
-0x00, // 182
-0x00, // 189
-0x00, // 196
-0x00, // 203
-0x00, // 210
-0x00, // 217
-0x00, // 224
-0x00, // 231
-0x00, // 238
-0x00, // 245
-0x00, // 252
-0x00, // 259
-0x00, // 266
-0x00, // 273
-0x00, // 280
-0x00, // 287
-0x00, // 294
-0x00, // 301
-0x01, // 308
-0x00, // 315
-0x00, // 322
-0x00, // 329
-0x00, // 336
-0x00, // 343
-0x00, // 350
-0x00, // 357
-0x21, // 364
-0x00, // 371
-0x00, // 378
-0x00, // 385
-0x00, // 392
-0x00, // 399
-0x00, // 406
-0x00, // 413
-0x23, // 420
-0x00, // 427
-0x00, // 434
-0x00, // 441
-0x00, // 448
-0x00, // 455
-0x00, // 462
-0x00, // 469
-0x22, // 476
-0x00, // 483
-0x00, // 490
-0x00, // 497
-0x00, // 504
-0x00, // 511
-0x00, // 518
-0x00, // 525
-0x22, // 532
-0x00, // 539
-0x00, // 546
-0x00, // 553
-0x00, // 560
-0x00, // 567
-0x00, // 574
-0x00, // 581
-0x33, // 588
-0x00, // 595
-0x00, // 602
-0x00, // 609
-0x00, // 616
-0x00, // 623
-0x00, // 630
-0x00, // 637
-0x1f, // 644
-0x80, // 651
-0x00, // 658
-0x00, // 665
-0x00, // 672
-0x00, // 679
-0x00, // 686
-0x00, // 693
-0x08, // 700
-0x80, // 707
-0x00, // 714
-0x00, // 721
-0x00, // 728
-0x00, // 735
-0x00, // 742
-0x00, // 749
-0x08, // 756
-0x88, // 763
-0x00, // 770
-0x00, // 777
-0x00, // 784
-0x00, // 791
-0x00, // 798
-0x00, // 805
-0x09, // 812
-0x98, // 819
-0x00, // 826
-0x00, // 833
-0x00, // 840
-0x00, // 847
-0x00, // 854
-0x00, // 861
-0x0f, // 868
-0xf0, // 875
-0x00, // 882
-0x00, // 889
-0x00, // 896
-0x00, // 903
-0x00, // 910
-0x00, // 917
-0x0c, // 924
-0x20, // 931
-0x00, // 938
-0x00, // 945
-0x00, // 952
-0x00, // 959
-0x00, // 966
-0x0f, // 973
-0xf8, // 980
-0x30, // 987
-0x00, // 994
-0x00, // 1001
-0x00, // 1008
-0x00, // 1015
-0x00, // 1022
-0x00, // 1029
-0x08, // 1036
-0x1f, // 1043
-0x80, // 1050
-0x00, // 1057
-0x00, // 1064
-0x00, // 1071
-0x00, // 1078
-0x00, // 1085
-0x1c, // 1092
-0x10, // 1099
-0x00, // 1106
-0x00, // 1113
-0x00, // 1120
-0x00, // 1127
-0x00, // 1134
-0x00, // 1141
-0xf6, // 1148
-0x30, // 1155
-0x00, // 1162
-0x00, // 1169
-0x00, // 1176
-0x00, // 1183
-0x00, // 1190
-0x00, // 1197
-0x83, // 1204
-0x60, // 1211
-0x00, // 1218
-0x00, // 1225
-0x00, // 1232
-0x00, // 1239
-0x00, // 1246
-0x00, // 1253
-0x01, // 1260
-0xc0, // 1267
-0x00, // 1274
-0x00, // 1281
-0x00, // 1288
-0x00, // 1295
-0x00, // 1302
-0x00, // 1309
-0x03, // 1316
-0xe0, // 1323
-0x00, // 1330
-0x00, // 1337
-0x00, // 1344
-0x00, // 8
-0x00, // 16
-0x00, // 24
-0x00, // 32
-0x00, // 40
-0x00, // 48
-0x00, // 56
-0x00, // 64
-0x00, // 72
-0x00, // 80
-0x00, // 88
-0x00, // 96
-0x00, // 104
-0x00, // 112
-0x00, // 120
-0x00, // 128
-0x00, // 136
-0x00, // 144
-0x00, // 152
-0x00, // 160
-0x00, // 168
-0x00, // 176
-0x00, // 184
-0x00, // 192
-0x00, // 200
-0x00, // 208
-0x00, // 216
-0x00, // 224
-0x00, // 232
-0x00, // 240
-0x00, // 248
-0x00, // 256
-0x00, // 264
-0x00, // 272
-0x00, // 280
-0x00, // 288
-0x00, // 296
-0x00, // 304
-0x00, // 312
-0x00, // 320
-0x00, // 328
-0x00, // 336
-0x00, // 344
-0x00, // 352
-0x00, // 360
-0x00, // 368
-0x00, // 376
-0x00, // 384
-0x00, // 392
-0x00, // 400
-0x00, // 408
-0x00, // 416
-0x00, // 424
-0x00, // 432
-0x00, // 440
-0x00, // 448
-0x00, // 456
-0x00, // 464
-0x00, // 472
-0x00, // 480
-0x00, // 488
-0x00, // 496
-0x00, // 504
-0x00, // 512
-0x00, // 520
-0x00, // 528
-0x00, // 536
-0x00, // 544
-0x0c, // 552
-0x00, // 560
-0x00, // 568
-0x00, // 576
-0x00, // 584
-0x00, // 592
-0x00, // 600
-0x06, // 608
-0x18, // 616
-0x00, // 624
-0x00, // 632
-0x00, // 640
-0x00, // 648
-0x00, // 656
-0x00, // 664
-0x03, // 672
-0x30, // 680
-0x00, // 688
-0x00, // 696
-0x00, // 704
-0x00, // 712
-0x00, // 720
-0x00, // 728
-0x01, // 736
-0xe0, // 744
-0x00, // 752
-0x00, // 760
-0x00, // 768
-0x00, // 776
-0x00, // 784
-0x00, // 792
-0x01, // 800
-0x20, // 808
-0x00, // 816
-0x00, // 824
-0x00, // 832
-0x00, // 840
-0x00, // 848
-0x00, // 856
-0x01, // 864
-0x20, // 872
-0x00, // 880
-0x00, // 888
-0x00, // 896
-0x00, // 904
-0x00, // 912
-0x00, // 920
-0x01, // 928
-0xe0, // 936
-0x00, // 944
-0x00, // 952
-0x00, // 960
-0x00, // 968
-0x00, // 976
-0x00, // 984
-0x3d, // 992
-0xb9, // 1000
-0x80, // 1008
-0x00, // 1016
-0x00, // 1024
-0x00, // 1032
-0x00, // 1040
-0x00, // 1048
-0x07, // 1056
-0x0f, // 1064
-0x00, // 1072
-0x00, // 1080
-0x00, // 1088
-0x00, // 1096
-0x00, // 1104
-0x00, // 1112
-0x02, // 1120
-0x08, // 1128
-0x00, // 1136
-0x00, // 1144
-0x00, // 1152
-0x00, // 1160
-0x00, // 1168
-0x00, // 1176
-0x02, // 1184
-0x0b, // 1192
-0x80, // 1200
-0x00, // 1208
-0x00, // 1216
-0x00, // 1224
-0x00, // 1232
-0x00, // 1240
-0x3f, // 1248
-0x1e, // 1256
-0x00, // 1264
-0x00, // 1272
-0x00, // 1280
-0x00, // 1288
-0x00, // 1296
-0x00, // 1304
-0x01, // 1312
-0x10, // 1320
-0x00, // 1328
-0x00, // 1336
-0x00, // 1344
-0x00, // 1352
-0x00, // 1360
-0x00, // 1368
-0x01, // 1376
-0xe0, // 1384
-0x00, // 1392
-0x00, // 1400
-0x00, // 1408
-0x00, // 1416
-0x00, // 1424
-0x00, // 1432
-0x00, // 1440
-0xf0, // 1448
-0x00, // 1456
-0x00, // 1464
-0x00, // 1472
-0x00, // 1480
-0x00, // 1488
-0x00, // 1496
-0x01, // 1504
-0x98, // 1512
-0x00, // 1520
-0x00, // 1528
-0x00, // 1536
-0x00, // 9
-0x00, // 18
-0x00, // 27
-0x01, // 36
-0xff, // 45
-0xc0, // 54
-0x00, // 63
-0x00, // 72
-0x00, // 81
-0x00, // 90
-0x00, // 99
-0x00, // 108
-0xff, // 117
-0x80, // 126
-0x00, // 135
-0x00, // 144
-0x00, // 153
-0x00, // 162
-0x00, // 171
-0x00, // 180
-0x3f, // 189
-0x80, // 198
-0x00, // 207
-0x00, // 216
-0x00, // 225
-0x00, // 234
-0x00, // 243
-0x00, // 252
-0x01, // 261
-0x80, // 270
-0x00, // 279
-0x00, // 288
-0x00, // 297
-0x00, // 306
-0x00, // 315
-0x00, // 324
-0x00, // 333
-0x00, // 342
-0x00, // 351
-0x00, // 360
-0x00, // 369
-0x00, // 378
-0x00, // 387
-0x00, // 396
-0x00, // 405
-0x00, // 414
-0x00, // 423
-0x00, // 432
-0x00, // 441
-0x00, // 450
-0x00, // 459
-0x00, // 468
-0x00, // 477
-0x00, // 486
-0x00, // 495
-0x00, // 504
-0x00, // 513
-0x00, // 522
-0x00, // 531
-0x00, // 540
-0x00, // 549
-0x00, // 558
-0x00, // 567
-0x00, // 576
-0x00, // 585
-0x00, // 594
-0x00, // 603
-0x00, // 612
-0x0c, // 621
-0x00, // 630
-0x00, // 639
-0x00, // 648
-0x00, // 657
-0x00, // 666
-0x00, // 675
-0x06, // 684
-0x18, // 693
-0x00, // 702
-0x00, // 711
-0x00, // 720
-0x00, // 729
-0x00, // 738
-0x00, // 747
-0x03, // 756
-0x30, // 765
-0x00, // 774
-0x00, // 783
-0x00, // 792
-0x00, // 801
-0x00, // 810
-0x00, // 819
-0x01, // 828
-0xe0, // 837
-0x00, // 846
-0x00, // 855
-0x00, // 864
-0x00, // 873
-0x00, // 882
-0x00, // 891
-0x01, // 900
-0x20, // 909
-0x00, // 918
-0x00, // 927
-0x00, // 936
-0x00, // 945
-0x00, // 954
-0x00, // 963
-0x01, // 972
-0x20, // 981
-0x00, // 990
-0x00, // 999
-0x00, // 1008
-0x00, // 1017
-0x00, // 1026
-0x00, // 1035
-0x01, // 1044
-0xe0, // 1053
-0x00, // 1062
-0x00, // 1071
-0x00, // 1080
-0x00, // 1089
-0x00, // 1098
-0x00, // 1107
-0x3d, // 1116
-0xb9, // 1125
-0x80, // 1134
-0x00, // 1143
-0x00, // 1152
-0x00, // 1161
-0x00, // 1170
-0x00, // 1179
-0x07, // 1188
-0x0f, // 1197
-0x00, // 1206
-0x00, // 1215
-0x00, // 1224
-0x00, // 1233
-0x00, // 1242
-0x00, // 1251
-0x02, // 1260
-0x08, // 1269
-0x00, // 1278
-0x00, // 1287
-0x00, // 1296
-0x00, // 1305
-0x00, // 1314
-0x00, // 1323
-0x02, // 1332
-0x0b, // 1341
-0x80, // 1350
-0x00, // 1359
-0x00, // 1368
-0x00, // 1377
-0x00, // 1386
-0x00, // 1395
-0x3f, // 1404
-0x1e, // 1413
-0x00, // 1422
-0x00, // 1431
-0x00, // 1440
-0x00, // 1449
-0x00, // 1458
-0x00, // 1467
-0x01, // 1476
-0x10, // 1485
-0x00, // 1494
-0x00, // 1503
-0x00, // 1512
-0x00, // 1521
-0x00, // 1530
-0x00, // 1539
-0x01, // 1548
-0xe0, // 1557
-0x00, // 1566
-0x00, // 1575
-0x00, // 1584
-0x00, // 1593
-0x00, // 1602
-0x00, // 1611
-0x00, // 1620
-0xf0, // 1629
-0x00, // 1638
-0x00, // 1647
-0x00, // 1656
-0x00, // 1665
-0x00, // 1674
-0x00, // 1683
-0x01, // 1692
-0x98, // 1701
-0x00, // 1710
-0x00, // 1719
-0x00, // 1728
-0x00, // 10
-0x00, // 20
-0x00, // 30
-0x0f, // 40
-0xfe, // 50
-0x00, // 60
-0x00, // 70
-0x00, // 80
-0x00, // 90
-0x00, // 100
-0x00, // 110
-0x0f, // 120
-0xff, // 130
-0xc0, // 140
-0x00, // 150
-0x00, // 160
-0x00, // 170
-0x00, // 180
-0x00, // 190
-0x1f, // 200
-0xff, // 210
-0xc0, // 220
-0x00, // 230
-0x00, // 240
-0x00, // 250
-0x00, // 260
-0x00, // 270
-0x1f, // 280
-0xff, // 290
-0x80, // 300
-0x00, // 310
-0x00, // 320
-0x00, // 330
-0x00, // 340
-0x00, // 350
-0x1f, // 360
-0xff, // 370
-0x80, // 380
-0x00, // 390
-0x00, // 400
-0x00, // 410
-0x00, // 420
-0x00, // 430
-0x1f, // 440
-0xff, // 450
-0x80, // 460
-0x00, // 470
-0x00, // 480
-0x00, // 490
-0x00, // 500
-0x00, // 510
-0x3f, // 520
-0xff, // 530
-0x80, // 540
-0x00, // 550
-0x00, // 560
-0x00, // 570
-0x00, // 580
-0x00, // 590
-0x3f, // 600
-0xff, // 610
-0xff, // 620
-0xff, // 630
-0xf8, // 640
-0x00, // 650
-0x00, // 660
-0x00, // 670
-0x3f, // 680
-0xff, // 690
-0x80, // 700
-0x00, // 710
-0x08, // 720
-0x00, // 730
-0x00, // 740
-0x00, // 750
-0x3f, // 760
-0xff, // 770
-0x80, // 780
-0x00, // 790
-0x08, // 800
-0x00, // 810
-0x00, // 820
-0x00, // 830
-0x3f, // 840
-0xff, // 850
-0x80, // 860
-0x7f, // 870
-0xf8, // 880
-0x00, // 890
-0x00, // 900
-0x00, // 910
-0x3f, // 920
-0xff, // 930
-0xff, // 940
-0xc0, // 950
-0x00, // 960
-0x00, // 970
-0x00, // 980
-0x00, // 990
-0x3f, // 1000
-0xff, // 1010
-0x80, // 1020
-0x00, // 1030
-0x00, // 1040
-0x00, // 1050
-0x00, // 1060
-0x00, // 1070
-0x3f, // 1080
-0xff, // 1090
-0x80, // 1100
-0x00, // 1110
-0x00, // 1120
-0x00, // 1130
-0x00, // 1140
-0x00, // 1150
-0x3f, // 1160
-0xff, // 1170
-0x80, // 1180
-0x00, // 1190
-0x00, // 1200
-0x00, // 1210
-0x00, // 1220
-0x00, // 1230
-0x3f, // 1240
-0xff, // 1250
-0x80, // 1260
-0x00, // 1270
-0x00, // 1280
-0x00, // 1290
-0x00, // 1300
-0x00, // 1310
-0x3f, // 1320
-0xff, // 1330
-0x80, // 1340
-0x00, // 1350
-0x00, // 1360
-0x00, // 1370
-0x00, // 1380
-0x00, // 1390
-0x3f, // 1400
-0xff, // 1410
-0x80, // 1420
-0x00, // 1430
-0x00, // 1440
-0x00, // 1450
-0x00, // 1460
-0x00, // 1470
-0x03, // 1480
-0xfb, // 1490
-0x80, // 1500
-0x00, // 1510
-0x00, // 1520
-0x00, // 1530
-0x00, // 1540
-0x00, // 1550
-0x3f, // 1560
-0x1e, // 1570
-0x00, // 1580
-0x00, // 1590
-0x00, // 1600
-0x00, // 1610
-0x00, // 1620
-0x1c, // 1630
-0x01, // 1640
-0x10, // 1650
-0x7c, // 1660
-0x00, // 1670
-0x00, // 1680
-0x00, // 1690
-0x00, // 1700
-0x10, // 1710
-0x01, // 1720
-0xe0, // 1730
-0x0c, // 1740
-0x00, // 1750
-0x00, // 1760
-0x00, // 1770
-0x00, // 1780
-0x00, // 1790
-0x00, // 1800
-0xf0, // 1810
-0x00, // 1820
-0x80, // 1830
-0x00, // 1840
-0x00, // 1850
-0x00, // 1860
-0x00, // 1870
-0x01, // 1880
-0x98, // 1890
-0x00, // 1900
-0x00, // 1910
-0x00, // 1920
-0x00, // 11
-0x00, // 22
-0x00, // 33
-0x07, // 44
-0xfe, // 55
-0x00, // 66
-0x00, // 77
-0x00, // 88
-0x00, // 99
-0x00, // 110
-0x00, // 121
-0x3f, // 132
-0xff, // 143
-0x80, // 154
-0x00, // 165
-0x00, // 176
-0x00, // 187
-0x00, // 198
-0x00, // 209
-0x3f, // 220
-0xff, // 231
-0xc0, // 242
-0x00, // 253
-0x00, // 264
-0x00, // 275
-0x00, // 286
-0x00, // 297
-0x3f, // 308
-0xff, // 319
-0xc0, // 330
-0x00, // 341
-0x00, // 352
-0x00, // 363
-0x00, // 374
-0x00, // 385
-0x3f, // 396
-0xff, // 407
-0xc0, // 418
-0x00, // 429
-0x00, // 440
-0x00, // 451
-0x00, // 462
-0x00, // 473
-0x3f, // 484
-0xff, // 495
-0xc0, // 506
-0x00, // 517
-0x00, // 528
-0x00, // 539
-0x00, // 550
-0x00, // 561
-0x7f, // 572
-0xff, // 583
-0xc0, // 594
-0x00, // 605
-0x00, // 616
-0x00, // 627
-0x00, // 638
-0x00, // 649
-0x7f, // 660
-0xff, // 671
-0xc0, // 682
-0x01, // 693
-0xf8, // 704
-0x00, // 715
-0x00, // 726
-0x00, // 737
-0x7f, // 748
-0xff, // 759
-0xc0, // 770
-0x1f, // 781
-0x0c, // 792
-0x00, // 803
-0x00, // 814
-0x00, // 825
-0x7f, // 836
-0xff, // 847
-0xc0, // 858
-0xf0, // 869
-0x0c, // 880
-0x00, // 891
-0x00, // 902
-0x00, // 913
-0x7f, // 924
-0xff, // 935
-0xff, // 946
-0x00, // 957
-0x38, // 968
-0x00, // 979
-0x00, // 990
-0x00, // 1001
-0x7f, // 1012
-0xff, // 1023
-0xe0, // 1034
-0x01, // 1045
-0xc0, // 1056
-0x00, // 1067
-0x00, // 1078
-0x00, // 1089
-0x3f, // 1100
-0xff, // 1111
-0xc0, // 1122
-0xff, // 1133
-0x00, // 1144
-0x00, // 1155
-0x00, // 1166
-0x00, // 1177
-0x3f, // 1188
-0xff, // 1199
-0xc7, // 1210
-0x80, // 1221
-0x00, // 1232
-0x00, // 1243
-0x00, // 1254
-0x00, // 1265
-0x3f, // 1276
-0xff, // 1287
-0xfc, // 1298
-0x00, // 1309
-0x00, // 1320
-0x00, // 1331
-0x00, // 1342
-0x00, // 1353
-0x3f, // 1364
-0xff, // 1375
-0xe0, // 1386
-0x00, // 1397
-0x00, // 1408
-0x00, // 1419
-0x00, // 1430
-0x00, // 1441
-0x3f, // 1452
-0xff, // 1463
-0xc0, // 1474
-0x00, // 1485
-0x00, // 1496
-0x00, // 1507
-0x00, // 1518
-0x00, // 1529
-0x3f, // 1540
-0xff, // 1551
-0x80, // 1562
-0x00, // 1573
-0x00, // 1584
-0x00, // 1595
-0x00, // 1606
-0x00, // 1617
-0x3f, // 1628
-0xff, // 1639
-0x80, // 1650
-0x00, // 1661
-0x00, // 1672
-0x00, // 1683
-0x00, // 1694
-0x00, // 1705
-0x3f, // 1716
-0xff, // 1727
-0x80, // 1738
-0x00, // 1749
-0x00, // 1760
-0x00, // 1771
-0x00, // 1782
-0x00, // 1793
-0x1f, // 1804
-0xff, // 1815
-0x80, // 1826
-0x00, // 1837
-0x00, // 1848
-0x00, // 1859
-0x00, // 1870
-0x00, // 1881
-0x1f, // 1892
-0xff, // 1903
-0x80, // 1914
-0x00, // 1925
-0x00, // 1936
-0x00, // 1947
-0x00, // 1958
-0x00, // 1969
-0x1f, // 1980
-0xff, // 1991
-0x80, // 2002
-0x00, // 2013
-0x00, // 2024
-0x00, // 2035
-0x00, // 2046
-0x5f, // 2057
-0x9f, // 2068
-0xff, // 2079
-0x9f, // 2090
-0x10, // 2101
-0x00, // 2112
-};
diff --git a/modules/rosapps/applications/sysutils/utils/pice/module/bp.c
b/modules/rosapps/applications/sysutils/utils/pice/module/bp.c
deleted file mode 100644
index 7b71296e4c1..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/module/bp.c
+++ /dev/null
@@ -1,752 +0,0 @@
-/*++
-
-Copyright (c) 1998-2001 Klaus P. Gerlicher
-
-Module Name:
-
- bp.c
-
-Abstract:
-
- setting, listing and removing breakpoints
-
-Environment:
-
- LINUX 2.2.X
- Kernel mode only
-
-Author:
-
- Klaus P. Gerlicher
-
-Revision History:
-
- 13-Nov-1999: created
- 15-Nov-2000: general cleanup of source files
-
-Copyright notice:
-
- This file may be distributed under the terms of the GNU Public License.
-
---*/
-
-////////////////////////////////////////////////////
-// INCLUDES
-////
-#include "remods.h"
-#include "precomp.h"
-
-////////////////////////////////////////////////////
-// GLOBALS
-////
-char tempBp[1024];
-
-ULONG OldInt3Handler=0;
-
-SW_BP aSwBreakpoints[64]={{0,0,0,0},};
-
-//*************************************************************************
-// FindSwBp()
-//
-//*************************************************************************
-PSW_BP FindSwBp(ULONG ulAddress)
-{
- ULONG i;
-
- for(i=0;i<DIM(aSwBreakpoints);i++)
- {
- if(aSwBreakpoints[i].ulAddress == ulAddress &&
aSwBreakpoints[i].bUsed==TRUE && aSwBreakpoints[i].bVirtual==FALSE)
- return &aSwBreakpoints[i];
- }
-
- return NULL;
-}
-
-//*************************************************************************
-// FindEmptySwBpSlot()
-//
-//*************************************************************************
-PSW_BP FindEmptySwBpSlot(void)
-{
- ULONG i;
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- if(aSwBreakpoints[i].bUsed == FALSE)
- {
- return &aSwBreakpoints[i];
- }
- }
-
- return NULL;
-}
-
-//*************************************************************************
-// FindVirtualSwBp()
-//
-//*************************************************************************
-PSW_BP FindVirtualSwBp(LPSTR ModName,LPSTR szFunctionName)
-{
- ULONG i;
- PSW_BP p;
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
-
- if(p->bUsed == TRUE &&
- p->bVirtual == TRUE &&
- PICE_strcmpi(p->szModName,ModName)==0 &&
- PICE_strcmpi(p->szFunctionName,szFunctionName)==0)
- {
- return p;
- }
- }
-
- return NULL;
-}
-
-//*************************************************************************
-// IsSwBpAtAddressInstalled()
-//
-//*************************************************************************
-BOOLEAN IsSwBpAtAddressInstalled(ULONG ulAddress)
-{
- ULONG i;
-
- for(i=0;i<DIM(aSwBreakpoints);i++)
- {
- if(aSwBreakpoints[i].ulAddress == ulAddress &&
- aSwBreakpoints[i].bUsed == TRUE &&
- aSwBreakpoints[i].bInstalled &&
- aSwBreakpoints[i].bVirtual == FALSE)
- return TRUE;
- }
-
- return FALSE;
-}
-
-//*************************************************************************
-// IsSwBpAtAddress()
-//
-//*************************************************************************
-BOOLEAN IsSwBpAtAddress(ULONG ulAddress)
-{
- ULONG i;
-
- for(i=0;i<DIM(aSwBreakpoints);i++)
- {
- if(aSwBreakpoints[i].ulAddress == ulAddress &&
aSwBreakpoints[i].bUsed==TRUE && aSwBreakpoints[i].bVirtual==FALSE)
- return TRUE;
- }
-
- return FALSE;
-}
-
-//*************************************************************************
-// NeedToReInstallSWBreakpoints()
-//
-//*************************************************************************
-BOOLEAN NeedToReInstallSWBreakpoints(ULONG ulAddress,BOOLEAN bUseAddress)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
- ULONG i;
-
- ENTER_FUNC();
- DPRINT((0,"NeedToReInstallSWBreakpoint() for %x (bUseAddress =
%s)\n",ulAddress,bUseAddress?"TRUE":"FALSE"));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- if(bUseAddress)
- {
- if(p->bUsed == TRUE && p->bInstalled == FALSE &&
p->ulAddress==ulAddress && p->bVirtual==FALSE)
- {
- if(IsAddressValid(p->ulAddress))
- {
- DPRINT((0,"NeedToReInstallSWBreakpoint(): [1] found
BP\n"));
- bResult = TRUE;
- break;
- }
- }
- }
- else
- {
- if(p->bUsed == TRUE && p->bInstalled == FALSE &&
p->bVirtual == FALSE)
- {
- if(IsAddressValid(p->ulAddress))
- {
- DPRINT((0,"NeedToReInstallSWBreakpoint(): [2] found
BP\n"));
- bResult = TRUE;
- break;
- }
- }
- }
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-//*************************************************************************
-// ReInstallSWBreakpoint()
-//
-//*************************************************************************
-BOOLEAN ReInstallSWBreakpoint(ULONG ulAddress)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
- ULONG i;
-
- ENTER_FUNC();
- DPRINT((0,"ReInstallSWBreakpoint()\n"));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- if(p->bUsed == TRUE && p->bInstalled == FALSE &&
p->ulAddress == ulAddress && p->bVirtual == FALSE)
- {
- if(IsAddressValid(p->ulAddress))
- {
- BOOLEAN isWriteable;
-
- if( !( isWriteable = IsAddressWriteable(p->ulAddress) ) )
- SetAddressWriteable(p->ulAddress,TRUE);
- *(PUCHAR)(p->ulAddress) = 0xCC;
- if( !isWriteable )
- SetAddressWriteable(p->ulAddress,FALSE);
- p->bInstalled = TRUE;
- bResult = TRUE;
- }
- }
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-
-//*************************************************************************
-// InstallSWBreakpoint()
-//
-//*************************************************************************
-BOOLEAN InstallSWBreakpoint(ULONG ulAddress,BOOLEAN bPermanent,void
(*SWBreakpointCallback)(void))
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
-
- ENTER_FUNC();
- DPRINT((0,"InstallSWBreakpoint()\n"));
-
- // check if page is present
- // TODO: must also check if it's a writable page
- if(IsAddressValid(ulAddress) )
- {
- DPRINT((0,"InstallSWBreakpoint(): %.8X is valid, writable?
%d\n",ulAddress,IsAddressWriteable(ulAddress)));
- DPRINT((0,"pde: %x, pte: %x\n", *(ADDR_TO_PDE(ulAddress)),
*(ADDR_TO_PTE(ulAddress))));
- if((p = FindSwBp(ulAddress))==NULL)
- {
- DPRINT((0,"InstallSWBreakpoint(): %.8X is free\n",ulAddress));
- if( (p=FindEmptySwBpSlot()) )
- {
- BOOLEAN isWriteable;
- DPRINT((0,"InstallSWBreakpoint(): found empty slot\n"));
- DPRINT((0,"InstallSWBreakpoint(): %x value: %x", ulAddress,
*(PUCHAR)ulAddress));
- p->ucOriginalOpcode = *(PUCHAR)ulAddress;
- //allow writing to page
- if( !( isWriteable = IsAddressWriteable(ulAddress) ) )
- SetAddressWriteable(ulAddress,TRUE);
- DPRINT((0,"writing breakpoint\n"));
- *(PUCHAR)ulAddress = 0xCC;
- DPRINT((0,"restoring page access\n"));
- if( !isWriteable )
- SetAddressWriteable(ulAddress,FALSE);
- p->bUsed = TRUE;
- p->bInstalled = TRUE;
- // find next address
- p->ulAddress = ulAddress;
- Disasm(&ulAddress,(PUCHAR)&tempBp);
- p->ulNextInstr = ulAddress;
- p->bPermanent = bPermanent;
- if(bPermanent)
- p->Callback = SWBreakpointCallback;
- else
- p->Callback = NULL;
- bResult = TRUE;
- }
- }
- else
- {
- DPRINT((0,"InstallSWBreakpoint(): %.8X is already
used\n",ulAddress));
- if(p->bPermanent)
- {
- DPRINT((0,"InstallSWBreakpoint(): %.8X is a permanent
breakpoint\n",ulAddress));
- }
- }
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-//*************************************************************************
-// InstallVirtualSWBreakpoint()
-//
-//*************************************************************************
-BOOLEAN InstallVirtualSWBreakpoint(LPSTR ModName,LPSTR FunctionName)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
-
- ENTER_FUNC();
- DPRINT((0,"InstallVirtualSWBreakpoint(%s!%s)\n",ModName,FunctionName));
-
- if( (p=FindEmptySwBpSlot()) )
- {
- DPRINT((0,"InstallVirtualSWBreakpoint(): found empty slot\n"));
-
- p->bUsed = TRUE;
- p->bInstalled = TRUE;
- p->bVirtual = TRUE;
- p->Callback = NULL;
- PICE_strcpy(p->szModName,ModName);
- PICE_strcpy(p->szFunctionName,FunctionName);
-
- bResult = TRUE;
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-//*************************************************************************
-// TryToInstallVirtualSWBreakpoints()
-//
-//*************************************************************************
-void TryToInstallVirtualSWBreakpoints(void)
-{
- ULONG i,ulAddress;
- PDEBUG_MODULE pMod;
- PSW_BP p;
-
- DPRINT((0,"TryToInstallVirtualSWBreakpoints()\n"));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- if(p->bUsed == TRUE && p->bVirtual)
- {
- if((pMod = IsModuleLoaded(p->szModName)))
- {
- if((ulAddress = FindFunctionInModuleByName(p->szFunctionName,pMod)))
- {
- if((p = FindVirtualSwBp(p->szModName,p->szFunctionName)))
- {
- ULONG ulAddressWithOffset = ulAddress+p->ulAddress;
- DPRINT((0,"TryToInstallVirtualSWBreakpoints(): ulAddressWithOffset = %x
(offset = %x)\n",ulAddressWithOffset,p->ulAddress));
-
- if(IsAddressValid(ulAddressWithOffset))
- {
- BOOLEAN isWriteable;
- DPRINT((0,"TryToInstallVirtualSWBreakpoints(): installing...\n"));
- p->ucOriginalOpcode = *(PUCHAR)ulAddressWithOffset;
- //allow writing to page
- if( !( isWriteable = IsAddressWriteable(ulAddressWithOffset) ) )
- SetAddressWriteable(ulAddressWithOffset,TRUE);
- *(PUCHAR)ulAddressWithOffset = 0xCC;
- if( !isWriteable )
- SetAddressWriteable(ulAddressWithOffset,FALSE);
- p->bUsed = TRUE;
- p->bInstalled = TRUE;
- p->bVirtual = FALSE;
- // find next address
- p->ulAddress = ulAddressWithOffset;
- Disasm(&ulAddressWithOffset,(PUCHAR)&tempBp);
- p->ulNextInstr = ulAddressWithOffset;
- p->bPermanent = FALSE;
- p->Callback = NULL;
- }
- else
- {
- DPRINT((0,"TryToInstallVirtualSWBreakpoints(): not valid
address\n"));
- PICE_memset(p,0,sizeof(*p));
- }
- }
-
- }
- }
- }
- }
-}
-
-//*************************************************************************
-// RemoveSWBreakpoint()
-//
-// removes breakpoint from breakpoint list
-//*************************************************************************
-BOOLEAN RemoveSWBreakpoint(ULONG ulAddress)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
-
- ENTER_FUNC();
- DPRINT((0,"RemoveSWBreakpoint()\n"));
-
- if( (p = FindSwBp(ulAddress)) )
- {
- if(IsAddressValid(ulAddress) && p->bInstalled == TRUE &&
p->bVirtual==FALSE)
- {
- BOOLEAN isWriteable;
- if( !( isWriteable = IsAddressWriteable(ulAddress) ) )
- SetAddressWriteable(ulAddress,TRUE);
- // restore original opcode
- *(PUCHAR)(p->ulAddress) = p->ucOriginalOpcode;
- if( !isWriteable )
- SetAddressWriteable(ulAddress,FALSE);
- }
-
- PICE_memset(p,0,sizeof(*p));
-
- bResult = TRUE;
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-
-//*************************************************************************
-// DeInstallSWBreakpoint()
-//
-//*************************************************************************
-BOOLEAN DeInstallSWBreakpoint(ULONG ulAddress)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
-
- ENTER_FUNC();
- DPRINT((0,"DeInstallSWBreakpoint()\n"));
-
- if( (p = FindSwBp(ulAddress)) )
- {
- if(IsAddressValid(ulAddress) && p->bInstalled == TRUE &&
p->bVirtual==FALSE)
- {
- BOOLEAN isWriteable;
- if( !( isWriteable = IsAddressWriteable(ulAddress) ) )
- SetAddressWriteable(ulAddress,TRUE);
- // restore original opcode
- *(PUCHAR)(p->ulAddress) = p->ucOriginalOpcode;
- if( !isWriteable )
- SetAddressWriteable(ulAddress,FALSE);
- }
-
- p->bInstalled = FALSE;
-
- bResult = TRUE;
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-//*************************************************************************
-// RemoveAllSWBreakpoints()
-//
-//*************************************************************************
-BOOLEAN RemoveAllSWBreakpoints(BOOLEAN bEvenPermanents)
-{
- PSW_BP p;
- BOOLEAN bResult = FALSE;
- ULONG i;
-
- ENTER_FUNC();
- DPRINT((0,"RemoveAllSWBreakpoint()\n"));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- if(p->bUsed == TRUE)
- {
- if(bEvenPermanents)
- {
- if(IsAddressValid(p->ulAddress) && p->bVirtual==FALSE)
- {
- BOOLEAN isWriteable;
- if( !( isWriteable = IsAddressWriteable(p->ulAddress) ) )
- SetAddressWriteable(p->ulAddress,TRUE);
- *(PUCHAR)(p->ulAddress) = p->ucOriginalOpcode;
- if( !isWriteable )
- SetAddressWriteable(p->ulAddress,FALSE);
- bResult = TRUE;
- }
- PICE_memset(p,0,sizeof(*p));
- }
- else
- {
- if(!p->bPermanent)
- {
- if(IsAddressValid(p->ulAddress) &&
p->bVirtual==FALSE)
- {
- BOOLEAN isWriteable;
- if( !( isWriteable = IsAddressWriteable(p->ulAddress) ) )
- SetAddressWriteable(p->ulAddress,TRUE);
- *(PUCHAR)(p->ulAddress) = p->ucOriginalOpcode;
- if( !isWriteable )
- SetAddressWriteable(p->ulAddress,FALSE);
- bResult = TRUE;
- }
- PICE_memset(p,0,sizeof(*p));
- }
- }
- }
- }
-
- LEAVE_FUNC();
-
- return bResult;
-}
-
-//*************************************************************************
-// IsPermanentSWBreakpoint()
-//
-//*************************************************************************
-PSW_BP IsPermanentSWBreakpoint(ULONG ulAddress)
-{
- PSW_BP p;
- ULONG i;
-
- ENTER_FUNC();
- DPRINT((0,"IsPermanentSWBreakpoint(%.8X)\n",ulAddress));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(aSwBreakpoints[0]));i++)
- {
- p = &aSwBreakpoints[i];
- if(p->ulAddress == ulAddress &&
- p->bUsed == TRUE &&
- p->bPermanent == TRUE)
- {
- LEAVE_FUNC();
- return p;
- }
- }
-
- LEAVE_FUNC();
-
- return NULL;
-}
-
-//*************************************************************************
-// ListSWBreakpoints()
-//
-//*************************************************************************
-void ListSWBreakpoints(void)
-{
- PSW_BP p;
- ULONG i;
- LPSTR pSymbolName;
- PDEBUG_MODULE pMod;
-
- ENTER_FUNC();
- DPRINT((0,"ListSWBreakpoints()\n"));
-
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- if(p->bUsed == TRUE && p->bVirtual == FALSE)
- {
- if((pSymbolName = FindFunctionByAddress(p->ulAddress,NULL,NULL)) )
- {
- pMod = FindModuleFromAddress(p->ulAddress);
- PICE_sprintf(tempBp,"[%u] %.8X (%S!%s)
%s\n",i,p->ulAddress,pMod->name,pSymbolName,p->bPermanent?"PERMANENT":"");
- }
- else
- {
- if(ScanExportsByAddress(&pSymbolName,p->ulAddress))
- PICE_sprintf(tempBp,"[%u] %.8X (%s)
%s\n",i,p->ulAddress,pSymbolName,p->bPermanent?"PERMANENT":"");
- else
- PICE_sprintf(tempBp,"[%u] %.8X (no symbol)
%s\n",i,p->ulAddress,p->bPermanent?"PERMANENT":"");
- }
- Print(OUTPUT_WINDOW,tempBp);
- }
- else if(p->bUsed == TRUE)
- {
- PICE_sprintf(tempBp,"[%u] xxxxxxxx (%s!%s)
VIRTUAL\n",i,p->szModName,p->szFunctionName);
- Print(OUTPUT_WINDOW,tempBp);
- }
- }
-
- LEAVE_FUNC();
-}
-
-//*************************************************************************
-// RevirtualizeBreakpointsForModule()
-//
-//*************************************************************************
-void RevirtualizeBreakpointsForModule(PDEBUG_MODULE pMod)
-{
- ULONG i,start,end;
- PSW_BP p;
- char temp[DEBUG_MODULE_NAME_LEN];
-
- DPRINT((0,"RevirtualizeBreakpointsForModule(%x)\n",(ULONG)pMod));
-
- if(IsRangeValid((ULONG)pMod,sizeof(DEBUG_MODULE)) )
- {
- start = (ULONG)pMod->BaseAddress;
- end = (ULONG)pMod->BaseAddress+pMod->size;
-
- DPRINT((0,"RevirtualizeBreakpointsForModule(): module %x
(%x-%x)\n",(ULONG)pMod,start,end));
- // go through all breakpoints
- for(i=0;i<(sizeof(aSwBreakpoints)/sizeof(SW_BP));i++)
- {
- p = &aSwBreakpoints[i];
- // if it's used and installed and not virtual
- if(p->bUsed && p->bInstalled && p->bVirtual ==
FALSE)
- {
- // make sure we're in module's bound
- if(p->ulAddress>=start && p->ulAddress<end)
- {
- LPSTR pFind;
- ULONG ulFunctionAddress;
-
- DPRINT((0,"RevirtualizeBreakpointsForModule(): module breakpoint
%u\n",i));
- // find the function in which this breakpoint resides
- if(ScanExportsByAddress(&pFind,p->ulAddress))
- {
- // from now on it's virtual again
- p->bVirtual = TRUE;
- if(IsAddressValid(p->ulAddress) )
- {
- BOOLEAN isWriteable;
- if( !( isWriteable = IsAddressWriteable(p->ulAddress) ) )
- SetAddressWriteable(p->ulAddress,TRUE);
- DPRINT((0,"RevirtualizeBreakpointsForModule(): restoring original opcode @
%x\n",p->ulAddress));
- *(PUCHAR)(p->ulAddress) = p->ucOriginalOpcode;
- if( !isWriteable )
- SetAddressWriteable(p->ulAddress,FALSE);
- }
- else
- {
- DPRINT((0,"RevirtualizeBreakpointsForModule(): could not restore original
opcode @ %x\n",p->ulAddress));
- }
- // skip past the module separator
- while(*pFind!='!')pFind++;
- pFind++;
- // remember the function and the module for reinstallation
- CopyWideToAnsi(temp,pMod->name);
- PICE_strcpy(p->szModName,temp);
- PICE_strcpy(p->szFunctionName,pFind);
- DPRINT((0,"RevirtualizeBreakpointsForModule():
%s!%s\n",p->szModName,p->szFunctionName));
- // if function name contains a '+' it's an offset
- pFind = p->szFunctionName;
- while(*pFind!=0)
- {
- DPRINT((0,"RevirtualizeBreakpointsForModule(): [1] %s\n",pFind));
- // found any offset to function
- if(*pFind=='+')
- {
- *pFind=0;
- break;
- }
- pFind++;
- }
-
- DPRINT((0,"RevirtualizeBreakpointsForModule(): [2]
%s\n",p->szFunctionName));
- if(ScanExports(p->szFunctionName,&ulFunctionAddress))
- {
- p->ulAddress -= ulFunctionAddress;
- DPRINT((0,"RevirtualizeBreakpointsForModule(): [1] function @ %x offset =
%x\n",ulFunctionAddress,p->ulAddress));
- }
- else
- {
- if((ulFunctionAddress = FindFunctionInModuleByName(p->szFunctionName,pMod)) )
- {
- p->ulAddress -= ulFunctionAddress;
- DPRINT((0,"RevirtualizeBreakpointsForModule(): [2] function @ %x offset =
%x\n",ulFunctionAddress,p->ulAddress));
- }
- else
- {
- DPRINT((0,"RevirtualizeBreakpointsForModule(): Breakpoint %u could not be
virtualized properly!\n",i));
- PICE_sprintf(tempBp,"Breakpoint %u could not be virtualized
properly!\n",i);
- Print(OUTPUT_WINDOW,tempBp);
- }
- }
- }
- else
- {
- DPRINT((0,"RevirtualizeBreakpointsForModule(): function for %x not
found!\n",p->ulAddress));
- PICE_memset(p,0,sizeof(*p));
- }
- }
- }
- }
- }
-}
-
-//*************************************************************************
-// NewInt3Handler()
-//
-//*************************************************************************
-__asm__ ("\n\t \
-NewInt3Handler:\n\t \
- pushl $" STR(REASON_INT3) "\n\t \
- // call debugger loop\n\t \
- jmp NewInt31Handler\n\t \
-");
-
-
-//*************************************************************************
-// InstallInt3Hook()
-//
-//*************************************************************************
-void InstallInt3Hook(void)
-{
- ULONG LocalInt3Handler;
-
- ENTER_FUNC();
- DPRINT((0,"enter InstallInt3Hook()...\n"));
-
- MaskIrqs();
- if(!OldInt3Handler)
- {
- PICE_memset(aSwBreakpoints,0,sizeof(aSwBreakpoints));
- __asm__("mov $NewInt3Handler,%0"
- :"=r" (LocalInt3Handler)
- :
- :"eax");
- OldInt3Handler=SetGlobalInt(0x03,(ULONG)LocalInt3Handler);
- }
- UnmaskIrqs();
-
- DPRINT((0,"leave InstallInt3Hook()...\n"));
- LEAVE_FUNC();
-}
-
-//*************************************************************************
-// DeInstallInt3Hook()
-//
-//*************************************************************************
-void DeInstallInt3Hook(void)
-{
- ENTER_FUNC();
- DPRINT((0,"enter DeInstallInt3Hook()...\n"));
-
- MaskIrqs();
- if(OldInt3Handler)
- {
- RemoveAllSWBreakpoints(TRUE);
- SetGlobalInt(0x03,(ULONG)OldInt3Handler);
- OldInt3Handler=0;
- }
- UnmaskIrqs();
-
- DPRINT((0,"leave DeInstallInt3Hook()...\n"));
- LEAVE_FUNC();
-}
diff --git a/modules/rosapps/applications/sysutils/utils/pice/module/bp.h
b/modules/rosapps/applications/sysutils/utils/pice/module/bp.h
deleted file mode 100644
index 29cf59d1926..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/module/bp.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*++
-
-Copyright (c) 1998-2001 Klaus P. Gerlicher
-
-Module Name:
-
- bp.h
-
-Abstract:
-
- HEADER for bp.c
-
-Environment:
-
- LINUX 2.2.X
- Kernel mode only
-
-Author:
-
- Klaus P. Gerlicher
-
-Revision History:
-
- 15-Nov-2000: general cleanup of source files
-
-Copyright notice:
-
- This file may be distributed under the terms of the GNU Public License.
-
---*/
-typedef struct _SW_BP
-{
- ULONG ulAddress;
- ULONG ulNextInstr;
- UCHAR ucOriginalOpcode;
- BOOLEAN bUsed;
- BOOLEAN bInstalled;
- BOOLEAN bPermanent;
- BOOLEAN bVirtual;
- char szModName[128];
- char szFunctionName[128];
- void (*Callback)(void);
-}SW_BP,*PSW_BP;
-
-BOOLEAN InstallSWBreakpoint(ULONG ulAddress,BOOLEAN bPermanent,void
(*SWBreakpointCallback)(void));
-BOOLEAN InstallVirtualSWBreakpoint(LPSTR ModName,LPSTR Function);
-void TryToInstallVirtualSWBreakpoints(void);
-BOOLEAN DeInstallSWBreakpoint(ULONG ulAddress);
-BOOLEAN RemoveSWBreakpoint(ULONG ulAddress);
-BOOLEAN NeedToReInstallSWBreakpoints(ULONG ulAddress,BOOLEAN bUseAddress);
-BOOLEAN ReInstallSWBreakpoint(ULONG ulAddress);
-BOOLEAN RemoveAllSWBreakpoints(BOOLEAN bEvenPermanents);
-PSW_BP IsPermanentSWBreakpoint(ULONG ulAddress);
-void ListSWBreakpoints(void);
-PSW_BP FindSwBp(ULONG ulAddress);
-BOOLEAN IsSwBpAtAddress(ULONG ulAddress);
-BOOLEAN IsSwBpAtAddressInstalled(ULONG ulAddress);
-void RevirtualizeBreakpointsForModule(PDEBUG_MODULE pMod);
-
-void InstallInt3Hook(void);
-void DeInstallInt3Hook(void);
-
diff --git a/modules/rosapps/applications/sysutils/utils/pice/module/charset.h
b/modules/rosapps/applications/sysutils/utils/pice/module/charset.h
deleted file mode 100644
index 4b276a9f5e9..00000000000
--- a/modules/rosapps/applications/sysutils/utils/pice/module/charset.h
+++ /dev/null
@@ -1,2564 +0,0 @@
-// this file is dynamically generated: DON'T TOUCH
-
-UCHAR cGraphTable[8*256]=
-{
- /* 0 0x00 '^@' */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
-
- /* 1 0x01 '^A' */
- 0x7e, /* 01111110 */
- 0x81, /* 10000001 */
- 0xa5, /* 10100101 */
- 0x81, /* 10000001 */
- 0xbd, /* 10111101 */
- 0x99, /* 10011001 */
- 0x81, /* 10000001 */
- 0x7e, /* 01111110 */
-
- /* 2 0x02 '^B' */
- 0x7e, /* 01111110 */
- 0xff, /* 11111111 */
- 0xdb, /* 11011011 */
- 0xff, /* 11111111 */
- 0xc3, /* 11000011 */
- 0xe7, /* 11100111 */
- 0xff, /* 11111111 */
- 0x7e, /* 01111110 */
-
- /* 3 0x03 '^C' */
- 0x6c, /* 01101100 */
- 0xfe, /* 11111110 */
- 0xfe, /* 11111110 */
- 0xfe, /* 11111110 */
- 0x7c, /* 01111100 */
- 0x38, /* 00111000 */
- 0x10, /* 00010000 */
- 0x00, /* 00000000 */
-
- /* 4 0x04 '^D' */
- 0x10, /* 00010000 */
- 0x38, /* 00111000 */
- 0x7c, /* 01111100 */
- 0xfe, /* 11111110 */
- 0x7c, /* 01111100 */
- 0x38, /* 00111000 */
- 0x10, /* 00010000 */
- 0x00, /* 00000000 */
-
- /* 5 0x05 '^E' */
- 0x38, /* 00111000 */
- 0x7c, /* 01111100 */
- 0x38, /* 00111000 */
- 0xfe, /* 11111110 */
- 0xfe, /* 11111110 */
- 0xd6, /* 11010110 */
- 0x10, /* 00010000 */
- 0x38, /* 00111000 */
-
- /* 6 0x06 '^F' */
- 0x10, /* 00010000 */
- 0x38, /* 00111000 */
- 0x7c, /* 01111100 */
- 0xfe, /* 11111110 */
- 0xfe, /* 11111110 */
- 0x7c, /* 01111100 */
- 0x10, /* 00010000 */
- 0x38, /* 00111000 */
-
- /* 7 0x07 '^G' */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
- 0x18, /* 00011000 */
- 0x3c, /* 00111100 */
- 0x3c, /* 00111100 */
- 0x18, /* 00011000 */
- 0x00, /* 00000000 */
- 0x00, /* 00000000 */
-
- /* 8 0x08 '^H' */
- 0xff, /* 11111111 */
- 0xff, /* 11111111 */
- 0xe7, /* 11100111 */
- 0xc3, /* 11000011 */
- 0xc3, /* 11000011 */
- 0xe7, /* 11100111 */
- 0xff, /* 11111111 */
- 0xff, /* 11111111 */
-
- /* 9 0x09 '^I' */
- 0x00, /* 00000000 */
- 0x3c, /* 00111100 */
- 0x66, /* 01100110 */
- 0x42, /* 01000010 */
- 0x42, /* 01000010 */
- 0x66, /* 01100110 */
- 0x3c, /* 00111100 */
- 0x00, /* 00000000 */
-
- /* 10 0x0a '^J' */
- 0xff, /* 11111111 */
- 0xc3, /* 11000011 */
- 0x99, /* 10011001 */
- 0xbd, /* 10111101 */
- 0xbd, /* 10111101 */
- 0x99, /* 10011001 */
- 0xc3, /* 11000011 */
- 0xff, /* 11111111 */
-
- /* 11 0x0b '^K' */
- 0x0f, /* 00001111 */
... 26746 lines suppressed ...