aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/ops.tab
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2010-12-09 20:57:27 +0100
committerBjörn Gustavsson <[email protected]>2011-01-17 15:23:44 +0100
commit5cf1e739a5599943c1ac1d40d0577f83f5e0e62b (patch)
tree8d783ae37a1a4da872a6093d6f670b98d071cbdc /erts/emulator/beam/ops.tab
parent3694076f5a68cc78e9ccd6c67651bc0f761fc94f (diff)
downloadotp-5cf1e739a5599943c1ac1d40d0577f83f5e0e62b.tar.gz
otp-5cf1e739a5599943c1ac1d40d0577f83f5e0e62b.tar.bz2
otp-5cf1e739a5599943c1ac1d40d0577f83f5e0e62b.zip
Eliminate use of GetArg1() in the badmatch and case_end instructions
Create separate instructions for each register type. The "badmatch x(0)" and "case_end x(0)" (which are very common) will only require a single word each, compared to two words when GetArg1() is used.
Diffstat (limited to 'erts/emulator/beam/ops.tab')
-rw-r--r--erts/emulator/beam/ops.tab14
1 files changed, 10 insertions, 4 deletions
diff --git a/erts/emulator/beam/ops.tab b/erts/emulator/beam/ops.tab
index edc44f966b..c10b3e8d52 100644
--- a/erts/emulator/beam/ops.tab
+++ b/erts/emulator/beam/ops.tab
@@ -250,11 +250,17 @@ is_number Fail Literal=q => move Literal x | is_number Fail x
jump f
-case_end Literal=q => move Literal x | case_end x
-badmatch Literal=q => move Literal x | badmatch x
+case_end Literal=cq => move Literal x | case_end x
+badmatch Literal=cq => move Literal x | badmatch x
+
+case_end r
+case_end x
+case_end y
+
+badmatch r
+badmatch x
+badmatch y
-case_end s
-badmatch s
if_end
raise s s