H. Peter Anvin | c65a2f6 | 2007-10-22 17:34:10 -0700 | [diff] [blame^] | 1 | ;; Integer constants... |
| 2 | |
H. Peter Anvin | bea0bbb | 2007-10-22 16:53:48 -0700 | [diff] [blame] | 3 | dd 1010_0101 ; Decimal |
| 4 | dd 01010_0101 ; Decimal (*not* octal!) |
| 5 | dd 0d1010_0101 ; Decimal |
| 6 | dd 0t1010_0101 ; Decimal |
| 7 | dd 1010_0101d ; Decimal |
| 8 | dd 1010_0101t ; Decimal |
| 9 | |
| 10 | dd 0b1010_0101 ; Binary |
| 11 | dd 0y1010_0101 ; Binary |
| 12 | dd 1010_0101b ; Binary |
| 13 | dd 1010_0101y ; Binary |
| 14 | |
| 15 | dd 0o1010_0101 ; Octal |
| 16 | dd 0q1010_0101 ; Octal |
| 17 | dd 1010_0101o ; Octal |
| 18 | dd 1010_0101q ; Octal |
| 19 | |
| 20 | dd 0h1010_0101 ; Hex |
| 21 | dd 0x1010_0101 ; Hex |
| 22 | dd 1010_0101h ; Hex |
| 23 | dd 1010_0101x ; Hex |
| 24 | dd $1010_0101 ; Hex |
H. Peter Anvin | c65a2f6 | 2007-10-22 17:34:10 -0700 | [diff] [blame^] | 25 | |
| 26 | ;; Floating-point constants |
| 27 | ;; All of these should output B4A21147 |
| 28 | dd 3.7282705e+4 ; Decimal |
| 29 | dd 00003.7282705e+4 ; Decimal |
| 30 | dd 0d3.7282705e+4 ; Decimal |
| 31 | dd 0t3.7282705e+4 ; Decimal |
| 32 | |
| 33 | dd 0x1.23456789p+15 ; Hex |
| 34 | dd 0h1.23456789p+15 ; Hex |
| 35 | |
| 36 | dd 0o1.10642547422p+15 ; Octal |
| 37 | dd 0q1.10642547422p+15 ; Octal |
| 38 | |
| 39 | dd 0b1.0010_0011_0100_0101_0110_0111_1000_1001p+15 ; Binary |
| 40 | dd 0y1.0010_0011_0100_0101_0110_0111_1000_1001p+15 ; Binary |