001 /* 002 * This file is part of the Jikes RVM project (http://jikesrvm.org). 003 * 004 * This file is licensed to You under the Eclipse Public License (EPL); 005 * You may not use this file except in compliance with the License. You 006 * may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/eclipse-1.0.php 009 * 010 * See the COPYRIGHT.txt file distributed with this work for information 011 * regarding copyright ownership. 012 */ 013 package org.jikesrvm.compilers.opt.ir; 014 015 import org.jikesrvm.ArchitectureSpecific.CodeArray; 016 import org.jikesrvm.compilers.opt.regalloc.LinearScan; 017 import org.jikesrvm.osr.VariableMap; 018 019 /** 020 * Wrapper class around IR info that is valid on the MIR 021 */ 022 public final class MIRInfo { 023 024 /** 025 * The generated machinecodes produced by this compilation of 'method' 026 */ 027 public CodeArray machinecode; 028 029 /** 030 * Estimate produced by FinalMIRExpansion and used by 031 * Assembler to create code array; only meaningful on PowerPC 032 */ 033 public int mcSizeEstimate; 034 035 /** 036 * The IRMap for the method (symbolic GCMapping info) 037 */ 038 public GCIRMap gcIRMap; 039 040 public VariableMap osrVarMap; 041 /** 042 * The frame size of the current method 043 */ 044 public int FrameSize; 045 046 /** 047 * The number of floating point stack slots allocated. 048 * (Only used on IA32) 049 */ 050 public int fpStackHeight; 051 052 /** 053 * A basic block holding the call to Thread.threadSwitch for a 054 * prologue. 055 */ 056 public BasicBlock prologueYieldpointBlock = null; 057 058 /** 059 * A basic block holding the call to Thread.threadSwitch for an 060 * epilogue. 061 */ 062 public BasicBlock epilogueYieldpointBlock = null; 063 064 /** 065 * A basic block holding the call to Thread.threadSwitch for a 066 * backedge. 067 */ 068 public BasicBlock backedgeYieldpointBlock = null; 069 070 /** 071 * A basic block holding the call to yieldpointFromOsrOpt for an 072 * OSR invalidation. 073 */ 074 public BasicBlock osrYieldpointBlock = null; 075 076 /** 077 * Information needed for linear scan. 078 */ 079 public LinearScan.LinearScanState linearScanState = null; 080 081 public MIRInfo(IR ir) { 082 ir.compiledMethod.setSaveVolatile(ir.method.getDeclaringClass().hasSaveVolatileAnnotation()); 083 ir.compiledMethod.setOptLevel(ir.options.getOptLevel()); 084 } 085 086 }