10 August 2016, 11:36 | #41 |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
|
10 August 2016, 14:01 | #42 | ||||||||
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
|
||||||||
10 August 2016, 20:55 | #43 |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
|
10 August 2016, 23:53 | #44 | |
Registered User
Join Date: Jun 2010
Location: PL?
Posts: 2,859
|
Quote:
in fact this is one of the most important instructions (common operations in DSP world) - hope this can open more advanced DSP possibilities for developers... Adding to this circular buffer addressing and reverse order addressing may remove necessity to use external DSP. |
|
11 August 2016, 12:53 | #45 |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
FMA is useful in a whole range of contexts other than DSP, it can be used in 3D graphics to do all sorts of vector arithmetic: dot products, matrix multiplication..
|
11 August 2016, 16:36 | #46 | |
Registered User
Join Date: Jun 2010
Location: PL?
Posts: 2,859
|
Quote:
I think that few instructions together with repeat instruction(s) may be highly beneficial for lack of hardware functionality i.e. virtualizing hardware in some form of the software but efficient DMA-like behaviour - substitute for lack of dedicated hardware. |
|
11 August 2016, 19:21 | #47 |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
DSP = Digital Signal Processing ?
anyway i kind of fell like this sort of stream processing could be done better off-chip, like some kind of blitter. |
11 August 2016, 20:22 | #48 | |||||||
Banned
Join Date: Jan 2010
Location: Kansas
Posts: 1,284
|
Unfortunately .
Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
The most important aspect of the hint bit is that it is practically free. Also, nobody has to use it unless they want to. |
|||||||
11 August 2016, 20:28 | #49 | |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
Quote:
All the condition codes also have an "opposite" condition code, don't they? GE <> LT, CC <> CS &c... so if you want a branch "reversed" without having to change the actual direction of the branch and the resultant spaghetti, you can just use the opposite condition code instead, right? I don't see the problem here. I do see the problem of compilers not being able to tell at compile time whether a branch is likely to be taken or not... whichever technique is used i suspect it is only of use to ASM coders. |
|
11 August 2016, 21:03 | #50 | ||||
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
Quote:
Quote:
May i see the actual code ? Quote:
Another problem is that the memory must be able to fulfill the bandwidth requirements. If some work is made at copymem speeds, the number of inner instructions doesn't count much. Quote:
I wouldn't use it as an asm programmer and i doubt any compiler will. |
||||
11 August 2016, 21:43 | #51 | ||||
Banned
Join Date: Jan 2010
Location: Kansas
Posts: 1,284
|
Quote:
Yes, I had added FMADD/FMSUB evaluation instructions to the ISA worded vaguely. The purpose of FMA is clear enough for me but the usefulness on the 68k FPU is in question. The purpose of FMA is to get better accuracy faster for some algorithms. The 68k FPU calculates in extended precision which means calculations should have more accuracy than double precision FMA gives. It is faster to do the FMA intermediate round though. There is software which uses FMA and expects FMA so it would be nice to give them FMA. Implementing FMA in extended precision would give more accuracy yet for the same algorithms. It may shorten some floating point math support algorithms. There is a cost to FMA though. It needs 3 read ports and 1 write port which is more expensive than most instructions and more encoding space than most instructions. I'm not sure the best way to implement or use FMA on a 68k FPU and the FMSUB may be unnecessary. I updated the ISA on the first post to specify an IEEE 754 fused multiply-add for FMADD/FMSUB but it is still for evaluation. I have FDIM, FSIGN, FMIN and FMAX documented as C99 function compatible hardware instructions which I believe would be good for DSP, 3D and general purpose uses. They are simple, common enough for general purpose use, easy to use and make compiler support easier. Quote:
Quote:
Quote:
P.S. I added 2 new evaluation addressing modes which give (d32,PC) and (d24,PC,Rn.Size*Scale). The encodings are a word shorter than the Full Extension Word encodings and should be significantly faster to decode. I did not add the new addressing modes to any instructions in the documentation nor did I give any info that these should be preferred where possible. I updated the ISA docs in the first post of this thread. Last edited by matthey; 11 August 2016 at 21:57. |
||||
11 August 2016, 22:22 | #52 |
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
|
11 August 2016, 22:57 | #53 |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
i'll be honest i never really liked the Full Extension Word addressing modes anyway, you need to read the first extension word to know if it is Full or Brief, so you need to look in two or even three different words to know the full length of the instruction. Not very nice. Oh well.
Any (d32,An) and (d24,An,Rn.Size*Scale) ? |
12 August 2016, 01:28 | #54 | |||||
Banned
Join Date: Jan 2010
Location: Kansas
Posts: 1,284
|
Quote:
TLSFMem you would have to disassemble but it uses many different variations of BFFFO. My builtin.lib use is rather simple. Code:
clz16: bfffo d0{16:16},d0 Quote:
Quote:
Quote:
1) compile the program with -pg to turn on profiling 2) run the program to create a profile 3) compile with -fprofile-use=<profile_path> to use the profile Step #3 turns on -fbranch-probabilities which is what optimizes branches. This is where the hint bit would be set if supported. A programmer might want to take a look at the profile with gprof to look for those nasty branches also. Yes. Absolutely. Where do I use a bit which changes the size of an instruction or split an instruction encoding into multiple sizes? Some of my encodings may be ugly but I hope none of them are dirty. I did fix DBcc.L to your encoding suggestion but it was only ugly and not dirty before. Quote:
No. It is not possible the way I encoded them. (d16,An) uses EA mode/register of 101 reg (d8,An,Rn.Size*Scale) uses 110 reg (bd,An,Rn.Size*Scale) uses 110 reg (d16,PC) uses EA mode/register of 111 010 (d8,PC,Rn.Size*Scale) uses 111 011 (bd,PC,Rn.Size*Scale) uses 111 011 (d32,PC) uses 111 110 (d24,PC,Rn.Size*Scale) uses 111 111 There were 2 free modes but there is no room to encode a register. This is basically how meynaf suggested to encode (d32,PC) but I used a different slot as his used my OP.L #data.w,Dn addressing mode and this is more consistent since I added (d24,PC,Rn.Size*Scale) as well. These encodings seem natural and are very easy to decode. The instruction length can be determined from the instruction word which is better even than (d8,An,Rn.Size*Scale) which requires looking at 2 words. |
|||||
12 August 2016, 10:30 | #55 | ||||
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
Quote:
Code:
bfextu d0{16:16},d0 ffo d0 You're using bfffo because it's there, but you wouldn't have asked for it if it weren't. Anyway we have it now, so unless we go the incompatible way this is useless talk. Quote:
Quote:
Quote:
In addition i don't differentiate ugly and dirty. For me if it's ugly, it's dirty. Anything that adds special cases is to be avoided if possible. By having SELcc move the condition field in an unusual position you create a special case. By adding the hint bit you change the way PC-relative displacements are interpreted but not always. By adding an addressing mode for short displacements you add a mode that's only valid in a few cases (i see the regular immediate addr mode as a bad choice as well). |
||||
12 August 2016, 11:09 | #56 | ||
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
Quote:
Quote:
|
||
12 August 2016, 13:13 | #57 |
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
You think you've spotted a contradiction ?
It's not all black and white, you see. I won't let a small inconsistency reduce the usefulness, hence the unsigned An.B (and if we had d8(An,Dn.B) the d8 would be signed but Dn.B unsigned). I don't see SELcc as really useful. I don't see the hint bit as useful at all. I am not against short immediates but against the way they are encoded. So i maintain everything. I care more about usefulness than consistency and anything that adds special cases is to be avoided if possible. |
12 August 2016, 13:46 | #58 | |
Glastonbridge Software
Join Date: Jan 2012
Location: Edinburgh/Scotland
Posts: 2,243
|
I don't much care for the word "contradiction", i prefer to call things a puzzle, or paradox.
Quote:
But do tell me what exactly is the use of a byte sized address. |
|
12 August 2016, 17:02 | #59 | |||
son of 68k
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,351
|
Quote:
Quote:
Bugs causing jumps to bogus addresses, which end up into data such as text, with all these 6x codes, is a common cause for 80000003 errors. I've already warned about the use of this bit, which would break any program using an odd address branch to deliberately trigger an exception. Quote:
Remember that i am for more data uses for An registers - as i'm quite often out of data regs, but more rarely of address regs. I've even used address regs to represent R,G,B values If you don't like the data/address register split, you should understand the use for this quite easily. |
|||
12 August 2016, 19:51 | #60 | |
Registered User
Join Date: Jun 2010
Location: PL?
Posts: 2,859
|
Quote:
Yes, this DSP... hope you not consider matrix multiplication as non DSP task... same for dot product - in fact lot of graphical hardware was build around DSP. DSP is not only audio processing. And off CPU - yes but his add complexity and also usually is outdated (blitter 30 years ago was breakthrough - today most of CPU's are faster performing those OP's by software - as such i think adding some features that will improve CPU performance as pseudo HW is right direction) |
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
BOOM (DOOM Enhanced) port to 68k | NovaCoder | News | 155 | 05 May 2023 12:26 |
ISA Ethernet Cards | jmmijo | support.Hardware | 13 | 03 February 2015 11:04 |
Any ISA Mach64 Information? | CU_AMiGA | support.Hardware | 21 | 09 September 2007 22:17 |
Help converting an 8bit ISA slot to 16bit ISA slot | Smiley | support.Hardware | 4 | 25 April 2006 11:20 |
A2000 ISA slots | Unknown_K | support.Hardware | 1 | 20 March 2005 09:48 |
|
|