com.tapina.robe.swi
Class SharedCLibrary

java.lang.Object
  extended bycom.tapina.robe.runtime.Block
      extended bycom.tapina.robe.runtime.DataBlock
          extended bycom.tapina.robe.module.Module
              extended bycom.tapina.robe.swi.SWIHandler
                  extended bycom.tapina.robe.swi.SharedCLibrary

public class SharedCLibrary
extends SWIHandler

Floating point emulator SWIs. Currently there are no floating point instructions available.


Field Summary
static int FILE_DESCRIPTOR_SIZE
           
 
Fields inherited from class com.tapina.robe.swi.SWIHandler
log, METHOD_PARAMETERS
 
Method Summary
static int getBase()
           
static SharedCLibrary getInstance()
           
static java.lang.reflect.Method getMethod(java.lang.Integer offset)
           
 void LibInitAPCS_32(Environment env)
           
 void LibInitAPCS_R(Environment env)
          Initialise the Shared C Library stubs.
 Stub[] libInitAPCS_R(int chunkId)
           
 
Methods inherited from class com.tapina.robe.module.Module
getBytes, getHelp, getName, getSize, setSize
 
Methods inherited from class com.tapina.robe.runtime.Block
getAddress, setAddress
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FILE_DESCRIPTOR_SIZE

public static final int FILE_DESCRIPTOR_SIZE
See Also:
Constant Field Values
Method Detail

getInstance

public static SharedCLibrary getInstance()

getBase

public static int getBase()

getMethod

public static java.lang.reflect.Method getMethod(java.lang.Integer offset)
                                          throws java.lang.NoSuchMethodException
Throws:
java.lang.NoSuchMethodException

LibInitAPCS_R

public void LibInitAPCS_R(Environment env)
Initialise the Shared C Library stubs.

Parameters:
env - IN: R0 points to list of stub chunks; OUT: R0 = R2, R2 = R1 + (R6 >> 16), R6 = 6
  0: Chunk ID (0 = kernel, 1 = C library, -1 = end of list)
  4: Pointer to start of stub list
  8: Pointer to end of stub list
  12: Pointer to workspace for statics (C library only)
  16: reserved
 
The static workspace contains:
  0x000: errno
  0x004: stdin
  0x02c: stdout
  0x054: stderr
  0x290: ctype
 
A RISC OS file record looks like:
 {
  WORD __ptr;
  WORD __icnt;
  WORD __ocnt;
  WORD __flag;
  WORD __base;
  WORD __file;
  WORD __pos;
  WORD __bufsiz;
  WORD __signature;
  FILE *real;
 }
 
The stub list is a set of instructions which implement the desired function.

LibInitAPCS_32

public final void LibInitAPCS_32(Environment env)

libInitAPCS_R

public Stub[] libInitAPCS_R(int chunkId)


Copyright © 2003-2005 . All Rights Reserved.