⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 integer.lst

📁 MSP430 IAR project with FreeRTOS port.
💻 LST
📖 第 1 页 / 共 2 页
字号:
   \   000004   0812         PUSH.W  R8
   \   000006   2182         SUB.W   #0x4, SP
   \   000008   0A4C         MOV.W   R12, R10
    110          /* These variables are all effectively set to constants so they are volatile to
    111          ensure the compiler does not just get rid of them. */
    112          volatile portLONG lValue;
    113          portSHORT sError = pdFALSE;
   \   00000A   0B43         MOV.W   #0x0, R11
    114          volatile signed portBASE_TYPE *pxTaskHasExecuted;
    115          
    116          	/* Set a pointer to the variable we are going to set to true each
    117          	iteration.  This is also a good test of the parameter passing mechanism
    118          	within each port. */
    119          	pxTaskHasExecuted = ( volatile signed portBASE_TYPE * ) pvParameters;
   \   00000C   084A         MOV.W   R10, R8
    120          
    121          	/* Keep performing a calculation and checking the result against a constant. */
    122          	for( ;; )
    123          	{
    124          		/* Perform the calculation.  This will store partial value in
    125          		registers, resulting in a good test of the context switch mechanism. */
    126          		lValue = intgCONST1;
   \                     ??vCompeteingIntMathTask_0:
   \   00000E   B1407B000000 MOV.W   #0x7b, 0x0(SP)
   \   000014   81430200     MOV.W   #0x0, 0x2(SP)
    127          		lValue += intgCONST2;
   \   000018   B15047940000 ADD.W   #0x9447, 0x0(SP)
   \   00001E   B16003000200 ADDC.W  #0x3, 0x2(SP)
    128          
    129          		/* Yield in case cooperative scheduling is being used. */
    130          		#if configUSE_PREEMPTION == 0
    131          		{
    132          			taskYIELD();
    133          		}
    134          		#endif
    135          
    136          		/* Finish off the calculation. */
    137          		lValue *= intgCONST3;
   \   000024   2C41         MOV.W   0x0(SP), R12
   \   000026   1D410200     MOV.W   0x2(SP), R13
   \   00002A   3E40FDFF     MOV.W   #0xfffd, R14
   \   00002E   3F43         MOV.W   #0xffff, R15
   \   000030   B012....     CALL    #?Mul32
   \   000034   814C0000     MOV.W   R12, 0x0(SP)
   \   000038   814D0200     MOV.W   R13, 0x2(SP)
    138          		lValue /= intgCONST4;
   \   00003C   2C41         MOV.W   0x0(SP), R12
   \   00003E   1D410200     MOV.W   0x2(SP), R13
   \   000042   3E400700     MOV.W   #0x7, R14
   \   000046   0F43         MOV.W   #0x0, R15
   \   000048   B012....     CALL    #?DivMod32s
   \   00004C   814C0000     MOV.W   R12, 0x0(SP)
   \   000050   814D0200     MOV.W   R13, 0x2(SP)
    139          
    140          		/* If the calculation is found to be incorrect we stop setting the 
    141          		TaskHasExecuted variable so the check task can see an error has 
    142          		occurred. */
    143          		if( lValue != intgEXPECTED_ANSWER ) /*lint !e774 volatile used to prevent this being optimised out. */
   \   000054   B1901B770000 CMP.W   #0x771b, 0x0(SP)
   \   00005A   0420         JNE     ??vCompeteingIntMathTask_1
   \   00005C   B190FEFF0200 CMP.W   #0xfffe, 0x2(SP)
   \   000062   0124         JEQ     ??vCompeteingIntMathTask_2
    144          		{
    145          			sError = pdTRUE;
   \                     ??vCompeteingIntMathTask_1:
   \   000064   1B43         MOV.W   #0x1, R11
    146          		}
    147          
    148          		if( sError == pdFALSE )
   \                     ??vCompeteingIntMathTask_2:
   \   000066   0B93         CMP.W   #0x0, R11
   \   000068   D223         JNE     ??vCompeteingIntMathTask_0
    149          		{
    150          			/* We have not encountered any errors, so set the flag that show
    151          			we are still executing.  This will be periodically cleared by
    152          			the check task. */
    153          			portENTER_CRITICAL();
   \   00006A   32C2         DINT
   \   00006C   0343         NOP
   \   00006E   9253....     ADD.W   #0x1, &usCriticalNesting
    154          				*pxTaskHasExecuted = pdTRUE;
   \   000072   98430000     MOV.W   #0x1, 0(R8)
    155          			portEXIT_CRITICAL();
   \   000076   8293....     CMP.W   #0x0, &usCriticalNesting
   \   00007A   C927         JEQ     ??vCompeteingIntMathTask_0
   \   00007C   B253....     ADD.W   #0xffff, &usCriticalNesting
   \   000080   8293....     CMP.W   #0x0, &usCriticalNesting
   \   000084   C423         JNE     ??vCompeteingIntMathTask_0
   \   000086   32D2         EINT
   \   000088   C23F         JMP     ??vCompeteingIntMathTask_0
    156          		}
    157          
    158          		/* Yield in case cooperative scheduling is being used. */
    159          		#if configUSE_PREEMPTION == 0
    160          		{
    161          			taskYIELD();
    162          		}
    163          		#endif
    164          	}
    165          }
    166          /*-----------------------------------------------------------*/
    167          
    168          /* This is called to check that all the created tasks are still running. */

   \                                 In segment CODE, align 2
    169          portBASE_TYPE xAreIntegerMathsTaskStillRunning( void )
   \                     xAreIntegerMathsTaskStillRunning:
    170          {
    171          portBASE_TYPE xReturn = pdTRUE;
   \   000000   1C43         MOV.W   #0x1, R12
    172          portSHORT sTask;
    173          
    174          	/* Check the maths tasks are still running by ensuring their check variables 
    175          	are still being set to true. */
    176          	for( sTask = 0; sTask < intgNUMBER_OF_TASKS; sTask++ )
   \   000002   0E43         MOV.W   #0x0, R14
   \                     ??xAreIntegerMathsTaskStillRunning_0:
   \   000004   1E93         CMP.W   #0x1, R14
   \   000006   0C34         JGE     ??xAreIntegerMathsTaskStillRunning_1
    177          	{
    178          		if( xTaskCheck[ sTask ] == pdFALSE )
   \   000008   0F4E         MOV.W   R14, R15
   \   00000A   0F5F         RLA.W   R15
   \   00000C   8F93....     CMP.W   #0x0, xTaskCheck(R15)
   \   000010   0120         JNE     ??xAreIntegerMathsTaskStillRunning_2
    179          		{
    180          			/* The check has not incremented so an error exists. */
    181          			xReturn = pdFALSE;
   \   000012   0C43         MOV.W   #0x0, R12
    182          		}
    183          
    184          		/* Reset the check variable so we can tell if it has been set by
    185          		the next time around. */
    186          		xTaskCheck[ sTask ] = pdFALSE;
   \                     ??xAreIntegerMathsTaskStillRunning_2:
   \   000014   0F4E         MOV.W   R14, R15
   \   000016   0F5F         RLA.W   R15
   \   000018   8F43....     MOV.W   #0x0, xTaskCheck(R15)
    187          	}
   \   00001C   1E53         ADD.W   #0x1, R14
   \   00001E   F23F         JMP     ??xAreIntegerMathsTaskStillRunning_0
    188          
    189          	return xReturn;
   \                     ??xAreIntegerMathsTaskStillRunning_1:
   \   000020   3041         RET
    190          }

   \                                 In segment DATA16_C, align 1, align-sorted
   \                     `?<Constant "IntMath">`:
   \   000000   496E744D6174 DC8 "IntMath"
   \            6800        
    191          

   Maximum stack usage in bytes:

     Function                       CSTACK
     --------                       ------
     vCompeteingIntMathTask            12
     vStartIntegerMathTasks            14
       -> xTaskCreate                  14
     xAreIntegerMathsTaskStillRunning
                                        2


   Segment part sizes:

     Function/Label                 Bytes
     --------------                 -----
     xTaskCheck                        2
     vStartIntegerMathTasks           56
     vCompeteingIntMathTask          138
     xAreIntegerMathsTaskStillRunning
                                      34
     ?<Constant "IntMath">             8

 
 228 bytes in segment CODE
   8 bytes in segment DATA16_C
   2 bytes in segment DATA16_Z
 
 228 bytes of CODE  memory
   8 bytes of CONST memory
   2 bytes of DATA  memory

Errors: none
Warnings: 1

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -