On Saturday, 1 March 2014 at 02:59:37 UTC, Mike wrote:
On Friday, 28 February 2014 at 21:18:05 UTC, Timo Sintonen wrote:
On Wednesday, 8 January 2014 at 19:13:36 UTC, Timo Sintonen wrote:
On Wednesday, 8 January 2014 at 15:52:25 UTC, Johannes Pfau wrote:


Stupid question, but are C++ exceptions working for you? I think we don't change anything inthe compiler related to exception handling, so if C++ worked and D didn't it could only be a problem with the runtime
code?


I investigated this a little. It seems that the processor gets a fault interrupt when calling _Unwind_RaiseException in _d_throw. The status bits indicate an invalid instruction code. When looking at the disassembly I see that the call is a blx instruction with address. In Cortex-m4 blx can only take a register argument.
Is this a bug in gdc or gcc?

blx can also take a label.  Are you sure it's an address and not
a label?

According to the instruction card
http://infocenter.arm.com/help/topic/com.arm.doc.qrc0006e/QRC0006_UAL16.pdf
blx with label is valid in thumb instruction set. But it is a 32
bit instruction so I think it does not exist in any thumb only
processors.

Here we can see it is not valid in M4:
http://infocenter.arm.com/help/topic/com.arm.doc.dui0553a/BABEFHAE.html

Reply via email to