![]() | ||
| Home | SwiftX Archive | SwiftForth Archive | |

Hi Kevin
I will make a cut at an indirect answer to your question. Since the structured loop words do not support the 'delayed branch' in your processor you may need to extend the compiler to make new versions of these words. The key will be to base these words on the code in C:\ForthInc\SWIFTFORTH\SRC\KERNEL\STRUCT.F
You need to learn about >RESOLVE and <RESOLVE
In fact, these words do the branch address resolution that you need, and require HERE to push the target address on the data stack at the appropriate point in the word definition. You could use these words directly in assembler code to form your structures but using structured compiler words will ultimately be safer and faster.
You may want to give these new words slightly different names from the core words. You may want to use the same names if you always want to use delayed branches.
If You extend the compiler will need to understand the COMPILER vocabulary mechanism in SWIFTX. See C:\ForthInc\SwiftX\Src\COMP.F Note that there are versions of IF for the native system and the target system. These use AHEAD, and BACK, instead of <RESOLVE AND >RESOLVE.
Last, check out the extended structures discussed in STRUCT.F but not in the manuals. It is always a learning experience to read the source code! FORTH.INC does this internal documentation very well and it is a treasure that you should explore.
Good Luck, Ken B
At 08:52 AM 10/6/2006, you wrote:
>> The question had to do with the fact that deferred branches were
>> not supported by IF THEN BEGIN UNTIL, though I suppose that my
>> e-mail was not clear about that because I restructured it right
>> before pressing send.
>>
>> Yes, I do realize that IF THEN and BEGIN UNTIL make labels and
>> forward references unnecessary, but that does not give me a
>> mechanism to do deferred branching on the DSP without using
>> PC-relative branches.
>
>The TI TMS320C3X manual calls these instructions "delayed branch"
>instructions rather than "deferred branch" instructions. I read
>the "deferred" term used first and it stuck, so I need to reflash
>that part of my memory.
>
>--
>Kevin R. Bulgrien
>Design and Development Engineer
>
Dr. Kenneth B Butterfield
phone: 505 667 8944
PO Box 1663
ms J562
Los Alamos National Laboratory
Los Alamos New Mexico 87545
"I do not trust a computer that I am not carrying!"
----------------------------------------------------------------------
swiftx_at_forth.com The SwiftX programming discussion email list
To unsubscribe, send subject "unsubscribe" to swiftx-request_at_forth.com
For list command help, send subject "help" to swiftx-request_at_forth.com
Message archives are located at http://www.forth.com/archive/swiftx
----------------------------------------------------------------------
This list is a forum for SwiftX users. For product support and bug
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Wed Oct 11 2006 - 09:28:39 PDT
This archive was generated by hypermail 2.2.0 : Tue Dec 02 2008 - 03:04:51 PST