Groups | Search | Server Info | Login | Register
Groups > comp.lang.forth > #134239
| From | minforth <minforth@gmx.net> |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: 3dup again |
| Date | 2025-10-03 11:09 +0200 |
| Message-ID | <mk9i5hFld65U1@mid.individual.net> (permalink) |
| References | <2025Sep30.183350@mips.complang.tuwien.ac.at> <mk5b0uFubm8U1@mid.individual.net> <68de4aaa@news.ausics.net> <2025Oct2.224440@mips.complang.tuwien.ac.at> <nnd$36c0a5f5$2a9d9179@1179128ec025831e> |
Am 03.10.2025 um 11:02 schrieb albert@spenarnc.xs4all.nl: > In article <2025Oct2.224440@mips.complang.tuwien.ac.at>, > Anton Ertl <anton@mips.complang.tuwien.ac.at> wrote: >> dxf <dxforth@gmail.com> writes: >>> For 3DUP I believe this is the one to beat: >>> >>> : 3DUP ( a b c -- a b c a b c ) dup 2over rot ; >>> >>> With NTF/LFX the locals version will break even. >> >> As we already discussed in the thread including >> <2021Sep11.083507@mips.complang.tuwien.ac.at>, NTF/LXF produces the >> same (optimal for the calling convention used by NTF/LXF) code for >> 3DUP versions using the data stack, return stack, or locals. That's >> because the actual data flow is always the same, and NTF/LXF can see >> this data flow in all three cases. > > The problem with 3DUP is that it is actually used in context. > What is the data that is going to 3DUP ped? In my view this > amounts to double use of data that is in registers (32 in the riscv) > anyway, after an optimiser does his thing. > Code inlining will mend it.
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar
Generating a random sequence of Forth words anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2025-09-30 16:33 +0000
Re: Generating a random sequence of Forth words minforth <minforth@gmx.net> - 2025-10-01 11:20 +0200
Re: Generating a random sequence of Forth words anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2025-10-01 17:10 +0000
Re: Generating a random sequence of Forth words Hans Bezemer <the.beez.speaks@gmail.com> - 2025-10-01 17:11 +0200
Re: Generating a random sequence of Forth words minforth <minforth@gmx.net> - 2025-10-01 20:42 +0200
Re: Generating a random sequence of Forth words dxf <dxforth@gmail.com> - 2025-10-02 19:49 +1000
Re: Generating a random sequence of Forth words albert@spenarnc.xs4all.nl - 2025-10-02 13:07 +0200
Re: Generating a random sequence of Forth words dxf <dxforth@gmail.com> - 2025-10-03 18:22 +1000
3dup again (was: Generating a random sequence of Forth words) anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2025-10-02 20:44 +0000
Re: 3dup again (was: Generating a random sequence of Forth words) albert@spenarnc.xs4all.nl - 2025-10-03 11:02 +0200
Re: 3dup again minforth <minforth@gmx.net> - 2025-10-03 11:09 +0200
Re: 3dup again anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2025-10-04 08:04 +0000
Re: 3dup again Hans Bezemer <the.beez.speaks@gmail.com> - 2025-10-05 11:29 +0200
Re: Generating a random sequence of Forth words antispam@fricas.org (Waldek Hebisch) - 2025-10-15 19:19 +0000
Re: Generating a random sequence of Forth words anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2025-10-24 15:55 +0000
csiph-web