Click Here
home features news forums classifieds faqs links search
6071 members 
Amiga Q&A /  Free for All /  Emulation /  Gaming / (Latest Posts)
Login

Nickname

Password

Lost Password?

Don't have an account yet?
Register now!

Support Amigaworld.net
Your support is needed and is appreciated as Amigaworld.net is primarily dependent upon the support of its users.
Donate

Menu
Main sections
» Home
» Features
» News
» Forums
» Classifieds
» Links
» Downloads
Extras
» OS4 Zone
» IRC Network
» AmigaWorld Radio
» Newsfeed
» Top Members
» Amiga Dealers
Information
» About Us
» FAQs
» Advertise
» Polls
» Terms of Service
» Search

IRC Channel
Server: irc.amigaworld.net
Ports: 1024,5555, 6665-6669
SSL port: 6697
Channel: #Amigaworld
Channel Policy and Guidelines

Who's Online
20 crawler(s) on-line.
 121 guest(s) on-line.
 0 member(s) on-line.



You are an anonymous user.
Register Now!
 BigD:  12 mins ago
 OlafS25:  14 mins ago
 kolla:  33 mins ago
 amigakit:  42 mins ago
 NutsAboutAmiga:  45 mins ago
 Gunnar:  1 hr 23 mins ago
 Frank:  1 hr 30 mins ago
 MickJT:  2 hrs 9 mins ago
 A1200:  2 hrs 33 mins ago
 outlawal2:  3 hrs 7 mins ago

/  Forum Index
   /  General Technology (No Console Threads)
      /  The (Microprocessors) Code Density Hangout
Register To Post

Goto page ( 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 Next Page )
PosterThread
cdimauro 
The (Microprocessors) Code Density Hangout
Posted on 1-May-2021 5:39:00
#1 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

Since we talk about code density from time to time, I'd like to open a thread in this section to collect all information, instead of having it spread around in several threads (which also disappear and are difficult to retrieve).

@matthey: I think that you're the most competent and active expert about this topic. Would you like to contribute?

My idea is to create some comments at the beginning of the thread which covers/collect specific topics, which will get updated from time to time. Example:
- General information (what's code density, why it's important, etc.)
- Benchmarks (state of the art)
- Compilers (which ones are best)
- Literature (book, academic papers, web sites)
- Microprocessors (general information like if the ISA is more or less oriented to code density, if it has specific execution modes for compact code, if it has specific extensions for compact code, etc.)
- Motorola 68K corner (anything which is useful about this family, which is not covered by other topics)
- Intel IA-32/x86 / AMD x86-64/x64 corner (...)
- ARM corner (...)
- RISC-V corner (...)
- SuperH / J2 corner (...)
- Embedded corner (...)
- another 5 empty comments for topics which may pop-up in future.

@matthey can you take care of creating and updating those comments? As I said, you're the most competent and also active, so I think that you can contribute much better than me.

A request from my side: please can you share your updated 68K source about this http://deater.net/weave/vmwprod/asm/ll/ll.html ? Looking at your tables in Google Documents the numbers don't match with what mr. Weaver published in that link.

 Status: Offline
Profile     Report this post  
noXLar 
Re: The (Microprocessors) Code Density Hangout
Posted on 1-May-2021 20:32:39
#2 ]
Cult Member
Joined: 8-May-2003
Posts: 736
From: Norway

@cdimauro

wow, are you back:)

nice to see you bro! hope you will supply site with lots of interesting things:)

_________________
nox's in the house!

 Status: Offline
Profile     Report this post  
matthey 
Re: The (Microprocessors) Code Density Hangout
Posted on 2-May-2021 0:06:06
#3 ]
Super Member
Joined: 14-Mar-2007
Posts: 1968
From: Kansas

cdimauro Quote:

Since we talk about code density from time to time, I'd like to open a thread in this section to collect all information, instead of having it spread around in several threads (which also disappear and are difficult to retrieve).

@matthey: I think that you're the most competent and active expert about this topic. Would you like to contribute?

...

@matthey can you take care of creating and updating those comments? As I said, you're the most competent and also active, so I think that you can contribute much better than me.


The topic is a nice idea but I get the feeling that most people here really don't want to know about code density so I'm not very motivated. I really should stop wasting my time here but the interesting court case lured me in.

cdimauro Quote:

A request from my side: please can you share your updated 68K source about this http://deater.net/weave/vmwprod/asm/ll/ll.html ? Looking at your tables in Google Documents the numbers don't match with what mr. Weaver published in that link.


The last update I sent Dr. Weaver was mostly an improvement of the decompression code by ross on EAB. The assembler files are available on the last 2 pages of the following thread.

http://eab.abime.net/showthread.php?s=e81df9c472e296778e1c2996bf076333&t=85855&page=8

Notice that ross complains in the last post about the statistics not being updated.

ross Quote:

Just noticed that my 54 byte version is not signaled.
http://www.deater.net/weave/vmwprod/asm/ll/
(best is the 56 bytes 8086 version)

68k deserve the throne

 Status: Offline
Profile     Report this post  
cdimauro 
General information
Posted on 2-May-2021 5:34:39
#4 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Benchmarks
Posted on 2-May-2021 5:35:05
#5 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

Some benchmarks from the The Totally Unscientific Code Density Competition! (compiling the OSD control module from one of the many Minimig variants):

OpenRISC – 81376
MIPS (f32c) – 71356
RISC-V – 69936
ZPU – 68868
ARM – 67952
X86-64 – 66112
m68k (68000) – 65760
i386 – 64080
832 – 63599
RISC-V compressed – 57780
MIPS16 – 54192
ARM Thumb – 51436


Some benchmarks from the Code Density Compared Between Way Too Many Instruction Sets (doing a buildroot run. NOTE: of what? The Gemini portal? NOT clear):
Microblaze LE - 1,223,148 bytes - No target specific settings available
Xtensa - 1,216,228 bytes - fsf target
OpenRISC - 1,133,164 bytes - No target specific settings available
MIPS32 LE - 1,017,196 bytes - P5600 target, no softfloat
SPARC64 - 997,624 bytes - SPARCv9
MIPS64 LE - 989,024 bytes - P6600 target, no softfloat, n32 ABI
PPC64LE - 985,552 bytes - Power8 target
PPC32 - 984,396 bytes - 476FP target
RV64G - 934,368 bytes - RV64G platform defaults
SPARC32 - 931,064 bytes - SPARCv8
S390X - 907,712 bytes - z15 target
Nios II - 892,316 bytes - No target specific settings available
NDS32 - 888,124 bytes - No target specific settings available
SH-4A LE - 842,884 bytes - No target specific settings
ARM64 LE - 779,936 bytes - Cortex-A76 target, FP-ARMv8
x86_64 - 747,224 bytes - Haswell target
RV64GC - 741,856 bytes - ilp64d ABI
RV32GC - 719,916 bytes - ilp32d ABI
x86 - 713,916 bytes - i686 target
m68k - 698,776 bytes - M68040 target
ARM Thumb1 LE - 632,004 bytes - Thumb, softfloat, ARM926T target
ARC LE - 623,912 bytes - 8K pages, HS38 Quad MAC + FPU target
ARM Thumb2 LE - 599,248 bytes - Thumb2, VFPv4-D16, Cortex-A7 target


Some benchmarks from the SPARC16: A new compression approach for the SPARC architecture:
SPARC16-A-new-compression-approach-for-the-SPARC-architecture


Some benchmarks from High-Performance Extendable Instruction Set Computing (benchmark tests unknown):
High-Performance-Extendable-Instruction-Set-Computing


Some benchmarks from Comparative Architectures, CST Part II, 16 lectures, Lent Term 2005 (Ian Pratt) (Old versions of GCC, GCC-C++, PGP):
Comparative-Architectures-CST-Part-II-16-lectures-Lent-Term-2005-Ian-Prattview image download


Some benchmarks from Enhancing the RISC-V Instruction Set Architecture (SPEC2006 and CSiBE test suits used with GCC):
SPEC2006
Enhancing-the-RISC-V-Instruction-Set-Architecture-1-SPEC2006how to modify pictures online for free

SPEC2006 - Compressed vs Base ISA
Enhancing-the-RISC-V-Instruction-Set-Architecture-2-SPEC2006-Compressed-vs-Base-ISA

CSiBE
Enhancing-the-RISC-V-Instruction-Set-Architecture-3-CSi-BE

Average instruction length
Enhancing-the-RISC-V-Instruction-Set-Architecture-4-Average-instruction-length

Normalised instruction counts
Enhancing-the-RISC-V-Instruction-Set-Architecture-5-Normalised-instruction-counts

Last edited by cdimauro on 03-Oct-2022 at 04:57 PM.
Last edited by cdimauro on 02-Oct-2022 at 07:43 PM.
Last edited by cdimauro on 02-Oct-2022 at 07:24 PM.
Last edited by cdimauro on 19-Sep-2022 at 08:47 PM.
Last edited by cdimauro on 18-Sep-2022 at 05:01 AM.

 Status: Offline
Profile     Report this post  
cdimauro 
Compilers
Posted on 2-May-2021 5:35:23
#6 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Literature
Posted on 2-May-2021 5:35:37
#7 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Microprocessors
Posted on 2-May-2021 5:35:52
#8 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Motorola 68K
Posted on 2-May-2021 5:36:22
#9 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

Some instructions statistics from Kickstart 1.2:

1 word opcodes: 1965 (51.0)
2 word opcodes: 1436 (37.2)
3 word opcodes: 267 (6.9)
4 word opcodes: 92 (2.4)
5 word opcodes: 34 (0.9)
6 word opcodes: 7 (0.2)
7 word opcodes: 17 (0.4)
8 word opcodes: 18 (0.5)
9 word opcodes: 3 (0.1)


And from some applications (only showing instructions with 1% or more of total):
Program 'dis' (my disassember, asm)
total insts = 23861
1 word insts = 11050, 46%
2 word insts = 10940, 45%
3 word insts = 1834, 7%

Program 'CMP' (asm)
total insts = 1984
1 word insts = 752, 37%
2 word insts = 943, 47%
3 word insts = 217, 10%
4 word insts = 72, 3%

Program 'MBRTest-2' (asm?)
total insts = 25401
1 word insts = 16664, 65%
2 word insts = 7619, 29%
3 word insts = 965, 3%

Program 'Hex'
total insts = 8730
1 word insts = 2935, 33%
2 word insts = 5120, 58%
3 word insts = 646, 7%

Program 'Redit'
total insts = 23984
1 word insts = 8890, 37%
2 word insts = 12025, 50%
3 word insts = 2880, 12%

Program 'cb' (Sierra game "Colonel's bequest")
total insts = 1093
1 word insts = 454, 41%
2 word insts = 561, 51%
3 word insts = 65, 5%
4 word insts = 13, 1%

Program 'AIBB'
total insts = 49748
1 word insts = 22517, 45%
2 word insts = 20943, 42%
3 word insts = 5574, 11%

Program 'moned'
total insts = 5136
1 word insts = 2894, 56%
2 word insts = 2023, 39%
3 word insts = 208, 4%

Program 'AmiModRadio'
total insts = 43042
1 word insts = 24239, 56%
2 word insts = 11125, 25%
3 word insts = 7587, 17%

Program 'wolf3d'
total insts = 40359
1 word insts = 20901, 51%
2 word insts = 11938, 29%
3 word insts = 5932, 14%
4 word insts = 1398, 3%

Program 'IBrowse' (sasc)
total insts = 222475
1 word insts = 115443, 51%
2 word insts = 88699, 39%
3 word insts = 15854, 7%
4 word insts = 2397, 1%

Program 'python2.4' (gcc?)
total insts = 175669
1 word insts = 98758, 56%
2 word insts = 55819, 31%
3 word insts = 19977, 11%

Last edited by cdimauro on 10-Sep-2022 at 07:22 AM.

 Status: Offline
Profile     Report this post  
cdimauro 
Intel IA-32/x86 / AMD x86-64/x64
Posted on 2-May-2021 5:36:36
#10 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
ARM
Posted on 2-May-2021 5:36:51
#11 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
RISC-V
Posted on 2-May-2021 5:37:06
#12 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
SuperH / J2
Posted on 2-May-2021 5:37:18
#13 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Embedded
Posted on 2-May-2021 5:37:31
#14 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
NEx64T
Posted on 2-May-2021 5:38:09
#15 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

Code density statistics for NEx64T (click on the images for better quality):

08-Code-density-improvements

09-Instructions-lengths-distribution-32-bit-mode

10-Instructions-lengths-distribution-64-bit-mode


Instructions execution statistics for NEx64T (click on the images for better quality):
11-Fewer-instructions-executed


32-bit Windows applications used:
arm-none-eabi-gdb.exe
cc1.exe
cc1plus.exe
CrashReportClient_32.exe
Discord.exe
ffmpeg_32.exe
FoxitProxyServer_Socket_RD.exe
GalaxyCommunication.exe
GameClient.exe
Kodi.exe
LauncherPrereqSetup_x64.exe
lto1.exe
MassEffect3.exe
Microsoft.VSCode.CPP.Extension.exe
MomodoraRUtM.exe
Neverwinter.exe
OriginER.exe
OriginThinSetupInternal.exe
ovftool.exe
PlanMaker.exe
Presentations.exe
PS32.exe
Skype.exe
sublime_text_32.exe
TextMaker.exe
The Bard's Tale.exe
TOTALCMD.EXE
UE4Game_32.exe
vmware-remotemks.exe
vs_profiler_x86_enu.exe
WinUAE.exe


64-bit Windows applications used:
aswidsagenta.exe
atio6axx.dll
Code.exe
CrashReportClient_64.exe
EpicGamesLauncher.exe
EXCEL.EXE
fdm.exe
ffmpeg_64.exe
GRAPH.EXE
mame64.exe
mkvinfo.exe
MSACCESS.EXE
MSPUB.EXE
node.exe
OfficeC2RClient.exe
PS64.exe
steamwebhelper.exe
sublime_text_64.exe
TOTALCMD64.EXE
UE4Game_64.exe
VirtualBox.exe
vmware-vmx-debug.exe
vmware-vmx.exe
vsinstr.exe
WinUAE64.exe


Decoder information for NEx64T (click on the images for better quality):
05-Instructions-decoding-only-first-bits-LSBs-matter

06-Simplified-frontend-decoders-keep-only-the-good-parts-of-Intel64-x64

07-New-opportunities-with-simplified-frontend

Last edited by cdimauro on 10-Sep-2022 at 07:53 AM.

 Status: Offline
Profile     Report this post  
cdimauro 
Future Topic
Posted on 2-May-2021 5:38:23
#16 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Future Topic
Posted on 2-May-2021 5:38:34
#17 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Future Topic
Posted on 2-May-2021 5:38:45
#18 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Future Topic
Posted on 2-May-2021 5:38:57
#19 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  
cdimauro 
Future Topic
Posted on 2-May-2021 5:39:11
#20 ]
Elite Member
Joined: 29-Oct-2012
Posts: 3621
From: Germany

TBD

 Status: Offline
Profile     Report this post  

[ home ][ about us ][ privacy ] [ forums ][ classifieds ] [ links ][ news archive ] [ link to us ][ user account ]
Copyright (C) 2000 - 2019 Amigaworld.net.
Amigaworld.net was originally founded by David Doyle