douggilliland / R32V2020

My 32-bit RISC CPU for smallish FPGAs
GNU General Public License v3.0
14 stars 3 forks source link

Reference data labels #43

Closed mjgpy3 closed 5 years ago

mjgpy3 commented 5 years ago

Broken off of #38.

mjgpy3 commented 5 years ago
label: .string "Hell"
lil r8,label.LOWER
label2: .string "Foo"

Examples

lil r8,label.LOWER ; references 0000
liu r8,label.UPPER ; references 0000
lil r8,label2.LOWER ; references 0001
liu r8,label2.UPPER ; references 0000
douggilliland commented 5 years ago

Works well.

Produced List file -

helloWorld:     .string "R32V2020"
; Read 32-bit elapsed time counter and put to 7 seg display
start:
00000000    42400000        lix SAR,helloWorld.LOWER

Data File -

:0400000052333256EF
:040001003230323037
:0400020000000000FA
:00000001FF