Changeset 3462 for trunk/sources/HeuristicLab.Encodings.SymbolicExpressionTreeEncoding/3.3/Compiler/Instruction.cs
- Timestamp:
- 04/21/10 15:21:34 (14 years ago)
- Location:
- trunk/sources/HeuristicLab.Encodings.SymbolicExpressionTreeEncoding/3.3/Compiler
- Files:
-
- 1 added
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Encodings.SymbolicExpressionTreeEncoding/3.3/Compiler/Instruction.cs
r3456 r3462 26 26 using System.Collections.Generic; 27 27 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding; 28 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding. GeneralSymbols;28 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Symbols; 29 29 30 namespace HeuristicLab.Encodings.SymbolicExpressionTreeEncoding { 31 public enum CodeSymbol : byte { 32 Add, 33 Sub, 34 Mul, 35 Div, 36 Call, 37 Arg, 38 Values, 39 Dynamic 40 }; 30 namespace HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Compiler { 31 // total size of this struct should be small to improve cache access while executing the code 32 // should be aligned to 8/16/32 byte 33 // size = 4(8) + 1 + 1 + 2 = 8 (12) 41 34 public struct Instruction { 35 // the tree node can hold additional data that is necessary for the execution of this instruction 36 public SymbolicExpressionTreeNode dynamicNode; 37 // op code of the function that determines what operation should be executed 38 public byte opCode; 39 // number of arguments of the current instruction 42 40 public byte nArguments; 43 public CodeSymbol symbol; 44 public short iArg0; 45 public SymbolicExpressionTreeNode dynamicNode; 41 // an optional short value (addresses for calls, argument index for arguments) 42 public ushort iArg0; 46 43 } 47 44 }
Note: See TracChangeset
for help on using the changeset viewer.