类 PeepholeEditor

  • 所有已实现的接口:
    AttributeVisitor

    public class PeepholeEditor
    extends java.lang.Object
    implements AttributeVisitor
    This AttributeVisitor lets a given instruction visitor edit the code attributes that it visits. The instruction visitor can use a given (optional) branch target finder and code attribute editor, which this class sets up and applies, for convenience.
    • 构造器详细资料

      • PeepholeEditor

        public PeepholeEditor​(CodeAttributeEditor codeAttributeEditor,
                              InstructionVisitor instructionVisitor)
        Creates a new PeepholeEditor.
        参数:
        codeAttributeEditor - the code attribute editor that will be reset and then executed.
        instructionVisitor - the instruction visitor that performs peephole optimizations using the above code attribute editor.
      • PeepholeEditor

        public PeepholeEditor​(BranchTargetFinder branchTargetFinder,
                              CodeAttributeEditor codeAttributeEditor,
                              InstructionVisitor instructionVisitor)
        Creates a new PeepholeEditor.
        参数:
        branchTargetFinder - branch target finder that will be initialized to indicate branch targets in the visited code.
        codeAttributeEditor - the code attribute editor that will be reset and then executed.
        instructionVisitor - the instruction visitor that performs peephole optimizations using the above code attribute editor.