Classes | |
struct | littlefoot::NativeFunction |
Defines a native function that the program can call. More... | |
struct | littlefoot::Program |
A reference to a block of memory which contains a complete program. More... | |
struct | littlefoot::Runner< programAndHeapSpace, stackAndGlobalsSpace > |
Loads a program, and lets the user execute its functions. More... | |
struct | littlefoot::Runner< programAndHeapSpace, stackAndGlobalsSpace >::FunctionExecutionContext |
Namespaces | |
littlefoot | |
Macros | |
#define | LITTLEFOOT_DEBUG_TRACE 0 |
#define | LITTLEFOOT_DUMP_PROGRAM 0 |
#define | LITTLEFOOT_OP(name) name, |
#define | LITTLEFOOT_OP(name) case OpCode::name: s << #name; break; |
#define | LITTLEFOOT_OP(name) case OpCode::name: return 0; |
#define | LITTLEFOOT_OP_INT16(name) case OpCode::name: s << #name << " " << juce::String::toHexString ((int) readInt16 (prog)).paddedLeft ('0', 4); prog += 2; break; |
#define | LITTLEFOOT_OP_INT16(name) case OpCode::name: return 2; |
#define | LITTLEFOOT_OP_INT32(name) case OpCode::name: s << #name << " " << juce::String::toHexString ((int) readInt32 (prog)).paddedLeft ('0', 8); prog += 4; break; |
#define | LITTLEFOOT_OP_INT32(name) case OpCode::name: return 4; |
#define | LITTLEFOOT_OP_INT8(name) case OpCode::name: s << #name << " " << juce::String::toHexString ((int) *prog++).paddedLeft ('0', 2); break; |
#define | LITTLEFOOT_OP_INT8(name) case OpCode::name: return 1; |
#define | LITTLEFOOT_OPCODES(OP, OP_INT8, OP_INT16, OP_INT32) |
#define | LITTLEFOOT_PERFORM_OP(name) case OpCode::name: name(); break; |
#define | LITTLEFOOT_PERFORM_OP_INT16(name) case OpCode::name: name (readProgram16()); break; |
#define | LITTLEFOOT_PERFORM_OP_INT32(name) case OpCode::name: name (readProgram32()); break; |
#define | LITTLEFOOT_PERFORM_OP_INT8(name) case OpCode::name: name ((int8) *programCounter++); break; |
Typedefs | |
using | littlefoot::FunctionID = int16 |
using | littlefoot::int16 = signed short |
using | littlefoot::int32 = signed int |
using | littlefoot::int8 = signed char |
using | littlefoot::uint16 = unsigned short |
using | littlefoot::uint32 = unsigned int |
using | littlefoot::uint8 = unsigned char |
Enumerations | |
enum | littlefoot::OpCode : uint8 { littlefoot::OpCode::LITTLEFOOT_OP, littlefoot::OpCode::endOfOpcodes } |
enum | littlefoot::Type : uint8 { littlefoot::Type::void_ = 'v', littlefoot::Type::int_ = 'i', littlefoot::Type::bool_ = 'b', littlefoot::Type::float_ = 'f' } |
Available value types. More... | |
Variables | |
const int | littlefoot::numBytesInType = 4 |
#define LITTLEFOOT_DEBUG_TRACE 0 |
#define LITTLEFOOT_DUMP_PROGRAM 0 |
#define LITTLEFOOT_OP | ( | name | ) | name, |
#define LITTLEFOOT_OP | ( | name | ) | case OpCode::name: s << #name; break; |
#define LITTLEFOOT_OP | ( | name | ) | case OpCode::name: return 0; |
#define LITTLEFOOT_OP_INT16 | ( | name | ) | case OpCode::name: s << #name << " " << juce::String::toHexString ((int) readInt16 (prog)).paddedLeft ('0', 4); prog += 2; break; |
#define LITTLEFOOT_OP_INT16 | ( | name | ) | case OpCode::name: return 2; |
#define LITTLEFOOT_OP_INT32 | ( | name | ) | case OpCode::name: s << #name << " " << juce::String::toHexString ((int) readInt32 (prog)).paddedLeft ('0', 8); prog += 4; break; |
#define LITTLEFOOT_OP_INT32 | ( | name | ) | case OpCode::name: return 4; |
#define LITTLEFOOT_OP_INT8 | ( | name | ) | case OpCode::name: s << #name << " " << juce::String::toHexString ((int) *prog++).paddedLeft ('0', 2); break; |
#define LITTLEFOOT_OP_INT8 | ( | name | ) | case OpCode::name: return 1; |
#define LITTLEFOOT_OPCODES | ( | OP, | |
OP_INT8, | |||
OP_INT16, | |||
OP_INT32 | |||
) |
#define LITTLEFOOT_PERFORM_OP | ( | name | ) | case OpCode::name: name(); break; |
#define LITTLEFOOT_PERFORM_OP_INT16 | ( | name | ) | case OpCode::name: name (readProgram16()); break; |
#define LITTLEFOOT_PERFORM_OP_INT32 | ( | name | ) | case OpCode::name: name (readProgram32()); break; |
#define LITTLEFOOT_PERFORM_OP_INT8 | ( | name | ) | case OpCode::name: name ((int8) *programCounter++); break; |