diff options
author | Björn Gustavsson <[email protected]> | 2018-10-29 16:31:00 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2018-11-21 10:09:10 +0100 |
commit | e79e5f194577d6c5b289415ec84338f70d2486db (patch) | |
tree | 3677f1347f8db479329a28130eefb3809235399f /lib/ssh/test | |
parent | b4595a670b159c802489d94d8537a48567967927 (diff) | |
download | otp-e79e5f194577d6c5b289415ec84338f70d2486db.tar.gz otp-e79e5f194577d6c5b289415ec84338f70d2486db.tar.bz2 otp-e79e5f194577d6c5b289415ec84338f70d2486db.zip |
Sort move instructions on the Y register
Sort sequences of `move` instructions on the Y register.
When moving from X registers to Y registers, having the instructions
sorted on Y registers give the loader more opportunities to use
`move_window{3,4,5}` instructions. For examples, the following five
instructions:
move_xy x(2) y(0)
move_xy x(1) y(1)
move_xy x(0) y(2)
move_xy x(5) y(3)
move_xy x(4) y(4)
can be replaced with:
move_window5_xxxxxy x(2) x(1) x(0) x(5) x(4) y(0)
When the Y registers are not ordered so that `move_window5` can be
used, the loader would typically combine the first three moves to a
`move3_xyxyxy` instruction and the last two moves to a
`move2_par_xyxy` instruction.
When moving from Y registers to X registers, sorting on the Y
registers could potentially be more cache-friendly. It could also
be worthwhile investigating a new `move_window` instruction in
the BEAM interpreter that could move values from contiguous Y registers
to X registers.
Note that `scripts/diffable` can generate diffable dissambly files for
the loaded BEAM code:
$ scripts/diffable --dis 0
$ scripts/diffable --dis 1
$ diff -u 0 1
Diffstat (limited to 'lib/ssh/test')
0 files changed, 0 insertions, 0 deletions