base.isa (12110:c24ee249b8ba) base.isa (12234:78ece221f9f5)
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

--- 551 unchanged lines hidden (view full) ---

560}};
561
562output exec {{
563 /// Check "FP enabled" machine status bit. Called when executing any FP
564 /// instruction.
565 /// @retval Full-system mode: NoFault if FP is enabled, FpDisabled
566 /// if not. Non-full-system mode: always returns NoFault.
567 static inline Fault
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

--- 551 unchanged lines hidden (view full) ---

560}};
561
562output exec {{
563 /// Check "FP enabled" machine status bit. Called when executing any FP
564 /// instruction.
565 /// @retval Full-system mode: NoFault if FP is enabled, FpDisabled
566 /// if not. Non-full-system mode: always returns NoFault.
567 static inline Fault
568 checkFpEnableFault(CPU_EXEC_CONTEXT *xc)
568 checkFpEnableFault(ExecContext *xc)
569 {
570 if (FullSystem) {
571 PSTATE pstate = xc->readMiscReg(MISCREG_PSTATE);
572 if (pstate.pef && xc->readMiscReg(MISCREG_FPRS) & 0x4) {
573 return NoFault;
574 } else {
575 return std::make_shared<FpDisabled>();
576 }
577 } else {
578 return NoFault;
579 }
580 }
581 static inline Fault
569 {
570 if (FullSystem) {
571 PSTATE pstate = xc->readMiscReg(MISCREG_PSTATE);
572 if (pstate.pef && xc->readMiscReg(MISCREG_FPRS) & 0x4) {
573 return NoFault;
574 } else {
575 return std::make_shared<FpDisabled>();
576 }
577 } else {
578 return NoFault;
579 }
580 }
581 static inline Fault
582 checkVecEnableFault(CPU_EXEC_CONTEXT *xc)
582 checkVecEnableFault(ExecContext *xc)
583 {
584 return std::make_shared<VecDisabled>();
585 }
586}};
587
588
583 {
584 return std::make_shared<VecDisabled>();
585 }
586}};
587
588