Forcing a Thumb address

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Forcing a Thumb address

ソリューションへジャンプ
707件の閲覧回数
ERussell
Contributor IV

I am working with a k60 using CW10.2. I would like to force a label in an assembly file to be at a thumb address, i.e. with the LSB set, but have not been able to do this.  Can anyone tell me how to do this?

 

Thanks.

0 件の賞賛
1 解決策
569件の閲覧回数
Nouchi
Senior Contributor II

Hi,

 

Cortex M processors only support thumb and thumb-2 instructions.

 http://www.arm.com/products/processors/cortex-m/cortex-m4-processor.php

 

元の投稿で解決策を見る

0 件の賞賛
3 返答(返信)
569件の閲覧回数
konrada
Contributor IV

Whether you need to add one to your code address depends on what instruction you use to jump there (B/BL vs BX/BLX), so adding the one to the label is dangerous.

 

What are you trying to do? 

0 件の賞賛
568件の閲覧回数
ERussell
Contributor IV

I was attempting to implement the QK Scheduler  portion of the Quantum Leaps QP code. There is a warning, at least for the GNU C compiler, to insure that the address of an assembly label is a thumb address in the PendSV_Handler routine. As it turned out there was no problem and the function is working correctly with no intervention on my part, so I assummed that the fist responder was correct.

 

Thanks for responding.

0 件の賞賛
570件の閲覧回数
Nouchi
Senior Contributor II

Hi,

 

Cortex M processors only support thumb and thumb-2 instructions.

 http://www.arm.com/products/processors/cortex-m/cortex-m4-processor.php

 

0 件の賞賛