On 5-Apr-08, at 11:16 AM, Joachim MÃ¥rtensson wrote:
I just joined this list and seem to be having trouble posting, but I'll give it another try.
I was wondering what the prevailing wisdom is regarding pattern naming conventions for assembly languages. I'm working on a bundle for an obscure chip (the long-discontinued Motorola DSP96002 which we still use in a variety instruments on account of it being one of the few DSPs which supports extended precision floats). So far, I've got patterns like "assembly.opcode", "assembly.directive", and "assembly.directive.macro", but I'm not sure this is the way to go. Should these all be under "keyword", for example?
While I am not an authorative person on the subject (I do get harassed by Infininight ever so often ;) ) here are some suggestions:
assembly.opcode => keyword.control.assembly (Jump, Call, Load, Store etc) perhaps ops such as add and multiply should be keyword.operator.assembly
assembly.directive.macro => support.function.macro.assembly
I would put registers under storage.type.register.assembly and labels under entity.name.function.assembly. For example,
label: add r1, r2
in the above label would be the entity scope, r1 and r2 the storage.
Wow, you have a very different take on it. I will definitely consider your approach...
-Ted