Commit Graph

2 Commits (5d9acc45e88db40f45b6027819792783dde8e14d)
 

Author SHA1 Message Date
jzigman 5d9acc45e8 BLOAT made use of a special instruction called a 'Label' this instruction denoted the target of a jump, exception handler, or the start and end of a try catch block (the start of a basic block). BCEL has no such instruction, however Labels can be emulated by setting a Label attribute to InstructionHandles and creating a NOP instruction. For Peephole this would work but I wanted to allow Peephole to be run on code that had not been generated using CodeGenerator. For this reason when calling transform on Peephole there is a flag to indicate whether Labels have been set or not. If Labels have not been set a call to FlowGraph.buildBLOATInstructionList(method) is performed. This only sets the Label attribute in InstructionHandles it does not create the NOP instructions. 18 years ago
jzigman 7cd141f28e Initial revision 18 years ago