Search found 178 matches

by agner
2024-02-17, 6:28:54
Forum: forwardcom forum
Topic: Fushed push with bounds check
Replies: 3
Views: 75

Re: Fushed push with bounds check

The addressing mode with bounds check works only if the array size is fixed and known at compile time. The push instruction will signal an error if writing to inaccessible memory. The push instruction is already quite complex at the hardware level. Adding still more complexity might be critical. It ...
by agner
2024-01-31, 6:51:29
Forum: forwardcom forum
Topic: Proposal for symbol lookup in the linker
Replies: 7
Views: 1627

Re: Proposal for symbol lookup in the linker

I don't know what happened with the "[redundant text removed]"
You posted the same text twice, that's why I removed it.
by agner
2024-01-30, 15:58:58
Forum: forwardcom forum
Topic: Proposal for symbol lookup in the linker
Replies: 7
Views: 1627

Re: Proposal for symbol lookup in the linker

Multi-entrypoint functions are possible in assembly code, but cannot be coded in high level language. They can be called from HLL code, though. I think you are asking for trouble if you want partially compatible libraries with multiple versions of the same function. ForwardCom tries to solve the pro...
by agner
2024-01-30, 14:11:52
Forum: forwardcom forum
Topic: Proposal for symbol lookup in the linker
Replies: 7
Views: 1627

Re: Proposal for symbol lookup in the linker

In my experience, dynamic linking is slow, not because of symbol lookup, but because the libraries are many and large. It is not uncommon for an application to load ten DLLs of 1 MB each, and use only 1 kB of each. It will load at least one memory page from each DLL, and usually more. This is a wast...
by agner
2024-01-29, 5:51:11
Forum: forwardcom forum
Topic: Proposal for symbol lookup in the linker
Replies: 7
Views: 1627

Re: Proposal for symbol lookup in the linker

Name hashing was actually used in the old OMF object file format used in DOS. This format was not very successful (mostly for other reasons). Some systems today use unsorted name tables, while ELF files often have both a sorted and an unsorted name table. ForwardCom is using sorted name tables and b...
by agner
2023-11-29, 5:57:43
Forum: forwardcom forum
Topic: Dot Product
Replies: 5
Views: 22988

Re: Dot Product

A cross product has 3 dimensions. It requires more permutations. Permutations and data movement across vector lanes are expensive in hardware. Therefore, I have no plans to implement an instruction with more dimensions than 2. Augmented multiplication is possible with FMA instructions: Y = a * b dY ...
by agner
2023-11-26, 8:21:43
Forum: forwardcom forum
Topic: SQRT or RSQRT - that is the question
Replies: 1
Views: 13113

Re: SQRT or RSQRT - that is the question

Existing instruction sets have several different instructions for fast reciprocal and fast rsqrt with different precisions. It will be a mess if different hardware implementations have different precision for the same instruction. Therefore, I think these have to be optional implementation-specific ...
by agner
2023-11-26, 8:09:03
Forum: forwardcom forum
Topic: Underflow/Overflow in mul_2pow
Replies: 2
Views: 13526

Re: Underflow/Overflow in mul_2pow

The main purpose of the mul_2pow instruction is to improve speed. x * 0.25 will take several clock cycles. With optimization on, the compiler or assembler can change x*0.25 to mul_2pow(x, -2) which takes only 1 clock cycle. It would be difficult to do this in a single clock cycle if you want underfl...
by agner
2023-11-26, 7:47:39
Forum: forwardcom forum
Topic: Rounding Mode
Replies: 2
Views: 13644

Re: Rounding Mode

I have added the rounding mode "odd if not exact" in the compress instruction because this is needed in a two step reduction: double precision -> single precision -> half precision. Other rounding modes can be added if they are needed. Do you have any good use cases for the rounding modes ...
by agner
2023-11-26, 7:33:52
Forum: forwardcom forum
Topic: Dot Product
Replies: 5
Views: 22988

Re: Dot Product

Damian, you need to use this instruction twice for a complex number multiplication or division. First, you calculate the real part of the product and place it in y0, where (y0,y1) is the result vector. Then you calculate the imaginary part and place it in y1, while retaining y0 by using (c0,c1) = (y...
by agner
2023-07-27, 5:11:22
Forum: forwardcom forum
Topic: First evidence of ForwardCom effectiveness
Replies: 1
Views: 15840

Re: First evidence of ForwardCom effectiveness

Congratulations with your thesis, Kulasko.
Officially, it is 'just' a bachelor thesis, but in reality it is the result of six years of work. A very impressive achievement!
Thank you for your work. I hope you will continue...
by agner
2023-03-18, 8:32:44
Forum: forwardcom forum
Topic: Should we build a ForwardCom organization?
Replies: 1
Views: 15409

Should we build a ForwardCom organization?

Do we need an organization to manage the ForwardCom project? Such an organization could help people get involved, organize online meetings and conferences, facilitate research projects, develop standards, etc. The idea of an organization came up as I was trying to find a solution to the problem of c...
by agner
2023-02-01, 5:57:39
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

@Moonchild It is too complex for a single instruction. It requires many additions and horizontal data transfer across vector lanes. The latency would depend on the vector length. People could propose a zillion other functions that they would like to implement in hardware, including elementary mathem...
by agner
2023-01-31, 9:19:39
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

@Moonchild:
Sum scan of an array is a complex instruction with long data-dependent latency. This would require microcode. ForwardCom avoids microcode.
by agner
2023-01-30, 6:53:28
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

Good idea, Hubert I have thought about a cheaper solution, though less universal. ForwardCom is intended to avoid memory fragmentation. In small systems and embedded systems you may not need demand paged memory. If you don't have demand paging you don't need to be able to recover from memory access ...
by agner
2023-01-26, 13:38:46
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

Moonchild wrote:
vector sum scan instruction
I don't understand what you mean. The manual explains how to make a horizontal vector sum.
by agner
2023-01-26, 13:35:39
Forum: forwardcom forum
Topic: Bit addressing
Replies: 8
Views: 31744

Re: Bit addressing

Moonchild wrote:
One-off bit operations
There are instructions for set, clear, toggle, and test a single bit or multiple bits. There is bit scan, popcount, and bitfield manipulation. What else do you need?
by agner
2023-01-24, 9:58:23
Forum: forwardcom forum
Topic: Softcore update
Replies: 0
Views: 23715

Softcore update

The FPGA softcore has now been developed to a stage where all integer instructions work. This includes complicated instructions such as: multiplication, multiplication high part, multiply and add, division with a choice of rounding modes, remainder, push/pop a sequence of registers with a choice of ...
by agner
2022-12-04, 15:13:13
Forum: forwardcom forum
Topic: Integer division by zero
Replies: 4
Views: 22727

Re: Integer division by zero

Hi Webenson What you propose is indeed the solution I have implemented. Performance counter number 16 will count various errors and show the code address where the first error occurred. This is a cheap solution to implement in hardware. Division by 0 gives INT_MAX, INT_MIN, or UINT_MAX. Returning 0 ...
by agner
2022-12-03, 6:31:31
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

You are right that speculation is quite expensive in terms of hardware. ForwardCom needs less speculation because there are no numerical error traps. A processor with out-of-order capabilities but no speculation might be attractive. (It could decode both sides of a 2-way branch to reduce pipeline bu...
by agner
2022-12-02, 8:02:12
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

Hubert, the idea of a priority hint makes sense. A NOP instruction has many unused bits that can be used as various hints. On the other hand, if the compiler knows which instructions should have high priority, it would simply put these instructions first. An out-of-order processor will reorder instr...
by agner
2022-12-02, 7:41:06
Forum: forwardcom forum
Topic: Integer division by zero
Replies: 4
Views: 22727

Re: Integer division by zero

Hubert, a % b = a will satisfy a % b == a - (a/b)*b in all cases. There is a modulo instruction, and it is easy to implement because the existing division hardware gives the remainder as well, whether you need it or not. I have considered to make division by 0 give 0, but this would increase the ris...
by agner
2022-11-27, 16:22:42
Forum: forwardcom forum
Topic: Integer division by zero
Replies: 4
Views: 22727

Integer division by zero

I have almost finished making the division hardware for the ForwardCom softcore (using a radix-4 division loop). Now I have to decide what to do with integer division by zero. I have tried to google what other microprocessors do with integer division by zero. X86 makes an error trap. ARM and PowerPC...
by agner
2022-10-23, 14:06:55
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Re: Proposals for next version

Thank you for your comments. Regarding speculative read The proposed speculative read should be a special instruction for this purpose. Advantages: no waste of RAM for padding space. Disadvantages: messy hardware logic; does not allow all addressing modes. The alternative is to insert a padding spac...
by agner
2022-10-17, 12:41:12
Forum: forwardcom forum
Topic: Proposals for next version
Replies: 16
Views: 87078

Proposals for next version

I am beginning to work on version 1.12 of ForwardCom. I have several proposals for changes that I will open up for discussion: 1. Speculative memory read I would like an option for reading from memory without causing a trap in case the address is invalid. A read from an illegal address should produc...