|
|
6.34 CompiledCode
- Defined in namespace Smalltalk
- Category: Language-Implementation
- I represent code that has been compiled. I am an abstract
superclass for blocks and methods
6.34.1 CompiledCode class: cache flushing
- flushTranslatorCache
- Answer any kind of cache mantained by a just-in-time code translator in the virtual machine (if any). Do nothing for now.
6.34.2 CompiledCode class: instance creation
- newMethod: numBytecodes header: anInteger literals: literals
- Answer a new CompiledMethod with room for the given bytes and the given header
- newMethod: numBytecodes header: anInteger numLiterals: numLiterals
- Answer a new CompiledMethod with room for the given bytes and the given header
6.34.3 CompiledCode: accessing
- at: anIndex put: aBytecode
- Store aBytecode as the anIndex-th bytecode
- blockAt: anIndex
- Answer the CompiledBlock attached to the anIndex-th literal, assuming that the literal is a BlockClosure.
- bytecodeAt: anIndex
- Answer the anIndex-th bytecode
- bytecodeAt: anIndex put: aBytecode
- Store aBytecode as the anIndex-th bytecode
- flags
- Private - Answer the optimization flags for the receiver
- literalAt: anIndex
- Answer the anIndex-th literal
- literalAt: anInteger put: aValue
- Store aValue as the anIndex-th literal
- literals
- Answer `literals'.
- methodClass
- Answer the class in which the receiver is installed.
- methodClass: methodClass
- Set the receiver's class instance variable
- numArgs
- Answer the number of arguments for the receiver
- numLiterals
- Answer the number of literals for the receiver
- numTemps
- Answer the number of temporaries for the receiver
- primitive
- Answer the primitive called by the receiver
- selector
- Answer the selector through which the method is called
- selector: aSymbol
- Set the selector through which the method is called
- stackDepth
- Answer the number of stack slots needed for the receiver
6.34.4 CompiledCode: basic
- = aMethod
- Answer whether the receiver and aMethod are equal
- hash
- Answer an hash value for the receiver
- methodCategory
- Answer the method category
- methodCategory: aCategory
- Set the method category to the given string
- methodSourceCode
- Answer the method source code (a FileSegment or String or nil)
- methodSourceFile
- Answer the file where the method source code is stored
- methodSourcePos
- Answer the location where the method source code is stored in the methodSourceFile
- methodSourceString
- Answer the method source code as a string
6.34.5 CompiledCode: copying
- deepCopy
- Answer a deep copy of the receiver
6.34.6 CompiledCode: debugging
- breakAtLine: lineNumber
- This method's functionality has not been implemented yet.
- breakpointAt: byteIndex
- Put a break-point at the given bytecode
- inspect
- Print the contents of the receiver in a verbose way.
- removeBreakpointAt: byteIndex
- Remove the break-point at the given bytecode (don't fail if none was set
6.34.7 CompiledCode: printing
- printOn: aStream
- Print the receiver's class and selector on aStream
6.34.8 CompiledCode: testing accesses
- accesses: instVarIndex
- Answer whether the receiver access the instance variable with the given index
- containsLiteral: anObject
- Answer if the receiver contains a literal which is equal to anObject.
- hasBytecode: byte between: firstIndex and: lastIndex
- Answer whether the receiver includes the `byte' bytecode in any of the indices between firstIndex and lastIndex.
- jumpDestinationAt: anIndex
- Answer where the jump at bytecode index `anIndex' lands
- refersTo: anObject
- Answer whether the receiver refers to the given object
6.34.9 CompiledCode: translation
- discardTranslation
- Flush the just-in-time translated code for the receiver (if any).
|