Allow for special purpose function arguments and return values.

Enumerate a set of special purposes for function arguments that general
purpose code needs to know about. Some of these argument purposes will
only appear in the signature of the current function, representing
things the prologue and epilogues need to know about like the link
register and callee-saved registers.

Get rid of the 'inreg' argument flag. Arguments can be pre-assigned to a
specific register instead.
This commit is contained in:
Jakob Stoklund Olesen
2017-04-17 15:04:00 -07:00
parent d3235eb81f
commit 7e9bdcf059
6 changed files with 116 additions and 18 deletions

View File

@@ -42,8 +42,7 @@ class CretonneLexer(RegexLexer):
(r'[-+]?(\d+\.\d+([eE]\d+)?|s?NaN|Inf)', Number.Float),
(r'[-+]?\d+', Number.Integer),
# Known attributes.
(keywords('align', 'aligntrap', 'uext', 'sext', 'inreg'),
Name.Attribute),
(keywords('uext', 'sext'), Name.Attribute),
# Well known value types.
(r'\b(b\d+|i\d+|f32|f64)(x\d+)?\b', Keyword.Type),
# v<nn> = value