harpoon.Analysis.Realtime
Class RealtimeAllocationStrategy
java.lang.Object
harpoon.Backend.Runtime1.AllocationStrategy
harpoon.Backend.Runtime1.MallocAllocationStrategy
harpoon.Analysis.Realtime.RealtimeAllocationStrategy
- All Implemented Interfaces:
- Serializable
public class RealtimeAllocationStrategy
- extends MallocAllocationStrategy
RealtimeAllocationStrategy
makes all memory allocations to go through
RTJ_malloc
. If DEBUG_REF is turned on, then it calls
RTJ_malloc_ref(size, fileNumber, "fileName")
. The const char* "fileName"
must be emitted in a separate area, so emitStrings must be called later in the
file to emit that data.
- Author:
- Wes Beebee <wbeebee@mit.edu>
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RealtimeAllocationStrategy
public RealtimeAllocationStrategy(Frame f)
- Creates a
RealtimeAllocationStrategy
.
memAlloc
public Exp memAlloc(TreeFactory tf,
HCodeElement src,
DerivationGenerator dg,
AllocationInformation.AllocationProperties ap,
Exp length)
- Produces the Tree code corresponding to a memory allocation.
- Overrides:
memAlloc
in class MallocAllocationStrategy
stringLabel
public static Label stringLabel(String s)
- Return a label corresponding to the string s.
Available only if DEBUG_REF is turned on.
emitStrings
public static Stm emitStrings(TreeFactory tf,
HCodeElement src)
- Emit all of the const char*'s used so far in the file and flush the list.