crashanalysercmd/PerfToolsSharedLibraries/Engine/SymbianInstructionLib/Arm/Instructions/Thumb/Branching/Thumb_Branch_Conditional.cs
changeset 0 818e61de6cd1
equal deleted inserted replaced
-1:000000000000 0:818e61de6cd1
       
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 * 
       
    14 * Description:
       
    15 *
       
    16 */
       
    17 using System;
       
    18 using System.Collections.Generic;
       
    19 using System.Text;
       
    20 using SymbianStructuresLib.Arm.Registers;
       
    21 using SymbianStructuresLib.Arm.Instructions;
       
    22 using SymbianInstructionLib.Arm.Instructions.Common;
       
    23 
       
    24 namespace SymbianInstructionLib.Arm.Instructions.Thumb.Branching
       
    25 {
       
    26     [ArmRef( "A7.1.13 B (1)", "B<cond> <target_address>" )]
       
    27     public class Thumb_Branch_Conditional : Thumb_Branch_Immediate
       
    28     {
       
    29         #region Constructors
       
    30         public Thumb_Branch_Conditional()
       
    31         {
       
    32             base.SetMask( "1101" + "####" + "########" );
       
    33         }
       
    34         #endregion
       
    35 
       
    36         #region API
       
    37         #endregion
       
    38 
       
    39         #region Properties
       
    40         public override int BranchOffset
       
    41         {
       
    42             get
       
    43             {
       
    44                 int ret = ThumbInstructionUtils.SignExtend8BitTo32Bit( base.AIRawValue & 0xFF );
       
    45                 return ret;
       
    46             }
       
    47         }
       
    48         #endregion
       
    49 
       
    50         #region From ArmBaseInstruction
       
    51         protected override void OnRawValueAssigned()
       
    52         {
       
    53             base.OnRawValueAssigned();
       
    54             base.AIConditionCode = (TArmInstructionCondition) (TArmInstructionCondition) base.AIRawValue[ 11, 8 ].ToUInt();
       
    55         }
       
    56         #endregion
       
    57 
       
    58         #region Internal methods
       
    59         #endregion
       
    60 
       
    61         #region Data members
       
    62         #endregion
       
    63     }
       
    64 }
       
    65