Difference between revisions of "Assembly"

From Chessprogramming wiki
Jump to: navigation, search
Line 126: Line 126:
 
* [http://www.peter-cockerell.net/aalp/html/frames.html ARM Assembly Language Programming] by [http://www.peter-cockerell.net/ Pete Cockerell]
 
* [http://www.peter-cockerell.net/aalp/html/frames.html ARM Assembly Language Programming] by [http://www.peter-cockerell.net/ Pete Cockerell]
 
==[[Fairchild F8]]==
 
==[[Fairchild F8]]==
* [http://bitsavers.informatik.uni-stuttgart.de/pdf/fairchild/f8/F8_prelimUM_Jan75.pdf F8 Prelimanary Microprocessor User's Manual] (pdf) Circuit Organization, Machine Instructions, F8 Cross Assembler, F8 Cross Simulator, from [http://bitsavers.informatik.uni-stuttgart.de/ bitsavers.org] » [[Fairchild F8]]
+
* [https://archive.org/details/bitsavers_fairchildfng1977_5888299 Fairchild F8 Guide To Programming 1977], hosted by the [https://en.wikipedia.org/wiki/Internet_Archive Internet Archive] » [[Fairchild F8]]
 
==HP Saturn==
 
==HP Saturn==
 
* <span id="HPSATURN"></span>[https://fr.linkedin.com/in/fernandesgilbert Gilbert Fernandes], [http://www.hpcalc.org/contact.php Eric Rechlin] ('''2005'''). ''[http://www.hpcalc.org/details.php?id=1693 Introduction to Saturn Assembly Language]''. Third edition, Part of the [http://www.hpcalc.org/ HP Calculator Archive] » [https://en.wikipedia.org/wiki/HP_Saturn HP Saturn], [https://en.wikipedia.org/wiki/HP_48_series HP 48 series]
 
* <span id="HPSATURN"></span>[https://fr.linkedin.com/in/fernandesgilbert Gilbert Fernandes], [http://www.hpcalc.org/contact.php Eric Rechlin] ('''2005'''). ''[http://www.hpcalc.org/details.php?id=1693 Introduction to Saturn Assembly Language]''. Third edition, Part of the [http://www.hpcalc.org/ HP Calculator Archive] » [https://en.wikipedia.org/wiki/HP_Saturn HP Saturn], [https://en.wikipedia.org/wiki/HP_48_series HP 48 series]

Revision as of 14:25, 11 June 2018

Home * Programming * Languages * Assembly

Assembly is a family of low-level languages for programming computers. They implement a symbolic representation of the machine instructions and data needed to program a particular CPU architecture with its particular instruction- and register set. An assembler is used to translate the assembly source code into executable machine instructions in object code. Almost each architecture and its extensions have their own proprietary assembly language with different syntax and mnemonics for operations, data declarations etc..

Assembler

CDC 6600/Cyber

Mobility in Chess 4.6 based on 47 CXi Xk Population Count, written in COMPASS, the CDC Macro Assembler for the CDC 6600 and CDC Cyber [1]. The square list aka bitboard was loaded into two 60-bit registers, with both populations added and stored.

** COUNTS - COUNT MEMBERS OF A SQUARE LIST

COUNTS MACRO Y
.STST
LOADS Y
.CHK2
CX'.S1' X'.S1'
CX'.S2' X'.S2'
IX'.SS' X'.S2'+X'.S1'
.STND
COUNTS ENDM 
...
SETQ MOBIL,(PLUS,(COUNTS,(INDEXS,ATKFR,(LSHIFT,SQLN,1))),MOB

Cray

Cray Assembly Language (CAL) [2], some snippet from Cray Blitz Bitboard code for the Cray-1 or Cray X-MP [3]:

l1020    =         *              
         s3        msave3-1,a2    
         s4        msave4-1,a2    
         a4        pcount-1,a1    
         a6        pcount-1,a5    
         pfirst-1,a1 s1           
         plast-1,a1 s2            
         pfirst-1,a5 s3           
         plast-1,a5 s4            
         a4        a4-1           
         a6        a6+1           
         pcount-1,a1 a4           
         pcount-1,a5 a6    

Intel/AMD

Architectures

CPU Assemblers
8080 / Z80 ASM80
8086 MASM, TASM, NASM, GNU Assembler
x86 FASM, MASM, NASM, TASM, GNU Assembler
x86-64 MASM64, NASM, GNU Assembler

Syntax

Intel-Syntax: operation target, source

  add rax, rdx  ; rax += rdx

AT & T Syntax operation<type> source, target

  addq %rdx, %rax  /* rax += rdx */

PDP-6

HAKMEM 169, to count the ones in a PDP-6/PDP-10 36-bit word, written in MIDAS [4]:

   LDB B,[014300,,A]      ;or MOVE B,A then LSH B,-1
   AND B,[333333,,333333]
   SUB A,B
   LSH B,-1
   AND B,[333333,,333333]
   SUBB A,B               ;each octal digit is replaced by number of 1's in it
   LSH B,-3
   ADD A,B
   AND A,[070707,,070707]
   IDIVI A,77             ;casting out 63.'s

Inline Assembly

Inline assembly is embedded inside various C, C++, D, Pascal and Delphi compiler [5].

See also

Publications

Listings

Manuals

6502

68000

Alpha

ARM

Fairchild F8

HP Saturn

PowerPC

SPARC

x86-64

Z80

  • Neil J. Colvin (1977). TDL Z80 Relocating/Linking Assembler User's Manual. pdf

Forum Posts

External Links

DEC

IBM

Intel

References

Up one Level