base.isa (12104:edd63f9c6184) | base.isa (12106:7784fac1b159) |
---|---|
1// Copyright (c) 2006-2007 The Regents of The University of Michigan 2// All rights reserved. 3// 4// Redistribution and use in source and binary forms, with or without 5// modification, are permitted provided that the following conditions are 6// met: redistributions of source code must retain the above copyright 7// notice, this list of conditions and the following disclaimer; 8// redistributions in binary form must reproduce the above copyright --- 276 unchanged lines hidden (view full) --- 285 void 286 SparcStaticInst::printReg(std::ostream &os, RegId reg) const 287 { 288 const int MaxGlobal = 8; 289 const int MaxOutput = 16; 290 const int MaxLocal = 24; 291 const int MaxInput = 32; 292 const int MaxMicroReg = 40; | 1// Copyright (c) 2006-2007 The Regents of The University of Michigan 2// All rights reserved. 3// 4// Redistribution and use in source and binary forms, with or without 5// modification, are permitted provided that the following conditions are 6// met: redistributions of source code must retain the above copyright 7// notice, this list of conditions and the following disclaimer; 8// redistributions in binary form must reproduce the above copyright --- 276 unchanged lines hidden (view full) --- 285 void 286 SparcStaticInst::printReg(std::ostream &os, RegId reg) const 287 { 288 const int MaxGlobal = 8; 289 const int MaxOutput = 16; 290 const int MaxLocal = 24; 291 const int MaxInput = 32; 292 const int MaxMicroReg = 40; |
293 RegIndex reg_idx = reg.regIdx; 294 if (reg.regClass == IntRegClass) { | 293 RegIndex reg_idx = reg.index(); 294 if (reg.isIntReg()) { |
295 // If we used a register from the next or previous window, 296 // take out the offset. 297 while (reg_idx >= MaxMicroReg) 298 reg_idx -= MaxMicroReg; 299 if (reg_idx == FramePointerReg) 300 ccprintf(os, "%%fp"); 301 else if (reg_idx == StackPointerReg) 302 ccprintf(os, "%%sp"); --- 28 unchanged lines hidden (view full) --- 331 case 6: 332 ccprintf(os, "%%otherwin"); 333 break; 334 case 7: 335 ccprintf(os, "%%wstate"); 336 break; 337 } 338 } | 295 // If we used a register from the next or previous window, 296 // take out the offset. 297 while (reg_idx >= MaxMicroReg) 298 reg_idx -= MaxMicroReg; 299 if (reg_idx == FramePointerReg) 300 ccprintf(os, "%%fp"); 301 else if (reg_idx == StackPointerReg) 302 ccprintf(os, "%%sp"); --- 28 unchanged lines hidden (view full) --- 331 case 6: 332 ccprintf(os, "%%otherwin"); 333 break; 334 case 7: 335 ccprintf(os, "%%wstate"); 336 break; 337 } 338 } |
339 } else if (reg.regClass == FloatRegClass) { | 339 } else if (reg.isFloatReg()) { |
340 ccprintf(os, "%%f%d", reg_idx); 341 } else { 342 switch (reg_idx) { 343 case MISCREG_ASI: 344 ccprintf(os, "%%asi"); 345 break; 346 case MISCREG_FPRS: 347 ccprintf(os, "%%fprs"); --- 236 unchanged lines hidden --- | 340 ccprintf(os, "%%f%d", reg_idx); 341 } else { 342 switch (reg_idx) { 343 case MISCREG_ASI: 344 ccprintf(os, "%%asi"); 345 break; 346 case MISCREG_FPRS: 347 ccprintf(os, "%%fprs"); --- 236 unchanged lines hidden --- |