diff options
author | Björn Gustavsson <[email protected]> | 2010-01-15 12:26:17 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2010-01-15 13:40:14 +0100 |
commit | 31e231d813d8a15a937ebd5fbb71299ce1faf9c1 (patch) | |
tree | fc90dee8d743c38b3072350c16d23ec3f4899044 /lib/compiler/vsn.mk | |
parent | b327123e4da61ee2794aa473d357c37e7168d189 (diff) | |
download | otp-31e231d813d8a15a937ebd5fbb71299ce1faf9c1.tar.gz otp-31e231d813d8a15a937ebd5fbb71299ce1faf9c1.tar.bz2 otp-31e231d813d8a15a937ebd5fbb71299ce1faf9c1.zip |
beam_validator: fix incorrect assumptions about GC guard BIFs
The beam_validator pass incorrectly assumes that a GC guard
BIF (such as length/1) may first do a garbage collection
and then fail. That assumption is not correct (guards BIF
only do garbage collection when it is known that the BIF
call will succeed), and will cause the compiler to reject
valid programs.
Modify the beam_validator to assume that if the branch is
taken for a gc_bif instruction, all registers are unchanged
and no garbage collection has occurred. Also add a comment
in the emulator about that assumption.
Diffstat (limited to 'lib/compiler/vsn.mk')
0 files changed, 0 insertions, 0 deletions