Parse insertlane and extractlane instruction formats.

These instruction formats take immediate lane index operands. We store these as
u8 fields and require them to be in decimal format in the source. No hexadecimal
lane indexes are supported.
This commit is contained in:
Jakob Stoklund Olesen
2016-07-06 13:36:15 -07:00
parent e5feb864c7
commit a6c1362975
3 changed files with 53 additions and 3 deletions

View File

@@ -14,3 +14,10 @@ function select() {
ebb0(vx0: i32, vx1: i32, vx2: b1):
v0 = select vx2, vx0, vx1
}
function lanes() {
ebb0:
v0 = iconst.i32x4 2
v1 = extractlane v0, 3
v2 = insertlane v0, 1, v1
}